/* Plaza Park Pay - Global Styles */
:root {
  /* Colors - we'll update these based on your image */
  --primary-color: #58381b;  /* Blue - adjust based on your logo */
  --secondary-color: #e9bd80; /* Orange/Gold accent */
  --success-color: #27ae60;
  --error-color: #e74c3c;
  --text-primary: #58381b;
  --text-secondary: #7f8c8d;
  --background: #f8f9fa;
  --white: #f4eade;
  --border-color: #dee2e6;
  --dark-text: #553816;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  background-color: var(--background);
  color: var(--text-primary);
  line-height: 1.6;
  min-height: 100vh;
}

.container {
  max-width: 400px;
  margin: 0 auto;
  padding: 20px;
  background-color: var(--white);
  min-height: 100vh;
}

.lot-code-badge {
    display: inline-block;
    background-color: var(--primary-color);
    color: var(--secondary-color);
    padding: 8px 20px;
    border-radius: 25px;
    font-size: 24px;
    font-weight: bold;
    letter-spacing: 2px;
    margin: 15px 0 10px 0;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

/* Header with Logo */
.header {
  text-align: center;
  margin-bottom: 30px;
  padding-bottom: 20px;
  border-bottom: 2px solid var(--border-color);
}

.logo-container {
  margin-bottom: 20px;
}

.logo-img {
  max-width: 200px;
  height: auto;
}

.logo-text {
  font-size: 24px;
  font-weight: bold;
  color: var(--primary-color);
  margin-bottom: 10px;
}

.lot-name {
  font-size: 20px;
  color: var(--text-primary);
  margin-bottom: 5px;
}

.lot-address {
  font-size: 14px;
  color: var(--text-secondary);
}

/* Form Styles */
.form-group {
  margin-bottom: 20px;
}

label {
  display: block;
  margin-bottom: 5px;
  font-weight: 600;
  color: var(--text-primary);
}

input, select {
  width: 100%;
  padding: 12px;
  border: 2px solid var(--border-color);
  border-radius: 8px;
  font-size: 16px;
  transition: all 0.3s;
  background-color: var(--white);
}

input:focus, select:focus {
  outline: none;
  border-color: var(--primary-color);
  box-shadow: 0 0 0 3px rgba(44, 90, 160, 0.1);
}

.license-group {
  display: flex;
  gap: 10px;
}

.license-plate {
  flex: 1;
}

.state-select {
  width: 100px;
}

/* Duration Selector */
.duration-selector {
  display: flex;
  align-items: center;
  gap: 15px;
  padding: 15px;
  background-color: var(--background);
  border-radius: 12px;
  margin-bottom: 20px;
  border: 2px solid var(--border-color);
}

.duration-controls {
  display: flex;
  align-items: center;
  gap: 10px;
}

.btn-duration {
  width: 40px;
  height: 40px;
  border: none;
  background-color: var(--primary-color);
  color: var(--white);
  border-radius: 50%;
  font-size: 20px;
  cursor: pointer;
  transition: all 0.3s;
  display: flex;
  align-items: center;
  justify-content: center;
}

.btn-duration:hover {
  transform: scale(1.1);
  box-shadow: 0 4px 8px rgba(0,0,0,0.2);
}

.btn-duration:disabled {
  background-color: var(--border-color);
  cursor: not-allowed;
  transform: scale(1);
}

.duration-display {
  font-size: 28px;
  font-weight: bold;
  min-width: 50px;
  text-align: center;
  color: var(--text-primary);
}

/* Cost Display */
.cost-display {
  background: linear-gradient(135deg, var(--primary-color), var(--primary-color));
  padding: 20px;
  border-radius: 12px;
  margin-bottom: 20px;
  text-align: center;
  color: var(--white);
  box-shadow: 0 4px 6px rgba(0,0,0,0.1);
}

.cost-label {
  font-size: 14px;
  opacity: 0.9;
  margin-bottom: 5px;
}

.cost-amount {
  font-size: 36px;
  font-weight: bold;
}

.rate-info {
  font-size: 12px;
  opacity: 0.8;
  margin-top: 5px;
}

/* Buttons */
.btn-checkout {
  width: 100%;
  padding: 16px;
  background-color: var(--success-color);
  color: var(--white);
  border: none;
  border-radius: 12px;
  font-size: 18px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s;
  box-shadow: 0 4px 6px rgba(39, 174, 96, 0.3);
}

.btn-checkout:hover {
  background-color: #219a52;
  transform: translateY(-2px);
  box-shadow: 0 6px 12px rgba(39, 174, 96, 0.4);
}

.btn-checkout:disabled {
  background-color: #95a5a6;
  cursor: not-allowed;
  transform: translateY(0);
  box-shadow: none;
}

/* Error Messages */
.error {
  color: var(--error-color);
  font-size: 14px;
  margin-top: 5px;
}

/* Success Page Styles */
.success-container {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  min-height: 100vh;
  text-align: center;
}

.success-icon {
  width: 80px;
  height: 80px;
  background-color: var(--success-color);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 20px;
  animation: scaleIn 0.5s ease-out;
}

@keyframes scaleIn {
  from {
    transform: scale(0);
    opacity: 0;
  }
  to {
    transform: scale(1);
    opacity: 1;
  }
}

.checkmark {
  color: var(--white);
  font-size: 40px;
}

.message {
  color: var(--text-secondary);
  margin-bottom: 30px;
  font-size: 18px;
}

.details {
  background-color: var(--background);
  padding: 20px;
  border-radius: 12px;
  margin-bottom: 30px;
  width: 100%;
  border: 2px solid var(--border-color);
}

.detail-row {
  display: flex;
  justify-content: space-between;
  margin-bottom: 10px;
  font-size: 14px;
}

.detail-label {
  color: var(--text-secondary);
}

.detail-value {
  font-weight: 600;
  color: var(--text-primary);
}

.timer {
  font-size: 48px;
  font-weight: bold;
  color: var(--primary-color);
  margin-bottom: 10px;
}

.timer-label {
  color: var(--text-secondary);
  font-size: 14px;
  margin-bottom: 30px;
}

/* Loading Spinner */
.loading {
  display: inline-block;
  width: 20px;
  height: 20px;
  border: 3px solid var(--white);
  border-top: 3px solid transparent;
  border-radius: 50%;
  animation: spin 1s linear infinite;
}

@keyframes spin {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

/* Responsive */
@media (max-width: 480px) {
  .container {
    padding: 15px;
  }
  
  .cost-amount {
    font-size: 32px;
  }
  
  .timer {
    font-size: 36px;
  }
  
}

/* Map styles */
.map-container {
    margin: 20px -20px; /* Negative margins to make it full width */
    overflow: hidden;
}

.lot-map {
    width: 100%;
    height: auto;
    display: block;
    border-top: 2px solid var(--border-color);
    border-bottom: 2px solid var(--border-color);
}

/* On mobile, ensure map touches screen edges */
@media (max-width: 480px) {
    .map-container {
        margin: 20px -15px;
    }
}

/* Rate toggle styles */
.rate-toggle {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
    margin-bottom: 20px;
}

.rate-option {
    padding: 15px;
    border: 2px solid var(--border-color);
    border-radius: 12px;
    background: var(--white);
    cursor: pointer;
    transition: all 0.3s;
    position: relative;
    overflow: visible; /* Changed from hidden to visible */
}

.rate-option:hover {
    border-color: var(--primary-color);
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0,0,0,0.1);
}

.rate-option.active {
    border-color: var(--primary-color);
    background: linear-gradient(135deg, rgba(44, 90, 160, 0.1), rgba(44, 90, 160, 0.05));
}

.rate-option.recommended {
    border-color: var(--success-color);
    margin-top: 25px; /* Add space for the badge above */
}

/* New "Best Value" badge positioning - above the box */
.rate-option.recommended::before {
    content: 'BEST VALUE';
    position: absolute;
    top: -25px; /* Position above the box */
    left: 50%;
    transform: translateX(-50%); /* Center horizontally */
    background: var(--success-color);
    color: var(--white);
    padding: 5px 15px;
    font-size: 10px;
    font-weight: bold;
    border-radius: 12px;
    white-space: nowrap;
    z-index: 1;
    box-shadow: 0 2px 4px rgba(0,0,0,0.2);
}

.rate-label {
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 5px;
}

.rate-price {
    font-size: 18px;
    color: var(--primary-color);
    font-weight: bold;
}

.rate-savings {
    font-size: 12px;
    color: var(--success-color);
    margin-top: 5px;
    font-weight: 600;
}

.daily-message {
    text-align: center;
    padding: 20px;
    background: var(--background);
    border-radius: 8px;
    color: var(--text-secondary);
}

.daily-message .icon {
    font-size: 24px;
    margin-right: 10px;
}

@keyframes slideUp {
    from {
        transform: translate(-50%, 100%);
        opacity: 0;
    }
    to {
        transform: translate(-50%, 0);
        opacity: 1;
    }
}

.notification-content {
    display: flex;
    align-items: center;
    gap: 15px;
}

.close-btn {
    background: none;
    border: none;
    color: white;
    font-size: 24px;
    cursor: pointer;
    opacity: 0.8;
    transition: opacity 0.2s;
}

.close-btn:hover {
    opacity: 1;
}

/* Parking lots list styles */
.lots-container {
    margin: 20px 0;
}

.lot-card {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px;
    margin-bottom: 15px;
    background: var(--white);
    border: 2px solid var(--border-color);
    border-radius: 12px;
    transition: all 0.3s;
}

.lot-card:hover {
    border-color: var(--primary-color);
    box-shadow: 0 4px 8px rgba(0,0,0,0.1);
}

.lot-info {
    flex: 1;
}

.lot-code-small {
    font-weight: bold;
    color: var(--primary-color);
    font-size: 18px;
    margin-bottom: 5px;
}

.lot-name-small {
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 5px;
}

.lot-address-small {
    font-size: 14px;
    color: var(--text-secondary);
    margin-bottom: 5px;
}

.lot-rates {
    font-size: 14px;
    color: var(--success-color);
    font-weight: 600;
}

.btn-park-now {
    padding: 12px 24px;
    background-color: var(--primary-color);
    color: var(--white);
    text-decoration: none;
    border-radius: 8px;
    font-weight: 600;
    transition: all 0.3s;
    white-space: nowrap;
}

.btn-park-now:hover {
    background-color: #1e3d6f;
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0,0,0,0.2);
}

.loading-message {
    text-align: center;
    color: var(--text-secondary);
    padding: 40px;
}
/* Breadcrumb styles */
.breadcrumb {
    background-color: var(--background);
    padding: 10px 20px;
    border-bottom: 1px solid var(--border-color);
}

.breadcrumb-link {
    color: var(--primary-color);
    text-decoration: none;
    font-size: 14px;
    display: inline-flex;
    align-items: center;
    transition: opacity 0.3s;
}

.breadcrumb-link:hover {
    opacity: 0.7;
}

/* Adjust container top margin to account for breadcrumb */
.container {
    margin-top: 0; /* Remove any existing top margin */
}
#map {
    width: 100%;
    height: 300px;
    border-radius: 8px; /* Optional: rounded corners */
}

/* Make map responsive */
@media (max-width: 480px) {
    #map {
        height: 150px;
    }
}
.map-loading {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 100%;
    color: var(--text-secondary);
}
@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.active-session-notice {
    animation: slideDown 0.3s ease-out;
}