/* Our Time Vacations — Facebook Zoom reservation · evening ocean/night brand */

:root {
  /* OKLCH palette — anchor hue ~200° from Impeccable seed-126 */
  --color-bg: oklch(0.10 0.045 225);
  --color-surface: oklch(0.15 0.050 225);
  --color-ink: oklch(0.93 0.015 220);
  --color-muted: oklch(0.62 0.035 215);
  --color-primary: oklch(0.58 0.14 198);
  --color-primary-hover: oklch(0.52 0.15 198);
  --color-accent: oklch(0.78 0.16 42);
  --color-accent-hover: oklch(0.72 0.17 42);
  --color-danger: oklch(0.62 0.20 25);
  --color-on-primary: oklch(0.98 0.005 220);
  --color-on-accent: oklch(0.18 0.04 42);

  --font-display: "Tenor Sans", Georgia, serif;
  --font-body: "Literata", Georgia, serif;

  --text-xs: clamp(0.75rem, 0.7rem + 0.25vw, 0.8125rem);
  --text-sm: clamp(0.875rem, 0.82rem + 0.3vw, 0.9375rem);
  --text-base: clamp(1rem, 0.94rem + 0.35vw, 1.0625rem);
  --text-lg: clamp(1.125rem, 1rem + 0.6vw, 1.3125rem);
  --text-xl: clamp(1.375rem, 1.1rem + 1.2vw, 1.75rem);
  --text-hero: clamp(2.75rem, 1.8rem + 4.5vw, 4.5rem);

  --space-xs: clamp(0.5rem, 0.4rem + 0.5vw, 0.75rem);
  --space-sm: clamp(0.75rem, 0.6rem + 0.75vw, 1rem);
  --space-md: clamp(1.25rem, 1rem + 1.25vw, 1.75rem);
  --space-lg: clamp(2rem, 1.5rem + 2.5vw, 3.5rem);
  --space-xl: clamp(3rem, 2rem + 5vw, 5rem);

  --radius-sm: 0.375rem;
  --radius-md: 0.625rem;
  --radius-pill: 999px;

  --shadow-soft: 0 1.25rem 3rem oklch(0.05 0.04 225 / 0.45);
  --ease-out: cubic-bezier(0.22, 1, 0.36, 1);
  --duration: 0.55s;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: var(--font-body);
  font-size: var(--text-base);
  line-height: 1.65;
  color: var(--color-ink);
  background: var(--color-bg);
  -webkit-font-smoothing: antialiased;
}

img {
  max-width: 100%;
  display: block;
}

main {
  min-height: 100dvh;
}

/* —— Sections —— */

.section {
  max-width: 38rem;
  margin-inline: auto;
  padding-inline: clamp(1.25rem, 4vw, 2rem);
  padding-block: var(--space-lg);
}

.section:not(#section-hero) {
  animation: step-in var(--duration) var(--ease-out) both;
}

.is-hidden {
  display: none !important;
}

/* —— Hero (full-bleed atmosphere) —— */

#section-hero {
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  min-height: 100dvh;
  max-width: none;
  margin: 0;
  padding: clamp(1.5rem, 5vw, 3rem);
  padding-bottom: clamp(2.5rem, 8vh, 4.5rem);
  overflow: visible;
  isolation: isolate;
}

.hero-media {
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  overflow: hidden;
}

.hero-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 35%;
}

.hero-media::after {
  content: "";
  position: absolute;
  inset: 0;
  /* Lighter veil so the ocean stays visible on phones */
  background:
    linear-gradient(
      175deg,
      oklch(0.08 0.05 225 / 0.25) 0%,
      oklch(0.10 0.055 220 / 0.45) 48%,
      oklch(0.09 0.06 215 / 0.78) 100%
    );
}

.hero-content {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  max-width: 38rem;
}

.hero-content > * {
  animation: hero-rise 0.9s var(--ease-out) both;
}

.hero-content > *:nth-child(1) { animation-delay: 0.05s; }
.hero-content > *:nth-child(2) { animation-delay: 0.12s; }
.hero-content > *:nth-child(3) { animation-delay: 0.18s; }
.hero-content > *:nth-child(4) { animation-delay: 0.26s; }
.hero-content > *:nth-child(5) { animation-delay: 0.34s; }
.hero-content > *:nth-child(6) { animation-delay: 0.4s; }

.brand-operator {
  margin: 0.35rem 0 0;
  font-size: var(--text-sm);
  color: var(--color-muted);
}

.hero-kicker {
  margin: 0.65rem 0 0;
  font-family: var(--font-display);
  font-size: var(--text-lg);
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--color-accent);
  text-shadow: 0 0.1em 0.45em oklch(0.08 0.05 225 / 0.5);
}

#section-hero h1 {
  margin: 0 0 var(--space-sm);
  font-family: var(--font-display);
  font-size: clamp(2.1rem, 1.4rem + 3.2vw, 3.5rem);
  font-weight: 400;
  line-height: 1.05;
  letter-spacing: -0.02em;
  color: var(--color-ink);
  text-wrap: balance;
  text-shadow: 0 0.15em 0.6em oklch(0.08 0.05 225 / 0.55);
}

#section-hero .hero-lead {
  margin: 0 0 var(--space-md);
  font-size: clamp(1.125rem, 1.02rem + 0.55vw, 1.3125rem);
  line-height: 1.55;
  color: oklch(0.94 0.015 220);
  max-width: 42ch;
  text-wrap: pretty;
  text-shadow: 0 0.1em 0.45em oklch(0.08 0.05 225 / 0.5);
}

.hero-terms {
  margin: 0 0 var(--space-md);
  padding: 1rem 1.15rem 1.05rem;
  max-width: 44ch;
  color: oklch(0.94 0.012 220);
  background: oklch(0.11 0.05 225 / 0.78);
  border: 1px solid oklch(0.78 0.16 42 / 0.35);
  border-radius: var(--radius-md);
  backdrop-filter: blur(10px);
}

.hero-terms p {
  margin: 0 0 0.7rem;
  font-size: var(--text-sm);
  line-height: 1.55;
  text-wrap: pretty;
}

.hero-terms p:last-child {
  margin-bottom: 0;
}

.hero-terms-kicker {
  font-family: var(--font-display);
  font-size: var(--text-xs);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--color-accent);
}

/* —— Typography —— */

h2 {
  margin: 0 0 var(--space-sm);
  font-family: var(--font-display);
  font-size: var(--text-xl);
  font-weight: 400;
  line-height: 1.2;
  letter-spacing: 0.01em;
}

.section > p:first-of-type {
  margin-top: 0;
  color: var(--color-muted);
}

p {
  margin: 0 0 var(--space-sm);
}

strong {
  color: var(--color-ink);
  font-weight: 600;
}

/* —— Buttons —— */

button {
  font: inherit;
  cursor: pointer;
  border: none;
  border-radius: var(--radius-pill);
  transition:
    transform 0.2s var(--ease-out),
    background-color 0.2s ease,
    box-shadow 0.2s ease,
    opacity 0.2s ease;
}

button:focus-visible {
  outline: 2px solid var(--color-accent);
  outline-offset: 3px;
}

#btn-start,
#btn-book {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin-top: var(--space-xs);
  padding: 0.9rem 1.75rem;
  font-family: var(--font-display);
  font-size: var(--text-sm);
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--color-on-accent);
  background: var(--color-accent);
  box-shadow: 0 0.5rem 1.5rem oklch(0.78 0.16 42 / 0.35);
}

#btn-start:hover,
#btn-book:hover {
  background: var(--color-accent-hover);
  transform: translateY(-2px);
}

#btn-start:active,
#btn-book:active {
  transform: translateY(0);
}

#btn-refresh-slots {
  margin-top: var(--space-sm);
  padding: 0.55rem 1.1rem;
  font-size: var(--text-xs);
  color: var(--color-muted);
  background: transparent;
  border: 1px solid oklch(0.62 0.035 215 / 0.35);
}

#btn-refresh-slots:hover {
  color: var(--color-ink);
  border-color: oklch(0.62 0.035 215 / 0.6);
}

/* Qualification choice buttons */

.qual-panel {
  margin-bottom: var(--space-md);
  padding: var(--space-md);
  background: var(--color-surface);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-soft);
}

.qual-panel p {
  margin-bottom: var(--space-xs);
}

.qual-actions {
  display: flex;
  flex-direction: column;
  gap: var(--space-xs);
  margin-top: var(--space-sm);
}

.qual-actions button {
  width: 100%;
  padding: 0.85rem 1.1rem;
  text-align: left;
  color: var(--color-ink);
  background: oklch(0.18 0.045 225);
  border: 1px solid oklch(0.28 0.05 220 / 0.5);
}

.qual-actions button:hover {
  background: oklch(0.22 0.05 220);
  border-color: var(--color-primary);
  transform: translateX(4px);
}

.qual-actions button[aria-pressed="true"],
.qual-actions button.is-selected {
  background: var(--color-primary);
  border-color: var(--color-primary);
  color: var(--color-on-primary);
}

/* Slot time buttons — vertical control list, not card grid */

#slots-list {
  display: flex;
  flex-direction: column;
  gap: var(--space-xs);
  margin-top: var(--space-md);
}

#slots-list button,
#slots-list [role="option"] {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  padding: 1rem 1.15rem;
  text-align: left;
  color: var(--color-ink);
  background: var(--color-surface);
  border: 1px solid oklch(0.25 0.05 220 / 0.55);
  border-radius: var(--radius-md);
  box-shadow: none;
}

#slots-list button:hover,
#slots-list [role="option"]:hover {
  border-color: var(--color-primary);
  transform: translateX(6px);
}

#slots-list button[aria-selected="true"],
#slots-list button.is-selected,
#slots-list [role="option"][aria-selected="true"] {
  background: oklch(0.20 0.06 200);
  border-color: var(--color-primary);
  box-shadow: inset 3px 0 0 var(--color-primary);
}

#slots-status {
  font-size: var(--text-sm);
  color: var(--color-muted);
}

/* —— Form —— */

label {
  display: block;
  margin-top: var(--space-md);
  font-family: var(--font-display);
  font-size: var(--text-xs);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--color-muted);
}

input,
select {
  display: block;
  width: 100%;
  margin-top: var(--space-xs);
  padding: 0.8rem 0.95rem;
  font: inherit;
  color: var(--color-ink);
  background: var(--color-surface);
  border: 1px solid oklch(0.28 0.05 220 / 0.55);
  border-radius: var(--radius-sm);
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

input:focus,
select:focus {
  outline: none;
  border-color: var(--color-primary);
  box-shadow: 0 0 0 3px oklch(0.58 0.14 198 / 0.25);
}

#book-error:not(:empty) {
  margin-top: var(--space-sm);
  padding: var(--space-xs) var(--space-sm);
  font-size: var(--text-sm);
  color: var(--color-danger);
  background: oklch(0.62 0.20 25 / 0.12);
  border-radius: var(--radius-sm);
}

/* —— Success / terminal sections —— */

#section-success h2,
#section-not-qualified h2 {
  color: var(--color-accent);
}

/* —— Footer —— */

footer {
  max-width: 38rem;
  margin: 0 auto;
  padding: var(--space-md) clamp(1.25rem, 4vw, 2rem) var(--space-xl);
  font-size: clamp(0.9375rem, 0.88rem + 0.3vw, 1.0625rem);
  line-height: 1.65;
  color: oklch(0.72 0.03 215);
  border-top: 1px solid oklch(0.25 0.04 220 / 0.4);
}

footer p {
  margin: 0.4rem 0 0;
}

footer p:first-child {
  margin-top: 0;
}

footer a {
  color: inherit;
  text-decoration: underline;
}

.sms-consent-block {
  margin-top: var(--space-md);
}

.sms-consent {
  display: flex;
  gap: 0.7rem;
  align-items: flex-start;
}

.sms-consent input[type="checkbox"] {
  width: auto;
  min-width: 1.1rem;
  height: 1.1rem;
  margin-top: 0.3rem;
  flex-shrink: 0;
  accent-color: var(--color-primary);
}

.sms-consent label {
  margin-top: 0;
  text-transform: none;
  letter-spacing: 0;
  font-family: var(--font-body);
  font-size: var(--text-sm);
  font-weight: 400;
  color: var(--color-ink);
  line-height: 1.5;
}

.sms-consent-links {
  margin: var(--space-xs) 0 0 1.8rem;
  font-size: var(--text-sm);
}

.sms-consent-links a {
  color: var(--color-primary);
}

body.legal-page {
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
}

.legal-header {
  max-width: 42rem;
  width: 100%;
  margin: 0 auto;
  padding: var(--space-md) clamp(1.25rem, 4vw, 2rem);
  font-family: var(--font-display);
}

.legal-header a {
  color: var(--color-ink);
  text-decoration: none;
  letter-spacing: 0.04em;
}

.legal-main {
  flex: 1;
  max-width: 42rem;
  width: 100%;
  margin: 0 auto;
  padding: 0 clamp(1.25rem, 4vw, 2rem) var(--space-lg);
}

.legal-main h1,
.legal-main h2 {
  font-family: var(--font-display);
  text-wrap: balance;
}

.legal-main .updated {
  color: var(--color-muted);
}

body.legal-page footer {
  max-width: 42rem;
}

/* —— Motion —— */

@keyframes hero-rise {
  from {
    opacity: 0;
    transform: translateY(1.25rem);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes step-in {
  from {
    opacity: 0;
    transform: translateY(0.75rem);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.section.step-in-replay {
  animation: step-in var(--duration) var(--ease-out) both;
}

@media (max-width: 47.99rem) {
  #section-hero {
    justify-content: flex-start;
    min-height: auto;
    padding-top: max(1.15rem, env(safe-area-inset-top));
    padding-bottom: 1.75rem;
  }

  #section-hero h1 {
    font-size: clamp(2.15rem, 9vw, 2.85rem);
    margin-bottom: 0.4rem;
  }

  .brand-operator {
    margin-top: 0.15rem;
  }

  #section-hero .hero-lead {
    margin-bottom: 0.85rem;
    font-size: 1.0625rem;
  }

  .hero-terms {
    padding: 0.8rem 0.9rem;
    margin-bottom: 0.85rem;
  }

  .hero-terms p {
    margin-bottom: 0.5rem;
    line-height: 1.45;
  }
}

@media (min-width: 48rem) {
  .qual-actions {
    flex-direction: row;
    flex-wrap: wrap;
  }

  .qual-actions button {
    width: auto;
    flex: 1 1 calc(50% - var(--space-xs));
    min-width: 12rem;
  }

  #section-hero {
    padding-inline: clamp(2rem, 8vw, 6rem);
  }

  #section-hero .hero-content {
    max-width: 42rem;
  }

  .hero-media::after {
    background:
      linear-gradient(
        175deg,
        oklch(0.08 0.05 225 / 0.3) 0%,
        oklch(0.10 0.055 220 / 0.55) 48%,
        oklch(0.09 0.06 215 / 0.85) 100%
      );
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }

  #section-hero > *,
  .hero-content > *,
  .section:not(#section-hero) {
    opacity: 1;
    transform: none;
  }
}
