/* thativanng.com — one stylesheet. Tokens = the 夜藍 deck set (studio/shell-v7.mjs SETS.night), so a reader who arrives
   from a carousel lands on the same paper. Simple · bright · minimal · professional (Ivan 2026-09-19). */
:root {
  --paper: #FFFFFF;
  --ink: #111827;
  --slate: #4B5563;
  --fade: #7C8492;
  --seal: #C1272D;
  --hl: #FDE68A;
  --mist: #F7F8FA;
  --hair: rgba(17, 24, 39, .12);
  --grid: rgba(17, 24, 39, .045);
  --serif: 'Noto Serif TC', 'Songti TC', serif;
  --sans: 'Huninn', 'Noto Sans TC', 'PingFang TC', system-ui, sans-serif;   /* the deck body face (shell-v7 hun) */
  --mono: 'DM Mono', ui-monospace, monospace;
  --hand: 'LXGW WenKai TC', 'Kaiti TC', cursive;
  --col: 640px;
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0; color: var(--ink); font: 400 17px/1.95 var(--sans); letter-spacing: .02em;
  background-color: var(--paper);
  background-image: linear-gradient(var(--grid) 1px, transparent 1px), linear-gradient(90deg, var(--grid) 1px, transparent 1px);
  background-size: 28px 28px;
}
a { color: inherit; }
h1, h2, h3, .maxim { text-wrap: balance; line-break: strict; }
a:focus-visible, button:focus-visible, input:focus-visible { outline: 2px solid var(--seal); outline-offset: 3px; border-radius: 4px; }
.wrap { max-width: var(--col); margin: 0 auto; padding: 0 20px; }

/* furniture */
.topbar { display: flex; justify-content: space-between; align-items: center; padding: 22px 0 0; font: 500 13px/1 var(--mono); letter-spacing: .04em; color: var(--fade); }
.topbar a { text-decoration: none; }
.topbar a:hover { color: var(--ink); }
.stamp { display: inline-block; font: 700 13px/1 var(--sans); letter-spacing: .12em; color: var(--seal); border: 1.5px solid var(--seal); border-radius: 3px; padding: 5px 7px 4px; }
.meta { font: 500 13px/1.6 var(--mono); color: var(--fade); letter-spacing: .04em; }
.label { font: 500 12px/1 var(--mono); letter-spacing: .14em; color: var(--fade); text-transform: uppercase; margin: 0 0 14px; }

/* the signature: the card's highlighter stroke under one phrase */
.hl { background: linear-gradient(transparent 58%, var(--hl) 58%, var(--hl) 92%, transparent 92%); padding: 0 .08em; -webkit-box-decoration-break: clone; box-decoration-break: clone; }

/* ── HUB ─────────────────────────────────── */
.me { padding: 56px 0 8px; display: grid; grid-template-columns: 96px 1fr; gap: 22px; align-items: start; }
.me img { width: 96px; height: 96px; object-fit: cover; border: 2px solid var(--seal); border-radius: 14px; display: block; }
.me h1, .me h2 { margin: 2px 0 2px; font: 900 34px/1.2 var(--serif); letter-spacing: .02em; }
.me .role { font: 700 15px/1.5 var(--sans); color: var(--seal); letter-spacing: .06em; }
.me p { margin: 12px 0 0; color: var(--slate); font-size: 16px; line-height: 1.85; }
.me .hand { font: 700 19px/1.3 var(--hand); color: var(--ink); display: inline-block; transform: rotate(-1.5deg); margin-top: 10px; }
.maxim { margin: 34px 0 48px; padding: 4px 0 4px 18px; border-left: 4px solid var(--seal); font: 700 20px/1.7 var(--serif); }
.section { margin: 0 0 44px; }
.card { display: grid; grid-template-columns: 112px 1fr; gap: 18px; padding: 16px; background: var(--paper); border: 1px solid var(--hair); border-radius: 16px; text-decoration: none; transition: border-color .2s, transform .2s; }
.card + .card { margin-top: 14px; }
.card:hover { border-color: var(--ink); transform: translateY(-2px); }
.card img { width: 112px; aspect-ratio: 4 / 5; object-fit: cover; border-radius: 8px; display: block; }
.card h3 { margin: 10px 0 6px; font: 900 17px/1.55 var(--serif); }
.card p { margin: 0; color: var(--slate); font-size: 15px; line-height: 1.75; text-wrap: pretty; }
.card .go { display: inline-block; margin-top: 10px; font: 500 13px/1 var(--mono); color: var(--seal); letter-spacing: .04em; }
.card.text { grid-template-columns: 1fr; }
.links { display: flex; flex-wrap: wrap; gap: 10px; }
.links a { font: 500 14px/1 var(--mono); letter-spacing: .03em; text-decoration: none; padding: 11px 14px; border: 1px solid var(--hair); border-radius: 999px; background: var(--paper); }
.links a:hover { border-color: var(--ink); }
footer { padding: 36px 0 56px; font: 500 12px/1.6 var(--mono); color: var(--fade); letter-spacing: .04em; }

/* ── ARTICLE ─────────────────────────────── */
.head { padding: 44px 0 8px; }
.head .row { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.head h1 { margin: 22px 0 14px; font: 900 34px/1.45 var(--serif); letter-spacing: .02em; }
.head .dek { margin: 0; font-size: 18px; color: var(--slate); }
.head .ig { margin-top: 18px; font: 500 13px/1.6 var(--mono); color: var(--fade); }
.head .ig a { color: var(--seal); text-decoration: none; border-bottom: 1px solid currentColor; }
article { padding: 18px 0 40px; }
article p { margin: 0 0 1.25em; text-wrap: pretty; }
article h2 { margin: 2.2em 0 .9em; font: 700 23px/1.6 var(--serif); letter-spacing: .02em; }
article h2::before { content: ''; display: block; width: 28px; height: 4px; background: var(--seal); margin-bottom: 14px; }
article blockquote { margin: 0 0 1.25em; padding: 14px 18px; background: var(--mist); border-radius: 10px; font: 700 17px/2 var(--serif); }
article blockquote p { margin: 0; }
.figs { margin: 6px 0 1.4em; border-top: 1px solid var(--hair); }
.fig { display: grid; grid-template-columns: 112px 1fr; gap: 16px; padding: 16px 0; border-bottom: 1px solid var(--hair); align-items: baseline; }
.fig b { font: 500 32px/1.1 var(--mono); color: var(--seal); letter-spacing: -.01em; }
.fig span { display: block; font-weight: 500; line-height: 1.7; }
.fig small { display: block; margin-top: 4px; font: 400 12px/1.5 var(--mono); color: var(--fade); letter-spacing: .02em; }
.pairs { width: 100%; border-collapse: collapse; margin: 6px 0 1.4em; font-size: 16px; }
.pairs th { text-align: left; font: 500 12px/1 var(--mono); letter-spacing: .14em; color: var(--fade); padding: 0 0 10px; }
.pairs td { padding: 11px 0; border-top: 1px solid var(--hair); vertical-align: top; }
.pairs td:first-child { color: var(--fade); text-decoration: line-through; text-decoration-color: rgba(193, 39, 45, .55); width: 44%; }
.pairs td.arrow { width: 36px; color: var(--seal); font-family: var(--mono); }
.end { margin: 12px 0 0; padding: 22px; border: 1px solid var(--hair); border-radius: 16px; background: var(--paper); display: grid; grid-template-columns: 64px 1fr; gap: 16px; }
.end img { width: 64px; height: 64px; object-fit: cover; border-radius: 10px; border: 2px solid var(--seal); }
.end b { font: 900 18px/1.4 var(--serif); }
.end p { margin: 4px 0 0; font-size: 15px; line-height: 1.8; color: var(--slate); }

/* ── THE GATE (Ivan 2026-09-18: a layer on top; it closes only on submit) ── */
article strong { font-weight: 700; color: var(--ink); }
article u { text-decoration: underline; text-decoration-thickness: 1.5px; text-underline-offset: 4px; text-decoration-color: rgba(17, 24, 39, .35); }

/* the cut: the article fades out where the free part ends, and the ask sits inline under it.
   No modal, no blur, nothing to dismiss — he reads down to here first (Ivan 2026-09-20). */
.cut { height: 120px; margin-top: -120px; position: relative; pointer-events: none;
  background: linear-gradient(to bottom, rgba(250, 249, 245, 0), var(--paper) 88%); }
body.locked { overflow: hidden; }
.gate { position: fixed; inset: 0; z-index: 10; display: grid; place-items: center; padding: 20px; background: rgba(17, 24, 39, .28); backdrop-filter: blur(3px); opacity: 0; transition: opacity .3s ease; }
.gate.on { opacity: 1; }
.gate[hidden] { display: none; }
.gate h2 { margin: 14px 0 10px; font: 900 24px/1.45 var(--serif); color: var(--ink); }
.gate form { width: 100%; max-width: 420px; margin: 0 auto; max-height: 92vh; overflow: auto; background: var(--paper); border: 1px solid var(--ink); border-radius: 18px; padding: 24px 24px 18px; box-shadow: 0 18px 44px -26px rgba(17, 24, 39, .3); }
.gate .stamp { display: inline-block; font: 500 11px/1 var(--mono); letter-spacing: .12em; color: var(--fade); border: 1px solid var(--hair); border-radius: 999px; padding: 6px 11px; }
.gate .why { margin: 0 0 18px; color: var(--slate); font-size: 15px; line-height: 1.85; }
.gate label { display: block; font: 500 12px/1 var(--mono); letter-spacing: .12em; color: var(--fade); margin: 0 0 7px; }
.gate input { width: 100%; font: 400 16px/1.4 var(--sans); padding: 12px 14px; border: 1px solid var(--hair); border-radius: 10px; margin: 0 0 14px; background: #fff; color: var(--ink); }
.gate input:focus { border-color: var(--ink); outline: none; }
.gate button { width: 100%; font: 700 16px/1 var(--sans); letter-spacing: .08em; color: #fff; background: var(--ink); border: 0; border-radius: 10px; padding: 15px; cursor: pointer; margin-top: 4px; }
.gate button:hover { background: var(--seal); }
.gate button[disabled] { opacity: .6; cursor: wait; }
.gate .err { min-height: 22px; margin: 8px 0 0; font-size: 14px; color: var(--seal); }
.gate .fine { margin: 6px 0 0; font-size: 12.5px; line-height: 1.7; color: var(--fade); }
.cf-turnstile { margin: 0 0 6px; min-height: 0; }

@media (min-width: 720px) {
  body { font-size: 18px; }
  .wrap.read { max-width: 760px; }            /* 720 of text + gutters: a CJK reading line of ~38 characters */
  .head h1 { font-size: 40px; }
  .me h1, .me h2 { font-size: 38px; }
  article h2 { font-size: 25px; }
}
/* desktop hub: you on the left, the work on the right (phone keeps the single column, same order) */
@media (min-width: 1024px) {
  .wrap.hub { max-width: 1120px; padding: 0 40px; display: grid; grid-template-columns: 340px 1fr; column-gap: 72px;
    grid-template-areas: "me main" "maxim main" "links main" ". main"; align-items: start; }
  .hub .me { grid-area: me; grid-template-columns: 1fr; gap: 18px; padding-top: 56px; }
  .hub .me img { width: 132px; height: 132px; border-radius: 18px; }
  .hub .maxim { grid-area: maxim; margin: 28px 0 32px; font-size: 19px; }
  .hub .main { grid-area: main; padding-top: 64px; }
  .hub .links-block { grid-area: links; }
  .hub .card { grid-template-columns: 150px 1fr; gap: 24px; padding: 20px; }
  .hub .card img { width: 150px; }
  .hub .card.text { grid-template-columns: 1fr; }
  .hub .card h3 { font-size: 21px; }
  .hub footer { grid-column: 1 / -1; }
}
@media (max-width: 420px) {
  .me { grid-template-columns: 72px 1fr; gap: 16px; padding-top: 40px; }
  .me img { width: 72px; height: 72px; border-radius: 12px; }
  .card { grid-template-columns: 88px 1fr; gap: 14px; padding: 12px; }
  .card img { width: 88px; }
  .fig { grid-template-columns: 92px 1fr; }
  .fig b { font-size: 26px; }
}
@media (prefers-reduced-motion: reduce) {
  .gate, .card { transition: none; }
}

/* ── v0.4 · the frame (Ivan 2026-09-19): header 「Ivan的斜槓學習手帳」 + the frozen track bar ── */
header.site { position: sticky; top: 0; z-index: 5; background: rgba(255, 255, 255, .92); -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px); border-bottom: 1px solid var(--hair); }
.site-in { max-width: 1120px; margin: 0 auto; padding: 12px 20px 0; }
.brand { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; font: 900 18px/1.2 var(--serif); letter-spacing: .03em; }
.brand .mark { display: inline-grid; place-items: center; width: 26px; height: 26px; border-radius: 7px; background: var(--seal); color: #fff; font: 700 16px/1 var(--sans); }
.tracks { display: flex; gap: 6px; overflow-x: auto; padding: 10px 0 12px; scrollbar-width: none; -webkit-overflow-scrolling: touch; }
.tracks::-webkit-scrollbar { display: none; }
.tracks a { flex: none; font: 500 14px/1 var(--sans); letter-spacing: .04em; text-decoration: none; color: var(--slate); padding: 9px 13px; border: 1px solid var(--hair); border-radius: 999px; background: var(--paper); }
.tracks a:hover { border-color: var(--ink); color: var(--ink); }
.tracks a[aria-current] { background: var(--ink); border-color: var(--ink); color: #fff; }

/* the hub list (one list, filtered by track) */
#list .card + .card { margin-top: 14px; }
.card h3 a { text-decoration: none; }
.card h3 a:hover { text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 4px; }
.cardfoot { display: flex; align-items: center; gap: 12px; margin-top: 10px; flex-wrap: wrap; }
.cardfoot .go { margin-top: 0; text-decoration: none; }
.plat { font: 500 12px/1 var(--mono); color: var(--fade); text-decoration: none; border: 1px solid var(--hair); border-radius: 999px; padding: 6px 9px; }
.plat:hover { color: var(--ink); border-color: var(--ink); }
.empty { color: var(--fade); font-size: 15px; padding: 24px 0; }
.card[hidden] { display: none; }

/* 專題 chips + the series list */
.tag { font: 500 12px/1 var(--mono); letter-spacing: .02em; color: var(--seal); text-decoration: none; background: rgba(193, 39, 45, .07); border-radius: 999px; padding: 6px 9px; }
.tag:hover { background: rgba(193, 39, 45, .14); }
.series, .posts { margin: 8px 0 22px; }
.series ol { margin: 0; padding: 0 0 0 1.4em; }
.series li { margin: 6px 0; font-size: 16px; }
.series li[aria-current] a { color: var(--ink); font-weight: 700; text-decoration: none; }
.series li a { color: var(--slate); }
.posts { display: grid; gap: 12px; }
.post { display: grid; grid-template-columns: auto 1fr; gap: 14px; align-items: center; padding: 12px; border: 1px solid var(--hair); border-radius: 14px; text-decoration: none; background: var(--paper); }
.post:hover { border-color: var(--ink); }
.post img { width: 56px; aspect-ratio: 4 / 5; object-fit: cover; border-radius: 6px; }
.post b { display: block; font: 700 15px/1.5 var(--sans); }
.post small { color: var(--fade); font-size: 13px; }

/* new article blocks: 圖 · 流程圖 · 金句 */
.shot { margin: 8px 0 1.5em; }
.shot img { width: 100%; height: auto; display: block; border: 1px solid var(--hair); border-radius: 10px; background: var(--mist); }
.shot figcaption { margin-top: 8px; font-size: 14px; line-height: 1.7; color: var(--fade); }
.flow { list-style: none; margin: 6px 0 1.5em; padding: 0; display: flex; flex-wrap: wrap; align-items: center; gap: 8px 0; }
.flow li { position: relative; font: 700 15px/1.3 var(--sans); padding: 10px 14px; border: 1.5px solid var(--ink); border-radius: 10px; background: var(--paper); }
.flow li + li { margin-left: 28px; }
.flow li + li::before { content: '→'; position: absolute; left: -22px; top: 50%; transform: translateY(-50%); font: 500 15px/1 var(--mono); color: var(--fade); }
.flow li.dead { border-color: var(--seal); color: var(--seal); background: rgba(193, 39, 45, .05); }
.flow li i { font-style: normal; margin-left: 6px; font-weight: 900; }
blockquote.pull { margin: 1.6em 0; padding: 4px 0 4px 20px; border-left: 4px solid var(--seal); background: none; }
blockquote.pull p { margin: 0; font: 900 24px/1.6 var(--serif); letter-spacing: .02em; text-wrap: balance; }
blockquote.pull cite { display: block; margin-top: 8px; font: 500 13px/1.5 var(--mono); font-style: normal; color: var(--fade); }
.soon { margin: 8px 0 40px; padding: 16px 18px; border: 1px dashed var(--hair); border-radius: 12px; color: var(--slate); font-size: 16px; }
.about .me { padding-top: 40px; }

@media (max-width: 560px) {
  .flow { flex-direction: column; align-items: stretch; }
  .flow li + li { margin-left: 0; margin-top: 22px; }
  .flow li + li::before { content: '↓'; left: 50%; top: -18px; transform: translateX(-50%); }
  blockquote.pull p { font-size: 21px; }
}

/* v0.4 fixes after the first look */
.nb { white-space: nowrap; }
.main { margin-bottom: 40px; }
.shot img { width: auto; max-width: 100%; max-height: 72vh; margin: 0 auto; }
#list { scroll-margin-top: 140px; }
#list-label { scroll-margin-top: 130px; }
@media (max-width: 560px) {
  .card { grid-template-columns: 1fr; }
  .card > a:first-child { display: none; }   /* phone: no thumbnail, the title gets the full width (his line breaks hold) */
}
@media (max-width: 560px) {
  .end { grid-template-columns: 1fr; }
}
.fig span, .fig small { text-wrap: pretty; }

/* ── v0.5 (Ivan 2026-09-20): one header row · the hero · the doors out · the walker · the version bottom-right ── */
.site-in { display: flex; align-items: center; gap: 14px; padding: 12px 20px; }
.brand { flex: none; }
.site-in .tracks { flex: 1 1 auto; justify-content: flex-end; padding: 0; min-width: 0; }
.tracks a { padding: 9px 14px; }
.tracks .about-pill { position: relative; margin-left: 13px; }
.tracks .about-pill::before { content: ''; position: absolute; left: -10px; top: 22%; bottom: 22%; width: 1px; background: var(--hair); }
.xp { display: inline-flex; align-items: center; gap: 8px; text-decoration: none; font: 500 14px/1 var(--sans); letter-spacing: .03em; color: var(--slate); padding: 9px 14px 9px 11px; border: 1px solid var(--hair); border-radius: 999px; background: var(--paper); transition: border-color .2s, color .2s; }
.xp svg { width: 18px; height: 18px; flex: none; display: block; }
.xp-sol svg { color: #0E0E0E; }
.xp:hover { border-color: var(--ink); color: var(--ink); }
.ext { display: flex; gap: 6px; flex: none; padding-left: 12px; border-left: 1px solid var(--hair); }
.ext .xp { padding: 8px; }
.ext .xp span { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }   /* header: the marks only; the name stays for screen readers */
.links { display: flex; flex-wrap: wrap; gap: 10px; }

.hero { max-width: 1120px; margin: 0 auto; padding: 60px 40px 0; }
.hero-t { margin: 0; font: 900 clamp(34px, 6.4vw, 76px)/1.15 var(--serif); letter-spacing: .02em; }
.hero-t img { display: block; width: min(100%, 720px); height: auto; }   /* Ivan 09-20: 「a tad smaller」 */
.hero-sub { margin: 22px 0 0; font: 500 clamp(16px, 1.9vw, 20px)/1.75 var(--sans); color: var(--slate); letter-spacing: .04em; }
.ext-hero { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 24px; }
.walk { position: relative; height: 132px; margin: 30px -40px 0; overflow: hidden; }
.walk-line { position: absolute; left: 0; right: 0; bottom: 9px; border-top: 3px dashed rgba(17, 24, 39, .16); }
.cc { position: absolute; left: 0; bottom: 0; width: 76px; height: 76px; fill: var(--seal); will-change: transform; transform: translateX(-80px); }
.hub .me { padding-top: 40px; }

footer { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 6px 18px; }
footer .fr { margin-left: auto; text-align: right; }

@media (min-width: 1024px) {
  .hub .me { padding-top: 44px; }
  .hub .main { padding-top: 52px; }
}
@media (max-width: 960px) {   /* the header wraps: brand + marks on one row, the section pills scroll underneath */
  .site-in { flex-wrap: wrap; row-gap: 0; padding-bottom: 0; }
  .ext { margin-left: auto; }
  .site-in .tracks { order: 3; flex: 1 0 100%; justify-content: flex-start; padding: 10px 0 12px; }
}
@media (max-width: 720px) {
  .hero { padding: 36px 20px 0; }
  .walk { margin: 24px -20px 0; height: 104px; }
  .cc { width: 52px; height: 52px; }
  .walk-line { bottom: 8px; }
  .brand { font-size: 16px; }
  .brand .mark { width: 24px; height: 24px; }
  .ext { padding-left: 0; border-left: 0; gap: 4px; }
  .ext .xp { padding: 7px; }
  .ext .xp svg { width: 16px; height: 16px; }
}
@media (prefers-reduced-motion: reduce) { .xp { transition: none; } }
.about-body { padding: 8px 0 24px; }
.draftnote { margin: 0 0 8px; padding: 10px 14px; border: 1px dashed var(--seal); border-radius: 10px; color: var(--seal); font: 500 13px/1.7 var(--mono); letter-spacing: .02em; }
@media (max-width: 420px) {   /* all five section pills fit one phone row (Ivan 09-20: 關於我 in the same range) */
  .site-in .tracks { gap: 4px; }
  .tracks a { font-size: 13px; padding: 8px 9px; letter-spacing: 0; }
  .tracks .about-pill { margin-left: 0; }
  .tracks .about-pill::before { display: none; }
  .ext-hero { gap: 8px; }
  .ext-hero .xp { font-size: 13px; padding: 8px 11px 8px 9px; gap: 6px; }
  .ext-hero .xp svg { width: 16px; height: 16px; }
}
/* v0.5.1 (Ivan 09-20): the doors sit under the bio · every mark the same 18 px box · the hero line is his */
.me-links { margin-top: 16px; }
.end-links { margin-top: 12px; }
.end-links .xp { font-size: 13px; padding: 7px 11px 7px 9px; }
.xp svg { width: 18px; height: 18px; }
.hero-sub { line-height: 1.8; }
@media (min-width: 1024px) { .hub .me-links { gap: 8px; } }
@media (max-width: 720px) { .site-in .ext { display: none; } }   /* phone: the doors are right under the bio; the header keeps name + sections */
@media (max-width: 420px) {
  .me-links { gap: 8px; }
  .me-links .xp { font-size: 13px; padding: 8px 11px 8px 9px; gap: 6px; }
  .me-links .xp svg { width: 16px; height: 16px; }
}
.links a.xp { font: 500 14px/1 var(--sans); letter-spacing: .03em; }   /* the old mono pill rule was winning */
@media (max-width: 420px) { .me-links a.xp { font-size: 13px; } }
/* v0.6: the hero in the carousel's title face, so the site and the decks read as one thing (Ivan 09-20) */
.hero-t { font: 900 clamp(32px, 6.4vw, 74px)/1.28 var(--serif); letter-spacing: .02em; }
.hero-sub { font-weight: 400; }
@media (max-width: 420px) { .hero-t { font-size: clamp(29px, 8vw, 38px); } }
/* v0.6.1 (Ivan 09-20): one-line hero sub · 👉 閱讀完整版 (no arrow) · the IG mark itself is the link */
.hero-sub { margin-top: 16px; }
.card .go { display: inline-flex; align-items: center; gap: 7px; font: 500 14px/1 var(--sans); }
.card .go .hand { font-size: 15px; line-height: 1; }
.plat.mark { display: inline-flex; align-items: center; justify-content: center; padding: 7px; line-height: 0; }
.plat.mark svg { width: 18px; height: 18px; display: block; }
@media (max-width: 420px) { .hero-sub { font-size: 14.5px; } }
/* v0.6.2: the sub-line sits under the title, not adrift (Ivan 09-20) */
.hero-sub { margin-top: 8px; }
@media (min-width: 720px) { .hero-sub { margin-top: 6px; } }
article h3 { margin: 1.9em 0 .7em; font: 700 18px/1.7 var(--serif); letter-spacing: .02em; color: var(--ink); }
article h3::before { content: ''; display: inline-block; width: 14px; height: 2px; background: var(--seal); vertical-align: middle; margin-right: 10px; }
.walk { display: flex; align-items: flex-end; }
/* v0.7 (Ivan 09-20): the article head reads like the card — stamp on top, claim, sub under it */
.head .stampline { margin: 0 0 14px; font: 500 14px/1.8 var(--sans); color: var(--slate); letter-spacing: .03em; }
.head .subline { margin: 0 0 18px; font: 700 17px/1.8 var(--serif); color: var(--ink); }
.head .row { margin-bottom: 4px; }
.head .ig { display: flex; align-items: center; gap: 10px; }
.pmark { display: inline-flex; padding: 6px; border: 1px solid var(--hair); border-radius: 999px; line-height: 0; }
.pmark:hover { border-color: var(--ink); }
.pmark svg { width: 18px; height: 18px; display: block; }
em.acc { font-style: normal; color: var(--seal); font-weight: 700; }
@media (min-width: 720px) { .head .subline { font-size: 19px; } }
/* the platform line: his words, then the mark, both at reading size */
.head .ig .hand { font-size: 15px; }
.pmark { gap: 7px; padding: 6px 11px; align-items: center; }
.pmark span { font: 500 13.5px/1 var(--sans); color: var(--slate); letter-spacing: .02em; }
.pmark:hover span { color: var(--ink); }
/* the stations, as a framework: stages stacked, stops inside each (Ivan 09-20) */
.stages { margin: 10px 0 1.8em; display: grid; gap: 16px; }
.stage { border: 1px solid var(--hair); border-radius: 16px; padding: 16px 18px 18px; background: var(--paper); }
.stage > header { display: flex; align-items: baseline; gap: 12px; padding-bottom: 12px; border-bottom: 1px dashed var(--hair); margin-bottom: 14px; }
.stage .no { font: 500 13px/1 var(--mono); color: var(--seal); letter-spacing: .08em; }
.stage header b { font: 900 17px/1.5 var(--serif); letter-spacing: .02em; }
.stage header small { display: block; margin-top: 3px; font: 400 13.5px/1.7 var(--sans); color: var(--fade); }
.stops { display: grid; gap: 10px; }
.stop { border-left: 3px solid var(--hl); padding: 2px 0 2px 14px; }
.stop b { display: block; font: 700 15px/1.6 var(--sans); }
.stop p { margin: 3px 0 0; font-size: 14.5px; line-height: 1.8; color: var(--slate); text-wrap: pretty; }
.stop p.no-go { color: var(--fade); font-size: 13.5px; }
.stop p.no-go::first-line { color: var(--fade); }
@media (min-width: 720px) { .stops { grid-template-columns: 1fr 1fr; gap: 14px 22px; } .stage { padding: 18px 22px 20px; } }
/* artefact labels: /a/<slug>/?labels=1 shows a chip on every figure, flow, table, quote and stage block,
   so he can say 「fix ST2」 instead of describing the picture (Ivan 2026-09-20) */
body.labels [data-lb] { position: relative; outline: 1px dashed rgba(193,39,45,.35); outline-offset: 6px; }
body.labels [data-lb]::after { content: attr(data-lb); position: absolute; top: -10px; left: -6px; z-index: 2;
  font: 500 11px/1 var(--mono); letter-spacing: .06em; color: #fff; background: var(--seal); padding: 4px 6px; border-radius: 5px; }
/* the quiet footer link + the legal page's own measure */
footer .quiet { color: var(--fade); text-decoration: none; border-bottom: 1px solid transparent; }
footer .quiet:hover { color: var(--ink); border-bottom-color: var(--hair); }
.legal article p { font-size: 16px; color: var(--slate); }
.legal article h2 { font-size: 19px; margin: 2em 0 .6em; }
.legal article h2::before { width: 20px; height: 3px; }
.legal .terms { margin: 0 0 1.4em; }
.legal .terms dt { font: 700 15px/1.8 var(--sans); color: var(--ink); margin-top: 14px; }
.legal .terms dd { margin: 2px 0 0; font-size: 15.5px; line-height: 1.85; color: var(--slate); }
.legal .head .subline { font: 500 13px/1 var(--mono); color: var(--fade); }

/* RB0006 09-29 his pen: takeaway cards · dimmed citations */
blockquote.pull.take { margin: 1.8em 0; padding: 18px 22px; border-left: 4px solid var(--seal); border-radius: 0 12px 12px 0; background: #F7F4EE; }
blockquote.pull.take p { font: 900 22px/1.65 var(--serif); }
sup.cite { font: 500 11px/1 var(--mono); vertical-align: super; margin-left: 1px; }
sup.cite a { color: var(--fade); text-decoration: none; }
section.sources { margin: 4.5em 0 1em; padding-top: 22px; border-top: 1px solid var(--fade); color: var(--fade); }   /* the long rule: the article ends here, the receipts sit below it */
section.sources h3 { margin: 0 0 8px; font: 600 12px/1.6 var(--mono); letter-spacing: .12em; color: var(--fade); }
section.sources h3::before { display: none; }
section.sources ol { margin: 0; padding-left: 1.7em; font: 400 12.5px/1.75 var(--sans); letter-spacing: .01em; }
section.sources li { margin: 2px 0; }
@media (max-width: 640px) { blockquote.pull.take p { font-size: 19px; } }

/* RB0006 09-29 his pen: 學習帳本 as a card */
aside.ledger { box-sizing: border-box; width: 100%; margin: 2em 0; padding: 0; border: 1.5px solid var(--ink); border-radius: 14px; background: #fff; box-shadow: 5px 5px 0 var(--ink); overflow: hidden; }   /* every 帳本 the same card: the article's full width */
aside.ledger > b { display: block; margin: 0; padding: 11px 20px 10px; border-bottom: 1.5px solid var(--ink); background: #F7F4EE; font: 700 14px/1.4 var(--sans); letter-spacing: .08em; color: var(--seal); }
aside.ledger p, aside.ledger ul { margin: 0; padding: 14px 20px 16px; font-size: 16px; line-height: 1.85; }
aside.ledger ul { padding-left: 38px; }
aside.ledger.yours > b { color: var(--ink); background: #FFF6D6; }   /* the reader's prompt: same card, a yellow head (theirs to fill) */
/* 10-04 his ruling 「gate principles applies」: an article's gate closes like a tool's — × top right, a 🔓 button under the cut brings it back */
.gate form { position: relative; }
.gate .gate-x { position: absolute; top: 10px; right: 10px; width: 40px; height: 40px; margin: 0; padding: 0; border-radius: 50%; background: transparent; color: var(--slate); font: 400 26px/1 var(--sans); letter-spacing: 0; }
.gate .gate-x:hover { background: rgba(17, 24, 39, .08); color: var(--ink); }
.gate-reopen { display: block; margin: 8px auto 2em; font: 700 16px/1 var(--sans); letter-spacing: .04em; color: #fff; background: var(--seal); border: 0; border-radius: 999px; padding: 14px 22px; cursor: pointer; box-shadow: 0 10px 24px -12px rgba(0, 0, 0, .5); }
.gate-reopen:hover { background: #A51F24; }
.gate-reopen[hidden] { display: none; }
/* 10-04: a posted carousel as its 完整版 — the cards one under another, at IG's own 4:5 */
.shot.ig-card { margin: 0 0 18px; }
.shot.ig-card img, .shot.ig-card video { width: 100%; max-width: 560px; max-height: none; height: auto; aspect-ratio: 4 / 5; display: block; margin: 0 auto; border: 1px solid var(--hair); border-radius: 10px; background: var(--mist); }
.shot video { width: 100%; height: auto; display: block; border: 1px solid var(--hair); border-radius: 10px; background: var(--mist); }
/* 10-04: with both IG and Threads (開幹 · 蘋果) the row squeezed its label to 「原貼\n文：」 on a phone — the label and each
   button keep their words on one line, and the buttons wrap under the label when the row is full */
.head .ig { flex-wrap: wrap; row-gap: 8px; }
.head .ig .lbl, .pmark span { white-space: nowrap; }
/* 10-04 聯絡我 (his ask): under the bio on the hub, 關於我 and every article's bio card */
.contact { margin: 18px 0 0; padding: 14px 16px; border: 1.5px solid var(--ink); border-radius: 14px; background: #FFF6D6; box-shadow: 4px 4px 0 var(--ink); }
.contact .contact-h { margin: 0; font: 700 14px/1.4 var(--sans); letter-spacing: .08em; color: var(--ink); }
.contact .contact-l { margin: 6px 0 12px; font-size: 14.5px; line-height: 1.7; color: var(--slate); }
.contact .links { gap: 8px; }
.contact .xp svg { width: 16px; height: 16px; }
/* 10-04 his catch 「fully utilise the banner space … why break to 3 lines unnecessarily?」: a preview card's title fills each line
   before it wraps (balance evened the lines out — 「Kopi 櫃檯模擬 / 器」 — and left the card half empty) */
.card h3 { text-wrap: wrap; }
/* 10-04 his ruling: a posted carousel shows as a Threads-style row — swipe sideways, the next card peeking — never stacked */
.swipe { position: relative; margin: 8px 0 1.8em; }
.swipe-track { display: flex; gap: 10px; overflow-x: auto; scroll-snap-type: x mandatory; scroll-padding: 0; overscroll-behavior-x: contain;
  -webkit-overflow-scrolling: touch; scrollbar-width: none; padding: 2px 0 4px; outline: none; }
.swipe-track::-webkit-scrollbar { display: none; }
.swipe-card { flex: 0 0 min(82%, 360px); margin: 0; scroll-snap-align: start; }
.swipe-card img, .swipe-card video { display: block; width: 100%; height: auto; aspect-ratio: 4 / 5; object-fit: cover; border: 1px solid var(--hair); border-radius: 12px; background: var(--mist); }
.swipe-btn { position: absolute; top: calc(50% - 30px); width: 40px; height: 40px; border-radius: 50%; border: 1px solid var(--hair); background: rgba(255, 255, 255, .94);
  color: var(--ink); font: 400 26px/1 var(--sans); cursor: pointer; box-shadow: 0 6px 16px -10px rgba(0, 0, 0, .5); display: grid; place-items: center; padding: 0 0 3px; }
.swipe-btn.prev { left: -6px; } .swipe-btn.next { right: -6px; }
.swipe-btn[hidden] { display: none; }
.swipe-count { margin: 8px 0 0; font: 500 12px/1 var(--mono); letter-spacing: .08em; color: var(--fade); }
@media (hover: none) { .swipe-btn { display: none; } }
.swipe-track:focus-visible { outline: 2px solid var(--seal); outline-offset: 4px; border-radius: 12px; }   /* the row is a Tab stop: show where it is */
/* 10-04 his ask: a tapped card opens full screen and keeps swiping */
.swipe-card { cursor: zoom-in; }
.lb { position: fixed; inset: 0; z-index: 30; background: rgba(10, 12, 16, .94); }
.lb-track { display: flex; height: 100%; overflow-x: auto; scroll-snap-type: x mandatory; overscroll-behavior: contain; scrollbar-width: none; outline: none; }
.lb-track::-webkit-scrollbar { display: none; }
.lb-card { flex: 0 0 100%; height: 100%; margin: 0; display: grid; place-items: center; scroll-snap-align: center; padding: 56px 12px 48px; box-sizing: border-box; cursor: zoom-out; }
.lb-card img, .lb-card video { max-width: 100%; max-height: 100%; width: auto; height: auto; aspect-ratio: 4 / 5; object-fit: contain; border-radius: 10px; background: #111; cursor: default; }
.lb-x { position: absolute; top: 10px; right: 12px; width: 44px; height: 44px; border-radius: 50%; border: 0; background: rgba(255, 255, 255, .14); color: #fff; font: 400 28px/1 var(--sans); cursor: pointer; }
.lb-btn { position: absolute; top: calc(50% - 22px); width: 44px; height: 44px; border-radius: 50%; border: 0; background: rgba(255, 255, 255, .14); color: #fff; font: 400 28px/1 var(--sans); cursor: pointer; padding: 0 0 3px; }
.lb-btn.prev { left: 12px; } .lb-btn.next { right: 12px; }
.lb-count { position: absolute; left: 0; right: 0; bottom: 14px; margin: 0; text-align: center; font: 500 12px/1 var(--mono); letter-spacing: .1em; color: rgba(255, 255, 255, .75); }
@media (hover: none) { .lb-btn { display: none; } }
