:root{
    --ink: #080B16;
    --ink-2: #0B1022;
    --surface: #10152A;
    --surface-2: #141a34;
    --border: rgba(255,255,255,0.09);
    --border-soft: rgba(255,255,255,0.05);
    --text-primary: #F4F6FB;
    --text-muted: #939bbd;
    --text-faint: #5c6386;
    --blue: #6C8CFF;
    --teal: #35E0C6;
    --violet: #9A8CFF;
    --gradient: linear-gradient(115deg, var(--blue) 0%, var(--violet) 48%, var(--teal) 100%);
    --radius-lg: 22px;
    --radius-md: 14px;
    --radius-sm: 10px;
    --maxw: 1120px;
  }

  *{ box-sizing: border-box; margin:0; padding:0; }

  html{ scroll-behavior: smooth; }

  body{
    background: var(--ink);
    color: var(--text-primary);
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    line-height: 1.6;
    overflow-x: hidden;
    position: relative;
  }

  h1, h2, h3, .display{
    font-family: 'Space Grotesk', 'Inter', sans-serif;
    letter-spacing: -0.02em;
    font-weight: 600;
  }

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

  img{ max-width:100%; display:block; }

  .wrap{
    max-width: var(--maxw);
    margin: 0 auto;
    padding: 0 32px;
  }

  ::selection{ background: var(--teal); color: var(--ink); }

  a:focus-visible, button:focus-visible{
    outline: 2px solid var(--teal);
    outline-offset: 3px;
    border-radius: 4px;
  }

  /* ---------- background texture ---------- */

  .grain{
    position: fixed;
    inset: 0;
    pointer-events: none;
    z-index: 2;
    opacity: 0.035;
    mix-blend-mode: overlay;
  }

  .field{
    position: fixed;
    inset: 0;
    z-index: 0;
    pointer-events: none;
    overflow: hidden;
  }

  .orb{
    position: absolute;
    border-radius: 50%;
    filter: blur(90px);
    opacity: 0.4;
  }
  .orb.a{
    width: 620px; height: 620px;
    background: radial-gradient(circle at 30% 30%, var(--blue), transparent 70%);
    top: -220px; right: -180px;
    animation: drift-a 26s ease-in-out infinite;
  }
  .orb.b{
    width: 520px; height: 520px;
    background: radial-gradient(circle at 50% 50%, var(--teal), transparent 70%);
    top: 40%; left: -220px;
    animation: drift-b 30s ease-in-out infinite;
    opacity: 0.28;
  }
  .orb.c{
    width: 460px; height: 460px;
    background: radial-gradient(circle at 50% 50%, var(--violet), transparent 70%);
    bottom: -200px; right: 10%;
    animation: drift-c 34s ease-in-out infinite;
    opacity: 0.3;
  }

  @keyframes drift-a{
    0%, 100%{ transform: translate(0,0) scale(1); }
    50%{ transform: translate(-60px, 60px) scale(1.08); }
  }
  @keyframes drift-b{
    0%, 100%{ transform: translate(0,0) scale(1); }
    50%{ transform: translate(70px, -40px) scale(1.1); }
  }
  @keyframes drift-c{
    0%, 100%{ transform: translate(0,0) scale(1); }
    50%{ transform: translate(-40px, -70px) scale(1.05); }
  }

  /* ---------- nav ---------- */

  header{
    position: sticky;
    top: 0;
    z-index: 50;
    backdrop-filter: blur(14px);
    background: rgba(8, 11, 22, 0.65);
    border-bottom: 1px solid var(--border-soft);
  }

  nav{
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 20px 0;
  }

  .mark{
    font-family: 'Space Grotesk', sans-serif;
    font-weight: 700;
    font-size: 1.05rem;
    display: flex;
    align-items: center;
    gap: 10px;
  }

  .mark-badge{
    width: 34px; height: 34px;
    border-radius: 10px;
    background: var(--gradient);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.85rem;
    color: var(--ink);
    font-weight: 700;
  }

  .nav-links{
    display: flex;
    gap: 34px;
    font-size: 0.94rem;
    color: var(--text-muted);
  }

  .nav-links a{
    position: relative;
    padding: 4px 0;
    transition: color 0.25s ease;
  }
  .nav-links a::after{
    content: '';
    position: absolute;
    left: 0; bottom: 0;
    width: 0; height: 1.5px;
    background: var(--gradient);
    transition: width 0.3s ease;
  }
  .nav-links a:hover{ color: var(--text-primary); }
  .nav-links a:hover::after{ width: 100%; }

  .nav-cta{
    font-size: 0.9rem;
    font-weight: 600;
    padding: 10px 20px;
    border-radius: 100px;
    border: 1px solid var(--border);
    transition: border-color 0.25s ease, transform 0.25s ease, background 0.25s ease;
  }
  .nav-cta:hover{
    border-color: rgba(108,140,255,0.5);
    background: rgba(108,140,255,0.08);
    transform: translateY(-1px);
  }

  @media (max-width: 720px){
    .nav-links{ display: none; }
  }

  /* ---------- hero ---------- */

  .hero{
    position: relative;
    z-index: 1;
    padding: 96px 0 84px;
    display: grid;
    grid-template-columns: 1.15fr 0.85fr;
    gap: 40px;
    align-items: center;
  }

  .hero-text > *{
    opacity: 0;
    transform: translateY(16px);
    animation: rise 0.9s cubic-bezier(.22,1,.36,1) forwards;
  }
  .hero-eyebrow{ animation-delay: 0.05s; }
  .hero-title{ animation-delay: 0.18s; }
  .hero-role{ animation-delay: 0.32s; }
  .hero-bio{ animation-delay: 0.46s; }
  .hero-actions{ animation-delay: 0.6s; }

  @keyframes rise{
    to{ opacity: 1; transform: translateY(0); }
  }

  .hero-eyebrow{
    font-size: 0.95rem;
    color: var(--text-muted);
    margin-bottom: 18px;
  }

  .hero-title{
    font-size: clamp(2.6rem, 5.6vw, 4.4rem);
    line-height: 1.03;
    margin-bottom: 10px;
  }

  .hero-role{
    font-size: clamp(1.3rem, 2.6vw, 1.8rem);
    font-family: 'Space Grotesk', sans-serif;
    font-weight: 500;
    background: var(--gradient);
    background-size: 200% auto;
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    animation: rise 0.9s cubic-bezier(.22,1,.36,1) forwards, shine 7s linear infinite 1.4s;
    margin-bottom: 22px;
  }

  @keyframes shine{
    to{ background-position: 200% center; }
  }

  .hero-bio{
    max-width: 46ch;
    color: var(--text-muted);
    font-size: 1.05rem;
    margin-bottom: 36px;
  }

  .hero-actions{
    display: flex;
    flex-wrap: wrap;
    gap: 14px;
  }

  .btn{
    position: relative;
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 14px 26px;
    border-radius: 100px;
    font-weight: 600;
    font-size: 0.96rem;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    overflow: hidden;
  }

  .btn svg{ width: 18px; height: 18px; flex-shrink: 0; }

  .btn-primary{
    background: var(--gradient);
    background-size: 220% auto;
    color: var(--ink);
  }
  .btn-primary::before{
    content: '';
    position: absolute;
    top: 0; left: -120%;
    width: 60%; height: 100%;
    background: linear-gradient(115deg, transparent, rgba(255,255,255,0.55), transparent);
    transform: skewX(-20deg);
    transition: left 0.7s ease;
  }
  .btn-primary:hover{
    transform: translateY(-2px);
    box-shadow: 0 12px 30px -8px rgba(108,140,255,0.55);
  }
  .btn-primary:hover::before{ left: 130%; }

  .btn-ghost{
    border: 1px solid var(--border);
    color: var(--text-primary);
    background: rgba(255,255,255,0.02);
  }
  .btn-ghost:hover{
    border-color: rgba(53,224,198,0.45);
    transform: translateY(-2px);
    background: rgba(53,224,198,0.06);
  }

  /* hero visual */

  .hero-visual{
    position: relative;
    height: 380px;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    animation: rise 1.1s cubic-bezier(.22,1,.36,1) forwards;
    animation-delay: 0.5s;
  }

  .ring{
    position: absolute;
    border-radius: 50%;
    border: 1px solid var(--border);
  }
  .ring.r1{ width: 300px; height: 300px; animation: spin 40s linear infinite; }
  .ring.r2{ width: 220px; height: 220px; border-style: dashed; opacity: 0.5; animation: spin-rev 55s linear infinite; }

  @keyframes spin{ to{ transform: rotate(360deg); } }
  @keyframes spin-rev{ to{ transform: rotate(-360deg); } }

  .core{
    position: relative;
    width: 156px; height: 156px;
    border-radius: 40px;
    background: linear-gradient(150deg, rgba(108,140,255,0.18), rgba(53,224,198,0.14));
    border: 1px solid var(--border);
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 0 80px -10px rgba(108,140,255,0.35), inset 0 0 40px rgba(255,255,255,0.03);
    animation: float 6s ease-in-out infinite;
  }
  @keyframes float{
    0%, 100%{ transform: translateY(0); }
    50%{ transform: translateY(-14px); }
  }

  .core svg{ width: 62px; height: 62px; color: var(--teal); }

  .satellite{
    position: absolute;
    width: 46px; height: 46px;
    border-radius: 14px;
    background: var(--surface);
    border: 1px solid var(--border);
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 10px 30px -10px rgba(0,0,0,0.6);
  }
  .satellite svg{ width: 20px; height: 20px; color: var(--blue); }
  .sat-1{ top: 14px; right: 26px; animation: float 5s ease-in-out infinite 0.3s; }
  .sat-2{ bottom: 30px; left: 6px; animation: float 6.5s ease-in-out infinite 0.9s; }
  .sat-2 svg{ color: var(--violet); }

  @media (max-width: 880px){
    .hero{ grid-template-columns: 1fr; padding-top: 56px; }
    .hero-visual{ height: 260px; order: -1; }
    .core{ width: 120px; height: 120px; }
    .ring.r1{ width: 230px; height: 230px; }
    .ring.r2{ width: 170px; height: 170px; }
  }

  @media (max-width: 600px){
    .hero .wrap{
      display: block !important;
      position: relative;
    }
    .hero-visual{
      position: absolute;
      inset: 0;
      height: 100%;
      order: 0;
      z-index: 0;
      opacity: 0.12;
      transform: scale(0.8);
      filter: blur(2px);
      pointer-events: none;
    }
    .hero-visual *{
      animation: none !important;
    }
    .hero-text{
      position: relative;
      z-index: 1;
    }
  }

  /* ---------- sections ---------- */

  section{
    position: relative;
    z-index: 1;
    padding: 100px 0;
  }

  .section-head{
    max-width: 62ch;
    margin-bottom: 52px;
  }
  .section-head h2{
    font-size: clamp(1.7rem, 3.2vw, 2.3rem);
    margin-bottom: 14px;
  }
  .section-head p{
    color: var(--text-muted);
    font-size: 1.02rem;
  }

  .reveal{
    opacity: 0;
    transform: translateY(18px);
    transition: opacity 0.7s cubic-bezier(.22,1,.36,1), transform 0.7s cubic-bezier(.22,1,.36,1);
  }
  .reveal.in{ opacity: 1; transform: translateY(0); }

  /* about */

  .about{
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    align-items: start;
  }
  .about-copy p{
    color: var(--text-muted);
    margin-bottom: 18px;
    font-size: 1.02rem;
  }
  .about-copy p:first-child{
    color: var(--text-primary);
    font-size: 1.12rem;
  }

  .stat-list{
    display: flex;
    flex-direction: column;
    gap: 0;
  }
  .stat{
    padding: 22px 0;
    border-top: 1px solid var(--border-soft);
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 20px;
  }
  .stat:last-child{ border-bottom: 1px solid var(--border-soft); }
  .stat-num{
    font-family: 'Space Grotesk', sans-serif;
    font-size: 1.7rem;
    font-weight: 600;
    background: var(--gradient);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    white-space: nowrap;
  }
  .stat-label{
    color: var(--text-muted);
    font-size: 0.96rem;
    text-align: right;
  }

  @media (max-width: 820px){
    .about{ grid-template-columns: 1fr; gap: 36px; }
  }

  /* skills / focus */

  .focus-grid{
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
  }

  .focus-card{
    background: linear-gradient(180deg, var(--surface), var(--surface-2));
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 32px 28px;
    transition: transform 0.35s ease, border-color 0.35s ease, box-shadow 0.35s ease;
  }
  .focus-card:hover{
    transition-delay: 0s;
    transform: translateY(-6px);
    border-color: rgba(108,140,255,0.35);
    box-shadow: 0 20px 40px -18px rgba(108,140,255,0.35);
  }

  .focus-icon{
    width: 46px; height: 46px;
    border-radius: 13px;
    background: rgba(108,140,255,0.1);
    border: 1px solid var(--border);
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 22px;
  }
  .focus-icon svg{ width: 22px; height: 22px; color: var(--teal); }

  .focus-card h3{
    font-size: 1.15rem;
    margin-bottom: 10px;
  }
  .focus-card p{
    color: var(--text-muted);
    font-size: 0.96rem;
  }

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

  /* contact */

  .contact-grid{
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
  }

  .contact-card{
    position: relative;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 30px 26px;
    display: flex;
    flex-direction: column;
    gap: 16px;
    transition: transform 0.35s ease, border-color 0.35s ease, box-shadow 0.35s ease;
    overflow: hidden;
  }
  .contact-card::before{
    content: '';
    position: absolute;
    inset: -1px;
    border-radius: inherit;
    padding: 1px;
    background: var(--gradient);
    opacity: 0;
    transition: opacity 0.35s ease;
    -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
    -webkit-mask-composite: xor;
    mask-composite: exclude;
    pointer-events: none;
  }
  .contact-card:hover{
    transition-delay: 0s;
    transform: translateY(-6px);
    box-shadow: 0 24px 46px -20px rgba(53,224,198,0.3);
  }
  .contact-card:hover::before{ opacity: 1; transition-delay: 0s; }

  .contact-icon{
    width: 48px; height: 48px;
    border-radius: 14px;
    background: rgba(53,224,198,0.1);
    display: flex;
    align-items: center;
    justify-content: center;
  }
  .contact-icon svg{ width: 22px; height: 22px; color: var(--teal); }

  .contact-card h3{
    font-size: 1.08rem;
  }
  .contact-card .value{
    color: var(--text-muted);
    font-size: 0.95rem;
    word-break: break-word;
  }
  .contact-card .go{
    margin-top: auto;
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--blue);
    display: inline-flex;
    align-items: center;
    gap: 6px;
  }
  .contact-card .go svg{
    width: 14px; height: 14px;
    transition: transform 0.3s ease;
  }
  .contact-card:hover .go svg{ transform: translate(3px, -3px); }

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

  /* footer */

  footer{
    position: relative;
    z-index: 1;
    border-top: 1px solid var(--border-soft);
    padding: 34px 0;
  }
  .footer-row{
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 12px;
    color: var(--text-faint);
    font-size: 0.88rem;
  }
  .footer-row a{
    color: var(--text-faint);
    transition: color 0.25s ease;
  }
  .footer-row a:hover{ color: var(--text-primary); }

  @media (prefers-reduced-motion: reduce){
    *{
      animation-duration: 0.01ms !important;
      animation-iteration-count: 1 !important;
      transition-duration: 0.01ms !important;
      scroll-behavior: auto !important;
    }
  }