/* =========================================================
   Shamire — The Voice of the Beauty Industry
   Premium editorial design system
   Single stylesheet, zero dependencies, dark mode included
   ========================================================= */

/* ---------- 1. Design tokens ---------- */
:root {
  /* Brand palette — warm editorial luxe */
  --rose-50:  #fdf7f5;
  --rose-100: #fbeae5;
  --rose-200: #f5d3c9;
  --rose-300: #eab3a2;
  --rose-400: #d98d77;
  --rose-500: #c26b54;
  --rose-600: #a4523e;

  --sand-50:  #fbf9f6;
  --sand-100: #f4efe8;
  --sand-200: #e8dfd3;
  --sand-300: #d4c6b3;

  --ink-900: #17120f;
  --ink-800: #241c18;
  --ink-700: #3b302a;
  --ink-600: #5c4d45;
  --ink-500: #7d6d63;
  --ink-400: #a1938a;

  --gold:    #b8944e;
  --gold-lt: #e3cf9f;

  /* Semantic */
  --bg:            var(--sand-50);
  --bg-alt:        #ffffff;
  --bg-tint:       var(--rose-50);
  --surface:       #ffffff;
  --surface-2:     var(--sand-100);
  --text:          var(--ink-800);
  --text-muted:    var(--ink-500);
  --text-soft:     var(--ink-600);
  --accent:        var(--rose-500);
  --accent-hover:  var(--rose-600);
  --border:        rgba(23, 18, 15, 0.10);
  --border-strong: rgba(23, 18, 15, 0.18);
  --shadow-sm: 0 1px 2px rgba(23,18,15,.05), 0 2px 8px rgba(23,18,15,.04);
  --shadow-md: 0 4px 12px rgba(23,18,15,.07), 0 12px 32px rgba(23,18,15,.06);
  --shadow-lg: 0 10px 30px rgba(23,18,15,.10), 0 30px 60px rgba(23,18,15,.08);

  /* Type */
  --font-display: "Cormorant Garamond", "Iowan Old Style", "Palatino Linotype", Palatino, Georgia, serif;
  --font-body: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --font-mono: ui-monospace, SFMono-Regular, "SF Mono", Menlo, monospace;

  /* Fluid type scale */
  --fs-xs:   0.78rem;
  --fs-sm:   0.875rem;
  --fs-base: 1.0625rem;
  --fs-lg:   1.1875rem;
  --fs-xl:   clamp(1.35rem, 1.1rem + 0.8vw, 1.6rem);
  --fs-2xl:  clamp(1.7rem, 1.3rem + 1.6vw, 2.4rem);
  --fs-3xl:  clamp(2.1rem, 1.5rem + 2.8vw, 3.4rem);
  --fs-4xl:  clamp(2.6rem, 1.6rem + 4.4vw, 5rem);

  /* Space & layout */
  --space-1: 0.25rem; --space-2: 0.5rem;  --space-3: 0.75rem;
  --space-4: 1rem;    --space-5: 1.5rem;  --space-6: 2rem;
  --space-7: 3rem;    --space-8: 4rem;    --space-9: 6rem;
  --wrap: 1200px;
  --wrap-narrow: 720px;
  --radius-sm: 6px;
  --radius: 12px;
  --radius-lg: 20px;
  --radius-full: 999px;
  --header-h: 68px;
  --ease: cubic-bezier(.22,.61,.36,1);
}

[data-theme="dark"] {
  --bg:            #100c0a;
  --bg-alt:        #171210;
  --bg-tint:       #1c1512;
  --surface:       #191311;
  --surface-2:     #221a16;
  --text:          #f2ece7;
  --text-muted:    #a3948b;
  --text-soft:     #c7bab1;
  --accent:        #e79c83;
  --accent-hover:  #f2b39c;
  --border:        rgba(242, 236, 231, 0.12);
  --border-strong: rgba(242, 236, 231, 0.22);
  --gold:          #d9bd7d;
  --shadow-sm: 0 1px 2px rgba(0,0,0,.4);
  --shadow-md: 0 4px 14px rgba(0,0,0,.45);
  --shadow-lg: 0 12px 40px rgba(0,0,0,.55);
}

/* ---------- 2. Reset ---------- */
*, *::before, *::after { box-sizing: border-box; }
* { margin: 0; }
html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--header-h) + 16px);
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: .01ms !important; transition-duration: .01ms !important; }
}
body {
  font-family: var(--font-body);
  font-size: var(--fs-base);
  line-height: 1.7;
  color: var(--text);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  font-synthesis-weight: none;
  overflow-x: hidden;
  transition: background-color .3s var(--ease), color .3s var(--ease);
}
img, picture, svg, video { display: block; max-width: 100%; height: auto; }
input, button, textarea, select { font: inherit; color: inherit; }
button { cursor: pointer; background: none; border: none; }
a { color: inherit; text-decoration: none; }
ul, ol { padding-left: 1.25em; }
:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
  border-radius: 3px;
}
::selection { background: var(--rose-200); color: var(--ink-900); }

/* ---------- 3. Typography ---------- */
h1, h2, h3, h4 {
  font-family: var(--font-display);
  font-weight: 600;
  line-height: 1.12;
  letter-spacing: -0.015em;
  color: var(--text);
  text-wrap: balance;
}
h1 { font-size: var(--fs-3xl); }
h2 { font-size: var(--fs-2xl); }
h3 { font-size: var(--fs-xl); }
h4 { font-size: var(--fs-lg); font-family: var(--font-body); font-weight: 650; letter-spacing: 0; }
p { text-wrap: pretty; }

.eyebrow {
  font-family: var(--font-body);
  font-size: var(--fs-xs);
  font-weight: 600;
  letter-spacing: .18em;
  text-transform: uppercase;
  color: var(--accent);
}
.lede { font-size: var(--fs-lg); color: var(--text-soft); line-height: 1.65; }
.muted { color: var(--text-muted); }
.small { font-size: var(--fs-sm); }

/* ---------- 4. Layout utilities ---------- */
.wrap { width: min(100% - 2.5rem, var(--wrap)); margin-inline: auto; }
.wrap-narrow { width: min(100% - 2.5rem, var(--wrap-narrow)); margin-inline: auto; }
.section { padding-block: var(--space-9); }
.section-tight { padding-block: var(--space-8); }
.stack > * + * { margin-top: var(--space-4); }
.center { text-align: center; }
.skip-link {
  position: absolute; left: -9999px; top: 0; z-index: 999;
  background: var(--accent); color: #fff; padding: .75rem 1.25rem; border-radius: 0 0 var(--radius) 0;
}
.skip-link:focus { left: 0; }
.visually-hidden {
  position: absolute !important; width: 1px; height: 1px;
  padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}

.section-head {
  display: flex; align-items: flex-end; justify-content: space-between;
  gap: var(--space-5); margin-bottom: var(--space-6); flex-wrap: wrap;
}
.section-head h2 { max-width: 22ch; }
.rule { height: 1px; background: var(--border); border: 0; }

/* ---------- 5. Buttons & pills ---------- */
.btn {
  display: inline-flex; align-items: center; gap: .5rem;
  padding: .8rem 1.6rem; border-radius: var(--radius-full);
  font-size: var(--fs-sm); font-weight: 600; letter-spacing: .02em;
  transition: transform .25s var(--ease), background-color .25s var(--ease), box-shadow .25s var(--ease), color .25s var(--ease);
  will-change: transform;
}
.btn-primary { background: var(--accent); color: #fff; box-shadow: var(--shadow-sm); }
.btn-primary:hover { background: var(--accent-hover); transform: translateY(-2px); box-shadow: var(--shadow-md); }
.btn-ghost { border: 1px solid var(--border-strong); color: var(--text); }
.btn-ghost:hover { border-color: var(--accent); color: var(--accent); transform: translateY(-2px); }
.btn-link { color: var(--accent); font-weight: 600; font-size: var(--fs-sm); display: inline-flex; align-items: center; gap: .4rem; }
.btn-link::after { content: "→"; transition: transform .25s var(--ease); }
.btn-link:hover::after { transform: translateX(4px); }

.pill {
  display: inline-block; padding: .3rem .8rem; border-radius: var(--radius-full);
  background: var(--bg-tint); border: 1px solid var(--border);
  font-size: var(--fs-xs); font-weight: 600; letter-spacing: .06em; text-transform: uppercase;
  color: var(--text-soft); transition: all .2s var(--ease);
}
a.pill:hover { background: var(--accent); border-color: var(--accent); color: #fff; }
.pill-accent { background: var(--accent); border-color: var(--accent); color: #fff; }

/* ---------- 6. Header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 100;
  height: var(--header-h);
  display: flex; align-items: center;
  background: color-mix(in srgb, var(--bg) 82%, transparent);
  backdrop-filter: saturate(180%) blur(14px);
  -webkit-backdrop-filter: saturate(180%) blur(14px);
  border-bottom: 1px solid transparent;
  transition: border-color .3s var(--ease), background-color .3s var(--ease);
}
.site-header.is-stuck { border-bottom-color: var(--border); }
.header-inner { display: flex; align-items: center; justify-content: space-between; gap: var(--space-5); }

.logo { display: flex; align-items: baseline; gap: .5rem; }
.logo-mark {
  font-family: var(--font-display); font-size: 1.6rem; font-weight: 600;
  letter-spacing: .04em; line-height: 1;
}
.logo-mark em { font-style: italic; color: var(--accent); }
.logo-sub {
  font-size: 0.58rem; letter-spacing: .3em; text-transform: uppercase;
  color: var(--text-muted); font-weight: 600;
}

.nav { display: flex; align-items: center; gap: var(--space-5); }
.nav a {
  font-size: var(--fs-sm); font-weight: 500; color: var(--text-soft);
  position: relative; padding-block: .25rem;
}
.nav a::after {
  content: ""; position: absolute; left: 0; bottom: 0; height: 1.5px; width: 0;
  background: var(--accent); transition: width .3s var(--ease);
}
.nav a:hover, .nav a[aria-current="page"] { color: var(--text); }
.nav a:hover::after, .nav a[aria-current="page"]::after { width: 100%; }

.header-actions { display: flex; align-items: center; gap: .5rem; }
.icon-btn {
  width: 38px; height: 38px; display: grid; place-items: center;
  border-radius: var(--radius-full); color: var(--text-soft);
  transition: background-color .2s var(--ease), color .2s var(--ease);
}
.icon-btn:hover { background: var(--surface-2); color: var(--text); }
.icon-btn svg { width: 19px; height: 19px; }
.theme-toggle .moon { display: none; }
[data-theme="dark"] .theme-toggle .sun { display: none; }
[data-theme="dark"] .theme-toggle .moon { display: block; }

.menu-btn { display: none; }
@media (max-width: 900px) {
  .nav {
    position: fixed; inset: var(--header-h) 0 auto 0;
    flex-direction: column; align-items: stretch; gap: 0;
    background: var(--bg-alt); border-bottom: 1px solid var(--border);
    padding: var(--space-4) 1.25rem var(--space-5);
    box-shadow: var(--shadow-md);
    transform: translateY(-120%); opacity: 0; pointer-events: none;
    transition: transform .35s var(--ease), opacity .25s var(--ease);
  }
  .nav.is-open { transform: translateY(0); opacity: 1; pointer-events: auto; }
  .nav a { padding: .85rem 0; border-bottom: 1px solid var(--border); font-size: var(--fs-lg); }
  .nav a::after { display: none; }
  .menu-btn { display: grid; }
}

/* ---------- 7. Search overlay ---------- */
.search-overlay {
  position: fixed; inset: 0; z-index: 200;
  background: color-mix(in srgb, var(--bg) 92%, transparent);
  backdrop-filter: blur(10px);
  display: none; padding-top: 12vh;
}
.search-overlay.is-open { display: block; animation: fadeIn .2s var(--ease); }
@keyframes fadeIn { from { opacity: 0 } to { opacity: 1 } }
.search-box { width: min(100% - 2.5rem, 640px); margin-inline: auto; }
.search-field {
  display: flex; align-items: center; gap: .75rem;
  background: var(--surface); border: 1px solid var(--border-strong);
  border-radius: var(--radius); padding: .9rem 1.1rem; box-shadow: var(--shadow-lg);
}
.search-field input { flex: 1; border: 0; outline: 0; background: none; font-size: var(--fs-lg); }
.search-results { margin-top: 1rem; max-height: 55vh; overflow-y: auto; }
.search-results a {
  display: block; padding: .9rem 1.1rem; border-radius: var(--radius-sm);
  background: var(--surface); border: 1px solid var(--border); margin-bottom: .5rem;
  transition: border-color .2s var(--ease), transform .2s var(--ease);
}
.search-results a:hover { border-color: var(--accent); transform: translateX(3px); }
.search-results strong { display: block; font-weight: 600; }

/* ---------- 8. Hero ---------- */
.hero {
  position: relative; overflow: hidden;
  padding-block: clamp(3rem, 7vw, 6.5rem) clamp(3rem, 6vw, 5rem);
  background:
    radial-gradient(ellipse 80% 60% at 12% 0%, var(--rose-100) 0%, transparent 60%),
    radial-gradient(ellipse 70% 60% at 92% 20%, var(--sand-200) 0%, transparent 55%);
}
[data-theme="dark"] .hero {
  background:
    radial-gradient(ellipse 80% 60% at 12% 0%, rgba(231,156,131,.13) 0%, transparent 60%),
    radial-gradient(ellipse 70% 60% at 92% 20%, rgba(217,189,125,.09) 0%, transparent 55%);
}
.hero-grid {
  display: grid; grid-template-columns: 1.05fr .95fr;
  gap: clamp(2rem, 5vw, 4.5rem); align-items: center;
}
@media (max-width: 900px) { .hero-grid { grid-template-columns: 1fr; } }
.hero h1 { font-size: var(--fs-4xl); margin-block: 1rem 1.25rem; }
.hero h1 em { font-style: italic; color: var(--accent); }
.hero-actions { display: flex; gap: .75rem; flex-wrap: wrap; margin-top: var(--space-5); }
.hero-stats {
  display: flex; gap: var(--space-6); margin-top: var(--space-7);
  padding-top: var(--space-5); border-top: 1px solid var(--border); flex-wrap: wrap;
}
.hero-stat b { display: block; font-family: var(--font-display); font-size: 1.9rem; line-height: 1; }
.hero-stat span { font-size: var(--fs-xs); letter-spacing: .12em; text-transform: uppercase; color: var(--text-muted); }

.hero-visual { position: relative; }
.hero-visual .frame {
  border-radius: var(--radius-lg); overflow: hidden; box-shadow: var(--shadow-lg);
  aspect-ratio: 4/5;
}
.hero-badge {
  position: absolute; left: -1.5rem; bottom: 2rem;
  background: var(--surface); border: 1px solid var(--border);
  border-radius: var(--radius); padding: .9rem 1.1rem; box-shadow: var(--shadow-md);
  max-width: 230px;
}
@media (max-width: 600px) { .hero-badge { left: 0; bottom: -1rem; } }
.hero-badge b { font-family: var(--font-display); font-size: 1.05rem; }

/* Decorative gradient art (no image files needed) */
.art {
  width: 100%; height: 100%;
  background:
    radial-gradient(circle at 30% 25%, var(--rose-200), transparent 55%),
    radial-gradient(circle at 75% 65%, var(--gold-lt), transparent 50%),
    linear-gradient(150deg, var(--rose-100), var(--sand-200));
}
.art-2 {
  background:
    radial-gradient(circle at 70% 30%, var(--rose-300), transparent 55%),
    linear-gradient(200deg, var(--sand-100), var(--rose-100));
}
.art-3 {
  background:
    radial-gradient(circle at 25% 70%, var(--gold-lt), transparent 55%),
    linear-gradient(120deg, var(--rose-100), var(--sand-200));
}
.art-4 {
  background:
    radial-gradient(circle at 50% 20%, var(--rose-200), transparent 60%),
    linear-gradient(320deg, var(--sand-200), var(--rose-50));
}

/* ---------- 9. Cards & grids ---------- */
.grid { display: grid; gap: var(--space-6); }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-4 { grid-template-columns: repeat(4, 1fr); }
.grid-2 { grid-template-columns: repeat(2, 1fr); }
@media (max-width: 980px) { .grid-3, .grid-4 { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 620px) { .grid-2, .grid-3, .grid-4 { grid-template-columns: 1fr; } }

.card { display: flex; flex-direction: column; gap: var(--space-3); }
.card-media {
  border-radius: var(--radius); overflow: hidden; aspect-ratio: 4/3;
  position: relative; box-shadow: var(--shadow-sm);
}
.card-media > * { transition: transform .6s var(--ease); height: 100%; }
.card:hover .card-media > * { transform: scale(1.05); }
.card-meta {
  display: flex; align-items: center; gap: .6rem;
  font-size: var(--fs-xs); color: var(--text-muted); letter-spacing: .06em; text-transform: uppercase;
}
.card-meta .dot { width: 3px; height: 3px; border-radius: 50%; background: currentColor; }
.card h3 { font-size: var(--fs-xl); transition: color .2s var(--ease); }
.card:hover h3 { color: var(--accent); }
.card p { color: var(--text-muted); font-size: var(--fs-sm); }

/* Featured (large) card */
.feature-card { position: relative; border-radius: var(--radius-lg); overflow: hidden; min-height: 440px; display: flex; align-items: flex-end; box-shadow: var(--shadow-md); }
.feature-card .art { position: absolute; inset: 0; transition: transform .8s var(--ease); }
.feature-card:hover .art { transform: scale(1.05); }
.feature-card .overlay {
  position: relative; z-index: 2; padding: var(--space-6);
  background: linear-gradient(to top, rgba(20,14,11,.88) 0%, rgba(20,14,11,.55) 45%, transparent 100%);
  width: 100%; color: #fff;
}
.feature-card .overlay h3 { color: #fff; font-size: var(--fs-2xl); }
.feature-card .overlay p { color: rgba(255,255,255,.82); }
.feature-card .overlay .card-meta { color: rgba(255,255,255,.75); }

/* Category tiles */
.cat-tile {
  position: relative; border-radius: var(--radius); overflow: hidden;
  aspect-ratio: 1/1; display: grid; place-items: center; text-align: center;
  box-shadow: var(--shadow-sm);
}
.cat-tile .art { position: absolute; inset: 0; transition: transform .6s var(--ease); }
.cat-tile:hover .art { transform: scale(1.08); }
.cat-tile span {
  position: relative; z-index: 2; font-family: var(--font-display); font-size: 1.5rem;
  color: var(--ink-900); background: rgba(255,255,255,.82); padding: .5rem 1.25rem;
  border-radius: var(--radius-full); backdrop-filter: blur(6px);
}

/* ---------- 10. Article / prose ---------- */
.article-header { padding-block: var(--space-7) var(--space-6); }
.breadcrumbs { font-size: var(--fs-xs); color: var(--text-muted); margin-bottom: var(--space-4); letter-spacing: .04em; }
.breadcrumbs a:hover { color: var(--accent); }
.breadcrumbs span[aria-hidden] { margin-inline: .4rem; }
.article-header h1 { margin-block: .75rem 1rem; }
.byline { display: flex; align-items: center; gap: .85rem; margin-top: var(--space-5); flex-wrap: wrap; }
.avatar {
  width: 44px; height: 44px; border-radius: 50%; flex-shrink: 0;
  background: linear-gradient(140deg, var(--rose-300), var(--gold-lt));
  display: grid; place-items: center; font-family: var(--font-display); font-weight: 600; color: #fff; font-size: 1.05rem;
}
.byline-text { font-size: var(--fs-sm); line-height: 1.45; }
.byline-text b { font-weight: 650; }
.byline-text span { color: var(--text-muted); }

.hero-figure { border-radius: var(--radius-lg); overflow: hidden; aspect-ratio: 16/9; box-shadow: var(--shadow-md); margin-bottom: var(--space-6); }

/* Answer-first block — key for AEO / AI Overviews */
.answer-box {
  background: var(--bg-tint); border: 1px solid var(--border);
  border-left: 3px solid var(--accent);
  border-radius: var(--radius); padding: var(--space-5); margin-block: var(--space-6);
}
.answer-box .eyebrow { display: block; margin-bottom: .5rem; }
.answer-box p { font-size: var(--fs-lg); line-height: 1.6; }
.answer-box p + p { margin-top: .75rem; font-size: var(--fs-base); color: var(--text-soft); }

.key-takeaways {
  background: var(--surface); border: 1px solid var(--border);
  border-radius: var(--radius); padding: var(--space-5); margin-block: var(--space-6);
}
.key-takeaways h2 { font-size: var(--fs-lg); font-family: var(--font-body); font-weight: 650; margin-bottom: .75rem; }
.key-takeaways ul { margin: 0; padding-left: 1.1em; }
.key-takeaways li { margin-bottom: .5rem; color: var(--text-soft); }
.key-takeaways li::marker { color: var(--accent); }

.prose { font-size: var(--fs-lg); line-height: 1.78; }
.prose > * + * { margin-top: 1.35em; }
.prose h2 { font-size: var(--fs-2xl); margin-top: 2.4em; scroll-margin-top: 90px; }
.prose h3 { font-size: var(--fs-xl); margin-top: 1.9em; scroll-margin-top: 90px; }
.prose h2 + p, .prose h3 + p { margin-top: .8em; }
.prose a { color: var(--accent); text-decoration: underline; text-underline-offset: 3px; text-decoration-thickness: 1px; }
.prose a:hover { color: var(--accent-hover); }
.prose ul, .prose ol { padding-left: 1.3em; }
.prose li { margin-bottom: .5em; }
.prose li::marker { color: var(--accent); }
.prose strong { font-weight: 650; }
.prose blockquote {
  border-left: 3px solid var(--accent); padding: .3em 0 .3em 1.4em;
  font-family: var(--font-display); font-size: 1.35em; font-style: italic; color: var(--text-soft);
}
.prose figure figcaption { font-size: var(--fs-sm); color: var(--text-muted); margin-top: .6rem; text-align: center; }
.prose table { width: 100%; border-collapse: collapse; font-size: var(--fs-sm); }
.prose th, .prose td { padding: .75rem .9rem; border-bottom: 1px solid var(--border); text-align: left; vertical-align: top; }
.prose th { font-weight: 650; background: var(--surface-2); }
.prose code { font-family: var(--font-mono); font-size: .88em; background: var(--surface-2); padding: .15em .4em; border-radius: 4px; }
.table-wrap { overflow-x: auto; }

/* Table of contents */
.toc {
  background: var(--surface); border: 1px solid var(--border);
  border-radius: var(--radius); padding: var(--space-5); margin-block: var(--space-6);
}
.toc h2 { font-size: var(--fs-sm); font-family: var(--font-body); font-weight: 650;
  letter-spacing: .12em; text-transform: uppercase; color: var(--text-muted); margin-bottom: .75rem; }
.toc ol { list-style: none; padding: 0; margin: 0; counter-reset: toc; }
.toc li { counter-increment: toc; margin-bottom: .45rem; font-size: var(--fs-sm); }
.toc li::before { content: counter(toc, decimal-leading-zero); color: var(--accent); font-weight: 600; margin-right: .6rem; }
.toc a:hover { color: var(--accent); }

/* FAQ — AEO gold */
.faq { margin-block: var(--space-7); }
.faq details {
  border-bottom: 1px solid var(--border); padding: 1.1rem 0;
}
.faq summary {
  cursor: pointer; list-style: none; font-weight: 650; font-size: var(--fs-lg);
  display: flex; justify-content: space-between; gap: 1rem; align-items: center;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; font-size: 1.5rem; color: var(--accent); font-weight: 300; transition: transform .25s var(--ease); }
.faq details[open] summary::after { transform: rotate(45deg); }
.faq details p { margin-top: .8rem; color: var(--text-soft); }

/* Reading progress */
.progress {
  position: fixed; top: 0; left: 0; height: 2.5px; width: 0%;
  background: linear-gradient(90deg, var(--accent), var(--gold));
  z-index: 300; transition: width .1s linear;
}

/* Share row */
.share-row { display: flex; align-items: center; gap: .6rem; flex-wrap: wrap; margin-block: var(--space-6); padding-block: var(--space-5); border-block: 1px solid var(--border); }
.share-row span { font-size: var(--fs-xs); letter-spacing: .12em; text-transform: uppercase; color: var(--text-muted); margin-right: .3rem; }

/* Author box — E-E-A-T signal */
.author-box {
  display: flex; gap: var(--space-5); align-items: flex-start;
  background: var(--bg-tint); border: 1px solid var(--border);
  border-radius: var(--radius); padding: var(--space-5); margin-block: var(--space-6);
}
.author-box .avatar { width: 64px; height: 64px; font-size: 1.4rem; }
.author-box h3 { font-size: var(--fs-lg); font-family: var(--font-body); font-weight: 650; }
.author-box p { font-size: var(--fs-sm); color: var(--text-soft); margin-top: .35rem; }
@media (max-width: 560px) { .author-box { flex-direction: column; } }

/* ---------- 11. Newsletter ---------- */
.newsletter {
  background: var(--ink-900); color: var(--sand-50);
  border-radius: var(--radius-lg); padding: clamp(2rem, 5vw, 3.5rem);
  position: relative; overflow: hidden;
}
.newsletter::before {
  content: ""; position: absolute; inset: 0;
  background: radial-gradient(ellipse 60% 80% at 85% 30%, rgba(194,107,84,.35), transparent 60%);
}
.newsletter > * { position: relative; z-index: 1; }
.newsletter h2 { color: var(--sand-50); max-width: 16ch; }
.newsletter p { color: rgba(251,249,246,.7); max-width: 46ch; margin-top: .75rem; }
.newsletter form { display: flex; gap: .6rem; margin-top: var(--space-5); max-width: 460px; flex-wrap: wrap; }
.newsletter input {
  flex: 1 1 240px; padding: .85rem 1.1rem; border-radius: var(--radius-full);
  border: 1px solid rgba(251,249,246,.25); background: rgba(251,249,246,.07); color: var(--sand-50);
}
.newsletter input::placeholder { color: rgba(251,249,246,.45); }
.newsletter input:focus { outline: none; border-color: var(--rose-300); background: rgba(251,249,246,.12); }
.newsletter .btn-primary { background: var(--sand-50); color: var(--ink-900); }
.newsletter .btn-primary:hover { background: #fff; }
.newsletter .fine { font-size: var(--fs-xs); color: rgba(251,249,246,.5); margin-top: .9rem; }

/* ---------- 12. Footer ---------- */
.site-footer {
  background: var(--bg-alt); border-top: 1px solid var(--border);
  padding-block: var(--space-8) var(--space-5); margin-top: var(--space-9);
}
.footer-grid { display: grid; grid-template-columns: 1.6fr 1fr 1fr 1fr; gap: var(--space-6); }
@media (max-width: 860px) { .footer-grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 500px) { .footer-grid { grid-template-columns: 1fr; } }
.footer-grid h4 { font-size: var(--fs-xs); letter-spacing: .14em; text-transform: uppercase; color: var(--text-muted); margin-bottom: .9rem; font-family: var(--font-body); }
.footer-grid ul { list-style: none; padding: 0; }
.footer-grid li { margin-bottom: .5rem; font-size: var(--fs-sm); }
.footer-grid a { color: var(--text-soft); }
.footer-grid a:hover { color: var(--accent); }
.footer-about p { font-size: var(--fs-sm); color: var(--text-muted); max-width: 34ch; margin-top: .9rem; }
.socials { display: flex; gap: .5rem; margin-top: 1rem; }
.socials a {
  width: 36px; height: 36px; display: grid; place-items: center; border-radius: 50%;
  border: 1px solid var(--border); color: var(--text-muted); transition: all .2s var(--ease);
}
.socials a:hover { border-color: var(--accent); color: var(--accent); transform: translateY(-2px); }
.socials svg { width: 16px; height: 16px; }
.footer-bottom {
  margin-top: var(--space-7); padding-top: var(--space-5); border-top: 1px solid var(--border);
  display: flex; justify-content: space-between; gap: var(--space-4); flex-wrap: wrap;
  font-size: var(--fs-xs); color: var(--text-muted);
}
.footer-bottom nav { display: flex; gap: 1.2rem; flex-wrap: wrap; }

/* ---------- 13. Misc components ---------- */
.filter-bar { display: flex; gap: .5rem; flex-wrap: wrap; margin-bottom: var(--space-6); }
.filter-bar button {
  padding: .45rem 1rem; border-radius: var(--radius-full); border: 1px solid var(--border);
  font-size: var(--fs-sm); font-weight: 500; color: var(--text-soft); transition: all .2s var(--ease);
}
.filter-bar button:hover { border-color: var(--accent); color: var(--accent); }
.filter-bar button.is-active { background: var(--text); color: var(--bg); border-color: var(--text); }

.post-row { display: grid; grid-template-columns: 280px 1fr; gap: var(--space-5); padding-block: var(--space-5); border-bottom: 1px solid var(--border); align-items: center; }
@media (max-width: 700px) { .post-row { grid-template-columns: 1fr; } }
.post-row .card-media { aspect-ratio: 16/10; }

.note {
  background: var(--surface-2); border-radius: var(--radius); padding: var(--space-5);
  font-size: var(--fs-sm); color: var(--text-soft); border: 1px solid var(--border);
}
.note b { color: var(--text); }

.reveal { opacity: 0; transform: translateY(18px); transition: opacity .7s var(--ease), transform .7s var(--ease); }
.reveal.is-visible { opacity: 1; transform: none; }

.contact-form { display: grid; gap: var(--space-4); }
.field label { display: block; font-size: var(--fs-sm); font-weight: 600; margin-bottom: .4rem; }
.field input, .field textarea, .field select {
  width: 100%; padding: .8rem 1rem; border-radius: var(--radius-sm);
  border: 1px solid var(--border-strong); background: var(--surface);
}
.field input:focus, .field textarea:focus { outline: none; border-color: var(--accent); }
.field textarea { min-height: 150px; resize: vertical; }

/* Print */
@media print {
  .site-header, .site-footer, .newsletter, .share-row, .progress, .toc { display: none !important; }
  body { background: #fff; color: #000; }
  .prose a::after { content: " (" attr(href) ")"; font-size: .8em; color: #555; }
}

/* ---------- 14. Brand logo (added) ---------- */
/* One inline SVG logo. The ink uses currentColor so it follows the theme —
   no second image, no light/dark swap. */
.logo { align-items: center; gap: 0; color: var(--text); flex: 0 0 auto; }
.logo-img { height: 44px; width: auto; aspect-ratio: 520 / 140; display: block; }
.footer-logo { height: 52px; margin-bottom: .4rem; color: var(--text); }
@media (max-width: 480px) { .logo-img { height: 36px; } }

/* Keep the primary nav on a single line. */
.header-inner { flex-wrap: nowrap; }
.nav { flex-wrap: nowrap; min-width: 0; }
.nav a { white-space: nowrap; }
@media (max-width: 1180px) { .nav { gap: var(--space-4); } }
@media (max-width: 1080px) { .nav a { font-size: var(--fs-sm); } }

/* Hero banner image slot */
.hero-visual .frame img,
.hero-visual .frame svg { width: 100%; height: 100%; object-fit: cover; display: block; }

/* Wholesale / industry accent for trade content */
.pill-industry { background: var(--ink-800); border-color: var(--ink-800); color: var(--sand-50); }
[data-theme="dark"] .pill-industry { background: var(--gold); border-color: var(--gold); color: var(--ink-900); }

/* Figure with caption inside prose */
.prose figure { margin-block: 2em; }
.prose figure .frame { border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow-sm); }

/* ---------- 15. Cookie consent bar ---------- */
.cookie-bar {
  position: fixed; left: 50%; bottom: 1rem; transform: translateX(-50%);
  width: min(100% - 2rem, 720px); z-index: 400;
  background: var(--surface); border: 1px solid var(--border-strong);
  border-radius: var(--radius); box-shadow: var(--shadow-lg);
  padding: 1rem 1.15rem; display: flex; gap: 1rem; align-items: center; flex-wrap: wrap;
}
.cookie-bar[hidden] { display: none; }
.cookie-bar p { font-size: var(--fs-sm); color: var(--text-soft); flex: 1 1 320px; margin: 0; }
.cookie-bar a { color: var(--accent); text-decoration: underline; text-underline-offset: 2px; }
.cookie-actions { display: flex; gap: .5rem; flex-wrap: wrap; }
.cookie-actions .btn { padding: .55rem 1.1rem; }
@media (max-width: 520px) { .cookie-actions { width: 100%; } .cookie-actions .btn { flex: 1; justify-content: center; } }

/* ---------- 16. App: accounts, dashboard, community ---------- */
.account-slot { display: inline-flex; align-items: center; gap: .6rem; font-size: var(--fs-sm); margin-right: .25rem; white-space: nowrap; }
.acct-link { color: var(--text-muted); font-weight: 500; }
.acct-link:hover { color: var(--text); }
.acct-name { color: var(--text); font-weight: 600; }
.btn-sm { padding: .42rem .95rem; font-size: var(--fs-sm); }
/* The mobile drawer gets its own copy of the account controls. */
.nav-write, .account-slot-mobile { display: none; }
@media (max-width: 860px) { .acct-link { display: none; } }
@media (max-width: 700px) {
  .account-slot { display: none; }
  .nav-write { display: block; }
  .account-slot-mobile { display: flex; }
}

.toast {
  position: fixed; left: 50%; bottom: 1.25rem; transform: translateX(-50%);
  z-index: 500; padding: .8rem 1.2rem; border-radius: var(--radius-full);
  background: var(--ink-900); color: var(--sand-50); font-size: var(--fs-sm);
  box-shadow: var(--shadow-lg); max-width: min(92vw, 520px);
}
.toast-err { background: #8f2f22; }
.toast[hidden] { display: none; }

.panel {
  background: var(--surface); border: 1px solid var(--border);
  border-radius: var(--radius); padding: var(--space-5); margin-bottom: var(--space-5);
}
.panel-head { display: flex; justify-content: space-between; align-items: center; gap: 1rem; flex-wrap: wrap; margin-bottom: 1rem; }
.panel-head h2, .panel-head h3 { margin: 0; }

.status {
  display: inline-block; padding: .18rem .6rem; border-radius: var(--radius-full);
  font-size: var(--fs-xs); font-weight: 650; letter-spacing: .04em; text-transform: uppercase;
}
.status-approved { background: #e3f3e8; color: #1d5c33; }
.status-pending  { background: #fdf0d9; color: #7a5312; }
.status-rejected { background: #fbe3e0; color: #8f2f22; }
.status-draft    { background: var(--surface-2); color: var(--text-muted); }
.status-live     { background: #e3f3e8; color: #1d5c33; }
[data-theme="dark"] .status-approved, [data-theme="dark"] .status-live { background: #1d3a27; color: #9fdcb4; }
[data-theme="dark"] .status-pending { background: #3d3018; color: #f0cf92; }
[data-theme="dark"] .status-rejected { background: #3d1f1a; color: #f0a99e; }

.seo-check { display: flex; gap: .5rem; flex-wrap: wrap; align-items: center; margin-top: .6rem; }
.seo-pill { padding: .25rem .7rem; border-radius: var(--radius-full); font-size: var(--fs-xs); font-weight: 650; }
.seo-pass { background: #e3f3e8; color: #1d5c33; }
.seo-fail { background: #fbe3e0; color: #8f2f22; }
[data-theme="dark"] .seo-pass { background:#1d3a27; color:#9fdcb4; }
[data-theme="dark"] .seo-fail { background:#3d1f1a; color:#f0a99e; }

.row { display: grid; grid-template-columns: 1fr 1fr; gap: var(--space-4); }
@media (max-width: 620px) { .row { grid-template-columns: 1fr; } }

.item-row {
  display: flex; justify-content: space-between; gap: 1rem; align-items: flex-start;
  padding: 1rem 0; border-bottom: 1px solid var(--border); flex-wrap: wrap;
}
.item-row:last-child { border-bottom: 0; }
.item-row h3 { font-size: var(--fs-lg); }
.item-meta { font-size: var(--fs-xs); color: var(--text-muted); letter-spacing: .04em; }

.tag {
  display: inline-block; padding: .18rem .6rem; margin: .15rem .25rem .15rem 0;
  border-radius: var(--radius-full); background: var(--bg-tint);
  border: 1px solid var(--border); font-size: var(--fs-xs); color: var(--text-soft);
}
a.tag:hover { border-color: var(--accent); color: var(--accent); }

.empty { text-align: center; padding: 3rem 1rem; color: var(--text-muted); }

.editor-grid { display: grid; grid-template-columns: 1fr 320px; gap: var(--space-6); align-items: start; }
@media (max-width: 900px) { .editor-grid { grid-template-columns: 1fr; } }
.sticky-side { position: sticky; top: calc(var(--header-h) + 1rem); }

.reply { padding: 1.1rem 0; border-bottom: 1px solid var(--border); }
.reply:last-child { border-bottom: 0; }
.reply-head { display: flex; gap: .6rem; align-items: center; font-size: var(--fs-sm); margin-bottom: .4rem; }
.reply-body { white-space: pre-wrap; color: var(--text-soft); }

.rate-card { display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--space-5); }
@media (max-width: 860px) { .rate-card { grid-template-columns: 1fr; } }
.rate {
  border: 1px solid var(--border); border-radius: var(--radius-lg);
  padding: var(--space-5); background: var(--surface); display: flex; flex-direction: column;
}
.rate.featured { border-color: var(--accent); box-shadow: var(--shadow-md); }
.rate .price { font-family: var(--font-display); font-size: 2.4rem; line-height: 1; margin: .5rem 0; }
.rate ul { padding-left: 1.1em; margin: 1rem 0; flex: 1; }
.rate li { font-size: var(--fs-sm); color: var(--text-soft); margin-bottom: .45rem; }
.rate li::marker { color: var(--accent); }
