:root {
  --bg-main: radial-gradient(circle at top, #101632 0, #050814 55%, #02030a 100%);
  --card-bg: rgba(10, 15, 33, 0.9);
  --accent: #f9c838;
  --accent-soft: #fef4cf;
  --accent-hover: #ffde6a;
  --border-subtle: rgba(255, 255, 255, 0.08);
  --text-main: #f7f8ff;
  --text-muted: #a9b0d4;
  --text-soft: rgba(255, 255, 255, 0.82);
  --error: #ff6b81;
  --usop-blue: #193f90;
  --usop-gold: #f9c838;
  --field-bg: rgba(8, 12, 28, 0.95);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  padding: 20px 12px;
  min-height: 100vh;
  font-family: 'Montserrat', system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  background: var(--bg-main);
  color: var(--text-main);
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  align-items: center;
}

.page-wrapper {
  width: 100%;
  max-width: 1100px;
  display: flex;
  flex-direction: column;
  gap: 18px;
}

header.hero {
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding: 12px 18px 4px;
  border-radius: 18px;
  background: linear-gradient(145deg, rgba(25, 63, 144, 0.75), rgba(3, 6, 24, 0.96));
  border: 1px solid rgba(249, 200, 56, 0.35);
  box-shadow:
    0 22px 60px rgba(0, 0, 0, 0.7),
    0 0 0 1px rgba(0, 0, 0, 0.55);
  position: relative;
  overflow: hidden;
}

header.hero::before {
  content: '';
  position: absolute;
  inset: -40%;
  background:
    radial-gradient(circle at 10% 0%, rgba(249, 200, 56, 0.32) 0, transparent 50%),
    radial-gradient(circle at 80% 20%, rgba(119, 152, 255, 0.32) 0, transparent 55%);
  opacity: 0.85;
  pointer-events: none;
  mix-blend-mode: screen;
}

.hero-inner {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: row;
  justify-content: space-between;
  gap: 18px;
  align-items: center;
}

.hero-main {
  flex: 1.1;
  min-width: 0;
}

.hero-logo {
  height: 72px;
  width: auto;
  display: block;
  margin-bottom: 6px;
  max-width: 100%;
  object-fit: contain;
  filter: drop-shadow(0 6px 16px rgba(0, 0, 0, 0.6));
}

.hero-title {
  margin: 2px 0 6px;
  font-size: clamp(1.4rem, 1.8vw + 0.8rem, 1.8rem);
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: #fff;
  text-shadow: 0 4px 12px rgba(0, 0, 0, 0.75);
}

.hero-subtitle {
  margin: 0;
  font-size: 0.9rem;
  color: var(--text-soft);
  max-width: 620px;
  line-height: 1.45;
}

.hero-subtitle strong {
  color: var(--accent-soft);
  font-weight: 600;
}

.hero-badges {
  margin-top: 6px;
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  font-size: 0.75rem;
  color: var(--text-soft);
}

.hero-badge {
  padding: 4px 10px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.22);
  background: linear-gradient(
    135deg,
    rgba(0, 0, 0, 0.75),
    rgba(4, 10, 35, 0.95)
  );
  display: inline-flex;
  align-items: center;
  gap: 6px;
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.65);
  backdrop-filter: blur(12px);
}

.hero-badge span.emoji {
  font-size: 0.95rem;
}

.hero-aside {
  flex: 0.9;
  min-width: 0;
  display: flex;
  justify-content: flex-end;
}

.hero-aside-card {
  border-radius: 16px;
  padding: 10px 12px;
  background: radial-gradient(circle at top, rgba(1, 15, 40, 0.96), rgba(0, 3, 13, 0.98));
  border: 1px solid rgba(255, 255, 255, 0.15);
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.75);
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--text-soft);
  max-width: 310px;
  width: 100%;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.hero-aside-title {
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.16em;
  color: var(--accent-soft);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
}
.field-label.parking-selection-label {
  color: var(--accent-soft);
  font-weight: 700;
}



.hero-aside-tag {
  font-size: 0.75rem;
  padding: 4px 10px;
  border-radius: 999px;

  /* stronger gold border */
  border: 1px solid rgba(249, 200, 56, 0.95);

  /* darker background to boost contrast */
  background: radial-gradient(
    circle at top,
    rgba(249, 200, 56, 0.55),
    rgba(0, 0, 0, 0.85)
  );

  /* more readable text color */
  color: #ffffff;

  font-weight: 700;

  /* subtle glow instead of white highlight */
  text-shadow:
    0 1px 2px rgba(0, 0, 0, 0.85),
    0 0 4px rgba(249, 200, 56, 0.4);
}


.hero-aside-list {
  margin: 2px 0 0;
  padding-left: 1.05rem;
}

.hero-aside-list li {
  margin-bottom: 2px;
  line-height: 1.35;
}

.hero-aside-footnote {
  font-size: 0.72rem;
  color: var(--text-muted);
  line-height: 1.3;
  margin-top: 2px;
}

main.card {
  border-radius: 20px;
  background: radial-gradient(circle at top left, rgba(28, 46, 100, 0.72), rgba(2, 3, 12, 0.98));
  padding: 16px 14px 18px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  box-shadow:
    0 24px 70px rgba(0, 0, 0, 0.85),
    0 0 0 1px rgba(0, 0, 0, 0.8);
}

.card-inner {
  display: grid;
  grid-template-columns: minmax(0, 3fr) minmax(0, 2.3fr);
  gap: 20px;
  align-items: flex-start;
}

section {
  background: linear-gradient(
    145deg,
    rgba(5, 10, 33, 0.98),
    rgba(3, 6, 18, 0.98)
  );
  border-radius: 16px;
  padding: 14px 14px 15px;
  border: 1px solid rgba(255, 255, 255, 0.06);
  box-shadow: 0 14px 40px rgba(0, 0, 0, 0.8);
}

.section-title {
  margin: 0 0 10px;
  font-size: 1rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent-soft);
  display: flex;
  align-items: center;
  gap: 7px;
}

.section-title span.badge {
  font-size: 0.72rem;
  padding: 2px 8px;
  border-radius: 999px;
  background: rgba(249, 200, 56, 0.14);
  color: var(--text-soft);
  border: 1px solid rgba(249, 200, 56, 0.65);
}

.fields-grid {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.field-group {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.field-label {
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--text-muted);
  display: flex;
  align-items: center;
  gap: 6px;
}

.required {
  color: var(--accent);
  font-size: 0.8rem;
}

.name-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 12px;
}

@media (max-width: 600px) {
  .name-row {
    grid-template-columns: 1fr;
    gap: 10px;
  }
}

input[type="email"],
input[type="number"],
input[type="text"],
select {
  width: 100%;
  padding: 11px 13px;
  border-radius: 10px;
  border: 1px solid rgba(255, 255, 255, 0.16);
  background: rgba(5, 12, 32, 0.85);
  color: var(--text-main);
  font-size: 0.95rem;
  outline: none;
  transition: border-color 0.15s ease, box-shadow 0.15s ease, background 0.15s ease;
  min-height: 44px;
}

input:focus,
select:focus {
  border-color: var(--usop-gold);
  box-shadow: 0 0 0 1px rgba(249, 200, 56, 0.3);
  background: rgba(6, 16, 48, 0.95);
}

input[type="number"]::-webkit-inner-spin-button,
input[type="number"]::-webkit-outer-spin-button {
  -webkit-appearance: none;
  margin: 0;
}

.help-text {
  font-size: 0.78rem;
  color: var(--text-muted);
  margin-top: 3px;
  line-height: 1.4;
}

.error-text {
  font-size: 0.78rem;
  color: var(--error);
  margin-top: 4px;
}

.ticket-options {
  display: grid;
  grid-template-columns: 1fr;
  gap: 12px;
}

@media (min-width: 700px) {
  .ticket-options {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

.ticket-option-card {
  border-radius: 12px;
  padding: 10px 11px;
  background: radial-gradient(circle at top left, rgba(25, 63, 144, 0.3), rgba(3, 7, 20, 0.98));
  border: 1px solid rgba(255, 255, 255, 0.14);
  display: flex;
  flex-direction: column;
  gap: 4px;
  position: relative;
  cursor: pointer;
  transition:
    border-color 0.18s ease,
    box-shadow 0.18s ease,
    transform 0.12s ease,
    background 0.18s ease;
}

.ticket-option-card:hover {
  transform: translateY(-1px);
  border-color: rgba(249, 200, 56, 0.75);
  box-shadow:
    0 16px 36px rgba(0, 0, 0, 0.8),
    0 0 0 1px rgba(249, 200, 56, 0.35);
  background: radial-gradient(circle at top left, rgba(25, 63, 144, 0.45), rgba(3, 7, 20, 0.98));
}

.ticket-header {
  display: flex;
  align-items: center;
  gap: 8px;
}

.ticket-radio {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 20px;
  height: 20px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.4);
  background: rgba(0, 0, 0, 0.65);
  position: relative;
}

.ticket-radio input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.ticket-radio-indicator {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: transparent;
  transition: background 0.18s ease;
}

.ticket-option-card input:checked + .ticket-radio-indicator {
  background: var(--usop-gold);
  box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.7);
}

.ticket-title {
  font-size: 0.9rem;
  font-weight: 600;
  color: #ffffff;
}

.ticket-subtitle {
  font-size: 0.75rem;
  color: var(--text-soft);
}

.ticket-price {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--accent-soft);
}

.ticket-note {
  font-size: 0.75rem;
  margin: 2px 0 0;
  color: var(--text-muted);
}

.days-input-row {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 6px;
}

.days-input-row input[type="number"] {
  max-width: 80px;
  text-align: center;
  padding-right: 0;
}

.days-input-row .inline-note {
  font-size: 0.78rem;
  color: var(--text-muted);
}

aside {
  background: linear-gradient(
    150deg,
    rgba(1, 10, 30, 0.98),
    rgba(0, 0, 0, 0.98)
  );
  border-radius: 16px;
  padding: 12px 13px 14px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  box-shadow: 0 18px 45px rgba(0, 0, 0, 0.9);
}

.summary-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
  margin-bottom: 10px;
}

.summary-title {
  font-size: 0.96rem;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--accent-soft);
}

.summary-pill {
  font-size: 0.72rem;
  padding: 4px 8px;
  border-radius: 999px;
  border: 1px solid rgba(76, 175, 80, 0.9);
  color: #c8f9d0;
  background: radial-gradient(circle at top, rgba(76, 175, 80, 0.35), rgba(0, 0, 0, 0.98));
  text-shadow: 0 1px 0 rgba(0, 0, 0, 0.6);
}

.summary-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.86rem;
  margin-bottom: 6px;
  color: var(--text-soft);
}

.summary-row span:first-child {
  color: var(--text-muted);
}

.summary-total {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  margin-top: 8px;
  padding-top: 8px;
  border-top: 1px dashed rgba(255, 255, 255, 0.16);
  font-size: 0.9rem;
  font-weight: 600;
}

.summary-total-amount {
  font-size: 1.05rem;
  color: var(--accent-soft);
}

.summary-footnote {
  margin-top: 9px;
  font-size: 0.78rem;
  color: var(--text-muted);
  line-height: 1.35;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border-radius: 999px;
  padding: 12px 24px;
  font-size: 0.93rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.16em;
  border: none;
  cursor: pointer;
  margin-top: 14px;
  background: linear-gradient(135deg, #f9c838, #ffed94);
  color: #1a1403;
  text-shadow: 0 1px 0 rgba(255, 255, 255, 0.4);
  box-shadow:
    0 12px 26px rgba(0, 0, 0, 0.85),
    0 0 0 1px rgba(0, 0, 0, 0.7);
  transition:
    transform 0.1s ease,
    box-shadow 0.12s ease,
    filter 0.12s ease;
  width: 100%;
}

.btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
  box-shadow: 0 8px 18px rgba(0, 0, 0, 0.7);
  filter: grayscale(0.1);
}

.btn:not(:disabled):hover {
  transform: translateY(-1px);
  box-shadow: 0 16px 30px rgba(0, 0, 0, 0.55);
  filter: brightness(1.02);
}

.btn:not(:disabled):active {
  transform: translateY(0);
}

.btn-icon {
  font-size: 1rem;
}

.status-message {
  font-size: 0.8rem;
  margin-top: 8px;
  min-height: 1.2em;
  line-height: 1.4;
}

.status-message.error {
  color: var(--error);
}

.status-message.success {
  color: var(--usop-gold);
}

.weekly-tip {
  font-size: 0.8rem;
  margin-top: 8px;
  padding: 8px 10px;
  border-radius: 8px;
  background: rgba(249, 200, 56, 0.06);
  border: 1px solid rgba(249, 200, 56, 0.55);
  color: var(--text-main);
  line-height: 1.4;
}

@media (max-width: 900px) {
  body {
    padding: 14px 10px;
    align-items: flex-start;
  }

  .page-wrapper {
    gap: 14px;
  }

  header.hero {
    padding: 12px 12px 6px;
  }

  .hero-inner {
    flex-direction: column;
    align-items: flex-start;
  }

  .hero-main {
    width: 100%;
  }

  .hero-aside {
    width: 100%;
    justify-content: flex-start;
  }

  .hero-aside-card {
    max-width: 100%;
  }

  main.card {
    padding: 14px 10px 16px;
  }

  .card-inner {
    grid-template-columns: 1fr;
    gap: 16px;
  }
}

@media (max-width: 600px) {
  body {
    padding: 10px 8px;
  }

  header.hero {
    border-radius: 14px;
  }

  .hero-title {
    font-size: 1.3rem;
  }

  .hero-subtitle {
    font-size: 0.82rem;
  }

  section,
  aside {
    border-radius: 14px;
  }

  .btn {
    padding: 11px 18px;
    font-size: 0.85rem;
    letter-spacing: 0.12em;
  }

  .summary-title {
    font-size: 0.9rem;
  }
}

/* Weekly-only mode (when daily parking is disabled) - remove hover and cursor changes */
.ticket-option-card.weekly-only {
  cursor: default;
}

.ticket-option-card.weekly-only:hover {
  transform: none;
  border-color: rgba(249, 200, 56, 0.45);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.6);
  background: radial-gradient(circle at top left, rgba(25, 63, 144, 0.35), rgba(3, 7, 20, 0.98));
}

/* Parking overview page */
.overview-section {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.overview-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 12px;
  flex-wrap: wrap;
}

.overview-lead {
  margin: 2px 0 0;
  color: var(--text-soft);
  font-size: 0.9rem;
  line-height: 1.45;
}

.overview-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.overview-refresh {
  border: none;
  border-radius: 12px;
  padding: 10px 16px;
  font-size: 0.9rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  background: linear-gradient(135deg, #f9c838, #ffed94);
  color: #0d0b02;
  cursor: pointer;
  box-shadow:
    0 10px 22px rgba(0, 0, 0, 0.75),
    0 0 0 1px rgba(0, 0, 0, 0.65);
  transition: transform 0.1s ease, box-shadow 0.12s ease, filter 0.12s ease;
  min-width: 150px;
}

.overview-refresh:disabled {
  opacity: 0.6;
  cursor: not-allowed;
  box-shadow: 0 8px 18px rgba(0, 0, 0, 0.6);
}

.overview-refresh:not(:disabled):hover {
  transform: translateY(-1px);
  box-shadow: 0 14px 26px rgba(0, 0, 0, 0.75);
  filter: brightness(1.02);
}

.overview-refresh:not(:disabled):active {
  transform: translateY(0);
}

.overview-updated {
  font-size: 0.82rem;
  color: var(--text-muted);
}

.overview-table-wrap {
  overflow-x: auto;
  border-radius: 14px;
  border: 1px solid var(--border-subtle);
  background: linear-gradient(140deg, rgba(10, 15, 33, 0.9), rgba(4, 6, 18, 0.98));
  box-shadow: 0 14px 36px rgba(0, 0, 0, 0.75);
}

.overview-table {
  width: 100%;
  border-collapse: collapse;
  min-width: 480px;
}

.overview-table th,
.overview-table td {
  padding: 12px 14px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  font-size: 0.92rem;
}

.overview-table th {
  text-align: left;
  background: rgba(255, 255, 255, 0.06);
  color: var(--accent-soft);
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.overview-table th.number-cell {
  text-align: right;
}

.overview-table td {
  color: var(--text-soft);
}

.overview-table tr:hover td {
  background: rgba(249, 200, 56, 0.05);
}

.lot-cell {
  font-weight: 700;
  color: #ffffff;
}

.number-cell {
  text-align: right;
  font-variant-numeric: tabular-nums;
}

.availability-pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 6px 10px;
  border-radius: 999px;
  font-size: 0.86rem;
  font-weight: 700;
  min-width: 68px;
}

.availability-pill.ok {
  background: rgba(76, 175, 80, 0.15);
  color: #b1f2b6;
  border: 1px solid rgba(76, 175, 80, 0.65);
}

.availability-pill.warn {
  background: rgba(255, 193, 7, 0.16);
  color: #ffe9a6;
  border: 1px solid rgba(255, 193, 7, 0.55);
}

.availability-pill.danger {
  background: rgba(255, 107, 129, 0.16);
  color: #ffc5cf;
  border: 1px solid rgba(255, 107, 129, 0.7);
}

.hero-topbar {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  width: 100%;
}

.hero-actions {
  flex: 0 0 auto;
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  align-items: flex-end;
  gap: 8px;
}

.hero-meta {
  font-size: 0.82rem;
  color: var(--text-soft);
}

.overview-empty {
  text-align: center;
  color: var(--text-muted);
  padding: 16px 12px;
}

.overview-status {
  font-size: 0.85rem;
  color: var(--text-muted);
  min-height: 1.2em;
}

.overview-status.error {
  color: var(--error);
}

@media (max-width: 760px) {
  .overview-header {
    flex-direction: column;
    align-items: flex-start;
  }

  .overview-actions {
    width: 100%;
    justify-content: space-between;
  }

  .hero-topbar {
    flex-direction: column;
    align-items: flex-start;
  }

  .hero-actions {
    align-items: flex-start;
  }
}
