/* ============================================================
   JHeapo site styles
   Palette is variable-driven — rebrand by editing :root below.
   ============================================================ */
:root {
  --bg:        #ffffff;
  --bg-alt:    #f5f7fa;
  --ink:       #10233b;   /* near-navy text */
  --ink-soft:  #4b5c72;
  --line:      #e2e8f0;

  --brand:     #0e7c86;   /* deep teal — "hippo water" */
  --brand-ink: #0a5a62;
  --brand-2:   #12a3b0;
  --accent:    #f2a900;   /* warm counterpoint for the hero band */

  --hero-bg-1: #0b2b33;
  --hero-bg-2: #103f49;

  --radius:    14px;
  --wrap:      1120px;
  --shadow:    0 10px 30px rgba(16, 35, 59, .08);
  --shadow-lg: 0 24px 60px rgba(16, 35, 59, .14);
  --font: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  --mono: ui-monospace, SFMono-Regular, "SF Mono", Menlo, Consolas, monospace;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg:       #0c1420;
    --bg-alt:   #121d2c;
    --ink:      #e8eef6;
    --ink-soft: #a7b6c9;
    --line:     #243449;
    --brand-2:  #2ec2cf;
    --shadow:   0 10px 30px rgba(0,0,0,.35);
    --shadow-lg:0 24px 60px rgba(0,0,0,.5);
  }
}

/* ---------- reset-ish ---------- */
* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 76px; }
body {
  margin: 0;
  font-family: var(--font);
  color: var(--ink);
  background: var(--bg);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; display: block; }
a { color: var(--brand); text-decoration: none; }
a:hover { color: var(--brand-ink); }
h1, h2, h3, h4 { line-height: 1.15; margin: 0 0 .4em; letter-spacing: -.01em; }
code { font-family: var(--mono); }

.wrap { width: min(var(--wrap), 92vw); margin-inline: auto; }
.eyebrow {
  text-transform: uppercase;
  letter-spacing: .12em;
  font-size: .74rem;
  font-weight: 700;
  color: var(--brand-2);
  margin: 0 0 .6em;
}

/* ---------- buttons ---------- */
.btn {
  display: inline-block;
  padding: .8rem 1.5rem;
  border-radius: 999px;
  font-weight: 650;
  font-size: .98rem;
  transition: transform .12s ease, box-shadow .12s ease, background .12s ease;
  border: 1.5px solid transparent;
}
.btn:hover { transform: translateY(-2px); }
.btn-primary { background: var(--brand); color: #fff; box-shadow: var(--shadow); }
.btn-primary:hover { background: var(--brand-ink); color: #fff; }
.btn-ghost { border-color: rgba(255,255,255,.4); color: #fff; }
.btn-ghost:hover { background: rgba(255,255,255,.1); color: #fff; }

/* ============================================================
   Header / nav
   ============================================================ */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: color-mix(in srgb, var(--bg) 85%, transparent);
  backdrop-filter: saturate(150%) blur(10px);
  border-bottom: 1px solid var(--line);
}
.nav { display: flex; align-items: center; justify-content: space-between; height: 64px; }
.brand { display: flex; align-items: center; gap: .55rem; color: var(--ink); font-weight: 750; }
.brand:hover { color: var(--ink); }
.brand-mark { width: 30px; height: 30px; }
.brand-name { font-size: 1.15rem; letter-spacing: -.02em; }
.nav-links { display: flex; align-items: center; gap: 1.6rem; }
.nav-links a { color: var(--ink-soft); font-weight: 550; font-size: .95rem; }
.nav-links a:hover { color: var(--brand); }
.nav-gh {
  border: 1.5px solid var(--line); border-radius: 999px;
  padding: .4rem 1rem !important; color: var(--ink) !important;
}
.nav-gh:hover { border-color: var(--brand); color: var(--brand) !important; }
.nav-toggle, .nav-burger { display: none; }

/* ============================================================
   Hero
   ============================================================ */
.hero {
  background: radial-gradient(120% 140% at 80% -10%, var(--hero-bg-2), var(--hero-bg-1));
  color: #eaf4f5;
  padding: clamp(3rem, 8vw, 6.5rem) 0 0;  /* no bottom padding: hippo reaches the section edge (the "waterline") */
  overflow: hidden;
}
.hero-grid {
  display: grid; grid-template-columns: 1.15fr .85fr; gap: 2.5rem; align-items: end;
}
/* Copy floats above the waterline; the hippo's bottom meets the section's color change. */
.hero-copy { padding-bottom: clamp(2.5rem, 6vw, 5rem); }
.hero .eyebrow { color: var(--accent); }
.hero h1 {
  font-size: clamp(3rem, 7vw, 5rem);
  margin: 0;
  background: linear-gradient(90deg, #fff, #bfe9ec);
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
.hero-sub {
  font-size: clamp(1.3rem, 3vw, 1.9rem); font-weight: 600;
  color: #d7ecee; margin: .2rem 0 1.1rem;
}
.hero-lede { font-size: 1.12rem; color: #b7d3d6; max-width: 40ch; margin-bottom: 1.8rem; }
.hero-cta { display: flex; gap: .9rem; flex-wrap: wrap; }
.hero-note { margin-top: 1.4rem; font-size: .85rem; color: #8fb2b6; }
.hero-art img {
  width: 100%; max-width: 340px; margin-inline: auto;
  filter: drop-shadow(0 20px 40px rgba(0,0,0,.4));
}
/* Wide line-art hippo (3.5:1) — bigger, no heavy shadow; bottom flush with the section edge. */
.hero-art--wide img { max-width: 520px; filter: none; display: block; margin-bottom: 0; }

/* ============================================================
   Sections
   ============================================================ */
.section { padding: clamp(3.5rem, 7vw, 6rem) 0; }
.section-alt { background: var(--bg-alt); }
.section-title { font-size: clamp(1.8rem, 4vw, 2.6rem); text-align: center; }
.section-lede {
  text-align: center; color: var(--ink-soft); font-size: 1.1rem;
  max-width: 60ch; margin: 0 auto 2.8rem;
}

/* ---------- static pages (About, etc.) ---------- */
.page-body { max-width: 66ch; margin: 0 auto; }
.page-body p { color: var(--ink-soft); margin: 0 0 1.2rem; font-size: 1.08rem; line-height: 1.7; }
.page-body p strong { color: var(--ink); font-weight: 650; }
.page-body .page-cta { margin-top: 2rem; }
.about-bio { margin-top: 2.4rem; padding-top: 1.8rem; border-top: 1px solid var(--line); }

/* ---------- services ---------- */
.service-grid {
  display: grid; grid-template-columns: repeat(2, 1fr); gap: 1.6rem;
  max-width: 840px; margin: 0 auto;
}
.service-card {
  padding: 1rem 1.4rem;   /* flat — blends into the section, like the home-page cards */
  display: flex; flex-direction: column;
}
.service-card h2 { font-size: 1.45rem; margin: .1rem 0 .6rem; }
.service-card p { color: var(--ink-soft); margin: 0 0 1.6rem; line-height: 1.6; }
.service-card .btn { align-self: flex-start; margin-top: auto; }
.service-note { text-align: center; color: var(--ink-soft); font-size: .9rem; margin: 1.6rem 0 0; }
/* thin teal page-title bar */
.page-head { padding: 1.6rem 0; }
.page-head .section-title { margin: 0; }

/* ---------- products overview ---------- */
.product-grid {
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.8rem;
}
.product-card {
  text-align: center;
  padding: 1rem 1.4rem;   /* blends into the section — no card background or shadow */
}
.product-icon { width: 120px; height: 120px; object-fit: contain; display: block; margin: 0 auto .7rem; }
.product-card h3 { font-size: 1.5rem; margin: 0 0 .15rem; }       /* name, just below the icon */
.product-card .eyebrow { margin: 0 0 .7rem; }                     /* tagline, below the name */
.product-card p:last-child { color: var(--ink-soft); margin: 0; font-size: .98rem; }

/* ---------- feature grid ---------- */
.feature-grid {
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 2.6rem 2.4rem;
}
/* Flat points, no card chrome — jxray-style. */
.feature-card {
  padding: 0;
}
.feature-icon {
  display: inline-grid; place-items: center;
  width: 46px; height: 46px; border-radius: 12px;
  background: color-mix(in srgb, var(--brand) 14%, transparent);
  color: var(--brand-2); font-size: 1.4rem; margin-bottom: .9rem;
}
.feature-card h3 { font-size: 1.18rem; }
.feature-card p { color: var(--ink-soft); margin: 0; font-size: .98rem; }

/* ---------- why grid ---------- */
.why-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.4rem; }
.why-card {
  background: var(--bg); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 1.7rem; border-top: 4px solid var(--brand);
}
.why-card h3 { font-size: 1.3rem; }
.why-card p { color: var(--ink-soft); margin: 0; }
.why-kicker {
  text-align: center; max-width: 62ch; margin: 2.6rem auto 0;
  font-size: 1.1rem; color: var(--ink); font-weight: 550;
}

/* ---------- jscrub ---------- */
.jscrub-mark { display: block; width: 132px; height: auto; margin: 0 auto 1rem; }
.jheapo-mark { display: block; width: 210px; height: auto; margin: 0 auto 1.1rem; }

/* ---------- jscrub flow ---------- */
.jscrub-flow {
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 2.6rem 2.4rem;
}
.jscrub-flow.two-up { grid-template-columns: repeat(2, 1fr); max-width: 760px; margin-inline: auto; }
.jscrub-step h3 { font-size: 1.25rem; margin-bottom: .35rem; }
.jscrub-step p:last-child { color: var(--ink-soft); margin: 0; }
.jscrub-cta { text-align: center; margin-top: 3rem; }

/* ---------- tour ---------- */
.tour-row {
  display: grid; grid-template-columns: 1fr 1fr; gap: 2.5rem; align-items: center;
  padding: 2.4rem 0;
}
.tour-row + .tour-row { border-top: 1px solid var(--line); }
.tour-row.right .tour-text { order: 2; }
.tour-text h3 { font-size: clamp(1.4rem, 3vw, 1.9rem); }
.ticks { list-style: none; padding: 0; margin: 1rem 0 0; }
.ticks li { position: relative; padding-left: 1.7rem; margin-bottom: .7rem; color: var(--ink-soft); }
.ticks li::before {
  content: "✓"; position: absolute; left: 0; top: 0;
  color: #fff; background: var(--brand); border-radius: 50%;
  width: 1.2rem; height: 1.2rem; font-size: .72rem;
  display: grid; place-items: center; font-weight: 700;
}
.tour-shot img {
  width: 100%; border-radius: var(--radius); border: 1px solid var(--line);
  box-shadow: var(--shadow-lg);
}

/* ---------- CTA banner (same background as the Features section) ---------- */
.cta-banner {
  background: var(--bg);
  text-align: center; padding: clamp(3rem, 6vw, 4.5rem) 0;
}

/* ---------- Tour band: the same deep teal as the hero ---------- */
.section-brand {
  background: radial-gradient(120% 140% at 80% -10%, var(--hero-bg-2), var(--hero-bg-1));
  color: #fff;
}
/* Tour text/marks made readable on the deep-teal band */
.section-brand .section-lede,
.section-brand .ticks li { color: rgba(255,255,255,.85); }
.section-brand .eyebrow { color: #d7ecee; }
.section-brand .product-card p:last-child { color: rgba(255,255,255,.82); }
.section-brand .jscrub-step p:last-child { color: rgba(255,255,255,.82); }
.section-brand .ticks li::before { background: #fff; color: var(--brand-ink); }
.section-brand .tour-row + .tour-row { border-top-color: rgba(255,255,255,.18); }
.section-brand .tour-shot img { border-color: rgba(255,255,255,.22); }
.cta-banner h2 { font-size: clamp(1.6rem, 4vw, 2.4rem); }
.cta-inner p { margin: .8rem 0 1.6rem; }
.cta-inner code {
  background: rgba(0,0,0,.25); padding: .5rem 1rem; border-radius: 8px;
  font-size: .95rem; display: inline-block;
}

/* ============================================================
   Footer
   ============================================================ */
.site-footer { background: var(--bg-alt); padding: 1.8rem 0; }
.footer-bar { display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 1rem; }
.footer-brand { display: flex; align-items: center; gap: .5rem; justify-self: start; }
.footer-brand .brand-mark { width: 26px; height: 26px; }
.footer-brand .brand-name { font-weight: 750; font-size: 1.05rem; }
.footer-copy { justify-self: center; color: var(--ink-soft); font-size: .85rem; }
.footer-top { justify-self: end; color: var(--ink-soft); font-size: .85rem; }
.footer-top:hover { color: var(--brand); }

/* ============================================================
   Responsive
   ============================================================ */
@media (max-width: 860px) {
  .hero-grid { grid-template-columns: 1fr; text-align: center; }
  .hero-lede { margin-inline: auto; }
  .hero-cta { justify-content: center; }
  .hero-art { order: 1; }              /* hippo below the copy, floating on the waterline */
  .hero-art img { max-width: 220px; }
  .feature-grid, .jscrub-flow, .jscrub-flow.two-up, .product-grid, .service-grid { grid-template-columns: 1fr; }
  .tour-row, .tour-row.right .tour-text { grid-template-columns: 1fr; order: initial; }
  .tour-row.right .tour-shot { order: -1; }
  .footer-bar { grid-template-columns: 1fr; justify-items: center; gap: .6rem; }
  .footer-brand, .footer-copy, .footer-top { justify-self: center; }

  /* mobile nav */
  .nav-burger {
    display: block; cursor: pointer; width: 26px; height: 20px; position: relative;
  }
  .nav-burger span, .nav-burger span::before, .nav-burger span::after {
    content: ""; position: absolute; left: 0; height: 2px; width: 100%;
    background: var(--ink); border-radius: 2px; transition: .2s;
  }
  .nav-burger span { top: 9px; }
  .nav-burger span::before { top: -7px; }
  .nav-burger span::after { top: 7px; }
  .nav-links {
    position: absolute; top: 64px; left: 0; right: 0;
    flex-direction: column; align-items: stretch; gap: 0;
    background: var(--bg); border-bottom: 1px solid var(--line);
    max-height: 0; overflow: hidden; transition: max-height .25s ease;
  }
  .nav-links a { padding: .9rem 6vw; border-top: 1px solid var(--line); }
  .nav-gh { margin: .8rem 6vw; text-align: center; }
  .nav-toggle:checked ~ .nav-links { max-height: 60vh; }
}

/* ============================================================
   Analytics notice — bottom card; opt-out model for GA.
   ============================================================ */
.cookie-consent {
  position: fixed;
  left: 50%;
  bottom: 1.2rem;
  transform: translateX(-50%);
  z-index: 100;
  width: calc(100% - 2rem);
  max-width: 30rem;
  background: var(--bg);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow-lg);
  padding: 1.1rem 1.2rem;
}
.cookie-consent[hidden] { display: none; }
.cookie-consent__text {
  margin: 0 0 .9rem;
  font-size: .9rem;
  line-height: 1.5;
  color: var(--ink-soft);
}
.cookie-consent__text strong { color: var(--ink); font-weight: 650; }
.cookie-consent__actions {
  display: flex;
  gap: .6rem;
  justify-content: flex-end;
}
.cookie-btn {
  padding: .5rem 1.1rem;
  border-radius: 999px;
  font: inherit;
  font-size: .88rem;
  font-weight: 650;
  cursor: pointer;
  border: 1.5px solid transparent;
  transition: background .12s ease, border-color .12s ease, color .12s ease;
}
.cookie-btn--accept { background: var(--brand); color: #fff; }
.cookie-btn--accept:hover { background: var(--brand-ink); }
.cookie-btn--decline { background: transparent; border-color: var(--line); color: var(--ink-soft); }
.cookie-btn--decline:hover { border-color: var(--ink-soft); color: var(--ink); }
