*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }
  :root {
    --bg: #0a0808;
    --bg-soft: #100c0d;
    --surface: #161112;
    --line: rgba(255,255,255,0.10);
    --line-strong: rgba(255,255,255,0.22);
    --text: #f3f1f1;
    --muted: #8f8888;
    --muted-dim: #5e5757;
    --white: #ffffff;
    --red: #e10b1f;
    --red-soft: #ff2436;
    --radius: 14px;
    --ease: cubic-bezier(0.22, 1, 0.36, 1);
    --ease-bounce: cubic-bezier(0.34, 1.56, 0.64, 1);
    --glass-bg: rgba(255,255,255,0.012);
    --glass-bg-hover: rgba(255,255,255,0.035);
    --glass-border: rgba(255,255,255,0.14);
    --glass-blur: 9px;
    --glass-shadow:
      0 10px 40px rgba(0,0,0,0.28),
      inset 0 1px 1px rgba(255,255,255,0.30),
      inset 0 -10px 24px -12px rgba(255,255,255,0.10),
      inset 0 12px 24px -14px rgba(255,255,255,0.16);
    --glass-shadow-hover:
      0 20px 60px rgba(0,0,0,0.38),
      0 0 40px -12px rgba(225,11,31,.28),
      inset 0 1px 1px rgba(255,255,255,0.45),
      inset 0 -12px 28px -12px rgba(255,255,255,0.14),
      inset 0 14px 28px -14px rgba(255,255,255,0.22);
  }
  body.light {
    --glass-bg: rgba(255,255,255,0.10);
    --glass-bg-hover: rgba(255,255,255,0.20);
    --glass-border: rgba(255,255,255,0.40);
    --glass-shadow:
      0 10px 40px rgba(0,0,0,0.10),
      inset 0 1px 1px rgba(255,255,255,0.7),
      inset 0 -10px 24px -12px rgba(255,255,255,0.35),
      inset 0 12px 24px -14px rgba(255,255,255,0.5);
    --glass-shadow-hover:
      0 20px 60px rgba(0,0,0,0.16),
      0 0 40px -12px rgba(225,11,31,.20),
      inset 0 1px 1px rgba(255,255,255,0.9),
      inset 0 -12px 28px -12px rgba(255,255,255,0.45),
      inset 0 14px 28px -14px rgba(255,255,255,0.6);
  }
  html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
  body {
    font-family: 'Inter', 'Segoe UI', system-ui, sans-serif;
    background: var(--bg); color: var(--text); line-height: 1.6;
    overflow-x: hidden; -webkit-font-smoothing: antialiased; letter-spacing: .2px;
  }
  ::selection { background: var(--red); color: #fff; }
  a { color: inherit; text-decoration: none; }
  img { max-width: 100%; display: block; }
  ::-webkit-scrollbar { width: 9px; }
  ::-webkit-scrollbar-track { background: var(--bg); }
  ::-webkit-scrollbar-thumb { background: #2a1f20; border-radius: 9px; }
  ::-webkit-scrollbar-thumb:hover { background: var(--red); }

  .heavy { font-family: 'Arial Black', 'Inter', sans-serif; font-weight: 900; letter-spacing: -0.5px; }
  .display { font-weight: 900; letter-spacing: 1px; text-transform: uppercase; }

  .progress { position: fixed; top: 0; left: 0; height: 3px; width: 0%; background: var(--red); z-index: 300; box-shadow: 0 0 12px var(--red); }

  .cursor-glow { position: fixed; top:0; left:0; width: 440px; height: 440px; border-radius: 50%;
    background: radial-gradient(circle, rgba(225,11,31,0.10), transparent 65%); transform: translate(-50%,-50%);
    pointer-events: none; z-index: 1; will-change: transform; }

  .container { width: min(1180px, 92vw); margin: 0 auto; position: relative; z-index: 2; }
  section { position: relative; z-index: 2; }

  nav { position: fixed; top: 0; left: 0; right: 0; z-index: 100; padding: 22px clamp(18px,4vw,46px);
    display: flex; align-items: center; justify-content: space-between;
    transition: background .4s var(--ease), padding .4s var(--ease), backdrop-filter .4s; }
  nav.scrolled { background: rgba(10,8,8,.8); backdrop-filter: blur(14px); padding-block: 14px; border-bottom: 1px solid var(--line); }
  .logo { font-size: 1.35rem; font-weight: 900; letter-spacing: 1px; color: var(--red); }
  .logo span { color: var(--red); }
  .nav-links { display: flex; gap: clamp(20px,3vw,44px); list-style: none; }
  .nav-links a { color: var(--text); font-size: .78rem; font-weight: 700; letter-spacing: 2px; position: relative; }
  .nav-links a::after { content:''; position:absolute; left:0; bottom:-6px; width:0; height:1px; background: var(--red); transition: width .35s var(--ease); }
  .nav-links a:hover { color: var(--red-soft); }
  .nav-links a:hover::after { width: 100%; }
  .burger { display: flex; flex-direction: column; gap: 5px; background: none; border: none; cursor: pointer; padding: 6px; z-index: 110; }
  .burger span { width: 28px; height: 2px; background: var(--red); transition: transform .35s var(--ease), opacity .3s; }
  .burger.active span:nth-child(1){ transform: translateY(7px) rotate(45deg); }
  .burger.active span:nth-child(2){ opacity: 0; }
  .burger.active span:nth-child(3){ transform: translateY(-7px) rotate(-45deg); }
  @media (max-width: 880px) { .nav-links.desktop { display: none; } }
  @media (min-width: 881px) { .burger { display: none; } }

  .mobile-menu { position: fixed; inset: 0; background: rgba(10,8,8,.97); backdrop-filter: blur(10px); z-index: 105;
    display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 26px;
    opacity: 0; pointer-events: none; transition: opacity .4s var(--ease); }
  .mobile-menu.open { opacity: 1; pointer-events: auto; }
  .mobile-menu a { font-size: 1.8rem; font-weight: 900; letter-spacing: 3px; text-transform: uppercase; color: var(--text);
    opacity: 0; transform: translateY(24px); transition: opacity .5s var(--ease), transform .5s var(--ease), color .3s; }
  .mobile-menu.open a { opacity: 1; transform: none; }
  .mobile-menu a:hover { color: var(--red-soft); }
  .mobile-menu.open a:nth-child(1){transition-delay:.1s}.mobile-menu.open a:nth-child(2){transition-delay:.16s}
  .mobile-menu.open a:nth-child(3){transition-delay:.22s}.mobile-menu.open a:nth-child(4){transition-delay:.28s}
  .mobile-menu.open a:nth-child(5){transition-delay:.34s}.mobile-menu.open a:nth-child(6){transition-delay:.4s}

  .hero { min-height: 100vh; position: relative; display: flex; align-items: center; overflow: hidden; }
  .hero::after { content:''; position:absolute; inset:0; z-index:0; pointer-events:none;
    background: radial-gradient(80% 60% at 75% 45%, rgba(225,11,31,.10), transparent 60%); }

  .hero-inner { position: relative; z-index: 2; width: min(1180px, 92vw); margin: 0 auto;
    display: grid; grid-template-columns: 1.05fr 1fr; gap: clamp(20px, 4vw, 50px); align-items: center; }

  .hero-content { text-align: left; max-width: 600px; }
  .hero-content > * { opacity: 0; transform: translateY(26px); animation: heroUp .9s var(--ease) forwards; }
  .hero-content .badge { animation-delay: .15s; }
  .hero-content h1 { animation-delay: .3s; }
  .hero-content .role-line { animation-delay: .45s; }
  .hero-content p { animation-delay: .6s; }
  .hero-btns { animation-delay: .75s; }
  .hero-stats { animation-delay: .9s; }
  @keyframes heroUp { to { opacity: 1; transform: none; } }

  .hero-content .badge { display: inline-flex; align-items: center; gap: 8px; padding: 7px 16px; border-radius: 999px;
    background: var(--surface); border: 1px solid var(--line); color: var(--text); font-size: .8rem; font-weight: 600; margin-bottom: 18px; }
  .hero-content .badge .dot { width: 7px; height: 7px; border-radius: 50%; background: var(--red); box-shadow: 0 0 0 0 rgba(225,11,31,.5); animation: pulse 2s var(--ease) infinite; }
  @keyframes pulse { 0%,100%{ box-shadow: 0 0 0 0 rgba(225,11,31,.5);} 50%{ box-shadow: 0 0 0 7px rgba(225,11,31,0);} }
  .hero-content h1 { font-size: clamp(2.4rem, 6.5vw, 5rem); font-weight: 900; line-height: 1.0; letter-spacing: -1.5px; }
  .hero-content h1 .accent { background: linear-gradient(120deg, var(--red-soft), #ff7a86); -webkit-background-clip: text; background-clip: text; color: transparent; }
  .role-line { font-size: clamp(1.05rem, 3vw, 1.5rem); font-weight: 800; margin-top: 12px; color: var(--text); min-height: 1.6em; }
  .role-line .typed { color: var(--red-soft); }
  .role-line .caret { display: inline-block; width: 2px; height: 1.05em; background: var(--red); margin-left: 3px; vertical-align: -0.18em; animation: blink 1s step-end infinite; }
  @keyframes blink { 50% { opacity: 0; } }
  .hero-content p { color: var(--muted); font-size: clamp(1rem, 2.2vw, 1.15rem); margin: 16px 0 26px; max-width: 480px; }
  .hero-btns { display: flex; gap: 14px; flex-wrap: wrap; margin-bottom: 30px; }

  .hero-stats { display: inline-flex; gap: clamp(18px, 4vw, 40px); padding: 16px 24px; border-radius: 16px;
    background: var(--surface); border: 1px solid var(--line); }
  .hero-stats .hs b { display: block; font-size: clamp(1.3rem, 4vw, 1.8rem); font-weight: 900; color: var(--text); line-height: 1; }
  .hero-stats .hs span { font-size: .66rem; letter-spacing: 1.5px; text-transform: uppercase; color: var(--muted); }
  .hero-stats .sep { width: 1px; background: var(--line); }

  .hero-visual { display: flex; align-items: center; justify-content: center; opacity: 0; animation: heroUp 1.1s var(--ease) .5s forwards; }
  .hero-visual { min-height: 40vh; }

  .scroll-cue { position: absolute; bottom: 18px; left: 50%; transform: translateX(-50%); z-index: 3; color: var(--muted);
    font-size: .62rem; letter-spacing: 3px; display: flex; flex-direction: column; align-items: center; gap: 8px;
    animation: cueBob 2s var(--ease) infinite; }
  @keyframes cueBob { 0%,100%{ transform: translateX(-50%) translateY(0);} 50%{ transform: translateX(-50%) translateY(7px);} }
  .scroll-cue .line { width: 1px; height: 30px; background: linear-gradient(var(--red), transparent); }

  @media (max-width: 820px) {
    .hero { padding-top: 90px; padding-bottom: 60px; }
    .hero-inner { grid-template-columns: 1fr; text-align: center; gap: 10px; }
    .hero-content { text-align: center; margin: 0 auto; }
    .hero-content p { margin-inline: auto; }
    .hero-btns { justify-content: center; }
    .hero-visual { order: -1; }
    .hero-visual { min-height: 32vh; }
  }
  @media (max-width: 480px) {
    .hero-stats { gap: 14px; padding: 14px 14px; }
  }

  .sec { padding: clamp(70px,11vw,130px) 0; }

  @media (min-width: 981px) {
    .sec.dot-left  .container { width: min(800px, 64vw); margin-left: auto;  margin-right: clamp(16px,2vw,40px); }
    .sec.dot-right .container { width: min(800px, 64vw); margin-right: auto; margin-left: clamp(16px,2vw,40px); }
    .sec.dot-left  .head { text-align: left; }
    .sec.dot-right .head { text-align: left; }
    .sec .head .sub { justify-content: flex-start; }
    .sec.dot-left::before, .sec.dot-right::before {
      content:''; position:absolute; top:50%; transform:translateY(-50%);
      width: 28vw; height: 28vw; max-width:360px; max-height:360px; border-radius:50%;
      background: radial-gradient(circle, rgba(225,11,31,.06), transparent 65%); pointer-events:none; z-index:0; }
    .sec.dot-left::before  { left: 0; }
    .sec.dot-right::before { right: 0; }
  }
  .head { margin-bottom: clamp(40px,7vw,70px); }
  .head .sub { color: var(--red-soft); font-weight: 800; letter-spacing: 4px; text-transform: uppercase; font-size: .72rem; display: flex; align-items: center; gap: 12px; }
  .head .sub::before { content:''; width: 30px; height: 1px; background: var(--red); }
  .head h2 { font-size: clamp(2rem,7vw,4rem); font-weight: 900; margin-top: 14px; text-transform: uppercase; line-height: 1; }
  .head h2 .outline { color: transparent; -webkit-text-stroke: 1.4px var(--red); }

  .about-grid { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(30px,5vw,60px); align-items: center; }
  .about-grid p { color: var(--muted); margin-bottom: 18px; font-size: 1.02rem; }
  .about-grid strong { color: var(--white); }
  .about-visual { aspect-ratio: 1; border: 1px solid rgba(225,11,31,.4); border-radius: 50%; display: grid; place-items: center; position: relative; }
  .about-visual .sq { width: 55%; aspect-ratio: 1; background: var(--red); display: grid; place-items: center; font-size: clamp(3rem,9vw,6rem); font-weight: 900; color: #fff; }
  .stats { display: grid; grid-template-columns: repeat(3,1fr); gap: 14px; margin-top: 26px; }
  .stat { border: 1px solid var(--line); border-radius: var(--radius); padding: 18px; text-align: center; transition: border-color .4s, transform .4s var(--ease); }
  .stat:hover { border-color: var(--red); transform: translateY(-5px); }
  .stat b { font-size: 1.7rem; display: block; color: var(--red-soft); font-weight: 900; }
  .stat span { font-size: .72rem; color: var(--muted); letter-spacing: 1px; }

  .marquee { overflow: hidden; border-block: 1px solid var(--line); padding: 20px 0;
    -webkit-mask-image: linear-gradient(90deg,transparent,#000 12%,#000 88%,transparent); mask-image: linear-gradient(90deg,transparent,#000 12%,#000 88%,transparent); }
  .marquee-track { display: flex; gap: 44px; width: max-content; animation: scroll 24s linear infinite; }
  .marquee:hover .marquee-track { animation-play-state: paused; }
  .marquee-track span { font-size: clamp(1.2rem,3.5vw,2rem); font-weight: 900; text-transform: uppercase; color: transparent; -webkit-text-stroke: 1px var(--muted-dim); transition: -webkit-text-stroke .3s, color .3s; }
  .marquee-track span.dot { color: var(--red); -webkit-text-stroke: 0; }
  .marquee-track span:hover { color: var(--red-soft); -webkit-text-stroke: 0; }
  @keyframes scroll { to { transform: translateX(-50%); } }

  .skill-cats { display: grid; grid-template-columns: repeat(3,1fr); gap: clamp(14px,2.5vw,20px); }
  .skill-card, .proj-card, .ach, .blog-card, .contact-card {
    background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius);
    transition: transform .4s var(--ease), border-color .4s, background .4s; position: relative; overflow: hidden; }
  .skill-card { padding: clamp(22px,3vw,30px); }
  .skill-card::before, .proj-card::before, .ach::before, .blog-card::before, .contact-card::before {
    content:''; position:absolute; top:0; left:0; width:3px; height:0; background: var(--red); transition: height .4s var(--ease); z-index: 3; }
  .skill-card:hover, .ach:hover, .blog-card:hover, .contact-card:hover { transform: translateY(-8px); border-color: var(--line-strong); background: #1a1314; }
  .skill-card:hover::before, .proj-card:hover::before, .ach:hover::before, .blog-card:hover::before, .contact-card:hover::before { height: 100%; }
  .skill-card h3 { margin-bottom: 18px; font-size: 1.05rem; display: flex; align-items: center; gap: 10px; }
  .skill-card .ico { font-size: 1.3rem; filter: grayscale(1) brightness(1.6); }
  .chips { display: flex; flex-wrap: wrap; gap: 9px; }
  .chip { background: var(--bg-soft); border: 1px solid var(--line); padding: 6px 14px; border-radius: 999px; font-size: .8rem; color: var(--muted); transition: all .3s var(--ease); }
  .chip:hover { background: var(--red); border-color: var(--red); color: #fff; transform: translateY(-3px); }

  .proj-grid { display: grid; grid-template-columns: repeat(2,1fr); gap: clamp(16px,2.5vw,24px); }
  .proj-card:hover { transform: translateY(-8px); border-color: var(--line-strong); box-shadow: 0 24px 60px rgba(225,11,31,.12); }
  .proj-top { height: 150px; display: grid; place-items: center; font-size: 2.8rem; background: linear-gradient(135deg,#160f10,#1c1314); border-bottom: 1px solid var(--line); position: relative; overflow: hidden; }
  .proj-top::after { content:''; position:absolute; bottom:0; left:0; right:0; height:0; background: linear-gradient(transparent, rgba(225,11,31,.18)); transition: height .45s var(--ease); }
  .proj-card:hover .proj-top::after { height: 100%; }
  .proj-top span { filter: grayscale(1) brightness(1.4); transition: transform .5s var(--ease-bounce); display:inline-block; z-index:2; }
  .proj-card:hover .proj-top span { transform: scale(1.25) rotate(-8deg); }
  .proj-body { padding: 26px; }
  .proj-body h3 { font-size: 1.2rem; margin-bottom: 8px; }
  .proj-body p { color: var(--muted); font-size: .9rem; margin-bottom: 16px; }
  .proj-tags { display: flex; flex-wrap: wrap; gap: 7px; margin-bottom: 18px; }
  .proj-tags span { font-size: .72rem; color: var(--muted); border: 1px solid var(--line); padding: 4px 11px; border-radius: 999px; }
  .proj-links a { color: var(--muted); font-size: .85rem; font-weight: 700; margin-right: 18px; position: relative; transition: color .3s; }
  .proj-links a:hover { color: var(--red-soft); }

  .timeline { position: relative; max-width: 760px; margin: 0 auto; }
  .timeline::before { content:''; position:absolute; left:19px; top:6px; bottom:6px; width:1px; background: linear-gradient(var(--red), transparent); }
  .tl-item { position: relative; padding-left: 60px; margin-bottom: 42px; }
  .tl-item .dot { position:absolute; left:12px; top:5px; width:15px; height:15px; border-radius:50%; background: var(--bg); border:2px solid var(--red); transition: transform .4s var(--ease-bounce), box-shadow .4s; }
  .tl-item:hover .dot { transform: scale(1.4); box-shadow: 0 0 0 6px rgba(225,11,31,.12); }
  .tl-item time { color: var(--red-soft); font-weight:700; font-size:.76rem; letter-spacing:1px; text-transform:uppercase; }
  .tl-item h3 { font-size: 1.12rem; margin: 5px 0; }
  .tl-item .org { color: var(--white); font-size: .9rem; margin-bottom: 6px; }
  .tl-item p { color: var(--muted); font-size: .9rem; }

  .ach-grid { display: grid; grid-template-columns: repeat(3,1fr); gap: clamp(14px,2.5vw,20px); }
  .ach { padding: clamp(22px,3vw,30px); text-align: center; }
  .ach .icon { font-size: 2.2rem; margin-bottom: 14px; filter: grayscale(1) brightness(1.5); transition: transform .4s var(--ease-bounce); display:inline-block; }
  .ach:hover .icon { transform: scale(1.2) rotate(8deg); }
  .ach h3 { font-size: 1rem; margin-bottom: 6px; }
  .ach p { color: var(--muted); font-size: .84rem; }

  .blog-grid { display: grid; grid-template-columns: repeat(3,1fr); gap: clamp(14px,2.5vw,20px); }
  .blog-card { padding: clamp(22px,3vw,28px); }
  .blog-card time { color: var(--red-soft); font-size:.74rem; font-weight:700; letter-spacing:1px; text-transform:uppercase; }
  .blog-card h3 { font-size: 1.08rem; margin: 10px 0; }
  .blog-card p { color: var(--muted); font-size: .86rem; margin-bottom: 14px; }
  .blog-card a { color: var(--white); font-weight: 700; font-size: .84rem; }
  .blog-card a:hover { color: var(--red-soft); }

  .contact-box { border: 1px solid var(--line); border-radius: 24px; padding: clamp(40px,7vw,72px) clamp(24px,5vw,48px); text-align: center; max-width: 760px; margin: 0 auto; position: relative; overflow: hidden; background: var(--surface); }
  .contact-box::before { content:''; position:absolute; top:-60px; right:-60px; width:200px; height:200px; border:1px solid rgba(225,11,31,.3); border-radius:50%; }
  .contact-box h3 { font-size: clamp(1.6rem,5vw,2.6rem); font-weight: 900; text-transform: uppercase; line-height:1.1; }
  .contact-box p { color: var(--muted); margin: 18px auto 32px; max-width: 460px; }

  .contact-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: clamp(14px,2.5vw,20px); }
  .contact-card { display: flex; align-items: center; gap: 16px; padding: clamp(18px,2.6vw,24px); text-decoration: none; }
  .contact-card .ci { width: 48px; height: 48px; flex: 0 0 48px; border-radius: 12px; display: grid; place-items: center; font-size: 1.4rem;
    background: var(--bg-soft); border: 1px solid var(--line); filter: grayscale(1) brightness(1.4); transition: background .35s, filter .35s, transform .35s var(--ease-bounce); }
  .contact-card:hover .ci { background: var(--red); filter: grayscale(1) brightness(2); transform: scale(1.08) rotate(6deg); }
  .contact-card .cmeta { text-align: left; min-width: 0; }
  .contact-card .cmeta b { display: block; font-size: .95rem; color: var(--text); }
  .contact-card .cmeta span { font-size: .8rem; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; display: block; }
  @media (max-width: 560px) { .contact-grid { grid-template-columns: 1fr; } }
  .btn { padding: 15px 34px; border-radius: 999px; font-weight: 800; letter-spacing: 1px; font-size: .85rem; cursor: pointer; display: inline-block; border: 1px solid var(--red); background: var(--red); color: #fff; transition: transform .35s var(--ease), background .35s, color .35s, box-shadow .35s; text-transform: uppercase; }
  .btn:hover { background: transparent; color: var(--red-soft); transform: translateY(-3px); box-shadow: 0 12px 30px rgba(225,11,31,.25); }
  .btn-ghost { background: transparent; color: var(--text); border-color: var(--line-strong); }
  .btn-ghost:hover { border-color: var(--red); color: var(--red-soft); box-shadow:none; }
  .social-row { display: flex; justify-content: center; gap: 14px; flex-wrap: wrap; margin-top: 10px; }
  .social { width: 52px; height: 52px; border-radius: 12px; background: var(--bg-soft); border: 1px solid var(--line); display: grid; place-items: center; font-size: 1.3rem; filter: grayscale(1) brightness(1.4); transition: transform .35s var(--ease-bounce), background .35s, filter .35s; }
  .social:hover { transform: translateY(-7px) scale(1.08); background: var(--red); filter: grayscale(1) brightness(2); }

  footer { text-align: center; padding: 36px 20px; color: var(--muted-dim); font-size: .82rem; border-top: 1px solid var(--line); }
  footer strong { color: var(--text); }
  .ph { color: var(--muted-dim); font-style: italic; }

  .top-btn { position: fixed; bottom: 24px; right: 24px; width: 48px; height: 48px; border-radius: 50%; background: var(--red); color: #fff; border: none; font-size: 1.2rem; cursor: pointer; z-index: 120; opacity: 0; transform: translateY(20px); transition: opacity .4s var(--ease), transform .4s var(--ease-bounce); display: grid; place-items: center; }
  .top-btn.show { opacity: 1; transform: none; }
  .top-btn:hover { transform: translateY(-4px) scale(1.08); }

  .grain { position: fixed; inset: -50%; z-index: 90; pointer-events: none; opacity: .04; mix-blend-mode: overlay;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='120' height='120'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='3'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
    animation: grainShift 1.2s steps(4) infinite; }
  @keyframes grainShift { 0%{transform:translate(0,0)} 25%{transform:translate(-4%,3%)} 50%{transform:translate(3%,-2%)} 75%{transform:translate(-2%,-3%)} 100%{transform:translate(2%,2%)} }

  .cursor-dot { position: fixed; top:0; left:0; width: 8px; height: 8px; border-radius: 50%; background: var(--red); z-index: 400; pointer-events: none; transform: translate(-50%,-50%); transition: width .25s var(--ease), height .25s var(--ease), background .25s; }
  .cursor-ring { position: fixed; top:0; left:0; width: 38px; height: 38px; border: 1px solid rgba(225,11,31,.6); border-radius: 50%; z-index: 400; pointer-events: none; transform: translate(-50%,-50%); transition: width .3s var(--ease), height .3s var(--ease), border-color .3s, background .3s; }
  .cursor-ring.hovering { width: 58px; height: 58px; background: rgba(225,11,31,.10); border-color: var(--red-soft); }
  .cursor-dot.hovering { width: 4px; height: 4px; }
  body.has-cursor { cursor: none; }
  body.has-cursor a, body.has-cursor button { cursor: none; }
  @media (max-width: 760px), (pointer: coarse) { .cursor-dot, .cursor-ring { display: none; } body.has-cursor, body.has-cursor a, body.has-cursor button { cursor: auto; } }

  #morphCanvas { position: fixed; inset: 0; width: 100vw; height: 100vh; z-index: 1; pointer-events: none; }
  nav, section, footer, .marquee { position: relative; z-index: 2; }

  .words .w { display: inline-block; overflow: hidden; vertical-align: top; }
  .words .w > span { display: inline-block; transform: translateY(110%); transition: transform .8s var(--ease); }
  .words.show .w > span { transform: none; }
  .words.show .w:nth-child(1)>span{transition-delay:.05s}.words.show .w:nth-child(2)>span{transition-delay:.13s}
  .words.show .w:nth-child(3)>span{transition-delay:.21s}.words.show .w:nth-child(4)>span{transition-delay:.29s}
  .words.show .w:nth-child(5)>span{transition-delay:.37s}

  .skill-card, .proj-card, .ach, .blog-card, .contact-card, .stat,
  .hero-stats, .hero-content .badge, .contact-box, .marquee,
  .btn, .social, .chip, nav.scrolled, .theme-toggle, .top-btn {
    background: var(--glass-bg) !important;
    -webkit-backdrop-filter: blur(var(--glass-blur)) saturate(130%) brightness(1.05);
    backdrop-filter: blur(var(--glass-blur)) saturate(130%) brightness(1.05);
    border: 1px solid var(--glass-border) !important;
    box-shadow: var(--glass-shadow);
  }
  .skill-card, .proj-card, .ach, .blog-card, .contact-card, .contact-box, .hero-stats { position: relative; }
  .skill-card::after, .proj-card::after, .ach::after, .blog-card::after, .contact-card::after {
    content:''; position:absolute; inset:0; border-radius:inherit; pointer-events:none; z-index:2;
    background:
      linear-gradient(135deg, rgba(255,255,255,0.28) 0%, rgba(255,255,255,0) 12%),
      linear-gradient(315deg, rgba(255,255,255,0.14) 0%, rgba(255,255,255,0) 10%);
    -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
    -webkit-mask-composite: xor; mask-composite: exclude;
    padding: 1px;
    opacity: .7; transition: opacity .45s var(--ease); }
  .skill-card:hover, .proj-card:hover, .ach:hover, .blog-card:hover, .contact-card:hover {
    background: var(--glass-bg-hover) !important; box-shadow: var(--glass-shadow-hover);
    transform: translateY(-8px); border-color: rgba(255,255,255,0.45) !important; }
  .skill-card:hover::after, .proj-card:hover::after, .ach:hover::after, .blog-card:hover::after, .contact-card:hover::after { opacity: 1; }
  .ach:hover { transform: translateY(-8px) scale(1.02); }

  .btn { color: var(--text) !important; }
  .btn:hover { background: var(--glass-bg-hover) !important; box-shadow: var(--glass-shadow-hover); transform: translateY(-3px); }
  .btn:not(.btn-ghost) { background: linear-gradient(180deg, rgba(225,11,31,.55), rgba(225,11,31,.30)) !important; border-color: rgba(255,120,130,.5) !important; color:#fff !important; }
  .btn:not(.btn-ghost):hover { background: linear-gradient(180deg, rgba(225,11,31,.75), rgba(225,11,31,.45)) !important; }

  .chip { color: var(--text) !important; }
  .chip:hover { background: linear-gradient(180deg, rgba(225,11,31,.6), rgba(225,11,31,.35)) !important; border-color: rgba(255,120,130,.5) !important; color:#fff !important; }
  .social:hover, .theme-toggle:hover, .top-btn:hover { background: var(--glass-bg-hover) !important; }

  nav { -webkit-backdrop-filter: blur(var(--glass-blur)) saturate(130%) brightness(1.05); backdrop-filter: blur(var(--glass-blur)) saturate(130%) brightness(1.05); }

  .head h2 .outline { transition: color .4s, -webkit-text-stroke .4s, text-shadow .4s; }
  .head:hover h2 .outline { color: var(--red); text-shadow: 0 0 30px rgba(225,11,31,.5); }
  .stat { position: relative; }

  .blog-card a, .proj-links a { background-image: linear-gradient(var(--red),var(--red)); background-repeat: no-repeat; background-position: 0 100%; background-size: 0% 1px; padding-bottom: 2px; transition: background-size .35s var(--ease), color .3s; }
  .blog-card a:hover, .proj-links a:hover { background-size: 100% 1px; }

  .chip { position: relative; overflow: hidden; }
  .chip::before { content:''; position:absolute; inset:0; background: var(--red); transform: scaleX(0); transform-origin:left; transition: transform .35s var(--ease); z-index:-1; }
  .chip:hover { color:#fff; border-color: var(--red); }
  .chip:hover::before { transform: scaleX(1); }

  .head .sub { position: relative; }

  .marquee.rev .marquee-track { animation-direction: reverse; animation-duration: 30s; }

  .stat:hover b { text-shadow: 0 0 24px rgba(225,11,31,.6); }

  .btn { will-change: transform; }

  .reveal { opacity: 0; transform: translateY(38px); transition: opacity .9s var(--ease), transform .9s var(--ease); }
  .reveal.show { opacity: 1; transform: none; }
  .reveal.fade-left { transform: translateX(-46px); }
  .reveal.fade-right { transform: translateX(46px); }
  .reveal.fade-left.show, .reveal.fade-right.show { transform: none; }
  .reveal.fade-scale { transform: scale(.9); }
  .reveal.fade-scale.show { transform: scale(1); }
  .stagger > .reveal { transition-delay: calc(var(--i,0) * 85ms); }
  body { animation: pageIn 1s var(--ease) both; }
  @keyframes pageIn { from { opacity: 0; } to { opacity: 1; } }

  .preloader { position: fixed; inset: 0; z-index: 1000; background: #060404; display: flex; flex-direction: column;
    align-items: center; justify-content: center; gap: 26px; overflow: hidden; }
  .preloader.done { animation: plExit 1s var(--ease) forwards; }
  @keyframes plExit { to { transform: translateY(-100%); visibility: hidden; } }
  .preloader::after { content:''; position:absolute; inset:0; background: var(--red); transform: translateY(100%); z-index:-1; }
  .preloader.done::after { animation: wipeUp 1s var(--ease) forwards; }
  @keyframes wipeUp { 0%{transform:translateY(100%)} 45%{transform:translateY(0)} 100%{transform:translateY(-100%)} }

  .pl-name { display: flex; font-weight: 900; letter-spacing: 2px; font-size: clamp(2rem, 9vw, 5rem); color: var(--white); }
  .pl-name .l { display: inline-block; opacity: 0; transform: translateY(40px) rotateX(-90deg); transform-origin: bottom;
    animation: letterIn .6s var(--ease) forwards; }
  .pl-name .deg { color: var(--red); }
  @keyframes letterIn { to { opacity: 1; transform: none; } }
  .pl-name .l:nth-child(1){animation-delay:.15s}.pl-name .l:nth-child(2){animation-delay:.23s}
  .pl-name .l:nth-child(3){animation-delay:.31s}.pl-name .l:nth-child(4){animation-delay:.39s}
  .pl-name .l:nth-child(5){animation-delay:.47s}.pl-name .l:nth-child(6){animation-delay:.55s}
  .pl-name .l:nth-child(7){animation-delay:.63s}.pl-name .l:nth-child(8){animation-delay:.71s}

  .pl-bar { width: min(280px, 60vw); height: 2px; background: rgba(255,255,255,.12); position: relative; overflow: hidden; }
  .pl-bar i { position: absolute; left:0; top:0; height:100%; width:0%; background: var(--red); transition: width .2s linear; }
  .pl-pct { color: var(--muted); font-size: .8rem; letter-spacing: 3px; font-weight: 700; }
  .pl-sub { color: var(--muted-dim); font-size: .66rem; letter-spacing: 4px; text-transform: uppercase; }
  body.loading { overflow: hidden; }

  .theme-toggle { position: fixed; bottom: 24px; left: 24px; width: 48px; height: 48px; border-radius: 50%;
    background: var(--surface); border: 1px solid var(--line); color: var(--text); font-size: 1.1rem; cursor: pointer;
    z-index: 120; display: grid; place-items: center; transition: transform .35s var(--ease-bounce), background .35s, border-color .35s; }
  .theme-toggle:hover { transform: translateY(-4px) rotate(20deg); border-color: var(--red); color: var(--red-soft); }

  body.light {
    --bg: #f4f1f1; --bg-soft: #ece8e8; --surface: #ffffff; --line: rgba(0,0,0,0.10); --line-strong: rgba(0,0,0,0.22);
    --text: #161112; --muted: #5e5757; --muted-dim: #8f8888; --white: #161112;
  }
  body.light nav.scrolled { background: rgba(244,241,241,.85); }
  body.light .grain { mix-blend-mode: multiply; opacity: .03; }
  body.light .head h2 .outline, body.light .hero h1 .outline { -webkit-text-stroke-color: var(--red); }
  body.light ::selection { background: var(--red); color: #fff; }
  body.light .proj-top { background: linear-gradient(135deg,#efeaea,#e3dcdc); }
  body.light .marquee-track span { -webkit-text-stroke-color: rgba(0,0,0,.25); }

  @media (prefers-reduced-motion: reduce) {
    *, *::before, *::after { animation: none !important; transition: none !important; }
    .reveal { opacity:1 !important; transform:none !important; }
    .cursor-glow { display:none; }
  }

  @media (max-width: 980px) { .skill-cats, .ach-grid, .blog-grid { grid-template-columns: 1fr 1fr; } }
  @media (max-width: 760px) {
    .about-grid, .proj-grid { grid-template-columns: 1fr; }
    .about-visual { max-width: 320px; margin: 0 auto; }
    .cursor-glow { display:none; }
  }
  @media (max-width: 560px) {
    .skill-cats, .ach-grid, .blog-grid { grid-template-columns: 1fr; }
    .stats { grid-template-columns: repeat(3,1fr); }
  }
