/* ==========================================================================
   AboutStack guides (/guides/). Plain CSS (no Tailwind build needed), flat
   brand style: crisp ink/hairline edges, amber caps, brand blue, no blurred
   drop shadows. Everything is prefixed g- so it can't leak into the app.
   ========================================================================== */

.g-page {
  --ink: #0b1220;
  --ink-2: #1f2937;
  --muted: #5b6474;
  --line: #d6dce8;
  --line-soft: #e8ecf3;
  --wash: #f6f8fc;
  --blue: #2451f0;
  --blue-d: #1c39a3;
  --blue-50: #eef4ff;
  --blue-100: #dbe6ff;
  --sky: #7fb2ff;
  --amber: #fbcb2b;
  --amber-50: #fffbea;
  --amber-d: #8f5a10;
  --green: #15803d;
  --green-50: #ecfdf3;
  --red: #b42318;
  --red-50: #fef3f2;
  --radius: 14px;
  --measure: 44rem;
}

/* Components set display:flex/grid, which would otherwise beat [hidden]. */
.g-page [hidden] { display: none !important; }

/* ---------- reading progress ---------- */
.g-progress { position: fixed; top: 64px; left: 0; right: 0; height: 3px; z-index: 49; pointer-events: none; }
.g-progress span { display: block; height: 100%; width: 100%; background: var(--amber); transform-origin: 0 50%; transform: scaleX(var(--p, 0)); }

.g-preview { position: relative; z-index: 2; margin-top: 64px; background: var(--amber-50); border-bottom: 1px solid #f3dd8a; color: var(--amber-d); text-align: center; font-size: 14px; padding: 10px 16px; }
.g-preview + .g-hero { padding-top: 0; }
.g-preview code { font-size: 12.5px; background: #fff3c4; padding: 1px 5px; border-radius: 4px; }

/* ---------- hero ---------- */
.g-hero { position: relative; overflow: hidden; padding-top: 64px; color: #fff; }
.g-hero-grid { position: absolute; inset: 0; pointer-events: none; }
.g-hero-inner { position: relative; z-index: 1; max-width: 52rem; margin: 0 auto; padding: 44px 20px 52px; }
.g-hero-edge { position: absolute; left: 0; right: 0; bottom: 0; height: 4px; background: var(--amber); }
.g-crumbs ol { display: flex; flex-wrap: wrap; gap: 6px; list-style: none; margin: 0 0 22px; padding: 0; font-size: 13px; font-weight: 600; }
.g-crumbs li { color: rgba(255,255,255,.62); }
.g-crumbs li + li::before { content: "/"; margin-right: 6px; color: rgba(255,255,255,.35); }
.g-crumbs a { color: rgba(255,255,255,.82); text-decoration: none; }
.g-crumbs a:hover { color: #fff; text-decoration: underline; }
.g-crumbs [aria-current] { color: var(--amber); }
.g-eyebrow { margin: 0 0 14px; font-size: 12px; font-weight: 800; letter-spacing: .14em; text-transform: uppercase; color: #fadb5f; }
.g-title { margin: 0; font-size: clamp(2rem, 4.6vw, 3.35rem); line-height: 1.06; letter-spacing: -.03em; font-weight: 800; text-wrap: balance; }
.g-dek { margin: 18px 0 0; max-width: 40rem; font-size: clamp(1.05rem, 1.6vw, 1.2rem); line-height: 1.55; color: rgba(255,255,255,.84); text-wrap: pretty; }
.g-meta { display: flex; align-items: center; gap: 12px; margin-top: 26px; }
.g-avatar { flex: none; display: inline-flex; align-items: center; justify-content: center; width: 42px; height: 42px; border-radius: 50%; background: var(--amber); color: var(--ink); font-weight: 800; font-size: 14px; border: 2px solid #fff; }
.g-avatar-lg { width: 56px; height: 56px; font-size: 18px; border-color: var(--ink); }
.g-avatar-logo { background: #fff; overflow: hidden; }
.g-avatar-logo img { width: 72%; height: 72%; object-fit: contain; }
.g-meta-text { display: flex; flex-direction: column; line-height: 1.3; }
.g-meta-name { font-weight: 700; font-size: 15px; }
.g-meta-sub { font-size: 13.5px; color: rgba(255,255,255,.72); }
.g-badges { display: flex; flex-wrap: wrap; gap: 8px; list-style: none; margin: 22px 0 0; padding: 0; }
.g-badges li { font-size: 12.5px; font-weight: 700; padding: 6px 12px; border-radius: 999px; background: rgba(255,255,255,.1); border: 1px solid rgba(255,255,255,.35); }
.g-badges li:first-child { background: var(--amber); color: var(--ink); border-color: var(--ink); }

/* ---------- layout ---------- */
.g-layout { max-width: 72rem; margin: 0 auto; padding: 36px 20px 24px; display: grid; gap: 28px; }
@media (min-width: 1100px) {
  .g-layout { grid-template-columns: 15rem minmax(0, var(--measure)); justify-content: center; gap: 56px; padding-top: 52px; }
}
.g-article { min-width: 0; }

/* table of contents */
.g-toc-box { border: 1px solid var(--line); border-radius: var(--radius); background: #fff; }
.g-toc-box summary { cursor: pointer; list-style: none; padding: 14px 16px; font-size: 12px; font-weight: 800; letter-spacing: .12em; text-transform: uppercase; color: var(--muted); display: flex; justify-content: space-between; }
.g-toc-box summary::-webkit-details-marker { display: none; }
.g-toc-box summary::after { content: "+"; font-size: 16px; line-height: 1; color: var(--ink); }
.g-toc-box[open] summary::after { content: "–"; }
.g-toc ol { list-style: none; margin: 0; padding: 0 8px 12px; counter-reset: toc; }
.g-toc li { counter-increment: toc; }
.g-toc a { display: grid; grid-template-columns: 1.6rem 1fr; padding: 7px 8px; border-radius: 8px; font-size: 14px; line-height: 1.35; color: var(--ink-2); text-decoration: none; border-left: 3px solid transparent; }
.g-toc a::before { content: counter(toc, decimal-leading-zero); font-size: 11.5px; font-weight: 700; color: #9aa3b2; padding-top: 2px; }
.g-toc a:hover { background: var(--wash); }
.g-toc a.is-active { background: var(--blue-50); color: var(--blue-d); font-weight: 700; border-left-color: var(--blue); }
.g-toc a.is-active::before { color: var(--blue); }
@media (min-width: 1100px) {
  .g-toc { position: sticky; top: 92px; align-self: start; max-height: calc(100vh - 110px); overflow: auto; }
  .g-toc-box { border: 0; background: transparent; }
  .g-toc-box summary { pointer-events: none; padding: 0 8px 10px; }
  .g-toc-box summary::after { content: none; }
  .g-toc ol { padding: 0; }
}

/* ---------- prose ---------- */
.g-prose { font-size: 18px; line-height: 1.72; color: var(--ink-2); }
.g-prose > * + * { margin-top: 1.1em; }
.g-prose p { margin: 0; text-wrap: pretty; }
.g-prose > p + p { margin-top: .9em; }
.g-prose h2 { margin: 2.6em 0 0; padding-top: .2em; font-size: clamp(1.55rem, 2.6vw, 1.95rem); line-height: 1.18; letter-spacing: -.022em; font-weight: 800; color: var(--ink); scroll-margin-top: 96px; text-wrap: balance; }
.g-prose h2 + * { margin-top: .75em; }
.g-prose h3 { margin: 1.9em 0 0; font-size: 1.2rem; line-height: 1.3; font-weight: 800; color: var(--ink); scroll-margin-top: 96px; }
.g-prose strong { color: var(--ink); font-weight: 700; }
.g-prose a { color: var(--blue); text-decoration: underline; text-decoration-thickness: 1.5px; text-underline-offset: 3px; text-decoration-color: rgba(36,81,240,.35); }
.g-prose a:hover { text-decoration-color: var(--blue); }
.g-prose a.g-btn { color: var(--ink); text-decoration: none; }
.g-prose ul, .g-prose ol { margin: 0; padding-left: 1.35em; }
.g-prose ul { list-style: disc; }
.g-prose ol { list-style: decimal; }
.g-sources ol { list-style: decimal; }
.g-prose li { margin: .45em 0; padding-left: .2em; }
.g-prose li::marker { color: var(--blue); font-weight: 700; }
.g-prose code { font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: .84em; background: var(--blue-50); color: var(--blue-d); padding: .12em .4em; border-radius: 6px; word-break: break-word; }
.g-prose em { color: var(--ink); }
.g-prose blockquote { margin: 1.5em 0; padding: 4px 0 4px 20px; border-left: 4px solid var(--amber); color: var(--ink); font-size: 1.05em; }
.g-prose hr { border: 0; border-top: 1px solid var(--line); margin: 2.5em 0; }
.g-prose > ul li em, .g-prose > ul li > em { font-style: italic; }
.g-prose :focus-visible, .g-page :focus-visible { outline: 3px solid #fadb5f; outline-offset: 2px; border-radius: 4px; }

/* tables */
.g-table { margin: 1.6em 0; overflow-x: auto; border: 1px solid var(--line); border-radius: var(--radius); }
.g-table table { width: 100%; border-collapse: collapse; font-size: 15.5px; line-height: 1.45; min-width: 34rem; }
.g-table th { text-align: left; background: var(--wash); font-size: 12.5px; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); font-weight: 800; padding: 12px 14px; border-bottom: 1px solid var(--line); }
.g-table td { padding: 13px 14px; border-top: 1px solid var(--line-soft); vertical-align: top; }
.g-table tr:last-child td { background: var(--blue-50); }
.g-table tr:last-child td:first-child { box-shadow: inset 4px 0 0 var(--blue); }

/* method details */
.g-method { margin-top: 1.8em; border: 1px solid var(--line); border-radius: var(--radius); background: var(--wash); font-size: 16px; line-height: 1.65; }
.g-method summary { cursor: pointer; padding: 15px 18px; font-weight: 700; color: var(--ink); list-style: none; display: flex; align-items: center; gap: 10px; }
.g-method summary::-webkit-details-marker { display: none; }
.g-method summary::before { content: "▸"; color: var(--blue); transition: transform .2s; }
.g-method[open] summary::before { transform: rotate(90deg); }
.g-method > :not(summary) { margin: 0 18px 14px; }
.g-method ul { padding-left: 1.2em; }

/* ---------- shared bits ---------- */
.g-btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; padding: 14px 24px; border-radius: 12px; font-weight: 800; font-size: 16px; text-decoration: none; white-space: nowrap; }
.g-tone-blue { --tone: var(--blue); --tone-bg: var(--blue-50); }
.g-tone-sky { --tone: var(--sky); --tone-bg: #eef5ff; }
.g-tone-amber { --tone: var(--amber); --tone-bg: var(--amber-50); }
.g-tone-ink { --tone: var(--ink); --tone-bg: #eef0f4; }
.g-tone-wait { --tone: #9aa3b2; --tone-bg: var(--wash); }
.g-chart-title { margin: 0 0 14px !important; font-size: 13px; font-weight: 800; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); line-height: 1.4; }
figure.g-chart figcaption, .g-stats figcaption, .g-labels figcaption, .g-browser figcaption, .g-form-mock figcaption, .g-lp figcaption { margin-top: 12px; font-size: 14px; line-height: 1.5; color: var(--muted); }
.sr-only { position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0; }

/* ---------- quick answer ---------- */
.g-answer { margin: 0 0 1.6em !important; border: 2px solid var(--ink); border-radius: 18px; background: #fff; overflow: hidden; }
.g-answer-kicker { margin: 0 !important; padding: 11px 18px; background: var(--amber); border-bottom: 2px solid var(--ink); font-size: 13px; font-weight: 800; letter-spacing: .1em; text-transform: uppercase; color: var(--ink); }
.g-answer-body ul { list-style: none; margin: 0; padding: 0; }
.g-answer-body li { margin: 0; padding: 14px 18px 14px 52px; position: relative; font-size: 17px; line-height: 1.55; border-top: 1px solid var(--line-soft); }
.g-answer-body li:first-child { border-top: 0; }
.g-answer-body li::before { content: "→"; position: absolute; left: 18px; top: 13px; width: 24px; height: 24px; border-radius: 50%; background: var(--blue-50); color: var(--blue); font-weight: 800; font-size: 14px; display: flex; align-items: center; justify-content: center; }
.g-answer-body strong { display: block; color: var(--ink); }

/* ---------- decision helper ---------- */
.g-helper { margin: 2em 0 !important; border: 1px solid var(--line); border-top: 4px solid var(--blue); border-radius: 18px; background: var(--wash); padding: 22px; }
.g-helper-kicker { margin: 0 0 14px !important; font-size: 1.15rem; font-weight: 800; color: var(--ink); line-height: 1.3; }
.g-helper-qs { display: grid; gap: 16px; }
.g-helper-q { margin: 0; padding: 0; border: 0; min-width: 0; }
.g-helper-q legend { display: flex; align-items: center; gap: 10px; padding: 0; margin-bottom: 9px; font-size: 15.5px; font-weight: 700; color: var(--ink); line-height: 1.35; }
.g-helper-n { flex: none; display: inline-flex; align-items: center; justify-content: center; width: 24px; height: 24px; border-radius: 50%; background: var(--ink); color: #fff; font-size: 12.5px; font-weight: 800; }
.g-helper-q[data-hidden] { display: none; }
.g-chips { display: flex; flex-wrap: wrap; gap: 8px; }
.g-chip { position: relative; cursor: pointer; }
.g-chip input { position: absolute; opacity: 0; inset: 0; cursor: pointer; margin: 0; }
.g-chip span { display: inline-flex; align-items: center; min-height: 40px; padding: 8px 14px; border-radius: 999px; border: 1.5px solid var(--line); background: #fff; font-size: 14.5px; font-weight: 600; color: var(--ink-2); line-height: 1.25; transition: border-color .15s, background-color .15s; }
.g-chip:hover span { border-color: var(--blue); }
.g-chip input:checked + span { background: var(--ink); border-color: var(--ink); color: #fff; }
.g-chip input:focus-visible + span { outline: 3px solid #fadb5f; outline-offset: 2px; }
.g-helper-outcomes { margin-top: 18px; display: grid; gap: 12px; }
.g-outcome { background: #fff; border: 2px solid var(--ink); border-radius: 14px; padding: 16px 18px; }
.g-outcome-wait { border-color: #9aa3b2; }
.g-outcome-warn { border-color: var(--amber-d); background: var(--amber-50); }
.g-outcome-if { margin: 0 0 4px !important; font-size: 13px; font-weight: 700; color: var(--muted); }
.g-js .g-outcome-if { display: none; }
.g-js .g-outcome { display: none; }
.g-js .g-outcome.is-match { display: block; animation: g-pop .28s cubic-bezier(.22,1,.36,1); }
.g-outcome-title { margin: 0 !important; font-size: 1.2rem; font-weight: 800; color: var(--ink); line-height: 1.3; }
.g-outcome-title::before { content: "✓ "; color: var(--green); }
.g-outcome-wait .g-outcome-title::before { content: "○ "; color: #9aa3b2; }
.g-outcome-warn .g-outcome-title::before { content: "! "; color: var(--amber-d); }
.g-outcome-answer { margin: 10px 0 0 !important; display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.g-outcome-answer span { font-size: 12px; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
.g-outcome-answer code { font-size: 15px !important; background: var(--blue-50); padding: 6px 10px !important; }
.g-outcome-body { margin-top: 8px; font-size: 16px; line-height: 1.6; }
.g-outcome-body p { margin: 0; }
@keyframes g-pop { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }

/* ---------- form mock ---------- */
.g-form-mock { margin: 2em 0 !important; }
.g-fm-window, .g-browser-window { border: 2px solid var(--ink); border-radius: 16px; overflow: hidden; background: #fff; }
.g-fm-bar { display: flex; align-items: center; gap: 6px; padding: 10px 14px; background: #eef1f6; border-bottom: 1px solid var(--line); }
.g-fm-bar span { width: 10px; height: 10px; border-radius: 50%; background: #c9d0dc; }
.g-fm-bar span:first-child { background: #ff6b6b; } .g-fm-bar span:nth-child(2) { background: var(--amber); } .g-fm-bar span:nth-child(3) { background: #3ccf7a; }
.g-fm-bar em { margin-left: 10px; flex: 1; font-style: normal; font-size: 12.5px; color: var(--muted); background: #fff; border: 1px solid var(--line); border-radius: 999px; padding: 3px 12px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; font-family: ui-monospace, Menlo, monospace; }
.g-fm-body { padding: 22px 22px 24px; display: grid; gap: 14px; background: linear-gradient(#fff, #fafbfd); }
.g-fm-role { margin: 0 0 4px !important; font-size: 18px; font-weight: 800; color: var(--ink); line-height: 1.3; }
.g-fm-role small { display: block; font-size: 13.5px; font-weight: 500; color: var(--muted); }
.g-fm-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.g-fm-field { display: grid; gap: 6px; font-size: 13.5px; font-weight: 700; color: var(--ink-2); }
.g-fm-field b { color: var(--red); }
.g-fm-opt { font-style: normal; font-weight: 600; font-size: 11.5px; color: var(--muted); background: var(--wash); border: 1px solid var(--line); border-radius: 999px; padding: 1px 8px; margin-left: 4px; }
.g-fm-input { display: flex; align-items: center; min-height: 42px; padding: 9px 12px; border: 1.5px solid var(--line); border-radius: 10px; background: #fff; font-weight: 500; font-size: 14.5px; color: var(--ink); overflow: hidden; white-space: nowrap; font-family: ui-monospace, Menlo, monospace; }
.g-fm-grid .g-fm-input { font-family: inherit; }
.g-fm-file { font-family: inherit !important; justify-content: space-between; }
.g-fm-file i { font-style: normal; font-size: 12px; font-weight: 700; color: var(--green); background: var(--green-50); border-radius: 999px; padding: 2px 9px; }
.g-fm-field.is-focus > span:first-child { color: var(--blue-d); }
.g-fm-field.is-focus .g-fm-input { border-color: var(--blue); box-shadow: 0 0 0 4px rgba(36,81,240,.14); }
.g-fm-caret { display: inline-block; width: 2px; height: 1.15em; background: var(--blue); margin-left: 1px; animation: g-blink 1s steps(1) infinite; }
[data-fm-label] { transition: opacity .25s; }
[data-fm-label].is-swapping { opacity: 0; }
.g-fm-submit { justify-self: start; margin-top: 4px; padding: 10px 18px; border-radius: 10px; background: var(--blue); color: #fff; font-weight: 700; font-size: 14px; }
@keyframes g-blink { 50% { opacity: 0; } }

/* ---------- browser frame ---------- */
.g-browser { margin: 2em auto !important; max-width: 34rem; }
.g-browser-shot { max-height: 30rem; overflow: hidden; position: relative; }
.g-browser-shot img { display: block; width: 100%; height: auto; }
.g-browser-shot::after { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 70px; background: linear-gradient(rgba(255,255,255,0), #fff); }
.g-browser figcaption a { font-weight: 700; color: var(--blue); }

/* ---------- stats ---------- */
.g-stats { margin: 1.8em 0 !important; }
.g-stats ul { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
@media (min-width: 720px) { .g-stats ul { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
.g-stat { margin: 0 !important; padding: 16px 16px 18px !important; border: 1px solid var(--line); border-top: 4px solid var(--blue); border-radius: 14px; background: #fff; display: flex; flex-direction: column; gap: 6px; }
.g-stat-amber { border-top-color: var(--amber); }
.g-stat-ink { border-top-color: var(--ink); }
.g-stat-value { font-size: clamp(2rem, 4vw, 2.6rem); font-weight: 800; letter-spacing: -.04em; line-height: 1; color: var(--ink); font-variant-numeric: tabular-nums; }
.g-stat-label { font-size: 14.5px; line-height: 1.4; color: var(--ink-2); }
.g-stat-detail { margin-top: auto; font-size: 12.5px; font-weight: 600; color: var(--muted); }

/* ---------- bar chart ---------- */
.g-chart { margin: 2em 0 !important; padding: 20px; border: 1px solid var(--line); border-radius: 16px; background: #fff; }
.g-chart-legend { display: flex; flex-wrap: wrap; gap: 6px 16px; list-style: none; margin: -4px 0 16px; padding: 0; font-size: 13.5px; color: var(--ink-2); }
.g-chart-legend li { display: flex; align-items: center; gap: 7px; margin: 0; padding: 0; }
.g-swatch { width: 12px; height: 12px; border-radius: 3px; background: var(--tone); border: 1px solid var(--ink); }
.g-chart-rows { display: grid; gap: 18px; }
.g-chart-row { display: grid; gap: 8px; }
@media (min-width: 640px) { .g-chart-row { grid-template-columns: 7.5rem 1fr; align-items: center; } }
.g-chart-label { font-weight: 800; font-size: 15px; color: var(--ink); }
.g-chart-label small { display: block; font-weight: 500; color: var(--muted); font-size: 12.5px; }
.g-chart-bars { display: grid; gap: 5px; }
.g-bar { position: relative; display: block; height: 24px; background: var(--wash); border-radius: 6px; overflow: hidden; }
.g-bar-fill { position: absolute; inset: 0 auto 0 0; width: var(--w); background: var(--tone); border-right: 2px solid var(--ink); border-radius: 6px; transform-origin: 0 50%; }
.g-bar[style*="--w: 0%"] .g-bar-fill { border-right: 0; }
.g-js .g-chart:not(.is-in) .g-bar-fill { transform: scaleX(0); }
.g-chart.is-in .g-bar-fill { transition: transform .9s cubic-bezier(.22,1,.36,1); }
.g-bar-val { position: absolute; left: 8px; top: 50%; transform: translateY(-50%); font-size: 12.5px; font-weight: 800; color: var(--ink); white-space: nowrap; }
.g-bar-val small { font-weight: 600; opacity: .7; }
/* Before the bars grow in, white labels would sit on the pale track: keep them ink until the fill is under them. */
.g-js .g-chart:not(.is-in) .g-bar-val { color: var(--ink) !important; }
.g-chart.is-in .g-bar-val { transition: color .2s ease .45s; }
.g-tone-blue .g-bar-val { color: #fff; }
.g-tone-blue.g-bar[style*="--w: 0%"] .g-bar-val, .g-tone-blue.g-bar[style*="--w: 5%"] .g-bar-val, .g-tone-blue.g-bar[style*="--w: 10%"] .g-bar-val { color: var(--ink); left: calc(var(--w) + 8px); }
.g-bar[style*="--w: 0%"] .g-bar-val, .g-bar[style*="--w: 5%"] .g-bar-val, .g-bar[style*="--w: 10%"] .g-bar-val { left: calc(var(--w) + 8px); }

/* ---------- label cloud ---------- */
.g-labels { margin: 1.6em 0 !important; padding: 20px; border: 1px solid var(--line); border-radius: 16px; background: var(--wash); }
.g-labels ul { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 10px; }
.g-label-pill { margin: 0 !important; padding: 0 !important; display: inline-flex; align-items: stretch; border: 1.5px solid var(--ink); border-radius: 10px; background: #fff; overflow: hidden; font-size: 14px; line-height: 1.2; }
.g-label-text { padding: 8px 12px; font-weight: 700; color: var(--ink); }
.g-label-count { padding: 8px 10px; background: var(--ink); color: #fff; font-weight: 800; font-variant-numeric: tabular-nums; }
.g-label-where { padding: 8px 10px; font-size: 12px; font-weight: 600; color: var(--muted); border-left: 1px solid var(--line); align-self: center; }
.g-label-pill.is-big { font-size: 17px; border-width: 2px; }
.g-label-pill.is-big .g-label-count { background: var(--blue); }
.g-label-pill.is-mid { font-size: 15.5px; }

/* ---------- options ---------- */
.g-options { list-style: none !important; margin: 1.6em 0 !important; padding: 0 !important; display: grid; gap: 14px; counter-reset: none; }
.g-option { margin: 0 !important; padding: 18px 18px 16px !important; border: 1px solid var(--line); border-left: 5px solid var(--tone); border-radius: 14px; background: #fff; }
.g-option::marker { content: none; }
.g-option-head { display: flex; gap: 14px; align-items: flex-start; }
.g-option-rank { flex: none; width: 34px; height: 34px; border-radius: 10px; background: var(--tone-bg); border: 1.5px solid var(--ink); color: var(--ink); font-weight: 800; display: flex; align-items: center; justify-content: center; font-size: 15px; }
.g-option-title { margin: 0 !important; font-size: 1.12rem; font-weight: 800; color: var(--ink); line-height: 1.3; }
.g-option-verdict { margin: 2px 0 0 !important; font-size: 15px; color: var(--muted); line-height: 1.45; }
.g-option-facts { margin: 14px 0 0; display: grid; gap: 8px; font-size: 15.5px; line-height: 1.5; }
@media (min-width: 720px) { .g-option-facts { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; } }
.g-option-facts dt { font-size: 11.5px; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); margin-bottom: 2px; }
.g-option-facts dd { margin: 0; color: var(--ink-2); }
.g-option-example { margin: 12px 0 0 !important; display: flex; flex-wrap: wrap; align-items: center; gap: 8px; font-size: 14px; }
.g-option-example span { font-size: 11.5px; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }

/* ---------- link-preview gallery ---------- */
.g-lp { margin: 2em 0 !important; }
.g-lp-title { margin: 0 0 14px !important; font-size: 13px; font-weight: 800; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); line-height: 1.4; }
.g-lp-grid { list-style: none !important; margin: 0 !important; padding: 0 !important; display: grid; gap: 14px; }
@media (min-width: 720px) { .g-lp-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.g-lp-item { margin: 0 !important; padding: 16px !important; border: 1px solid var(--line); border-top: 5px solid var(--tone); border-radius: 14px; background: #fff; min-width: 0; }
.g-lp-item::marker { content: none; }
.g-lp-label { margin: 0 0 10px !important; font-weight: 800; color: var(--ink); font-size: 1.02rem; line-height: 1.3; }
.g-lp-card { border: 1px solid var(--line); border-radius: 12px; overflow: hidden; background: var(--wash); }
.g-lp-card.is-thumb { display: flex; align-items: stretch; }
.g-lp-img { display: block; width: 100%; height: auto; aspect-ratio: 1200 / 630; }
.g-lp-thumb { flex: none; width: 72px; display: flex; align-items: center; justify-content: center; background: var(--blue-100); color: var(--blue-d); font-weight: 800; font-size: 20px; }
.g-lp-page { display: flex; flex-direction: column; gap: 7px; padding: 16px 22px; aspect-ratio: 1200 / 630; background: #fff; border-bottom: 1px solid var(--line-soft); overflow: hidden; }
.g-lp-page i { display: block; height: 6px; border-radius: 3px; background: #dfe3ea; }
.g-lp-page i:nth-child(1) { width: 34%; height: 9px; background: #9fb2c9; }
.g-lp-page i:nth-child(3) { width: 92%; } .g-lp-page i:nth-child(4) { width: 76%; }
.g-lp-page i:nth-child(5) { width: 40%; height: 8px; background: #9fb2c9; margin-top: 6px; } .g-lp-page i:nth-child(6) { width: 88%; }
.g-lp-text { display: flex; flex-direction: column; gap: 2px; padding: 10px 12px 12px; min-width: 0; }
.g-lp-host { font-size: 12px; color: var(--muted); overflow-wrap: anywhere; }
.g-lp-head { font-size: 15px; font-weight: 700; color: var(--ink); line-height: 1.35; overflow-wrap: anywhere; }
.g-lp-head.is-empty { font-weight: 600; font-style: italic; color: var(--muted); }
.g-lp-desc { font-size: 13.5px; color: var(--ink-2); line-height: 1.4; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; overflow-wrap: anywhere; }
.g-lp-verdict { margin: 12px 0 0 !important; font-size: 15px; font-weight: 700; color: var(--ink); line-height: 1.45; }
.g-lp-found { margin: 6px 0 0 !important; padding-left: 1.1em !important; font-size: 14.5px; line-height: 1.5; color: var(--ink-2); }
.g-lp-found li { margin: 3px 0 !important; }

/* ---------- callouts ---------- */
.g-callout { margin: 1.8em 0 !important; display: flex; gap: 14px; padding: 18px 20px; border-radius: 14px; border: 1px solid var(--line); background: var(--wash); font-size: 16.5px; line-height: 1.62; }
.g-callout-icon { flex: none; width: 30px; height: 30px; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-weight: 800; background: var(--ink); color: #fff; font-size: 15px; }
.g-callout-title { margin: 0 0 4px !important; font-weight: 800; color: var(--ink); font-size: 17px; line-height: 1.35; }
.g-callout-body p { margin: 0; }
.g-callout-body p + p { margin-top: .6em; }
.g-callout-tip { background: var(--green-50); border-color: #b7e4c7; }
.g-callout-tip .g-callout-icon { background: var(--green); }
.g-callout-warning { background: var(--amber-50); border-color: #f3dd8a; }
.g-callout-warning .g-callout-icon { background: var(--amber); color: var(--ink); }
.g-callout-story { background: var(--blue-d); border-color: var(--blue-d); color: rgba(255,255,255,.88); }
.g-callout-story .g-callout-title { color: #fff; }
.g-callout-story .g-callout-icon { background: var(--amber); color: var(--ink); font-size: 22px; padding-top: 6px; }
.g-callout-data .g-callout-icon { background: var(--blue); }

/* ---------- link checker ---------- */
.g-checker { margin: 1.8em 0 !important; border: 2px solid var(--ink); border-radius: 18px; background: #fff; overflow: hidden; }
.g-checker-head { padding: 16px 20px; background: var(--ink); color: #fff; display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 4px 16px; }
.g-checker-kicker { margin: 0 !important; font-weight: 800; font-size: 1.1rem; }
.g-checker-note { margin: 0 !important; font-size: 13px; color: rgba(255,255,255,.7); }
.g-checker-form { display: flex; gap: 10px; padding: 18px 20px 6px; flex-wrap: wrap; }
.g-checker-form input { flex: 1 1 16rem; min-width: 0; min-height: 48px; padding: 10px 14px; border: 1.5px solid var(--line); border-radius: 12px; font: 500 15px ui-monospace, Menlo, monospace; color: var(--ink); background: var(--wash); }
.g-checker-form input:focus { outline: none; border-color: var(--blue); background: #fff; box-shadow: 0 0 0 4px rgba(36,81,240,.14); }
.g-checker-form button { min-height: 48px; padding: 0 20px; border-radius: 12px; font-weight: 800; font-size: 15px; cursor: pointer; }
.g-checker-examples { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 8px; padding: 6px 20px 16px; font-size: 13px; color: var(--muted); }
.g-checker-examples button { font: inherit; font-weight: 600; color: var(--blue-d); background: var(--blue-50); border: 1px solid var(--blue-100); border-radius: 999px; padding: 4px 10px; cursor: pointer; }
.g-checker-examples button:hover { border-color: var(--blue); }
.g-checker-out { border-top: 1px solid var(--line); padding: 16px 20px 20px; background: var(--wash); }
.g-checks { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.g-check { margin: 0 !important; padding: 0 0 0 32px !important; position: relative; font-size: 15.5px; line-height: 1.5; }
.g-check::before { position: absolute; left: 0; top: 1px; width: 22px; height: 22px; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size: 12px; font-weight: 800; }
.g-check-ok::before { content: "✓"; background: var(--green); color: #fff; }
.g-check-warn::before { content: "!"; background: var(--amber); color: var(--ink); }
.g-check-bad::before { content: "✕"; background: var(--red); color: #fff; }
.g-check b { color: var(--ink); }
.g-checker-clean { margin-top: 14px; display: flex; flex-wrap: wrap; align-items: center; gap: 8px 10px; padding: 12px 14px; background: #fff; border: 1.5px dashed var(--blue); border-radius: 12px; }
.g-checker-clean span { font-size: 12px; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
.g-checker-clean code { flex: 1 1 14rem; font-size: 14.5px !important; }
.g-copy { font: inherit; font-size: 13.5px; font-weight: 800; padding: 7px 14px; border-radius: 9px; border: 1.5px solid var(--ink); background: var(--amber); color: var(--ink); cursor: pointer; }
.g-checker-nojs { margin: 0 !important; padding: 16px 20px; font-size: 15px; }

/* ---------- dos / don'ts ---------- */
.g-dd { margin: 1.8em 0 !important; display: grid; gap: 14px; }
@media (min-width: 720px) { .g-dd { grid-template-columns: 1fr 1fr; } }
.g-dd-col { border-radius: 14px; padding: 16px 18px 8px; border: 1px solid; }
.g-dd-do { background: var(--green-50); border-color: #b7e4c7; }
.g-dd-dont { background: var(--red-50); border-color: #f7c6c1; }
.g-dd-head { margin: 0 0 8px !important; font-weight: 800; font-size: 15px; letter-spacing: .06em; text-transform: uppercase; display: flex; align-items: center; gap: 8px; }
.g-dd-do .g-dd-head { color: var(--green); }
.g-dd-dont .g-dd-head { color: var(--red); }
.g-dd ul { list-style: none; margin: 0; padding: 0; }
.g-dd li { margin: 0 0 10px !important; padding: 0 !important; font-size: 15.5px; line-height: 1.55; }
.g-dd code { background: rgba(255,255,255,.75) !important; }

/* ---------- timeline ---------- */
.g-timeline { list-style: none !important; margin: 1.8em 0 !important; padding: 0 !important; display: grid; gap: 0; position: relative; }
@media (min-width: 720px) {
  .g-timeline { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; }
  .g-timeline::before { content: ""; position: absolute; left: 12px; right: 12px; top: 11px; height: 3px; background: var(--line); }
}
.g-tl-step { margin: 0 !important; padding: 0 0 20px 34px !important; position: relative; }
.g-tl-step::before { content: ""; position: absolute; left: 10px; top: 22px; bottom: 0; width: 3px; background: var(--line); }
.g-tl-step:last-child::before { display: none; }
@media (min-width: 720px) { .g-tl-step { padding: 36px 0 0 !important; } .g-tl-step::before { display: none; } }
.g-tl-dot { position: absolute; left: 0; top: 0; width: 24px; height: 24px; border-radius: 50%; background: var(--tone); border: 3px solid #fff; box-shadow: 0 0 0 2px var(--ink); }
.g-tl-when { display: inline-block; font-size: 11.5px; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
.g-tl-title { margin: 2px 0 0 !important; font-weight: 800; color: var(--ink); font-size: 16px; line-height: 1.35; }
.g-tl-text { margin: 4px 0 0 !important; font-size: 14.5px; line-height: 1.5; color: var(--ink-2); }

/* ---------- in-article CTA ---------- */
.g-cta { margin: 2.2em 0 !important; display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 18px 24px; padding: 24px; border-radius: 18px; background: var(--blue); color: #fff; border: 2px solid var(--ink); position: relative; overflow: hidden; }
.g-cta::after { content: ""; position: absolute; right: -40px; top: -40px; width: 160px; height: 160px; border-radius: 50%; background: rgba(255,255,255,.08); pointer-events: none; }
.g-cta-text { flex: 1 1 20rem; }
.g-cta-text p { margin: 0; font-size: 16px; line-height: 1.55; color: rgba(255,255,255,.86); }
.g-cta-title { font-size: 1.3rem !important; font-weight: 800; color: #fff !important; line-height: 1.25 !important; margin-bottom: 6px !important; }
.g-cta-fine { margin-top: 8px !important; font-size: 13px !important; color: rgba(255,255,255,.65) !important; }

/* ---------- FAQ ---------- */
.g-faq { margin-top: 64px; }
.g-faq h2, .g-sources h2, .g-related h2 { margin: 0 0 16px; font-size: clamp(1.45rem, 2.4vw, 1.8rem); font-weight: 800; letter-spacing: -.02em; color: var(--ink); scroll-margin-top: 96px; }
.g-faq-item { border-top: 1px solid var(--line); }
.g-faq-item:last-child { border-bottom: 1px solid var(--line); }
.g-faq-item summary { cursor: pointer; list-style: none; display: flex; justify-content: space-between; gap: 16px; padding: 18px 2px; font-weight: 700; font-size: 17px; line-height: 1.4; color: var(--ink); }
.g-faq-item summary::-webkit-details-marker { display: none; }
.g-faq-item summary:hover { color: var(--blue-d); }
.g-faq-icon { flex: none; width: 24px; height: 24px; border-radius: 50%; border: 1.5px solid var(--ink); position: relative; margin-top: 1px; }
.g-faq-icon::before, .g-faq-icon::after { content: ""; position: absolute; left: 50%; top: 50%; width: 10px; height: 2px; background: var(--ink); transform: translate(-50%, -50%); }
.g-faq-icon::after { transform: translate(-50%, -50%) rotate(90deg); transition: transform .2s; }
.g-faq-item[open] .g-faq-icon { background: var(--amber); }
.g-faq-item[open] .g-faq-icon::after { transform: translate(-50%, -50%) rotate(0deg); }
.g-faq-a { padding: 0 2px 18px; font-size: 16.5px; line-height: 1.65; color: var(--ink-2); max-width: 40rem; }
.g-faq-a p { margin: 0; }

/* ---------- author, sources, related ---------- */
.g-author { margin-top: 48px; display: flex; gap: 16px; align-items: flex-start; padding: 20px; border: 1px solid var(--line); border-radius: 16px; background: var(--wash); }
.g-author-name { margin: 0; font-weight: 800; color: var(--ink); font-size: 16.5px; }
.g-author-name span { font-weight: 600; color: var(--muted); }
.g-author-bio { margin: 4px 0 0; font-size: 15.5px; line-height: 1.6; color: var(--ink-2); }
.g-sources { margin-top: 48px; }
.g-sources ol { margin: 0; padding-left: 1.4em; display: grid; gap: 10px; font-size: 15px; line-height: 1.5; color: var(--ink-2); }
.g-sources li::marker { color: var(--muted); font-weight: 700; }
.g-sources a { color: var(--blue); font-weight: 600; text-underline-offset: 3px; }
.g-sources li span { display: block; color: var(--muted); font-size: 14px; }
.g-related { margin-top: 48px; }
.g-related-grid { display: grid; gap: 12px; }
@media (min-width: 640px) { .g-related-grid { grid-template-columns: 1fr 1fr; } }
.g-related-card { display: flex; flex-direction: column; gap: 6px; padding: 18px; border: 1.5px solid var(--line); border-radius: 14px; text-decoration: none; color: var(--ink); background: #fff; transition: border-color .2s, transform .2s; }
.g-related-card:hover { border-color: var(--blue); transform: translateY(-2px); }
.g-related-eyebrow { font-size: 11.5px; font-weight: 800; letter-spacing: .1em; text-transform: uppercase; color: var(--blue); }
.g-related-title { font-weight: 800; font-size: 17px; line-height: 1.3; }
.g-related-go { margin-top: auto; font-weight: 700; font-size: 14px; color: var(--blue); }

/* ---------- final CTA band ---------- */
.g-final { margin-top: 72px; background: var(--ink); color: #fff; border-top: 4px solid var(--amber); }
.g-final + footer { margin-top: 0; }
.g-final-inner { max-width: 44rem; margin: 0 auto; padding: 56px 20px; text-align: center; }
.g-final-eyebrow { margin: 0 0 10px; font-size: 12px; font-weight: 800; letter-spacing: .14em; text-transform: uppercase; color: #fadb5f; }
.g-final h2 { margin: 0; font-size: clamp(1.7rem, 3.4vw, 2.4rem); line-height: 1.12; letter-spacing: -.025em; font-weight: 800; text-wrap: balance; }
.g-final p { margin: 14px auto 26px; max-width: 32rem; font-size: 17px; line-height: 1.6; color: rgba(255,255,255,.76); }
.g-final strong { color: #fff; }

/* ---------- index ---------- */
.g-index { max-width: 72rem; margin: 0 auto; padding: 48px 20px 16px; }
.g-index-grid { list-style: none; margin: 0; padding: 0; display: grid; gap: 20px; }
@media (min-width: 720px) { .g-index-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (min-width: 1100px) { .g-index-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
.g-index-card { display: flex; flex-direction: column; height: 100%; border: 1.5px solid var(--line); border-radius: 16px; overflow: hidden; text-decoration: none; color: var(--ink); background: #fff; transition: border-color .2s, transform .2s; }
.g-index-card:hover { border-color: var(--blue); transform: translateY(-3px); }
.g-index-card img { display: block; width: 100%; height: auto; aspect-ratio: 1200 / 630; object-fit: cover; border-bottom: 1px solid var(--line); background: var(--blue-50); }
.g-index-body { display: flex; flex-direction: column; gap: 8px; padding: 18px 18px 20px; flex: 1; }
.g-index-title { font-weight: 800; font-size: 1.2rem; line-height: 1.28; letter-spacing: -.01em; }
.g-index-desc { font-size: 15px; line-height: 1.55; color: var(--muted); }
.g-index-meta { margin-top: auto; padding-top: 6px; font-size: 13px; font-weight: 600; color: #8a93a3; }
.g-empty { text-align: center; color: var(--muted); padding: 40px 0; }

/* ---------- small screens ---------- */
@media (max-width: 640px) {
  .g-prose { font-size: 17px; }
  .g-hero-inner { padding: 32px 18px 40px; }
  .g-helper, .g-chart, .g-labels { padding: 16px; }
  .g-fm-body { padding: 16px; }
  .g-fm-grid { grid-template-columns: 1fr 1fr; gap: 10px; }
  .g-fm-input { font-size: 13px; }
  .g-cta { padding: 20px; }
  .g-cta .g-btn { width: 100%; }
  .g-answer-body li { padding-left: 46px; font-size: 16px; }
  .g-answer-body li::before { left: 14px; }
}

@media (prefers-reduced-motion: reduce) {
  .g-page *, .g-page *::before, .g-page *::after { animation: none !important; transition: none !important; }
  .g-js .g-chart:not(.is-in) .g-bar-fill { transform: none; }
}

@media print {
  .g-progress, .g-toc, .g-final, .g-checker, nav, footer { display: none !important; }
  .g-hero { color: var(--ink); background: none !important; }
  .g-js .g-outcome { display: block !important; }
}
