
/* ── TOKENS ── */
:root {
  --c-void:       #03050d;
  --c-deep:       #070c1a;
  --c-midnight:   #0b1224;
  --c-surface:    #0f1a30;
  --c-border:     rgba(59, 130, 246, 0.12);
  --c-border-sub: rgba(255, 255, 255, 0.05);

  --c-blue:       #3b82f6;
  --c-blue-light: #60a5fa;
  --c-blue-dim:   rgba(59, 130, 246, 0.15);
  --c-amber:      #f59e0b;

  --c-text:       #e2e8f0;
  --c-text-sub:   #94a3b8;
  --c-text-muted: #475569;
  --c-white:      #ffffff;

  --f-display: 'Bebas Neue', sans-serif;
  --f-body:    'Outfit', sans-serif;
  --f-mono:    'JetBrains Mono', monospace;

  --section-pad: 120px 60px;
  --max-w: 1080px;
  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
}

/* ── RESET ── */
*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }

html {
  scroll-behavior: smooth;
  scrollbar-width: none;
  -ms-overflow-style: none;
}

html::-webkit-scrollbar {
  display: none;
}

body {
  --ticker-height: 34px;
  --ticker-offset: var(--ticker-height);
  background: var(--c-void);
  color: var(--c-text);
  font-family: var(--f-body);
  font-size: 16px;
  line-height: 1.6;
  overflow-x: hidden;
  scrollbar-width: none;
  -webkit-font-smoothing: antialiased;
}

body::-webkit-scrollbar {
  display: none;
}

body.ticker-collapsed {
  --ticker-offset: 0px;
}

.mono {
  font-family: var(--f-mono);
  font-size: 11px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--c-text-muted);
}

a { color: inherit; text-decoration: none; }

/* ══════════════════════════════════════════════
   NAV
══════════════════════════════════════════════ */
#nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  opacity: 0;
  transform: translateY(-8px);
  transition: opacity 0.5s var(--ease-out), transform 0.5s var(--ease-out);
  pointer-events: none;
}

#nav.visible {
  opacity: 1;
  transform: translateY(0);
  pointer-events: auto;
}

.nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 18px 40px;
  background: rgba(3, 5, 13, 0.88);
  backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--c-border);
}

.nav-logo {
  font-family: var(--f-mono);
  font-size: 13px;
  font-weight: 500;
  letter-spacing: 0.2em;
  color: var(--c-blue);
  transition: opacity 0.2s;
}

.nav-logo:hover { opacity: 0.7; }

.nav-links { display: flex; gap: 36px; }

.nav-link {
  font-family: var(--f-mono);
  font-size: 10px;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--c-text-sub);
  transition: color 0.2s;
}

.nav-link:hover { color: var(--c-text); }
.nav-link.active { color: var(--c-blue); }

/* ══════════════════════════════════════════════
   HAMBURGER MENU
══════════════════════════════════════════════ */
.nav-hamburger {
  display: none;           /* hidden on desktop */
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 5px;
  width: 36px;
  height: 36px;
  background: transparent;
  border: 1px solid var(--c-border);
  cursor: pointer;
  padding: 0;
  flex-shrink: 0;
}

.nav-hamburger .bar {
  display: block;
  width: 18px;
  height: 1px;
  background: var(--c-text-sub);
  transition: transform 0.35s var(--ease-out), opacity 0.25s ease, width 0.3s var(--ease-out);
  transform-origin: center;
}

/* Animate bars into an X when open */
.nav-hamburger.open .bar:nth-child(1) {
  transform: translateY(6px) rotate(45deg);
  background: var(--c-blue);
}
.nav-hamburger.open .bar:nth-child(2) {
  opacity: 0;
  width: 0;
}
.nav-hamburger.open .bar:nth-child(3) {
  transform: translateY(-6px) rotate(-45deg);
  background: var(--c-blue);
}

/* Mobile dropdown panel */
.nav-mobile-panel {
  display: none;           /* hidden on desktop */
  flex-direction: column;
  background: rgba(3, 5, 13, 0.97);
  backdrop-filter: blur(16px);
  border-top: 1px solid var(--c-border);
  overflow: hidden;
  max-height: 0;
  transition: max-height 0.4s var(--ease-out);
}

.nav-mobile-panel.open {
  max-height: 400px;       /* large enough to never clip */
}

.nav-mobile-link {
  font-family: var(--f-mono);
  font-size: 11px;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--c-text-sub);
  padding: 18px 24px;
  border-bottom: 1px solid var(--c-border);
  transition: color 0.2s, background 0.2s, padding-left 0.2s var(--ease-out);
}

.nav-mobile-link:last-child {
  border-bottom: none;
}

.nav-mobile-link:hover,
.nav-mobile-link.active {
  color: var(--c-blue);
  padding-left: 32px;       /* subtle slide-in on hover */
  background: rgba(59, 130, 246, 0.04);
}

/* Show hamburger + panel only on mobile */
@media (max-width: 768px) {
  .nav-links {
    display: none;
  }
  .nav-hamburger {
    display: flex;
    margin-right: 8px;
  }
  .nav-mobile-panel {
    display: flex;
  }

  .nav-inner {
    padding-right: 88px;
  }

  /* Keep ticker toggle clear of the mobile hamburger */
  .ticker-toggle {
    right: 88px;
  }
}

/* ══════════════════════════════════════════════
   SHARED SECTION HELPERS
══════════════════════════════════════════════ */
section { position: relative; }

.section-inner {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: var(--section-pad);
}

.section-label {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 48px;
}

.label-num { color: var(--c-blue); font-size: 10px; }
.label-text {
  font-size: 10px;
  color: var(--c-text-muted);
  border-left: 1px solid var(--c-border);
  padding-left: 14px;
}

.section-heading {
  font-family: var(--f-display);
  font-size: clamp(36px, 5vw, 64px);
  letter-spacing: 0.02em;
  line-height: 1.0;
  color: var(--c-white);
}

.section-heading em { font-style: normal; color: var(--c-blue); }

/* ══════════════════════════════════════════════
   01 — HERO
══════════════════════════════════════════════ */
#hero {
  height: 100vh;
  min-height: 600px;
  padding-top: var(--ticker-offset);
  box-sizing: border-box;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--c-void);
  overflow: hidden;
}

#starfield {
  position: absolute;
  inset: 0;
  width: 100%; height: 100%;
  pointer-events: none;
}

#hero-model-container {
  position: absolute;
  inset: 0;
  pointer-events: none;
  opacity: 0.25;
  z-index: 0;
}

#hero-model-container canvas {
  width: 100% !important;
  height: 100% !important;
}

.hud-corner {
  position: absolute;
  width: 32px; height: 32px;
  border-color: rgba(59, 130, 246, 0.3);
  border-style: solid;
  pointer-events: none;
}
.hud-tl { top: 24px; left: 24px; border-width: 1px 0 0 1px; }
.hud-tr { top: 24px; right: 24px; border-width: 1px 1px 0 0; }
.hud-bl { bottom: 24px; left: 24px; border-width: 0 0 1px 1px; }
.hud-br { bottom: 24px; right: 24px; border-width: 0 1px 1px 0; }

body:not(.ticker-collapsed) .hud-tl,
body:not(.ticker-collapsed) .hud-tr {
  top: calc(24px + var(--ticker-offset));
}

.hero-coords {
  position: absolute;
  bottom: 28px;
  left: 50%;
  transform: translateX(-50%);
  color: rgba(59, 130, 246, 0.35);
  font-size: 10px;
  letter-spacing: 0.2em;
  white-space: nowrap;
}

.hero-content {
  position: relative;
  z-index: 1;
  text-align: center;
  padding: 0 24px;
}

.hero-label {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 28px;
  padding: 6px 16px;
  border: 1px solid rgba(59, 130, 246, 0.22);
  border-radius: 2px;
  background: rgba(59, 130, 246, 0.06);
}

.label-dot {
  width: 5px; height: 5px;
  border-radius: 50%;
  background: var(--c-blue);
  animation: pulse-dot 2s ease-in-out infinite;
}

@keyframes pulse-dot {
  0%, 100% { opacity: 1; }
  50%       { opacity: 0.25; }
}

.hero-name {
  font-family: var(--f-display);
  font-size: clamp(80px, 16vw, 200px);
  line-height: 0.88;
  letter-spacing: -0.01em;
  color: var(--c-white);
  display: flex;
  flex-direction: column;
  align-items: center;
  margin-bottom: 24px;
}

.hero-name .line { display: block; }

.hero-sub {
  font-size: 11px;
  letter-spacing: 0.2em;
  color: var(--c-text-muted);
  margin-bottom: 48px;
}

.hero-cta {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
  flex-wrap: wrap;
}

.btn-primary {
  display: inline-flex;
  align-items: center;
  padding: 14px 36px;
  background: var(--c-blue);
  color: white;
  font-family: var(--f-mono);
  font-size: 11px;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  border: 1px solid var(--c-blue);
  transition: background 0.25s, transform 0.2s;
}

.btn-primary:hover {
  background: var(--c-blue-light);
  transform: translateY(-2px);
}

.btn-ghost {
  display: inline-flex;
  align-items: center;
  padding: 14px 36px;
  background: transparent;
  color: var(--c-text-sub);
  font-family: var(--f-mono);
  font-size: 11px;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  border: 1px solid rgba(255, 255, 255, 0.1);
  transition: border-color 0.25s, color 0.25s, transform 0.2s;
}

.btn-ghost:hover {
  border-color: rgba(255, 255, 255, 0.28);
  color: var(--c-text);
  transform: translateY(-2px);
}

.scroll-indicator {
  position: absolute;
  right: 28px;
  bottom: 32px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
}

.scroll-indicator .mono { color: rgba(59, 130, 246, 0.4); }

.scroll-line {
  width: 1px;
  height: 48px;
  background: linear-gradient(to bottom, rgba(59, 130, 246, 0.4), transparent);
  animation: scroll-drop 2s ease-in-out infinite;
}

@keyframes scroll-drop {
  0%   { clip-path: inset(0 0 100% 0); }
  50%  { clip-path: inset(0 0 0% 0); }
  100% { clip-path: inset(100% 0 0% 0); }
}

/* ══════════════════════════════════════════════
   02 — ABOUT
══════════════════════════════════════════════ */
#about {
  background: var(--c-deep);
  border-top: 1px solid var(--c-border);
}

.about-grid {
  display: grid;
  grid-template-columns: 1fr 1.4fr;
  gap: 80px;
  align-items: start;
}

.about-left .section-heading { position: sticky; top: 100px; }

.about-bio {
  font-size: 16px;
  color: var(--c-text-sub);
  margin-bottom: 20px;
  line-height: 1.75;
}

.stats-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0;
  margin: 48px 0 36px;
  border: 1px solid var(--c-border);
}

.stat {
  flex: 1;
  padding: 24px 20px;
  border-right: 1px solid var(--c-border);
  text-align: center;
}

.stat:last-child { border-right: none; }

.stat-num {
  display: block;
  font-family: var(--f-display);
  font-size: 48px;
  line-height: 1;
  color: var(--c-white);
  margin-bottom: 8px;
}

.stat-label { font-size: 9px; color: var(--c-text-muted); letter-spacing: 0.15em; }

.skill-tags { display: flex; flex-wrap: wrap; gap: 8px; }

.skill-tag {
  padding: 6px 14px;
  border: 1px solid var(--c-border);
  font-family: var(--f-mono);
  font-size: 10px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--c-text-muted);
  background: rgba(59, 130, 246, 0.03);
  transition: border-color 0.2s, color 0.2s;
}

.skill-tag:hover {
  border-color: rgba(59, 130, 246, 0.4);
  color: var(--c-blue-light);
}

/* ══════════════════════════════════════════════
   03 — PROJECTS
══════════════════════════════════════════════ */
#projects {
  background: var(--c-midnight);
  border-top: 1px solid var(--c-border);
}

#projects .section-heading { margin-bottom: 56px; }

.projects-grid { display: flex; flex-direction: column; gap: 2px; }

.project-card {
  position: relative;
  background: var(--c-surface);
  border: 1px solid var(--c-border-sub);
  display: grid;
  grid-template-columns: 80px 1fr;
  overflow: hidden;
  transition: border-color 0.3s, transform 0.3s var(--ease-out);
}

.project-card:hover {
  border-color: rgba(59, 130, 246, 0.3);
  transform: translateX(4px);
}

/* ── TAP FEEDBACK (touch devices) ── */
.project-card:active {
  border-color: rgba(59, 130, 246, 0.3);
  transform: translateX(4px);
}

.project-card:active .project-accent-line {
  opacity: 1;
}

/* Held state — set by JS for 300ms after touchend */
.project-card.tapped {
  border-color: rgba(59, 130, 246, 0.3);
  transform: translateX(4px);
}

.project-card.tapped .project-accent-line {
  opacity: 1;
}

.project-accent-line {
  position: absolute;
  left: 0; top: 0; bottom: 0;
  width: 2px;
  background: var(--c-blue);
  opacity: 0;
  transition: opacity 0.3s;
}

.project-card:hover .project-accent-line,
.project-featured .project-accent-line { opacity: 1; }

.project-number {
  padding: 32px 20px;
  color: var(--c-blue);
  font-family: var(--f-mono);
  font-size: 11px;
  border-right: 1px solid var(--c-border-sub);
  display: flex;
  align-items: flex-start;
  justify-content: center;
  writing-mode: horizontal-tb;
}

.project-body { padding: 32px 40px; }

.project-tags { display: flex; gap: 8px; margin-bottom: 14px; flex-wrap: wrap; }

.ptag {
  font-family: var(--f-mono);
  font-size: 9px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  padding: 3px 10px;
  background: var(--c-blue-dim);
  color: var(--c-blue-light);
  border: 1px solid rgba(59, 130, 246, 0.2);
}

.project-title {
  font-family: var(--f-display);
  font-size: 32px;
  letter-spacing: 0.02em;
  color: var(--c-white);
  margin-bottom: 14px;
  line-height: 1;
}

.project-desc {
  font-size: 15px;
  color: var(--c-text-sub);
  line-height: 1.7;
  margin-bottom: 20px;
  max-width: 640px;
}

.project-meta { color: rgba(148, 163, 184, 0.45); font-size: 10px; }

.projects-note { margin-top: 32px; color: var(--c-text-muted); font-size: 10px; }

/* ══════════════════════════════════════════════
   04 — EXPERIENCE
══════════════════════════════════════════════ */
#experience {
  background: var(--c-deep);
  border-top: 1px solid var(--c-border);
}

#experience .section-heading { margin-bottom: 64px; }

.timeline { max-width: 700px; }

.tl-entry {
  display: grid;
  grid-template-columns: 40px 1fr;
  gap: 0 32px;
  padding-bottom: 56px;
}

.tl-entry:last-child { padding-bottom: 0; }

.tl-left {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding-top: 4px;
}

.tl-dot {
  width: 10px; height: 10px;
  border-radius: 50%;
  background: var(--c-blue);
  border: 2px solid var(--c-deep);
  box-shadow: 0 0 0 1px var(--c-blue);
  flex-shrink: 0;
}

.tl-dot--ghost {
  background: transparent;
  border-color: rgba(255, 255, 255, 0.1);
  box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.07);
}

.tl-line {
  flex: 1;
  width: 1px;
  background: linear-gradient(to bottom, rgba(59, 130, 246, 0.3), transparent);
  margin-top: 8px;
}

.tl-year {
  color: var(--c-blue);
  font-size: 10px;
  letter-spacing: 0.15em;
  margin-bottom: 8px;
}

.tl-title {
  font-family: var(--f-display);
  font-size: 28px;
  letter-spacing: 0.02em;
  color: var(--c-white);
  margin-bottom: 4px;
  line-height: 1;
}

.tl-org { font-size: 13px; color: var(--c-text-muted); margin-bottom: 14px; }

.tl-desc {
  font-size: 15px;
  color: var(--c-text-sub);
  line-height: 1.7;
  margin-bottom: 16px;
}

.tl-skills { display: flex; flex-wrap: wrap; gap: 8px; }

.tl-skill {
  font-family: var(--f-mono);
  font-size: 9px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  padding: 4px 10px;
  border: 1px solid var(--c-border);
  color: var(--c-text-muted);
}

/* ══════════════════════════════════════════════
   05 — ACHIEVEMENTS
══════════════════════════════════════════════ */
#achievements {
  background: var(--c-midnight);
  border-top: 1px solid var(--c-border);
}

#achievements .section-heading { margin-bottom: 56px; }

.achievements-list { display: flex; flex-direction: column; gap: 2px; }

.achievement-card {
  position: relative;
  display: grid;
  grid-template-columns: 80px 1fr;
  background: var(--c-surface);
  border: 1px solid var(--c-border-sub);
  overflow: hidden;
  transition: border-color 0.3s, transform 0.3s var(--ease-out);
}

.achievement-card:hover {
  border-color: rgba(245, 158, 11, 0.28);
  transform: translateX(4px);
}

.achievement-card:active {
  border-color: rgba(245, 158, 11, 0.28);
  transform: translateX(4px);
}

.achievement-card:active .ach-accent {
  opacity: 1;
}

.achievement-card.tapped {
  border-color: rgba(245, 158, 11, 0.28);
  transform: translateX(4px);
}

.achievement-card.tapped .ach-accent {
  opacity: 1;
}

.ach-accent {
  position: absolute;
  left: 0; top: 0; bottom: 0;
  width: 2px;
  background: var(--c-amber);
  opacity: 0;
  transition: opacity 0.3s;
}

.achievement-card:hover .ach-accent { opacity: 1; }

.ach-index {
  padding: 32px 20px;
  color: var(--c-amber);
  font-family: var(--f-mono);
  font-size: 11px;
  border-right: 1px solid var(--c-border-sub);
  display: flex;
  align-items: flex-start;
  justify-content: center;
}

.ach-body { padding: 32px 40px; }

.ach-org {
  color: var(--c-amber);
  font-family: var(--f-mono);
  font-size: 9px;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  margin-bottom: 10px;
  opacity: 0.65;
}

.ach-title {
  font-family: var(--f-display);
  font-size: 28px;
  letter-spacing: 0.02em;
  color: var(--c-white);
  margin-bottom: 12px;
  line-height: 1;
}

.ach-desc {
  font-size: 15px;
  color: var(--c-text-sub);
  line-height: 1.7;
  max-width: 580px;
}

/* ══════════════════════════════════════════════
   06 — CONTACT
══════════════════════════════════════════════ */
#contact {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  background: var(--c-void);
  border-top: 1px solid var(--c-border);
  overflow: hidden;
}

#contact-starfield {
  position: absolute;
  inset: 0;
  width: 100%; height: 100%;
  pointer-events: none;
}

.contact-inner {
  position: relative;
  z-index: 1;
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.contact-heading {
  font-family: var(--f-display);
  font-size: clamp(72px, 12vw, 160px);
  letter-spacing: 0.01em;
  line-height: 0.9;
  color: var(--c-white);
  margin-bottom: 40px;
}

.contact-sub {
  font-size: 17px;
  color: var(--c-text-sub);
  max-width: 500px;
  line-height: 1.7;
  margin-bottom: 56px;
}

.contact-links {
  display: flex;
  flex-direction: column;
  gap: 2px;
  max-width: 560px;
  width: 100%;
}

.contact-btn {
  display: flex;
  align-items: center;
  gap: 24px;
  padding: 24px 32px;
  background: var(--c-surface);
  border: 1px solid var(--c-border-sub);
  transition: border-color 0.25s, transform 0.25s var(--ease-out), background 0.25s;
}

.contact-btn:hover {
  border-color: rgba(59, 130, 246, 0.35);
  background: rgba(59, 130, 246, 0.06);
  transform: translateX(6px);
}

.contact-btn:active,
.contact-btn.tapped {
  border-color: rgba(59, 130, 246, 0.35);
  background: rgba(59, 130, 246, 0.06);
  transform: translateX(6px);
}

.contact-btn-label {
  color: var(--c-blue);
  font-size: 10px;
  min-width: 72px;
}

.contact-btn-value {
  font-size: 15px;
  color: var(--c-text-sub);
  transition: color 0.2s;
}

.contact-btn:hover .contact-btn-value { color: var(--c-text); }

footer {
  position: relative;
  z-index: 1;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 24px 60px;
  border-top: 1px solid var(--c-border);
  background: rgba(3, 5, 13, 0.5);
}

footer .mono { color: var(--c-text-muted); font-size: 10px; }
footer a { color: var(--c-text-muted); transition: color 0.2s; }
footer a:hover { color: var(--c-text); }

/* ══════════════════════════════════════════════
   SCROLL REVEAL
══════════════════════════════════════════════ */
.reveal {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.65s var(--ease-out), transform 0.65s var(--ease-out);
}

.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

/* stagger siblings */
.reveal:nth-child(2) { transition-delay: 0.1s; }
.reveal:nth-child(3) { transition-delay: 0.2s; }

/* ══════════════════════════════════════════════
   HERO TEXT REVEAL
══════════════════════════════════════════════ */
/* ── HERO DECRYPT ── */
.hero-char {
  display: inline-block;
  opacity: 0;
  color: var(--c-blue);
}

.hero-char--active {
  opacity: 1;
  color: var(--c-blue-light);   /* scrambling — glowing blue */
}

.hero-char--resolved {
  color: var(--c-white);        /* final — snaps to white */
  transition: color 0.12s ease;
}

.hero-fade-up {
  animation: heroFadeUp 0.7s var(--ease-out) both;
}
@keyframes heroFadeUp {
  from { opacity: 0; transform: translateY(14px); }
  to   { opacity: 1; transform: translateY(0); }
}

.hero-fade-up-centred {
  opacity: 0;
  animation: heroFadeUpCentred 0.7s var(--ease-out) forwards;
}
@keyframes heroFadeUpCentred {
  from { opacity: 0; transform: translateX(-50%) translateY(14px); }
  to   { opacity: 1; transform: translateX(-50%) translateY(0); }
}

/* ══════════════════════════════════════════════
   CUSTOM CURSOR
══════════════════════════════════════════════ */
.custom-cursor-active,
.custom-cursor-active * {
  cursor: none !important;
}

#cursor-dot {
  position: fixed;
  top: 0; left: 0;
  width: 5px; height: 5px;
  background: var(--c-blue);
  border-radius: 50%;
  pointer-events: none;
  z-index: 9999;
  margin-left: -2.5px;
  margin-top: -2.5px;
  transition: width 0.2s, height 0.2s, margin 0.2s, background 0.2s;
  will-change: transform;
}

#cursor-ring {
  position: fixed;
  top: 0; left: 0;
  width: 28px; height: 28px;
  border: 1px solid rgba(59, 130, 246, 0.5);
  border-radius: 50%;
  pointer-events: none;
  z-index: 9998;
  margin-left: -14px;
  margin-top: -14px;
  transition: width 0.25s var(--ease-out), height 0.25s var(--ease-out),
              margin 0.25s var(--ease-out), border-color 0.25s;
  will-change: transform;
}

#cursor-dot.cursor--hover {
  width: 8px; height: 8px;
  margin-left: -4px; margin-top: -4px;
  background: var(--c-blue-light);
}

#cursor-ring.cursor--hover {
  width: 44px; height: 44px;
  margin-left: -22px; margin-top: -22px;
  border-color: rgba(96, 165, 250, 0.6);
}

/* ══════════════════════════════════════════════
    TIMELINE DRAW
══════════════════════════════════════════════ */
.tl-draw-line {
  position: absolute;
  left: 19.5px;           /* aligns with the centre of the dot column */
  top: 12px;
  width: 1px;
  height: 0%;           /* JS animates this to 0–100% */
  background: linear-gradient(
    to bottom,
    var(--c-blue) 0%,
    rgba(59, 130, 246, 0.2) 100%
  );
  transition: height 0.1s linear;
  pointer-events: none;
  z-index: 0;
}

/* Make the timeline container relative so the line positions correctly */
#experience .timeline {
  position: relative;
}

/* ══════════════════════════════════════════════
   NEWS TICKER
══════════════════════════════════════════════ */
#news-ticker {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 102;
  height: 34px;
  display: flex;
  align-items: center;
  background: rgba(3, 5, 13, 0.96);
  border-bottom: 1px solid var(--c-border);
  backdrop-filter: blur(12px);
  overflow: hidden;
}

.ticker-label {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 0 16px;
  height: 100%;
  border-right: 1px solid var(--c-border);
  flex-shrink: 0;
  background: rgba(59, 130, 246, 0.06);
}

.ticker-dot {
  width: 5px; height: 5px;
  border-radius: 50%;
  background: var(--c-blue);
  flex-shrink: 0;
  animation: pulse-dot 2s ease-in-out infinite;
}

.ticker-window {
  flex: 1;
  overflow: hidden;
  height: 100%;
  display: flex;
  align-items: center;
}

.ticker-track {
  display: flex;
  align-items: center;
  white-space: nowrap;
  will-change: transform;
}

.ticker-track.running {
  animation: ticker-scroll var(--ticker-duration, 60s) linear infinite;
}

@keyframes ticker-scroll {
  0%   { transform: translateX(0); }
  100% { transform: translateX(-50%); }
}

.ticker-copy {
  display: inline-flex;
  align-items: center;
  padding-right: 48px;
}

.ticker-headline {
  font-family: var(--f-mono);
  font-size: 10px;
  letter-spacing: 0.07em;
  color: var(--c-text-sub);
  white-space: nowrap;
}

.ticker-headline a {
  color: inherit;
  text-decoration: none;
  transition: color 0.2s;
}

.ticker-headline a:hover { color: var(--c-text); }

.ticker-sep {
  font-family: var(--f-mono);
  font-size: 10px;
  color: rgba(59, 130, 246, 0.35);
  margin: 0 20px;
  flex-shrink: 0;
}

.ticker-toggle {
  position: fixed;
  right: 0;
  z-index: 103;
  width: 28px;
  height: 16px;
  border: none;
  border-left: 1px solid var(--c-border);
  border-bottom: 1px solid var(--c-border);
  background: rgba(3, 5, 13, 0.96);
  color: var(--c-text-muted);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--f-mono);
  font-size: 7px;
  transition: color 0.2s, background 0.2s, top 0.4s var(--ease-out);
}

.ticker-toggle:hover {
  background: rgba(59, 130, 246, 0.08);
  color: var(--c-blue-light);
}

/* .ticker-toggle-icon {
  display: inline-block;
  transition: transform 0.4s var(--ease-out);
}

#news-ticker.collapsed .ticker-toggle-icon {
  transform: rotate(180deg);
} */

.ticker-chevron {
  display: inline-block;
  width: 8px;
  height: 8px;
  border-right: 1.5px solid var(--c-text-muted);
  border-bottom: 1.5px solid var(--c-text-muted);
  transform: rotate(225deg) translateY(-2px);
  transition: transform 0.4s var(--ease-out), border-color 0.2s;
}

.ticker-toggle:hover .ticker-chevron {
  border-color: var(--c-blue-light);
}

#ticker-toggle.ticker-collapsed .ticker-chevron {
  transform: rotate(45deg) translateY(-2px);
}

#news-ticker {
  transition: transform 0.4s var(--ease-out);
}

#news-ticker.collapsed {
  transform: translateY(-100%);
}

/* Push nav below ticker */
#nav { top: var(--ticker-offset); }

.ticker-toggle {
  top: var(--ticker-offset);
}

/* ══════════════════════════════════════════════
   RESPONSIVE
══════════════════════════════════════════════ */
@media (max-width: 900px) {
  :root { --section-pad: 80px 28px; }

  .about-grid { grid-template-columns: 1fr; gap: 40px; }
  .about-left .section-heading { position: static; }

  .stat {
    flex: 0 0 50%;   /* exactly 2 per row */
    border-right: 1px solid var(--c-border);
    box-sizing: border-box;
    }
    .stat:nth-child(2n) { border-right: none; }
    .stat:nth-child(1),
    .stat:nth-child(2) { border-bottom: 1px solid var(--c-border); }

  .project-card, .achievement-card { grid-template-columns: 1fr; }
  .project-number, .ach-index { display: none; }
  .project-body, .ach-body { padding: 28px 24px; }

  .tl-entry { grid-template-columns: 28px 1fr; gap: 0 20px; }

  .contact-heading { font-size: clamp(56px, 18vw, 110px); }

  footer { flex-direction: column; gap: 12px; padding: 24px 28px; text-align: center; }

  .nav-links { gap: 18px; }
  .nav-inner { padding: 16px 24px; }

  .tl-draw-line { left: 13.5px; }
}

@media (max-width: 600px) {
  .hero-cta { flex-direction: column; gap: 12px; }
  .hero-cta a { width: 100%; justify-content: center; }
  .hud-corner { display: none; }
  .stats-row { flex-direction: column; }
  .stat {
    flex: 0 0 100%;
    border-right: none;
    border-bottom: 1px solid var(--c-border);
  }
  .stat:last-child { border-bottom: none; }
  .stat:nth-child(2n) { border-right: none; }
  .stat:last-child { border-bottom: none; }
}
