:root {
  --bg: #08090d;
  --bg-soft: #10121a;
  --panel: rgba(18, 21, 31, .76);
  --line: rgba(255,255,255,.09);
  --text: #f3f5f7;
  --muted: #9da4b3;
  --accent: #b7ff4a;
  --accent-2: #d7ff91;
  --shadow: 0 25px 70px rgba(0,0,0,.34);
  --radius: 22px;
  --max: 1180px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background:
    radial-gradient(circle at 80% 10%, rgba(183,255,74,.09), transparent 25%),
    radial-gradient(circle at 15% 55%, rgba(125,92,255,.08), transparent 24%),
    var(--bg);
  color: var(--text);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  line-height: 1.6;
  overflow-x: hidden;
}

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

.noise {
  position: fixed; inset: 0; pointer-events: none; opacity: .035; z-index: 20;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 180 180' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.88' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='.7'/%3E%3C/svg%3E");
}

.site-header {
  position: sticky; top: 0; z-index: 50;
  width: min(calc(100% - 40px), var(--max));
  margin: 14px auto 0;
  padding: 12px 14px 12px 16px;
  display: flex; align-items: center; justify-content: space-between; gap: 18px;
  background: rgba(8,9,13,.72);
  border: 1px solid var(--line);
  border-radius: 18px;
  backdrop-filter: blur(16px);
}
.brand { display:flex; align-items:center; gap:10px; font-weight: 900; letter-spacing: .16em; font-size: .8rem; }
.brand-mark {
  width: 31px; height: 31px; display:grid; place-items:center; border-radius:10px;
  background: var(--accent); color:#0b0d0a; font-size:.9rem; letter-spacing:0; box-shadow: 0 0 26px rgba(183,255,74,.3);
}
.nav { display:flex; gap: 28px; align-items:center; font-size:.9rem; color:var(--muted); }
.nav a { transition: color .2s ease; }
.nav a:hover { color:var(--text); }
.menu-toggle { display:none; color:var(--text); background:transparent; border:1px solid var(--line); padding:8px 12px; border-radius:10px; }

.section-pad { width:min(calc(100% - 40px), var(--max)); margin-inline:auto; }
.hero { min-height: calc(100vh - 85px); display:grid; grid-template-columns: 1.05fr .95fr; align-items:center; gap: 50px; padding-top: 80px; padding-bottom: 90px; }
.eyebrow, .kicker, .mini-label, .stack-label { letter-spacing:.14em; font-size:.74rem; text-transform:uppercase; color:var(--muted); }
.eyebrow { display:flex; align-items:center; gap:8px; margin-bottom: 20px; }
.eyebrow > span { width:7px; height:7px; background:var(--accent); border-radius:50%; box-shadow:0 0 16px rgba(183,255,74,.7); }
.hero h1 { font-size: clamp(3.4rem, 6.7vw, 6.2rem); line-height:.98; letter-spacing:-.055em; max-width:800px; margin:0; }
em { font-style:normal; color:var(--accent); }
.hero-lead { max-width:650px; margin: 28px 0 0; font-size:1.08rem; color:var(--muted); }
.hero-actions { display:flex; gap:12px; margin-top:30px; flex-wrap:wrap; }
.btn { display:inline-flex; align-items:center; justify-content:center; gap:10px; min-height:48px; padding:0 18px; border-radius:13px; border:1px solid var(--line); font-weight:750; font-size:.9rem; transition: transform .2s ease, background .2s ease, border-color .2s ease; }
.btn:hover { transform:translateY(-2px); }
.btn-primary { color:#0a0d06; background:var(--accent); border-color:var(--accent); }
.btn-primary:hover { background:var(--accent-2); }
.btn-ghost { background:rgba(255,255,255,.025); }
.btn-ghost:hover { border-color:rgba(255,255,255,.2); background:rgba(255,255,255,.06); }
.hero-meta { display:flex; gap:26px; flex-wrap:wrap; margin-top:48px; padding-top:24px; border-top:1px solid var(--line); }
.hero-meta div { display:flex; flex-direction:column; gap:2px; }
.hero-meta b { font-size:.72rem; color:var(--accent); letter-spacing:.12em; }
.hero-meta span { color:var(--muted); font-size:.77rem; }

.hero-visual { min-height:500px; position:relative; display:grid; place-items:center; }
.core-card { width:min(100%, 475px); border:1px solid rgba(255,255,255,.11); border-radius:24px; background:linear-gradient(150deg, rgba(24,27,37,.95), rgba(8,9,13,.95)); box-shadow:var(--shadow); overflow:hidden; transform: rotate(1.5deg); }
.terminal-top { height:48px; padding:0 16px; display:flex; align-items:center; gap:7px; border-bottom:1px solid var(--line); background:rgba(255,255,255,.015); color:var(--muted); }
.terminal-top > span { width:9px; height:9px; border-radius:50%; background:#353a48; }
.terminal-top code { margin-left:auto; font: 11px/1.2 ui-monospace,SFMono-Regular,Menlo,monospace; opacity:.7; }
.terminal-body { padding:24px 25px 31px; min-height:330px; font: 14px/1.9 ui-monospace,SFMono-Regular,Menlo,monospace; }
.terminal-body p { margin: 0; }
.muted { color:#666d7b; }
.accent { color:var(--accent); }
.status { color:#c7ced8; }
.status .dot, .availability .dot { display:inline-block; width:7px; height:7px; border-radius:50%; background:var(--accent); box-shadow:0 0 13px rgba(183,255,74,.75); margin-right:8px; }
.code-line { color:#d8dce3; }
.cursor { display:inline-block; width:8px; height:15px; background:var(--accent); vertical-align:-2px; animation:blink 1s steps(1) infinite; }
@keyframes blink { 50% { opacity:0; } }
.orbit { position:absolute; border:1px solid rgba(183,255,74,.18); border-radius:50%; }
.orbit-a { width:490px; height:490px; animation:spin 18s linear infinite; }
.orbit-b { width:580px; height:340px; transform:rotate(-28deg); border-color:rgba(255,255,255,.08); animation:spinReverse 24s linear infinite; }
@keyframes spin { to { transform:rotate(360deg); } }
@keyframes spinReverse { to { transform:rotate(-360deg); } }
.floating-tag { position:absolute; padding:7px 11px; border-radius:999px; background:rgba(13,15,21,.84); border:1px solid rgba(255,255,255,.11); backdrop-filter:blur(12px); font-size:.78rem; color:#dfe3e9; box-shadow:0 10px 30px rgba(0,0,0,.28); }
.tag-one { top:15%; right:2%; }
.tag-two { bottom:13%; left:2%; }
.tag-three { top:42%; left:3%; color:#0c0f08; background:var(--accent); border-color:var(--accent); font-weight:800; }

.section { padding-top:110px; padding-bottom:110px; }
.section-dark { width:100%; padding-left:max(20px, calc((100vw - var(--max))/2 + 20px)); padding-right:max(20px, calc((100vw - var(--max))/2 + 20px)); background:linear-gradient(180deg, rgba(255,255,255,.018), rgba(255,255,255,.006)); border-top:1px solid var(--line); border-bottom:1px solid var(--line); }
.section-heading { display:flex; gap:20px; align-items:flex-start; margin-bottom:50px; }
.section-number { font:700 12px/1 ui-monospace,SFMono-Regular,Menlo,monospace; color:var(--accent); padding-top:7px; }
.section-heading .kicker { margin:0 0 9px; }
.section-heading h2 { margin:0; font-size:clamp(2rem,4vw,3.7rem); line-height:1.02; letter-spacing:-.045em; max-width:850px; }
.about-grid { display:grid; grid-template-columns:1.45fr .55fr; gap:30px; align-items:start; }
.about-main { max-width:790px; }
.about-main p { color:var(--muted); font-size:1.02rem; }
.about-main .big-copy { color:var(--text); font-size:clamp(1.2rem,2vw,1.55rem); line-height:1.45; margin-top:0; }
.about-card { border:1px solid var(--line); background:var(--panel); border-radius:var(--radius); padding:25px; box-shadow:var(--shadow); }
.about-card strong { display:block; font-size:1.4rem; line-height:1.2; margin:10px 0 22px; }
.availability { color:var(--muted); font-size:.8rem; }

.projects-grid { display:grid; grid-template-columns:repeat(12,1fr); gap:16px; }
.project-card { position:relative; min-height:305px; padding:26px; border:1px solid var(--line); border-radius:var(--radius); background:linear-gradient(145deg, rgba(255,255,255,.03), rgba(255,255,255,.012)); overflow:hidden; transition:transform .25s ease,border-color .25s ease,background .25s ease; }
.project-card:hover { transform:translateY(-5px); border-color:rgba(183,255,74,.25); background:linear-gradient(145deg, rgba(183,255,74,.055), rgba(255,255,255,.015)); }
.project-card:nth-child(1), .project-card:nth-child(4), .project-card:nth-child(6) { grid-column:span 7; }
.project-card:nth-child(2), .project-card:nth-child(3), .project-card:nth-child(5) { grid-column:span 5; }
.project-index { color:#666d7b; font:700 .73rem ui-monospace,SFMono-Regular,Menlo,monospace; }
.project-icon { position:absolute; top:19px; right:19px; width:54px; height:54px; border:1px solid var(--line); border-radius:15px; display:grid; place-items:center; color:var(--accent); background:rgba(255,255,255,.025); box-shadow:inset 0 0 18px rgba(255,255,255,.02); }
.project-icon svg { width:30px; height:30px; display:block; filter:drop-shadow(0 0 8px rgba(183,255,74,.2)); }
.project-card h3 { margin:55px 0 9px; font-size:1.65rem; letter-spacing:-.025em; }
.project-card p { margin:0; color:var(--muted); max-width:650px; font-size:.9rem; }
.project-tags { display:flex; flex-wrap:wrap; gap:8px; margin-top:19px; }
.project-tags span { font-size:.7rem; padding:5px 8px; border-radius:7px; background:rgba(255,255,255,.04); border:1px solid rgba(255,255,255,.07); color:#c2c8d2; }
.project-link { position:absolute; right:23px; bottom:22px; color:var(--accent); font-size:.8rem; font-weight:800; }

.stack-wrap { display:grid; gap:18px; }
.stack-column { padding:24px 0; border-top:1px solid var(--line); display:grid; grid-template-columns:220px 1fr; gap:24px; align-items:start; }
.stack-label { padding-top:5px; }
.chips { display:flex; flex-wrap:wrap; gap:9px; }
.chips span { border:1px solid var(--line); background:rgba(255,255,255,.02); padding:9px 13px; border-radius:11px; color:#d6dae1; font-size:.86rem; }

.contact { padding-top:80px; padding-bottom:80px; }
.contact-card { max-width:var(--max); margin-inline:auto; border:1px solid rgba(183,255,74,.17); border-radius:28px; padding:42px; display:flex; justify-content:space-between; align-items:flex-end; gap:40px; background:radial-gradient(circle at 83% 25%, rgba(183,255,74,.1), transparent 30%), rgba(255,255,255,.018); }
.contact-card h2 { margin:8px 0 13px; font-size:clamp(2.7rem,5.8vw,5.3rem); line-height:.95; letter-spacing:-.05em; }
.contact-card p:last-child { margin:0; max-width:630px; color:var(--muted); }
.contact-actions { display:flex; gap:10px; flex-wrap:wrap; }
.footer { width:min(calc(100% - 40px),var(--max)); margin-inline:auto; padding:24px 0 34px; display:flex; justify-content:space-between; gap:20px; color:#6e7582; font-size:.73rem; letter-spacing:.09em; text-transform:uppercase; }

.reveal { opacity:0; transform:translateY(18px); animation:reveal .8s ease forwards; }
.reveal-delay { animation-delay:.12s; }
@keyframes reveal { to { opacity:1; transform:none; } }

@media (max-width: 980px) {
  .hero { grid-template-columns:1fr; padding-top:70px; }
  .hero-visual { min-height:420px; }
  .about-grid { grid-template-columns:1fr; }
  .project-card:nth-child(1), .project-card:nth-child(2), .project-card:nth-child(3), .project-card:nth-child(4) { grid-column:span 12; }
  .contact-card { flex-direction:column; align-items:flex-start; }
}

@media (max-width: 700px) {
  .site-header { width:calc(100% - 20px); margin:10px auto 0; padding:10px 10px 10px 12px; border-radius:16px; }
  .brand { gap:8px; font-size:.72rem; letter-spacing:.13em; }
  .brand-mark { width:30px; height:30px; border-radius:9px; }
  .menu-toggle { display:block; min-height:38px; padding:7px 11px; font-size:.82rem; }
  .nav { position:absolute; top:calc(100% + 8px); left:0; right:0; display:none; flex-direction:column; align-items:stretch; gap:2px; padding:8px; background:rgba(8,9,13,.97); border:1px solid var(--line); border-radius:16px; box-shadow:0 18px 45px rgba(0,0,0,.45); }
  .nav.open { display:flex; }
  .nav a { padding:12px; border-radius:10px; }

  .section-pad { width:calc(100% - 28px); }
  .hero { min-height:auto; padding-top:58px; padding-bottom:65px; gap:28px; }
  .eyebrow { margin-bottom:15px; font-size:.66rem; }
  .hero h1 { font-size:clamp(2.75rem,14vw,4rem); line-height:.97; }
  .hero-lead { margin-top:20px; font-size:.96rem; line-height:1.55; }
  .hero-actions { margin-top:24px; }
  .hero-actions .btn { flex:1 1 140px; }
  .hero-meta { display:grid; grid-template-columns:repeat(3,1fr); gap:12px; margin-top:34px; padding-top:19px; }
  .hero-meta b { font-size:.64rem; }
  .hero-meta span { font-size:.66rem; line-height:1.35; }

  .hero-visual { min-height:315px; width:100%; overflow:hidden; }
  .core-card { width:100%; max-width:430px; transform:none; border-radius:20px; }
  .terminal-top { height:42px; padding:0 12px; }
  .terminal-top code { font-size:9px; }
  .terminal-body { min-height:245px; padding:18px 18px 23px; font-size:11px; line-height:1.8; }
  .orbit-a { width:300px; height:300px; }
  .orbit-b { width:350px; height:220px; }
  .floating-tag { display:none; }

  .section { padding-top:68px; padding-bottom:68px; }
  .section-dark { padding-left:14px; padding-right:14px; }
  .section-heading { gap:12px; margin-bottom:28px; }
  .section-number { font-size:10px; padding-top:5px; }
  .section-heading h2 { font-size:clamp(1.85rem,9vw,2.7rem); }
  .about-main .big-copy { font-size:1.1rem; }
  .about-main p { font-size:.93rem; }
  .about-card { padding:20px; border-radius:18px; }

  .projects-grid { grid-template-columns:1fr; gap:12px; }
  .project-card, .project-card:nth-child(1), .project-card:nth-child(2), .project-card:nth-child(3), .project-card:nth-child(4), .project-card:nth-child(5), .project-card:nth-child(6) {
    grid-column:1 / -1; min-height:0; padding:22px 20px 62px; border-radius:18px;
  }
  .project-icon { width:48px; height:48px; top:16px; right:16px; border-radius:13px; }
  .project-icon svg { width:26px; height:26px; }
  .project-card h3 { margin:45px 62px 9px 0; font-size:1.35rem; }
  .project-card p { font-size:.84rem; line-height:1.55; }
  .project-tags { margin-top:15px; gap:6px; padding-right:5px; }
  .project-tags span { font-size:.65rem; padding:5px 7px; }
  .project-link { right:20px; bottom:19px; font-size:.76rem; }

  .stack-column { grid-template-columns:1fr; gap:12px; padding:20px 0; }
  .chips { gap:7px; }
  .chips span { padding:8px 10px; font-size:.76rem; }

  .contact { padding-top:60px; padding-bottom:60px; }
  .contact-card { padding:27px 21px; border-radius:20px; gap:25px; }
  .contact-card h2 { font-size:clamp(2.4rem,13vw,3.5rem); }
  .contact-card p:last-child { font-size:.9rem; }
  .contact-actions { width:100%; }
  .contact-actions .btn { flex:1; min-width:0; }

  .footer { width:calc(100% - 28px); flex-direction:column; gap:7px; padding-bottom:25px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior:auto; }
  *, *::before, *::after { animation-duration:.01ms !important; animation-iteration-count:1 !important; transition-duration:.01ms !important; }
}

/* Project details modal */
body.modal-open { overflow:hidden; }
.project-link { appearance:none; border:0; background:none; padding:0; font:inherit; cursor:pointer; }
.project-modal { position:fixed; inset:0; z-index:1000; display:grid; place-items:center; padding:22px; opacity:0; visibility:hidden; pointer-events:none; transition:opacity .22s ease, visibility .22s ease; }
.project-modal.open { opacity:1; visibility:visible; pointer-events:auto; }
.project-modal-backdrop { position:absolute; inset:0; background:rgba(2,3,7,.72); backdrop-filter:blur(12px); }
.project-modal-card { position:relative; width:min(900px, 100%); max-height:min(86vh, 780px); overflow:auto; border:1px solid rgba(183,255,74,.18); border-radius:28px; padding:34px; background:linear-gradient(145deg, rgba(21,24,33,.98), rgba(8,9,13,.98)); box-shadow:0 30px 100px rgba(0,0,0,.5); transform:translateY(18px) scale(.985); transition:transform .25s ease; }
.project-modal.open .project-modal-card { transform:none; }
.modal-close { position:absolute; top:18px; right:18px; width:42px; height:42px; border:1px solid var(--line); border-radius:12px; background:rgba(255,255,255,.04); color:var(--text); font-size:1.7rem; line-height:1; cursor:pointer; }
.modal-close:hover { border-color:rgba(183,255,74,.3); background:rgba(183,255,74,.08); }
.modal-project-icon { width:72px; height:72px; border:1px solid rgba(183,255,74,.2); border-radius:18px; display:grid; place-items:center; color:var(--accent); background:rgba(183,255,74,.04); margin-bottom:24px; }
.modal-project-icon svg { width:40px; height:40px; }
.project-modal-card .kicker { margin:0 0 9px; }
.project-modal-card h2 { margin:0; padding-right:54px; font-size:clamp(2.2rem,5vw,4rem); line-height:1; letter-spacing:-.045em; }
.modal-description { max-width:780px; margin:20px 0 0; color:var(--muted); font-size:1rem; line-height:1.7; }
.modal-columns { display:grid; grid-template-columns:1.2fr .8fr; gap:32px; margin-top:30px; padding-top:26px; border-top:1px solid var(--line); }
.modal-columns > div { min-width:0; }
.modal-list { margin:15px 0 0; padding-left:20px; color:#cfd4dc; }
.modal-list li { margin:9px 0; padding-left:4px; }
.modal-chips { margin-top:15px; }
.modal-actions { display:flex; gap:10px; flex-wrap:wrap; margin-top:32px; }
.project-modal .btn { cursor:pointer; }
.project-modal .btn-ghost { color:#9da4b3; }
.project-modal .btn.is-disabled { opacity:.45; cursor:default; pointer-events:none; }
@media (max-width:700px) {
  .project-modal { padding:10px; }
  .project-modal-card { padding:24px 20px; border-radius:22px; max-height:90vh; }
  .modal-columns { grid-template-columns:1fr; gap:25px; }
  .modal-project-icon { width:62px; height:62px; }
  .modal-project-icon svg { width:34px; height:34px; }
}
