/* ==========================================================================
   Standard Notes guide
   Design system: light theme matching standardnotes.com
   Colours  : #086DD6 primary, #181818 headings, #313944 body, #63666B muted,
              #CCD2DA borders, #F8F9FC soft background, #EBAD00 corn accent
   Type     : Lato (headings, 900/700) + Avenir Next (body; Nunito Sans fallback)
   ========================================================================== */

@font-face {
  font-family: "Lato";
  src: url("../fonts/lato-400.woff2") format("woff2");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Lato";
  src: url("../fonts/lato-400-italic.woff2") format("woff2");
  font-weight: 400;
  font-style: italic;
  font-display: swap;
}
@font-face {
  font-family: "Lato";
  src: url("../fonts/lato-700.woff2") format("woff2");
  font-weight: 700;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Lato";
  src: url("../fonts/lato-900.woff2") format("woff2");
  font-weight: 900;
  font-style: normal;
  font-display: swap;
}
/* Avenir Next is a commercial font: it is used where the visitor has it installed
   (macOS, iOS). Everyone else gets Nunito Sans, its closest open-licence match. */
@font-face {
  font-family: "Nunito Sans";
  src: url("../fonts/nunito-sans-var.woff2") format("woff2");
  font-weight: 200 1000;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Nunito Sans";
  src: url("../fonts/nunito-sans-var-italic.woff2") format("woff2");
  font-weight: 200 1000;
  font-style: italic;
  font-display: swap;
}
@font-face {
  font-family: "JetBrains Mono";
  src: url("../fonts/jetbrains-mono-var.woff2") format("woff2");
  font-weight: 100 800;
  font-style: normal;
  font-display: swap;
}

:root {
  /* Brand palette (standardnotes.com) */
  --white: #ffffff;
  --black: #181818;
  --ink: #000000;
  --blue: #086dd6;
  --blue-600: #0e5cc9;
  --blue-700: #2a5078;
  --blue-50: #e6f0fb;
  --blue-100: #d6e3fc;
  --corn: #ebad00;
  --body-gray: #313944;
  --heading-gray: #63666b;
  --border-gray: #ccd2da;
  --background-gray: #f8f9fc;

  /* Semantic tokens */
  --bg: #ffffff;
  --bg-soft: #f8f9fc;
  --bg-elev: #ffffff;
  --text: #313944;
  --text-muted: #63666b;
  --text-faint: #63666b;
  --heading: #181818;
  --line: #ccd2da;
  --line-strong: #ababab;
  --accent: #086dd6;
  --accent-hover: #0e5cc9;
  --accent-ink: #ffffff;
  --accent-soft: #e6f0fb;
  --accent-text: #086dd6;
  --highlight: #ebad00;
  --success: #1aa772;
  --warn: #8a5300;
  --danger: #d0342c;
  --code-bg: #f7f7f7;
  --chip-bg: #f7f7f7;
  --glow: rgba(214, 227, 252, .7);

  --radius-sm: 4px;
  --radius: 8px;
  --radius-lg: 8px;
  --radius-xl: 8px;
  --shadow-sm: 0 1px 2px rgba(0, 0, 0, .05);
  --shadow: 0 10px 28px -14px rgba(24, 24, 24, .22), 0 2px 6px -2px rgba(24, 24, 24, .06);
  --shadow-lg: 0 28px 56px -24px rgba(24, 24, 24, .28);
  --ring: 0 0 0 3px #fff, 0 0 0 5px var(--accent);

  --wrap: 1200px;
  --gutter: clamp(16px, 4vw, 32px);
  --header-h: 72px;
  --font: "Avenir Next", "Avenir", "Nunito Sans", ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --font-head: "Lato", "Avenir Next", "Nunito Sans", ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
  --mono: "JetBrains Mono", ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  --ease: cubic-bezier(.2, .7, .2, 1);
}

/* Optional dark theme (only when the visitor turns it on with the toggle) */
[data-theme="dark"] {
  --bg: #0f1114;
  --bg-soft: #161a1f;
  --bg-elev: #1a1e24;
  --text: #d9dde3;
  --text-muted: #a7aeb8;
  --text-faint: #8f97a3;
  --heading: #ffffff;
  --line: #2b3038;
  --line-strong: #3d444e;
  --accent: #3b8ff0;
  --accent-hover: #5aa2f3;
  --accent-ink: #ffffff;
  --accent-soft: #10243b;
  --accent-text: #74b0f6;
  --code-bg: #1f242b;
  --chip-bg: #1f242b;
  --glow: rgba(59, 143, 240, .14);
  --success: #3fbf86;
  --warn: #e3a43c;
  --danger: #ff7b80;
  --shadow: 0 10px 30px -12px rgba(0, 0, 0, .6), 0 2px 6px -2px rgba(0, 0, 0, .4);
  --shadow-lg: 0 30px 60px -20px rgba(0, 0, 0, .7);
  --ring: 0 0 0 3px #0f1114, 0 0 0 5px var(--accent);
  color-scheme: dark;
}

/* ---------- Base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: calc(var(--header-h) + 16px); }
body {
  margin: 0;
  font-family: var(--font);
  font-size: 18px;
  font-weight: 400;
  line-height: 1.5;
  color: var(--text);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}
img, svg { display: block; max-width: 100%; }
img { height: auto; }
a { color: var(--accent-text); text-decoration: none; text-underline-offset: 3px; text-decoration-thickness: 1px; }
a:hover { color: var(--accent); text-decoration: underline; }
h1, h2, h3, h4 { color: var(--heading); margin: 0 0 .55em; }
h1, h2 { font-family: var(--font-head); letter-spacing: 0; line-height: 1.3; }
h1 { font-size: clamp(36px, 4.4vw, 48px); font-weight: 900; }
h2 { font-size: clamp(26px, 2.8vw, 30px); font-weight: 700; }
h3 { font-size: 20px; font-weight: 600; line-height: 1.4; }
h4 { font-size: 16px; font-weight: 600; line-height: 1.4; }
p { margin: 0 0 1em; }
b, strong { font-weight: 600; }
ul, ol { padding-left: 1.25em; margin: 0 0 1.2em; }
li { margin: .3em 0; }
code, kbd { font-family: var(--mono); font-size: .84em; background: var(--code-bg); border: 1px solid var(--line); border-radius: 3px; padding: .1em .4em; color: var(--heading); }
pre { font-family: var(--mono); font-size: 15px; background: var(--code-bg); color: var(--heading); border: 1px solid var(--line); border-radius: var(--radius); padding: 18px 20px; overflow-x: auto; line-height: 1.6; }
pre code { background: none; border: 0; padding: 0; color: inherit; }
hr { border: 0; border-top: 1px solid var(--line); margin: 2.5rem 0; }
table { border-collapse: collapse; width: 100%; }
:focus-visible { outline: none; box-shadow: var(--ring); border-radius: 4px; }
::selection { background: var(--accent); color: #fff; }

.skip-link { position: absolute; left: 12px; top: -60px; z-index: 200; background: var(--accent); color: #fff; padding: 10px 16px; border-radius: var(--radius-sm); font-weight: 600; text-decoration: none; transition: top .2s; }
.skip-link:focus { top: 12px; color: #fff; }
.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; }
.wrap { width: 100%; max-width: var(--wrap); margin: 0 auto; padding-inline: var(--gutter); }
.wrap-narrow { max-width: 820px; }

/* ---------- Buttons ---------- */
.btn {
  --b-bg: var(--accent); --b-fg: var(--accent-ink); --b-bd: transparent;
  display: inline-flex; align-items: center; justify-content: center; gap: .5em;
  min-height: 46px; padding: 12px 16px; border-radius: var(--radius-sm);
  font: 600 16px/1.2 var(--font); text-decoration: none; white-space: nowrap;
  background: var(--b-bg); color: var(--b-fg); border: 1px solid var(--b-bd); cursor: pointer;
  transition: background-color .18s, color .18s, border-color .18s;
}
.btn svg { width: 18px; height: 18px; flex: none; }
.btn:hover { color: var(--b-fg); background: var(--accent-hover); text-decoration: underline; text-underline-offset: 3px; }
.btn-dark { --b-bg: var(--black); --b-fg: #fff; }
.btn-dark:hover { background: #000; }
[data-theme="dark"] .btn-dark { --b-bg: #fff; --b-fg: #000; }
[data-theme="dark"] .btn-dark:hover { background: #e6e8eb; }
.btn-ghost { --b-bg: var(--bg-elev); --b-fg: var(--heading); --b-bd: var(--line); }
.btn-ghost:hover { background: var(--bg-elev); color: var(--heading); border-color: var(--heading); }
.btn-sm { min-height: 38px; padding: 8px 14px; font-size: 15px; }
.btn-block { width: 100%; }

/* ---------- Header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 100; height: var(--header-h);
  background: color-mix(in srgb, var(--bg) 94%, transparent);
  -webkit-backdrop-filter: saturate(180%) blur(12px); backdrop-filter: saturate(180%) blur(12px);
  border-bottom: 1px solid var(--line); transition: box-shadow .2s;
}
.site-header.scrolled { box-shadow: 0 6px 20px -16px rgba(0, 0, 0, .3); }
.header-inner { height: 100%; display: flex; align-items: center; gap: 24px; }
.brand { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; color: var(--accent); font-family: var(--font-head); font-weight: 700; font-size: 24px; letter-spacing: -.01em; flex: none; }
.brand:hover { color: var(--accent); text-decoration: none; }
.brand img { width: 34px; height: 34px; }
.brand-text { line-height: 1; white-space: nowrap; }
.nav { display: flex; align-items: center; gap: 32px; margin-left: auto; }
.nav a { position: relative; padding: 6px 0; color: var(--text-muted); text-decoration: none; font-weight: 500; font-size: 16px; line-height: 1.375; transition: color .15s; }
.nav a::after { content: ""; position: absolute; left: 0; right: 0; bottom: 2px; height: 1px; background: var(--highlight); transform: scaleX(0); transition: transform .2s var(--ease); }
.nav a:hover { color: var(--heading); text-decoration: none; }
.nav a:hover::after, .nav a[aria-current="page"]::after { transform: scaleX(1); }
.nav a[aria-current="page"] { color: var(--heading); font-weight: 600; }
.header-cta { display: flex; align-items: center; gap: 10px; margin-left: 12px; }
.icon-btn { display: inline-grid; place-items: center; width: 40px; height: 40px; border-radius: var(--radius-sm); border: 1px solid var(--line); background: var(--bg-elev); color: var(--heading); cursor: pointer; transition: background-color .15s, border-color .15s; }
.icon-btn:hover { background: var(--bg-soft); border-color: var(--line-strong); }
.icon-btn svg { width: 19px; height: 19px; }
.theme-toggle .moon { display: none; }
[data-theme="dark"] .theme-toggle .moon { display: block; }
[data-theme="dark"] .theme-toggle .sun { display: none; }
.nav-toggle { display: none; color: var(--accent); }
/* Hamburger: three bars that morph into a centred X */
.nav-toggle .bars { position: relative; display: block; width: 20px; height: 14px; }
.nav-toggle .bars > span { position: absolute; left: 0; width: 100%; height: 2px; background: currentColor; border-radius: 2px; transition: transform .25s var(--ease), opacity .2s, top .25s var(--ease); }
.nav-toggle .bars > span:nth-child(1) { top: 0; }
.nav-toggle .bars > span:nth-child(2) { top: 6px; }
.nav-toggle .bars > span:nth-child(3) { top: 12px; }
.site-header.open .nav-toggle { background: var(--accent-soft); border-color: var(--accent); }
.site-header.open .nav-toggle .bars > span:nth-child(1) { top: 6px; transform: rotate(45deg); }
.site-header.open .nav-toggle .bars > span:nth-child(2) { opacity: 0; transform: scaleX(0); }
.site-header.open .nav-toggle .bars > span:nth-child(3) { top: 6px; transform: rotate(-45deg); }

@media (max-width: 1024px) {
  :root { --header-h: 58px; }
  .nav-toggle { display: inline-grid; }
  .nav {
    position: absolute; top: 100%; left: 0; right: 0; margin: 0;
    flex-direction: column; align-items: stretch; gap: 2px; padding: 10px var(--gutter) 18px;
    background: var(--bg); border-bottom: 1px solid var(--line); box-shadow: 0 18px 30px -18px rgba(24, 24, 24, .25);
    transform: translateY(-8px); opacity: 0; visibility: hidden; transition: opacity .2s, transform .25s var(--ease), visibility .2s;
    max-height: calc(100vh - var(--header-h)); max-height: calc(100dvh - var(--header-h)); overflow-y: auto; overscroll-behavior: contain;
  }
  .site-header.open .nav { transform: none; opacity: 1; visibility: visible; }
  .nav a { display: flex; align-items: center; min-height: 46px; margin: 0; padding: 11px 14px; border-radius: 6px; font-size: 16px; line-height: 1.4; color: var(--text); }
  .nav a:hover { background: var(--bg-soft); }
  .nav a::after { display: none; }
  .nav a[aria-current="page"] { background: var(--accent-soft); color: var(--accent-text); font-weight: 600; box-shadow: inset 3px 0 0 var(--accent); }
  .header-cta { margin-left: auto; gap: 8px; }
  .header-cta .btn-dl-label { display: none; }
  .header-cta .btn { min-height: 40px; width: 40px; padding: 0; justify-content: center; }
}
@media (max-width: 420px) { .brand { font-size: 21px; } .brand img { width: 30px; height: 30px; } .header-cta .btn { display: none; } }

/* ---------- Sections ---------- */
.section { padding-block: clamp(64px, 9vw, 104px); position: relative; }
.section-sm { padding-block: clamp(40px, 6vw, 64px); }
.section-soft { background: var(--bg-soft); }
.section-dark { background: var(--bg-soft); border-block: 1px solid var(--line); }
.section-head { max-width: 760px; margin-bottom: clamp(32px, 5vw, 48px); }
.section-head.center { text-align: center; margin-inline: auto; }
.section-head .lead { margin-bottom: 0; }
.eyebrow { display: inline-flex; align-items: center; gap: .55em; font-size: 14px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--accent-text); margin-bottom: 12px; }
.eyebrow::before { content: ""; width: 18px; height: 2px; border-radius: 2px; background: var(--highlight); }
.lead { font-size: 18px; font-weight: 500; color: var(--text); line-height: 1.5; }
.muted { color: var(--text-muted); }
.small { font-size: 15px; }

.grid { display: grid; gap: clamp(16px, 2.2vw, 24px); }
.grid-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.grid-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.grid-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
@media (max-width: 1024px) { .grid-4 { grid-template-columns: repeat(2, minmax(0, 1fr)); } .grid-3 { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 680px) { .grid-2, .grid-3, .grid-4 { grid-template-columns: minmax(0, 1fr); } }

/* ---------- Hero ---------- */
.hero { position: relative; overflow: hidden; background: linear-gradient(180deg, var(--bg) 20%, var(--bg-soft) 100%); color: var(--text); padding-block: clamp(48px, 7vw, 96px) clamp(72px, 9vw, 120px); isolation: isolate; border-bottom: 1px solid var(--line); }
.hero::before { content: ""; position: absolute; inset: 0; z-index: -1; background: radial-gradient(760px 420px at 82% 18%, var(--glow), transparent 65%); }
.hero-grid { display: grid; grid-template-columns: minmax(0, .95fr) minmax(0, 1.05fr); gap: clamp(32px, 5vw, 64px); align-items: center; }
.hero h1 .accent { font-weight: inherit; text-decoration: underline; text-decoration-color: var(--highlight); text-decoration-thickness: 4px; text-underline-offset: 8px; text-decoration-skip-ink: none; }
.hero .lead { max-width: 600px; color: var(--text); }
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; margin: 28px 0 32px; }
.pill { display: inline-flex; align-items: center; gap: 8px; padding: 5px 12px 5px 5px; border-radius: var(--radius-sm); border: 1px solid var(--line); background: var(--bg-elev); font-size: 14px; color: var(--text); margin-bottom: 20px; }
.pill b { background: var(--accent); color: #fff; padding: 3px 9px; border-radius: 3px; font-size: 12px; font-weight: 700; letter-spacing: .02em; }
.hero-meta { display: grid; grid-template-columns: repeat(3, auto); gap: 10px 32px; justify-content: start; }
.hero-meta div { display: grid; }
.hero-meta strong { color: var(--heading); font-family: var(--font-head); font-weight: 900; font-size: 26px; line-height: 1.2; }
.hero-meta span { font-size: 14px; color: var(--text-muted); }
.hero-art { position: relative; }
.hero-art img { border-radius: var(--radius); border: 1px solid var(--line); border-bottom: 8px solid var(--accent); box-shadow: var(--shadow-lg); }
.hero-badge { position: absolute; display: flex; align-items: center; gap: 10px; padding: 10px 14px; border-radius: var(--radius); background: #fff; border: 1px solid var(--border-gray); color: var(--black); box-shadow: var(--shadow); font-size: 14px; font-weight: 600; line-height: 1.25; }
.hero-badge small { display: block; font-weight: 500; color: var(--heading-gray); font-size: 12px; }
.hero-badge .dot { display: grid; place-items: center; width: 34px; height: 34px; border-radius: var(--radius); background: var(--blue-50); color: var(--blue); flex: none; }
.hero-badge .dot svg { width: 18px; height: 18px; }
.hero-badge.b1 { left: -18px; bottom: 26px; animation: float 6s ease-in-out infinite; }
.hero-badge.b2 { right: -10px; top: 22px; animation: float 7s ease-in-out -2s infinite; }
@keyframes float { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-8px); } }
@media (max-width: 900px) {
  .hero-grid { grid-template-columns: minmax(0, 1fr); }
  .hero-art { max-width: 620px; }
  .hero-badge.b1 { left: 8px; } .hero-badge.b2 { right: 8px; }
}
@media (max-width: 520px) { .hero-meta { grid-template-columns: repeat(2, auto); } .hero-badge { display: none; } }

/* ---------- Facts strip ---------- */
.facts { margin-top: -44px; position: relative; z-index: 2; }
.facts-card { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); background: var(--bg-elev); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); overflow: hidden; }
.fact { padding: 20px 22px; border-right: 1px solid var(--line); }
.fact:last-child { border-right: 0; }
.fact dt { font-size: 12px; font-weight: 700; text-transform: uppercase; letter-spacing: .1em; color: var(--text-muted); margin-bottom: 6px; }
.fact dd { margin: 0; color: var(--heading); font-weight: 600; line-height: 1.35; font-size: 17px; }
.fact dd span { display: block; font-weight: 500; color: var(--text-muted); font-size: 14px; }
@media (max-width: 1024px) { .facts-card { grid-template-columns: repeat(3, minmax(0, 1fr)); } .fact:nth-child(3) { border-right: 0; } .fact:nth-child(-n+3) { border-bottom: 1px solid var(--line); } }
@media (max-width: 600px) { .facts-card { grid-template-columns: repeat(2, minmax(0, 1fr)); } .fact { border-right: 1px solid var(--line) !important; border-bottom: 1px solid var(--line); } .fact:nth-child(2n) { border-right: 0 !important; } .fact:last-child { grid-column: 1 / -1; border-bottom: 0; } }

/* ---------- Cards ---------- */
.card { position: relative; background: var(--bg-elev); border: 1px solid var(--line); border-radius: var(--radius); padding: clamp(22px, 2.6vw, 28px); transition: transform .25s var(--ease), box-shadow .25s var(--ease), border-color .25s; }
.card:hover { transform: translateY(-3px); box-shadow: var(--shadow); border-color: var(--line-strong); }
.card h3 { margin-bottom: .4em; }
.card p:last-child { margin-bottom: 0; }
.card p { color: var(--text); font-size: 16px; font-weight: 500; line-height: 1.5; }
.ic { display: grid; place-items: center; width: 46px; height: 46px; border-radius: var(--radius); background: var(--accent-soft); color: var(--accent-text); margin-bottom: 18px; }
.ic svg { width: 22px; height: 22px; }
.ic.dark { background: var(--black); color: #fff; }
[data-theme="dark"] .ic.dark { background: #fff; color: #000; }
.tag-free { display: inline-block; font-size: 11px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; border-radius: 3px; padding: 3px 8px; background: var(--accent-soft); color: var(--accent-text); margin-left: 6px; vertical-align: middle; }
.tag-paid { background: var(--chip-bg); color: var(--text-muted); border: 1px solid var(--line); }

/* Split media */
.split { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: clamp(28px, 5vw, 72px); align-items: center; }
.split.rev > :first-child { order: 2; }
.split img { border-radius: var(--radius); border: 1px solid var(--line); box-shadow: var(--shadow); }
@media (max-width: 900px) { .split { grid-template-columns: minmax(0, 1fr); } .split.rev > :first-child { order: 0; } }
.checklist { list-style: none; padding: 0; margin: 0 0 1.4em; display: grid; gap: 12px; }
.checklist li { position: relative; padding-left: 34px; margin: 0; }
.checklist li::before { content: ""; position: absolute; left: 0; top: .15em; width: 22px; height: 22px; border-radius: 4px; background: var(--accent-soft) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23086DD6' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 12.5l4.5 4.5L19 7.5'/%3E%3C/svg%3E") center/14px no-repeat; }

/* Flow steps (encryption) */
.flow { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 18px; counter-reset: flow; margin-top: 32px; }
.flow-step { position: relative; padding: 24px; border-radius: var(--radius); background: var(--bg-elev); border: 1px solid var(--line); }
.flow-step::before { counter-increment: flow; content: "0" counter(flow); font: 700 13px var(--mono); color: var(--accent-text); display: block; margin-bottom: 10px; }
.flow-step p { margin: 0; color: var(--text); font-size: 16px; }
@media (max-width: 800px) { .flow { grid-template-columns: minmax(0, 1fr); } }

/* ---------- Pricing ---------- */
.plans { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 20px; align-items: stretch; }
.plan { display: flex; flex-direction: column; background: var(--bg-elev); border: 1px solid var(--line); border-radius: var(--radius); padding: 30px; position: relative; }
.plan.featured { border: 2px solid var(--accent); box-shadow: 0 24px 50px -28px rgba(8, 109, 214, .45); }
.plan-badge { position: absolute; top: -13px; left: 30px; background: var(--accent); color: #fff; font-size: 12px; font-weight: 700; padding: 4px 12px; border-radius: var(--radius-sm); letter-spacing: .03em; }
.plan h3 { font-size: 20px; margin-bottom: 6px; }
.plan .price { font-family: var(--font-head); font-size: 44px; font-weight: 900; color: var(--heading); line-height: 1.1; }
.plan .price small { font-family: var(--font); font-size: 16px; font-weight: 500; color: var(--text-muted); }
.plan .plan-desc { color: var(--text); font-weight: 500; font-size: 16px; min-height: 3em; margin: 8px 0 18px; }
.plan ul { list-style: none; padding: 0; margin: 0 0 24px; display: grid; gap: 9px; font-size: 16px; }
.plan li { margin: 0; padding-left: 26px; position: relative; }
.plan li::before { content: ""; position: absolute; left: 0; top: .3em; width: 15px; height: 15px; background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23086DD6' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 12.5l4.5 4.5L19 7.5'/%3E%3C/svg%3E") center/contain no-repeat; }
.plan .btn { margin-top: auto; }
.fineprint { font-size: 15px; color: var(--text-muted); margin-top: 22px; }
@media (max-width: 960px) { .plans { grid-template-columns: minmax(0, 1fr); max-width: 560px; margin-inline: auto; } }

/* ---------- Download ---------- */
.dl-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
.dl-card { display: flex; flex-direction: column; gap: 4px; padding: 24px; border-radius: var(--radius); background: var(--bg-elev); border: 1px solid var(--line); color: var(--text); transition: border-color .2s, box-shadow .2s, transform .2s var(--ease); }
.dl-card:hover { border-color: var(--accent); box-shadow: var(--shadow); transform: translateY(-2px); }
.dl-card.is-detected { border: 2px solid var(--accent); background: var(--accent-soft); }
.dl-card .os { display: flex; align-items: center; gap: 12px; margin-bottom: 8px; }
.dl-card .os svg { width: 28px; height: 28px; color: var(--accent); }
.dl-card h3 { margin: 0; font-size: 20px; }
.dl-card .meta { font-size: 15px; color: var(--text-muted); margin-bottom: 14px; }
.dl-card .btn { margin-top: auto; }
.dl-card .detected-label { display: none; font-size: 11px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--accent-text); }
.dl-card.is-detected .detected-label { display: inline; }
.dl-note { display: flex; gap: 14px; align-items: flex-start; margin-top: 26px; padding: 18px 20px; border-radius: var(--radius); background: var(--bg-elev); border: 1px dashed var(--line-strong); font-size: 16px; color: var(--text); }
.dl-note svg { width: 22px; height: 22px; color: var(--success); flex: none; margin-top: 2px; }
.dl-note p { margin: 0; }
@media (max-width: 900px) { .dl-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 560px) { .dl-grid { grid-template-columns: minmax(0, 1fr); } }

/* ---------- Tabs (install + FAQ) ---------- */
.tablist { display: flex; flex-wrap: wrap; gap: 4px; padding: 4px; border-radius: var(--radius); background: var(--bg-soft); border: 1px solid var(--line); width: fit-content; max-width: 100%; margin-bottom: 28px; }
.section-head.center + .tablist, .tablist.center { margin-inline: auto; }
.tab { display: inline-flex; align-items: center; gap: 8px; border: 0; background: transparent; color: var(--text-muted); font: 600 15px var(--font); padding: 10px 16px; border-radius: var(--radius-sm); cursor: pointer; transition: background-color .15s, color .15s; }
.tab:hover { color: var(--heading); }
.tab[aria-selected="true"] { background: var(--accent); color: #fff; }
.tab .count { font-size: 12px; background: var(--accent-soft); color: var(--accent-text); padding: 1px 8px; border-radius: 3px; }
.tab[aria-selected="true"] .count { background: rgba(255, 255, 255, .2); color: #fff; }
.tabpanel[hidden] { display: none; }
@media (max-width: 640px) { .tablist { width: 100%; } .tab { flex: 1 1 auto; justify-content: center; padding: 9px 12px; } }

.steps { display: grid; gap: 14px; counter-reset: step; }
.step { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 18px; padding: 22px 24px; border-radius: var(--radius); border: 1px solid var(--line); background: var(--bg-elev); }
.step .num { display: grid; place-items: center; width: 38px; height: 38px; border-radius: var(--radius); background: var(--accent); color: #fff; font-family: var(--font-head); font-weight: 900; font-size: 17px; }
.step h3 { margin: 4px 0 6px; font-size: 18px; }
.step p { margin: 0; color: var(--text); font-size: 16px; }
.install-aside { margin-top: 18px; font-size: 16px; color: var(--text-muted); }

/* Split layout: vertical tabs on the left, answer/steps card on the right */
.tabs-split { display: grid; grid-template-columns: 330px minmax(0, 1fr); gap: 32px; align-items: start; max-width: 1080px; margin-inline: auto; }
.tabs-side { display: grid; gap: 18px; position: sticky; top: calc(var(--header-h) + 24px); }
.install-tabs > .tablist-v { position: sticky; top: calc(var(--header-h) + 24px); }
.tablist-v { flex-direction: column; flex-wrap: nowrap; width: 100%; margin: 0; padding: 8px; gap: 4px; background: var(--bg-elev); border-radius: var(--radius); box-shadow: var(--shadow-sm); }
.tablist-v .tab { position: relative; width: 100%; gap: 14px; padding: 12px 14px; text-align: left; color: var(--text); border: 1px solid transparent; border-radius: 6px; }
.tablist-v .tab:hover { background: var(--bg-soft); color: var(--heading); }
.tablist-v .tab[aria-selected="true"] { background: var(--accent-soft); border-color: color-mix(in srgb, var(--accent) 35%, transparent); color: var(--heading); }
.tablist-v .tab[aria-selected="true"]::before { content: ""; position: absolute; left: -9px; top: 12px; bottom: 12px; width: 3px; border-radius: 0 3px 3px 0; background: var(--accent); }
.tab-ic { display: grid; place-items: center; width: 40px; height: 40px; flex: none; border-radius: var(--radius); background: var(--bg-soft); border: 1px solid var(--line); color: var(--accent); transition: background-color .15s, color .15s, border-color .15s; }
.tab-ic svg { width: 20px; height: 20px; }
.tablist-v .tab[aria-selected="true"] .tab-ic { background: var(--accent); border-color: var(--accent); color: #fff; }
.tab-label { display: flex; flex-direction: column; flex: 1; min-width: 0; font-size: 16px; font-weight: 600; line-height: 1.3; color: var(--heading); }
.tab-label small { margin-top: 3px; font-size: 13px; font-weight: 400; color: var(--text-muted); }
.tablist-v .tab .count { background: var(--bg-soft); border: 1px solid var(--line); color: var(--text-muted); }
.tablist-v .tab[aria-selected="true"] .count { background: var(--accent); border-color: var(--accent); color: #fff; }
.tabs-note { margin: 0; padding: 0 6px; font-size: 15px; color: var(--text-muted); }

.tabs-panels .tabpanel { background: var(--bg-elev); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow-sm); padding: 30px 34px; }
.tabs-panels .tabpanel:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }

/* Install steps as a connected timeline */
.install-tabs .steps { gap: 0; }
.install-tabs .step { position: relative; padding: 0 0 26px; border: 0; border-radius: 0; background: none; }
.install-tabs .step:not(:last-child)::before { content: ""; position: absolute; left: 19px; top: 46px; bottom: 6px; width: 2px; background: var(--line); }
.install-tabs .step .num { width: 40px; height: 40px; border-radius: 50%; box-shadow: 0 0 0 5px var(--accent-soft); }
.install-tabs .step h3 { margin-top: 7px; }
.install-tabs .install-aside { margin: 4px 0 0; padding-top: 18px; border-top: 1px solid var(--line); }

/* FAQ answers as a clean divided list inside one card */
.faq-tabs .tabpanel { padding: 6px 30px; }
.faq-tabs .faq-list { max-width: none; gap: 0; }
.faq-tabs .faq-item { border: 0; border-bottom: 1px solid var(--line); border-radius: 0; background: none; }
.faq-tabs .faq-item:last-child { border-bottom: 0; }
.faq-tabs .faq-item.open { box-shadow: none; }
.faq-tabs .faq-q { padding: 20px 0; }
.faq-tabs .faq-item.open .faq-q { color: var(--accent-text); }
.faq-tabs .faq-a-inner { padding: 0 44px 22px 0; }

@media (max-width: 900px) {
  .tabs-split { grid-template-columns: minmax(0, 1fr); gap: 20px; }
  .tabs-side, .install-tabs > .tablist-v { position: static; }
  .tablist-v { flex-direction: row; overflow-x: auto; scrollbar-width: thin; }
  .tablist-v .tab { width: auto; flex: none; padding: 10px 12px; gap: 10px; }
  .tablist-v .tab[aria-selected="true"]::before { display: none; }
  .tab-label small { display: none; }
  .tab-ic { width: 32px; height: 32px; }
  .tab-ic svg { width: 17px; height: 17px; }
  .tabs-panels .tabpanel { padding: 22px 20px; }
  .faq-tabs .tabpanel { padding: 4px 20px; }
  .faq-tabs .faq-a-inner { padding-right: 0; }
}

/* ---------- Related guides box (inside posts) ---------- */
.related-box { margin: 2.4em 0; padding: 22px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--bg-soft); }
.related-box .related-title { margin: 0 0 14px; font-family: var(--font-head); font-size: 20px; font-weight: 700; color: var(--heading); }
.related-box ul { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.related-box li { margin: 0; padding: 0; }
.related-box li::before { content: none; }
.prose .related-box a, .prose .related-box a:hover { text-decoration: none; }
.related-box a { position: relative; display: flex; flex-direction: column; gap: 4px; height: 100%; padding: 14px 44px 14px 16px; border: 1px solid var(--line); border-radius: 6px; background: var(--bg-elev); text-decoration: none; transition: border-color .15s, box-shadow .15s; }
.related-box a:hover { border-color: var(--accent); box-shadow: 0 8px 20px -14px rgba(8, 109, 214, .6); text-decoration: none; }
.related-box strong { color: var(--heading); font-size: 16px; line-height: 1.35; }
.related-box a:hover strong { color: var(--accent-text); }
.related-box span { color: var(--text-muted); font-size: 14px; line-height: 1.45; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.related-box svg { position: absolute; right: 14px; top: 16px; width: 18px; height: 18px; color: var(--accent); transition: transform .2s var(--ease); }
.related-box a:hover svg { transform: translateX(3px); }
@media (max-width: 640px) { .related-box { padding: 16px; } .related-box ul { grid-template-columns: minmax(0, 1fr); } }

/* ---------- Private vault feature section ---------- */
.vault-section .wrap { display: grid; gap: 28px; }
.vault-card { display: flex; flex-direction: column; border: 1px solid var(--line); border-radius: var(--radius); background: var(--bg-elev); overflow: hidden; box-shadow: var(--shadow-sm); }
.vault-media { background: #e9f1fd; border-bottom: 1px solid var(--line); }
.vault-media img { display: block; width: 100%; height: auto; }
.vault-body { padding: clamp(24px, 4vw, 48px); display: flex; flex-direction: column; gap: 4px; flex: 1; }
.vault-body.center { align-items: center; text-align: center; }
.vault-body.center > p { max-width: 780px; margin-inline: auto; }
.vault-body h2 { margin-bottom: .45em; }
.vault-body h2.h3 { font-size: clamp(22px, 2.2vw, 26px); }
.vault-body p { color: var(--text); }
.vault-body .btn { margin-top: 10px; align-self: center; }
.vault-link { display: inline-flex; align-items: center; gap: 8px; margin-top: auto; padding-top: 10px; font-weight: 700; color: var(--accent-text); }
.vault-link svg, .use-panel a svg, .vault-body .btn svg { width: 18px; height: 18px; transition: transform .2s var(--ease); }
.vault-link:hover svg, .use-panel a:hover svg { transform: translateX(3px); }
.vault-duo { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 28px; }
.center-actions { justify-content: center; margin-top: 10px; }

.use-title { margin: 22px 0 16px; font-size: 18px; }
.tablist.use-tabs { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); width: 100%; max-width: 980px; margin: 0 auto 18px; padding: 0; border: 0; background: none; gap: 8px; }
.use-tabs .tab { justify-content: flex-start; text-align: left; min-height: 42px; gap: 8px; padding: 8px 12px; border: 1px solid var(--line); border-radius: 6px; background: var(--bg-elev); color: var(--text); font-size: 14px; font-weight: 600; }
.use-tabs .tab svg { width: 16px; height: 16px; color: var(--accent); flex: none; }
.use-tabs .tab:hover { border-color: var(--accent); color: var(--accent-text); }
.use-tabs .tab[aria-selected="true"] { background: var(--accent); border-color: var(--accent); color: #fff; }
.use-tabs .tab[aria-selected="true"] svg { color: #fff; }
.use-panels { width: 100%; max-width: 780px; margin: 0 auto 10px; }
.use-panel { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 18px; align-items: start; padding: 22px 24px; border: 1px solid color-mix(in srgb, var(--accent) 30%, var(--line)); border-radius: var(--radius); background: var(--accent-soft); text-align: left; }
.use-panel[hidden] { display: none; }
.use-ic { display: grid; place-items: center; width: 48px; height: 48px; border-radius: var(--radius); background: var(--accent); color: #fff; }
.use-ic svg { width: 24px; height: 24px; }
.use-panel h4 { margin: 2px 0 4px; font-family: var(--font-head); font-size: 19px; color: var(--heading); }
.use-panel p { margin: 0 0 8px; font-size: 16px; }
.use-panel a { display: inline-flex; align-items: center; gap: 6px; font-size: 15px; font-weight: 700; color: var(--accent-text); }

@media (max-width: 760px) {
  .vault-duo { grid-template-columns: minmax(0, 1fr); }
  .tablist.use-tabs { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 6px; }
  .use-tabs .tab { padding: 7px 9px; font-size: 13px; line-height: 1.25; }
  .use-panel { grid-template-columns: minmax(0, 1fr); gap: 12px; padding: 18px; }
  .center-actions .btn { width: 100%; }
}

/* ---------- Tables ---------- */
.table-wrap { overflow-x: auto; border: 1px solid var(--line); border-radius: var(--radius); background: var(--bg-elev); }
.table-wrap table { min-width: 620px; font-size: 16px; }
.table-wrap th, .table-wrap td { text-align: left; padding: 14px 18px; border-bottom: 1px solid var(--line); vertical-align: top; }
.table-wrap thead th { background: var(--bg-soft); font-size: 13px; text-transform: uppercase; letter-spacing: .08em; color: var(--text-muted); font-weight: 700; }
.table-wrap tbody tr:last-child td, .table-wrap tbody tr:last-child th { border-bottom: 0; }
.table-wrap tbody th { color: var(--heading); font-weight: 600; }

/* ---------- Timeline ---------- */
.timeline { list-style: none; margin: 0; padding: 0; position: relative; display: grid; gap: 4px; }
.timeline::before { content: ""; position: absolute; left: 7px; top: 8px; bottom: 8px; width: 2px; background: var(--line); }
.timeline li { position: relative; padding: 0 0 22px 36px; margin: 0; }
.timeline li::before { content: ""; position: absolute; left: 0; top: 6px; width: 16px; height: 16px; border-radius: 50%; background: var(--bg); border: 3px solid var(--accent); }
.timeline time { display: block; font: 700 13px var(--mono); color: var(--accent-text); letter-spacing: .02em; margin-bottom: 2px; }
.timeline strong { color: var(--heading); }
.timeline p { margin: 2px 0 0; color: var(--text); font-size: 16px; }

/* ---------- Post cards ---------- */
.posts { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 24px; }
@media (max-width: 1024px) { .posts { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 640px) { .posts { grid-template-columns: minmax(0, 1fr); } }
.post-card { position: relative; display: flex; flex-direction: column; background: var(--bg-elev); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; transition: transform .25s var(--ease), box-shadow .25s var(--ease), border-color .25s; }
.post-card:hover { transform: translateY(-4px); box-shadow: var(--shadow); border-color: var(--line-strong); }
.post-card .thumb { aspect-ratio: 16 / 9; overflow: hidden; background: var(--bg-soft); border-bottom: 1px solid var(--line); }
.post-card .thumb img { width: 100%; height: 100%; object-fit: cover; transition: transform .5s var(--ease); }
.post-card:hover .thumb img { transform: scale(1.04); }
.post-card .body { display: flex; flex-direction: column; flex: 1; padding: 22px 22px 24px; }
.post-card h3 { font-size: 19px; margin-bottom: .5em; }
.post-card h3 a { color: var(--heading); text-decoration: none; }
.post-card h3 a:hover { color: var(--accent-text); }
.post-card h3 a::after { content: ""; position: absolute; inset: 0; }
.post-card h3 a:focus-visible { box-shadow: none; }
.post-card:focus-within { box-shadow: var(--ring); }
.post-card p { color: var(--text); font-size: 16px; margin-bottom: 16px; }
.post-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 12px; font-size: 14px; color: var(--text-muted); margin-top: auto; }
.post-meta .dot-sep::before { content: "•"; margin-right: 12px; }
.cat-chip { position: relative; z-index: 2; display: inline-flex; width: fit-content; align-items: center; font-size: 12px; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; color: var(--accent-text); background: var(--chip-bg); border: 1px solid var(--line); padding: 3px 8px; border-radius: 3px; text-decoration: none; margin-bottom: 12px; }
.cat-chip:hover { background: var(--accent); border-color: var(--accent); color: #fff; text-decoration: none; }
.center-cta { display: flex; justify-content: center; margin-top: 40px; }

/* ---------- Guide listing ---------- */
.page-hero { background: var(--bg-soft); color: var(--text); padding-block: clamp(44px, 6vw, 76px); position: relative; overflow: hidden; isolation: isolate; border-bottom: 1px solid var(--line); }
.page-hero::before { content: ""; position: absolute; inset: 0; z-index: -1; background: radial-gradient(700px 360px at 88% 0%, var(--glow), transparent 65%); }
.page-hero h1 { margin-bottom: .3em; }
.page-hero .lead { max-width: 720px; margin: 0; }
.breadcrumb { font-size: 14px; margin-bottom: 18px; }
.breadcrumb ol { list-style: none; display: flex; flex-wrap: wrap; gap: 6px; padding: 0; margin: 0; }
.breadcrumb li { margin: 0; display: inline-flex; align-items: center; gap: 6px; color: var(--text-muted); }
.breadcrumb li + li::before { content: "/"; color: var(--line-strong); }
.breadcrumb a { color: var(--accent-text); text-decoration: none; font-weight: 500; }
.breadcrumb a:hover { text-decoration: underline; }

/* Guide toolbar: 8 category tabs in two equal rows of four, search underneath */
.toolbar { display: grid; gap: 14px; margin-bottom: 34px; padding: 14px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--bg-soft); }
.cat-filter { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px; list-style: none; padding: 0; margin: 0; }
.cat-filter li { margin: 0; display: flex; }
.cat-filter a { display: flex; align-items: center; justify-content: center; width: 100%; min-height: 46px; padding: 8px 12px; border-radius: 6px; border: 1px solid var(--line); text-decoration: none; text-align: center; color: var(--text); font-size: 15px; font-weight: 600; line-height: 1.3; background: var(--bg-elev); transition: border-color .15s, background-color .15s, color .15s, box-shadow .15s; }
.cat-filter a:hover { border-color: var(--accent); color: var(--accent-text); text-decoration: none; box-shadow: 0 6px 16px -12px rgba(8, 109, 214, .6); }
.cat-filter a[aria-current="page"] { background: var(--accent); border-color: var(--accent); color: #fff; }
.toolbar .search { flex: none; width: 100%; }
.toolbar .search input { height: 50px; border-radius: 6px; }
@media (max-width: 900px) { .cat-filter { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; } }
@media (max-width: 400px) { .toolbar { padding: 10px; } .cat-filter a { font-size: 14px; padding: 8px; } }
.search { position: relative; flex: 0 1 320px; }
.search input { width: 100%; height: 46px; padding: 0 16px 0 44px; border-radius: var(--radius-sm); border: 1px solid var(--line); background: var(--bg-elev); color: var(--text); font: 500 16px var(--font); }
.search input:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-soft); }
.search svg { position: absolute; left: 15px; top: 50%; width: 18px; height: 18px; transform: translateY(-50%); color: var(--text-muted); pointer-events: none; }
.search-results { margin-bottom: 30px; }
.search-results[hidden] { display: none; }
.search-results h2 { font-size: 20px; }
.search-results ul { list-style: none; padding: 0; margin: 0; display: grid; gap: 8px; }
.search-results li { margin: 0; }
.search-results a { display: block; padding: 14px 18px; border: 1px solid var(--line); border-radius: var(--radius); text-decoration: none; background: var(--bg-elev); }
.search-results a:hover { border-color: var(--accent); text-decoration: none; }
.search-results a strong { display: block; color: var(--heading); }
.search-results a span { font-size: 15px; color: var(--text-muted); }

.pagination { display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 8px; margin-top: 48px; }
.pagination a, .pagination span { display: inline-grid; place-items: center; min-width: 46px; height: 46px; padding: 0 16px; border-radius: var(--radius-sm); border: 1px solid var(--line); text-decoration: none; color: var(--text); font-weight: 600; font-size: 16px; background: var(--bg-elev); transition: border-color .15s, background-color .15s; }
.pagination a:hover { border-color: var(--heading); color: var(--heading); text-decoration: none; }
.pagination [aria-current="page"] { background: var(--accent); border-color: var(--accent); color: #fff; }
.pagination .disabled { opacity: .45; }
.pagination-info { width: 100%; text-align: center; font-size: 15px; color: var(--text-muted); margin-top: 6px; }

/* ---------- Article ---------- */
.article-hero { background: var(--bg-soft); padding-block: clamp(40px, 6vw, 68px) clamp(120px, 14vw, 180px); color: var(--text); position: relative; isolation: isolate; overflow: hidden; }
.article-hero::before { content: ""; position: absolute; inset: 0; z-index: -1; background: radial-gradient(760px 380px at 85% 0%, var(--glow), transparent 65%); }
.article-hero h1 { max-width: 900px; }
.article-hero .lead { max-width: 780px; }
.byline { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 22px; font-size: 15px; color: var(--text-muted); margin-top: 22px; }
.byline .author { display: flex; align-items: center; gap: 10px; color: var(--heading); font-weight: 600; }
.byline .avatar { display: grid; place-items: center; width: 36px; height: 36px; border-radius: 50%; background: var(--accent); color: #fff; font-weight: 700; font-size: 14px; }
.byline .author a { color: var(--heading); text-decoration: none; }
.byline .author a:hover { color: var(--accent-text); text-decoration: underline; }
.article-cover { margin-top: calc(-1 * clamp(100px, 12vw, 150px)); position: relative; z-index: 2; }
.article-cover img { width: 100%; border-radius: var(--radius); box-shadow: var(--shadow-lg); border: 1px solid var(--line); aspect-ratio: 16 / 9; object-fit: cover; }
.article-layout { display: grid; grid-template-columns: minmax(0, 1fr) 280px; gap: clamp(32px, 5vw, 64px); align-items: start; padding-top: clamp(32px, 5vw, 56px); }
@media (max-width: 1024px) { .article-layout { grid-template-columns: minmax(0, 1fr); } .toc-aside { order: -1; } }
.prose { max-width: 740px; font-size: 18px; line-height: 1.6; }
.prose a, .legal a { text-decoration: underline; }
.prose h2 { margin-top: 1.8em; scroll-margin-top: calc(var(--header-h) + 20px); }
.prose h3 { margin-top: 1.6em; }
.prose > :first-child { margin-top: 0; }
.prose img { border-radius: var(--radius); border: 1px solid var(--line); }
.prose ul li::marker, .prose ol li::marker { color: var(--accent); font-weight: 700; }
.prose blockquote { margin: 1.6em 0; padding: 4px 0 4px 22px; border-left: 3px solid var(--highlight); color: var(--text-muted); }
.prose .table-wrap { margin: 1.6em 0; }
.callout { display: flex; gap: 14px; margin: 1.8em 0; padding: 18px 20px; border-radius: var(--radius); background: var(--accent-soft); border: 1px solid color-mix(in srgb, var(--accent) 25%, transparent); font-size: 17px; }
.callout svg { width: 22px; height: 22px; color: var(--accent-text); flex: none; margin-top: 3px; }
.callout p { margin: 0; }
.callout.warn { background: color-mix(in srgb, var(--highlight) 12%, var(--bg)); border-color: color-mix(in srgb, var(--highlight) 45%, transparent); }
.callout.warn svg { color: var(--warn); }
.key-points { margin: 0 0 2em; padding: 22px 24px; border-radius: var(--radius); border: 1px solid var(--line); border-left: 4px solid var(--accent); background: var(--bg-soft); }
.key-points h2 { font-family: var(--font); font-size: 14px !important; text-transform: uppercase; letter-spacing: .08em; margin: 0 0 10px !important; color: var(--text-muted); }
.key-points ul { margin: 0; }
.article-faq { margin-top: 2.6em; }
.article-faq details { border: 1px solid var(--line); border-radius: var(--radius); background: var(--bg-elev); margin-bottom: 10px; }
.article-faq summary { cursor: pointer; list-style: none; padding: 16px 52px 16px 20px; font-weight: 600; color: var(--heading); position: relative; }
.article-faq summary::-webkit-details-marker { display: none; }
.article-faq summary::after { content: ""; position: absolute; right: 20px; top: 50%; width: 10px; height: 10px; margin-top: -7px; border-right: 2px solid var(--accent); border-bottom: 2px solid var(--accent); transform: rotate(45deg); transition: transform .2s; }
.article-faq details[open] summary::after { transform: rotate(-135deg); margin-top: -2px; }
.article-faq details > div { padding: 0 20px 16px; color: var(--text); }
.article-faq details > div p:last-child { margin: 0; }
.sources { margin-top: 2.4em; padding: 20px 22px; border-radius: var(--radius); border: 1px solid var(--line); font-size: 16px; }
.sources h2 { font-size: 18px !important; margin: 0 0 8px !important; }
.sources ul { margin: 0; }
.author-box { display: flex; gap: 16px; margin-top: 2.4em; padding: 22px; border-radius: var(--radius); background: var(--bg-soft); border: 1px solid var(--line); }
.author-box .avatar { display: grid; place-items: center; width: 52px; height: 52px; border-radius: 50%; background: var(--accent); color: #fff; font-weight: 700; flex: none; }
.author-box p { margin: 4px 0 0; font-size: 16px; color: var(--text); }
.author-box strong { color: var(--heading); }
.toc-aside { position: sticky; top: calc(var(--header-h) + 24px); display: grid; gap: 18px; }
@media (max-width: 1024px) { .toc-aside { position: static; } }
.toc { border: 1px solid var(--line); border-radius: var(--radius); padding: 18px 18px 14px; background: var(--bg-elev); }
.toc h2 { font-family: var(--font); font-size: 13px !important; text-transform: uppercase; letter-spacing: .1em; color: var(--text-muted); margin: 0 0 10px; }
.toc ol { list-style: none; padding: 0; margin: 0; display: grid; gap: 2px; font-size: 15px; line-height: 1.4; }
.toc li { margin: 0; }
.toc a { display: block; padding: 6px 10px; border-radius: 4px; color: var(--text); text-decoration: none; border-left: 2px solid transparent; }
.toc a:hover { color: var(--heading); background: var(--bg-soft); text-decoration: none; }
.toc a.active { color: var(--accent-text); font-weight: 600; border-left-color: var(--accent); background: var(--accent-soft); border-radius: 0 4px 4px 0; }
@media (max-width: 1024px) { .toc details summary { cursor: pointer; } }
.side-cta { border-radius: var(--radius); padding: 20px; background: var(--bg-soft); border: 1px solid var(--line); border-top: 4px solid var(--accent); color: var(--text); font-size: 15px; }
.side-cta h2 { font-size: 20px !important; margin: 0 0 6px; }
.side-cta p { margin-bottom: 14px; }
/* Previous / next guide cards */
.article-nav { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px; margin-top: 3em; padding-top: 2.2em; border-top: 1px solid var(--line); }
.article-nav a { display: grid; grid-template-columns: minmax(0, 1fr) 48px; grid-template-rows: auto auto; column-gap: 18px; row-gap: 6px; align-items: center; padding: 22px 24px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--bg-elev); box-shadow: var(--shadow-sm); text-decoration: none; transition: border-color .2s, box-shadow .2s, transform .2s var(--ease); }
.article-nav a:hover { border-color: var(--accent); box-shadow: 0 14px 30px -18px rgba(8, 109, 214, .45); transform: translateY(-2px); text-decoration: none; }
.article-nav small { grid-column: 1; grid-row: 1; align-self: end; display: block; color: var(--accent-text); font-size: 13px; font-weight: 700; text-transform: uppercase; letter-spacing: .08em; }
.article-nav strong { grid-column: 1; grid-row: 2; align-self: start; display: block; color: var(--heading); font-family: var(--font-head); font-size: 18px; font-weight: 700; line-height: 1.35; transition: color .15s; }
.article-nav a:hover strong { color: var(--accent-text); }
.article-nav a::after { content: "\2192"; grid-column: 2; grid-row: 1 / span 2; display: grid; place-items: center; width: 48px; height: 48px; border-radius: 50%; background: var(--accent-soft); color: var(--accent); font-size: 21px; font-weight: 700; line-height: 1; transition: background-color .2s, color .2s, transform .2s var(--ease); }
.article-nav a:hover::after { background: var(--accent); color: #fff; transform: translateX(3px); }
.article-nav .prev { grid-template-columns: 48px minmax(0, 1fr); }
.article-nav .prev small, .article-nav .prev strong { grid-column: 2; }
.article-nav .prev::after { content: "\2190"; grid-column: 1; }
.article-nav .prev:hover::after { transform: translateX(-3px); }
.article-nav .next { grid-column: 2; text-align: right; }
@media (max-width: 640px) {
  .article-nav { grid-template-columns: minmax(0, 1fr); gap: 14px; }
  .article-nav .next { grid-column: auto; text-align: left; }
  .article-nav a { padding: 18px; column-gap: 14px; }
  .article-nav strong { font-size: 16px; }
  .article-nav a::after { width: 40px; height: 40px; font-size: 18px; }
  .article-nav .prev { grid-template-columns: 40px minmax(0, 1fr); }
  .article-nav a { grid-template-columns: minmax(0, 1fr) 40px; }
}
.share { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; margin-top: 2em; font-size: 15px; color: var(--text-muted); }
.share button { font: 600 15px var(--font); }
.reading-progress { position: fixed; left: 0; top: 0; height: 3px; width: 100%; transform-origin: 0 50%; transform: scaleX(0); background: var(--accent); z-index: 150; }

/* ---------- FAQ accordion ---------- */
.faq-list { max-width: 860px; margin: 0 auto; display: grid; gap: 10px; }
.faq-item { border: 1px solid var(--line); border-radius: var(--radius); background: var(--bg-elev); overflow: hidden; transition: border-color .2s; }
.faq-item.open { border-color: var(--accent); box-shadow: var(--shadow-sm); }
.faq-item h3 { margin: 0; font-size: 17px; }
.faq-q { width: 100%; display: flex; align-items: center; justify-content: space-between; gap: 18px; text-align: left; padding: 18px 22px; background: none; border: 0; color: var(--heading); font: 600 17px/1.4 var(--font); cursor: pointer; }
.faq-q .plus { position: relative; width: 28px; height: 28px; flex: none; border-radius: 4px; background: var(--accent-soft); }
.faq-q .plus::before, .faq-q .plus::after { content: ""; position: absolute; left: 50%; top: 50%; width: 12px; height: 2px; margin: -1px 0 0 -6px; background: var(--accent); border-radius: 2px; transition: transform .25s var(--ease); }
.faq-q .plus::after { transform: rotate(90deg); }
.faq-item.open .plus::after { transform: rotate(0); }
.faq-a { max-height: 0; overflow: hidden; transition: max-height .3s var(--ease); }
.faq-a-inner { padding: 0 22px 20px; color: var(--text); font-size: 16px; }
.faq-a-inner p:last-child { margin: 0; }

/* ---------- Prose pages ---------- */
.legal { max-width: 800px; }
.legal h2 { margin-top: 1.6em; }
.legal .updated { font-size: 15px; color: var(--text-muted); }
.contact-grid { display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(0, .8fr); gap: clamp(28px, 5vw, 56px); align-items: start; }
@media (max-width: 900px) { .contact-grid { grid-template-columns: minmax(0, 1fr); } }
.form { display: grid; gap: 18px; padding: clamp(22px, 3vw, 32px); border-radius: var(--radius); border: 1px solid var(--line); background: var(--bg-elev); box-shadow: var(--shadow); }
.form-row { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px; }
@media (max-width: 560px) { .form-row { grid-template-columns: minmax(0, 1fr); } }
.field { display: grid; gap: 7px; }
.field label { font-weight: 600; font-size: 16px; color: var(--heading); }
.field input, .field select, .field textarea { width: 100%; padding: 12px 14px; border-radius: var(--radius-sm); border: 1px solid var(--line); background: var(--bg); color: var(--text); font: 500 16px var(--font); transition: border-color .15s, box-shadow .15s; }
.field textarea { min-height: 150px; resize: vertical; line-height: 1.55; }
.field input:focus, .field select:focus, .field textarea:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-soft); }
.field .hint { font-size: 14px; color: var(--text-muted); }
.field .error { font-size: 14px; color: var(--danger); display: none; }
.field.invalid input, .field.invalid textarea, .field.invalid select { border-color: var(--danger); }
.field.invalid .error { display: block; }
.check { display: flex; gap: 10px; align-items: flex-start; font-size: 15px; color: var(--text); font-weight: 500 !important; }
.check input { width: 18px; height: 18px; margin-top: 3px; accent-color: var(--accent); flex: none; }
.form-status { font-size: 16px; padding: 12px 14px; border-radius: var(--radius-sm); background: var(--accent-soft); color: var(--accent-text); }
.form-status[hidden] { display: none; }
.hp { position: absolute !important; left: -9999px !important; }
.contact-card { padding: 24px; border-radius: var(--radius); border: 1px solid var(--line); background: var(--bg-soft); }
.contact-card h2 { font-size: 22px; }
.contact-mail { display: inline-flex; align-items: center; gap: 10px; font-weight: 600; font-size: 18px; }
.contact-mail svg { width: 20px; height: 20px; color: var(--accent-text); }

/* ---------- CTA band ---------- */
.cta-band { border-radius: var(--radius); padding: clamp(32px, 5vw, 56px); background: var(--bg-soft); border: 1px solid var(--line); color: var(--text); position: relative; overflow: hidden; isolation: isolate; display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 28px; align-items: center; }
.cta-band::before { content: ""; position: absolute; inset: 0; z-index: -1; background: radial-gradient(600px 300px at 100% 0%, var(--glow), transparent 70%); }
.cta-band h2 { margin-bottom: .3em; }
.cta-band p { margin: 0; font-weight: 500; }
.cta-actions { display: flex; flex-wrap: wrap; gap: 12px; }
@media (max-width: 800px) { .cta-band { grid-template-columns: minmax(0, 1fr); } }

/* ---------- Footer ---------- */
.site-footer { background: var(--bg-soft); border-top: 1px solid var(--line); color: var(--text); padding-top: clamp(48px, 6vw, 72px); font-size: 16px; }
.footer-grid { display: grid; grid-template-columns: minmax(240px, 340px) repeat(3, auto); justify-content: space-between; gap: 36px 48px; padding-bottom: 44px; }
.footer-grid > nav { max-width: 300px; }
@media (max-width: 960px) { .footer-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); justify-content: stretch; } .footer-grid > nav { max-width: none; } }
@media (max-width: 560px) { .footer-grid { grid-template-columns: minmax(0, 1fr); } }
.footer-brand p { margin: 16px 0 0; max-width: 340px; color: var(--text); }
.site-footer h2 { font-family: var(--font); color: var(--heading); font-size: 16px; font-weight: 700; line-height: 1.6; margin-bottom: 10px; }
.site-footer ul { list-style: none; padding: 0; margin: 0; display: grid; gap: 8px; }
.site-footer li { margin: 0; }
.site-footer a { color: var(--text); text-decoration: none; }
.site-footer a:hover { color: var(--accent-text); text-decoration: underline; }
.site-footer .brand, .site-footer .brand:hover { color: var(--accent); text-decoration: none; }
.footer-bottom { border-top: 1px solid var(--line); padding-block: 26px 30px; display: grid; justify-items: center; gap: 8px; text-align: center; font-size: 14px; color: var(--text-muted); }
.footer-bottom p { margin: 0; max-width: 820px; }
.footer-bottom .copyright { font-size: 15px; font-weight: 600; color: var(--heading); }
.footer-bottom .copyright a { color: var(--accent-text); font-weight: 700; }
.footer-bottom .footer-disclaimer { line-height: 1.6; }

.to-top { position: fixed; right: 20px; bottom: 20px; z-index: 90; width: 46px; height: 46px; border-radius: var(--radius-sm); border: 0; background: var(--accent); color: #fff; display: grid; place-items: center; cursor: pointer; box-shadow: var(--shadow); opacity: 0; visibility: hidden; transform: translateY(10px); transition: opacity .25s, transform .25s var(--ease), visibility .25s, background-color .15s; }
.to-top:hover { background: var(--accent-hover); }
.to-top.show { opacity: 1; visibility: visible; transform: none; }
.to-top svg { width: 20px; height: 20px; }

/* ---------- 404 ---------- */
.not-found { min-height: 60vh; display: grid; place-items: center; text-align: center; }
.not-found .code { font: 900 clamp(5rem, 16vw, 9rem)/1 var(--font-head); background: linear-gradient(180deg, var(--heading), var(--accent)); -webkit-background-clip: text; background-clip: text; color: transparent; }

/* ---------- Reveal animation ---------- */
.js .reveal { opacity: 0; transform: translateY(18px); transition: opacity .7s var(--ease), transform .7s var(--ease); }
.js .reveal.in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
  .js .reveal { opacity: 1; transform: none; }
}

@media print {
  .site-header, .site-footer, .to-top, .toc-aside, .share, .article-nav, .reading-progress { display: none !important; }
  .article-hero, .page-hero, .hero { background: none !important; color: #000 !important; padding: 0 !important; }
  .article-hero h1, .page-hero h1 { color: #000 !important; }
  .article-cover { margin: 0 !important; }
}

/* ---------- Utilities ---------- */
.mx-auto { margin-inline: auto; }
.center { text-align: center; }
.prose figure { margin: 2em 0; }
.cta-actions[data-center] { justify-content: center; }
.split .flow { grid-template-columns: minmax(0, 1fr); gap: 10px; }
.split .flow-step { display: grid; grid-template-columns: auto minmax(0, 1fr); column-gap: 14px; padding: 16px 18px; }
.split .flow-step::before { grid-row: span 2; margin: 3px 0 0; }
.split .flow-step h3 { margin: 0 0 2px; font-size: 18px; }
.flow + p { margin-top: 18px; }
