/* =============================================================
   Animal Hospital Clinic — Design System v4
   Mobile-first · Fully Responsive · WCAG 2.1 AA
   ============================================================= */

@import url('https://fonts.googleapis.com/css2?family=Playfair+Display:ital,wght@0,400;0,600;1,400&family=Plus+Jakarta+Sans:wght@300;400;500;600&family=DM+Mono:wght@400&display=swap');

/* ── Tokens ────────────────────────────────────────────────── */
:root {
  /* Palette */
  --c-cream:     #F9F7F2;
  --c-sand:      #EDE8DC;
  --c-warm:      #E0D9CB;
  --c-stone:     #BFB5A5;
  --c-clay:      #96887A;
  --c-bark:      #665A4E;
  --c-espresso:  #352920;
  --c-forest:    #2A4538;
  --c-sage:      #517060;
  --c-sage-lt:   #8DAF9B;
  --c-sage-xl:   #C6DDD3;
  --c-sage-2xl:  #EBF4F0;
  --c-amber:     #C07D30;
  --c-amber-lt:  #F3E3C5;
  --c-rust:      #9E3B2B;
  --c-rust-lt:   #F3E2DE;
  --c-white:     #FFFFFF;

  /* Semantic */
  --bg:          var(--c-cream);
  --bg-surface:  var(--c-white);
  --bg-muted:    var(--c-sand);
  --bg-accent:   var(--c-sage-2xl);
  --text:        var(--c-espresso);
  --text-2:      var(--c-bark);
  --text-3:      var(--c-clay);
  --text-inv:    var(--c-white);
  --border:      var(--c-warm);
  --border-2:    var(--c-stone);
  --accent:      var(--c-forest);
  --accent-h:    var(--c-sage);

  /* Type */
  --f-display: 'Playfair Display', Georgia, serif;
  --f-body:    'Plus Jakarta Sans', system-ui, sans-serif;
  --f-mono:    'DM Mono', monospace;

  /* Scale (fluid) */
  --t-xs:   0.75rem;
  --t-sm:   0.875rem;
  --t-base: 1rem;
  --t-lg:   1.125rem;
  --t-xl:   1.25rem;
  --t-2xl:  1.5rem;
  --t-3xl:  clamp(1.5rem, 4vw, 1.875rem);
  --t-4xl:  clamp(1.75rem, 5vw, 2.25rem);
  --t-5xl:  clamp(2rem, 6vw, 3rem);
  --t-6xl:  clamp(2.25rem, 8vw, 3.75rem);

  /* Space */
  --s-1:  0.25rem;  --s-2:  0.5rem;   --s-3:  0.75rem;
  --s-4:  1rem;     --s-5:  1.25rem;  --s-6:  1.5rem;
  --s-8:  2rem;     --s-10: 2.5rem;   --s-12: 3rem;
  --s-16: 4rem;     --s-20: 5rem;     --s-24: 6rem;

  /* Radius */
  --r-sm:   4px;   --r-md:   8px;
  --r-lg:   14px;  --r-xl:   20px;
  --r-2xl:  28px;  --r-full: 9999px;

  /* Shadow */
  --sh-sm: 0 1px 4px rgba(53,41,32,.07);
  --sh-md: 0 4px 20px rgba(53,41,32,.10);
  --sh-lg: 0 8px 40px rgba(53,41,32,.12);
  --sh-xl: 0 16px 60px rgba(53,41,32,.15);

  /* Motion */
  --ease:  cubic-bezier(.16,1,.3,1);
  --fast:  140ms;
  --med:   260ms;
  --slow:  420ms;

  /* Layout */
  --max-w:      1200px;
  --max-w-blog: 820px;
  --max-w-text: 680px;
  --header-h:   64px;
  --gutter:     1rem;
}

@media (min-width: 640px)  { :root { --gutter: 1.5rem; } }
@media (min-width: 1024px) { :root { --gutter: 2rem; } }

/* ── Reset ─────────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html {
  font-size: 16px;
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
  overflow-x: hidden;
}
body {
  font-family: var(--f-body);
  font-size: var(--t-base);
  line-height: 1.7;
  color: var(--text);
  background: var(--bg);
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}
img, svg, video { display: block; max-width: 100%; height: auto; }
a { color: var(--accent); text-decoration: none; }
a:hover { color: var(--accent-h); }
button { cursor: pointer; font: inherit; border: none; background: none; }
input, textarea, select { font: inherit; font-size: inherit; }
ul, ol { padding-left: var(--s-6); }
/* Touch: no tap highlight */
a, button { -webkit-tap-highlight-color: transparent; }
/* Focus ring */
:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }
::selection { background: var(--c-sage-xl); color: var(--c-forest); }

/* ── Typography ─────────────────────────────────────────────── */
h1, h2, h3, h4 {
  font-family: var(--f-display);
  font-weight: 400;
  line-height: 1.15;
  color: var(--text);
}
h1 { font-size: var(--t-6xl); }
h2 { font-size: var(--t-5xl); }
h3 { font-size: var(--t-4xl); }
h4 { font-size: var(--t-3xl); }
h5 { font-size: var(--t-xl); font-family: var(--f-body); font-weight: 600; line-height: 1.3; }
h6 { font-size: var(--t-lg); font-family: var(--f-body); font-weight: 600; line-height: 1.3; }
p  { margin-bottom: var(--s-4); }
p:last-child { margin-bottom: 0; }

.lead {
  font-size: clamp(var(--t-base), 2vw, var(--t-xl));
  font-weight: 300;
  line-height: 1.65;
  color: var(--text-2);
}
.eyebrow {
  font-family: var(--f-body);
  font-size: var(--t-xs);
  font-weight: 600;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--accent);
}
blockquote {
  border-left: 3px solid var(--c-sage-lt);
  padding: var(--s-4) var(--s-5);
  margin: var(--s-8) 0;
  background: var(--bg-accent);
  border-radius: 0 var(--r-md) var(--r-md) 0;
  font-family: var(--f-display);
  font-size: clamp(var(--t-lg), 2vw, var(--t-xl));
  font-style: italic;
  color: var(--text-2);
}
code {
  font-family: var(--f-mono);
  font-size: .875em;
  background: var(--bg-muted);
  padding: .1em .4em;
  border-radius: var(--r-sm);
  color: var(--accent);
  word-break: break-all;
}
pre {
  background: var(--c-espresso);
  color: var(--c-sage-xl);
  padding: var(--s-5);
  border-radius: var(--r-lg);
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  font-size: var(--t-sm);
  line-height: 1.6;
  margin: var(--s-8) 0;
}
hr { border: none; border-top: 1px solid var(--border); margin: var(--s-8) 0; }

/* ── Layout utilities ────────────────────────────────────────── */
.container {
  width: 100%;
  max-width: var(--max-w);
  margin-inline: auto;
  padding-inline: var(--gutter);
}
.container--blog { max-width: var(--max-w-blog); }
.container--text { max-width: var(--max-w-text); }

.section    { padding-block: var(--s-12); }
.section-lg { padding-block: var(--s-20); }
.section-sm { padding-block: var(--s-8); }

@media (min-width: 768px) {
  .section    { padding-block: var(--s-16); }
  .section-lg { padding-block: var(--s-24); }
}

/* ── Skip link ───────────────────────────────────────────────── */
.skip-link {
  position: fixed; inset: auto auto auto var(--s-4); top: var(--s-4);
  z-index: 9999;
  background: var(--accent); color: var(--text-inv);
  padding: var(--s-3) var(--s-5);
  border-radius: var(--r-md);
  font-size: var(--t-sm); font-weight: 600;
  transform: translateY(-300%);
  transition: transform var(--fast) var(--ease);
}
.skip-link:focus { transform: translateY(0); }

/* ── Reading progress ────────────────────────────────────────── */
.ahc-progress {
  position: fixed; top: 0; left: 0; z-index: 9999;
  height: 3px; width: 0%;
  background: var(--accent);
  border-radius: 0 var(--r-full) var(--r-full) 0;
  transition: width 60ms linear;
  pointer-events: none;
}

/* ════════════════════════════════════════════════════════════
   BUTTONS
   ════════════════════════════════════════════════════════════ */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  gap: var(--s-2);
  min-height: 44px;
  padding: .625rem 1.25rem;
  font-family: var(--f-body);
  font-size: var(--t-sm); font-weight: 600;
  border-radius: var(--r-full);
  border: 1.5px solid transparent;
  transition: all var(--fast) var(--ease);
  white-space: nowrap;
  text-decoration: none;
  touch-action: manipulation;
}
.btn:hover { transform: translateY(-1px); }
.btn:active { transform: translateY(0); }

.btn-primary { background: var(--accent); color: var(--text-inv); border-color: var(--accent); }
.btn-primary:hover { background: var(--accent-h); border-color: var(--accent-h); color: var(--text-inv); box-shadow: var(--sh-md); }

.btn-outline { background: transparent; color: var(--accent); border-color: var(--accent); }
.btn-outline:hover { background: var(--accent); color: var(--text-inv); }

.btn-ghost { background: transparent; color: var(--text-2); border-color: var(--border-2); }
.btn-ghost:hover { background: var(--bg-muted); color: var(--text); }

.btn-amber { background: var(--c-amber); color: #fff; border-color: var(--c-amber); }
.btn-amber:hover { background: #a56b25; border-color: #a56b25; color: #fff; box-shadow: var(--sh-md); }

.btn-lg  { min-height: 52px; padding: .875rem 1.75rem; font-size: var(--t-base); }
.btn-sm  { min-height: 36px; padding: .4rem .9rem; font-size: var(--t-xs); }
.btn-full { width: 100%; }

/* ── Badges / Tags ────────────────────────────────────────────── */
.badge {
  display: inline-flex; align-items: center;
  padding: .2rem .65rem;
  font-size: var(--t-xs); font-weight: 700;
  border-radius: var(--r-full);
  text-transform: uppercase; letter-spacing: .07em;
  white-space: nowrap;
}
.badge-sage   { background: var(--c-sage-xl);  color: var(--c-forest); }
.badge-amber  { background: var(--c-amber-lt); color: #7a4e18; }
.badge-rust   { background: var(--c-rust-lt);  color: var(--c-rust); }
.badge-warm   { background: var(--c-warm);     color: var(--c-bark); }

.tag {
  display: inline-flex; align-items: center;
  min-height: 32px;
  padding: .2rem .75rem;
  font-size: var(--t-xs); font-weight: 500;
  border-radius: var(--r-full);
  border: 1px solid var(--border);
  background: var(--bg-muted); color: var(--text-2);
  text-decoration: none;
  transition: all var(--fast) var(--ease);
}
.tag:hover { background: var(--c-sage-xl); color: var(--c-forest); border-color: var(--c-sage-lt); }

/* ════════════════════════════════════════════════════════════
   HEADER
   ════════════════════════════════════════════════════════════ */
.site-header {
  position: sticky; top: 0; z-index: 100;
  background: rgba(249,247,242,.95);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--border);
  transition: box-shadow var(--med) var(--ease);
}
.site-header.is-scrolled { box-shadow: var(--sh-sm); }

.header-inner {
  display: flex; align-items: center;
  justify-content: space-between;
  height: var(--header-h);
  gap: var(--s-3);
}

/* Logo */
.site-logo {
  display: flex; align-items: center;
  gap: var(--s-2); flex-shrink: 0;
  text-decoration: none; color: var(--text);
  min-width: 0;
}
.site-logo__mark {
  width: 36px; height: 36px; flex-shrink: 0;
  background: var(--accent);
  border-radius: var(--r-md);
  display: flex; align-items: center; justify-content: center;
  font-size: 18px; line-height: 1;
}
.site-logo__text { min-width: 0; }
.site-logo__name {
  display: block;
  font-family: var(--f-display);
  font-size: clamp(.9rem, 3vw, var(--t-xl));
  line-height: 1;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.site-logo__sub {
  display: none;
  font-size: var(--t-xs); color: var(--text-3); line-height: 1;
  margin-top: 2px;
}
@media (min-width: 640px) {
  .site-logo__mark { width: 40px; height: 40px; font-size: 20px; }
  .site-logo__sub  { display: block; }
}

/* Desktop nav */
.site-nav {
  display: none;
  list-style: none; padding: 0; margin: 0;
}
@media (min-width: 768px) {
  .site-nav {
    display: flex; align-items: center;
    gap: var(--s-1); flex: 1; justify-content: center;
  }
}
.site-nav a {
  display: block; padding: var(--s-2) var(--s-3);
  font-size: var(--t-sm); font-weight: 500; color: var(--text-2);
  border-radius: var(--r-md);
  transition: all var(--fast) var(--ease);
  white-space: nowrap;
}
.site-nav a:hover,
.site-nav a[aria-current="page"] { color: var(--accent); background: var(--bg-accent); }

/* Dropdown */
.nav-has-drop { position: relative; }
.nav-drop {
  position: absolute; top: calc(100% + var(--s-2)); left: 0;
  min-width: 220px;
  background: var(--bg-surface);
  border: 1px solid var(--border);
  border-radius: var(--r-lg);
  box-shadow: var(--sh-lg);
  padding: var(--s-2);
  opacity: 0; visibility: hidden;
  transform: translateY(-6px);
  transition: all var(--med) var(--ease);
  z-index: 200;
  list-style: none;
}
.nav-has-drop:hover .nav-drop,
.nav-has-drop:focus-within .nav-drop {
  opacity: 1; visibility: visible; transform: translateY(0);
}
.nav-drop a {
  display: block; padding: var(--s-3) var(--s-4);
  font-size: var(--t-sm); color: var(--text-2);
  border-radius: var(--r-md);
}
.nav-drop a:hover { background: var(--bg-muted); color: var(--accent); }

/* Header right */
.header-right {
  display: flex; align-items: center;
  gap: var(--s-2); flex-shrink: 0;
}
/* Shorten emergency label on tiny screens */
.header-right .btn .long  { display: none; }
.header-right .btn .short { display: inline; }
@media (min-width: 420px) {
  .header-right .btn .long  { display: inline; }
  .header-right .btn .short { display: none; }
}

/* Hamburger */
.menu-btn {
  display: flex; flex-direction: column; justify-content: center;
  gap: 5px; width: 44px; height: 44px;
  padding: var(--s-2); border-radius: var(--r-md);
  transition: background var(--fast);
}
.menu-btn:hover { background: var(--bg-muted); }
.menu-btn span {
  display: block; width: 22px; height: 2px;
  background: var(--text); border-radius: 1px;
  transition: all var(--med) var(--ease);
  transform-origin: center;
}
.menu-btn.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.menu-btn.open span:nth-child(2) { opacity: 0; transform: scaleX(0); }
.menu-btn.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }
@media (min-width: 768px) { .menu-btn { display: none; } }

/* ── Mobile drawer ────────────────────────────────────────────── */
.drawer-mask {
  display: none;
  position: fixed; inset: 0; z-index: 98;
}
.drawer-mask.open { display: block; }

.drawer-bg {
  position: absolute; inset: 0;
  background: rgba(53,41,32,.45);
  backdrop-filter: blur(3px);
  animation: fade-in var(--med) var(--ease) both;
}
.drawer-panel {
  position: absolute; top: 0; right: 0; bottom: 0;
  width: min(340px, 88vw);
  background: var(--bg-surface);
  box-shadow: var(--sh-xl);
  overflow-y: auto; -webkit-overflow-scrolling: touch;
  padding: calc(var(--header-h) + var(--s-4)) var(--s-4) var(--s-8);
  animation: slide-in var(--med) var(--ease) both;
}
@keyframes fade-in  { from { opacity: 0; }               to { opacity: 1; } }
@keyframes slide-in { from { transform: translateX(100%); } to { transform: translateX(0); } }

.drawer-nav { list-style: none; padding: 0; margin: 0; }
.drawer-nav li { border-bottom: 1px solid var(--border); }
.drawer-nav li:last-child { border-bottom: none; }
.drawer-nav a {
  display: flex; align-items: center; justify-content: space-between;
  min-height: 52px; padding: var(--s-4) var(--s-2);
  font-size: var(--t-base); font-weight: 500; color: var(--text);
  border-radius: var(--r-md);
  transition: background var(--fast);
}
.drawer-nav a:hover, .drawer-nav a[aria-current="page"] {
  background: var(--bg-muted); color: var(--accent);
}
.drawer-subnav { list-style: none; padding: 0 0 var(--s-2) var(--s-5); margin: 0; }
.drawer-subnav a { font-size: var(--t-sm); color: var(--text-2); min-height: 40px; padding: var(--s-2) var(--s-2); }
.drawer-ctas { display: flex; flex-direction: column; gap: var(--s-3); margin-top: var(--s-6); }
body.nav-open { overflow: hidden; }

/* ════════════════════════════════════════════════════════════
   HERO
   ════════════════════════════════════════════════════════════ */
.hero {
  padding-block: var(--s-12) var(--s-16);
  position: relative; overflow: hidden;
}
.hero::before {
  content: '';
  position: absolute; inset: 0; pointer-events: none;
  background:
    radial-gradient(ellipse 80% 70% at 65% 40%, var(--c-sage-2xl), transparent 65%),
    radial-gradient(ellipse 50% 50% at 85% 85%, var(--c-amber-lt), transparent 55%);
}
@media (min-width: 768px) { .hero { padding-block: var(--s-20) var(--s-20); } }

.hero-grid {
  position: relative;
  display: flex; flex-direction: column; gap: var(--s-10);
}
@media (min-width: 768px) {
  .hero-grid {
    display: grid; grid-template-columns: 1fr 1fr;
    gap: var(--s-12); align-items: center;
  }
}
@media (min-width: 1024px) { .hero-grid { gap: var(--s-16); } }

.hero-content { display: flex; flex-direction: column; gap: 0; }
.hero-eyebrow { margin-bottom: var(--s-4); }
.hero-title {
  font-size: var(--t-6xl);
  margin-bottom: var(--s-5); letter-spacing: -.02em;
}
.hero-title em { color: var(--c-sage); font-style: italic; }
.hero-body {
  font-size: clamp(var(--t-base), 2vw, var(--t-lg));
  color: var(--text-2); font-weight: 300;
  margin-bottom: var(--s-7); line-height: 1.7;
}
.hero-actions {
  display: flex; flex-wrap: wrap; gap: var(--s-3);
  margin-bottom: var(--s-8);
}
@media (max-width: 380px) {
  .hero-actions { flex-direction: column; }
  .hero-actions .btn { width: 100%; }
}

/* Stats */
.hero-stats {
  display: grid; grid-template-columns: repeat(3, 1fr);
  gap: var(--s-4);
  padding-top: var(--s-6); border-top: 1px solid var(--border);
}
.stat-num {
  display: block;
  font-family: var(--f-display);
  font-size: clamp(1.5rem, 4vw, var(--t-4xl));
  color: var(--accent); line-height: 1;
}
.stat-lbl {
  display: block;
  font-size: clamp(10px, 2.2vw, var(--t-xs));
  color: var(--text-3); margin-top: 3px; line-height: 1.3;
}

/* Hero image — hidden on mobile */
.hero-img {
  display: none;
  border-radius: var(--r-xl); overflow: hidden;
  aspect-ratio: 4/5; background: var(--c-sage-xl);
  position: relative;
}
@media (min-width: 768px) { .hero-img { display: block; } }
.hero-img img { width: 100%; height: 100%; object-fit: cover; }
.hero-img-badge {
  position: absolute; bottom: var(--s-4); left: var(--s-4);
  right: var(--s-4);
  background: rgba(249,247,242,.95); backdrop-filter: blur(8px);
  border-radius: var(--r-lg); padding: var(--s-3) var(--s-4);
  box-shadow: var(--sh-lg);
}
.hero-img-badge strong { display: block; font-size: var(--t-sm); }
.hero-img-badge span   { display: block; font-size: var(--t-xs); color: var(--text-3); }

/* ── Trust bar ─────────────────────────────────────────────── */
.trust-bar {
  background: var(--bg-surface);
  border-block: 1px solid var(--border);
  padding-block: var(--s-4);
  overflow-x: auto; -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
}
.trust-bar::-webkit-scrollbar { display: none; }
.trust-inner {
  display: flex; flex-wrap: nowrap; align-items: center;
  gap: var(--s-6); padding-inline: var(--gutter);
  min-width: max-content;
}
@media (min-width: 700px) {
  .trust-inner {
    flex-wrap: wrap; min-width: unset;
    justify-content: center; gap: var(--s-8);
    padding-inline: 0;
  }
  .trust-bar { overflow-x: visible; }
}
.trust-item {
  display: flex; align-items: center; gap: var(--s-2);
  font-size: var(--t-sm); font-weight: 500;
  color: var(--text-3); white-space: nowrap; flex-shrink: 0;
}
.trust-icon {
  width: 32px; height: 32px; flex-shrink: 0;
  background: var(--bg-accent); border-radius: var(--r-md);
  display: flex; align-items: center; justify-content: center;
  font-size: 16px;
}

/* ════════════════════════════════════════════════════════════
   DIRECTORY SEARCH
   ════════════════════════════════════════════════════════════ */
.dir-search {
  background: var(--bg-surface);
  border: 1px solid var(--border);
  border-radius: var(--r-2xl); padding: var(--s-6);
  box-shadow: var(--sh-lg);
}
@media (min-width: 640px) { .dir-search { padding: var(--s-8); } }

.dir-search-head {
  display: flex; justify-content: space-between;
  align-items: flex-start; flex-wrap: wrap;
  gap: var(--s-3); margin-bottom: var(--s-5);
}
.dir-search-head h2 { font-size: var(--t-4xl); margin-bottom: var(--s-1); }
.dir-search-head p  { font-size: var(--t-sm); color: var(--text-3); margin: 0; }

.dir-search-form {
  display: flex; flex-direction: column; gap: var(--s-3);
}
@media (min-width: 600px) {
  .dir-search-form {
    display: grid; grid-template-columns: 1fr 1fr auto; align-items: start;
  }
}
@media (min-width: 1024px) {
  .dir-search-form { grid-template-columns: 1fr 200px auto; }
}

.search-field {
  position: relative;
}
.search-field-icon {
  position: absolute; left: var(--s-4); top: 50%;
  transform: translateY(-50%);
  font-size: 15px; color: var(--text-3); pointer-events: none;
}
.search-field input {
  width: 100%;
  padding: .875rem var(--s-4) .875rem 2.5rem;
  border: 1.5px solid var(--border);
  border-radius: var(--r-lg);
  background: var(--bg);
  min-height: 48px;
  transition: border-color var(--fast);
}
.search-field input:focus {
  outline: none;
  border-color: var(--c-sage-lt);
  box-shadow: 0 0 0 3px rgba(141,175,155,.18);
}
.dir-search-form .btn-primary { min-height: 48px; width: 100%; }
@media (min-width: 600px) { .dir-search-form .btn-primary { width: auto; align-self: stretch; } }

.dir-quick {
  display: flex; flex-wrap: wrap; align-items: center;
  gap: var(--s-2);
  margin-top: var(--s-4); padding-top: var(--s-4);
  border-top: 1px solid var(--border);
}
.dir-quick-lbl { font-size: var(--t-xs); font-weight: 600; color: var(--text-3); }

/* ════════════════════════════════════════════════════════════
   CARDS
   ════════════════════════════════════════════════════════════ */
.card {
  display: flex; flex-direction: column;
  background: var(--bg-surface);
  border: 1px solid var(--border);
  border-radius: var(--r-xl);
  overflow: hidden;
  transition: transform var(--med) var(--ease),
              box-shadow var(--med) var(--ease),
              border-color var(--med) var(--ease);
}
@media (hover: hover) {
  .card:hover {
    transform: translateY(-4px);
    box-shadow: var(--sh-xl);
    border-color: var(--border-2);
  }
}

.card-img {
  aspect-ratio: 16/9; overflow: hidden;
  background: var(--bg-muted); flex-shrink: 0;
}
.card-img img {
  width: 100%; height: 100%; object-fit: cover;
  transition: transform var(--slow) var(--ease);
}
@media (hover: hover) { .card:hover .card-img img { transform: scale(1.04); } }

.card-body { padding: var(--s-5); flex: 1; display: flex; flex-direction: column; }
@media (min-width: 640px) { .card-body { padding: var(--s-6); } }

.card-meta {
  display: flex; align-items: center; flex-wrap: wrap;
  gap: var(--s-2); margin-bottom: var(--s-3);
  font-size: var(--t-xs); color: var(--text-3);
}
.card-cat {
  font-size: var(--t-xs); font-weight: 700;
  text-transform: uppercase; letter-spacing: .07em;
  color: var(--accent); text-decoration: none;
}
.card-cat:hover { color: var(--accent-h); }

.card-title {
  font-family: var(--f-display);
  font-size: clamp(var(--t-lg), 2vw, var(--t-xl));
  line-height: 1.3; font-weight: 400;
  color: var(--text); margin-bottom: var(--s-3);
  text-decoration: none; display: block;
}
.card-title:hover { color: var(--accent); }

.card-excerpt {
  font-size: var(--t-sm); color: var(--text-2);
  line-height: 1.65; margin-bottom: var(--s-4);
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
  flex: 1;
}

.card-foot {
  display: flex; align-items: center; justify-content: space-between;
  padding: var(--s-3) var(--s-5); flex-wrap: wrap; gap: var(--s-2);
  border-top: 1px solid var(--border);
}
@media (min-width: 640px) { .card-foot { padding: var(--s-4) var(--s-6); } }

.card-author {
  display: flex; align-items: center; gap: var(--s-2);
  text-decoration: none; min-width: 0;
}
.card-avatar {
  width: 28px; height: 28px; border-radius: 50%;
  overflow: hidden; background: var(--c-sage-xl); flex-shrink: 0;
}
.card-avatar img { width: 100%; height: 100%; object-fit: cover; }
.card-author-name {
  font-size: var(--t-xs); font-weight: 600; color: var(--text-2);
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.card-time { font-size: var(--t-xs); color: var(--text-3); white-space: nowrap; }

/* Featured card */
.card-featured { grid-column: 1 / -1; }
@media (min-width: 768px) {
  .card-featured {
    display: grid; grid-template-columns: 1fr 1fr;
    flex-direction: unset;
  }
  .card-featured .card-img { aspect-ratio: unset; min-height: 260px; }
  .card-featured .card-body { justify-content: center; padding: var(--s-8); }
  .card-featured .card-title { font-size: clamp(var(--t-xl), 2.5vw, var(--t-3xl)); }
}

/* Blog grid */
.blog-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--s-5);
}
@media (min-width: 580px) {
  .blog-grid { grid-template-columns: repeat(2, 1fr); gap: var(--s-6); }
}
@media (min-width: 1024px) {
  .blog-grid { grid-template-columns: repeat(3, 1fr); gap: var(--s-8); }
}

/* Category cards */
.cat-card {
  display: block; text-decoration: none;
  background: var(--bg-surface); border: 1px solid var(--border);
  border-radius: var(--r-xl); padding: var(--s-5) var(--s-4);
  text-align: center;
  transition: all var(--med) var(--ease);
}
@media (hover: hover) {
  .cat-card:hover {
    transform: translateY(-3px); box-shadow: var(--sh-lg);
    border-color: var(--c-sage-lt); background: var(--bg-accent);
  }
}
.cat-card-icon {
  width: 52px; height: 52px;
  background: var(--bg-accent); border-radius: var(--r-xl);
  display: flex; align-items: center; justify-content: center;
  font-size: 26px; margin: 0 auto var(--s-3);
}
.cat-card-title { font-size: var(--t-sm); font-weight: 600; color: var(--text); margin-bottom: var(--s-1); }
.cat-card-count { font-size: var(--t-xs); color: var(--text-3); }

.cat-grid {
  display: grid; grid-template-columns: repeat(2, 1fr); gap: var(--s-4);
}
@media (min-width: 580px) { .cat-grid { grid-template-columns: repeat(3, 1fr); } }
@media (min-width: 1024px) { .cat-grid { grid-template-columns: repeat(4, 1fr); gap: var(--s-5); } }

/* Expert cards */
.expert-card {
  background: var(--bg-surface); border: 1px solid var(--border);
  border-radius: var(--r-xl); padding: var(--s-6);
  text-align: center;
  transition: all var(--med) var(--ease);
}
@media (hover: hover) { .expert-card:hover { transform: translateY(-4px); box-shadow: var(--sh-lg); } }
.expert-avatar {
  width: 80px; height: 80px; border-radius: 50%;
  overflow: hidden; background: var(--c-sage-xl);
  margin: 0 auto var(--s-4);
  border: 3px solid var(--bg); box-shadow: var(--sh-md);
}
.expert-avatar img { width: 100%; height: 100%; object-fit: cover; }
.expert-name  { font-size: var(--t-xl); font-weight: 600; margin-bottom: var(--s-1); }
.expert-creds { font-size: var(--t-sm); color: var(--accent); font-weight: 600; margin-bottom: var(--s-2); }
.expert-spec  { font-size: var(--t-sm); color: var(--text-3); margin-bottom: var(--s-4); }

.expert-grid {
  display: grid; grid-template-columns: 1fr; gap: var(--s-5);
}
@media (min-width: 480px) { .expert-grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1024px) { .expert-grid { grid-template-columns: repeat(4, 1fr); } }

/* Testimonials */
.testi {
  background: var(--bg-surface); border: 1px solid var(--border);
  border-radius: var(--r-xl); padding: var(--s-6);
  position: relative;
}
.testi::before {
  content: '"';
  font-family: var(--f-display); font-size: 72px; line-height: 1;
  color: var(--c-sage-xl);
  position: absolute; top: var(--s-3); left: var(--s-5);
  pointer-events: none;
}
.testi-stars { display: flex; gap: 2px; color: var(--c-amber); margin-bottom: var(--s-4); font-size: 14px; }
.testi-body { font-style: italic; color: var(--text-2); line-height: 1.7; margin-bottom: var(--s-5); position: relative; }
.testi-author { display: flex; align-items: center; gap: var(--s-3); }
.testi-avi { width: 40px; height: 40px; border-radius: 50%; background: var(--c-sage-xl); overflow: hidden; flex-shrink: 0; }
.testi-name { font-weight: 600; font-size: var(--t-sm); }
.testi-role { font-size: var(--t-xs); color: var(--text-3); }

.testi-grid { display: grid; grid-template-columns: 1fr; gap: var(--s-5); }
@media (min-width: 600px) { .testi-grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1024px) { .testi-grid { grid-template-columns: repeat(3, 1fr); } }

/* ════════════════════════════════════════════════════════════
   SECTION HEADER
   ════════════════════════════════════════════════════════════ */
.sec-head { margin-bottom: var(--s-8); }
.sec-head-center {
  text-align: center; max-width: 600px;
  margin-inline: auto; margin-bottom: var(--s-10);
}
.sec-head .eyebrow { display: block; margin-bottom: var(--s-3); }
.sec-head h2 { margin-bottom: var(--s-4); }
.sec-head .lead { margin: 0; }

/* ════════════════════════════════════════════════════════════
   POST / SINGLE LAYOUT
   ════════════════════════════════════════════════════════════ */
.post-layout {
  display: flex; flex-direction: column; gap: var(--s-10);
  max-width: 1080px; margin-inline: auto;
}
@media (min-width: 1024px) {
  .post-layout {
    display: grid; grid-template-columns: 1fr 300px;
    gap: var(--s-12); align-items: start;
  }
}

.post-header {
  padding-block: var(--s-10) var(--s-6);
  background: linear-gradient(to bottom, var(--bg-muted), var(--bg));
}
@media (min-width: 768px) { .post-header { padding-block: var(--s-16) var(--s-8); } }

.post-hero {
  border-radius: var(--r-lg); overflow: hidden;
  aspect-ratio: 16/9; background: var(--bg-muted);
  margin-bottom: var(--s-8);
}
@media (min-width: 768px) {
  .post-hero { aspect-ratio: 21/9; border-radius: var(--r-xl); margin-bottom: var(--s-12); }
}
.post-hero img { width: 100%; height: 100%; object-fit: cover; }

.post-meta {
  display: flex; align-items: center; flex-wrap: wrap;
  gap: var(--s-2); margin-bottom: var(--s-4);
  font-size: var(--t-sm); color: var(--text-3);
}
.post-meta-sep { color: var(--border-2); }

.post-title {
  font-size: clamp(var(--t-3xl), 5vw, var(--t-5xl));
  margin-bottom: var(--s-5); letter-spacing: -.02em; line-height: 1.15;
}
.post-subtitle {
  font-size: clamp(var(--t-base), 2vw, var(--t-xl));
  color: var(--text-2); font-weight: 300; line-height: 1.55;
  margin-bottom: var(--s-6);
}

/* Author box */
.author-box {
  display: flex; flex-direction: column; gap: var(--s-4);
  background: var(--bg-muted); border-radius: var(--r-xl);
  padding: var(--s-5); margin-bottom: var(--s-6);
}
@media (min-width: 480px) {
  .author-box { flex-direction: row; align-items: flex-start; gap: var(--s-5); padding: var(--s-6); }
}
.author-box-avi {
  width: 64px; height: 64px; border-radius: 50%;
  overflow: hidden; flex-shrink: 0; background: var(--c-sage-xl);
  align-self: flex-start;
}
@media (min-width: 480px) { .author-box-avi { width: 72px; height: 72px; } }
.author-box-avi img { width: 100%; height: 100%; object-fit: cover; }
.author-box-name  { font-weight: 700; font-size: var(--t-base); display: block; margin-bottom: var(--s-1); }
.author-box-creds { font-size: var(--t-sm); color: var(--accent); font-weight: 600; display: block; margin-bottom: var(--s-2); }
.author-box-bio   { font-size: var(--t-sm); color: var(--text-2); line-height: 1.65; }

/* Post content typography */
.post-content {
  font-size: clamp(var(--t-base), 1.5vw, var(--t-lg));
  line-height: 1.85; color: var(--text);
  word-break: break-word; overflow-wrap: break-word;
}
.post-content h2 {
  font-size: clamp(var(--t-2xl), 3.5vw, var(--t-3xl));
  margin-top: var(--s-12); margin-bottom: var(--s-4);
  padding-bottom: var(--s-3); border-bottom: 1px solid var(--border);
  scroll-margin-top: calc(var(--header-h) + 16px);
}
.post-content h3 {
  font-size: clamp(var(--t-xl), 2.5vw, var(--t-2xl));
  margin-top: var(--s-10); margin-bottom: var(--s-3);
  scroll-margin-top: calc(var(--header-h) + 16px);
}
.post-content h4 {
  font-size: clamp(var(--t-lg), 2vw, var(--t-xl));
  margin-top: var(--s-8); margin-bottom: var(--s-3);
  font-family: var(--f-body); font-weight: 700;
  scroll-margin-top: calc(var(--header-h) + 16px);
}
.post-content p { margin-bottom: var(--s-5); }
.post-content ul, .post-content ol {
  margin-bottom: var(--s-5); padding-left: var(--s-6);
}
@media (min-width: 480px) {
  .post-content ul, .post-content ol { padding-left: var(--s-8); }
}
.post-content li { margin-bottom: var(--s-2); }
.post-content a {
  color: var(--accent); text-decoration: underline;
  text-underline-offset: 3px; text-decoration-color: var(--c-sage-xl);
}
.post-content a:hover { text-decoration-color: var(--c-sage-lt); }
.post-content img { border-radius: var(--r-lg); margin-block: var(--s-6); width: 100%; }
.post-content strong { font-weight: 700; }

/* Tables */
.post-content .table-wrap {
  overflow-x: auto; -webkit-overflow-scrolling: touch;
  margin-block: var(--s-6);
  border-radius: var(--r-lg); border: 1px solid var(--border);
}
.post-content table {
  width: 100%; min-width: 500px; border-collapse: collapse;
  font-size: var(--t-sm);
  display: table; /* override global */
}
.post-content th {
  background: var(--bg-muted); padding: var(--s-3) var(--s-4);
  text-align: left; font-weight: 700; font-size: var(--t-xs);
  color: var(--text-2); border-bottom: 2px solid var(--border-2);
  white-space: nowrap;
}
.post-content td {
  padding: var(--s-3) var(--s-4); border-bottom: 1px solid var(--border);
  color: var(--text-2);
}
.post-content tr:last-child td { border-bottom: none; }
@media (hover: hover) { .post-content tr:hover td { background: var(--bg-muted); } }

/* Callouts */
.callout {
  display: flex; gap: var(--s-3);
  border-radius: var(--r-lg);
  padding: var(--s-4) var(--s-5); margin-block: var(--s-6);
  font-size: var(--t-sm);
}
@media (min-width: 480px) { .callout { gap: var(--s-4); font-size: var(--t-base); } }
.callout-icon { font-size: 20px; flex-shrink: 0; line-height: 1.5; }
.callout-title { font-weight: 700; font-size: var(--t-sm); margin-bottom: var(--s-1); }
.callout-body  { font-size: var(--t-sm); color: var(--text-2); line-height: 1.65; }
.callout-body p:last-child { margin-bottom: 0; }
.callout-info    { background: var(--bg-accent);    border-left: 3px solid var(--c-sage-lt); }
.callout-info .callout-title    { color: var(--c-forest); }
.callout-warning { background: var(--c-amber-lt);   border-left: 3px solid var(--c-amber); }
.callout-warning .callout-title { color: #7a4e18; }
.callout-alert   { background: var(--c-rust-lt);    border-left: 3px solid var(--c-rust); }
.callout-alert .callout-title   { color: var(--c-rust); }
.callout-tip     { background: var(--bg-muted);      border-left: 3px solid var(--c-stone); }

/* TOC */
.toc {
  background: var(--bg-muted); border: 1px solid var(--border);
  border-radius: var(--r-lg); padding: var(--s-5) var(--s-6);
  margin-block: var(--s-6);
}
.toc-title {
  font-size: var(--t-xs); font-weight: 700;
  text-transform: uppercase; letter-spacing: .08em;
  color: var(--text-3); margin-bottom: var(--s-4);
}
.toc-list { list-style: none; padding: 0; margin: 0; counter-reset: toc; }
.toc-list li { counter-increment: toc; margin-bottom: var(--s-1); }
.toc-list a {
  display: flex; align-items: center; gap: var(--s-2);
  font-size: var(--t-sm); color: var(--text-2);
  padding: var(--s-2) var(--s-3); border-radius: var(--r-md);
  min-height: 40px; text-decoration: none;
  transition: all var(--fast) var(--ease);
}
.toc-list a::before {
  content: counter(toc, decimal-leading-zero);
  font-size: var(--t-xs); font-weight: 700; font-family: var(--f-mono);
  color: var(--text-3); min-width: 22px; flex-shrink: 0;
}
.toc-list a:hover, .toc-list a.active {
  background: var(--bg-surface); color: var(--accent);
}
.toc-list a.active { font-weight: 600; }

/* Share bar */
.share-bar {
  display: flex; align-items: center; flex-wrap: wrap;
  gap: var(--s-2); padding-block: var(--s-5);
  border-block: 1px solid var(--border); margin-block: var(--s-10);
}
.share-label { font-size: var(--t-sm); font-weight: 600; color: var(--text-2); }
.share-btn {
  display: inline-flex; align-items: center; gap: var(--s-2);
  padding: .375rem .75rem; min-height: 36px;
  font-size: var(--t-xs); font-weight: 500;
  border-radius: var(--r-full); border: 1px solid var(--border-2);
  color: var(--text-2); background: var(--bg-surface);
  transition: all var(--fast) var(--ease); text-decoration: none;
  touch-action: manipulation;
}
.share-btn:hover { background: var(--bg-muted); color: var(--text); }
.share-btn.copied { background: var(--c-sage-xl); color: var(--c-forest); border-color: var(--c-sage-lt); }

/* Disclaimer */
.disclaimer {
  background: var(--bg-muted); border-radius: var(--r-lg);
  padding: var(--s-4) var(--s-5); margin-top: var(--s-8);
  font-size: var(--t-sm); color: var(--text-2); line-height: 1.65;
  border-left: 3px solid var(--c-stone);
}
.disclaimer strong { color: var(--text); }

/* ════════════════════════════════════════════════════════════
   SIDEBAR
   ════════════════════════════════════════════════════════════ */
.sidebar {}
@media (min-width: 1024px) {
  .sidebar {
    position: sticky;
    top: calc(var(--header-h) + 16px);
    max-height: calc(100vh - var(--header-h) - 32px);
    overflow-y: auto; -webkit-overflow-scrolling: touch;
  }
}

.widget-box {
  background: var(--bg-surface); border: 1px solid var(--border);
  border-radius: var(--r-xl); padding: var(--s-5);
  margin-bottom: var(--s-4);
}
@media (min-width: 480px) { .widget-box { padding: var(--s-6); } }
.widget-title {
  font-size: var(--t-xs); font-weight: 700;
  text-transform: uppercase; letter-spacing: .1em;
  color: var(--text-3); margin-bottom: var(--s-4);
  padding-bottom: var(--s-3); border-bottom: 1px solid var(--border);
}

/* Recent post row in sidebar */
.widget-post {
  display: flex; gap: var(--s-3);
  padding-block: var(--s-3); border-bottom: 1px solid var(--border);
  text-decoration: none;
}
.widget-post:last-child { border-bottom: none; padding-bottom: 0; }
.widget-post-thumb {
  width: 60px; height: 60px; border-radius: var(--r-md);
  overflow: hidden; background: var(--bg-muted); flex-shrink: 0;
}
.widget-post-thumb img { width: 100%; height: 100%; object-fit: cover; }
.widget-post-title {
  font-size: var(--t-sm); font-weight: 500; color: var(--text);
  line-height: 1.4; margin-bottom: var(--s-1);
}
.widget-post:hover .widget-post-title { color: var(--accent); }
.widget-post-date { font-size: var(--t-xs); color: var(--text-3); }

/* Emergency widget */
.widget-emergency {
  background: var(--c-rust-lt); border-color: var(--c-rust);
}
.widget-emergency .widget-title { color: var(--c-rust); }

/* Newsletter widget */
.widget-newsletter {
  background: var(--accent); border-color: var(--accent);
  overflow: hidden; position: relative;
}
.widget-newsletter::before {
  content: ''; position: absolute; top: -30%; right: -20%;
  width: 180px; height: 180px;
  background: rgba(255,255,255,.06); border-radius: 50%;
  pointer-events: none;
}
.widget-newsletter .widget-title { color: rgba(255,255,255,.65); border-color: rgba(255,255,255,.15); }
.nl-head { font-family: var(--f-display); font-size: var(--t-2xl); color: #fff; margin-bottom: var(--s-2); }
.nl-body { font-size: var(--t-sm); color: rgba(255,255,255,.8); margin-bottom: var(--s-5); line-height: 1.6; }
.nl-form { display: flex; flex-direction: column; gap: var(--s-3); }
.nl-input {
  width: 100%; padding: .75rem var(--s-4); min-height: 46px;
  border-radius: var(--r-full); border: none; font-size: var(--t-sm);
  background: rgba(255,255,255,.15); color: #fff;
}
.nl-input::placeholder { color: rgba(255,255,255,.55); }
.nl-input:focus { outline: none; background: rgba(255,255,255,.25); }

/* ════════════════════════════════════════════════════════════
   FAQ
   ════════════════════════════════════════════════════════════ */
.faq-item {
  border-bottom: 1px solid var(--border); padding-block: var(--s-4);
}
.faq-item:first-child { border-top: 1px solid var(--border); }
@media (min-width: 480px) { .faq-item { padding-block: var(--s-5); } }
.faq-q {
  width: 100%; text-align: left; background: none; border: none;
  display: flex; justify-content: space-between; align-items: flex-start;
  gap: var(--s-4); cursor: pointer;
  font-family: var(--f-body); font-size: clamp(var(--t-base), 2vw, var(--t-lg));
  font-weight: 600; color: var(--text); line-height: 1.4;
  padding: 0; min-height: 44px;
  touch-action: manipulation;
}
.faq-q::after {
  content: '+'; font-size: var(--t-2xl); font-weight: 300;
  color: var(--accent); flex-shrink: 0; line-height: 1;
  transition: transform var(--med) var(--ease);
}
.faq-item.open .faq-q::after { transform: rotate(45deg); }
.faq-a {
  font-size: var(--t-base); color: var(--text-2); line-height: 1.75;
  overflow: hidden; max-height: 0;
  transition: max-height var(--med) var(--ease), padding-top var(--med);
}
.faq-item.open .faq-a { max-height: 600px; padding-top: var(--s-3); }

/* ════════════════════════════════════════════════════════════
   PAGINATION
   ════════════════════════════════════════════════════════════ */
.pagination {
  display: flex; align-items: center; justify-content: center;
  flex-wrap: wrap; gap: var(--s-2); margin-top: var(--s-10);
}
.pagination .page-numbers {
  display: flex; align-items: center; justify-content: center;
  width: 40px; height: 40px; min-height: 40px;
  border-radius: var(--r-md); font-size: var(--t-sm); font-weight: 500;
  text-decoration: none; color: var(--text-2);
  border: 1px solid var(--border); background: var(--bg-surface);
  transition: all var(--fast) var(--ease);
}
.pagination .page-numbers:hover { border-color: var(--accent); color: var(--accent); }
.pagination .page-numbers.current { background: var(--accent); border-color: var(--accent); color: #fff; }
.pagination .page-numbers.dots { border: none; background: none; width: auto; }
.pagination .prev, .pagination .next { width: auto; padding-inline: var(--s-4); }

/* ════════════════════════════════════════════════════════════
   BREADCRUMB
   ════════════════════════════════════════════════════════════ */
.breadcrumb {
  display: flex; align-items: center; flex-wrap: wrap;
  gap: var(--s-2); margin-bottom: var(--s-5);
  font-size: var(--t-sm); color: var(--text-3);
  list-style: none; padding: 0;
}
.breadcrumb li + li::before { content: '›'; margin-right: var(--s-2); color: var(--border-2); }
.breadcrumb a { color: var(--text-3); text-decoration: none; }
.breadcrumb a:hover { color: var(--accent); }

/* ════════════════════════════════════════════════════════════
   NEWSLETTER section
   ════════════════════════════════════════════════════════════ */
.nl-section {
  background: var(--accent); border-radius: var(--r-2xl);
  padding: var(--s-10) var(--s-6); text-align: center;
  color: #fff; position: relative; overflow: hidden;
  max-width: var(--max-w-text); margin-inline: auto;
}
@media (min-width: 640px) { .nl-section { padding: var(--s-12) var(--s-10); } }
.nl-section::before {
  content: ''; position: absolute; inset: 0;
  background:
    radial-gradient(ellipse 70% 80% at 20% 20%, rgba(255,255,255,.06), transparent),
    radial-gradient(ellipse 60% 60% at 80% 90%, rgba(255,255,255,.04), transparent);
  pointer-events: none;
}
.nl-section h2 { font-family: var(--f-display); font-size: var(--t-4xl); color: #fff; margin-bottom: var(--s-3); position: relative; }
.nl-section p  { color: rgba(255,255,255,.8); margin-bottom: var(--s-6); position: relative; }
.nl-section form { display: flex; flex-direction: column; gap: var(--s-3); position: relative; }
@media (min-width: 480px) { .nl-section form { flex-direction: row; } }
.nl-section input {
  flex: 1; padding: .875rem var(--s-4); min-height: 50px;
  border-radius: var(--r-full); border: none; font-size: var(--t-base);
  background: rgba(255,255,255,.15); color: #fff;
}
.nl-section input::placeholder { color: rgba(255,255,255,.55); }
.nl-section input:focus { outline: 2px solid rgba(255,255,255,.4); outline-offset: 2px; background: rgba(255,255,255,.22); }
.nl-section .btn-amber { min-height: 50px; }
.nl-section small { display: block; color: rgba(255,255,255,.45); font-size: var(--t-xs); margin-top: var(--s-3); position: relative; }

/* ════════════════════════════════════════════════════════════
   COMMENTS
   ════════════════════════════════════════════════════════════ */
.comment-list { list-style: none; padding: 0; margin: 0; }
.comment { margin-bottom: var(--s-5); padding-bottom: var(--s-5); border-bottom: 1px solid var(--border); }
.comment:last-child { border-bottom: none; }
.comment-wrap { display: grid; grid-template-columns: 44px 1fr; gap: var(--s-3); }
@media (min-width: 480px) { .comment-wrap { grid-template-columns: 48px 1fr; gap: var(--s-4); } }
.comment-avi { width: 44px; height: 44px; border-radius: 50%; overflow: hidden; background: var(--c-sage-xl); }
.comment-avi img { width: 100%; height: 100%; object-fit: cover; }
.comment-author { font-weight: 600; font-size: var(--t-sm); margin-bottom: var(--s-1); }
.comment-date   { font-size: var(--t-xs); color: var(--text-3); margin-bottom: var(--s-2); }
.comment-body   { font-size: var(--t-sm); color: var(--text-2); line-height: 1.7; }

/* Comment form */
.comment-form-wrap { margin-top: var(--s-10); }
.form-group { margin-bottom: var(--s-4); }
.form-label { display: block; font-size: var(--t-sm); font-weight: 600; color: var(--text-2); margin-bottom: var(--s-2); }
.form-control {
  width: 100%; padding: .75rem var(--s-4); min-height: 48px;
  border: 1.5px solid var(--border); border-radius: var(--r-lg);
  background: var(--bg-surface); color: var(--text);
  font-size: var(--t-base);
  transition: border-color var(--fast);
}
.form-control:focus { outline: none; border-color: var(--c-sage-lt); box-shadow: 0 0 0 3px rgba(141,175,155,.18); }
textarea.form-control { resize: vertical; min-height: 120px; }
.form-row { display: flex; flex-direction: column; gap: var(--s-4); }
@media (min-width: 640px) { .form-row { flex-direction: row; } .form-row .form-group { flex: 1; } }

/* ════════════════════════════════════════════════════════════
   FOOTER
   ════════════════════════════════════════════════════════════ */
.site-footer {
  background: var(--c-espresso); color: rgba(255,255,255,.65);
  padding-top: var(--s-12); padding-bottom: var(--s-8);
  margin-top: var(--s-16);
}
@media (min-width: 768px) { .site-footer { padding-top: var(--s-20); padding-bottom: var(--s-10); } }

.footer-grid {
  display: grid; grid-template-columns: 1fr;
  gap: var(--s-6); padding-bottom: var(--s-8);
  border-bottom: 1px solid rgba(255,255,255,.1);
  margin-bottom: var(--s-8);
}
@media (min-width: 480px) { .footer-grid { grid-template-columns: 1fr 1fr; gap: var(--s-8); } }
@media (min-width: 768px) { .footer-grid { grid-template-columns: 1fr 1fr 1fr; } }
@media (min-width: 1024px) { .footer-grid { grid-template-columns: 2fr 1fr 1fr 1fr; gap: var(--s-12); } }

.footer-brand-logo {
  font-family: var(--f-display); font-size: var(--t-2xl);
  color: #fff; display: block; margin-bottom: var(--s-4);
  text-decoration: none;
}
.footer-brand-desc { font-size: var(--t-sm); color: rgba(255,255,255,.55); line-height: 1.7; margin-bottom: var(--s-5); }
.footer-social { display: flex; gap: var(--s-2); flex-wrap: wrap; }
.footer-social a {
  width: 40px; height: 40px; min-height: 40px;
  border-radius: var(--r-md); background: rgba(255,255,255,.08);
  display: flex; align-items: center; justify-content: center;
  color: rgba(255,255,255,.65); font-size: 15px;
  text-decoration: none; transition: all var(--fast) var(--ease);
  touch-action: manipulation;
}
.footer-social a:hover { background: rgba(255,255,255,.15); color: #fff; }

/* Footer column accordion */
.footer-col-btn {
  width: 100%; display: flex; justify-content: space-between; align-items: center;
  background: none; border: none; cursor: pointer;
  font-size: var(--t-xs); font-weight: 700;
  text-transform: uppercase; letter-spacing: .1em;
  color: #fff; margin-bottom: var(--s-4); padding: 0;
}
.footer-col-btn .chevron {
  color: rgba(255,255,255,.45); font-size: 16px; line-height: 1;
  transition: transform var(--fast) var(--ease);
}
.footer-col-btn.open .chevron { transform: rotate(180deg); }
.footer-col-links { list-style: none; padding: 0; margin: 0; display: none; }
.footer-col-links.visible { display: block; }
@media (min-width: 480px) {
  .footer-col-btn { pointer-events: none; cursor: default; }
  .footer-col-btn .chevron { display: none; }
  .footer-col-links { display: block !important; }
}
.footer-col-links li { margin-bottom: var(--s-3); }
.footer-col-links a {
  font-size: var(--t-sm); color: rgba(255,255,255,.55);
  text-decoration: none; transition: color var(--fast);
  display: inline-block; min-height: 28px; line-height: 1.6;
}
.footer-col-links a:hover { color: #fff; }

.footer-bottom {
  display: flex; flex-direction: column; gap: var(--s-4);
  font-size: var(--t-xs); color: rgba(255,255,255,.35);
}
@media (min-width: 640px) { .footer-bottom { flex-direction: row; justify-content: space-between; align-items: center; } }
.footer-legal { display: flex; flex-wrap: wrap; gap: var(--s-4); }
.footer-legal a { color: rgba(255,255,255,.45); text-decoration: none; transition: color var(--fast); }
.footer-legal a:hover { color: #fff; }

/* ════════════════════════════════════════════════════════════
   WORDPRESS DEFAULTS — style them to match our theme
   ════════════════════════════════════════════════════════════ */
/* Suppress default sidebars */
#secondary, .widget-area:not(#blog-sidebar-widget-area):not(#directory-sidebar-widget-area) { display: none; }

/* Style WP widgets inside our sidebar */
.sidebar .widget { @apply widget-box; }
.sidebar .widget-title, .sidebar .widgettitle { @apply widget-title; }
.sidebar .widget_recent_entries ul,
.sidebar .widget_recent_comments ul,
.sidebar .widget_categories ul,
.sidebar .widget_archive ul {
  list-style: none; padding: 0; margin: 0;
}
.sidebar .widget_recent_entries li,
.sidebar .widget_categories li,
.sidebar .widget_archive li {
  padding-block: var(--s-2); border-bottom: 1px solid var(--border);
  font-size: var(--t-sm);
}
.sidebar .widget_recent_entries li:last-child,
.sidebar .widget_categories li:last-child { border-bottom: none; }
.sidebar .widget_recent_entries a,
.sidebar .widget_categories a,
.sidebar .widget_archive a,
.sidebar .widget_recent_comments a {
  color: var(--text-2); text-decoration: none;
}
.sidebar .widget_recent_entries a:hover,
.sidebar .widget_categories a:hover { color: var(--accent); }

/* WP alignments */
.aligncenter { display: block; margin-inline: auto; }
.alignright  { float: right; margin: 0 0 var(--s-4) var(--s-4); max-width: 50%; }
.alignleft   { float: left;  margin: 0 var(--s-4) var(--s-4) 0; max-width: 50%; }
@media (max-width: 480px) {
  .alignright, .alignleft { float: none; max-width: 100%; margin: var(--s-4) 0; }
}
.wp-caption-text { font-size: var(--t-sm); color: var(--text-3); font-style: italic; text-align: center; margin-top: var(--s-2); }
.wp-block-pullquote { border-block: 3px solid var(--accent); padding-block: var(--s-6); margin-block: var(--s-8); text-align: center; }

/* ════════════════════════════════════════════════════════════
   ANIMATIONS
   ════════════════════════════════════════════════════════════ */
@keyframes rise {
  from { opacity: 0; transform: translateY(18px); }
  to   { opacity: 1; transform: translateY(0); }
}
.rise      { animation: rise var(--slow) var(--ease) both; }
.rise-d1   { animation-delay: 80ms; }
.rise-d2   { animation-delay: 160ms; }
.rise-d3   { animation-delay: 240ms; }
.rise-d4   { animation-delay: 320ms; }

.reveal {
  opacity: 0; transform: translateY(14px);
  transition: opacity var(--slow) var(--ease), transform var(--slow) var(--ease);
}
.reveal.in { opacity: 1; transform: translateY(0); }

/* Respect motion preferences */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: .01ms !important;
    transition-duration: .01ms !important;
  }
  .reveal { opacity: 1; transform: none; }
}

/* ════════════════════════════════════════════════════════════
   PRINT
   ════════════════════════════════════════════════════════════ */
@media print {
  .site-header, .site-footer, .sidebar, .share-bar,
  .ahc-progress, .drawer-mask { display: none !important; }
  body { font-size: 12pt; color: #000; background: #fff; }
  .container { max-width: 100%; padding: 0; }
  .post-layout { display: block; }
}

/* =============================================================
   v4.1 fixes — applied after base styles
   ============================================================= */

/* ── Fix: single post full-width (no grey side borders) ─────── */
/* WordPress sometimes wraps content in narrow containers from
   the default/parent theme. Override everything to be full-width. */
body.is-single #page,
body.is-single #content,
body.is-single .site-content,
body.is-single .content-area,
body.is-single #primary,
body.is-single .entry-content,
body.is-single .post-inner,
body.is-single .entry-inner,
body.is-single main#main {
    max-width: 100% !important;
    width: 100% !important;
    margin: 0 !important;
    padding: 0 !important;
    float: none !important;
}

/* Ensure body itself fills viewport — no phantom margins */
body {
    min-width: 320px;
}

/* Remove any padding WP themes add to body */
body.is-single,
body.is-archive,
body.is-front {
    padding: 0 !important;
}

/* ── Fix: blog grid — prevent orphan last card being huge ────── */
/* When an odd card is alone in the last row on a 3-col grid,
   cap it so it doesn't span the full width */
.blog-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: var(--s-5);
}

@media (min-width: 580px) {
    .blog-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: var(--s-6);
    }
    /* Prevent featured card from being too tall in 2-col */
    .card-featured .card-img {
        min-height: 220px;
    }
}

@media (min-width: 1024px) {
    .blog-grid {
        grid-template-columns: repeat(3, 1fr);
        gap: var(--s-8);
    }
    .card-featured .card-img {
        min-height: 260px;
    }
}

/* ── Fix: hero stats always 3 columns, even on tiny screens ─── */
.hero-stats {
    display: grid !important;
    grid-template-columns: repeat(3, 1fr) !important;
}

/* ── Fix: post layout — column on mobile, sidebar on desktop ── */
.post-layout {
    display: flex;
    flex-direction: column;
    gap: var(--s-10);
    max-width: 1080px;
    margin-inline: auto;
}

@media (min-width: 1024px) {
    .post-layout {
        display: grid;
        grid-template-columns: 1fr 300px;
        gap: var(--s-12);
        align-items: start;
    }
}

/* ── Fix: trust bar always horizontal ───────────────────────── */
.trust-inner {
    display: flex !important;
    flex-direction: row !important;
    flex-wrap: nowrap !important;
    white-space: nowrap;
}

/* ── Fix: WP default widgets — style them in our sidebar ────── */
/* Suppress default WP secondary sidebar areas */
#secondary,
.widget-area[id]:not([id="blog-sidebar"]):not([id="directory-sidebar"]) {
    display: none !important;
}

/* Make default WP widgets look native */
.sidebar .widgettitle,
.sidebar .widget-title {
    font-size: var(--t-xs) !important;
    font-weight: 700 !important;
    text-transform: uppercase !important;
    letter-spacing: .1em !important;
    color: var(--text-3) !important;
    border-bottom: 1px solid var(--border);
    padding-bottom: var(--s-3);
    margin-bottom: var(--s-4) !important;
    font-family: var(--f-body) !important;
}

.sidebar .widget_recent_entries ul,
.sidebar .widget_recent_comments ul,
.sidebar .widget_categories ul,
.sidebar .widget_archive ul,
.sidebar .widget_pages ul,
.sidebar .widget_meta ul {
    list-style: none !important;
    padding: 0 !important;
    margin: 0 !important;
}

.sidebar .widget_recent_entries li,
.sidebar .widget_categories li,
.sidebar .widget_archive li,
.sidebar .widget_pages li {
    padding-block: var(--s-2) !important;
    border-bottom: 1px solid var(--border);
    font-size: var(--t-sm) !important;
}

.sidebar .widget_recent_entries li:last-child,
.sidebar .widget_categories li:last-child { border-bottom: none; }

.sidebar .widget_recent_entries a,
.sidebar .widget_categories a,
.sidebar .widget_archive a { color: var(--text-2); text-decoration: none; }
.sidebar .widget_recent_entries a:hover,
.sidebar .widget_categories a:hover { color: var(--accent); }

/* ── Fix: dir-search form stacking ─────────────────────────── */
.dir-search-form {
    display: flex;
    flex-direction: column;
    gap: var(--s-3);
}

@media (min-width: 600px) {
    .dir-search-form {
        display: grid;
        grid-template-columns: 1fr 1fr auto;
        align-items: start;
    }
}

@media (min-width: 1024px) {
    .dir-search-form { grid-template-columns: 1fr 200px auto; }
}

.dir-search-form .btn-primary {
    width: 100%;
    min-height: 48px;
}

@media (min-width: 600px) {
    .dir-search-form .btn-primary { width: auto; align-self: stretch; }
}

/* ── Fix: footer grid collapse on mobile ────────────────────── */
.footer-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: var(--s-6);
}

@media (min-width: 480px) { .footer-grid { grid-template-columns: 1fr 1fr; gap: var(--s-8); } }
@media (min-width: 768px) { .footer-grid { grid-template-columns: repeat(3, 1fr); } }
@media (min-width: 1024px) { .footer-grid { grid-template-columns: 2fr 1fr 1fr 1fr; gap: var(--s-12); } }

/* ── Overflow guard ─────────────────────────────────────────── */
html { overflow-x: hidden; }
body { overflow-x: hidden; max-width: 100vw; }
img  { max-width: 100% !important; height: auto !important; }

/* Tables scrollable on mobile */
.post-content table {
    display: table !important; /* override global block setting */
    width: 100%;
    overflow: hidden;
}

