/* ==========================================================================
   Mehraz Hossain Rumman — portfolio
   Dark-first, tech aesthetic. Tokens on :root; the light theme swaps tokens.
   ========================================================================== */

:root {
  --bg: #09090b;
  --bg-2: #0e0e13;
  --surface: rgba(255, 255, 255, 0.028);
  --surface-2: rgba(255, 255, 255, 0.05);
  --border: rgba(255, 255, 255, 0.09);
  --border-strong: rgba(255, 255, 255, 0.2);
  --text: #ededf0;
  --text-2: #a1a1aa;
  --text-3: #6e6e78;
  --accent: #a78bfa;
  --accent-2: #22d3ee;
  --accent-ink: #09090b;
  --glow-a: rgba(139, 92, 246, 0.38);
  --glow-b: rgba(34, 211, 238, 0.24);
  --spot: rgba(167, 139, 250, 0.14);
  --solid-bg: #ffffff;
  --solid-fg: #09090b;
  --green: #4ade80;
  --dot: rgba(255, 255, 255, 0.07);
  --shadow: 0 30px 80px -30px rgba(0, 0, 0, 0.8);
  --nav-bg: rgba(14, 14, 19, 0.7);

  --font: "Geist", "Inter", system-ui, -apple-system, "Segoe UI", sans-serif;
  --mono: "Geist Mono", "JetBrains Mono", ui-monospace, SFMono-Regular, Menlo, monospace;
  --radius: 18px;
  --radius-sm: 12px;
  --container: 1140px;
  color-scheme: dark;
}

:root[data-theme="light"] {
  --bg: #fafafa;
  --bg-2: #ffffff;
  --surface: rgba(255, 255, 255, 0.85);
  --surface-2: rgba(0, 0, 0, 0.035);
  --border: rgba(9, 9, 11, 0.09);
  --border-strong: rgba(9, 9, 11, 0.22);
  --text: #09090b;
  --text-2: #52525b;
  --text-3: #8a8a94;
  --accent: #7c3aed;
  --accent-2: #0891b2;
  --accent-ink: #ffffff;
  --glow-a: rgba(124, 58, 237, 0.18);
  --glow-b: rgba(8, 145, 178, 0.14);
  --spot: rgba(124, 58, 237, 0.08);
  --solid-bg: #09090b;
  --solid-fg: #ffffff;
  --green: #16a34a;
  --dot: rgba(9, 9, 11, 0.09);
  --shadow: 0 30px 80px -30px rgba(9, 9, 11, 0.25);
  --nav-bg: rgba(255, 255, 255, 0.72);
  color-scheme: light;
}

/* ---------- Base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; background: var(--bg); }
body {
  margin: 0; font-family: var(--font); font-size: 16px; line-height: 1.6; color: var(--text); background: var(--bg);
  background-image: radial-gradient(var(--dot) 1px, transparent 1px); background-size: 26px 26px;
  -webkit-font-smoothing: antialiased; overflow-x: hidden;
}
img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
strong { color: var(--text); font-weight: 600; }
ul, ol { margin: 0; padding: 0; list-style: none; }
p { margin: 0; }
h1, h2, h3 { margin: 0; font-weight: 600; letter-spacing: -0.02em; line-height: 1.1; }
button { font: inherit; color: inherit; }
::selection { background: var(--accent); color: var(--accent-ink); }

.container { width: min(var(--container), 100% - 2.5rem); margin-inline: auto; }
.mono { font-family: var(--mono); font-size: 0.78rem; color: var(--text-3); letter-spacing: 0.01em; }
.muted { color: var(--text-3); }
.mt { margin-top: 1.1rem; }
.grad { background: linear-gradient(90deg, var(--accent), var(--accent-2)); -webkit-background-clip: text; background-clip: text; color: transparent; }
.arr { display: inline-block; transition: transform 0.2s; }
a:hover .arr { transform: translateX(3px); }
.icon { width: 1.1rem; height: 1.1rem; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; flex-shrink: 0; }

.skip-link { position: absolute; left: 1rem; top: -3rem; padding: 0.5rem 0.9rem; border-radius: 8px; background: var(--solid-bg); color: var(--solid-fg); font-weight: 600; z-index: 100; }
.skip-link:focus { top: 1rem; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; border-radius: 6px; }

/* ---------- Backdrop glow ---------- */
.backdrop { position: fixed; inset: 0; z-index: -1; pointer-events: none; overflow: hidden; }
.orb { position: absolute; border-radius: 50%; filter: blur(80px); opacity: 0.9; }
.orb-a { width: 60vw; height: 60vw; max-width: 760px; max-height: 760px; top: -28vw; right: -18vw; background: radial-gradient(circle, var(--glow-a), transparent 65%); }
.orb-b { width: 45vw; height: 45vw; max-width: 560px; max-height: 560px; top: 30vh; left: -20vw; background: radial-gradient(circle, var(--glow-b), transparent 65%); }

/* ---------- Nav ---------- */
.nav-wrap { position: sticky; top: 0.85rem; z-index: 50; padding-inline: 1.25rem; }
.nav {
  width: min(var(--container), 100%); margin-inline: auto; display: flex; align-items: center; gap: 1rem; justify-content: space-between;
  padding: 0.5rem 0.6rem 0.5rem 0.9rem; border-radius: 999px; border: 1px solid var(--border);
  background: var(--nav-bg); -webkit-backdrop-filter: blur(16px) saturate(1.4); backdrop-filter: blur(16px) saturate(1.4);
  box-shadow: 0 10px 40px -20px rgba(0, 0, 0, 0.6);
}
.brand { display: inline-flex; align-items: center; gap: 0.6rem; font-weight: 600; white-space: nowrap; }
.brand-mark {
  display: grid; place-items: center; width: 32px; height: 32px; border-radius: 10px; font-family: var(--mono); font-size: 0.72rem; font-weight: 600;
  color: #fff; background: linear-gradient(135deg, #8b5cf6, #22d3ee);
}
.nav-links { display: flex; gap: 0.15rem; }
.nav-links a { display: inline-block; padding: 0.45rem 0.7rem; border-radius: 999px; font-size: 0.88rem; font-weight: 500; color: var(--text-2); white-space: nowrap; transition: color 0.15s, background 0.15s; }
.nav-links a:hover, .nav-links a.active { color: var(--text); background: var(--surface-2); }
.nav-actions { display: flex; align-items: center; gap: 0.4rem; }
.icon-btn {
  display: grid; place-items: center; width: 38px; height: 38px; border-radius: 999px; border: 1px solid var(--border); background: transparent; cursor: pointer;
  color: var(--text-2); transition: color 0.15s, border-color 0.15s, background 0.15s, transform 0.15s;
}
.icon-btn:hover { color: var(--text); border-color: var(--border-strong); background: var(--surface-2); transform: translateY(-1px); }
.icon-moon, :root[data-theme="light"] .icon-sun { display: none; }
:root[data-theme="light"] .icon-moon { display: block; }
.nav-toggle { display: none; }
.nav-toggle .icon-close { display: none; }
.nav-toggle[aria-expanded="true"] .icon-menu { display: none; }
.nav-toggle[aria-expanded="true"] .icon-close { display: block; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; gap: 0.5rem; padding: 0.7rem 1.15rem; border-radius: 999px; font-weight: 600; font-size: 0.92rem;
  border: 1px solid transparent; cursor: pointer; transition: transform 0.15s, background 0.15s, border-color 0.15s, box-shadow 0.15s;
}
.btn:hover { transform: translateY(-1px); }
.btn-solid { background: var(--solid-bg); color: var(--solid-fg); }
.btn-solid:hover { box-shadow: 0 12px 30px -12px var(--glow-a); }
.btn-ghost { background: transparent; color: var(--text); border-color: var(--border-strong); }
.btn-ghost:hover { border-color: var(--text); background: var(--surface-2); }
.btn-sm { padding: 0.5rem 0.95rem; font-size: 0.85rem; }
.btn-lg { padding: 0.95rem 1.5rem; font-size: 1.05rem; }

/* ---------- Cards ---------- */
.card {
  position: relative; overflow: hidden; border-radius: var(--radius); border: 1px solid var(--border); background: var(--surface);
  transition: border-color 0.2s, transform 0.2s, box-shadow 0.2s;
}
.card::before {
  content: ""; position: absolute; inset: 0; border-radius: inherit; pointer-events: none; opacity: 0; transition: opacity 0.3s;
  background: radial-gradient(520px circle at var(--mx, 50%) var(--my, 50%), var(--spot), transparent 42%);
}
.card:hover::before { opacity: 1; }
a.card:hover, .project:hover { border-color: var(--border-strong); transform: translateY(-2px); box-shadow: var(--shadow); }
.card > * { position: relative; }

/* ---------- Hero ---------- */
.hero { display: grid; grid-template-columns: 1.1fr 0.9fr; gap: 3rem; align-items: center; padding-block: clamp(3.5rem, 8vw, 6.5rem) clamp(2rem, 4vw, 3rem); }
.status { display: inline-flex; align-items: center; gap: 0.6rem; padding: 0.4rem 0.85rem 0.4rem 0.6rem; border-radius: 999px; border: 1px solid var(--border); background: var(--surface); font-family: var(--mono); font-size: 0.74rem; color: var(--text-2); margin-bottom: 1.5rem; }
.status-dot { position: relative; width: 8px; height: 8px; border-radius: 50%; background: var(--green); }
.status-dot::after { content: ""; position: absolute; inset: -4px; border-radius: 50%; border: 1px solid var(--green); animation: ping 2s ease-out infinite; }
@keyframes ping { 0% { transform: scale(0.5); opacity: 0.9; } 100% { transform: scale(1.7); opacity: 0; } }
.hero-title { font-size: clamp(2.7rem, 6.5vw, 4.6rem); letter-spacing: -0.035em; line-height: 1.02; }
.hero-lead { margin-top: 1.4rem; font-size: clamp(1.02rem, 1.4vw, 1.15rem); color: var(--text-2); max-width: 54ch; }
.hero-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 0.7rem; margin-top: 1.9rem; }
.socials { display: flex; gap: 0.4rem; margin-left: 0.4rem; }

/* Developer ID card */
.id-card { perspective: 1200px; }
.id-inner {
  --rx: 0deg; --ry: 0deg; --sx: 50%; --sy: 50%;
  position: relative; overflow: hidden; padding: 1.5rem; border-radius: 22px; border: 1px solid transparent;
  background: linear-gradient(var(--bg-2), var(--bg-2)) padding-box, linear-gradient(135deg, var(--accent), var(--accent-2) 45%, var(--border) 70%) border-box;
  box-shadow: var(--shadow); transform: rotateX(var(--rx)) rotateY(var(--ry)); transform-style: preserve-3d; transition: transform 0.18s ease;
}
.id-inner::before { content: ""; position: absolute; inset: 0; pointer-events: none; background-image: radial-gradient(var(--dot) 1px, transparent 1px); background-size: 18px 18px; opacity: 0.6; }
.id-sheen { position: absolute; inset: 0; pointer-events: none; opacity: 0; transition: opacity 0.3s; background: radial-gradient(420px circle at var(--sx) var(--sy), rgba(255, 255, 255, 0.12), transparent 45%); }
.id-card:hover .id-sheen { opacity: 1; }
.id-inner > * { position: relative; }
.id-top { display: flex; justify-content: space-between; align-items: center; margin-bottom: 1.25rem; }
.id-top .mono { text-transform: uppercase; letter-spacing: 0.14em; font-size: 0.68rem; }
.id-chip { display: inline-grid; grid-template-columns: repeat(3, 8px); gap: 4px; padding: 5px 7px; border-radius: 6px; background: linear-gradient(135deg, #fbbf24, #f59e0b); }
.id-chip span { display: block; height: 14px; border-radius: 2px; background: rgba(0, 0, 0, 0.28); }
.id-person { display: flex; align-items: center; gap: 1rem; }
.id-photo { width: 84px; height: 84px; border-radius: 20px; object-fit: cover; border: 1px solid var(--border-strong); box-shadow: 0 0 0 4px var(--surface-2); }
.id-name { font-size: 1.15rem; font-weight: 600; letter-spacing: -0.02em; }
.id-role { color: var(--text-2); font-size: 0.92rem; margin-top: 0.1rem; }
.id-loc { display: inline-flex; align-items: center; gap: 0.5rem; margin-top: 0.4rem; font-size: 0.72rem; }
.id-facts { margin: 1.25rem 0 0; display: grid; grid-template-columns: 1fr 1fr; gap: 0.6rem; }
.id-facts > div { padding: 0.6rem 0.75rem; border-radius: 12px; background: var(--surface-2); border: 1px solid var(--border); }
.id-facts dt { font-family: var(--mono); font-size: 0.64rem; text-transform: uppercase; letter-spacing: 0.1em; color: var(--text-3); }
.id-facts dd { margin: 0.15rem 0 0; font-size: 0.86rem; font-weight: 500; color: var(--text); }
.id-foot { display: flex; justify-content: space-between; align-items: center; gap: 1rem; margin-top: 1.2rem; padding-top: 1rem; border-top: 1px solid var(--border); flex-wrap: wrap; }
.gh-stats { display: flex; gap: 1rem; font-size: 0.82rem; color: var(--text-2); }
.gh-stats strong { color: var(--text); font-variant-numeric: tabular-nums; }
.id-link { font-family: var(--mono); font-size: 0.72rem; color: var(--text-2); }
.id-link:hover { color: var(--text); }

/* GitHub tile */
.tile-github { grid-column: span 3; grid-row: span 2; display: flex; flex-direction: column; }
.tile-head { display: flex; justify-content: space-between; align-items: baseline; gap: 0.5rem; }
.tile-more { font-size: 0.78rem; font-weight: 500; color: var(--text-3); white-space: nowrap; }
.tile-more:hover { color: var(--text); }
.gh-repos { display: grid; gap: 0.5rem; margin-top: 0.4rem; }
.gh-repos a { display: grid; gap: 0.15rem; padding: 0.65rem 0.75rem; border-radius: 10px; border: 1px solid var(--border); background: var(--surface-2); transition: border-color 0.15s, transform 0.15s; }
.gh-repos a:hover { border-color: var(--border-strong); transform: translateX(2px); }
.gh-name { font-weight: 600; font-size: 0.92rem; }
.gh-desc { font-size: 0.8rem; color: var(--text-2); line-height: 1.4; display: -webkit-box; -webkit-line-clamp: 1; -webkit-box-orient: vertical; overflow: hidden; }
.gh-meta { font-size: 0.68rem; margin-top: 0.15rem; }

/* ---------- Bento ---------- */
.bento { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); grid-auto-rows: auto; gap: 1rem; padding-block: 1.5rem 2rem; }
.tile { padding: 1.35rem 1.4rem; }
.tile-label { font-family: var(--mono); font-size: 0.7rem; text-transform: uppercase; letter-spacing: 0.12em; color: var(--accent); margin-bottom: 0.65rem; }
.tile-title { font-size: 1.3rem; margin-bottom: 0.5rem; }
.tile-text { color: var(--text-2); font-size: 0.95rem; }
.tile-now { grid-column: span 5; grid-row: span 2; }
.tile-now .chips { margin-top: 1rem; }
.tile-stats { grid-column: span 4; grid-row: span 2; display: grid; grid-template-columns: 1fr 1fr; gap: 0.5rem; }
.stat { display: flex; flex-direction: column; justify-content: flex-end; padding: 0.75rem; border-radius: var(--radius-sm); background: var(--surface-2); border: 1px solid var(--border); }
.stat-num { font-size: 2.1rem; font-weight: 600; letter-spacing: -0.04em; line-height: 1; }
.stat-cap { margin-top: 0.4rem; font-family: var(--mono); font-size: 0.68rem; color: var(--text-3); text-transform: uppercase; letter-spacing: 0.06em; }
.tile-about { grid-column: span 7; }
.tile-edu { grid-column: span 3; }
.tile-geo { grid-column: span 2; }
.geo { font-size: 0.9rem; color: var(--text); line-height: 1.5; margin-bottom: 0.5rem; }
.tile-marquee { grid-column: span 12; padding: 0; display: flex; align-items: center; min-height: 60px; }
.marquee { width: 100%; overflow: hidden; -webkit-mask-image: linear-gradient(90deg, transparent, #000 10%, #000 90%, transparent); mask-image: linear-gradient(90deg, transparent, #000 10%, #000 90%, transparent); }
.marquee-track { display: flex; gap: 2.5rem; width: max-content; padding-inline: 1.25rem; animation: marquee 38s linear infinite; }
.marquee:hover .marquee-track { animation-play-state: paused; }
.marquee-track li { font-family: var(--mono); font-size: 0.8rem; color: var(--text-2); white-space: nowrap; }
.marquee-track li::before { content: "◆"; font-size: 0.5rem; color: var(--accent); margin-right: 2.5rem; vertical-align: middle; }
@keyframes marquee { to { transform: translateX(-50%); } }

/* ---------- Chips / badges ---------- */
.chips { display: flex; flex-wrap: wrap; gap: 0.4rem; margin-top: 0.9rem; }
.chips li { font-family: var(--mono); font-size: 0.7rem; padding: 0.25rem 0.6rem; border-radius: 6px; border: 1px solid var(--border); background: var(--surface-2); color: var(--text-2); }
.chips-lg { margin-top: 0; }
.chips-lg li { font-size: 0.78rem; padding: 0.38rem 0.75rem; color: var(--text); }
.badge { display: inline-flex; align-items: center; font-family: var(--mono); font-size: 0.68rem; padding: 0.25rem 0.6rem; border-radius: 999px; border: 1px solid var(--border); background: var(--surface-2); color: var(--text-2); white-space: nowrap; }
.badge-grad { border-color: transparent; color: #fff; background: linear-gradient(90deg, #8b5cf6, #06b6d4); }

/* ---------- Sections ---------- */
.section { padding-block: clamp(3rem, 6vw, 5rem); }
.section-head { margin-bottom: 2rem; }
.eyebrow { font-family: var(--mono); font-size: 0.74rem; text-transform: uppercase; letter-spacing: 0.14em; color: var(--accent); margin-bottom: 0.6rem; }
.section-title { font-size: clamp(1.8rem, 3.6vw, 2.6rem); letter-spacing: -0.03em; }
.section-sub { margin-top: 0.7rem; color: var(--text-2); max-width: 60ch; }
.section-sub a { color: var(--text); border-bottom: 1px solid var(--border-strong); }
.grid { display: grid; gap: 1.1rem; }
.grid-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.grid-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }

/* ---------- Timeline ---------- */
.timeline { position: relative; display: grid; gap: 1.5rem; }
.tl-item { display: grid; grid-template-columns: 200px 1fr; gap: 2.5rem; position: relative; }
.tl-item::before { content: ""; position: absolute; left: 212px; top: 1.35rem; bottom: -1.5rem; width: 1px; background: var(--border); }
.tl-item:last-child::before { bottom: 0; }
.tl-item::after { content: ""; position: absolute; left: 208px; top: 1.05rem; width: 9px; height: 9px; border-radius: 50%; background: var(--accent); box-shadow: 0 0 0 4px var(--bg), 0 0 18px var(--accent); }
.tl-meta { display: grid; gap: 0.25rem; align-content: start; padding-top: 1rem; }
.tl-meta .mono { color: var(--text); }
.tl-loc { font-size: 0.85rem; color: var(--text-3); }
.tl-card { padding: 1.4rem 1.5rem; }
.tl-title { font-size: 1.25rem; margin-bottom: 0.9rem; }
.tl-at { color: var(--text-2); font-weight: 500; }
.tl-at::before { content: "· "; color: var(--text-3); }
.bullets { display: grid; gap: 0.55rem; }
.bullets li { position: relative; padding-left: 1.2rem; color: var(--text-2); font-size: 0.95rem; }
.bullets li::before { content: ""; position: absolute; left: 0; top: 0.65em; width: 6px; height: 6px; border-radius: 2px; background: linear-gradient(135deg, var(--accent), var(--accent-2)); }
.links-row { display: flex; flex-wrap: wrap; gap: 1.25rem; margin-top: 1rem; font-size: 0.9rem; font-weight: 600; }
.links-row a { color: var(--accent); }

/* ---------- Projects ---------- */
.project { display: block; padding: 1.4rem 1.5rem; }
.project-top { display: flex; justify-content: space-between; align-items: center; margin-bottom: 1rem; }
.arr-box { display: grid; place-items: center; width: 30px; height: 30px; border-radius: 8px; border: 1px solid var(--border); color: var(--text-2); transition: transform 0.2s, color 0.15s, border-color 0.15s; }
.project:hover .arr-box { transform: translate(2px, -2px); color: var(--text); border-color: var(--border-strong); }
.project-title { font-size: 1.35rem; margin-bottom: 0.5rem; }
.project p { color: var(--text-2); font-size: 0.95rem; }
.project-featured { padding: 1.75rem; }
.project-featured::after { content: ""; position: absolute; inset: 0 0 auto 0; height: 2px; background: linear-gradient(90deg, var(--accent), var(--accent-2)); }
.project-featured .project-title { font-size: 1.7rem; }

/* ---------- Open source ---------- */
.oss { display: block; padding: 1.3rem 1.4rem; }
.oss-top { display: flex; justify-content: space-between; align-items: center; gap: 0.75rem; margin-bottom: 0.6rem; }
.oss-name { font-weight: 600; font-size: 1.1rem; letter-spacing: -0.01em; }
.oss p { color: var(--text-2); font-size: 0.93rem; }

/* ---------- Skills / ranks / posts ---------- */
.skill { padding: 1.3rem 1.4rem; }
.rank { display: flex; align-items: center; gap: 1rem; padding: 0.95rem 1.2rem; font-size: 0.95rem; }
.rank .badge { min-width: 6.6rem; justify-content: center; }
.post { display: block; padding: 1.3rem 1.4rem; }
.post-title { font-size: 1.15rem; margin: 0.8rem 0 0.4rem; }
.post p { color: var(--text-2); font-size: 0.9rem; }

/* ---------- Contact ---------- */
.contact { text-align: center; padding: clamp(2.5rem, 6vw, 4.5rem) 1.5rem; }
.contact::after { content: ""; position: absolute; inset: auto 0 -40% 0; height: 80%; background: radial-gradient(50% 60% at 50% 100%, var(--glow-a), transparent 70%); pointer-events: none; }
.contact-title { font-size: clamp(2.2rem, 5.5vw, 3.8rem); letter-spacing: -0.035em; margin-top: 0.3rem; }
.contact-copy { margin: 1rem auto 0; color: var(--text-2); max-width: 46ch; font-size: 1.05rem; }
.email-line { display: flex; flex-wrap: wrap; justify-content: center; gap: 0.7rem; margin-top: 2rem; }
.copy-label { min-width: 3.2ch; text-align: left; }
.copied { border-color: var(--accent); color: var(--accent); }
.contact-links { display: flex; flex-wrap: wrap; justify-content: center; gap: 1.5rem; margin-top: 1.75rem; font-weight: 500; font-size: 0.95rem; color: var(--text-2); }
.contact-links a:hover { color: var(--text); }

/* ---------- Visitor counter ---------- */
.visits { padding-bottom: 1.25rem; }
.visits-inner {
  display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 0.6rem 1.25rem; width: max-content; max-width: 100%; margin-inline: auto;
  padding: 0.7rem 1.35rem; border-radius: 999px; border: 1px solid var(--border); background: var(--surface);
  font-family: var(--mono); font-size: 0.76rem; color: var(--text-2);
}
.visits-label { display: inline-flex; align-items: center; gap: 0.55rem; text-transform: uppercase; letter-spacing: 0.12em; font-size: 0.66rem; color: var(--text-3); }
.visits-item strong { color: var(--text); font-size: 0.95rem; font-weight: 600; font-variant-numeric: tabular-nums; margin-right: 0.15rem; }
.visits-sep { width: 1px; height: 1rem; background: var(--border-strong); }

/* ---------- Footer ---------- */
.footer { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 0.5rem 2rem; padding: 1.75rem 0 2.5rem; font-size: 0.85rem; color: var(--text-3); border-top: 1px solid var(--border); }
.footer a { color: var(--text-2); }
.footer a:hover { color: var(--text); }

/* ---------- Reveal ---------- */
.reveal { opacity: 0; transform: translateY(16px); transition: opacity 0.6s ease, transform 0.6s ease; }
.reveal.in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .reveal { opacity: 1; transform: none; transition: none; }
  .status-dot::after, .marquee-track { animation: none; }
  .id-inner { transition: none; }
  .btn, .card, .arr, .arr-box, .icon-btn { transition: none; }
}

/* ---------- Responsive ---------- */
@media (max-width: 1060px) {
  .nav-links a { padding: 0.4rem 0.55rem; font-size: 0.84rem; }
  .brand-name { display: none; }
}
@media (max-width: 960px) {
  .hero { grid-template-columns: 1fr; gap: 2.25rem; }
  .id-card { max-width: 560px; }
  .tile-github { grid-column: span 5; grid-row: span 2; }
  .tile-now { grid-column: span 7; grid-row: span 1; }
  .tile-stats { grid-column: span 7; grid-row: span 1; }
  .tile-about { grid-column: span 12; }
  .tile-edu { grid-column: span 7; }
  .tile-geo { grid-column: span 5; }
  .grid-3 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .tl-item { grid-template-columns: 1fr; gap: 0.6rem; padding-left: 1.5rem; }
  .tl-item::before { left: 4px; top: 1.5rem; }
  .tl-item::after { left: 0; top: 0.35rem; }
  .tl-meta { padding-top: 0; grid-auto-flow: column; justify-content: start; gap: 1rem; }
}
@media (max-width: 820px) {
  .nav-toggle { display: grid; }
  .nav-cta { display: none; }
  .brand-name { display: inline; }
  .nav-links {
    position: absolute; left: 0; right: 0; top: calc(100% + 0.6rem); display: none; flex-direction: column; gap: 0.15rem;
    padding: 0.6rem; border-radius: var(--radius); border: 1px solid var(--border); background: var(--bg-2);
    box-shadow: var(--shadow);
  }
  .nav-links.open { display: flex; }
  .nav-links a { display: block; padding: 0.8rem 0.9rem; font-size: 0.95rem; border-radius: 10px; }
}
@media (max-width: 640px) {
  .tile-github, .tile-now, .tile-stats, .tile-about, .tile-edu, .tile-geo { grid-column: span 12; grid-row: auto; }
  .grid-2, .grid-3 { grid-template-columns: 1fr; }
  .tl-meta { grid-auto-flow: row; gap: 0.15rem; }
  .hero-actions .socials { margin-left: 0; width: 100%; }
  .id-inner { padding: 1.2rem; }
  .id-facts { grid-template-columns: 1fr; }
  .id-photo { width: 72px; height: 72px; }
  .contact { padding-inline: 1.1rem; }
  .btn-lg { font-size: 0.95rem; padding: 0.85rem 1.2rem; word-break: break-all; }
  .footer { flex-direction: column; }
}
