/* esorlex.com — Vercel-style theme. Themes: dark (default), light, blood. Accents via data-accent. */
:root {
  --bg: #000;
  --bg-2: #0a0a0a;
  --card: #0a0a0a;
  --card-hover: #111;
  --fg: #ededed;
  --muted: #a1a1a1;
  --subtle: #6b6b6b;
  --border: #1f1f1f;
  --border-2: #333;
  --grid: rgba(255, 255, 255, .055);
  --btn: #ededed;
  --btn-fg: #0a0a0a;
  --nav: rgba(0, 0, 0, .72);
  --spot: rgba(255, 255, 255, .06);
  --accent: #e5484d;
  --accent-soft: rgba(229, 72, 77, .14);
  --radius: 12px;
  --sans: "Geist", ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --mono: "Geist Mono", ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  color-scheme: dark;
}
:root[data-theme="light"] {
  --bg: #fff;
  --bg-2: #fafafa;
  --card: #fff;
  --card-hover: #fafafa;
  --fg: #171717;
  --muted: #666;
  --subtle: #8f8f8f;
  --border: #eaeaea;
  --border-2: #d4d4d4;
  --grid: rgba(0, 0, 0, .05);
  --btn: #171717;
  --btn-fg: #fff;
  --nav: rgba(255, 255, 255, .75);
  --spot: rgba(0, 0, 0, .04);
  color-scheme: light;
}
:root[data-theme="blood"] {
  --bg: #060000;
  --bg-2: #0c0202;
  --card: #0b0202;
  --card-hover: #140405;
  --fg: #f4e9e9;
  --muted: #b59c9c;
  --subtle: #7d6262;
  --border: #261012;
  --border-2: #42191c;
  --grid: rgba(255, 50, 50, .06);
  --nav: rgba(6, 0, 0, .72);
  --spot: rgba(255, 40, 40, .08);
}
:root[data-accent="red"]     { --accent: #e5484d; --accent-soft: rgba(229, 72, 77, .14); }
:root[data-accent="crimson"] { --accent: #ff1f3d; --accent-soft: rgba(255, 31, 61, .14); }
:root[data-accent="mono"]    { --accent: var(--fg); --accent-soft: var(--spot); }
:root[data-accent="blue"]    { --accent: #0070f3; --accent-soft: rgba(0, 112, 243, .14); }
:root[data-accent="violet"]  { --accent: #8e4ec6; --accent-soft: rgba(142, 78, 198, .16); }

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--fg);
  font: 15px/1.6 var(--sans);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
  transition: background-color .25s, color .25s;
}
img { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button, input { font: inherit; color: inherit; }
::selection { background: var(--accent); color: #fff; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; border-radius: 6px; }

.container { width: 100%; max-width: 1120px; margin: 0 auto; padding: 0 24px; }
.mono { font-family: var(--mono); }

/* ---------- nav ---------- */
.nav {
  position: sticky; top: 0; z-index: 50;
  height: 64px;
  background: var(--nav);
  backdrop-filter: saturate(180%) blur(12px);
  -webkit-backdrop-filter: saturate(180%) blur(12px);
  border-bottom: 1px solid var(--border);
}
.nav .container { height: 100%; display: flex; align-items: center; gap: 24px; }
.brand { display: flex; align-items: center; gap: 10px; font-weight: 600; letter-spacing: -.02em; }
.brand img { width: 28px; height: 28px; border-radius: 7px; border: 1px solid var(--border-2); background: #000; }
.brand .slash { color: var(--border-2); font-weight: 300; font-size: 20px; margin: 0 2px; }
.brand .sub { color: var(--muted); font-weight: 400; }
.nav-links { display: flex; gap: 4px; margin-left: 8px; }
.nav-links a {
  padding: 6px 10px; border-radius: 6px; color: var(--muted); font-size: 14px;
  transition: color .15s, background .15s;
}
.nav-links a:hover, .nav-links a[aria-current="page"] { color: var(--fg); background: var(--spot); }
.nav-right { margin-left: auto; display: flex; align-items: center; gap: 6px; }
.icon-btn {
  width: 34px; height: 34px; display: grid; place-items: center; border-radius: 8px;
  color: var(--muted); transition: color .15s, background .15s;
}
.icon-btn:hover { color: var(--fg); background: var(--spot); }
.icon-btn svg { width: 17px; height: 17px; fill: currentColor; }

/* ---------- buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  height: 40px; padding: 0 16px; border-radius: 8px;
  font-size: 14px; font-weight: 500; white-space: nowrap; cursor: pointer;
  border: 1px solid transparent; transition: background .15s, border-color .15s, color .15s, transform .15s;
}
.btn svg { width: 16px; height: 16px; fill: currentColor; }
.btn-primary { background: var(--btn); color: var(--btn-fg); }
.btn-primary:hover { opacity: .88; }
.btn-secondary { background: transparent; border-color: var(--border-2); color: var(--fg); }
.btn-secondary:hover { background: var(--spot); }
.btn-sm { height: 32px; padding: 0 12px; font-size: 13px; border-radius: 6px; }
.btn-danger { background: transparent; border-color: var(--border-2); color: #e5484d; }
.btn-danger:hover { background: rgba(229, 72, 77, .1); border-color: #e5484d; }

/* ---------- hero ---------- */
.hero { position: relative; padding: 104px 0 72px; overflow: hidden; }
.hero::before {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background-image: linear-gradient(var(--grid) 1px, transparent 1px), linear-gradient(90deg, var(--grid) 1px, transparent 1px);
  background-size: 64px 64px; background-position: center top;
  -webkit-mask-image: radial-gradient(ellipse 70% 60% at 50% 0%, #000 30%, transparent 75%);
  mask-image: radial-gradient(ellipse 70% 60% at 50% 0%, #000 30%, transparent 75%);
}
.hero::after {
  content: ""; position: absolute; left: 50%; top: -260px; width: 900px; height: 520px; transform: translateX(-50%);
  background: radial-gradient(closest-side, var(--accent-soft), transparent); pointer-events: none;
}
.hero .container { position: relative; z-index: 1; display: grid; grid-template-columns: 1.25fr 1fr; gap: 56px; align-items: center; }
.pill {
  display: inline-flex; align-items: center; gap: 8px; height: 30px; padding: 0 12px 0 10px;
  border: 1px solid var(--border-2); border-radius: 999px; font-size: 13px; color: var(--muted); background: var(--bg-2);
}
.pill .dot { width: 7px; height: 7px; border-radius: 50%; background: var(--accent); box-shadow: 0 0 0 3px var(--accent-soft); }
.pill b { color: var(--fg); font-weight: 500; }
h1.title {
  margin: 22px 0 18px; font-size: clamp(52px, 8.5vw, 96px); line-height: .95; letter-spacing: -.055em; font-weight: 700;
  background: linear-gradient(180deg, var(--fg) 35%, var(--subtle)); -webkit-background-clip: text; background-clip: text; color: transparent;
}
h1.title .accent-dot { color: var(--accent); -webkit-text-fill-color: var(--accent); }
.lead { font-size: 19px; line-height: 1.55; color: var(--muted); max-width: 520px; margin: 0 0 32px; letter-spacing: -.01em; }
.lead strong { color: var(--fg); font-weight: 500; }
.cta { display: flex; flex-wrap: wrap; gap: 12px; }

/* profile card */
.profile {
  border: 1px solid var(--border); border-radius: 16px; background: var(--card); overflow: hidden;
  box-shadow: 0 0 0 1px rgba(0, 0, 0, .02), 0 30px 80px -20px rgba(0, 0, 0, .5);
}
.profile-banner { position: relative; aspect-ratio: 5 / 2; background: #000 url("/assets/eyes-anim.webp") center / cover no-repeat; }
/* blinking eyes; the still frame when motion is reduced */
:root[data-motion="reduce"] .profile-banner { background-image: url("/assets/eyes.webp"); }
@media (prefers-reduced-motion: reduce) { .profile-banner { background-image: url("/assets/eyes.webp"); } }
.profile-banner::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, transparent 40%, var(--card)); }
.profile-body { position: relative; padding: 0 22px 22px; margin-top: -40px; }
.avatar {
  width: 80px; height: 80px; border-radius: 50%; border: 4px solid var(--card); background: #111 center / cover;
  position: relative; z-index: 1; image-rendering: auto;
}
.avatar-wrap { position: relative; width: 80px; }
.avatar-wrap .status { position: absolute; right: 2px; bottom: 4px; width: 18px; height: 18px; border-radius: 50%; background: #80848e; border: 4px solid var(--card); z-index: 2; transition: background .3s; }
[data-status="online"]  { --st: #23a55a; }
[data-status="idle"]    { --st: #f0b232; }
[data-status="dnd"]     { --st: #f23f43; }
[data-status="offline"], [data-status="unknown"] { --st: #80848e; }
.avatar-wrap .status, .pdot { background: var(--st); }

/* live Discord presence (Lanyard) */
.presence { margin-top: 12px; display: grid; gap: 10px; }
.presence[hidden] { display: none; }
.presence-line { display: flex; align-items: center; gap: 8px; font-size: 13px; color: var(--muted); min-width: 0; }
.pdot { width: 8px; height: 8px; border-radius: 50%; flex: none; }
[data-status="online"].pdot { box-shadow: 0 0 0 3px rgba(35, 165, 90, .18); }
.presence-line .custom { color: var(--fg); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; min-width: 0; }
.presence-line .custom:not(:empty)::before { content: "·"; color: var(--subtle); margin-right: 8px; }
.presence-line .custom img { width: 16px; height: 16px; display: inline-block; vertical-align: -3px; margin-right: 4px; }
.activity { display: flex; gap: 12px; padding: 12px; border: 1px solid var(--border); border-radius: 10px; background: var(--bg-2); min-width: 0; }
.activity[hidden] { display: none; }
.activity .art { width: 56px; height: 56px; border-radius: 8px; flex: none; background: var(--border) center / cover no-repeat; display: grid; place-items: center; color: var(--subtle); }
.activity .art svg { width: 24px; height: 24px; fill: currentColor; }
.activity .info { min-width: 0; flex: 1; display: grid; gap: 1px; align-content: center; }
.activity .kind { font: 11px var(--mono); text-transform: uppercase; letter-spacing: .08em; color: var(--accent); }
.activity .name { font-weight: 600; font-size: 14px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.activity .sub { font-size: 13px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.activity .sub:empty, .activity .elapsed:empty { display: none; }
.activity .elapsed { font-size: 12px; color: var(--subtle); margin-top: 2px; }
.activity .progress { height: 4px; border-radius: 4px; background: var(--border-2); overflow: hidden; margin-top: 6px; }
.activity .progress[hidden] { display: none; }
.activity .progress i { display: block; height: 100%; width: 0; background: #1db954; border-radius: 4px; }
.profile h3 { margin: 10px 0 0; font-size: 20px; letter-spacing: -.02em; }
.profile .handle { color: var(--muted); font-size: 14px; }
.profile .divider { height: 1px; background: var(--border); margin: 16px 0; }
.tags { display: flex; flex-wrap: wrap; gap: 6px; }
.tag {
  display: inline-flex; align-items: center; gap: 6px; height: 26px; padding: 0 10px; border-radius: 6px;
  font-size: 12px; font-family: var(--mono); color: var(--muted); background: var(--bg-2); border: 1px solid var(--border);
}
.tag .sw { width: 6px; height: 6px; border-radius: 2px; background: var(--accent); }

/* ---------- stats ---------- */
.stats {
  display: grid; grid-template-columns: repeat(3, 1fr);
  border-top: 1px solid var(--border); border-bottom: 1px solid var(--border);
}
.stat { padding: 32px 28px; border-left: 1px solid var(--border); }
.stat:first-child { border-left: 0; }
.stat .v { font-family: var(--mono); font-size: 34px; font-weight: 500; letter-spacing: -.04em; line-height: 1.1; }
.stat .v .plus { color: var(--accent); }
.stat .k { color: var(--muted); font-size: 14px; margin-top: 6px; }

/* ---------- sections ---------- */
section.block { padding: 96px 0 24px; }
.eyebrow { font-family: var(--mono); font-size: 12px; text-transform: uppercase; letter-spacing: .12em; color: var(--accent); }
h2.section-title { margin: 10px 0 12px; font-size: clamp(30px, 4.4vw, 44px); letter-spacing: -.04em; line-height: 1.05; font-weight: 600; }
.section-sub { color: var(--muted); margin: 0 0 40px; max-width: 560px; font-size: 16px; }

/* bento */
.bento { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; }
.card {
  --mx: 50%; --my: 50%;
  position: relative; border: 1px solid var(--border); border-radius: var(--radius); background: var(--card);
  padding: 24px; overflow: hidden; transition: border-color .2s, background .2s, transform .2s;
}
.card::before {
  content: ""; position: absolute; inset: 0; pointer-events: none; opacity: 0; transition: opacity .25s;
  background: radial-gradient(420px circle at var(--mx) var(--my), var(--spot), transparent 60%);
}
.card:hover { border-color: var(--border-2); }
.card:hover::before { opacity: 1; }
.card > * { position: relative; }
.card .num { font-family: var(--mono); font-size: 12px; color: var(--subtle); }
.card h3 { margin: 28px 0 6px; font-size: 20px; letter-spacing: -.025em; font-weight: 600; line-height: 1.25; }
.card p { margin: 0; color: var(--muted); font-size: 15px; }
.card.big { grid-column: span 2; grid-row: span 2; display: flex; flex-direction: column; min-height: 380px; }
.card.big .logo-stage { flex: 1; display: grid; place-items: center; padding: 12px 0; }
.card.big .logo-stage img {
  width: min(220px, 60%); border-radius: 18px; background: #000;
  filter: drop-shadow(0 0 30px rgba(229, 20, 20, .35));
  -webkit-mask-image: radial-gradient(circle, #000 55%, transparent 72%);
  mask-image: radial-gradient(circle, #000 55%, transparent 72%);
  animation: breathe 5s ease-in-out infinite;
}
.card.big h3 { font-size: 28px; margin-top: 8px; }
.card .stat-big { font-family: var(--mono); font-size: 44px; letter-spacing: -.05em; line-height: 1; margin-top: 22px; }
.card .stat-big span { color: var(--accent); }
.card.wide { grid-column: 1 / -1; text-align: center; padding: 56px 24px; background: radial-gradient(600px circle at 50% 120%, var(--accent-soft), var(--card) 70%); }
.card.wide h3 { margin: 10px 0 4px; font-size: clamp(28px, 4vw, 40px); letter-spacing: -.045em; }
.card.wide .heart { width: 22px; height: 22px; fill: var(--accent); margin: 0 auto; }
.card.wide .num { display: block; font-size: 13px; color: var(--muted); letter-spacing: .04em; }
@keyframes breathe { 50% { filter: drop-shadow(0 0 46px rgba(229, 20, 20, .55)); transform: scale(1.025); } }

/* socials */
.socials { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; }
.social { display: flex; flex-direction: column; gap: 18px; }
.social .head { display: flex; align-items: center; gap: 12px; }
.social .ico { width: 40px; height: 40px; border-radius: 10px; display: grid; place-items: center; border: 1px solid var(--border-2); background: var(--bg-2); flex: none; }
.social .ico svg { width: 20px; height: 20px; fill: var(--fg); }
.social .ico img { width: 100%; height: 100%; border-radius: 9px; object-fit: cover; }
.social .name { font-weight: 600; letter-spacing: -.01em; }
.social .meta { color: var(--muted); font-size: 13px; font-family: var(--mono); word-break: break-all; }
.social .actions { display: flex; gap: 8px; margin-top: auto; flex-wrap: wrap; }
.social .arrow { margin-left: auto; color: var(--subtle); transition: transform .2s, color .2s; }
a.card:hover .arrow { transform: translate(2px, -2px); color: var(--fg); }

/* footer */
footer { margin-top: 96px; border-top: 1px solid var(--border); padding: 32px 0 48px; color: var(--muted); font-size: 13px; }
footer .container { display: flex; align-items: center; gap: 16px; flex-wrap: wrap; }
footer .links { margin-left: auto; display: flex; gap: 18px; }
footer a:hover { color: var(--fg); }
footer .brand img { width: 22px; height: 22px; border-radius: 6px; }

/* ---------- settings page ---------- */
.page-head { padding: 72px 0 32px; border-bottom: 1px solid var(--border); }
.page-head h1 { margin: 0 0 8px; font-size: clamp(34px, 5vw, 48px); letter-spacing: -.045em; line-height: 1.05; font-weight: 600; }
.page-head p { margin: 0; color: var(--muted); }
.settings { display: grid; gap: 24px; padding: 40px 0 0; }
.setting { border: 1px solid var(--border); border-radius: var(--radius); background: var(--card); overflow: hidden; }
.setting .body { padding: 24px; }
.setting h2 { margin: 0 0 4px; font-size: 18px; letter-spacing: -.02em; font-weight: 600; }
.setting .desc { margin: 0 0 20px; color: var(--muted); font-size: 14px; }
.setting .foot {
  display: flex; align-items: center; gap: 12px; padding: 12px 24px; background: var(--bg-2);
  border-top: 1px solid var(--border); color: var(--muted); font-size: 13px; min-height: 56px;
}
.setting .foot .right { margin-left: auto; display: flex; gap: 8px; }
.row { display: flex; align-items: center; gap: 16px; padding: 14px 0; border-top: 1px solid var(--border); }
.row:first-of-type { border-top: 0; padding-top: 0; }
.row .label { flex: 1; }
.row .label b { display: block; font-weight: 500; font-size: 14px; }
.row .label span { color: var(--muted); font-size: 13px; }

.theme-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; }
.theme-opt { cursor: pointer; display: block; }
.theme-opt input { position: absolute; opacity: 0; pointer-events: none; }
.theme-opt .preview {
  aspect-ratio: 16 / 10; border-radius: 10px; border: 1px solid var(--border-2); overflow: hidden; position: relative;
  transition: border-color .15s, box-shadow .15s;
}
.theme-opt input:checked + .preview { border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-soft); }
.theme-opt input:focus-visible + .preview { outline: 2px solid var(--accent); outline-offset: 2px; }
.theme-opt .cap { display: flex; align-items: center; gap: 8px; margin-top: 10px; font-size: 14px; font-weight: 500; }
.theme-opt .cap::before { content: ""; width: 14px; height: 14px; border-radius: 50%; border: 1px solid var(--border-2); flex: none; }
.theme-opt input:checked ~ .cap::before { border: 4px solid var(--accent); }
.pv { position: absolute; inset: 0; padding: 10px; display: flex; flex-direction: column; gap: 6px; }
.pv i { display: block; height: 7px; border-radius: 3px; }
.pv .bar { height: 12px; border-radius: 4px; margin-bottom: 4px; }
.pv-dark { background: #000; } .pv-dark i { background: #262626; } .pv-dark .bar { background: #141414; } .pv-dark i.a { background: #e5484d; width: 30%; }
.pv-light { background: #fff; } .pv-light i { background: #e5e5e5; } .pv-light .bar { background: #f3f3f3; } .pv-light i.a { background: #171717; width: 30%; }
.pv-blood { background: #0b0000; } .pv-blood i { background: #3a1214; } .pv-blood .bar { background: #1a0506; } .pv-blood i.a { background: #ff1f3d; width: 30%; }
.pv-system { background: linear-gradient(135deg, #000 50%, #fff 50%); }
.pv i.s1 { width: 80%; } .pv i.s2 { width: 60%; } .pv i.s3 { width: 70%; }

.swatches { display: flex; gap: 10px; flex-wrap: wrap; }
.swatch { position: relative; cursor: pointer; }
.swatch input { position: absolute; opacity: 0; pointer-events: none; }
.swatch span {
  display: block; width: 36px; height: 36px; border-radius: 50%; background: var(--c);
  border: 1px solid var(--border-2); transition: box-shadow .15s, transform .15s;
}
.swatch input:checked + span { box-shadow: 0 0 0 2px var(--bg), 0 0 0 4px var(--c); }
.swatch input:focus-visible + span { outline: 2px solid var(--fg); outline-offset: 4px; }
.swatch:hover span { transform: scale(1.08); }

.switch { position: relative; width: 40px; height: 24px; flex: none; }
.switch input { position: absolute; inset: 0; opacity: 0; margin: 0; cursor: pointer; z-index: 1; }
.switch span { position: absolute; inset: 0; border-radius: 999px; background: var(--border-2); transition: background .2s; }
.switch span::after {
  content: ""; position: absolute; top: 3px; left: 3px; width: 18px; height: 18px; border-radius: 50%;
  background: #fff; transition: transform .2s; box-shadow: 0 1px 2px rgba(0, 0, 0, .3);
}
.switch input:checked + span { background: var(--accent); }
.switch input:checked + span::after { transform: translateX(16px); }
.switch input:focus-visible + span { outline: 2px solid var(--accent); outline-offset: 2px; }
:root[data-accent="mono"] .switch input:checked + span::after { background: var(--bg); }

.seg { display: inline-flex; padding: 3px; border: 1px solid var(--border); border-radius: 8px; background: var(--bg-2); gap: 2px; flex-wrap: wrap; }
.seg label { position: relative; cursor: pointer; }
.seg input { position: absolute; opacity: 0; pointer-events: none; }
.seg span { display: block; padding: 6px 12px; border-radius: 6px; font-size: 13px; color: var(--muted); transition: background .15s, color .15s; }
.seg input:checked + span { background: var(--card); color: var(--fg); box-shadow: 0 0 0 1px var(--border-2); }
.seg input:focus-visible + span { outline: 2px solid var(--accent); }

input[type="range"] { -webkit-appearance: none; appearance: none; width: 220px; max-width: 100%; height: 4px; border-radius: 4px; background: var(--border-2); outline: none; accent-color: var(--accent); }
input[type="range"]::-webkit-slider-thumb { -webkit-appearance: none; width: 16px; height: 16px; border-radius: 50%; background: var(--fg); border: 0; cursor: pointer; }
input[type="range"]::-moz-range-thumb { width: 16px; height: 16px; border-radius: 50%; background: var(--fg); border: 0; cursor: pointer; }
.range-val { font-family: var(--mono); font-size: 13px; color: var(--muted); min-width: 34px; text-align: right; }
.disabled { opacity: .45; pointer-events: none; }

/* toast */
.toast {
  position: fixed; left: 50%; bottom: 28px; z-index: 80; transform: translate(-50%, 20px); opacity: 0;
  background: var(--btn); color: var(--btn-fg); padding: 10px 16px; border-radius: 8px; font-size: 14px; font-weight: 500;
  transition: opacity .2s, transform .2s; pointer-events: none; box-shadow: 0 10px 30px rgba(0, 0, 0, .3);
}
.toast.show { opacity: 1; transform: translate(-50%, 0); }

/* ---------- 404 ---------- */
.notfound { min-height: calc(100vh - 64px); display: grid; place-items: center; text-align: center; padding: 48px 0; }
.notfound .code { font-family: var(--mono); font-size: 14px; color: var(--accent); }
.notfound h1 { font-size: clamp(36px, 6vw, 56px); letter-spacing: -.05em; margin: 10px 0 24px; }

/* ---------- blood rain ---------- */
#rain { position: fixed; inset: 0; width: 100%; height: 100%; pointer-events: none; z-index: 60; }

/* ---------- intro ---------- */
#intro {
  position: fixed; inset: 0; z-index: 100; background: #000; display: grid; place-items: center; cursor: pointer;
  transition: opacity .9s ease, filter .9s ease, transform .9s ease;
}
#intro::before {
  content: ""; position: absolute; inset: 0;
  background: radial-gradient(circle at 50% 46%, rgba(160, 0, 0, .28), transparent 45%); animation: introGlow 3.6s ease-in-out both;
}
#intro .stage { position: relative; display: flex; flex-direction: column; align-items: center; gap: 22px; }
#intro img {
  width: min(58vmin, 400px); height: auto; aspect-ratio: 1;
  /* the logo frames have a dark backdrop; fade its square edge into the black */
  -webkit-mask-image: radial-gradient(circle, #000 52%, transparent 70%);
  mask-image: radial-gradient(circle, #000 52%, transparent 70%);
}
#intro .word {
  font-family: var(--mono); color: #f2d6d6; font-size: clamp(12px, 1.8vw, 15px); letter-spacing: .6em; text-indent: .6em;
  text-transform: uppercase; opacity: 0; animation: introWord 1s ease 1.5s forwards;
}
#intro .bar { width: 160px; height: 1px; background: rgba(255, 255, 255, .1); overflow: hidden; }
#intro .bar i { display: block; height: 100%; background: #e5484d; transform-origin: left; transform: scaleX(0); animation: introBar 3.3s linear forwards; }
#intro .skip { position: absolute; bottom: 28px; left: 0; right: 0; text-align: center; font: 12px var(--mono); color: rgba(255, 255, 255, .3); letter-spacing: .1em; }
#intro.done { opacity: 0; filter: blur(10px); transform: scale(1.06); pointer-events: none; }
.no-intro #intro { display: none; }
html.intro-running, html.intro-running body { overflow: hidden; }
@keyframes introWord { from { opacity: 0; letter-spacing: 1em; } to { opacity: 1; letter-spacing: .6em; } }
@keyframes introBar { to { transform: scaleX(1); } }
@keyframes introGlow { 0% { opacity: 0; } 60% { opacity: 1; } 100% { opacity: .7; } }

/* page reveal after the intro */
/* (only hidden when the head script ran, so the page still shows without JavaScript) */
:root:is(.intro-running, .no-intro) body:not(.revealed) .reveal { opacity: 0; transform: translateY(14px); }
.reveal { transition: opacity .8s ease, transform .8s cubic-bezier(.2, .7, .2, 1); transition-delay: calc(var(--i, 0) * 80ms); }

/* reduced motion (setting or OS) */
:root[data-motion="reduce"] *, :root[data-motion="reduce"] *::before, :root[data-motion="reduce"] *::after {
  animation-duration: .001ms !important; animation-iteration-count: 1 !important; transition-duration: .001ms !important; scroll-behavior: auto !important;
}

/* ---------- responsive ---------- */
@media (max-width: 900px) {
  .hero { padding-top: 64px; }
  .hero .container { grid-template-columns: 1fr; gap: 40px; }
  .bento, .socials { grid-template-columns: 1fr 1fr; }
  .card.big { grid-column: 1 / -1; grid-row: auto; min-height: 320px; }
  .theme-grid { grid-template-columns: repeat(2, 1fr); }
}
.menu-btn { display: none; border: 0; background: none; cursor: pointer; padding: 0; }
.menu-btn span, .menu-btn span::before, .menu-btn span::after {
  display: block; width: 16px; height: 1.5px; background: currentColor; border-radius: 2px; position: relative; transition: transform .2s, background .2s;
}
.menu-btn span::before, .menu-btn span::after { content: ""; position: absolute; left: 0; }
.menu-btn span::before { top: -5px; }
.menu-btn span::after { top: 5px; }
.nav.open .menu-btn span { background: transparent; }
.nav.open .menu-btn span::before { transform: translateY(5px) rotate(45deg); }
.nav.open .menu-btn span::after { transform: translateY(-5px) rotate(-45deg); }

@media (max-width: 640px) {
  .container { padding: 0 16px; }
  .menu-btn { display: grid; }
  .nav-links {
    display: none; position: absolute; top: 64px; left: 0; right: 0; margin: 0; padding: 8px 16px 16px;
    flex-direction: column; gap: 2px; background: var(--bg); border-bottom: 1px solid var(--border);
  }
  .nav.open .nav-links { display: flex; }
  .nav-links a { padding: 12px 10px; font-size: 16px; }
  .nav-right .icon-btn.hide-sm { display: none; }
  .stats { grid-template-columns: 1fr; }
  .stat { border-left: 0; border-top: 1px solid var(--border); padding: 22px 4px; }
  .stat:first-child { border-top: 0; }
  .bento, .socials { grid-template-columns: 1fr; }
  .lead { font-size: 17px; }
  .row { flex-wrap: wrap; }
  .setting .foot { flex-wrap: wrap; }
  footer .links { margin-left: 0; }
}
