/* ============================================================
   ALWAYS AUTOMATIC — shared styles for secondary pages
   (get-started, contact, terms, privacy, 404)
   Matches the homepage design system: near-black stage / warm
   paper light mode, Space Grotesk + Inter + Instrument Serif +
   IBM Plex Mono, one lime accent.
   ============================================================ */

:root {
  --lime: #C8FE5D;
  --sage: #95CC75;
  --cream: #F6F8ED;

  --bg: #070B0A;
  --bg-deep: #050807;
  --bg-soft: #0B1411;
  --text: #F6F8ED;
  --muted: rgba(246, 248, 237, 0.55);
  --dim: rgba(246, 248, 237, 0.34);
  --hairline: rgba(244, 242, 234, 0.09);
  --accent-ink: #C8FE5D;
  --card-grad-a: rgba(246, 248, 237, 0.035);
  --card-grad-b: rgba(246, 248, 237, 0.012);
  --nav-bg: rgba(7, 11, 10, 0.65);
  --ghost-border: rgba(246, 248, 237, 0.25);
  --ghost-hover: rgba(246, 248, 237, 0.05);
  --btn-primary-hover-bg: #F6F8ED;
  --btn-primary-hover-color: #0A130F;
  --btn-hover-shadow: rgba(200, 254, 93, 0.25);
  --chip-bg: rgba(246, 248, 237, 0.04);
  --card-shadow: none;
  --btn-primary-border: transparent;

  --font-headline: 'Space Grotesk', sans-serif;
  --font-body: 'Inter', sans-serif;
  --font-serif: 'Instrument Serif', serif;
  --font-mono: 'IBM Plex Mono', monospace;

  --ease-out: cubic-bezier(0.22, 1, 0.36, 1);
}

[data-theme="light"] {
  --bg: #F4F2EA;
  --bg-deep: #EAE7DB;
  --bg-soft: #FDFCF6;
  --text: #101713;
  --muted: rgba(16, 23, 19, 0.66);
  --dim: rgba(16, 23, 19, 0.46);
  --hairline: rgba(16, 23, 19, 0.13);
  --accent-ink: #43761B;
  --card-grad-a: #FFFFFF;
  --card-grad-b: #FCFBF5;
  --nav-bg: rgba(244, 242, 234, 0.72);
  --ghost-border: rgba(16, 23, 19, 0.3);
  --ghost-hover: rgba(16, 23, 19, 0.05);
  --btn-primary-hover-bg: #101713;
  --btn-primary-hover-color: #F4F2EA;
  --btn-hover-shadow: rgba(16, 23, 19, 0.18);
  --chip-bg: rgba(255, 255, 255, 0.6);
  --card-shadow: 0 1px 2px rgba(16, 23, 19, 0.05), 0 12px 32px rgba(16, 23, 19, 0.07);
  --btn-primary-border: rgba(16, 23, 19, 0.12);
}

/* ==================== BASE ==================== */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }

body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 17px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  min-height: 100svh;
  display: flex;
  flex-direction: column;
  transition: background-color 0.45s ease, color 0.45s ease;
  opacity: 0;
}
body.loaded { opacity: 1; transition: opacity 0.5s ease, background-color 0.45s ease, color 0.45s ease; }

::selection { background: var(--lime); color: #0A130F; }
img, svg { display: block; max-width: 100%; }
button { font: inherit; }
a { color: inherit; text-decoration: none; }
em { font-style: normal; }

:focus-visible {
  outline: 2px solid var(--accent-ink);
  outline-offset: 3px;
  border-radius: 4px;
}

.mono {
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}
.serif { font-family: var(--font-serif); font-style: italic; font-weight: 400; }

/* ==================== GRAIN ==================== */
.grain {
  position: fixed;
  inset: -100px;
  z-index: 2000;
  pointer-events: none;
  opacity: 0.55;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 240 240' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2' stitchTiles='stitch'/%3E%3CfeColorMatrix type='saturate' values='0'/%3E%3CfeComponentTransfer%3E%3CfeFuncA type='linear' slope='0.05'/%3E%3C/feComponentTransfer%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  background-size: 240px 240px;
}
[data-theme="light"] .grain { opacity: 0.26; filter: invert(1); }

/* ==================== SUBNAV ==================== */
.subnav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 1000;
  padding: 16px 0;
  background: var(--nav-bg);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--hairline);
}
.subnav-inner {
  max-width: 1400px;
  margin: 0 auto;
  padding: 0 48px;
  display: flex;
  align-items: center;
  gap: 24px;
}
.subnav-brand {
  display: flex;
  align-items: center;
  gap: 12px;
  font-family: var(--font-headline);
  font-weight: 500;
  font-size: 16px;
  letter-spacing: -0.01em;
  color: var(--text);
}
/* the mark's cream blocks disappear on paper; swap to the light logo palette */
[data-theme="light"] .subnav-brand rect[fill="#F6F8ED"] { fill: #132A1F; }
[data-theme="light"] .subnav-brand rect[fill="#95CC75"] { fill: #37892C; }
[data-theme="light"] .subnav-brand rect[fill="#C8FE5D"] { fill: #90C413; }

.subnav-right { margin-left: auto; display: flex; align-items: center; gap: 20px; }
.subnav-back {
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--muted);
  transition: color 0.25s ease;
  display: inline-flex;
  align-items: center;
  gap: 8px;
}
.subnav-back:hover { color: var(--text); }

.theme-toggle {
  width: 38px;
  height: 38px;
  flex-shrink: 0;
  border-radius: 50%;
  border: 1px solid var(--hairline);
  background: transparent;
  color: var(--muted);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: color 0.25s ease, border-color 0.25s ease, transform 0.25s var(--ease-out);
}
.theme-toggle:hover { color: var(--text); border-color: var(--text); transform: rotate(15deg); }
.theme-toggle .icon-sun { display: none; }
[data-theme="light"] .theme-toggle .icon-sun { display: block; }
[data-theme="light"] .theme-toggle .icon-moon { display: none; }

/* ==================== BUTTONS ==================== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  font-family: var(--font-headline);
  font-weight: 500;
  letter-spacing: 0.01em;
  border-radius: 100px;
  border: 1px solid transparent;
  cursor: pointer;
  white-space: nowrap;
  transition: background 0.3s var(--ease-out), color 0.3s var(--ease-out),
              border-color 0.3s var(--ease-out), box-shadow 0.3s var(--ease-out),
              transform 0.3s var(--ease-out);
}
.btn:hover { transform: translateY(-2px); }
.btn-primary { background: var(--lime); color: #0A130F; border-color: var(--btn-primary-border); }
.btn-primary:hover {
  background: var(--btn-primary-hover-bg);
  color: var(--btn-primary-hover-color);
  box-shadow: 0 10px 40px var(--btn-hover-shadow);
}
.btn-ghost { background: transparent; color: var(--text); border-color: var(--ghost-border); }
.btn-ghost:hover { border-color: var(--text); background: var(--ghost-hover); }
.btn-lg { padding: 18px 40px; font-size: 16px; }

/* ==================== PAGE HERO (contact / 404 / get-started) ==================== */
.page {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 130px 24px 80px;
  position: relative;
  background: radial-gradient(110% 80% at 50% 50%, var(--bg-soft) 0%, var(--bg) 70%);
  transition: background-color 0.45s ease;
}
/* margin:auto centers when there is room and top-aligns (scrollable) when there is not */
.page-content { width: 100%; max-width: 1100px; position: relative; z-index: 1; margin: auto; }
.page-center { text-align: center; max-width: 640px; margin: 0 auto; }

.page-chip {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  padding: 9px 20px;
  border: 1px solid var(--hairline);
  border-radius: 100px;
  background: var(--chip-bg);
  color: var(--muted);
  margin-bottom: 40px;
}
.page-chip-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--lime);
  box-shadow: 0 0 12px rgba(200, 254, 93, 0.9);
}
[data-theme="light"] .page-chip-dot { background: #4F7A2E; box-shadow: 0 0 10px rgba(79, 122, 46, 0.7); }

.page-headline {
  font-family: var(--font-headline);
  font-weight: 500;
  font-size: clamp(48px, 7.5vw, 110px);
  line-height: 1.0;
  letter-spacing: -0.04em;
  color: var(--text);
  margin-bottom: 28px;
}
.page-headline .serif { color: var(--accent-ink); }
.page-sub {
  font-size: clamp(17px, 1.5vw, 19px);
  line-height: 1.7;
  color: var(--muted);
  max-width: 50ch;
  margin-bottom: 44px;
}
.page-center .page-sub { margin-left: auto; margin-right: auto; }
.page-detail { margin-top: 26px; color: var(--dim); }
.page-detail a { color: var(--muted); transition: color 0.25s ease; }
.page-detail a:hover { color: var(--accent-ink); }

/* ==================== GET STARTED ==================== */
.gs-grid {
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  gap: 80px;
  align-items: center;
}
.gs-bullets { list-style: none; margin-bottom: 36px; }
.gs-bullets li {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 13px 0;
  font-size: 16.5px;
  color: var(--muted);
  border-bottom: 1px solid var(--hairline);
}
.gs-bullets li:last-child { border-bottom: none; }
.gs-check {
  flex-shrink: 0;
  width: 12px;
  height: 1.5px;
  background: var(--accent-ink);
}
.gs-note { color: var(--accent-ink); }

.booking-card {
  border: 1px solid var(--hairline);
  border-radius: 28px;
  padding: 48px 44px;
  background: linear-gradient(180deg, var(--card-grad-a), var(--card-grad-b));
  position: relative;
  overflow: hidden;
  text-align: center;
  box-shadow: var(--card-shadow);
}
.booking-card::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 1px;
  background: linear-gradient(to right, transparent, var(--accent-ink), transparent);
  opacity: 0.8;
}
.booking-badge { display: inline-block; color: var(--accent-ink); margin-bottom: 24px; }
.booking-title {
  font-family: var(--font-headline);
  font-weight: 500;
  font-size: 32px;
  letter-spacing: -0.02em;
  color: var(--text);
  margin-bottom: 12px;
}
.booking-desc { font-size: 15.5px; color: var(--muted); line-height: 1.65; margin-bottom: 32px; }
.booking-btn { width: 100%; }
.booking-meta {
  margin-top: 22px;
  display: flex;
  justify-content: center;
  gap: 26px;
  color: var(--dim);
}
.booking-meta span { display: inline-flex; align-items: center; gap: 7px; }
.booking-meta svg { width: 13px; height: 13px; color: var(--accent-ink); }

/* ==================== LEGAL PAGES ==================== */
.legal-nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 1000;
  padding: 16px 0;
  background: var(--nav-bg);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--hairline);
  display: flex;
  align-items: center;
}
.legal-nav .legal-nav-inner {
  width: 100%;
  max-width: 880px;
  margin: 0 auto;
  padding: 0 32px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
}
.legal-nav .brand {
  font-family: var(--font-headline);
  font-weight: 500;
  font-size: 16px;
  color: var(--text);
}
.legal-nav a:not(.brand) {
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--muted);
  transition: color 0.25s ease;
}
.legal-nav a:not(.brand):hover { color: var(--text); }
.legal-nav-right { display: flex; align-items: center; gap: 20px; }

.container {
  width: 100%;
  max-width: 820px;
  margin: 0 auto;
  padding: 150px 32px 100px;
  flex: 1;
}
.container h1 {
  font-family: var(--font-headline);
  font-weight: 500;
  font-size: clamp(40px, 5.5vw, 64px);
  letter-spacing: -0.03em;
  line-height: 1.05;
  color: var(--text);
  margin-bottom: 20px;
}
.container .meta {
  font-family: var(--font-mono);
  font-size: 12.5px;
  letter-spacing: 0.06em;
  line-height: 2;
  color: var(--dim);
  padding-bottom: 32px;
  margin-bottom: 48px;
  border-bottom: 1px solid var(--hairline);
}
.container h2 {
  font-family: var(--font-headline);
  font-weight: 500;
  font-size: 26px;
  letter-spacing: -0.015em;
  color: var(--text);
  margin: 52px 0 16px;
}
.container h3 {
  font-family: var(--font-headline);
  font-weight: 500;
  font-size: 19px;
  color: var(--text);
  margin: 32px 0 10px;
}
.container p { color: var(--muted); margin-bottom: 16px; font-size: 16px; line-height: 1.75; }
.container ul, .container ol { margin: 0 0 16px 22px; color: var(--muted); font-size: 16px; line-height: 1.75; }
.container li { margin-bottom: 8px; }
.container strong { color: var(--text); font-weight: 600; }
.container a { color: var(--accent-ink); text-decoration: underline; text-underline-offset: 3px; }
.container .footer-legal {
  margin-top: 80px;
  padding-top: 32px;
  border-top: 1px solid var(--hairline);
  color: var(--dim);
  font-size: 14px;
}
.container .footer-legal p { color: var(--dim); font-size: 14px; }
.container .footer-legal a {
  color: var(--muted);
  text-decoration: none;
  margin: 0 12px 0 0;
  transition: color 0.25s ease;
}
.container .footer-legal a:hover { color: var(--accent-ink); }

/* ==================== MINI FOOTER ==================== */
.footer-mini {
  padding: 28px 24px;
  text-align: center;
  border-top: 1px solid var(--hairline);
  color: var(--dim);
  font-size: 13px;
  position: relative;
  z-index: 1;
}
.footer-mini a { color: var(--muted); transition: color 0.25s ease; }
.footer-mini a:hover { color: var(--accent-ink); }
.footer-mini .links { display: inline-flex; gap: 24px; margin-left: 24px; }

/* ==================== RESPONSIVE ==================== */
@media (max-width: 900px) {
  .gs-grid { grid-template-columns: 1fr; gap: 48px; }
}
@media (max-width: 768px) {
  body { font-size: 16px; }
  .subnav-inner { padding: 0 22px; }
  .page { padding: 120px 22px 60px; }
  .booking-card { padding: 38px 28px; }
  .container { padding: 130px 22px 70px; }
  .legal-nav .legal-nav-inner { padding: 0 22px; }
  .footer-mini .links { display: flex; justify-content: center; margin: 10px 0 0; }
}

/* ==================== REDUCED MOTION ==================== */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    transition-duration: 0.01ms !important;
  }
  body { opacity: 1; }
}
