/* GLP-1 Collective — design tokens.
   Healthcare-adjacent: teal primary, cool near-white grounds, one humanist
   sans throughout, softened radii. Deliberately shares nothing with the
   GLP-1 Studio network (no warm cream, no amber, no display serif). */
:root {
  --white:   #FFFFFF;
  --mist:    #F5FAF9;   /* page tint  */
  --tint:    #E6F2F0;   /* band       */
  --tint-2:  #D3E9E5;
  --rule:    #D8E6E4;
  --rule-2:  #EBF3F2;

  --teal:    #0E7C74;   /* primary    */
  --teal-d:  #0A5C56;   /* hover/deep */
  --teal-l:  #35A79C;
  --teal-xl: #7FC9C1;

  --ink:     #0F1F1E;
  --body:    #35504D;
  --mid:     #567270;
  --quiet:   #7C9491;
  --faint:   #A9BFBD;
  --warn:    #B4442F;

  /* Accent. Used sparingly to break up long reading: rules, numbered markers,
     one word in a heading. Never as a background behind body text, and never
     as a text color on white below 16px. */
  --pink:    #C81D6B;
  --pink-l:  #FBEAF2;
  --pink-xl: #FDF4F8;

  /* ONE content width, used by every block on every page. Nothing on this
     site is narrower than this or centred inside it — headings, prose, cards,
     tables and the tool pages all start and end on the same two edges. */
  --wrap:    1180px;
  --radius:  8px;
  --radius-s: 6px;
  --shadow:  0 1px 2px rgba(15,31,30,.04), 0 8px 24px rgba(15,31,30,.05);
  --shadow-h: 0 2px 4px rgba(15,31,30,.06), 0 12px 32px rgba(15,31,30,.09);
}
* { box-sizing: border-box; margin: 0; padding: 0; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  background: var(--white);
  color: var(--body);
  font-family: 'Public Sans', system-ui, -apple-system, 'Segoe UI', sans-serif;
  font-size: 17px;
  /* the full-width measure is long, so it gets more leading to stay readable */
  line-height: 1.75;
  -webkit-font-smoothing: antialiased;
}
.wrap { max-width: var(--wrap); margin: 0 auto; padding: 0 24px; }
h1, h2, h3, h4 { color: var(--ink); font-weight: 700; line-height: 1.15; letter-spacing: -0.021em; }
h1 { font-size: clamp(36px, 5.4vw, 60px); letter-spacing: -0.032em; }
h2 { font-size: clamp(25px, 3.2vw, 35px); letter-spacing: -0.026em; }
h3 { font-size: clamp(18px, 1.9vw, 21px); letter-spacing: -0.014em; font-weight: 600; }
a { color: var(--teal-d); text-underline-offset: 3px; text-decoration-thickness: 1px; }
a:hover { color: var(--teal); }
.eyebrow {
  font-size: 12px; text-transform: uppercase; letter-spacing: 0.11em;
  font-weight: 700; color: var(--teal);
}

/* ---- header ---- */
.masthead { border-bottom: 1px solid var(--rule); background: rgba(255,255,255,.94);
  backdrop-filter: saturate(1.4) blur(8px); position: sticky; top: 0; z-index: 50; }
.masthead .wrap { display: flex; align-items: center; gap: 28px; height: 72px; }
.brand { display: flex; align-items: center; gap: 9px; font-weight: 700; font-size: 17px;
  letter-spacing: -0.028em; color: var(--ink); text-decoration: none; white-space: nowrap; }
.brand .mark { width: 26px; height: 26px; border-radius: 7px; background: var(--teal);
  display: grid; place-items: center; color: #fff; font-size: 13px; font-weight: 700;
  letter-spacing: -0.04em; flex: none; }
.nav { display: flex; gap: 24px; margin-left: auto; align-items: center; flex-wrap: wrap; }
.nav a { font-size: 15px; color: var(--mid); text-decoration: none; font-weight: 500; }
.nav a:hover, .nav a[aria-current="page"] { color: var(--teal-d); }
.btn {
  display: inline-block; background: var(--teal); color: #fff;
  padding: 11px 20px; border-radius: var(--radius-s); font-weight: 600;
  font-size: 15px; text-decoration: none; border: 1px solid var(--teal);
  transition: background .15s ease, border-color .15s ease;
}
.btn:hover { background: var(--teal-d); border-color: var(--teal-d); color: #fff; }
.btn-ghost { background: transparent; border-color: var(--tint-2); color: var(--teal-d); }
.btn-ghost:hover { background: var(--tint); border-color: var(--teal-xl); color: var(--teal-d); }
.navtoggle { display: none; }

/* ---- sections ---- */
/* padding-block, never the shorthand: these classes share an element with
   .wrap, and `padding: X 0` would zero its side gutter. */
.hero { padding-block: 88px 66px; }
.hero p.lede { font-size: 21px; color: var(--mid); margin-top: 20px; line-height: 1.55; }
.band { background: var(--mist); border-block: 1px solid var(--rule); }
.sec { padding-block: 68px; }
.rule { border: 0; border-top: 1px solid var(--rule); margin: 0; }
.grid { display: grid; gap: 18px; }
.g2 { grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); }
.g3 { grid-template-columns: repeat(auto-fit, minmax(258px, 1fr)); }
.card {
  border: 1px solid var(--rule); border-radius: var(--radius);
  padding: 26px; background: var(--white); text-decoration: none; display: block;
  box-shadow: var(--shadow); transition: box-shadow .16s ease, border-color .16s ease, transform .16s ease;
}
a.card:hover { border-color: var(--teal-xl); box-shadow: var(--shadow-h); transform: translateY(-2px); }
.card h3 { margin-bottom: 8px; }
.card p { font-size: 15.5px; color: var(--mid); margin: 0; }
.stack > * + * { margin-top: 18px; }
/* .prose sets rhythm only — width comes from .wrap, like everything else */
.prose h2 { margin: 44px 0 14px; }
.prose h3 { margin: 32px 0 10px; }
.prose p, .prose ul, .prose ol { margin-bottom: 18px; }
.prose ul, .prose ol { padding-left: 22px; }
.prose li { margin-bottom: 8px; }
.prose table th { color: var(--ink); font-weight: 600; }

/* ---- attribution credit line ---- */
.credit {
  margin-top: 30px; padding: 18px 20px; background: var(--mist);
  border: 1px solid var(--rule); border-left: 3px solid var(--teal-l);
  border-radius: var(--radius-s);
  font-size: 14px; color: var(--mid); line-height: 1.6;
}
.credit strong { color: var(--ink); }

/* ---- footer ---- */
.foot { border-top: 1px solid var(--rule); margin-top: 76px; background: var(--mist); }
.foot-med {
  background: var(--tint); border-bottom: 1px solid var(--rule);
  padding: 20px 0; font-size: 14.5px; color: var(--body); line-height: 1.6;
}
.foot-med strong { color: var(--ink); }
.foot-main { padding: 46px 0 26px; display: grid; gap: 32px;
  grid-template-columns: repeat(auto-fit, minmax(185px, 1fr)); }
.foot h4 { font-size: 12px; text-transform: uppercase; letter-spacing: 0.1em;
  color: var(--teal); margin-bottom: 13px; font-weight: 700; }
.foot ul { list-style: none; }
.foot li { margin-bottom: 9px; }
.foot a { font-size: 15px; color: var(--mid); text-decoration: none; }
.foot a:hover { color: var(--teal-d); }
.foot-legal { padding: 22px 0 44px; border-top: 1px solid var(--rule);
  font-size: 13.5px; color: var(--quiet); }
.foot-legal p { max-width: none; margin-bottom: 9px; }

@media (max-width: 780px) {
  .nav { display: none; }
  .nav.open { display: flex; position: absolute; top: 72px; left: 0; right: 0;
    background: var(--white); border-bottom: 1px solid var(--rule); flex-direction: column;
    align-items: flex-start; padding: 18px 24px; gap: 15px; box-shadow: var(--shadow); }
  .navtoggle { display: block; margin-left: auto; background: none; border: 1px solid var(--rule);
    border-radius: var(--radius-s); padding: 8px 12px; font: inherit; font-size: 14px;
    color: var(--body); cursor: pointer; }
  .hero { padding-block: 58px 46px; }
  .sec { padding-block: 52px; }
}

/* nav-button contrast: .nav a out-specifies .btn, so restate it */
.nav a.btn { color: #fff; }
.nav a.btn:hover { color: #fff; }

/* paragraph rhythm outside .prose */
.hero p + p, section p + p { margin-top: 15px; }

/* ---- nav dropdown (Approved Uses) ---- */
.hassub { position: relative; display: inline-flex; align-items: center; }
.submenu {
  position: absolute; top: 100%; left: -14px; min-width: 232px; display: none;
  flex-direction: column; padding: 8px; gap: 2px; background: var(--white);
  border: 1px solid var(--rule); border-radius: var(--radius);
  box-shadow: var(--shadow-h); z-index: 60;
}
.hassub:hover .submenu, .hassub:focus-within .submenu { display: flex; }
.submenu a { padding: 9px 12px; border-radius: var(--radius-s); font-size: 15px;
  color: var(--body); white-space: nowrap; }
.submenu a:hover, .submenu a[aria-current="page"] { background: var(--tint); color: var(--teal-d); }
@media (max-width: 780px) {
  /* no hover on touch: the submenu is always open inside the drawer */
  .hassub { display: block; width: 100%; }
  .submenu { position: static; display: flex; border: 0; box-shadow: none;
    padding: 8px 0 0 14px; background: transparent; }
}

/* ---- a tool embedded in a page ---- */
.toolframe { margin: 0; }
.toolframe iframe {
  width: 100%; border: 1px solid var(--rule); border-radius: var(--radius);
  background: var(--white); display: block; transition: height .18s ease;
}
.toolframe-note {
  margin-top: 12px; font-size: 14px; color: var(--quiet); line-height: 1.6;
}


/* ================= reading rhythm =================
   Long educational pages were an undifferentiated wall of text. These give a
   page structure a reader can see: alternating section grounds, a marked lead
   paragraph, numbered steps, and callouts. Used sparingly on purpose. */

/* alternating grounds, so consecutive sections never share a background */
.band-2 { background: var(--pink-xl); border-block: 1px solid var(--rule-2); }
.band-3 { background: var(--tint); border-block: 1px solid var(--rule); }

/* section eyebrow with a short accent rule above it */
.marked { position: relative; padding-top: 26px; }
.marked::before {
  content: ""; position: absolute; top: 0; left: 0;
  width: 54px; height: 4px; border-radius: 2px; background: var(--pink);
}

/* the first paragraph of a section, set larger so the eye has an entry point */
.standfirst { font-size: 20px; line-height: 1.6; color: var(--body); }

/* numbered steps in teal circles */
.steps { list-style: none; padding: 0; counter-reset: step; display: grid; gap: 20px; }
.steps > li {
  counter-increment: step; position: relative; padding-left: 58px; margin: 0;
}
.steps > li::before {
  content: counter(step); position: absolute; left: 0; top: -2px;
  width: 38px; height: 38px; border-radius: 50%; background: var(--teal);
  color: #fff; font-weight: 700; font-size: 16px; display: grid; place-items: center;
  font-variant-numeric: tabular-nums;
}
.steps > li strong { color: var(--ink); display: block; margin-bottom: 3px; }

/* a callout that is not the disclosure box */
.note {
  padding: 22px 24px; border-radius: var(--radius); background: var(--tint);
  border-left: 4px solid var(--teal); margin: 26px 0;
}
.note.note-pink { background: var(--pink-l); border-left-color: var(--pink); }
.note p:last-child { margin-bottom: 0; }
.note h3 { margin-bottom: 8px; }

/* key figure, for a number worth stopping on */
.figure { display: flex; align-items: baseline; gap: 14px; margin: 4px 0 10px; }
.figure b { font-size: 42px; line-height: 1; color: var(--teal); letter-spacing: -0.03em;
  font-variant-numeric: tabular-nums; }
.figure span { font-size: 16px; color: var(--mid); }

/* cards pick up a teal edge on hover; non-link cards get it too */
.card { border-top: 3px solid transparent; }
a.card:hover { border-top-color: var(--teal); }

/* pull the accent into headings without shouting */
h2 em, h3 em { font-style: normal; color: var(--teal); }

/* ---- a tool in a dialog ---- */
.tooldialog {
  width: min(980px, 94vw); max-height: 90vh; padding: 0; border: 0; margin: auto;
  border-radius: var(--radius); box-shadow: var(--shadow-h);
  background: var(--white); overflow: hidden;
}
.tooldialog::backdrop { background: rgba(15, 31, 30, .55); }
.tooldialog-bar {
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  padding: 15px 20px; border-bottom: 1px solid var(--rule); background: var(--mist);
  position: sticky; top: 0;
}
.tooldialog-bar strong { color: var(--ink); font-size: 16px; }
.tooldialog-close {
  background: none; border: 1px solid var(--rule); border-radius: var(--radius-s);
  width: 34px; height: 34px; font-size: 21px; line-height: 1; color: var(--mid);
  cursor: pointer; flex: none;
}
.tooldialog-close:hover { background: var(--tint); color: var(--teal-d); border-color: var(--teal-xl); }
.tooldialog iframe { width: 100%; border: 0; display: block; max-height: calc(90vh - 66px); }

/* ---- boxed reading ----
   Long explanations become a small number of bordered blocks rather than one
   continuous column of paragraphs, so a reader can see where one idea ends. */
.blocks { display: grid; gap: 16px; margin: 26px 0; }
.blocks.two { grid-template-columns: repeat(auto-fit, minmax(320px, 1fr)); }
.block {
  border: 1px solid var(--rule); border-left: 4px solid var(--teal-xl);
  border-radius: var(--radius); padding: 24px 26px; background: var(--white);
  transition: border-color .16s ease, box-shadow .16s ease;
}
.block:hover { border-color: var(--teal-xl); border-left-color: var(--teal); box-shadow: var(--shadow); }
.block h3 { margin: 0 0 9px; }
.block p { margin: 0 0 12px; }
.block p:last-child { margin-bottom: 0; }
.block.alt { background: var(--mist); }
.block.pink { border-left-color: var(--pink); }
.block.pink:hover { border-left-color: var(--pink); border-color: var(--pink); }

/* a short label above a block, in the accent */
.block .tag {
  display: inline-block; font-size: 11px; text-transform: uppercase;
  letter-spacing: 0.12em; font-weight: 700; color: var(--pink);
  margin-bottom: 8px;
}
.block.alt .tag { color: var(--teal); }
