/* flatnumber Help — tokens mirror skills/flatnumber-design/colors_and_type.css (theme v2). Light only. */
@font-face { font-family: 'Outfit'; font-style: normal; font-weight: 100 900; font-display: swap; src: url('/assets/fonts/outfit-latin-wght-normal.woff2') format('woff2'); }
@font-face { font-family: 'Readex Pro'; font-style: normal; font-weight: 160 700; font-display: swap; src: url('/assets/fonts/readex-pro-latin-wght-normal.woff2') format('woff2'); }

:root {
  --fn-orange: #F66C02; --fn-orange-dark: #753400; --fn-orange-faint: #FEE5D1;
  --fg-1: #14181B; --fg-2: #57636C; --fg-muted: #95A1AC;
  --bg-canvas: #F1F4F8; --bg-surface: #FFFFFF; --input-fill: #F8FAFB;
  --border-1: #E0E3E7; --divider: #ECEEF1;
  --warning-soft: #FEF3D2; --warning-text: #7A5B00;
  --font-display: 'Outfit', system-ui, -apple-system, sans-serif;
  --font-body: 'Readex Pro', system-ui, -apple-system, sans-serif;
  --r-sm: 8px; --r-md: 16px; --r-button: 10px; --r-pill: 9999px;
  --gutter: 16px;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body { margin: 0; font-family: var(--font-body); font-weight: 300; font-size: 16px; line-height: 1.6; color: var(--fg-1); background: var(--bg-canvas); overflow-wrap: break-word; }
a { color: var(--fn-orange-dark); text-underline-offset: 3px; }
a:hover { color: var(--fn-orange); }
:focus-visible { outline: 2px solid var(--fn-orange); outline-offset: 2px; border-radius: 4px; }
h1, h2, h3 { font-family: var(--font-display); color: var(--fg-1); margin: 0; text-wrap: balance; }
h1 { font-weight: 600; font-size: 30px; line-height: 1.15; letter-spacing: -0.01em; }
.wrap { width: 100%; max-width: 1080px; margin: 0 auto; padding: 0 var(--gutter); }
.narrow { max-width: 760px; }

/* Header */
.site-header { background: var(--bg-surface); border-bottom: 1px solid var(--border-1); position: sticky; top: 0; z-index: 10; }
.site-header .wrap { display: flex; align-items: center; gap: 12px; min-height: 60px; }
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; }
.brand img { height: 26px; width: auto; display: block; }
.brand span { font-family: var(--font-display); font-weight: 500; font-size: 18px; color: var(--fg-2); padding-left: 10px; border-left: 1px solid var(--border-1); }
.header-cta { margin-left: auto; font-size: 14px; font-weight: 400; text-decoration: none; color: var(--fg-1); border: 1px solid var(--border-1); border-radius: var(--r-button); padding: 8px 14px; white-space: nowrap; }
.header-cta:hover { border-color: var(--fn-orange); color: var(--fn-orange-dark); }

/* Draft banner */
.draft-banner { background: var(--warning-soft); color: var(--warning-text); font-size: 14px; padding: 8px 0; border-bottom: 1px solid #f3e2a8; }

/* Home */
.hero { padding: 36px 0 8px; }
.hero p { color: var(--fg-2); margin: 8px 0 20px; max-width: 56ch; }
.search { position: relative; max-width: 560px; }
.search input { width: 100%; height: 52px; border: 1px solid var(--border-1); border-radius: var(--r-md); background: var(--bg-surface); padding: 0 16px 0 46px; font: inherit; font-weight: 400; color: var(--fg-1); }
.search input::placeholder { color: var(--fg-muted); }
.search svg { position: absolute; left: 16px; top: 16px; width: 20px; height: 20px; color: var(--fg-muted); pointer-events: none; }
.category { padding: 28px 0 0; }
.category h2 { font-weight: 600; font-size: 22px; }
.category > p { color: var(--fg-2); margin: 4px 0 14px; font-size: 15px; }
.cards { display: grid; gap: 12px; grid-template-columns: 1fr; list-style: none; padding: 0; margin: 0; }
.card { display: block; height: 100%; background: var(--bg-surface); border: 1px solid var(--border-1); border-radius: var(--r-md); padding: 16px; text-decoration: none; color: inherit; transition: border-color .2s ease-in-out; }
.card:hover { border-color: var(--fn-orange); color: inherit; }
.card h3 { font-weight: 500; font-size: 17px; line-height: 1.3; }
.card p { margin: 6px 0 0; color: var(--fg-2); font-size: 14px; line-height: 1.5; }
.badge { display: inline-block; font-size: 11px; font-weight: 500; letter-spacing: .04em; text-transform: uppercase; color: var(--fn-orange-dark); background: var(--fn-orange-faint); border-radius: var(--r-pill); padding: 2px 8px; margin-top: 10px; }
.empty { color: var(--fg-2); padding: 24px 0; }
[hidden] { display: none !important; }

/* Topic */
.crumbs { font-size: 14px; color: var(--fg-2); padding: 20px 0 10px; }
.crumbs a { color: var(--fg-2); }
.topic h1 { margin-bottom: 18px; }
.inshort { background: var(--bg-surface); border: 1px solid var(--border-1); border-radius: var(--r-md); padding: 18px 18px 6px; }
.inshort h2 { font-family: var(--font-body); font-size: 12px; font-weight: 500; letter-spacing: .06em; text-transform: uppercase; color: var(--fg-2); margin: 0 0 4px; }
.inshort p, .inshort ul { margin: 0 0 14px; }
.inshort ul { padding-left: 20px; }
.inshort li { margin-bottom: 4px; }
.watch { margin: 18px 0 0; }
.btn { display: inline-flex; align-items: center; gap: 8px; min-height: 44px; border: 0; border-radius: var(--r-button); background: var(--fn-orange); color: #fff; font: inherit; font-weight: 500; padding: 0 18px; cursor: pointer; }
.btn:hover { background: #dd6000; }
.btn svg { width: 18px; height: 18px; }
.watch small { display: block; color: var(--fg-2); margin-top: 6px; font-size: 13px; }
.anim-stage { margin: 16px auto 0; overflow: hidden; border-radius: var(--r-md); border: 1px solid var(--border-1); background: var(--bg-canvas); }
.anim-stage iframe { border: 0; display: block; transform-origin: top left; }

.article { background: var(--bg-surface); border: 1px solid var(--border-1); border-radius: var(--r-md); padding: 8px 18px 18px; margin-top: 18px; }
.article h2 { font-weight: 600; font-size: 22px; margin: 26px 0 8px; }
.article h3 { font-weight: 500; font-size: 18px; margin: 20px 0 6px; }
.article p, .article ul, .article ol { margin: 0 0 14px; }
.article ul, .article ol { padding-left: 22px; }
.article li { margin-bottom: 6px; }
.article li > ul { margin-top: 6px; }
.article strong { font-weight: 500; }
.article img { max-width: 100%; height: auto; border: 1px solid var(--border-1); border-radius: var(--r-sm); }
.article code { font-family: ui-monospace, Menlo, Consolas, monospace; font-size: .9em; background: var(--input-fill); border: 1px solid var(--divider); border-radius: 4px; padding: 1px 5px; }
.table-wrap { overflow-x: auto; margin: 0 0 14px; border: 1px solid var(--border-1); border-radius: var(--r-sm); }
table { border-collapse: collapse; width: 100%; font-size: 15px; }
th, td { text-align: left; vertical-align: top; padding: 10px 12px; border-bottom: 1px solid var(--divider); }
th { font-weight: 500; color: var(--fg-2); background: var(--input-fill); font-size: 13px; }
tr:last-child td { border-bottom: 0; }
td:first-child { min-width: 9em; }

.related { margin-top: 28px; }
.related h2 { font-weight: 600; font-size: 20px; margin-bottom: 12px; }
.meta { color: var(--fg-muted); font-size: 13px; margin-top: 20px; }

.site-footer { margin-top: 48px; border-top: 1px solid var(--border-1); background: var(--bg-surface); color: var(--fg-2); font-size: 14px; }
.site-footer .wrap { padding-top: 20px; padding-bottom: 28px; display: flex; flex-wrap: wrap; gap: 8px 20px; }
.site-footer a { color: var(--fg-2); }

@media (min-width: 640px) {
  :root { --gutter: 24px; }
  h1 { font-size: 38px; }
  .cards { grid-template-columns: repeat(2, 1fr); }
  .article { padding: 12px 28px 26px; }
  .inshort { padding: 22px 24px 8px; }
}
@media (min-width: 1000px) {
  .cards { grid-template-columns: repeat(3, 1fr); }
  .hero { padding-top: 56px; }
}
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } .card { transition: none; } }
@media print { .site-header, .site-footer, .watch, .related, .search { display: none; } body { background: #fff; } }
