/* Blog pages. Colours and type match the app (src/index.css, tailwind.config.js); topic colours are appended at build. */
:root {
  --bg: #f8f6fc;
  --surface: #ffffff;
  --subtle: #f1edf9;
  --line: #e4def1;
  --ink: #221c35;
  --muted: #6b6485;
  --accent: #7b61c9;
  --accent-hover: #6a50b8;
  --accent-soft: #ece5fb;
  --accent-ink: #5b43a8;
  --on-accent: #ffffff;
  --brand: #7b61c9;
  --display: 'Fraunces', Georgia, serif;
  --sans: 'Plus Jakarta Sans', system-ui, -apple-system, 'Segoe UI', sans-serif;
  --tint: #e8e1fa;
  --tint-ink: #5b43a8;
  color-scheme: light;
}
.dark {
  --bg: #120f1c;
  --surface: #1a1626;
  --subtle: #231e33;
  --line: #302a45;
  --ink: #eeeaf8;
  --muted: #a39cb9;
  --accent: #b6a2f2;
  --accent-hover: #c5b5f6;
  --accent-soft: #2c2448;
  --accent-ink: #cdbefa;
  --on-accent: #1a1330;
  color-scheme: dark;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: 92px; }
body { margin: 0; background: var(--bg); color: var(--ink); font: 16px/1.6 var(--sans); -webkit-font-smoothing: antialiased; }
a { color: var(--accent-ink); }
img, svg { max-width: 100%; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; border-radius: 6px; }
.wrap { max-width: 1152px; margin: 0 auto; padding: 0 16px; }
@media (min-width: 640px) { .wrap { padding: 0 24px; } }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip { position: absolute; left: 16px; top: -48px; z-index: 50; background: var(--ink); color: var(--bg); padding: 10px 14px; border-radius: 10px; }
.skip:focus { top: 12px; }

/* Header and footer: same as the app's public pages */
.site-header { position: sticky; top: 0; z-index: 40; background: color-mix(in srgb, var(--bg) 85%, transparent); backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px); border-bottom: 1px solid var(--line); }
.header-row { height: 68px; display: flex; align-items: center; gap: 24px; }
.logo { display: inline-flex; align-items: flex-start; gap: 6px; font: 600 26px/1 var(--display); letter-spacing: -0.01em; color: var(--ink); text-decoration: none; }
.logo-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--accent); margin-top: 14px; }
.nav { display: none; gap: 24px; flex: 1; }
.nav a { color: var(--muted); text-decoration: none; font-size: 14px; }
.nav a:hover { color: var(--ink); }
.nav a[aria-current] { color: var(--ink); font-weight: 600; }
@media (min-width: 768px) { .nav { display: flex; } }
.header-actions { margin-left: auto; display: flex; align-items: center; gap: 8px; }
.login { display: none; color: var(--ink); font-weight: 600; font-size: 14px; text-decoration: none; padding: 0 12px; }
@media (min-width: 640px) { .login { display: inline; } }
.btn { display: inline-flex; align-items: center; justify-content: center; min-height: 44px; padding: 0 20px; border-radius: 12px; background: var(--accent); color: var(--on-accent); font-weight: 600; font-size: 14px; text-decoration: none; white-space: nowrap; transition: background .15s; }
.btn:hover { background: var(--accent-hover); }
.btn-inverse { background: #fff; color: #4e3a96; min-height: 52px; padding: 0 26px; font-size: 15px; }
.btn-inverse:hover { background: #f1edf9; }
.site-footer { border-top: 1px solid var(--line); margin-top: 24px; }
.footer-row { padding: 32px 16px; display: flex; flex-wrap: wrap; gap: 16px; justify-content: space-between; font-size: 13px; color: var(--muted); }
@media (min-width: 640px) { .footer-row { padding: 32px 24px; } }
.footer-links { display: flex; flex-wrap: wrap; gap: 20px; }
.footer-links a { color: var(--muted); text-decoration: none; }
.footer-links a:hover { color: var(--ink); }

/* Shared pieces */
h1 { font: 500 clamp(34px, 5.2vw, 56px)/1.06 var(--display); letter-spacing: -0.02em; margin: 0; text-wrap: balance; }
.lede { font-size: 18px; line-height: 1.6; color: var(--muted); margin: 16px 0 0; max-width: 60ch; }
.topic { margin: 0 0 8px; font-size: 13px; font-weight: 600; color: var(--tint-ink); }
.meta { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 16px; font-size: 13px; color: var(--muted); }
/* The illustration tiles: topic colour, the app's dotted lattice, line art in the topic's ink. */
.art { position: relative; background-color: var(--tint); background-image: radial-gradient(circle, color-mix(in srgb, var(--tint-ink) 28%, transparent) 1.2px, transparent 1.4px); background-size: 18px 18px; background-position: 2px 2px; color: var(--tint-ink); display: grid; place-items: center; overflow: hidden; }
.art .motif { width: 34%; max-width: 132px; opacity: .85; }

/* Blog list */
.blog-hero { display: grid; gap: 28px; padding: 56px 0 28px; align-items: end; }
@media (min-width: 900px) { .blog-hero { grid-template-columns: 1.5fr 1fr; gap: 48px; padding: 72px 0 32px; } }
.search { position: relative; }
.search svg { position: absolute; left: 16px; top: 50%; width: 20px; height: 20px; transform: translateY(-50%); fill: none; stroke: var(--muted); stroke-width: 2; stroke-linecap: round; pointer-events: none; }
.search input { width: 100%; height: 54px; padding: 0 18px 0 46px; border-radius: 14px; border: 1px solid var(--line); background: var(--surface); color: var(--ink); font: 16px var(--sans); box-shadow: 0 1px 2px rgb(34 28 53 / .04); }
.search input:focus { outline: 2px solid var(--accent); outline-offset: 1px; border-color: transparent; }
.chips { display: flex; gap: 8px; overflow-x: auto; margin: 0 -16px; padding: 4px 16px 8px; scrollbar-width: none; }
.chips::-webkit-scrollbar { display: none; }
@media (min-width: 640px) { .chips { flex-wrap: wrap; overflow: visible; margin: 0; padding: 4px 0 8px; } }
.chip-btn { flex: none; display: inline-flex; align-items: center; gap: 8px; min-height: 40px; padding: 0 16px; border-radius: 999px; border: 1px solid var(--line); background: var(--surface); color: var(--ink); font: 500 14px var(--sans); cursor: pointer; }
.chip-btn:hover { border-color: var(--muted); }
.chip-btn .dot { width: 8px; height: 8px; border-radius: 50%; background: var(--tint-ink); }
.chip-btn[aria-pressed="true"] { background: var(--ink); border-color: var(--ink); color: var(--bg); }
.result-note { min-height: 22px; color: var(--muted); font-size: 14px; margin: 8px 0 12px; }
.grid { display: grid; gap: 20px; grid-template-columns: 1fr; }
@media (min-width: 680px) { .grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1000px) { .grid { grid-template-columns: repeat(3, 1fr); gap: 24px; } }
.card { position: relative; display: flex; flex-direction: column; background: var(--surface); border: 1px solid var(--line); border-radius: 22px; overflow: hidden; transition: border-color .15s; }
.card:hover { border-color: color-mix(in srgb, var(--accent) 55%, var(--line)); }
.card[hidden] { display: none; }
.card-art { aspect-ratio: 16 / 9; }
.card-body { padding: 20px 22px 22px; display: flex; flex-direction: column; flex: 1; }
.card-title { font: 500 21px/1.28 var(--display); letter-spacing: -0.005em; margin: 0 0 8px; text-wrap: balance; }
.card-title a, .featured-title a { color: var(--ink); text-decoration: none; }
.card-title a::after, .featured-title a::after { content: ''; position: absolute; inset: 0; }
.card:hover .card-title a, .card:hover .featured-title a { text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 4px; }
.card-desc { color: var(--muted); font-size: 15px; line-height: 1.55; margin: 0 0 16px; flex: 1; }
.featured { grid-column: 1 / -1; }
@media (min-width: 680px) { .featured:not([hidden]) { display: grid; grid-template-columns: 1.15fr 1fr; } }
.featured-art { aspect-ratio: 16 / 10; }
.featured-art .motif { width: 30%; max-width: 170px; }
@media (min-width: 680px) { .featured-art { aspect-ratio: auto; min-height: 340px; } }
.featured-body { padding: 26px; display: flex; flex-direction: column; justify-content: center; }
@media (min-width: 1000px) { .featured-body { padding: 44px; } }
.featured-title { font: 500 clamp(26px, 3vw, 36px)/1.15 var(--display); letter-spacing: -0.015em; margin: 0 0 12px; text-wrap: balance; }
.featured .card-desc { flex: 0; font-size: 16px; }

/* Closing band, as on the home page */
.band { margin: 72px 0 0; border-radius: 28px; background: var(--brand); color: #fff; padding: 32px; display: flex; flex-wrap: wrap; gap: 24px; align-items: center; justify-content: space-between; }
@media (min-width: 640px) { .band { padding: 48px; } }
.band h2 { font: 500 clamp(28px, 3.4vw, 38px)/1.15 var(--display); margin: 0 0 8px; max-width: 22ch; text-wrap: balance; }
.band p { margin: 0; opacity: .9; max-width: 52ch; }

/* Post */
.crumbs { display: flex; gap: 8px; font-size: 14px; color: var(--muted); padding: 24px 0 16px; }
.crumbs a { color: var(--muted); text-decoration: none; }
.crumbs a:hover { color: var(--ink); text-decoration: underline; }
.post-cover { position: relative; display: grid; gap: 24px; align-items: center; border-radius: 28px; padding: 32px 24px; background-color: var(--tint); background-image: radial-gradient(circle, color-mix(in srgb, var(--tint-ink) 22%, transparent) 1.2px, transparent 1.4px); background-size: 18px 18px; overflow: hidden; }
@media (min-width: 820px) { .post-cover { grid-template-columns: 1fr 220px; gap: 48px; padding: 56px; } }
.post-cover h1 { font-size: clamp(32px, 4.6vw, 52px); max-width: 20ch; }
.post-cover .lede { color: color-mix(in srgb, var(--ink) 72%, var(--tint)); }
.post-cover-art { display: none; width: 100%; color: var(--tint-ink); opacity: .85; }
@media (min-width: 820px) { .post-cover-art { display: block; } }
.byline { display: flex; align-items: center; gap: 12px; margin: 28px 0 0; }
.byline .meta { color: color-mix(in srgb, var(--ink) 70%, var(--tint)); font-size: 14px; }
.byline .meta span:first-child { font-weight: 600; color: var(--ink); }
.avatar { flex: none; width: 36px; height: 36px; border-radius: 50%; background: var(--brand); color: #fff; display: grid; place-items: center; font: 600 17px/1 var(--display); }
.post-layout { display: grid; gap: 32px; margin-top: 32px; }
.post-layout > * { min-width: 0; }
@media (min-width: 1000px) { .post-layout { margin-top: 48px; } }
@media (min-width: 1000px) { .post-layout { grid-template-columns: minmax(0, 1fr) 260px; gap: 72px; } }
.post-aside { order: -1; }
@media (min-width: 1000px) { .post-aside { order: 0; position: sticky; top: 100px; align-self: start; } }
.toc-title { margin: 0 0 10px; font-weight: 700; font-size: 14px; }
.toc { border: 1px solid var(--line); border-radius: 16px; padding: 0 18px; background: var(--surface); }
.toc summary { list-style: none; cursor: pointer; display: flex; justify-content: space-between; align-items: center; min-height: 52px; margin: 0; }
.toc summary::-webkit-details-marker { display: none; }
.toc summary::after { content: ''; width: 8px; height: 8px; border-right: 2px solid var(--muted); border-bottom: 2px solid var(--muted); transform: rotate(45deg) translateY(-3px); transition: transform .15s; }
.toc details[open] summary::after { transform: rotate(-135deg) translateY(-3px); }
.toc details[open] ol { padding-bottom: 14px; }
@media (min-width: 1000px) { .toc summary { min-height: 0; margin: 0 0 10px; cursor: default; pointer-events: none; } .toc summary::after { display: none; } }
@media (min-width: 1000px) { .toc { border: 0; padding: 0; background: none; } }
.toc ol { list-style: none; margin: 0; padding: 0; font-size: 14px; line-height: 1.45; }
@media (min-width: 1000px) { .toc ol { border-left: 1px solid var(--line); } }
.toc li a { display: block; padding: 6px 0; color: var(--muted); text-decoration: none; }
@media (min-width: 1000px) { .toc li a { padding-left: 16px; margin-left: -1px; border-left: 2px solid transparent; } }
.toc li a:hover { color: var(--ink); }
.toc li a[aria-current="true"] { color: var(--accent-ink); font-weight: 600; border-left-color: var(--accent); }
.share { display: none; }
@media (min-width: 1000px) { .share { display: block; margin-top: 32px; } }
.share-btn { display: inline-flex; align-items: center; min-height: 36px; padding: 0 14px; margin: 0 6px 6px 0; border-radius: 10px; border: 1px solid var(--line); background: var(--surface); color: var(--ink); font: 500 13px var(--sans); text-decoration: none; cursor: pointer; }
.share-btn:hover { border-color: var(--muted); }

.prose { max-width: 68ch; font-size: 18px; line-height: 1.75; overflow-wrap: break-word; }
.prose > :first-child { margin-top: 0; }
.prose h2 { font: 500 clamp(26px, 2.6vw, 32px)/1.2 var(--display); letter-spacing: -0.01em; margin: 56px 0 14px; text-wrap: balance; }
.prose h3 { font-size: 19px; line-height: 1.4; margin: 36px 0 8px; }
.prose p, .prose ul, .prose ol { margin: 0 0 20px; }
.prose ul, .prose ol { padding-left: 24px; }
.prose li { margin: 8px 0; padding-left: 4px; }
.prose li::marker { color: var(--accent); }
.prose strong { font-weight: 700; }
.prose a { text-decoration-thickness: 1px; text-underline-offset: 3px; }
.prose blockquote { margin: 28px 0; padding: 18px 22px; border-radius: 16px; background: var(--subtle); border: 1px solid var(--line); font-size: 16px; line-height: 1.65; }
.prose blockquote p:last-child { margin: 0; }
.prose code { background: var(--subtle); padding: 2px 6px; border-radius: 6px; font-size: .88em; }
.prose hr { border: 0; border-top: 1px solid var(--line); margin: 48px 0; }
.table-wrap { overflow-x: auto; margin: 8px 0 28px; border: 1px solid var(--line); border-radius: 16px; background: var(--surface); }
.prose table { border-collapse: collapse; width: 100%; font-size: 15px; line-height: 1.5; }
.prose th, .prose td { padding: 12px 16px; text-align: left; border-bottom: 1px solid var(--line); vertical-align: top; }
.prose th { background: var(--subtle); font-weight: 700; white-space: nowrap; font-size: 14px; }
.prose td { min-width: 120px; }
.prose td:first-child { font-weight: 600; }
.prose tr:last-child td { border-bottom: 0; }
/* The questions section reads as a list of answers rather than more article. */
.prose #frequently-asked-questions ~ h3 { margin-top: 0; padding-top: 22px; border-top: 1px solid var(--line); }

.related { margin: 72px 0 48px; }
.related > h2 { font: 500 30px/1.2 var(--display); margin: 0 0 20px; }

@media (prefers-reduced-motion: no-preference) { html { scroll-behavior: smooth; } }
@media (prefers-reduced-motion: reduce) { * { transition: none !important; } }
/* The direct answer at the top of a post (front matter "answer"): what answer engines and skimmers quote. */
.quick-answer { margin: 0 0 32px; padding: 18px 22px; border-radius: 16px; background: var(--accent-soft); border: 1px solid var(--line); border-left: 4px solid var(--accent); font-size: 17px; line-height: 1.65; }
.quick-answer .qa-label { margin: 0 0 6px; font-size: 12px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--accent-ink); }
.quick-answer p:last-child { margin: 0; }

/* Topic colours, generated from scripts/blog-art.mjs */
.t-guest-photo-sharing{--tint:#F9EDCC;--tint-ink:#8A5A00}.dark .t-guest-photo-sharing{--tint:#3A2E12;--tint-ink:#EBC56A}
.t-photo-delivery{--tint:#E3EFD9;--tint-ink:#3E6B2A}.dark .t-photo-delivery{--tint:#1F2E1A;--tint-ink:#A6D18D}
.t-ai-and-face-search{--tint:#E8E1FA;--tint-ink:#5B43A8}.dark .t-ai-and-face-search{--tint:#2C2448;--tint-ink:#CDBEFA}
.t-studio-business{--tint:#FCE3CF;--tint-ink:#9A4A12}.dark .t-studio-business{--tint:#3A2416;--tint-ink:#F2A877}
.t-comparisons{--tint:#E2E8F3;--tint-ink:#34507A}.dark .t-comparisons{--tint:#1C2433;--tint-ink:#9DB6DE}
.t-for-couples{--tint:#F6DDE2;--tint-ink:#8E2340}.dark .t-for-couples{--tint:#3A1A24;--tint-ink:#F29BB2}
