/* ============================================================
   HRV Book landing page styles
   ------------------------------------------------------------
   Paste this whole file into:
   Appearance -> Customize -> Additional CSS
   (or Jetpack -> Custom CSS if that is what your theme uses)

   Do not paste this into the Custom HTML block on the page.
   That block only needs hrv-book-content.html.
   ============================================================ */

@import url('https://fonts.googleapis.com/css2?family=Fraunces:ital,opsz,wght@0,9..144,400;0,9..144,500;0,9..144,600;1,9..144,400;1,9..144,500&family=Source+Sans+3:wght@400;500;600;700&display=swap');

/* ===== Token system =====
     bg / surface / surface-2 : ground for the page
     text / text-dim          : reading colors
     fight / rest             : the book's two nervous-system accents
     rule                     : hairline dividers
  */
  :root{
    --bg: #FFFFFF;
    --surface: #F7F5F1;
    --surface-2: #EFECE4;
    --text: #1C2530;
    --text-dim: #5B6570;
    --fight: #C7701E;
    --rest: #24796C;
    --rule: #E2E0D8;
    --maxw: 1120px;
  }

  *{ box-sizing:border-box; }
  html{ scroll-behavior:smooth; }
  body{
    margin:0;
    background:var(--bg);
    color:var(--text);
    font-family:'Source Sans 3', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    font-size:17px;
    line-height:1.65;
    -webkit-font-smoothing:antialiased;
  }
  h1,h2,h3{
    font-family:'Fraunces', Georgia, serif;
    font-weight:500;
    line-height:1.15;
    margin:0 0 0.5em 0;
    letter-spacing:-0.01em;
  }
  p{ margin:0 0 1em 0; }
  a{ color:inherit; }
  img,svg{ display:block; max-width:100%; }

  .wrap{
    max-width:var(--maxw);
    margin:0 auto;
    padding:0 28px;
  }

  a.button:focus-visible,
  a.link-cta:focus-visible,
  button:focus-visible{
    outline:2px solid var(--rest);
    outline-offset:3px;
  }

  /* ===== Hero ===== */
  .hero{
    padding:88px 0 40px;
    position:relative;
  }
  .hero .eyebrow{
    font-size:0.82rem;
    letter-spacing:0.14em;
    text-transform:uppercase;
    color:var(--text-dim);
    margin-bottom:22px;
  }
  .hero h1{
    font-size:clamp(2.1rem, 4.6vw, 3.4rem);
    max-width:16ch;
    color:var(--text);
  }
  .hero h1 em{
    font-style:italic;
    color:var(--rest);
  }
  .hero .sub{
    max-width:56ch;
    font-size:1.1rem;
    color:var(--text-dim);
    margin-top:20px;
  }
  .hero .cta-row{
    display:flex;
    gap:16px;
    margin-top:34px;
    flex-wrap:wrap;
  }
  .button{
    display:inline-block;
    text-decoration:none;
    padding:14px 30px;
    border-radius:2px;
    font-size:0.98rem;
    font-weight:600;
    transition:transform .18s ease, box-shadow .18s ease;
  }
  .button.primary{
    background:var(--rest);
    color:#FFFFFF;
  }
  .button.primary:hover{ transform:translateY(-1px); box-shadow:0 8px 24px rgba(79,166,154,0.25); }
  .button.ghost{
    border:1px solid var(--rule);
    color:var(--text);
  }
  .button.ghost:hover{ border-color:var(--text-dim); }

  /* ===== Waveform signature ===== */
  .waveform{
    margin-top:60px;
    padding:34px 0 6px;
  }
  .waveform .caption{
    display:flex;
    justify-content:space-between;
    font-size:0.78rem;
    letter-spacing:0.08em;
    text-transform:uppercase;
    color:var(--text-dim);
    margin-top:14px;
  }
  .waveform .caption span:first-child{ color:var(--fight); }
  .waveform .caption span:last-child{ color:var(--rest); }
  #wave-jagged{
    stroke:var(--fight);
    fill:none;
    stroke-width:2;
    opacity:1;
    transition:opacity 1.1s ease;
  }
  #wave-smooth{
    stroke:var(--rest);
    fill:none;
    stroke-width:2;
    opacity:0;
    transition:opacity 1.1s ease;
  }
  .waveform.regulated #wave-jagged{ opacity:0.18; }
  .waveform.regulated #wave-smooth{ opacity:1; }

  /* ===== Section shell ===== */
  section{ padding:76px 0; border-bottom:1px solid var(--rule); }
  section:last-of-type{ border-bottom:none; }
  .kicker{
    font-size:0.82rem;
    letter-spacing:0.14em;
    text-transform:uppercase;
    color:var(--rest);
    margin-bottom:14px;
  }
  section h2{
    font-size:clamp(1.7rem, 3.2vw, 2.3rem);
    max-width:20ch;
  }
  section .lede{
    max-width:64ch;
    color:var(--text-dim);
    font-size:1.05rem;
    margin-top:16px;
  }

  /* ===== Idea section (two columns) ===== */
  .idea-grid{
    display:grid;
    grid-template-columns:1fr 1fr;
    gap:40px;
    margin-top:44px;
  }
  .idea-card{
    background:var(--surface);
    border:1px solid var(--rule);
    border-top:3px solid var(--fight);
    padding:30px 28px;
  }
  .idea-card.rest{ border-top-color:var(--rest); }
  .idea-card h3{ font-size:1.25rem; margin-bottom:12px; }
  .idea-card h3 .tag{
    display:block;
    font-family:'Source Sans 3', sans-serif;
    font-size:0.78rem;
    letter-spacing:0.1em;
    text-transform:uppercase;
    color:var(--text-dim);
    margin-bottom:8px;
    font-weight:600;
  }
  .idea-card p{ color:var(--text-dim); font-size:0.98rem; }

  /* ===== Three readers ===== */
  .reader-grid{
    display:grid;
    grid-template-columns:repeat(3,1fr);
    gap:1px;
    background:var(--rule);
    margin-top:44px;
    border:1px solid var(--rule);
  }
  .reader-card{
    background:var(--surface);
    padding:32px 26px;
  }
  .reader-card .num{
    font-family:'Fraunces', serif;
    font-size:0.9rem;
    color:var(--text-dim);
    margin-bottom:18px;
  }
  .reader-card h3{ font-size:1.15rem; margin-bottom:10px; }
  .reader-card p{ color:var(--text-dim); font-size:0.95rem; margin:0; }

  /* ===== TOC / parts ===== */
  .parts{
    margin-top:44px;
    display:flex;
    flex-direction:column;
  }
  .part-row{
    display:grid;
    grid-template-columns:120px 1fr;
    gap:24px;
    padding:24px 0;
    border-top:1px solid var(--rule);
    align-items:baseline;
  }
  .parts .part-row:last-child{ border-bottom:1px solid var(--rule); }
  .part-row .part-label{
    font-family:'Fraunces', serif;
    font-style:italic;
    color:var(--text-dim);
    font-size:0.95rem;
  }
  .part-row h3{ font-size:1.08rem; margin-bottom:6px; color:var(--text); }
  .part-row p{ color:var(--text-dim); font-size:0.93rem; margin:0; }

  /* ===== About ===== */
  .about{
    display:grid;
    grid-template-columns:220px 1fr;
    gap:48px;
    margin-top:44px;
    align-items:start;
  }
  .about-portrait{
    width:100%;
    aspect-ratio:3/4;
    border:1px solid var(--rule);
    overflow:hidden;
  }
  .about-portrait img{
    width:100%;
    height:100%;
    object-fit:cover;
    display:block;
    filter:saturate(0.9);
  }
  .about p{ color:var(--text-dim); }
  .about .signature{
    font-family:'Fraunces', serif;
    font-style:italic;
    color:var(--text);
    font-size:1.1rem;
    margin-top:20px;
  }

  /* ===== Mission strip ===== */
  .mission{
    padding:70px 0;
    text-align:center;
    border-bottom:1px solid var(--rule);
  }
  .mission blockquote{
    margin:0 auto;
    max-width:52ch;
    font-family:'Fraunces', serif;
    font-style:italic;
    font-size:clamp(1.3rem,2.6vw,1.7rem);
    color:var(--text);
    line-height:1.4;
  }
  .mission cite{
    display:block;
    margin-top:20px;
    font-family:'Source Sans 3', sans-serif;
    font-style:normal;
    font-size:0.85rem;
    letter-spacing:0.08em;
    text-transform:uppercase;
    color:var(--text-dim);
  }

  /* ===== Final CTA ===== */
  .final-cta{
    text-align:center;
    padding:90px 0 100px;
  }
  .final-cta h2{ margin:0 auto 16px; max-width:18ch; }
  .final-cta .lede{ margin-left:auto; margin-right:auto; }
  .final-cta .cta-row{
    justify-content:center;
    margin-top:34px;
  }

  /* ===== Footer ===== */
  footer{
    padding:36px 0;
  }
  footer .wrap{
    display:flex;
    justify-content:space-between;
    align-items:center;
    flex-wrap:wrap;
    gap:12px;
    font-size:0.85rem;
    color:var(--text-dim);
  }
  footer a{ text-decoration:none; color:var(--text-dim); }
  footer a:hover{ color:var(--text); }

  @media (max-width:820px){
    .idea-grid{ grid-template-columns:1fr; }
    .reader-grid{ grid-template-columns:1fr; }
    .about{ grid-template-columns:1fr; }
    .about-portrait{ max-width:220px; }
    .part-row{ grid-template-columns:1fr; gap:6px; }
  }

  @media (prefers-reduced-motion: reduce){
    html{ scroll-behavior:auto; }
    #wave-jagged, #wave-smooth, .button{ transition:none; }
  }