/* =============================================================
   Bryce Canyon Night Sky — Observatory Annual Report (§4.4)
   Cormorant Garamond 600/700 (display ≥48px) + Outfit 400/500/600
   LIGHT clinical site: bg #f8f9fa, surface #ffffff
   0px radius everywhere. Institutional blue #1e3a5f.
   ============================================================= */

:root {
  --bg:        #f8f9fa;
  --surface:   #ffffff;
  --text:      #1a1f2e;
  --muted:     #6b7280;
  --accent:    #1e3a5f;
  --accent-2:  #e8930a;
  --border:    #dde1e7;
  --display:   "Cormorant Garamond", "Georgia", serif;
  --body:      "Outfit", system-ui, -apple-system, sans-serif;
}

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

html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--body);
  font-size: 17px;
  font-weight: 400;
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

@media (min-width: 768px) {
  body { font-size: 18px; }
}

/* ---------- Layout shell ---------- */

.container {
  width: min(72rem, 100% - 2.5rem);
  margin-inline: auto;
}

/* Body column capped at 65ch, left-aligned */
.page-body {
  max-width: 65ch;
}

/* Contained data callout (used inline within page-body) */
.data-callout-inline {
  background: var(--surface);
  border-left: 3px solid var(--accent-2);
  padding: 2rem 1.5rem;
  margin: 2rem 0 2.5rem;
  display: flex;
  align-items: baseline;
  gap: 1rem;
  flex-wrap: wrap;
}

/* ---------- Typography ---------- */

h1, h2, h3, h4 {
  font-family: var(--body);
  font-weight: 600;
  line-height: 1.2;
  color: var(--text);
  letter-spacing: -0.01em;
  overflow-wrap: break-word;
}

/* Cormorant display: only at ≥48px */
.display-heading {
  font-family: var(--display);
  font-weight: 700;
  line-height: 1.08;
  letter-spacing: -0.02em;
  color: var(--text);
}

h1 {
  font-size: clamp(2rem, 5.5vw, 3.25rem);
  margin: 0 0 1rem;
}

h2 {
  font-size: clamp(1.3rem, 3vw, 1.75rem);
  font-weight: 600;
  margin: 3rem 0 0.75rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--border);
}

/* Remove top border when h2 is the first block in its container */
h2:first-child { border-top: none; padding-top: 0; margin-top: 0; }
.hero-sub h2, .cta-band h2, .cta-band h3, .site-footer h2 { border-top: none; padding-top: 0; margin-top: 0; }

h3 {
  font-size: 1.1rem;
  font-weight: 600;
  margin: 1.75rem 0 0.5rem;
  color: var(--accent);
}

p { margin: 0 0 1.15rem; }

a {
  color: var(--accent);
  text-decoration-color: rgba(30,58,95,0.35);
  text-underline-offset: 3px;
  transition: color 0.12s ease;
}

a:hover { color: #152b47; text-decoration-color: var(--accent); }

ul, ol { padding-left: 1.4rem; margin: 0 0 1.25rem; }
li { margin-bottom: 0.5rem; }

p, li { max-width: 65ch; }

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

/* ---------- Navigation ---------- */

.site-nav {
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--surface);
  border-bottom: 1px solid var(--border);
}

.nav-inner {
  display: flex;
  align-items: center;
  gap: 0.25rem 1.25rem;
  padding: 0.75rem 0;
  flex-wrap: wrap;
}

.nav-brand {
  font-family: var(--body);
  font-size: 1rem;
  font-weight: 600;
  color: var(--accent);
  text-decoration: none;
  white-space: nowrap;
  margin-right: auto;
  letter-spacing: 0.01em;
}

.nav-brand:hover { color: var(--accent); }

.nav-toggle {
  display: none;
  background: transparent;
  border: 1px solid var(--border);
  color: var(--text);
  font-size: 1.2rem;
  line-height: 1;
  padding: 0.4rem 0.65rem;
  border-radius: 0;
  cursor: pointer;
  margin-left: auto;
  min-height: 44px;
  min-width: 44px;
  align-items: center;
  justify-content: center;
}

.nav-links {
  display: flex;
  gap: 0.15rem 1rem;
  list-style: none;
  margin: 0;
  padding: 0;
  flex-wrap: wrap;
  align-items: center;
}

.nav-links li { margin: 0; }

.nav-links a {
  font-size: 0.88rem;
  font-weight: 500;
  color: var(--muted);
  text-decoration: none;
  white-space: nowrap;
  padding: 0.4rem 0;
  min-height: 44px;
  display: inline-flex;
  align-items: center;
  border-bottom: 2px solid transparent;
  transition: color 0.12s;
}

.nav-links a:hover { color: var(--text); }
.nav-links a[aria-current="page"] { color: var(--accent); border-bottom-color: var(--accent); }

.nav-cta {
  background: var(--accent-2) !important;
  color: var(--text) !important;
  font-weight: 600;
  padding: 0.45rem 1rem !important;
  border-radius: 0 !important;
  border-bottom: none !important;
  min-height: 44px !important;
  display: inline-flex !important;
  align-items: center !important;
}

.nav-cta:hover { background: #c97c08 !important; color: var(--text) !important; }

/* ---------- Hero: split typographic / photo ---------- */

.hero-split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  min-height: 540px;
  border-bottom: 1px solid var(--border);
}

.hero-text {
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 5rem 3rem 5rem 0;
}

.hero-text .container {
  width: 100%;
  max-width: 520px;
  margin: 0 0 0 auto;
  padding-right: 2rem;
}

.hero-photo {
  position: relative;
  border-left: 6px solid var(--accent);
  overflow: hidden;
}

.hero-photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center top;
  display: block;
}

/* Hero typographic elements */

.hero-eyebrow {
  font-family: var(--body);
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 1.25rem;
  display: block;
}

.hero-h1 {
  font-family: var(--display);
  font-weight: 700;
  font-size: clamp(2.8rem, 6vw, 5rem);
  line-height: 1.05;
  letter-spacing: -0.025em;
  color: var(--text);
  margin: 0 0 1.25rem;
}

.hero-lede {
  font-size: 1.05rem;
  color: var(--muted);
  line-height: 1.7;
  max-width: 48ch;
  margin-bottom: 2rem;
}

/* Inner-page hero (sub-pages: typographic only, no photo) */

.hero-sub {
  background: var(--surface);
  border-bottom: 3px solid var(--accent);
  padding: 3.5rem 0 3rem;
}

.hero-sub .breadcrumbs { margin-bottom: 1rem; }

.hero-sub h1 {
  font-family: var(--display);
  font-weight: 700;
  font-size: clamp(2.2rem, 5vw, 3.5rem);
  line-height: 1.08;
  letter-spacing: -0.02em;
  color: var(--text);
  margin: 0 0 1rem;
  max-width: 22ch;
}

.hero-sub .lede {
  font-size: 1.05rem;
  color: var(--muted);
  max-width: 55ch;
  margin: 0;
}

/* ---------- Buttons: 0px radius ---------- */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: var(--accent-2);
  color: var(--text);
  font-family: var(--body);
  font-weight: 600;
  font-size: 0.95rem;
  text-decoration: none;
  padding: 0.8rem 1.6rem;
  min-height: 44px;
  border-radius: 0;
  border: none;
  transition: background 0.12s ease;
}

.btn:hover { background: #c97c08; color: var(--text); }

.btn-ghost {
  background: transparent;
  color: var(--accent);
  border: 2px solid var(--accent);
}

.btn-ghost:hover { background: var(--accent); color: var(--surface); }

.btn-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-top: 0.25rem;
}

/* ---------- Main content ---------- */

main { padding: 4rem 0 1rem; }

@media (min-width: 768px) {
  main { padding: 5rem 0 2rem; }
}

/* ---------- Data call-out blocks (replacing stat strips) ---------- */

.data-callout {
  width: 100vw;
  position: relative;
  left: 50%;
  right: 50%;
  margin-left: -50vw;
  margin-right: -50vw;
  background: var(--surface);
  border-left: 3px solid var(--accent-2);
  padding: 3rem 0;
  margin-top: 3rem;
  margin-bottom: 3rem;
}

.data-callout-inner {
  width: min(72rem, 100% - 2.5rem);
  margin-inline: auto;
  display: flex;
  align-items: baseline;
  gap: 1.25rem;
  flex-wrap: wrap;
}

.data-callout-stat {
  font-family: var(--display);
  font-weight: 700;
  font-size: clamp(4.5rem, 10vw, 8rem);
  line-height: 0.95;
  letter-spacing: -0.03em;
  color: var(--text);
}

.data-callout-label {
  font-family: var(--body);
  font-size: 1rem;
  font-weight: 500;
  color: var(--muted);
  max-width: 28ch;
  line-height: 1.5;
}

/* ---------- Spec-sheet tables (the primary content vehicle) ---------- */

.spec-wrap {
  overflow-x: auto;
  margin: 1.5rem 0 2.5rem;
}

table.spec {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.97rem;
  background: var(--surface);
  border: 1px solid var(--border);
}

table.spec th,
table.spec td {
  padding: 0.8rem 1rem;
  text-align: left;
  border-bottom: 1px solid var(--border);
  vertical-align: top;
}

table.spec th {
  font-weight: 500;
  font-size: 0.82rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--muted);
  width: 38%;
  white-space: nowrap;
}

table.spec td {
  font-weight: 600;
  color: var(--text);
  text-align: right;
  font-size: 1.05rem;
}

table.spec tr:last-child th,
table.spec tr:last-child td {
  border-bottom: none;
}

table.spec thead tr {
  background: var(--bg);
  border-bottom: 2px solid var(--border);
}

table.spec thead th {
  font-weight: 600;
  font-size: 0.85rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--accent);
  text-align: left;
}

table.spec thead th:last-child {
  text-align: right;
}

/* Comparison tables: three-column */
.compare-wrap { overflow-x: auto; margin: 1.5rem 0 2.5rem; }

table.compare {
  width: 100%;
  min-width: 500px;
  border-collapse: collapse;
  font-size: 0.95rem;
  background: var(--surface);
  border: 1px solid var(--border);
}

table.compare th,
table.compare td {
  padding: 0.8rem 1rem;
  text-align: left;
  border-bottom: 1px solid var(--border);
  vertical-align: top;
}

table.compare thead th {
  font-weight: 600;
  font-size: 0.82rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--accent);
  background: var(--bg);
  border-bottom: 2px solid var(--accent);
}

table.compare tbody th {
  color: var(--muted);
  font-weight: 500;
  font-size: 0.82rem;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  width: 28%;
}

table.compare tbody td { font-weight: 400; }

table.compare tr:last-child td,
table.compare tr:last-child th {
  border-bottom: none;
}

/* ---------- Photo figures ---------- */

.photo-figure {
  width: 100vw;
  position: relative;
  left: 50%;
  right: 50%;
  margin-left: -50vw;
  margin-right: -50vw;
  margin-top: 3rem;
  margin-bottom: 3rem;
}

.photo-figure img {
  width: 100%;
  height: auto;
  display: block;
  border-radius: 0;
}

.photo-figure figcaption {
  font-size: 0.84rem;
  color: var(--muted);
  margin-top: 0.6rem;
  line-height: 1.5;
  padding: 0 1.25rem;
}

@media (min-width: 768px) {
  .photo-figure figcaption {
    width: min(72rem, 100% - 2.5rem);
    margin-inline: auto;
    padding: 0;
  }
}

/* Contained figure (inside body column) */
.photo-figure-contained {
  margin: 2rem 0;
}

.photo-figure-contained img {
  width: 100%;
  height: auto;
  display: block;
  border-radius: 0;
  border: 1px solid var(--border);
}

.photo-figure-contained figcaption {
  font-size: 0.84rem;
  color: var(--muted);
  margin-top: 0.5rem;
  line-height: 1.5;
}

/* ---------- CTA band (booking) ---------- */

.cta-band {
  background: var(--surface);
  border: 1px solid var(--border);
  border-top: 3px solid var(--accent);
  padding: 2.25rem 1.75rem;
  margin: 3.5rem 0;
}

.cta-band h2,
.cta-band h3 {
  margin: 0 0 0.6rem;
  color: var(--accent);
  font-family: var(--body);
  font-weight: 600;
  border-top: none;
  padding-top: 0;
}

.cta-band p {
  color: var(--muted);
  max-width: 52ch;
  margin-bottom: 1.25rem;
}

.cta-band .btn { margin-top: 0; }

/* Full-bleed CTA (final CTA on some pages) */
.cta-band-full {
  width: 100vw;
  position: relative;
  left: 50%;
  right: 50%;
  margin-left: -50vw;
  margin-right: -50vw;
  background: var(--surface);
  border-top: 1px solid var(--border);
  padding: 3rem 0;
  margin-top: 4rem;
  margin-bottom: 0;
}

.cta-band-full-inner {
  width: min(65ch, 100% - 2.5rem);
  margin-inline: auto;
}

.cta-band-full h2 {
  font-family: var(--body);
  font-weight: 600;
  color: var(--accent);
  margin: 0 0 0.75rem;
  border-top: none;
  padding-top: 0;
}

.cta-band-full p {
  color: var(--muted);
  margin-bottom: 1.25rem;
}

/* ---------- Pull quote ---------- */

.pull-quote {
  border-left: 3px solid var(--accent);
  padding: 0.5rem 0 0.5rem 1.5rem;
  margin: 2.5rem 0;
}

.pull-quote blockquote {
  margin: 0;
  font-family: var(--display);
  font-style: italic;
  font-size: clamp(1.2rem, 2.5vw, 1.5rem);
  color: var(--text);
  line-height: 1.45;
}

/* ---------- Note / callout box ---------- */

.note {
  border-left: 3px solid var(--accent);
  background: var(--bg);
  padding: 1rem 1.25rem;
  margin: 1.75rem 0;
  font-size: 0.97rem;
}

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

/* ---------- Season headings ---------- */

.season {
  font-size: 1rem;
  font-weight: 600;
  color: var(--accent);
  margin: 2rem 0 0.4rem;
  text-transform: none;
  letter-spacing: 0;
}

/* ---------- FAQ: Cormorant italic question, Outfit answer ---------- */

details.faq {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 0;
  padding: 0;
  margin-bottom: 1px;
  overflow: hidden;
}

details.faq summary {
  cursor: pointer;
  list-style: none;
  font-family: var(--display);
  font-style: italic;
  font-weight: 600;
  font-size: 1.1rem;
  color: var(--text);
  padding: 1rem 3rem 1rem 1.25rem;
  position: relative;
  min-height: 44px;
  display: flex;
  align-items: center;
  background: var(--surface);
  transition: background 0.1s;
}

details.faq summary::-webkit-details-marker { display: none; }

details.faq summary::after {
  content: "+";
  position: absolute;
  right: 1.25rem;
  top: 50%;
  transform: translateY(-50%);
  color: var(--accent);
  font-size: 1.4rem;
  font-family: var(--body);
  font-style: normal;
  font-weight: 400;
}

details.faq[open] summary::after { content: "\2212"; }

details.faq[open] summary { background: var(--bg); }

details.faq .answer {
  padding: 0 1.25rem 1.15rem;
  color: var(--text);
  font-family: var(--body);
  font-style: normal;
  font-size: 0.97rem;
  line-height: 1.7;
  border-top: 1px solid var(--border);
}

details.faq .answer p:last-child { margin-bottom: 0; }

/* ---------- Breadcrumbs ---------- */

.breadcrumbs {
  font-size: 0.82rem;
  color: var(--muted);
  margin: 0 0 1rem;
  padding: 0;
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 0.3rem;
}

.breadcrumbs li { margin: 0; }
.breadcrumbs li + li::before { content: "/"; margin-right: 0.3rem; color: var(--border); }
.breadcrumbs a { color: var(--muted); text-decoration: none; }
.breadcrumbs a:hover { color: var(--accent); }

/* ---------- Footer ---------- */

.site-footer {
  margin-top: 5rem;
  border-top: 3px solid var(--accent);
  background: var(--surface);
  padding: 3rem 0 2rem;
  font-size: 0.93rem;
  color: var(--muted);
}

.footer-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 2rem;
}

.site-footer h2 {
  font-family: var(--body);
  font-size: 0.82rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--accent);
  margin: 0 0 0.75rem;
  border-top: none;
  padding-top: 0;
}

.site-footer ul { list-style: none; padding: 0; margin: 0; }
.site-footer li { margin-bottom: 0.4rem; }
.site-footer a { color: var(--muted); text-decoration: none; }
.site-footer a:hover { color: var(--accent); }
.site-footer p { max-width: none; }

.footer-note {
  margin-top: 2rem;
  padding-top: 1.25rem;
  border-top: 1px solid var(--border);
  font-size: 0.82rem;
  color: var(--muted);
  display: flex;
  align-items: flex-start;
  gap: 1rem;
}

.footer-note img {
  width: 36px;
  height: auto;
  flex-shrink: 0;
  opacity: 0.7;
}

.footer-note p { margin: 0; }

/* ---------- Responsive ---------- */

@media (max-width: 768px) {
  .nav-toggle {
    display: inline-flex;
  }

  .nav-links {
    display: none;
    width: 100%;
    flex-direction: column;
    gap: 0;
    padding: 0.5rem 0 0.75rem;
  }

  .site-nav.open .nav-links {
    display: flex;
    flex-direction: column;
  }

  .nav-links a {
    padding: 0.65rem 0;
    border-bottom: 1px solid var(--border);
    min-height: 44px;
    width: 100%;
    border-right: none;
  }

  .nav-links a[aria-current="page"] { border-bottom-color: var(--border); }

  .nav-cta {
    border-bottom: none !important;
    margin-top: 0.4rem;
    width: 100%;
    justify-content: center;
  }

  .nav-inner { flex-wrap: wrap; }

  /* Hero stacks photo-first on mobile */
  .hero-split {
    grid-template-columns: 1fr;
    min-height: auto;
  }

  .hero-photo {
    order: -1;
    border-left: none;
    border-bottom: 6px solid var(--accent);
    height: 55vw;
    min-height: 220px;
    max-height: 380px;
  }

  .hero-text {
    padding: 2.5rem 0 2rem;
  }

  .hero-text .container {
    max-width: 100%;
    padding-right: 0;
    margin: 0;
  }

  .btn-row {
    flex-direction: column;
    gap: 0.6rem;
  }

  .btn-row .btn { width: 100%; text-align: center; }

  .cta-band .btn { width: 100%; }

  .footer-note { flex-direction: column; align-items: flex-start; }

  .data-callout { padding: 2rem 0; }
  .data-callout-stat { font-size: clamp(3.5rem, 16vw, 6rem); }
}

@media (min-width: 640px) {
  .footer-grid { grid-template-columns: 2fr 1fr 1fr; }
}

@media (min-width: 900px) {
  .hero-split {
    grid-template-columns: 1fr 1fr;
    min-height: 560px;
  }
}

@media (min-width: 1100px) {
  .hero-split { min-height: 620px; }
}

/* ---------- Scroll reveal (subtle, progressive enhancement) ---------- */

@supports (animation-timeline: scroll()) {
  @media (prefers-reduced-motion: no-preference) {
    .data-callout {
      animation: fade-up linear both;
      animation-timeline: view();
      animation-range: entry 0% entry 30%;
    }
  }
}

@keyframes fade-up {
  from { opacity: 0; transform: translateY(16px); }
  to   { opacity: 1; transform: translateY(0); }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    transition-duration: 0.01ms !important;
  }
}
