/* Site-specific extensions on top of styles.css (the design tokens & primitives). */

/* Section rhythm */
.section { padding: 96px 0; }
.section-tight { padding: 64px 0; }
.section-eyebrow { margin-bottom: 18px; }
.display-h1 { font-family: var(--font-display); font-weight: 400; font-size: clamp(2.6rem, 5vw, 4.4rem); line-height: 1.02; letter-spacing: -0.02em; }
.display-h2 { font-family: var(--font-display); font-weight: 400; font-size: clamp(2rem, 3.6vw, 3.2rem); line-height: 1.06; letter-spacing: -0.015em; }
.display-h3 { font-family: var(--font-display); font-weight: 400; font-size: clamp(1.6rem, 2.4vw, 2.2rem); line-height: 1.1; letter-spacing: -0.01em; }
.lead { color: var(--ink-soft); font-size: 1.12rem; line-height: 1.55; max-width: 56ch; }

/* Grid helpers */
.grid { display: grid; gap: 24px; }
.grid-2 { grid-template-columns: 1.05fr 1fr; }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-4 { grid-template-columns: repeat(4, 1fr); }
.grid-6 { grid-template-columns: repeat(6, 1fr); }
@media (max-width: 1024px) {
  .grid-2, .grid-3, .grid-4 { grid-template-columns: 1fr; }
  .grid-6 { grid-template-columns: repeat(2, 1fr); }
}

/* Cards & strips */
.card-pad { padding: 28px; }
.card-pad-lg { padding: 40px; }
.dark-band { background: var(--ink); color: var(--bg); border-radius: var(--radius-lg); padding: 56px; }
.dark-band .lead { color: rgba(255,255,255,0.78); }

/* Tables */
.table { width: 100%; border-collapse: separate; border-spacing: 0; font-size: 0.95rem; }
.table thead th { text-align: left; font-weight: 500; color: var(--ink-soft); padding: 14px 12px; border-bottom: 1px solid var(--line); font-size: 0.82rem; text-transform: uppercase; letter-spacing: 0.06em; cursor: pointer; user-select: none; }
.table tbody td { padding: 16px 12px; border-bottom: 1px solid var(--line-soft); vertical-align: middle; }
.table tbody tr:hover { background: var(--bg-alt); }
.table th .sort-arrow { opacity: .35; margin-left: 4px; }
.table th.sort-asc .sort-arrow, .table th.sort-desc .sort-arrow { opacity: 1; color: var(--ink); }

/* Quiz */
.quiz-card { padding: 36px; }
.quiz-step { display: none; }
.quiz-step.active { display: block; }
.quiz-option { display: flex; align-items: center; justify-content: space-between; gap: 12px; width: 100%; padding: 16px 18px; border: 1px solid var(--line); background: var(--card); border-radius: 14px; text-align: left; transition: .15s; }
.quiz-option:hover { border-color: var(--ink); transform: translateY(-1px); }
.quiz-option.selected { border-color: var(--sage-deep); background: var(--sage-bg); }

/* FAQ */
.faq-item { border-bottom: 1px solid var(--line-soft); }
.faq-item summary { list-style: none; cursor: pointer; padding: 22px 0; display: flex; justify-content: space-between; align-items: center; gap: 18px; font-weight: 500; }
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::after { content: "+"; font-family: var(--font-mono); font-size: 1.4rem; color: var(--ink-mute); transition: transform .2s; }
.faq-item[open] summary::after { transform: rotate(45deg); }
.faq-item .faq-body { padding: 0 0 22px; color: var(--ink-soft); line-height: 1.6; }

/* Tabs */
.tabbar { display: flex; gap: 4px; border-bottom: 1px solid var(--line); margin-bottom: 32px; overflow-x: auto; }
.tab { padding: 14px 18px; color: var(--ink-soft); border-bottom: 2px solid transparent; white-space: nowrap; font-weight: 500; }
.tab:hover { color: var(--ink); }
.tab.active { color: var(--ink); border-bottom-color: var(--ink); }

/* Hero gradients per vertical */
.hero { padding: 80px 0 56px; }
.hero-radial { background: radial-gradient(ellipse 80% 60% at 50% 0%, var(--sage-bg), transparent 70%); }
.hero-coral  { background: radial-gradient(ellipse 80% 60% at 70% 0%, var(--coral-bg), transparent 65%); }
.hero-blue   { background: radial-gradient(ellipse 80% 60% at 30% 0%, oklch(0.95 0.03 250), transparent 65%); }
.hero-clay   { background: radial-gradient(ellipse 80% 60% at 50% 0%, oklch(0.94 0.04 60), transparent 65%); }
.hero-plum   { background: radial-gradient(ellipse 80% 60% at 50% 0%, oklch(0.94 0.03 320), transparent 65%); }

/* Best-for & vertical cards */
.cat-card { padding: 24px; transition: .2s; }
.cat-card:hover { transform: translateY(-3px); box-shadow: var(--shadow-md); }

/* Compare drawer */
.compare-drawer { position: fixed; left: 0; right: 0; bottom: 0; z-index: 80; background: var(--ink); color: var(--bg); transform: translateY(100%); transition: transform .25s ease; }
.compare-drawer.open { transform: translateY(0); }

/* Range slider tweaks */
input[type="range"] { -webkit-appearance: none; appearance: none; width: 100%; height: 6px; border-radius: 999px; background: var(--line); outline: none; }
input[type="range"]::-webkit-slider-thumb { -webkit-appearance: none; appearance: none; width: 22px; height: 22px; border-radius: 50%; background: var(--ink); cursor: pointer; }
input[type="range"]::-moz-range-thumb { width: 22px; height: 22px; border-radius: 50%; background: var(--ink); border: none; cursor: pointer; }

/* Inputs */
.input, .select, .textarea { width: 100%; padding: 12px 14px; border: 1px solid var(--line); border-radius: 12px; background: var(--card); color: var(--ink); font-family: inherit; font-size: 0.95rem; }
.input:focus, .select:focus, .textarea:focus { outline: none; border-color: var(--ink); }
.textarea { min-height: 120px; resize: vertical; }
.label { display: block; font-size: 0.82rem; color: var(--ink-soft); margin-bottom: 8px; font-weight: 500; }

/* Bar chart util */
.bar { height: 8px; background: var(--bg-alt); border-radius: 999px; overflow: hidden; }
.bar > span { display: block; height: 100%; background: var(--sage-deep); border-radius: 999px; }

/* Reading progress */
.read-progress { position: fixed; top: 0; left: 0; height: 3px; background: var(--coral); z-index: 100; width: 0%; transition: width .15s; }

/* Drop cap */
.dropcap::first-letter { font-family: var(--font-display); float: left; font-size: 4.6rem; line-height: 0.85; padding: 6px 10px 0 0; color: var(--ink); }

/* Article TOC */
.toc { position: sticky; top: 100px; align-self: start; }
.toc a { display: block; padding: 6px 0; color: var(--ink-mute); font-size: 0.92rem; border-left: 2px solid transparent; padding-left: 12px; }
.toc a.active { color: var(--ink); border-left-color: var(--ink); }

/* Misc */
.center { text-align: center; }
.muted { color: var(--ink-soft); }
.mute { color: var(--ink-mute); }
.text-coral { color: var(--coral); }
.text-sage { color: var(--sage-deep); }
.flex { display: flex; }
.flex-between { display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.gap-8 { gap: 8px; } .gap-12 { gap: 12px; } .gap-16 { gap: 16px; } .gap-24 { gap: 24px; }
.mt-8 { margin-top: 8px; } .mt-16 { margin-top: 16px; } .mt-24 { margin-top: 24px; } .mt-32 { margin-top: 32px; } .mt-48 { margin-top: 48px; }

/* Active state for filter pills (used on comparaison + articles) */
[data-pill-group] .btn.active,
.btn-ghost.active { background: var(--ink); color: var(--bg); border-color: var(--ink); }

/* Star picker (review form) */
[data-star-picker] [data-star].filled { color: var(--gold) !important; }

/* Notice banner (for missing config) */
.notice { background: oklch(0.95 0.05 80); color: oklch(0.35 0.1 60); padding: 10px 18px; font-size: 0.88rem; text-align: center; border-bottom: 1px solid oklch(0.85 0.05 80); }

/* Print styles for article reader */
@media print {
  .nav, .read-progress, .toc, footer { display: none !important; }
  body { background: white; color: black; }
  .container { max-width: 100%; padding: 0; }
}
