:root{
    --ink:#10131a;
    --ink-soft:#4b5162;
    --ink-faint:#8a90a2;
    --paper:#f5f6fa;
    --surface:#ffffff;
    --surface-dim:#eceef4;
    --line:#dde1ea;
    --line-strong:#c7cddb;
    --dark:#0f1420;
    --dark-2:#151b2c;
    --dark-text:#d9deea;
    --dark-text-dim:#818ba3;
    --amber:#c9861f;
    --amber-bright:#e8a33d;
    --teal:#0f6b64;
    --teal-bright:#17968c;
    --rose:#b8492f;

    --font-display:'Space Grotesk', sans-serif;
    --font-body:'Inter', sans-serif;
    --font-mono:'JetBrains Mono', monospace;
    --maxw:1180px;
    --ease:cubic-bezier(.16,.84,.44,1);
    --nav-h:72px;
    color-scheme: light;
    --navbar-bg: rgba(245,246,250,0.85);
  }
  :root[data-theme="dark"]{
    color-scheme: dark;
    --ink:#eef0f5;
    --ink-soft:#b7bdcf;
    --ink-faint:#7d84a0;
    --paper:#0b0e16;
    --surface:#131826;
    --surface-dim:#1b2133;
    --line:#262d40;
    --line-strong:#333b54;
    --amber:#e8a33d;
    --amber-bright:#f0b559;
    --teal:#2ec4b6;
    --teal-bright:#2ec4b6;
    --navbar-bg: rgba(11,14,22,0.85);
  }
  @media (prefers-reduced-motion: reduce){
    *{ animation-duration:0.01ms !important; animation-iteration-count:1 !important; transition-duration:0.01ms !important; scroll-behavior:auto !important; }
  }
  *{ box-sizing:border-box; }
  html{ scroll-behavior:smooth; }
  body{
    margin:0; color:var(--ink); font-family:var(--font-body); font-size:16px; line-height:1.6; -webkit-font-smoothing:antialiased;
    background:
      radial-gradient(1100px 480px at 12% -8%, rgba(232,163,61,0.10), transparent 60%),
      radial-gradient(900px 420px at 108% 6%, rgba(23,150,140,0.09), transparent 55%),
      var(--paper);
  }
  img{ max-width:100%; display:block; }
  a{ color:inherit; }
  ::selection{ background:var(--amber-bright); color:var(--dark); }
  ::-webkit-scrollbar{ width:10px; height:10px; }
  ::-webkit-scrollbar-track{ background:var(--paper); }
  ::-webkit-scrollbar-thumb{ background:var(--line-strong); border-radius:6px; }

  .skip-link{ position:absolute; left:-999px; top:0; background:var(--dark); color:#fff; padding:12px 18px; z-index:999; font-family:var(--font-mono); font-size:13px; border-radius:0 0 8px 0; }
  .skip-link:focus{ left:0; }
  a:focus-visible, button:focus-visible, summary:focus-visible, input:focus-visible, textarea:focus-visible{ outline:2px solid var(--teal-bright); outline-offset:3px; border-radius:2px; }

  h1,h2,h3,h4{ font-family:var(--font-display); margin:0; letter-spacing:-0.01em; }
  .eyebrow{ font-family:var(--font-mono); font-size:12.5px; color:var(--ink-faint); display:flex; align-items:center; gap:8px; margin-bottom:14px; }
  .eyebrow::before{ content:''; width:7px; height:7px; border-radius:50%; background:var(--amber-bright); box-shadow:0 0 0 3px rgba(232,163,61,0.18); }

  .section{ padding:64px 56px; max-width:var(--maxw); margin:0 auto; scroll-margin-top:calc(var(--nav-h) + 16px); }
  .section-head{ margin-bottom:32px; max-width:640px; }
  .section-title{ font-size:clamp(28px,3.4vw,38px); font-weight:600; }
  .section-sub{ color:var(--ink-soft); margin-top:12px; font-size:16px; max-width:560px; }
  @media (max-width:760px){ .section{ padding:48px 22px; } }

  .reveal{ opacity:0; transform:translateY(18px); transition:opacity 0.7s var(--ease), transform 0.7s var(--ease); }
  .reveal.in-view{ opacity:1; transform:translateY(0); }
  .stagger > *{ transition-delay:calc(var(--i,0) * 70ms); }

  /* ---------- Top navbar ---------- */
  .navbar{
    position:sticky; top:0; z-index:80; height:var(--nav-h);
    display:flex; align-items:center; justify-content:space-between;
    padding:0 40px; background:var(--navbar-bg); backdrop-filter:blur(10px);
    border-bottom:1px solid var(--line);
  }
  .brand{ display:flex; align-items:center; gap:9px; font-family:var(--font-display); font-weight:700; font-size:17px; text-decoration:none; color:var(--ink); }
  .brand-dot{ width:9px; height:9px; border-radius:50%; background:var(--amber-bright); box-shadow:0 0 0 3px rgba(232,163,61,0.2); }
  .nav-links{ display:flex; align-items:center; gap:6px; list-style:none; margin:0; padding:0; }
  .nav-links a{ text-decoration:none; color:var(--ink-soft); font-size:14.5px; font-weight:500; padding:9px 14px; border-radius:7px; position:relative; transition:color .2s; }
  .nav-links a:hover{ color:var(--ink); }
  .nav-links a.active{ color:var(--ink); }
  .nav-links a.active::after{ content:''; position:absolute; left:14px; right:14px; bottom:3px; height:2px; background:var(--amber-bright); border-radius:2px; }
  .nav-cta{ display:flex; align-items:center; gap:14px; }
  .avail-pill{ display:flex; align-items:center; gap:7px; font-family:var(--font-mono); font-size:12px; color:var(--teal); background:rgba(15,107,100,0.08); border:1px solid rgba(15,107,100,0.2); padding:6px 12px; border-radius:20px; }
  .avail-dot{ width:6px; height:6px; border-radius:50%; background:var(--teal-bright); animation:pulse 2.4s ease-in-out infinite; }
  @keyframes pulse{ 0%,100%{ opacity:1; } 50%{ opacity:0.3; } }
  .menu-btn{ display:none; background:none; border:1px solid var(--line-strong); border-radius:7px; padding:8px 12px; cursor:pointer; font-size:15px; }
  @media (max-width:940px){
    .nav-links{ display:none; }
    .avail-pill{ display:none; }
    .menu-btn{ display:inline-flex; }
    .navbar{ padding:0 20px; }
  }
  .mobile-drawer{ display:none; position:fixed; top:var(--nav-h); left:0; right:0; background:var(--surface); border-bottom:1px solid var(--line); z-index:79; padding:10px 20px 20px; box-shadow:0 20px 40px -20px rgba(0,0,0,0.2); }
  .mobile-drawer.open{ display:block; }
  .mobile-drawer a{ display:block; padding:12px 4px; text-decoration:none; color:var(--ink); font-weight:500; border-bottom:1px solid var(--line); font-size:15px; }
  .mobile-drawer a:last-child{ border-bottom:none; }

  /* ---------- Hero ---------- */
  .hero{ padding:72px 56px 48px; max-width:var(--maxw); margin:0 auto; display:grid; grid-template-columns:0.62fr 0.38fr; gap:56px; align-items:center; }
  @media (max-width:900px){ .hero{ grid-template-columns:1fr; padding:52px 22px 48px; text-align:center; } .hero-ctas, .hero-socials, .hero-stats{ justify-content:center; } }
  .hero-kicker{ font-family:var(--font-mono); font-size:13px; color:var(--teal); display:flex; align-items:center; gap:8px; margin-bottom:18px; }
  @media (max-width:900px){ .hero-kicker{ justify-content:center; } }
  .hero-kicker .bar{ width:22px; height:2px; background:var(--teal); }
  .hero h1{ font-size:clamp(30px,4vw,46px); font-weight:700; line-height:1.08; }
  .hero h1 .accent{ color:var(--amber); }
  .hero-role{ font-family:var(--font-mono); font-size:16.5px; color:var(--ink-soft); margin-top:16px; }
  .hero-desc{ margin-top:18px; color:var(--ink-soft); font-size:16.5px; max-width:480px; }
  @media (max-width:900px){ .hero-desc{ margin-left:auto; margin-right:auto; } }
  .hero-ctas{ display:flex; gap:14px; margin-top:30px; flex-wrap:wrap; }
  .btn{ font-family:var(--font-mono); font-size:13.5px; padding:13px 22px; border-radius:8px; text-decoration:none; display:inline-flex; align-items:center; gap:8px; cursor:pointer; border:1px solid transparent; transition:transform .18s var(--ease), box-shadow .18s var(--ease), background .18s; }
  .btn-primary{ background:linear-gradient(135deg, #10131a, #262d40); color:#fff; }
  .btn-primary:hover{ transform:translateY(-2px); box-shadow:0 12px 26px -6px rgba(16,19,26,0.35), 0 0 0 1px rgba(232,163,61,0.25); }
  .btn-ghost{ border-color:var(--line-strong); color:var(--ink); background:var(--surface); }
  .btn-ghost:hover{ transform:translateY(-2px); border-color:var(--ink); }
  .hero-socials{ display:flex; gap:16px; margin-top:26px; }
  .hero-socials a{ width:40px; height:40px; border-radius:50%; border:1px solid var(--line-strong); display:flex; align-items:center; justify-content:center; text-decoration:none; color:var(--ink-soft); transition:all .18s; }
  .hero-socials a:hover{ border-color:var(--ink); color:var(--ink); transform:translateY(-2px); }

  /* ---------- Hero photo (animated) ---------- */
  .hero-photo-wrap{ position:relative; width:320px; height:320px; margin:0 auto; display:grid; place-items:center; animation:photoIn .9s var(--ease) both; }
  .hero-photo-glow{ position:absolute; inset:-36px; border-radius:50%; background:radial-gradient(circle, rgba(232,163,61,0.30), rgba(23,150,140,0.22) 45%, transparent 70%); filter:blur(18px); animation:glow 6s ease-in-out infinite; pointer-events:none; }
  .hero-photo-ring{ position:absolute; inset:4px; border-radius:50%; background:conic-gradient(from 0deg, var(--amber-bright), transparent 28%, var(--teal-bright) 52%, transparent 78%, var(--amber-bright)); -webkit-mask:radial-gradient(farthest-side, transparent calc(100% - 3px), #000 calc(100% - 2px)); mask:radial-gradient(farthest-side, transparent calc(100% - 3px), #000 calc(100% - 2px)); animation:spin 7s linear infinite; }
  .hero-orbit{ position:absolute; inset:-10px; border-radius:50%; border:1px dashed var(--line-strong); animation:spin 28s linear infinite reverse; pointer-events:none; }
  .hero-orbit span{ position:absolute; top:50%; left:-5px; width:10px; height:10px; margin-top:-5px; border-radius:50%; background:var(--teal-bright); box-shadow:0 0 14px var(--teal-bright); }
  .hero-orbit span + span{ left:auto; right:-4px; top:20%; width:8px; height:8px; background:var(--amber-bright); box-shadow:0 0 14px var(--amber-bright); }
  @keyframes spin{ to{ transform:rotate(360deg); } }
  @keyframes float{ 0%,100%{ transform:translateY(0); } 50%{ transform:translateY(-8px); } }
  @keyframes glow{ 0%,100%{ opacity:.65; transform:scale(1); } 50%{ opacity:1; transform:scale(1.06); } }
  @keyframes photoIn{ from{ opacity:0; transform:scale(.88); } to{ opacity:1; transform:none; } }
  .hero-photo{ position:relative; width:280px; height:280px; border-radius:50%; background:linear-gradient(155deg, var(--dark), var(--dark-2)); border:5px solid var(--surface); box-shadow:0 24px 50px -16px rgba(16,19,26,0.35); display:flex; align-items:center; justify-content:center; overflow:hidden; animation:float 6s ease-in-out infinite; }
  .hero-photo img{ transition:transform .6s var(--ease); }
  .hero-photo-wrap:hover .hero-photo img{ transform:scale(1.06); }
  .hero-photo .initials{ font-family:var(--font-display); font-size:82px; font-weight:700; color:#fff; opacity:0.92; }
  .hero-badge{ position:absolute; bottom:26px; right:-14px; background:var(--surface); border:1px solid var(--line); border-radius:14px; padding:9px 13px; box-shadow:0 12px 24px -10px rgba(16,19,26,0.25); font-family:var(--font-mono); font-size:11.5px; display:flex; align-items:center; gap:7px; white-space:nowrap; animation:float 5s ease-in-out .8s infinite; }
  .hero-badge--alt{ right:auto; bottom:auto; left:-22px; top:34px; color:var(--teal); animation-delay:2.2s; }
  .hero-badge--alt b{ width:7px; height:7px; border-radius:50%; background:var(--teal-bright); animation:pulse 2.4s ease-in-out infinite; }
  @media (max-width:420px){ .hero-photo-wrap{ width:280px; height:280px; } .hero-photo{ width:244px; height:244px; } .hero-badge:not(.hero-badge--alt){ right:-6px; bottom:18px; } .hero-badge--alt{ left:-10px; top:24px; } }
  html, body{ overflow-x:clip; }

  .hero-stats{ display:flex; gap:36px; margin-top:44px; flex-wrap:wrap; padding-top:36px; border-top:1px solid var(--line); }
  .hero-stat b{ font-family:var(--font-display); font-size:30px; display:block; }
  .hero-stat span{ font-family:var(--font-mono); font-size:11.5px; color:var(--ink-faint); }

  /* ---------- About ---------- */
  .about-grid{ display:grid; grid-template-columns:1fr 1fr; gap:56px; align-items:start; }
  @media (max-width:900px){ .about-grid{ grid-template-columns:1fr; gap:32px; } }
  .about-copy p{ color:var(--ink-soft); margin:0 0 16px; }
  .about-copy p:last-child{ margin-bottom:0; }
  .about-copy strong{ color:var(--ink); font-weight:600; }
  .principles-card{ background:var(--surface); border:1px solid var(--line); border-radius:12px; padding:26px; }
  .principles{ list-style:none; margin:0; padding:0; display:flex; flex-direction:column; gap:16px; }
  .principles li{ display:flex; gap:14px; font-size:14.5px; color:var(--ink-soft); }
  .principles b{ color:var(--amber); font-family:var(--font-mono); font-size:12.5px; flex-shrink:0; padding-top:2px; }

  /* ---------- Skills ---------- */
  .skills-grid{ display:grid; grid-template-columns:repeat(3,1fr); gap:20px; }
  @media (max-width:900px){ .skills-grid{ grid-template-columns:1fr 1fr; } }
  @media (max-width:600px){ .skills-grid{ grid-template-columns:1fr; } }
  .skill-card{ background:var(--surface); border:1px solid var(--line); border-radius:12px; padding:24px; transition:border-color .2s, transform .2s, box-shadow .2s; }
  .skill-card:hover{ border-color:var(--line-strong); transform:translateY(-3px); box-shadow:0 16px 32px -22px rgba(16,19,26,0.28); }
  .skill-card h3{ font-size:14px; font-family:var(--font-mono); color:var(--teal); margin-bottom:16px; text-transform:uppercase; letter-spacing:0.04em; }
  .skill-row{ margin-bottom:13px; }
  .skill-row:last-child{ margin-bottom:0; }
  .skill-row-top{ display:flex; justify-content:space-between; font-size:13.5px; margin-bottom:6px; }
  .skill-row-top span:last-child{ color:var(--ink-faint); font-family:var(--font-mono); font-size:11.5px; }
  .bar-track{ height:5px; background:var(--surface-dim); border-radius:3px; overflow:hidden; }
  .bar-fill{ height:100%; border-radius:3px; background:linear-gradient(90deg, var(--teal-bright), var(--amber-bright)); width:0%; transition:width 1.1s var(--ease); }

  /* ---------- Stack ---------- */
  .stack-groups{ display:grid; grid-template-columns:repeat(4,1fr); gap:18px; }
  @media (max-width:900px){ .stack-groups{ grid-template-columns:1fr 1fr; } }
  @media (max-width:560px){ .stack-groups{ grid-template-columns:1fr; } }
  .stack-group{ background:var(--surface); border:1px solid var(--line); border-radius:12px; padding:22px; }
  .stack-group-title{ font-family:var(--font-mono); font-size:11px; color:var(--ink-faint); text-transform:uppercase; letter-spacing:0.08em; margin-bottom:14px; }
  .stack-items{ display:flex; flex-direction:column; gap:12px; }
  .stack-item{ display:flex; align-items:center; gap:10px; font-size:14px; color:var(--ink); }
  .stack-item i{ font-size:19px; width:20px; text-align:center; color:var(--amber); }

  /* ---------- GitHub Activity ---------- */
  .gh-activity-card{ background:var(--surface); border:1px solid var(--line); border-radius:12px; padding:28px; transition:border-color .2s, box-shadow .2s; }
  .gh-activity-card:hover{ border-color:var(--line-strong); box-shadow:0 18px 40px -24px rgba(16,19,26,0.28); }
  .gh-activity-chart{ width:100%; height:auto; }
  .gh-activity-link{ display:inline-flex; align-items:center; gap:8px; margin-top:20px; font-family:var(--font-mono); font-size:13px; color:var(--teal); text-decoration:none; transition:color .18s, transform .18s; }
  .gh-activity-link:hover{ color:var(--ink); transform:translateX(3px); }
  .gh-activity-link i{ font-size:16px; }

  /* ---------- Projects ---------- */
  .projects-list{ display:flex; flex-direction:column; gap:20px; }
  .project{ background:var(--surface); border:1px solid var(--line); border-radius:12px; overflow:hidden; transition:border-color .2s, box-shadow .2s; }
  .project:hover{ border-color:var(--line-strong); box-shadow:0 18px 40px -24px rgba(16,19,26,0.28); }
  .project-head{ padding:26px 26px 20px; display:grid; grid-template-columns:auto 1fr auto; gap:20px; align-items:start; }
  @media (max-width:700px){ .project-head{ grid-template-columns:1fr; } }
  .project-index{ font-family:var(--font-mono); font-size:12px; color:var(--ink-faint); padding-top:4px; }
  .project-title{ font-size:21px; font-weight:600; display:flex; align-items:center; gap:10px; flex-wrap:wrap; }
  .project-status{ font-family:var(--font-mono); font-size:10.5px; padding:3px 9px; border-radius:20px; background:rgba(23,150,140,0.12); color:var(--teal); border:1px solid rgba(23,150,140,0.25); }
  .project-tagline{ color:var(--ink-soft); margin-top:8px; font-size:15px; max-width:560px; }
  .project-tags{ display:flex; gap:7px; flex-wrap:wrap; margin-top:14px; }
  .tag{ font-family:var(--font-mono); font-size:11px; padding:4px 9px; border-radius:5px; background:var(--surface-dim); color:var(--ink-soft); border:1px solid var(--line); }
  .project-links{ display:flex; gap:10px; flex-shrink:0; }
  .icon-link{ width:36px; height:36px; border-radius:8px; border:1px solid var(--line); display:flex; align-items:center; justify-content:center; text-decoration:none; color:var(--ink-soft); transition:all .18s; }
  .icon-link:hover{ border-color:var(--ink); color:var(--ink); transform:translateY(-2px); }
  .project-soon{ background:var(--surface-dim); border-style:dashed; }
  .project-soon:hover{ box-shadow:none; }
  .project-soon .project-tagline{ max-width:620px; }
  .project-metrics{ display:flex; gap:28px; padding:0 26px 22px; flex-wrap:wrap; }
  .metric{ font-family:var(--font-mono); }
  .metric b{ font-size:20px; display:block; color:var(--ink); }
  .metric.up b::before{ content:'+ '; color:var(--teal); }
  .metric.down b::before{ content:'− '; color:var(--rose); }
  .metric span{ font-size:10.5px; color:var(--ink-faint); }
  details.case-study{ border-top:1px solid var(--line); }
  details.case-study summary{ list-style:none; cursor:pointer; padding:15px 26px; display:flex; align-items:center; justify-content:space-between; font-family:var(--font-mono); font-size:12.5px; color:var(--ink-soft); background:var(--surface-dim); transition:background .18s; }
  details.case-study summary::-webkit-details-marker{ display:none; }
  details.case-study summary:hover{ background:#e6e9f2; }
  details.case-study summary .chevron{ transition:transform .25s var(--ease); }
  details.case-study[open] summary .chevron{ transform:rotate(90deg); }
  .case-body{ padding:24px 26px 30px; display:grid; grid-template-columns:1fr 1fr 1fr; gap:26px; }
  @media (max-width:800px){ .case-body{ grid-template-columns:1fr; } }
  .case-col h4{ font-family:var(--font-mono); font-size:11px; text-transform:uppercase; letter-spacing:0.06em; color:var(--teal); margin-bottom:10px; }
  .case-col p, .case-col li{ font-size:13.8px; color:var(--ink-soft); }
  .case-col ul{ margin:0; padding-left:18px; display:flex; flex-direction:column; gap:6px; }

  /* ---------- Experience ---------- */
  .log{ position:relative; padding-left:30px; }
  .log::before{ content:''; position:absolute; left:6px; top:6px; bottom:6px; width:2px; background:var(--line-strong); }
  .commit{ position:relative; padding-bottom:38px; }
  .commit:last-child{ padding-bottom:0; }
  .commit::before{ content:''; position:absolute; left:-30px; top:5px; width:13px; height:13px; border-radius:50%; background:var(--surface); border:2.5px solid var(--amber); }
  .commit-meta{ display:flex; align-items:baseline; gap:12px; flex-wrap:wrap; }
  .commit-title{ font-size:18.5px; font-weight:600; font-family:var(--font-display); }
  .commit-date{ font-family:var(--font-mono); font-size:12px; color:var(--ink-faint); }
  .commit-org{ font-family:var(--font-mono); font-size:13px; color:var(--teal); margin-top:2px; }
  .commit-body{ margin-top:12px; color:var(--ink-soft); }
  .commit-body ul{ margin:10px 0 0; padding-left:20px; display:flex; flex-direction:column; gap:7px; font-size:14.5px; }
  .commit-tags{ display:flex; gap:7px; flex-wrap:wrap; margin-top:14px; }

  /* ---------- Education ---------- */
  .edu-grid{ display:grid; grid-template-columns:1fr 1fr; gap:20px; }
  @media (max-width:800px){ .edu-grid{ grid-template-columns:1fr; } }
  .edu-card{ background:var(--surface); border:1px solid var(--line); border-radius:12px; padding:24px; transition:border-color .2s, transform .2s, box-shadow .2s; }
  .edu-card:hover{ border-color:var(--line-strong); transform:translateY(-3px); box-shadow:0 16px 32px -22px rgba(16,19,26,0.28); }
  .edu-card h3{ font-size:17px; font-weight:600; }
  .edu-card .org{ font-family:var(--font-mono); font-size:13px; color:var(--teal); margin-top:4px; }
  .edu-card p{ color:var(--ink-soft); font-size:14px; margin-top:10px; }

  /* ---------- Achievements ---------- */
  .ach-grid{ display:grid; grid-template-columns:repeat(4,1fr); gap:18px; }
  @media (max-width:900px){ .ach-grid{ grid-template-columns:1fr 1fr; } }
  @media (max-width:560px){ .ach-grid{ grid-template-columns:1fr; } }
  .ach-card{ background:var(--surface); border:1px solid var(--line); border-radius:12px; padding:22px; transition:border-color .2s, transform .2s, box-shadow .2s; }
  .ach-card:hover{ border-color:var(--line-strong); transform:translateY(-3px); box-shadow:0 16px 32px -22px rgba(16,19,26,0.28); }
  .ach-card .num{ font-family:var(--font-display); font-size:30px; font-weight:700; color:var(--ink); }
  .ach-card .num .sign{ color:var(--teal); }
  .ach-card .label{ font-family:var(--font-mono); font-size:12px; color:var(--ink-soft); margin-top:8px; }
  .cert-list{ margin-top:34px; display:flex; flex-direction:column; border-top:1px solid var(--line); }
  .cert-row{ display:grid; grid-template-columns:1fr auto auto; gap:16px; padding:16px 4px; border-bottom:1px solid var(--line); align-items:center; }
  @media (max-width:700px){ .cert-row{ grid-template-columns:1fr; gap:6px; } }
  .cert-name{ font-weight:600; font-size:14.5px; }
  .cert-issuer{ font-family:var(--font-mono); font-size:12px; color:var(--ink-faint); }
  .cert-year{ font-family:var(--font-mono); font-size:12.5px; color:var(--ink-soft); }

  /* ---------- Contact ---------- */
  .contact-wrap{
    background:
      radial-gradient(700px 320px at 100% 0%, rgba(232,163,61,0.14), transparent 60%),
      radial-gradient(600px 300px at 0% 100%, rgba(23,150,140,0.14), transparent 60%),
      var(--dark);
    border-radius:20px; padding:56px; color:var(--dark-text); display:grid; grid-template-columns:1fr 1fr; gap:48px;
  }
  @media (max-width:900px){ .contact-wrap{ grid-template-columns:1fr; padding:34px 22px; } }
  .contact-wrap h2{ color:#fff; font-size:clamp(26px,3.4vw,34px); }
  .contact-wrap .section-sub{ color:var(--dark-text-dim); }
  .contact-list{ margin-top:28px; display:flex; flex-direction:column; gap:14px; }
  .contact-list a{ display:flex; align-items:center; gap:12px; text-decoration:none; color:var(--dark-text); font-family:var(--font-mono); font-size:14px; transition:color .18s, transform .18s; }
  .contact-list a:hover{ color:var(--amber-bright); transform:translateX(3px); }
  .contact-list i{ width:20px; text-align:center; color:var(--amber-bright); }
  .form-group{ margin-bottom:16px; }
  .form-group label{ display:block; font-family:var(--font-mono); font-size:11.5px; color:var(--dark-text-dim); margin-bottom:7px; text-transform:uppercase; letter-spacing:0.05em; }
  .form-group input, .form-group textarea{ width:100%; background:var(--dark-2); border:1px solid #2b3350; color:#fff; border-radius:8px; padding:12px 14px; font-family:var(--font-body); font-size:14px; resize:vertical; }
  .form-group input:focus, .form-group textarea:focus{ border-color:var(--amber-bright); outline:none; }
  .form-submit{ background:var(--amber-bright); color:var(--dark); border:none; font-family:var(--font-mono); font-weight:600; font-size:13.5px; padding:13px 24px; border-radius:8px; cursor:pointer; transition:transform .18s, background .18s; }
  .form-submit:hover{ transform:translateY(-2px); background:#f0b559; }
  .form-note{ font-family:var(--font-mono); font-size:11px; color:var(--dark-text-dim); margin-top:10px; }
  .form-success{ display:none; font-family:var(--font-mono); font-size:12.5px; color:var(--teal-bright); margin-top:12px; }
  .form-success.show{ display:block; }

  footer{ padding:0 56px 48px; max-width:var(--maxw); margin:0 auto; }
  @media (max-width:760px){ footer{ padding:0 22px 40px; } }
  .foot-inner{ display:flex; justify-content:space-between; flex-wrap:wrap; gap:16px; padding-top:32px; border-top:1px solid var(--line); }
  .foot-brand{ font-family:var(--font-display); font-weight:700; font-size:16px; }
  .foot-links{ display:flex; gap:18px; flex-wrap:wrap; }
  .foot-links a{ text-decoration:none; color:var(--ink-soft); font-size:13.5px; }
  .foot-links a:hover{ color:var(--ink); }
  .foot-copy{ font-family:var(--font-mono); font-size:12px; color:var(--ink-faint); margin-top:14px; }

  /* ---------- Dark mode toggle ---------- */
  body, .navbar, .skill-card, .project, .edu-card, .ach-card, .gh-activity-card, .mobile-drawer{ transition:background-color .3s, color .3s, border-color .3s; }
  .theme-toggle{ width:36px; height:36px; border-radius:50%; border:1px solid var(--line-strong); background:var(--surface); color:var(--ink); font-size:16px; line-height:1; cursor:pointer; display:inline-flex; align-items:center; justify-content:center; padding:0; transition:transform .2s, border-color .2s, background .3s; }
  .theme-toggle:hover{ transform:rotate(-15deg) scale(1.06); border-color:var(--amber-bright); }

  /* ---------- Live site link ---------- */
  .live-link{ display:inline-flex; align-items:center; height:36px; padding:0 14px; border-radius:8px; font-family:var(--font-mono); font-size:12.5px; font-weight:500; text-decoration:none; color:#fff; background:var(--teal); border:1px solid var(--teal); white-space:nowrap; transition:transform .18s var(--ease), background .18s; }
  .live-link:hover{ transform:translateY(-2px); background:var(--teal-bright); }
  :root[data-theme="dark"] .live-link{ color:#0b0e16; }
  .case-col a{ color:var(--teal); }

  /* ---------- Coursework ---------- */
  .course-feature{ display:grid; grid-template-columns:1fr auto; gap:24px; align-items:start; background:var(--surface); border:1px solid var(--line); border-radius:12px; padding:28px; text-decoration:none; color:var(--ink); transition:border-color .2s, transform .2s, box-shadow .2s; }
  .course-feature:hover{ border-color:var(--teal); transform:translateY(-3px); box-shadow:0 18px 40px -24px rgba(16,19,26,0.28); }
  @media (max-width:700px){ .course-feature{ grid-template-columns:1fr; } .course-feature .live-link{ justify-self:start; } }
  .course-term{ font-family:var(--font-mono); font-size:11px; text-transform:uppercase; letter-spacing:0.08em; color:var(--teal); }
  .course-feature h3{ font-size:21px; font-weight:600; margin:8px 0 0; }
  .course-feature p{ color:var(--ink-soft); font-size:15px; margin:10px 0 0; max-width:640px; }

  /* ---------- Project screenshots ---------- */
  .project-shot{ margin:0 26px 22px; border:1px solid var(--line); border-radius:10px; overflow:hidden; background:var(--surface-dim); }
  .project-shot img{ width:100%; height:auto; display:block; }
  .project-shot--phone{ display:flex; justify-content:center; padding:24px 16px; background:linear-gradient(135deg, rgba(15,107,100,0.10), rgba(232,163,61,0.10)), var(--surface-dim); }
  .project-shot--phone img{ width:auto; max-width:240px; max-height:440px; border-radius:22px; border:6px solid #10131a; box-shadow:0 18px 40px -18px rgba(16,19,26,0.45); }
  @media (max-width:700px){ .project-shot{ margin:0 16px 18px; } }
  .principles li span strong{ color:var(--ink); font-weight:600; }

  /* ---------- Navbar fit with 7 links ---------- */
  .brand, .avail-pill{ white-space:nowrap; }
  @media (max-width:1200px){
    .avail-pill{ display:none; }
    .nav-links a{ padding:9px 10px; font-size:14px; }
    .nav-links a.active::after{ left:10px; right:10px; }
  }

  /* =========================================================
     Motion system
     ========================================================= */
  @keyframes fadeUp{ from{ opacity:0; transform:translateY(18px); } to{ opacity:1; transform:none; } }
  @keyframes fadeIn{ from{ opacity:0; } to{ opacity:1; } }
  @keyframes themeSpin{ from{ transform:rotate(-180deg) scale(.6); } to{ transform:none; } }
  @keyframes shine{ from{ transform:translateX(-120%) skewX(-20deg); } to{ transform:translateX(220%) skewX(-20deg); } }

  /* Hero entrance, staggered on page load */
  .hero-kicker, .hero h1, .hero-desc, .hero-ctas, .hero-socials, .hero-stats{ animation:fadeUp .8s var(--ease) both; }
  .hero h1{ animation-delay:.08s; }
  .hero-desc{ animation-delay:.18s; }
  .hero-ctas{ animation-delay:.28s; }
  .hero-socials{ animation-delay:.36s; }
  .hero-stats{ animation-delay:.44s; }

  /* Sections: children rise in one after another (JS adds .rv-item and --i) */
  .js-motion .reveal{ opacity:1; transform:none; }
  .js-motion .rv-item{ opacity:0; transform:translateY(22px); transition:opacity .7s var(--ease), transform .7s var(--ease); transition-delay:calc(var(--i,0) * 90ms); }
  .js-motion .reveal.in-view .rv-item{ opacity:1; transform:none; }

  /* Navbar: shadow once you scroll, animated underline */
  .navbar{ transition:box-shadow .3s, background-color .3s; }
  .navbar.scrolled{ box-shadow:0 10px 30px -18px rgba(16,19,26,0.35); }
  .nav-links a::after{ content:''; position:absolute; left:14px; right:14px; bottom:3px; height:2px; background:var(--amber-bright); border-radius:2px; transform:scaleX(0); transform-origin:left center; transition:transform .35s var(--ease); }
  .nav-links a:hover::after, .nav-links a.active::after{ transform:scaleX(1); }
  .nav-links a:hover::after{ opacity:.5; }
  .nav-links a.active::after{ opacity:1; }
  @media (max-width:1200px){ .nav-links a::after{ left:10px; right:10px; } }

  /* Scroll progress bar */
  .scroll-progress{ position:fixed; top:0; left:0; right:0; height:3px; z-index:100; background:linear-gradient(90deg, var(--amber-bright), var(--teal-bright)); transform:scaleX(0); transform-origin:left center; pointer-events:none; }

  /* Buttons */
  .btn-primary{ position:relative; overflow:hidden; }
  .btn-primary::after{ content:''; position:absolute; top:0; bottom:0; left:0; width:40%; background:linear-gradient(90deg, transparent, rgba(255,255,255,0.22), transparent); transform:translateX(-120%) skewX(-20deg); pointer-events:none; }
  .btn-primary:hover::after{ animation:shine .8s var(--ease); }
  .btn-ghost:hover{ box-shadow:0 10px 22px -12px rgba(16,19,26,0.3); }
  .live-link{ position:relative; overflow:hidden; }
  .live-link::after{ content:''; position:absolute; top:0; bottom:0; left:0; width:40%; background:linear-gradient(90deg, transparent, rgba(255,255,255,0.3), transparent); transform:translateX(-120%) skewX(-20deg); pointer-events:none; }
  .live-link:hover::after{ animation:shine .8s var(--ease); }

  /* Cards: smooth lift on hover (keeps theme color transitions) */
  .skill-card, .edu-card, .ach-card, .gh-activity-card, .project, .course-feature, .stack-group{ transition:background-color .3s, color .3s, border-color .25s, transform .35s var(--ease), box-shadow .35s var(--ease); }
  .stack-group:hover{ border-color:var(--line-strong); transform:translateY(-3px); box-shadow:0 16px 32px -22px rgba(16,19,26,0.28); }
  .project:hover{ transform:translateY(-3px); }
  .project-shot img{ transition:transform .6s var(--ease); }
  .project:hover .project-shot img{ transform:scale(1.015); }
  .ach-card .num{ transition:color .25s; }
  .ach-card:hover .num{ color:var(--teal); }
  .stack-item{ transition:transform .2s var(--ease), color .2s; }
  .stack-item:hover{ transform:translateX(4px); color:var(--teal); }

  /* Case study: content fades in when opened; theme-safe hover */
  details.case-study summary{ transition:background-color .2s; }
  details.case-study summary:hover{ background:var(--surface-dim); }
  details.case-study[open] .case-body > *{ animation:fadeUp .5s var(--ease) both; }
  details.case-study[open] .case-body > *:nth-child(2){ animation-delay:.08s; }
  details.case-study[open] .case-body > *:nth-child(3){ animation-delay:.16s; }

  /* Timeline: line draws down, dots pop in */
  .js-motion .log::before{ transform:scaleY(0); transform-origin:top; transition:transform 1.2s var(--ease) .2s; }
  .js-motion .reveal.in-view .log::before{ transform:scaleY(1); }
  .commit::before{ transition:transform .4s var(--ease), background-color .3s; }
  .commit:hover::before{ transform:scale(1.25); background:var(--amber-bright); }

  /* Contact form focus glow */
  .form-group input, .form-group textarea{ transition:border-color .2s, box-shadow .2s; }
  .form-group input:focus, .form-group textarea:focus{ box-shadow:0 0 0 3px rgba(232,163,61,0.18); }
  .form-submit{ transition:transform .2s var(--ease), background-color .2s, box-shadow .2s; }
  .form-submit:hover{ box-shadow:0 12px 24px -10px rgba(232,163,61,0.55); }

  /* Theme toggle spins when switched */
  .theme-toggle.spin{ animation:themeSpin .5s var(--ease); }

  /* Back to top */
  .to-top{ position:fixed; right:22px; bottom:calc(22px + env(safe-area-inset-bottom, 0px)); z-index:90; width:44px; height:44px; border-radius:50%; border:1px solid var(--line-strong); background:var(--surface); color:var(--ink); font-size:18px; cursor:pointer; box-shadow:0 12px 24px -12px rgba(16,19,26,0.4); opacity:0; transform:translateY(12px); pointer-events:none; transition:opacity .3s, transform .3s var(--ease), border-color .2s; }
  .to-top.show{ opacity:1; transform:none; pointer-events:auto; }
  .to-top:hover{ border-color:var(--amber-bright); transform:translateY(-3px); }

  @media (prefers-reduced-motion: reduce){
    .js-motion .rv-item{ opacity:1; transform:none; }
    .js-motion .log::before{ transform:none; }
    .scroll-progress{ display:none; }
  }
  .stagger > *:not(.rv-item){ transition-delay:0s; }

  /* ---------- Project result metrics ---------- */
  .project-metrics{ display:grid; grid-template-columns:repeat(3, minmax(0,1fr)); gap:12px; margin-top:18px; max-width:600px; padding:0; }
  .project-metrics > div{ border:1px solid var(--line); border-radius:10px; padding:12px 14px; background:var(--surface-dim); }
  .project-metrics b{ display:block; font-family:var(--font-display); font-size:22px; font-weight:700; color:var(--teal); line-height:1.1; }
  .project-metrics span{ display:block; margin-top:6px; font-family:var(--font-mono); font-size:11px; line-height:1.45; color:var(--ink-soft); }
  @media (max-width:560px){ .project-metrics{ grid-template-columns:1fr; } }

  /* ---------- Hero: live "collaborator" cursors ---------- */
  .hero{ position:relative; }
  .cursor-layer{ position:absolute; inset:0; pointer-events:none; z-index:5; overflow:visible; }
  .live-cursor{ position:absolute; left:0; top:0; transform:translate(var(--x,0px), var(--y,0px)); transition:transform 1.4s cubic-bezier(.45,.05,.2,1), opacity .5s; opacity:0; will-change:transform; }
  .live-cursor.on{ opacity:1; }
  .live-cursor svg{ display:block; width:18px; height:18px; filter:drop-shadow(0 2px 3px rgba(0,0,0,.25)); transition:transform .15s; transform-origin:3px 2px; }
  .live-cursor svg path{ fill:var(--c); stroke:#fff; stroke-width:1.4; stroke-linejoin:round; }
  .live-cursor .tag{ position:absolute; left:14px; top:16px; padding:3px 8px; border-radius:6px 999px 999px 999px; background:var(--c); color:#fff; font-family:var(--font-mono); font-size:10.5px; font-weight:600; white-space:nowrap; box-shadow:0 6px 14px -6px rgba(0,0,0,.35); }
  .live-cursor.click svg{ transform:scale(.8); }
  .live-cursor .ripple{ position:absolute; left:-9px; top:-9px; width:22px; height:22px; border-radius:50%; border:2px solid var(--c); opacity:0; transform:scale(.3); }
  .live-cursor.click .ripple{ animation:cursorRipple .55s ease-out; }
  @keyframes cursorRipple{ 0%{ opacity:.9; transform:scale(.3); } 100%{ opacity:0; transform:scale(1.8); } }
  .cursor-hit{ border-radius:8px; box-shadow:0 0 0 2px var(--hit-c) !important; transition:box-shadow .2s; }
  .hero h1 .accent.cursor-hit{ border-radius:4px; }
  @media (prefers-reduced-motion: reduce){ .cursor-layer{ display:none; } }

  /* Cursor polish: smoother glide, action labels, dodge */
  .live-cursor{ transition:transform 1.5s cubic-bezier(.65,0,.25,1), opacity .5s; }
  .live-cursor.dodge{ transition:transform .35s cubic-bezier(.22,1,.36,1), opacity .5s; }
  .live-cursor .tag{ display:inline-flex; align-items:center; gap:0; overflow:hidden; }
  .live-cursor .tag b{ font-weight:600; }
  .live-cursor .tag em{ font-style:normal; font-weight:500; opacity:.92; max-width:0; white-space:nowrap; transition:max-width .35s var(--ease), margin .35s var(--ease); }
  .live-cursor.talk .tag em{ max-width:140px; margin-left:6px; }
  .live-cursor.talk .tag em::before{ content:'· '; }
  .live-cursor .tag{ animation:tagPop .4s var(--ease) both; }
  @keyframes tagPop{ from{ transform:scale(.6); opacity:0; } to{ transform:none; opacity:1; } }
  .hero-stat.cursor-hit b{ animation:statBump .45s var(--ease); transform-origin:left center; }
  @keyframes statBump{ 40%{ transform:scale(1.08); } }
  .live-cursor .tag em{ display:inline-block; overflow:hidden; vertical-align:bottom; }

  .cert-name a{ color:inherit; text-decoration:none; border-bottom:1px dashed var(--line-strong); transition:color .2s, border-color .2s; }
  .cert-name a:hover{ color:var(--teal); border-color:var(--teal); }
  .cert-name{ display:flex; align-items:center; gap:12px; }
  .cert-badge{ width:40px; height:40px; flex-shrink:0; transition:transform .3s var(--ease); }
  .cert-row:hover .cert-badge{ transform:rotate(-8deg) scale(1.08); }
