/* ===========================================================================
   Kimberly Joseph
   Built to concept 2 - Rooted Through Loss.
   Mockup: design/mockup/home-864.png (864px native, built at 1440px).

   Every value below traces to a measurement in design/SPEC.md. If a number
   here is not in SPEC.md, it is a bug - not a preference.
   =========================================================================== */

:root {
  /* --- Colour --- SPEC "Colour". Direct pixel probes; the mockup lays a paper
     texture over each flat field, so a band varies +/-6 and the token is the
     measured centre of that spread. */
  --forest:       #2B3C34;   /* (20,760) + (430,660) - specialties field   */
  --forest-deep:  #243B35;   /* (12,1671) footer, (12,64) hero panel       */
  --ivory:        #F2EEE6;   /* (430,30) header / page base                */
  --ivory-light:  #FAF7F1;   /* (12,431) intro, (12,1028) about            */
  --sage:         #DFE0D7;   /* (12,1337) Writing band                     */
  --clay:         #93553D;   /* (12,1612) CTA band, (118,363) hero button  */
  --card:         #FFFFFF;   /* (150,880) card fill                        */

  --ink:          var(--forest);
  --ink-soft:     #4A5A51;   /* body copy on ivory                         */
  --on-dark:      #F4F1EA;   /* hero + footer copy                         */
  --on-dark-soft: #C3CCC4;   /* footer secondary                           */
  --rule:         rgba(43, 60, 52, .22);

  /* --- Layout --- SPEC "Container". Two containers is a measurement:
     the header/footer rail is demonstrably wider than the content column. */
  --wrap:      1203px;   /* 1155 content (card row 693 mockup) + 2x24 pad  */
  --wrap-wide: 1365px;   /* 1317 content (header ink 790 mockup) + 2x24    */

  /* --- Type --- SPEC "Type scale". Line-height measured baseline to
     baseline across two lines, never derived from the size. */
  --serif: "EB Garamond", "Iowan Old Style", Palatino, Georgia, serif;
  --sans:  "Karla", -apple-system, "Segoe UI", system-ui, sans-serif;

  --f-h1:      65px;  --lh-h1:      72px;  /* width-match "Grief support" 212 */
  --f-h2:      46px;  --lh-h2:      52px;  /* width-match "Specialties" 112   */
  --f-h2-blk:  38px;  --lh-h2-blk:  48px;  /* width-match, both blocks = 23   */
  --f-h3:      33px;  --lh-h3:      38px;  /* width-match "Grief & Loss" 103  */
  --f-body:    21px;  --lh-body:    31px;  /* width-match intro line 380      */
  --f-card:    18px;  --lh-card:    27px;  /* "Support for navigating the many" 158 */
  --f-about:   19px;                       /* about body line 1 = 331 mockup  */
  --f-eyebrow: 18px;                       /* width-match "ABOUT KIMBERLY"113 */
  --f-nav:     20px;                       /* width-match "Home" 32           */
  --f-small:   17px;  --lh-small:   26px;  /* copyright band 1804-1812     */

  /* --- Rhythm --- SPEC "Vertical rhythm". Section top and bottom padding
     are frequently DIFFERENT - both are measured. */
  --gap-h1-body:   45px;
  --gap-body-cta:  42px;
  --gap-eyebrow:   30px;
  --gap-head-body: 22px;
  --gap-para:      18px;
  --gap-head-grid: 32px;   /* heading ink 684 -> cards 718 = 34 mockup */
  --gap-card:      20px;
  --gap-photo-ttl: 20px;

  /* --- Radii --- SPEC "Radii, borders, shadows" --- */
  --r-card: 6px;
  --r-btn:  5px;
  --r-img:  6px;
  --badge:  62px;   /* dark disc straddling the photo edge      */

  --wave: 23px;  /* wave amplitude, 14 mockup px x1.667 */
}

/* A minimal reset. Everything else belongs to the design. */
*, *::before, *::after { box-sizing: border-box; }
body { margin: 0; }
img, picture, svg, video { display: block; max-width: 100%; height: auto; }
h1, h2, h3, p, figure, blockquote { margin: 0; }
a { color: inherit; }
ul { margin: 0; padding: 0; list-style: none; }

body {
  background: var(--ivory);
  color: var(--ink);
  font-family: var(--sans);
  font-size: var(--f-body);
  line-height: var(--lh-body);
  -webkit-font-smoothing: antialiased;
}

.wrap {
  max-width: var(--wrap);
  margin-inline: auto;
  padding-inline: 24px;
}
.wrap--wide {
  max-width: var(--wrap-wide);
  margin-inline: auto;
  padding-inline: 24px;
}

h1, h2, h3, .serif { font-family: var(--serif); font-weight: 500; }

.eyebrow {
  font-family: var(--sans);
  font-size: var(--f-eyebrow);
  letter-spacing: .18em;
  text-transform: uppercase;
  color: var(--clay);
  display: flex;
  align-items: center;
  gap: 16px;
}
.eyebrow::after {
  content: ""; flex: 0 0 58px; height: 1px;
  background: currentColor; opacity: .55;
}

/* --- Buttons --- SPEC "Buttons" ------------------------------------------ */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  font-family: var(--sans);
  font-size: var(--f-nav);
  letter-spacing: .02em;
  border-radius: var(--r-btn);
  text-decoration: none;
  transition: background-color .2s ease, color .2s ease;
}
.btn--clay {                       /* hero: clay bbox 135x35 mockup */
  min-width: 225px; height: 58px;
  background: var(--clay); color: #FFF7F0;
  padding-inline: 26px;
}
.btn--clay:hover { background: #7E4632; }
.btn--forest {                     /* about: green bbox 161x30 mockup */
  min-width: 268px; height: 52px;
  background: var(--forest); color: var(--on-dark);
  padding-inline: 26px;
}
.btn--forest:hover { background: #1D2B24; }
.btn--ivory {
  min-width: 218px; height: 52px;
  background: var(--ivory-light); color: var(--forest);
  padding-inline: 26px;
}
.btn--ivory:hover { background: #FFFFFF; }

/* --- Decorative botanicals ----------------------------------------------- */
.bot { position: absolute; pointer-events: none; user-select: none; }
.bot--light { opacity: .5; }
.bot--onDark { opacity: .3; filter: brightness(0) invert(1); }

/* ===== Header ============================================================ */
.site-header {
  background: var(--ivory);
  height: 103px;                   /* band 0-61 mockup x1.667 */
  position: relative;
}
.site-header .wrap--wide {
  height: 100%;
  display: flex; align-items: center; justify-content: space-between;
}
.brand { display: flex; align-items: center; gap: 12px; text-decoration: none; }
.brand img { width: 34px; }
.brand span { font-family: var(--serif); font-size: 38px; letter-spacing: .01em; }

.nav { display: flex; align-items: center; gap: 44px; }
.nav a {
  font-size: var(--f-nav); text-decoration: none; color: var(--ink);
  padding-bottom: 4px;
}
.nav a[aria-current="page"] { border-bottom: 1px solid var(--ink); }
.nav a:hover { color: var(--clay); }
.nav-toggle { display: none; }

/* ===== Hero ============================================================== */
.hero {
  position: relative;
  background: var(--forest-deep);
  min-height: 612px;               /* band 62-429 mockup x1.667 */
  display: grid;
  isolation: isolate;
}
.hero__photo {
  position: absolute; inset: 0 0 0 36%;
  background: url("/assets/img/hero-path.jpg") center/cover no-repeat;
}
.hero__photo::before {             /* photo feathers into the panel */
  content: ""; position: absolute; inset: 0; width: 17%;
  background: linear-gradient(90deg, var(--forest-deep), rgba(36,59,53,0));
}
.hero__inner {
  position: relative; z-index: 2;
  max-width: var(--wrap-wide);
  margin-inline: auto; width: 100%;
  padding: 108px 24px 0;           /* band 62 -> H1 ink 127 = 65 mockup */
}
.hero__copy { max-width: 700px; }
/* The mockup's H1 break cannot come from wrapping: line 1 would also take
   "grounded" (621px < the 642px line 2 needs). It is a designed break, so it
   is explicit - and released below 1180 where the measured widths no longer
   apply. */
.lb { display: inline; }
.hero h1 {
  font-size: var(--f-h1); line-height: var(--lh-h1);
  color: var(--on-dark);
}
.hero p {
  margin-top: var(--gap-h1-body);
  color: #D9DED6; max-width: 500px;
}
.hero .btn { margin-top: var(--gap-body-cta); }
.hero__bot-l { left: 26px; top: 100px; width: 112px; }
.hero__bot-r { right: 44px; bottom: 100px; width: 210px; }

/* Wave divider - amplitude measured (14 mockup px); control points eyeballed
   to the mockup silhouette, since a bezier cannot be read off a raster. */
.wave { display: block; width: 100%; height: var(--wave); position: relative; z-index: 3; }
.wave svg { display: block; width: 100%; height: 100%; }

/* ===== Intro ============================================================= */
.intro {
  position: relative;
  background: var(--ivory-light);
  padding: 42px 0 18px;            /* band 430 -> art 455 = 25 mockup */
  overflow: hidden;
}
.intro .wrap {
  /* art x115-285, text x318-722 inside a wrap of x80-773 (mockup px) */
  display: grid; grid-template-columns: 283px 673px; gap: 55px;
  align-items: center; justify-content: start; padding-left: 82px;
}
.intro__art { position: relative; }
.intro__art { height: 258px; }      /* art y455-610 = 155 mockup x1.667 */
.intro__art img { height: 100%; width: auto; margin-inline: auto; }
.intro h2 { font-size: var(--f-h2-blk); line-height: var(--lh-h2-blk); }
.intro p { margin-top: var(--gap-head-body); color: var(--ink-soft); }
.intro p + p { margin-top: var(--gap-para); }

/* ===== Specialties ======================================================= */
.specialties {
  position: relative;
  background: var(--forest);
  padding: 55px 0 40px;            /* band 622 -> ink 655 = 33 mockup */
  color: var(--on-dark);
  overflow: hidden;
}
.section-head { text-align: center; }
.section-head h2 { font-size: var(--f-h2); line-height: var(--lh-h2); }
.section-head p {
  margin-top: var(--gap-head-body); color: var(--ink-soft);
  max-width: 620px; margin-inline: auto;   /* mockup x228-600 = 372 mockup */
}
.specialties .section-head p { color: #C7D0C8; }

/* centred rule + sprig under a section heading */
.orn { display: flex; align-items: center; justify-content: center; gap: 14px; margin-top: 10px; }
.orn::before, .orn::after { content: ""; width: 118px; height: 1px; background: currentColor; opacity: .4; }
.orn img { width: 46px; opacity: .75; }
.specialties .orn img { filter: brightness(0) invert(1); opacity: .6; }

.cards {
  display: grid; grid-template-columns: repeat(3, 1fr);
  gap: var(--gap-card);
  margin-top: var(--gap-head-grid);
}
.card {
  background: var(--card);
  border-radius: var(--r-card);
  overflow: hidden;
  color: var(--ink);
  text-align: center;
  display: flex; flex-direction: column;
}
.card__photo {
  position: relative; aspect-ratio: 223 / 133;   /* photo 718-850, card w 223 */
}
.card__photo img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.card__badge {
  position: absolute; left: 50%; bottom: calc(var(--badge) / -2);
  transform: translateX(-50%);
  width: var(--badge); height: var(--badge); border-radius: 50%;
  display: grid; place-items: center;
  color: var(--ivory-light);
}
.card__badge svg { width: 28px; height: 28px; }
.card__badge--forest { background: var(--forest); }
.card__badge--sage   { background: #6E8172; }
.card__badge--clay   { background: var(--clay); }
.card__body { padding: calc(var(--gap-photo-ttl) + var(--badge) / 2) 55px 24px; }  /* text x112-269 in card x80-303 */
.card h3 { font-size: var(--f-h3); line-height: var(--lh-h3); }
.card p {
  margin-top: var(--gap-head-body);
  font-size: var(--f-card); line-height: var(--lh-card);
  color: var(--ink-soft);
}

/* ===== About ============================================================= */
.about {
  position: relative;
  background: var(--ivory-light);
  padding: 8px 0;                  /* portrait y1029 in band 1027 = 2 mockup */
  overflow: hidden;
}
.about .wrap {
  display: grid; grid-template-columns: 398px 592px; gap: 80px;
  align-items: center; justify-content: start; padding-left: 79px;
}
.about__art { position: relative; }
.about__art img.portrait {
  width: 100%; height: 502px; object-fit: cover;   /* y1029-1335 = 307 mockup */
  border-radius: var(--r-img);
  position: relative; z-index: 2;
}
.about__blob {
  position: absolute; z-index: 1;
  left: -46px; bottom: -34px; width: 300px; opacity: .85;
}
.about__bot { left: -84px; top: 20px; width: 150px; z-index: 0; }
.about h2 {
  font-size: var(--f-h2-blk); line-height: var(--lh-h2-blk);
  margin-top: var(--gap-eyebrow);
}
.about p { margin-top: var(--gap-head-body); color: var(--ink-soft);
  font-size: var(--f-about); line-height: var(--lh-card); }
.about p + p { margin-top: var(--gap-para); }
.about .btn { margin-top: var(--gap-body-cta); }

/* ===== Writing & Presentations =========================================== */
.writing {
  position: relative;
  background: var(--sage);
  padding: 27px 0 30px;            /* band 1338 -> ink 1354 = 16 mockup */
  overflow: hidden;
}
.writing__bot { right: -30px; top: 10px; width: 250px; }
.writing .cards { grid-template-columns: repeat(2, 1fr); margin-top: 26px; }
.wcard {
  background: var(--ivory-light);
  border-radius: var(--r-card);
  overflow: hidden;
  display: grid; grid-template-columns: 200px 1fr;
}
.wcard__photo { position: relative; }
.wcard__photo img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.wcard__body { padding: 20px 26px; }
.wcard__head { display: flex; align-items: center; gap: 12px; }
.wcard__badge {
  width: 44px; height: 44px; border-radius: 50%;   /* mockup badge in card row */
  display: grid; place-items: center; color: var(--ivory-light);
  flex: 0 0 44px;
}
.wcard__badge svg { width: 22px; height: 22px; }
.wcard__badge--forest { background: var(--forest); }
.wcard__badge--clay   { background: var(--clay); }
.wcard__head span {
  font-size: 15px; letter-spacing: .16em; text-transform: uppercase;
}
.wcard p {
  margin-top: 14px;
  font-size: var(--f-card); line-height: var(--lh-card); color: var(--ink-soft);
}
.wlink {
  margin-top: 14px; display: inline-flex; align-items: center; gap: 10px;
  color: var(--clay); text-decoration: none; font-size: var(--f-card);
  transition: gap .2s ease;
}
.wlink svg { width: 20px; height: 20px; }
.wlink:hover { gap: 16px; }

/* ===== CTA band ========================================================== */
.cta {
  background: var(--clay);
  color: #FBF3EC;
  padding: 14px 0;                 /* band 61 - ink 36 = 12.5 mockup each */
}
.cta .wrap--wide {
  display: flex; align-items: center; gap: 40px;
}
.cta__sprig { width: 54px; opacity: .55; filter: brightness(0) invert(1); flex: 0 0 auto; }
.cta h2 { font-size: 33px; line-height: 40px; flex: 0 0 auto; }
.cta p { flex: 1; font-size: var(--f-card); line-height: var(--lh-card); }
.cta .btn { flex: 0 0 auto; }

/* ===== Footer ============================================================ */
.footer {
  background: var(--forest-deep);
  color: var(--on-dark);
  padding: 35px 0 12px;            /* band 1671 -> logo ink 1692 = 21 mockup */
}
.footer__cols {
  display: grid;
  grid-template-columns: 1.35fr 1fr 1fr 1.2fr;
  gap: 48px;
}
.footer .brand span { color: var(--on-dark); }
.footer .brand img { filter: brightness(0) invert(1); opacity: .85; }
.footer__tag {
  margin-top: 12px; font-size: var(--f-card); line-height: var(--lh-card);
  color: var(--on-dark-soft); max-width: 260px;
}
.footer h3 {
  font-family: var(--sans); font-size: 15px;
  letter-spacing: .16em; text-transform: uppercase; color: var(--on-dark-soft);
}
.footer ul { margin-top: 10px; display: grid; gap: 2px; }
.footer li, .footer a { font-size: var(--f-card); line-height: 24px; }
.footer a { text-decoration: none; color: var(--on-dark); }
.footer a:hover { color: #FFF; }
.footer .contact li { display: flex; gap: 12px; align-items: flex-start; }
.footer .contact a { overflow-wrap: anywhere; }
.footer .contact svg { width: 20px; height: 20px; flex: 0 0 20px; margin-top: 4px; color: var(--on-dark-soft); }
.footer__base {
  margin-top: 40px; padding-top: 0;
  display: flex; justify-content: center; gap: 26px;
  font-size: var(--f-small); line-height: var(--lh-small);
  color: var(--on-dark-soft);
}

/* A visible marker for content that is NOT yet confirmed by the client.
   design/BRIEF.md lists these; they stay visible until Kimberly confirms. */
.todo {
  background: #FFF3C4; color: #6B4E00;
  padding: 2px 8px; border-radius: 3px;
  font-family: var(--sans); font-size: .8em; letter-spacing: .02em;
}

/* ===== Responsive =========================================================
   Not measured - the mockup supplies 1440 only. SPEC "Assumptions". */
@media (max-width: 1180px) {
  .lb { display: none; }
  :root { --f-h1: 56px; --lh-h1: 60px; --f-h2: 44px; --lh-h2: 50px;
          --f-h2-blk: 38px; --lh-h2-blk: 42px; --f-h3: 28px; --lh-h3: 34px;
          --f-body: 20px; --lh-body: 30px; --f-card: 19px; --lh-card: 27px;
          --f-eyebrow: 17px; --f-nav: 18px; }
  .about .wrap { grid-template-columns: 340px 1fr; gap: 48px; padding-left: 24px; }
  .intro .wrap { grid-template-columns: 220px 1fr; gap: 40px; padding-left: 24px; }
  .brand span { font-size: 32px; }
  .nav { gap: 30px; }
}
@media (max-width: 900px) {
  .cards, .writing .cards { grid-template-columns: 1fr; }
  .footer__cols { grid-template-columns: 1fr 1fr; gap: 40px; }
  .cta .wrap--wide { flex-wrap: wrap; gap: 24px; }
  .cta h2, .cta p { flex: 1 1 100%; }
}
@media (max-width: 760px) {
  :root { --f-h1: 42px; --lh-h1: 48px; --f-h2: 34px; --lh-h2: 40px;
          --f-h2-blk: 31px; --lh-h2-blk: 37px; --f-body: 18px; --lh-body: 28px; }
  .nav { display: none; }
  .nav.is-open {
    display: flex; flex-direction: column; gap: 20px; align-items: flex-start;
    position: absolute; top: 103px; left: 0; right: 0; z-index: 10;
    background: var(--ivory); padding: 24px; border-top: 1px solid var(--rule);
  }
  .nav-toggle {
    display: grid; place-items: center; width: 44px; height: 44px;
    background: none; border: 0; color: var(--ink); cursor: pointer;
  }
  .nav-toggle svg { width: 26px; height: 26px; }
  .hero { min-height: 0; }
  .hero__photo { inset: 0; opacity: .3; }
  .hero__photo::before { display: none; }
  .hero__inner { padding: 56px 24px 64px; }
  .hero__bot-l, .hero__bot-r { display: none; }
  .intro .wrap, .about .wrap { grid-template-columns: 1fr; gap: 32px; }
  .intro__art { max-width: 240px; }
  .wcard { grid-template-columns: 1fr; }
  .wcard__photo { aspect-ratio: 16 / 9; }
  .footer__cols { grid-template-columns: 1fr; gap: 32px; }
  .footer__base { flex-direction: column; align-items: center; gap: 8px; text-align: center; }
}
