/* ═══════════════════════════════════════════════════════════════════════
   KHCounselling — karin.beam.page  ·  stylesheet
   Design: "a quiet exhale" — organic editorial calm.
   Fonts:  Fraunces (display serif) · Karla (body)

   HOW THIS FILE IS ORGANISED (for whoever edits next):
     1. Tokens      — colours, fonts, the 8px spacing scale, radii
     2. Reset/base  — element defaults
     3. Typography  — headings, body, kicker, lede
     4. Layout      — .wrap, section, column grids, utilities
     5. Components   — header, buttons, hero, cards, lists, form, footer
     6. Blog post page
     7. Motion + responsive tweaks

   SPACING RULE (rule of 8): every margin / padding / gap uses a --s-* token
   below. Tokens are multiples of 8px (with 4px as the only half-step).
   Never hard-code a spacing value — add or reuse a token.
   ═══════════════════════════════════════════════════════════════════════ */

/* ── 1. TOKENS ─────────────────────────────────────────────────────────── */
:root {
  /* palette — drawn from Karin's counselling room */
  --paper:      #f7f5ef;   /* warm off-white page background          */
  --paper-deep: #edeae1;   /* alternate section background            */
  --ink:        #2e3b34;   /* deep moss — primary text                */
  --ink-2:      #243029;   /* darker moss — button hover              */
  --ink-soft:   #5d6c62;   /* secondary text                         */
  --sage:       #8aa08c;   /* mid sage — labels, accents             */
  --sage-pale:  #c9d4c5;   /* pale sage — borders, hairlines         */
  --chair:      #9cb4ba;   /* dusty blue, from the room's chairs      */
  --warm:       #b07a4f;   /* warm ochre — links, highlights          */
  --white:      #fdfcf9;   /* card surface                            */

  --font-display: "Fraunces", "Iowan Old Style", Georgia, serif;
  --font-body:    "Karla", "Avenir Next", "Segoe UI", sans-serif;

  /* 8px spacing scale — the ONLY source of spacing values */
  --s-0:  0.25rem;  /*  4px  (half-step)  */
  --s-1:  0.5rem;   /*  8px  */
  --s-2:  1rem;     /* 16px  */
  --s-3:  1.5rem;   /* 24px  */
  --s-4:  2rem;     /* 32px  */
  --s-5:  2.5rem;   /* 40px  */
  --s-6:  3rem;     /* 48px  */
  --s-8:  4rem;     /* 64px  */
  --s-10: 5rem;     /* 80px  */
  --s-12: 6rem;     /* 96px  */

  /* fluid section rhythm — endpoints sit on the 8px grid (48px → 96px) */
  --section-y: clamp(var(--s-6), 9vw, var(--s-12));

  --measure:    64ch;     /* comfortable reading width        */
  --col-narrow: 640px;    /* intro / lead text blocks (8×80)  */
  --col-read:   760px;    /* article column (8×95)            */
  --col-figure: 960px;    /* article hero image (8×120)       */

  --radius:    16px;
  --radius-sm: 8px;
  --shadow: 0 16px 48px -16px rgba(46, 59, 52, .25);
}

/* ── 2. RESET / BASE ───────────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 1.0625rem;
  line-height: 1.7;
  color: var(--ink);
  background: var(--paper);
  -webkit-font-smoothing: antialiased;
}
img, video { max-width: 100%; height: auto; display: block; }
a { color: var(--warm);
    text-decoration-color: color-mix(in srgb, var(--warm) 45%, transparent);
    text-underline-offset: 3px; }
a:hover { text-decoration-color: var(--warm); }
:focus-visible { outline: 2px solid var(--chair); outline-offset: 2px; border-radius: 2px; }
::selection { background: var(--sage-pale); }

/* barely-there paper grain over everything */
body::after {
  content: ""; position: fixed; inset: 0; pointer-events: none; z-index: 60;
  opacity: .05; mix-blend-mode: multiply;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2'/%3E%3C/filter%3E%3Crect width='160' height='160' filter='url(%23n)' opacity='0.6'/%3E%3C/svg%3E");
}

/* ── 3. TYPOGRAPHY ─────────────────────────────────────────────────────── */
h1, h2, h3 {
  font-family: var(--font-display); font-weight: 480;
  line-height: 1.12; letter-spacing: -0.015em;
  margin: 0 0 var(--s-2); text-wrap: balance;
}
h1 { font-size: clamp(2.5rem, 6.2vw, 4.4rem); }
h2 { font-size: clamp(1.9rem, 3.6vw, 2.8rem); }
h3 { font-size: clamp(1.25rem, 2vw, 1.5rem); }
p  { margin: 0 0 var(--s-2); max-width: var(--measure); }
strong { font-weight: 700; color: var(--ink); }

/* small-caps section label, e.g. "HELLO, I'M KARIN" */
.kicker {
  display: flex; align-items: center; gap: var(--s-1);
  font-size: .8rem; font-weight: 700; letter-spacing: .22em;
  text-transform: uppercase; color: var(--sage);
  margin: 0 0 var(--s-3);
}
.kicker::before { content: ""; width: var(--s-5); height: 1px; background: var(--sage); }

/* oversized intro paragraph */
.lede { font-size: clamp(1.15rem, 1.8vw, 1.35rem); line-height: 1.6; color: var(--ink-soft); }

/* hand-drawn underline accent around a hero phrase */
.uline { position: relative; white-space: nowrap; }
.uline svg { position: absolute; left: -2%; bottom: -0.18em; width: 104%; height: .42em; overflow: visible; }
.uline svg path { fill: none; stroke: var(--chair); stroke-width: 7; stroke-linecap: round; opacity: .65; }

/* ── 4. LAYOUT ─────────────────────────────────────────────────────────── */
.wrap { width: min(1120px, calc(100% - var(--s-6))); margin-inline: auto; }
section { padding-block: var(--section-y); }
.section-alt { background: var(--paper-deep); }

/* width-limited content blocks (replaces inline max-width styles) */
.measure-narrow { max-width: var(--col-narrow); }
.link-plain { color: inherit; text-decoration: none; }

/* responsive column grids */
.cols { display: grid; gap: clamp(var(--s-4), 5vw, var(--s-10)); align-items: center; }
.cols > * { min-width: 0; }   /* let columns shrink — prevents grid blowout from long words */
.cols--top { align-items: start; }
@media (min-width: 880px) {
  .cols-2        { grid-template-columns: 1fr 1fr; }
  .cols-golden   { grid-template-columns: 1.25fr 1fr; }
  .cols-golden-rev { grid-template-columns: 1fr 1.25fr; }
}

/* ── 5. COMPONENTS ─────────────────────────────────────────────────────── */

/* header / nav */
.site-head {
  position: sticky; top: 0; z-index: 50;
  background: color-mix(in srgb, var(--paper) 85%, transparent);
  backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px);
  border-bottom: 1px solid color-mix(in srgb, var(--sage-pale) 60%, transparent);
}
.site-head .wrap { display: flex; align-items: center; gap: var(--s-3); padding-block: var(--s-1); }
.wordmark {
  font-family: var(--font-display); font-size: 1.18rem; font-weight: 560;
  color: var(--ink); text-decoration: none; letter-spacing: -0.01em; flex-shrink: 0;
}
.wordmark .wm-dot { color: var(--sage); }
.site-nav { display: flex; gap: var(--s-3); margin-left: auto; }
.site-nav a {
  font-size: .92rem; font-weight: 500; color: var(--ink-soft);
  text-decoration: none; white-space: nowrap; padding-block: var(--s-0);
}
.site-nav a:hover, .site-nav a[aria-current="page"] { color: var(--ink); }

/* buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: var(--s-1);
  font-family: var(--font-body); font-weight: 700; font-size: .98rem;
  padding: var(--s-2) var(--s-3); border-radius: 999px; white-space: nowrap;
  text-decoration: none; cursor: pointer; border: 1px solid transparent;
  transition: transform .25s ease, box-shadow .25s ease, background .25s ease;
}
.btn-primary { background: var(--ink); color: var(--white); }
.btn-primary:hover { transform: translateY(-2px); box-shadow: var(--shadow); background: var(--ink-2); }
.btn-ghost { border-color: var(--ink); color: var(--ink); background: transparent; }
.btn-ghost:hover { background: color-mix(in srgb, var(--ink) 7%, transparent); }
.btn-sm { padding: var(--s-1) var(--s-3); font-size: .88rem; }

/* hero */
.hero {
  position: relative; min-height: min(92vh, 880px);
  display: flex; align-items: center; overflow: hidden;
  padding-block: clamp(var(--s-10), 10vw, var(--s-12));
}
.hero-media { position: absolute; inset: 0; z-index: -2; }
.hero-media video, .hero-media img { width: 100%; height: 100%; object-fit: cover; object-position: 72% 40%; }
.hero::before { /* paper wash so type always reads over the video */
  content: ""; position: absolute; inset: 0; z-index: -1;
  background:
    linear-gradient(100deg, var(--paper) 0%, color-mix(in srgb, var(--paper) 88%, transparent) 38%, color-mix(in srgb, var(--paper) 25%, transparent) 68%, transparent 100%),
    linear-gradient(to top, var(--paper) 0%, transparent 22%);
}
.hero-inner { max-width: 620px; }
.hero h1 { margin-bottom: var(--s-2); }
.hero .lede { margin-bottom: var(--s-4); }
.hero-ctas { display: flex; flex-wrap: wrap; gap: var(--s-2); margin-bottom: var(--s-4); }
.hero-marks { display: flex; flex-wrap: wrap; gap: var(--s-1) var(--s-4); padding: 0; margin: 0; list-style: none; }
.hero-marks li { display: flex; gap: var(--s-1); align-items: baseline; font-size: .88rem; font-weight: 500; color: var(--ink-soft); }
.hero-marks li::before { content: "—"; color: var(--sage); }

/* drifting dandelion seeds (hero decoration) */
.seed { position: absolute; z-index: 1; width: 26px; height: 26px; color: var(--ink-soft); opacity: 0; animation: drift 16s linear infinite; }
.seed:nth-child(2) { animation-delay: 5s;  animation-duration: 20s; width: 18px; }
.seed:nth-child(3) { animation-delay: 11s; animation-duration: 24s; width: 22px; }
@keyframes drift {
  0%   { transform: translate(0, 0) rotate(0deg);      opacity: 0; }
  8%   { opacity: .5; }
  60%  { opacity: .35; }
  100% { transform: translate(-46vw, -34vh) rotate(70deg); opacity: 0; }
}

/* imagery */
.photo { border-radius: var(--radius); box-shadow: var(--shadow); }
.photo-arch { border-radius: 200px 200px var(--radius) var(--radius); } /* arched top */
.img-note { font-size: .85rem; color: var(--ink-soft); margin: var(--s-2) 0 0; }

/* "how I can help" two-column list */
.help-list { columns: 2; column-gap: var(--s-5); padding: 0; margin: var(--s-3) 0 0; list-style: none; max-width: 560px; }
.help-list li {
  break-inside: avoid; padding: var(--s-1) 0; font-weight: 500;
  border-bottom: 1px solid var(--sage-pale); display: flex; gap: var(--s-1);
}
.help-list li::before { content: "·"; color: var(--warm); font-weight: 700; }

/* fees cards */
.fee-grid { display: grid; gap: var(--s-3); margin-top: var(--s-5); }
@media (min-width: 760px) { .fee-grid { grid-template-columns: repeat(3, 1fr); } }
.fee-card {
  background: var(--white); border: 1px solid var(--sage-pale); border-radius: var(--radius);
  padding: var(--s-4) var(--s-3) var(--s-3);
  display: flex; flex-direction: column; gap: var(--s-0);
  transition: transform .25s ease, box-shadow .25s ease;
}
.fee-card:hover { transform: translateY(-4px); box-shadow: var(--shadow); }
.fee-card.fee-hero { background: var(--ink); color: var(--paper); border-color: var(--ink); }
.fee-card.fee-hero .fee-amount, .fee-card.fee-hero h3 { color: var(--paper); }
.fee-card.fee-hero p { color: color-mix(in srgb, var(--paper) 75%, transparent); }
.fee-amount { font-family: var(--font-display); font-size: 2.4rem; font-weight: 520; color: var(--ink); line-height: 1; }
.fee-amount small { font-size: .9rem; font-family: var(--font-body); font-weight: 500; opacity: .65; }
.fee-card p { font-size: .95rem; color: var(--ink-soft); margin: var(--s-1) 0 0; }

/* label + value rows (practical info, qualifications) */
.practical-list { list-style: none; padding: 0; margin: var(--s-5) 0 0; max-width: var(--measure); }
.practical-list li { padding: var(--s-1) 0; border-bottom: 1px solid var(--sage-pale); display: flex; gap: var(--s-2); font-size: .98rem; }
.practical-list li strong { flex: 0 0 152px; }   /* 8×19 */
.practical-list--flush { margin-top: 0; }         /* align list top with adjacent heading */

/* testimonials */
.quotes { display: grid; gap: clamp(var(--s-4), 4vw, var(--s-6)); }
.quotes blockquote {
  margin: 0; max-width: 720px;
  font-family: var(--font-display); font-style: italic; font-weight: 420;
  font-size: clamp(1.25rem, 2.4vw, 1.7rem); line-height: 1.45;
}
.quotes blockquote:nth-child(2) { justify-self: end; text-align: right; }
.quotes blockquote::before { content: "“"; color: var(--chair); font-size: 1.6em; line-height: 0; vertical-align: -0.3em; margin-right: var(--s-0); }
.quotes cite {
  display: block; margin-top: var(--s-2);
  font-family: var(--font-body); font-style: normal; font-size: .85rem;
  font-weight: 700; letter-spacing: .16em; text-transform: uppercase; color: var(--sage);
}

/* blog cards */
.post-grid { display: grid; gap: var(--s-3); margin-top: var(--s-5); }
@media (min-width: 700px)  { .post-grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1020px) { .post-grid { grid-template-columns: repeat(3, 1fr); } }
.post-card {
  background: var(--white); border: 1px solid var(--sage-pale); border-radius: var(--radius);
  overflow: hidden; text-decoration: none; color: var(--ink);
  display: flex; flex-direction: column; transition: transform .25s ease, box-shadow .25s ease;
}
.post-card:hover { transform: translateY(-5px); box-shadow: var(--shadow); }
.post-card img { aspect-ratio: 16 / 10; object-fit: cover; }
.post-card-body { padding: var(--s-3); display: flex; flex-direction: column; gap: var(--s-1); flex: 1; }
.post-card time { font-size: .8rem; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; color: var(--sage); }
.post-card h3 { font-size: 1.22rem; margin: 0; }
.post-card p { font-size: .93rem; color: var(--ink-soft); margin: 0; flex: 1; }
.post-card .more { font-size: .88rem; font-weight: 700; color: var(--warm); margin-top: var(--s-1); }

/* contact */
.contact-details { list-style: none; padding: 0; margin: var(--s-4) 0 0; }
.contact-details li { display: flex; gap: var(--s-2); align-items: baseline; padding: var(--s-1) 0; }
.contact-details .label {
  font-size: .8rem; font-weight: 700; letter-spacing: .16em; text-transform: uppercase;
  color: var(--sage); flex: 0 0 88px;  /* 8×11 */
}
.contact-details a { font-weight: 600; overflow-wrap: anywhere; }  /* long email never overflows */

.form-card { background: var(--white); border: 1px solid var(--sage-pale); border-radius: var(--radius); padding: clamp(var(--s-3), 3vw, var(--s-5)); box-shadow: var(--shadow); }
.form-card label { display: block; font-weight: 700; font-size: .92rem; margin: var(--s-3) 0 var(--s-1); }
.form-card label:first-of-type { margin-top: 0; }
.form-card label .opt { font-weight: 500; color: var(--ink-soft); }
.form-card input, .form-card textarea {
  width: 100%; font: inherit; color: var(--ink);
  background: var(--paper); border: 1px solid var(--sage-pale); border-radius: var(--radius-sm);
  padding: var(--s-1) var(--s-2);
}
.form-card input:focus, .form-card textarea:focus { outline: 2px solid var(--chair); outline-offset: 1px; border-color: var(--chair); }
.form-card textarea { min-height: 144px; resize: vertical; }   /* 8×18 */
.form-card .btn { width: 100%; margin-top: var(--s-3); }
.form-note { font-size: .85rem; color: var(--ink-soft); margin: var(--s-2) 0 0; text-align: center; }
.form-status { display: none; text-align: center; padding: var(--s-5) var(--s-2); }
.form-status h3 { color: var(--ink); }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }  /* spam honeypot */

/* footer */
.site-foot { background: var(--ink); color: color-mix(in srgb, var(--paper) 72%, transparent); padding-block: var(--s-6); font-size: .92rem; }
.site-foot .wrap { display: flex; flex-wrap: wrap; gap: var(--s-2) var(--s-6); align-items: center; }
.site-foot .wordmark { color: var(--paper); }
.site-foot a { color: color-mix(in srgb, var(--paper) 85%, transparent); }
.site-foot .fine { margin-left: auto; font-size: .84rem; }

/* ── 6. BLOG POST PAGE ─────────────────────────────────────────────────── */
.post-hero { padding-block: clamp(var(--s-6), 6vw, var(--s-10)) 0; }
.post-col   { max-width: var(--col-read); }     /* hero text + body column */
.post-figure { margin: clamp(var(--s-4), 4vw, var(--s-6)) auto; max-width: var(--col-figure); }
.post-figure img { border-radius: var(--radius); box-shadow: var(--shadow); aspect-ratio: 16 / 8; object-fit: cover; width: 100%; }
.post-meta { display: flex; flex-wrap: wrap; gap: var(--s-2); color: var(--ink-soft); font-size: .92rem; font-weight: 500; margin-top: var(--s-2); }
.post-body { padding-bottom: clamp(var(--s-6), 6vw, var(--s-10)); }
.post-body > * { max-width: var(--measure); margin-inline: auto; }
.post-body p:first-of-type { font-size: 1.18rem; color: var(--ink-soft); }
.post-body h3 { margin-top: var(--s-5); }
.post-body blockquote {
  font-family: var(--font-display); font-style: italic; font-size: 1.3rem; line-height: 1.5; color: var(--ink);
  border-left: 3px solid var(--chair); margin: var(--s-4) auto; padding: var(--s-0) 0 var(--s-0) var(--s-3);
}
.post-cta { background: var(--paper-deep); border-radius: var(--radius); padding: var(--s-5); text-align: center; margin: var(--s-6) auto 0; }
.post-cta p { margin-inline: auto; }
.post-nav { display: flex; flex-wrap: wrap; justify-content: space-between; gap: var(--s-2); max-width: var(--measure); margin: var(--s-5) auto 0; font-size: .92rem; }
.post-nav a { flex: 1 1 240px; }
.post-nav a:last-child { text-align: right; }

/* ── 7. MOTION + RESPONSIVE ────────────────────────────────────────────── */
/* hero load-in (one-time, on page load only — never scroll-triggered) */
.rise { opacity: 0; transform: translateY(18px); animation: rise .9s ease forwards; }
.rise-2 { animation-delay: .15s; } .rise-3 { animation-delay: .3s; } .rise-4 { animation-delay: .45s; }
@keyframes rise { to { opacity: 1; transform: none; } }

/* Once the wordmark + 5 links + button no longer fit (tablet portrait ~768
   included), hide the nav and pin the CTA to the right edge. One-pager, so
   the nav is a convenience — scroll + the CTA cover navigation. */
@media (max-width: 880px) {
  .site-nav { display: none; }
  .site-head .btn-sm { margin-left: auto; }     /* push "Book a free chat" right */
}
@media (max-width: 720px) {
  .site-head .wrap { gap: var(--s-2); }
  /* stack the wordmark into a two-line lockup: "Karin Hughes" / "Counselling",
     button stays vertically centred on the right */
  .wordmark { font-size: 1.05rem; line-height: 1.15; }
  .wordmark .wm-suffix { display: block; color: var(--sage); }
  .wordmark .wm-dot { display: none; }          /* drop the middle dot when stacked */
  .site-head .btn-sm { padding: var(--s-1) var(--s-2); font-size: .85rem; }
  /* stronger vertical wash so hero text always reads over the video */
  .hero::before {
    background: linear-gradient(to bottom,
      var(--paper) 0%,
      color-mix(in srgb, var(--paper) 82%, transparent) 52%,
      color-mix(in srgb, var(--paper) 58%, transparent) 100%);
  }
  .quotes blockquote:nth-child(2) { justify-self: start; text-align: left; }
}
@media (max-width: 560px) {
  .help-list { columns: 1; }
  /* stack label/value rows so nothing is squeezed on small phones */
  .practical-list li { flex-direction: column; gap: var(--s-0); }
  .practical-list li strong { flex-basis: auto; }
  /* keep the hand-drawn underline on mobile too — shrink the headline just
     enough that the underlined phrase stays on one line (the SVG can't span a
     wrapped phrase). The phrase keeps white-space:nowrap from the base rule. */
  .hero h1 { font-size: clamp(1.85rem, 8.6vw, 2.6rem); }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .rise { opacity: 1; transform: none; animation: none; }
  .seed { display: none; }
}
