/* =====================================================================
   Ai365Blog — brand & layout
   Change brand colours in :root below.
   ===================================================================== */
:root {
  --bg: #F6F7FB;
  --surface: #FFFFFF;
  --surface-2: #EEF0F8;
  --ink: #0E1330;
  --ink-2: #2B3156;
  --muted: #5D6386;
  --line: #E2E5F0;

  --brand: #2563EB;     /* electric blue */
  --brand-2: #7C3AED;   /* violet */
  --brand-3: #DB2777;   /* magenta */
  --grad: linear-gradient(120deg, var(--brand) 0%, var(--brand-2) 52%, var(--brand-3) 100%);
  --grad-soft: linear-gradient(120deg, rgba(37,99,235,.10), rgba(124,58,237,.10) 52%, rgba(219,39,119,.10));

  --radius: 16px;
  --radius-sm: 10px;
  --shadow: 0 1px 2px rgba(14,19,48,.05), 0 8px 24px rgba(14,19,48,.06);
  --shadow-lg: 0 2px 4px rgba(14,19,48,.06), 0 20px 48px rgba(14,19,48,.12);

  --font-ui: "Plus Jakarta Sans", system-ui, -apple-system, "Segoe UI", sans-serif;
  --font-read: "Source Serif 4", Georgia, "Times New Roman", serif;
  --font-code: "JetBrains Mono", ui-monospace, Consolas, monospace;

  --max: 1180px;
}
[data-theme="dark"] {
  --bg: #090D1E;
  --surface: #121833;
  --surface-2: #1A2142;
  --ink: #ECEEFB;
  --ink-2: #C9CDE8;
  --muted: #9AA0C3;
  --line: #242C50;
  --shadow: 0 1px 2px rgba(0,0,0,.3), 0 8px 24px rgba(0,0,0,.25);
  --shadow-lg: 0 2px 4px rgba(0,0,0,.3), 0 20px 48px rgba(0,0,0,.45);
  --grad-soft: linear-gradient(120deg, rgba(37,99,235,.18), rgba(124,58,237,.18) 52%, rgba(219,39,119,.18));
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font-ui);
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  transition: background .25s, color .25s;
}
img { max-width: 100%; display: block; }
a { color: var(--brand); text-decoration: none; }
a:hover { text-decoration: underline; }
[data-theme="dark"] a { color: #8AA8FF; }
button { font: inherit; cursor: pointer; }
:focus-visible { outline: 3px solid var(--brand-2); outline-offset: 2px; border-radius: 6px; }

.container { width: min(var(--max), 100% - 40px); margin-inline: auto; }
main { min-height: 70vh; outline: none; }

/* ---------- Header ---------- */
.read-progress {
  position: fixed; top: 0; left: 0; height: 3px; width: 0;
  background: var(--grad); z-index: 100; transition: width .1s linear;
}
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: color-mix(in srgb, var(--bg) 82%, transparent);
  backdrop-filter: saturate(1.6) blur(14px);
  border-bottom: 1px solid var(--line);
}
.header-inner { display: flex; align-items: center; gap: 24px; height: 68px; }
.brand { display: flex; align-items: center; gap: 10px; color: var(--ink); font-weight: 800; letter-spacing: -.02em; }
.brand:hover { text-decoration: none; }
.brand-mark {
  width: 40px; height: 40px; border-radius: 12px; display: grid; place-items: center;
  background: var(--grad); color: #fff; font-size: 12.5px; font-weight: 800; letter-spacing: -.03em;
  box-shadow: 0 6px 16px rgba(124,58,237,.35);
}
.brand-text { font-size: 20px; }
.brand-text b {
  background: var(--grad); -webkit-background-clip: text; background-clip: text; color: transparent;
}
.main-nav { display: flex; gap: 4px; margin-left: auto; }
.main-nav a {
  color: var(--ink-2); font-weight: 600; font-size: 15px;
  padding: 8px 14px; border-radius: 999px;
}
.main-nav a:hover { background: var(--surface-2); text-decoration: none; }
.main-nav a.active { background: var(--ink); color: var(--bg); }
.header-actions { display: flex; gap: 6px; }
.icon-btn {
  width: 40px; height: 40px; display: grid; place-items: center;
  border: 1px solid var(--line); background: var(--surface); color: var(--ink);
  border-radius: 12px;
}
.icon-btn:hover { border-color: var(--brand-2); }
.menu-btn { display: none; }

@media (max-width: 860px) {
  .menu-btn { display: grid; }
  .main-nav {
    position: absolute; top: 68px; left: 0; right: 0;
    flex-direction: column; gap: 2px; padding: 12px 20px 20px;
    background: var(--bg); border-bottom: 1px solid var(--line);
    display: none;
  }
  .main-nav.open { display: flex; }
  .main-nav a { padding: 12px 14px; border-radius: 12px; }
}

/* ---------- Generic ---------- */
.section { padding: 56px 0; }
.section-head { display: flex; align-items: end; justify-content: space-between; gap: 16px; margin-bottom: 24px; }
.section-head h2 { margin: 0; font-size: clamp(24px, 3vw, 30px); letter-spacing: -.02em; }
.section-head p { margin: 4px 0 0; color: var(--muted); }
.link-more { font-weight: 700; white-space: nowrap; }
.eyebrow {
  display: inline-flex; align-items: center; gap: 8px;
  font-size: 12px; font-weight: 800; letter-spacing: .12em; text-transform: uppercase; color: var(--brand-2);
}
[data-theme="dark"] .eyebrow { color: #B795FF; }
.btn {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 12px 20px; border-radius: 999px; font-weight: 700; border: 1px solid transparent;
}
.btn:hover { text-decoration: none; }
.btn-primary { background: var(--grad); color: #fff !important; box-shadow: 0 8px 20px rgba(124,58,237,.3); }
.btn-primary:hover { filter: brightness(1.08); }
.btn-ghost { border-color: var(--line); color: var(--ink) !important; background: var(--surface); }
.btn-ghost:hover { border-color: var(--brand-2); }

.topic-badge {
  display: inline-flex; align-items: center; gap: 6px;
  font-size: 12px; font-weight: 700; padding: 4px 10px; border-radius: 999px;
  color: var(--c); background: color-mix(in srgb, var(--c) 12%, transparent);
  border: 1px solid color-mix(in srgb, var(--c) 25%, transparent);
  white-space: nowrap;
}
.topic-badge:hover { text-decoration: none; }
[data-theme="dark"] .topic-badge { color: color-mix(in srgb, var(--c) 55%, white); }
.topic-badge svg { width: 14px; height: 14px; }
.meta { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 14px; color: var(--muted); font-size: 14px; }
.meta .dot { width: 3px; height: 3px; border-radius: 50%; background: currentColor; opacity: .6; }

/* ---------- Hero ---------- */
.hero { position: relative; overflow: hidden; padding: 72px 0 56px; }
.hero::before {
  content: ""; position: absolute; inset: -40% -10% auto -10%; height: 140%;
  background:
    radial-gradient(600px 300px at 15% 30%, rgba(37,99,235,.20), transparent 70%),
    radial-gradient(500px 300px at 60% 10%, rgba(124,58,237,.18), transparent 70%),
    radial-gradient(500px 280px at 90% 50%, rgba(219,39,119,.14), transparent 70%);
  pointer-events: none;
}
.hero-grid { position: relative; display: grid; grid-template-columns: 1.25fr .9fr; gap: 48px; align-items: center; }
.hero h1 {
  font-size: clamp(36px, 5.6vw, 64px); line-height: 1.04; letter-spacing: -.035em; margin: 14px 0 18px; font-weight: 800;
}
.hero h1 .grad { background: var(--grad); -webkit-background-clip: text; background-clip: text; color: transparent; }
.hero p.lead { font-size: 19px; color: var(--ink-2); max-width: 56ch; margin: 0 0 28px; }
.hero-cta { display: flex; flex-wrap: wrap; gap: 12px; }
.punch {
  display: inline-flex; gap: 0; border-radius: 999px; padding: 4px; background: var(--surface);
  border: 1px solid var(--line); box-shadow: var(--shadow);
}
.punch span { padding: 6px 14px; border-radius: 999px; font-weight: 800; font-size: 13px; letter-spacing: .02em; }
.punch span:nth-child(1) { color: var(--brand); }
.punch span:nth-child(2) { color: var(--brand-2); }
.punch span:nth-child(3) { background: var(--grad); color: #fff; }

.hero-card {
  background: var(--surface); border: 1px solid var(--line); border-radius: 22px; padding: 22px;
  box-shadow: var(--shadow-lg);
}
.hero-card h3 { margin: 0 0 4px; font-size: 15px; }
.hero-card p { margin: 0 0 16px; color: var(--muted); font-size: 14px; }
.focus-list { display: grid; gap: 10px; }
.focus-item {
  display: flex; align-items: center; gap: 14px; padding: 12px 14px; border-radius: 14px;
  border: 1px solid var(--line); color: var(--ink); background: var(--bg);
}
.focus-item:hover { border-color: var(--c); text-decoration: none; transform: translateX(3px); }
.focus-item { transition: transform .15s, border-color .15s; }
.focus-icon { width: 38px; height: 38px; border-radius: 11px; display: grid; place-items: center; color: #fff; background: var(--c); flex: none; }
.focus-icon svg { width: 20px; height: 20px; }
.focus-item b { display: block; font-size: 15px; }
.focus-item small { color: var(--muted); font-size: 13px; }
.focus-item .count { margin-left: auto; font-size: 12px; font-weight: 700; color: var(--muted); }

@media (max-width: 900px) { .hero-grid { grid-template-columns: 1fr; } }

/* ---------- Covers (auto-generated header images, illustrated style) ---------- */
.cover {
  --mint: #22E3CF;
  position: relative; overflow: hidden; aspect-ratio: 16 / 9; border-radius: var(--radius);
  background: linear-gradient(160deg, #42475F 0%, #363A52 100%);
  color: #fff; isolation: isolate;
}
[data-theme="dark"] .cover { background: linear-gradient(160deg, #2C3150 0%, #222741 100%); }
.cover img { width: 100%; height: 100%; object-fit: cover; }
.cv-ring {
  position: absolute; left: 24%; top: 14%; width: 44%; aspect-ratio: 1; border-radius: 50%;
  background: repeating-linear-gradient(135deg, rgba(255,255,255,.10) 0 3px, transparent 3px 11px);
  z-index: -1;
}
.cv-pill {
  position: absolute; border-radius: 999px; transform: rotate(-35deg);
  background: linear-gradient(90deg, var(--c) 0%, color-mix(in srgb, var(--c) 40%, var(--mint)) 55%, var(--mint) 100%);
}
.cv-pill.p1 { width: 62%; height: 20%; right: -18%; top: 20%; }
.cv-pill.p2 { width: 44%; height: 9%;  right: -10%; top: 48%; opacity: .95; }
.cv-pill.p3 { width: 34%; height: 7%;  right: -6%;  top: 68%; opacity: .85; }
.cv-dot { position: absolute; width: 4.5%; aspect-ratio: 1; border-radius: 50%; right: 46%; top: 72%;
  background: linear-gradient(135deg, var(--c), var(--mint)); }
.cv-icon {
  position: absolute; left: 10%; bottom: -4%; width: 30%; max-width: 190px;
  color: color-mix(in srgb, var(--c) 45%, var(--mint));
}
.cv-icon svg { width: 100%; height: auto; stroke-width: 1.5; }
.cover .cover-label {
  position: absolute; left: 6%; top: 10%; z-index: 1; font-weight: 800; font-size: 12px;
  letter-spacing: .14em; text-transform: uppercase; opacity: .85;
}
.cover .cover-title {
  position: absolute; left: 6%; top: 17%; z-index: 1;
  font-weight: 800; letter-spacing: -.02em; line-height: 1.12; font-size: clamp(18px, 2.4vw, 28px);
}
.cover:not(.sm) .cv-icon { width: 22%; bottom: 8%; }
.cover.lg { aspect-ratio: 3 / 1; border-radius: 22px; }
.cover.lg .cv-icon { width: 13%; left: 7%; bottom: 10%; }
.cover.lg .cv-ring { left: 30%; top: -10%; width: 30%; }
.cover.lg .cv-pill.p1 { width: 40%; height: 26%; right: -8%; top: 18%; }
.cover.lg .cv-pill.p2 { width: 28%; height: 12%; right: -2%; top: 56%; }
.cover.lg .cv-pill.p3 { width: 20%; height: 9%; right: 8%; top: 78%; }
.cover.lg .cover-title { font-size: clamp(22px, 3.2vw, 38px); }
@media (max-width: 700px) { .cover.lg { aspect-ratio: 16 / 9; } }

/* ---------- Featured post ---------- */
.featured {
  display: grid; grid-template-columns: 1.2fr 1fr; gap: 32px; align-items: center;
  background: var(--surface); border: 1px solid color-mix(in srgb, var(--brand) 14%, var(--line));
  border-radius: 12px; padding: 18px; box-shadow: var(--shadow); color: var(--ink);
}
.featured .cover { aspect-ratio: 16/10; border-radius: 8px; }
.featured-body { padding: 8px 18px 8px 0; display: flex; flex-direction: column; gap: 12px; align-items: flex-start; }
.featured-body h3 { font-size: clamp(24px, 3vw, 32px); line-height: 1.18; letter-spacing: -.02em; margin: 0; }
.featured-body h3 a { color: var(--ink); }
.featured-body p { color: var(--ink-2); font-size: 16.5px; line-height: 1.7; margin: 0; }
@media (max-width: 860px) { .featured { grid-template-columns: 1fr; } .featured-body { padding: 4px 6px 10px; } }

/* ---------- Post cards (cover · title · date · author · topic · summary · read more) ---------- */
.grid { display: grid; gap: 28px; grid-template-columns: repeat(auto-fill, minmax(310px, 1fr)); }
.card {
  display: flex; flex-direction: column; background: var(--surface);
  border: 1px solid color-mix(in srgb, var(--brand) 14%, var(--line));
  border-radius: 10px; overflow: hidden; color: var(--ink);
  box-shadow: 0 10px 30px rgba(14,19,48,.07);
  transition: transform .18s, box-shadow .18s;
}
.card:hover { transform: translateY(-4px); box-shadow: 0 18px 44px rgba(14,19,48,.13); }
.card-cover:hover { text-decoration: none; }
.card .cover { border-radius: 0; aspect-ratio: 16 / 6.4; }
.card-body { padding: 24px 28px 26px; display: flex; flex-direction: column; gap: 12px; flex: 1; align-items: flex-start; }
.card-body h3 { margin: 0 0 2px; font-size: 21px; line-height: 1.3; letter-spacing: -.015em; font-weight: 800; }
.card-body h3 a { color: var(--ink); }
.card-body h3 a:hover { color: var(--c, var(--brand)); text-decoration: none; }
.card-body p { margin: 0; color: var(--ink-2); font-size: 15.5px; line-height: 1.7; }
.card-body .meta { margin-top: auto; padding-top: 6px; font-size: 13px; }
.card-date { color: var(--ink-2); font-size: 14.5px; }
.card-author { display: flex; align-items: center; gap: 14px; }
.card-author .avatar { width: 54px; height: 54px; box-shadow: 0 0 0 3px var(--surface), 0 0 0 4px var(--line); }
.author-link { font-weight: 800; color: var(--ink) !important; }
.author-link:hover { color: var(--brand) !important; }
.card-topic {
  font-size: 14px; font-weight: 600; letter-spacing: .06em; text-transform: uppercase;
  color: var(--c, var(--brand)) !important;
}
[data-theme="dark"] .card-topic { color: color-mix(in srgb, var(--c) 55%, white) !important; }
.read-more {
  margin-top: auto; padding-top: 10px; font-weight: 800; font-size: 14px; letter-spacing: .1em; text-transform: uppercase;
  color: #14B8A6 !important;
}
.read-more::after { content: " →"; transition: margin .15s; }
.read-more:hover { text-decoration: none; filter: brightness(.9); }

/* ---------- Filters / chips ---------- */
.toolbar { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; margin-bottom: 28px; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip {
  border: 1px solid var(--line); background: var(--surface); color: var(--ink-2);
  padding: 7px 14px; border-radius: 999px; font-weight: 600; font-size: 14px;
  display: inline-flex; align-items: center; gap: 8px;
}
.chip .sw { width: 8px; height: 8px; border-radius: 50%; background: var(--c, var(--muted)); }
.chip:hover { border-color: var(--c, var(--brand-2)); }
.chip.active { background: var(--ink); color: var(--bg); border-color: var(--ink); }
.chip.active .sw { box-shadow: 0 0 0 2px var(--bg); }
.search {
  flex: 1 1 260px; max-width: 380px; display: flex; align-items: center; gap: 8px;
  background: var(--surface); border: 1px solid var(--line); border-radius: 999px; padding: 0 16px;
}
.search input { border: 0; outline: 0; background: transparent; color: var(--ink); font: inherit; padding: 10px 0; width: 100%; }
.search svg { color: var(--muted); flex: none; }
.empty { padding: 48px; text-align: center; color: var(--muted); border: 1px dashed var(--line); border-radius: var(--radius); }

/* ---------- Page header ---------- */
.page-head { padding: 56px 0 28px; position: relative; }
.page-head::before {
  content: ""; position: absolute; inset: 0; background: var(--grad-soft); opacity: .7;
  mask-image: linear-gradient(to bottom, #000, transparent);
  -webkit-mask-image: linear-gradient(to bottom, #000, transparent);
}
.page-head .container { position: relative; }
.page-head h1 { font-size: clamp(32px, 4.6vw, 48px); letter-spacing: -.03em; line-height: 1.08; margin: 10px 0 10px; }
.page-head p { color: var(--ink-2); font-size: 18px; max-width: 62ch; margin: 0; }

/* ---------- Article ---------- */
.post-hero { padding: 40px 0 8px; }
.post-hero .container { max-width: 900px; }
.post-hero h1 { font-size: clamp(32px, 5vw, 52px); line-height: 1.08; letter-spacing: -.035em; margin: 14px 0 14px; }
.post-hero .subtitle { font-size: 21px; line-height: 1.5; color: var(--ink-2); margin: 0 0 20px; font-family: var(--font-read); }
.post-hero .byline { display: flex; align-items: center; gap: 12px; margin-bottom: 28px; }
.avatar {
  width: 42px; height: 42px; border-radius: 50%; background: var(--grad); color: #fff;
  display: grid; place-items: center; font-weight: 800; font-size: 15px; overflow: hidden; flex: none;
}
.avatar img { width: 100%; height: 100%; object-fit: cover; }
.byline b { display: block; font-size: 15px; }
.post-cover { max-width: 1100px; margin: 0 auto; }

.post-layout {
  display: grid; grid-template-columns: minmax(0, 720px) 240px; gap: 56px; justify-content: center;
  padding: 40px 0 24px;
}
.toc { position: sticky; top: 92px; align-self: start; font-size: 14px; }
.toc h4 { margin: 0 0 10px; font-size: 12px; letter-spacing: .12em; text-transform: uppercase; color: var(--muted); }
.toc a { display: block; padding: 6px 0 6px 14px; border-left: 2px solid var(--line); color: var(--muted); }
.toc a:hover, .toc a.active { color: var(--ink); border-color: var(--brand-2); text-decoration: none; }
.toc .share { margin-top: 22px; display: grid; gap: 8px; }
@media (max-width: 1000px) { .post-layout { grid-template-columns: minmax(0, 720px); } .toc { display: none; } }

.prose { font-family: var(--font-read); font-size: 19px; line-height: 1.75; color: var(--ink); }
.prose > *:first-child { margin-top: 0; }
.prose p { margin: 0 0 1.25em; }
.prose h2 {
  font-family: var(--font-ui); font-size: 27px; letter-spacing: -.02em; line-height: 1.25;
  margin: 2em 0 .6em; scroll-margin-top: 90px;
}
.prose h3 { font-family: var(--font-ui); font-size: 21px; margin: 1.6em 0 .5em; scroll-margin-top: 90px; }
.prose ul, .prose ol { padding-left: 1.3em; margin: 0 0 1.3em; }
.prose li { margin: .35em 0; }
.prose li::marker { color: var(--brand-2); font-weight: 700; }
.prose strong { font-weight: 600; color: var(--ink); }
.prose blockquote {
  margin: 1.6em 0; padding: 16px 20px; border-radius: 14px;
  background: var(--grad-soft); border-left: 4px solid var(--brand-2);
  font-family: var(--font-ui); font-size: 16px; line-height: 1.6;
}
.prose blockquote p { margin: 0; }
.prose code { font-family: var(--font-code); font-size: .82em; background: var(--surface-2); padding: .15em .4em; border-radius: 6px; }
.prose pre {
  background: #0E1330; color: #E6E9FF; padding: 18px 20px; border-radius: 14px; overflow: auto;
  font-size: 14.5px; line-height: 1.6; margin: 1.5em 0;
}
.prose pre code { background: none; padding: 0; color: inherit; font-size: inherit; }
.prose table { width: 100%; border-collapse: collapse; font-family: var(--font-ui); font-size: 15px; margin: 1.5em 0; }
.prose th, .prose td { border-bottom: 1px solid var(--line); padding: 10px 12px; text-align: left; }
.prose th { background: var(--surface-2); font-weight: 700; }
.prose img { border-radius: 12px; margin: 1.5em 0; }
.prose hr { border: 0; height: 1px; background: var(--line); margin: 2.5em 0; }

.tags { display: flex; flex-wrap: wrap; gap: 8px; margin: 32px 0 0; }
.tag { font-size: 13px; padding: 4px 12px; border-radius: 999px; background: var(--surface-2); color: var(--ink-2); font-weight: 600; }

.author-box {
  display: flex; gap: 18px; align-items: flex-start; margin: 40px 0 0; padding: 22px;
  border-radius: var(--radius); background: var(--surface); border: 1px solid var(--line);
}
.author-box .avatar { width: 56px; height: 56px; font-size: 19px; }
.author-box h4 { margin: 0 0 2px; font-size: 17px; }
.author-box p { margin: 6px 0 0; color: var(--ink-2); font-size: 15px; }

.post-nav { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin-top: 32px; }
.post-nav a {
  padding: 16px 18px; border-radius: 14px; border: 1px solid var(--line); background: var(--surface); color: var(--ink);
}
.post-nav a:hover { border-color: var(--brand-2); text-decoration: none; }
.post-nav small { display: block; color: var(--muted); font-weight: 700; font-size: 12px; letter-spacing: .08em; text-transform: uppercase; }
.post-nav .next { text-align: right; grid-column: 2; }

/* ---------- Video ---------- */
.video {
  position: relative; aspect-ratio: 16/9; border-radius: var(--radius); overflow: hidden;
  background: #0E1330; border: 1px solid var(--line);
}
.video iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.video-thumb {
  position: absolute; inset: 0; width: 100%; height: 100%; border: 0; padding: 0; cursor: pointer;
  background-size: cover; background-position: center;
}
.video-thumb::after { content: ""; position: absolute; inset: 0; background: linear-gradient(to top, rgba(0,0,0,.55), transparent 60%); }
.play {
  position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%); z-index: 1;
  width: 68px; height: 68px; border-radius: 50%; background: rgba(255,255,255,.95);
  display: grid; place-items: center; box-shadow: 0 10px 30px rgba(0,0,0,.35); transition: transform .15s;
}
.video-thumb:hover .play { transform: translate(-50%, -50%) scale(1.08); }
.play svg { width: 26px; height: 26px; margin-left: 4px; fill: var(--brand-3); }
.video-placeholder {
  position: absolute; inset: 0; display: grid; place-items: center; text-align: center; color: #fff; padding: 20px;
}
.video-placeholder small { display: block; opacity: .85; margin-top: 6px; font-size: 13px; }
.video-card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; }
.video-card .video { border-radius: 0; border: 0; }
.video-card .card-body h3 { font-size: 17px; }
.post-video { margin: 0 0 2em; }
.post-video h4 { font-family: var(--font-ui); margin: 0 0 10px; font-size: 13px; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); }

/* ---------- Announcements ---------- */
.ann-layout { display: grid; grid-template-columns: 220px minmax(0, 1fr); gap: 40px; padding-bottom: 40px; }
.archive { position: sticky; top: 92px; align-self: start; font-size: 14px; }
.archive h4 { margin: 0 0 10px; font-size: 12px; letter-spacing: .12em; text-transform: uppercase; color: var(--muted); }
.archive .yr { font-weight: 800; margin: 14px 0 4px; color: var(--ink); }
.archive button {
  display: flex; justify-content: space-between; width: 100%; border: 0; background: none; color: var(--muted);
  padding: 5px 10px; border-radius: 8px; text-align: left;
}
.archive button:hover { background: var(--surface-2); color: var(--ink); }
.archive button span:last-child { font-size: 12px; font-weight: 700; }
@media (max-width: 860px) { .ann-layout { grid-template-columns: 1fr; } .archive { display: none; } }

.year-block { margin-bottom: 36px; }
.year-title {
  font-size: 44px; font-weight: 800; letter-spacing: -.04em; margin: 0 0 6px; line-height: 1;
  background: var(--grad); -webkit-background-clip: text; background-clip: text; color: transparent;
}
.month-block { position: relative; padding-left: 28px; margin-left: 8px; border-left: 2px solid var(--line); padding-bottom: 8px; }
.month-title {
  position: sticky; top: 70px; z-index: 2; background: var(--bg); margin: 0 0 12px -38px; padding: 14px 0 8px;
  display: flex; align-items: center; gap: 12px; font-size: 18px; scroll-margin-top: 80px;
}
.month-title::before {
  content: ""; width: 16px; height: 16px; border-radius: 50%; background: var(--grad);
  box-shadow: 0 0 0 4px var(--bg); flex: none;
}
.month-title small { color: var(--muted); font-weight: 600; font-size: 13px; }
.ann {
  display: grid; grid-template-columns: 64px minmax(0, 1fr); gap: 16px; padding: 16px 18px; margin-bottom: 12px;
  background: var(--surface); border: 1px solid var(--line); border-radius: 14px;
  transition: border-color .15s, box-shadow .15s;
}
.ann:hover { border-color: color-mix(in srgb, var(--c) 45%, var(--line)); box-shadow: var(--shadow); }
.ann-date {
  text-align: center; border-radius: 12px; padding: 8px 0; background: color-mix(in srgb, var(--c) 12%, transparent);
  color: var(--c); align-self: start;
}
[data-theme="dark"] .ann-date { color: color-mix(in srgb, var(--c) 55%, white); }
.ann-date b { display: block; font-size: 24px; line-height: 1; }
.ann-date small { font-size: 11px; font-weight: 800; letter-spacing: .1em; text-transform: uppercase; }
.ann h3 { margin: 4px 0 4px; font-size: 18px; letter-spacing: -.01em; }
.ann p { margin: 0; color: var(--ink-2); font-size: 15px; }
.ann .ann-top { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.type-pill { font-size: 11px; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
.ann a.more { display: inline-block; margin-top: 8px; font-weight: 700; font-size: 14px; }

.ann-mini { display: grid; gap: 10px; }
.ann-mini a {
  display: flex; gap: 14px; align-items: center; padding: 12px 14px; border-radius: 12px;
  border: 1px solid var(--line); background: var(--surface); color: var(--ink);
}
.ann-mini a:hover { border-color: var(--brand-2); text-decoration: none; }
.ann-mini .d { font-size: 12px; font-weight: 800; color: var(--muted); width: 56px; flex: none; text-transform: uppercase; }

/* ---------- Topics page ---------- */
.topic-card {
  display: flex; flex-direction: column; gap: 12px; padding: 22px; border-radius: var(--radius);
  background: var(--surface); border: 1px solid var(--line); color: var(--ink); position: relative; overflow: hidden;
  transition: transform .18s, box-shadow .18s, border-color .18s;
}
.topic-card::before { content: ""; position: absolute; inset: 0 0 auto 0; height: 4px; background: var(--c); }
.topic-card:hover { transform: translateY(-3px); box-shadow: var(--shadow-lg); border-color: var(--c); text-decoration: none; }
.topic-card h3 { margin: 0; font-size: 20px; }
.topic-card p { margin: 0; color: var(--muted); font-size: 15px; }
.topic-card .count { font-size: 13px; font-weight: 700; color: var(--c); margin-top: auto; }
.topic-card .focus-tag {
  position: absolute; top: 16px; right: 16px; font-size: 11px; font-weight: 800; letter-spacing: .08em; text-transform: uppercase;
  background: var(--grad); color: #fff; padding: 3px 9px; border-radius: 999px;
}

/* ---------- About / mission ---------- */
.mission-band {
  background: var(--ink); color: var(--bg); border-radius: 28px; padding: 48px; position: relative; overflow: hidden;
}
[data-theme="dark"] .mission-band { background: var(--surface-2); color: var(--ink); }
.mission-band::after {
  content: ""; position: absolute; right: -120px; top: -120px; width: 380px; height: 380px; border-radius: 50%;
  background: var(--grad); filter: blur(70px); opacity: .5;
}
.mission-band > * { position: relative; z-index: 1; }
.mission-band h2 { font-size: clamp(28px, 4vw, 44px); letter-spacing: -.03em; line-height: 1.1; margin: 10px 0 14px; max-width: 18ch; }
.mission-band .eyebrow { color: #C4A8FF; }
.mission-band p { max-width: 60ch; opacity: .85; font-size: 17px; margin: 0; }
.values { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; margin-top: 32px; }
.value {
  padding: 20px; border-radius: 18px; background: rgba(255,255,255,.07); border: 1px solid rgba(255,255,255,.12);
}
[data-theme="dark"] .value { background: var(--surface); border-color: var(--line); }
.value .num { font-size: 13px; font-weight: 800; opacity: .6; }
.value h3 { margin: 4px 0 6px; font-size: 22px; }
.value p { font-size: 15px; }
@media (max-width: 760px) { .values { grid-template-columns: 1fr; } .mission-band { padding: 30px 24px; } }

.mvv { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.mvv > div { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 24px; }
.mvv h3 { margin: 8px 0 8px; font-size: 22px; }
.mvv p { margin: 0; color: var(--ink-2); }
.mvv .ic { width: 44px; height: 44px; border-radius: 12px; display: grid; place-items: center; background: var(--grad); color: #fff; }
.mvv .ic svg { width: 22px; height: 22px; }
@media (max-width: 860px) { .mvv { grid-template-columns: 1fr; } }

/* ---------- Two column home ---------- */
.split { display: grid; grid-template-columns: 1.4fr 1fr; gap: 40px; }
@media (max-width: 900px) { .split { grid-template-columns: 1fr; } }

/* ---------- Footer ---------- */
.site-footer { border-top: 1px solid var(--line); margin-top: 48px; padding: 48px 0 28px; background: var(--surface); }
.footer-grid { display: grid; grid-template-columns: 1.6fr 1fr 1fr; gap: 32px; }
.footer-grid h4 { margin: 0 0 12px; font-size: 13px; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); }
.footer-grid ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.footer-grid a { color: var(--ink-2); }
.footer-punch { font-size: 22px; font-weight: 800; letter-spacing: -.02em; margin: 14px 0 6px; }
.footer-bottom { margin-top: 36px; padding-top: 20px; border-top: 1px solid var(--line); display: flex; justify-content: space-between; flex-wrap: wrap; gap: 10px; color: var(--muted); font-size: 14px; }
.socials { display: flex; gap: 8px; margin-top: 14px; }
.socials a { width: 38px; height: 38px; border-radius: 10px; border: 1px solid var(--line); display: grid; place-items: center; color: var(--ink-2); }
.socials a:hover { border-color: var(--brand-2); color: var(--brand-2); }
.socials svg { width: 18px; height: 18px; }
@media (max-width: 760px) { .footer-grid { grid-template-columns: 1fr; } }

.toast {
  position: fixed; bottom: 24px; left: 50%; transform: translateX(-50%) translateY(20px); opacity: 0;
  background: var(--ink); color: var(--bg); padding: 10px 18px; border-radius: 999px; font-weight: 600; font-size: 14px;
  transition: all .25s; z-index: 200; pointer-events: none;
}
.toast.show { opacity: 1; transform: translateX(-50%) translateY(0); }

.fade-in { animation: fade .35s ease both; }
@keyframes fade { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }
@media (prefers-reduced-motion: reduce) { * { animation: none !important; transition: none !important; scroll-behavior: auto !important; } }

/* ---------- About me ---------- */
.me {
  display: grid; grid-template-columns: 300px minmax(0, 1fr); gap: 48px; align-items: start;
  background: var(--surface); border: 1px solid var(--line); border-radius: 24px; padding: 40px; box-shadow: var(--shadow);
}
.me-side { text-align: center; display: flex; flex-direction: column; align-items: center; gap: 12px; position: sticky; top: 92px; }
.me-photo { width: 180px !important; height: 180px !important; box-shadow: 0 0 0 6px var(--surface), 0 0 0 8px transparent; position: relative; }
.me-side .me-photo { background: var(--grad); padding: 5px; }
.me-side .me-photo img { border-radius: 50%; }
.me-side h3 { margin: 6px 0 0; font-size: 20px; }
.me-side .socials { margin: 0; justify-content: center; }
.me-stats { display: grid; gap: 10px; width: 100%; margin-top: 8px; }
.me-stats div { display: flex; align-items: center; gap: 12px; text-align: left; padding: 10px 14px; border-radius: 12px; background: var(--surface-2); }
.me-stats b { font-size: 20px; font-weight: 800; min-width: 48px; background: var(--grad); -webkit-background-clip: text; background-clip: text; color: transparent; }
.me-stats span { font-size: 13px; color: var(--ink-2); line-height: 1.35; }
.me-main h2 { font-size: clamp(24px, 3vw, 32px); line-height: 1.2; letter-spacing: -.025em; margin: 10px 0 18px; }
.me-main p { font-size: 17px; line-height: 1.75; color: var(--ink-2); margin: 0 0 16px; }
.me-main h4 { margin: 26px 0 12px; font-size: 12px; letter-spacing: .12em; text-transform: uppercase; color: var(--muted); }
@media (max-width: 860px) { .me { grid-template-columns: 1fr; padding: 26px; gap: 28px; } .me-side { position: static; } }
