*, *::before, *::after { box-sizing: border-box; }

:root {
  --brand: #3b82f6;
  --brand-ink: #1d4ed8;
  --brand-soft: #e8f0fe;
  --green: #15803d;
  --amber: #b45309;
  --ink: #0f1b2d;
  --ink-2: #44566e;
  --muted: #718096;
  --bg: #f5f8fd;
  --surface: #ffffff;
  --surface-2: #edf3fb;
  --line: rgba(15, 27, 45, 0.12);
  --dark: #0b1420;
  --shadow: 0 18px 48px rgba(13, 30, 60, 0.13);
  --ring: rgba(59, 130, 246, 0.4);
  --disp: ui-rounded, "SF Pro Rounded", "Segoe UI", system-ui, -apple-system, sans-serif;
  --body: system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
}

:root[data-theme="dark"] {
  --brand: #5b9bff;
  --brand-ink: #93c0ff;
  --brand-soft: rgba(91, 155, 255, 0.14);
  --green: #4ade80;
  --amber: #fbbf24;
  --ink: #eaf2fe;
  --ink-2: #aec0d6;
  --muted: #8397b0;
  --bg: #090f17;
  --surface: #101b29;
  --surface-2: #152233;
  --line: rgba(255, 255, 255, 0.12);
  --shadow: 0 20px 52px rgba(0, 0, 0, 0.4);
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --brand: #5b9bff;
    --brand-ink: #93c0ff;
    --brand-soft: rgba(91, 155, 255, 0.14);
    --green: #4ade80;
    --amber: #fbbf24;
    --ink: #eaf2fe;
    --ink-2: #aec0d6;
    --muted: #8397b0;
    --bg: #090f17;
    --surface: #101b29;
    --surface-2: #152233;
    --line: rgba(255, 255, 255, 0.12);
    --shadow: 0 20px 52px rgba(0, 0, 0, 0.4);
  }
}

html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--bg); color: var(--ink); font-family: var(--body); line-height: 1.65; -webkit-font-smoothing: antialiased; }
a { color: inherit; text-decoration: none; }
img, svg { display: block; max-width: 100%; }
button { font: inherit; }
.wrap { width: 100%; max-width: 1180px; margin: 0 auto; padding: 0 24px; }

.nav { position: sticky; top: 0; z-index: 20; border-bottom: 1px solid var(--line); background: color-mix(in srgb, var(--bg) 88%, transparent); backdrop-filter: blur(16px); }
.nav-in { min-height: 74px; display: flex; align-items: center; justify-content: space-between; gap: 20px; }
.brand { display: flex; align-items: center; gap: 11px; flex: none; }
.brand img { width: auto; height: 40px; }
.brand b { display: block; font-family: var(--disp); font-size: 1.06rem; line-height: 1; }
.brand span span { display: block; margin-top: 4px; color: var(--brand-ink); font-family: var(--disp); font-size: .58rem; font-weight: 700; letter-spacing: .22em; text-transform: uppercase; }
.nav-actions { display: flex; align-items: center; gap: 10px; }
.back { color: var(--ink-2); font-weight: 700; }
.back:hover { color: var(--brand-ink); }
.theme { width: 40px; height: 40px; border: 1px solid var(--line); border-radius: 8px; background: var(--surface); color: var(--ink); cursor: pointer; display: grid; place-items: center; }
.theme:focus-visible, .btn:focus-visible { outline: none; box-shadow: 0 0 0 4px var(--ring); }
.theme .moon { display: none; }
:root[data-theme="dark"] .theme .sun { display: none; }
:root[data-theme="dark"] .theme .moon { display: block; }
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .theme .sun { display: none; }
  :root:not([data-theme="light"]) .theme .moon { display: block; }
}
.btn { display: inline-flex; align-items: center; justify-content: center; min-height: 42px; padding: 10px 18px; border: 1px solid transparent; border-radius: 999px; font-family: var(--disp); font-weight: 800; }
.btn-primary { background: var(--brand); color: #fff; }
.btn-ghost { border-color: var(--line); background: var(--surface); color: var(--ink); }

main { padding: 46px 0 0; }
.crumb { display: flex; align-items: center; gap: 9px; color: var(--muted); font-size: .9rem; margin-bottom: 34px; }
.crumb a:hover { color: var(--brand-ink); }
.article-head { max-width: 860px; margin: 0 auto 34px; text-align: center; }
.category { display: inline-flex; align-items: center; padding: 6px 12px; border-radius: 999px; background: var(--brand-soft); color: var(--brand-ink); font-family: var(--disp); font-size: .75rem; font-weight: 800; letter-spacing: .09em; text-transform: uppercase; }
.article-head h1 { margin: 18px auto 16px; font-family: var(--disp); font-size: clamp(2.15rem, 5.6vw, 4rem); line-height: 1.04; letter-spacing: -.035em; text-wrap: balance; }
.meta { color: var(--muted); font-size: .92rem; font-variant-numeric: tabular-nums; }
.lead { max-width: 720px; margin: 22px auto 0; color: var(--ink-2); font-size: 1.16rem; line-height: 1.75; }

.article-visual { max-width: 960px; margin: 0 auto 46px; min-height: 360px; padding: 34px; border-radius: 8px; background: var(--dark); display: grid; place-items: center; overflow: hidden; position: relative; box-shadow: var(--shadow); }
.article-visual::before { content: ""; position: absolute; inset: 0; opacity: .18; background: linear-gradient(90deg, transparent 49.8%, #fff 50%, transparent 50.2%), radial-gradient(circle at 50% 50%, transparent 0 90px, #fff 91px 92px, transparent 93px); }
.article-visual img { position: relative; width: min(340px, 84vw); max-height: 480px; object-fit: contain; border-radius: 8px; box-shadow: 0 22px 44px rgba(0, 0, 0, .38); }

.article-body { max-width: 760px; margin: 0 auto; font-size: 1.05rem; }
.article-body h2 { margin: 46px 0 15px; font-family: var(--disp); font-size: clamp(1.55rem, 3vw, 2.05rem); line-height: 1.2; letter-spacing: -.02em; }
.article-body h3 { margin: 30px 0 10px; font-family: var(--disp); font-size: 1.2rem; }
.article-body p { margin: 0 0 20px; color: var(--ink-2); line-height: 1.85; }
.article-body strong { color: var(--ink); }
.article-body ul, .article-body ol { margin: 0 0 24px; padding-left: 24px; color: var(--ink-2); }
.article-body li { margin: 9px 0; padding-left: 4px; }
.article-body li::marker { color: var(--brand); font-weight: 800; }
.note { margin: 30px 0; padding: 20px 22px; border-left: 4px solid var(--green); background: var(--surface-2); border-radius: 0 8px 8px 0; color: var(--ink-2); }
.note strong { display: block; margin-bottom: 5px; }
.article-cta { margin-top: 56px; padding: 34px; border-radius: 8px; background: var(--dark); color: #dbeafe; }
.article-cta h2 { margin: 0 0 10px; color: #fff; }
.article-cta p { color: #b9c8dc; }
.article-cta .actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 20px; }
.article-cta .btn-ghost { background: rgba(255,255,255,.08); border-color: rgba(255,255,255,.2); color: #fff; }

.more { margin: 64px auto 0; max-width: 760px; display: flex; justify-content: space-between; gap: 18px; border-top: 1px solid var(--line); padding-top: 24px; }
.more a { color: var(--brand-ink); font-weight: 800; }

.footer { margin-top: 76px; padding: 42px 0 28px; background: var(--dark); color: #b9c8dc; }
.footer-top { display: flex; justify-content: space-between; align-items: center; gap: 22px; flex-wrap: wrap; }
.footer .brand b { color: #fff; }
.footer-links { display: flex; flex-wrap: wrap; gap: 16px 20px; }
.footer-links a:hover { color: #fff; }
.footer-bottom { margin-top: 26px; padding-top: 20px; border-top: 1px solid rgba(255,255,255,.1); color: #7e92ac; font-size: .86rem; line-height: 1.7; }

@media (max-width: 760px) {
  .nav-actions .portal, .nav-actions .demo { display: none; }
  .article-head { text-align: left; }
  .lead { font-size: 1.05rem; }
  .article-visual { min-height: 300px; padding: 24px; }
  .article-body { font-size: 1rem; }
  .article-cta { padding: 26px 22px; }
  .more { flex-direction: column; }
}

@media (max-width: 480px) {
  .wrap { padding: 0 18px; }
  .brand span { display: none; }
  .article-head h1 { font-size: 2.15rem; }
  .article-visual { min-height: 250px; margin-left: -18px; margin-right: -18px; border-radius: 0; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
}
