/* ============ Towfeeque Aalam — portfolio ============ */
:root {
  --bg: #060b14;
  --bg-2: #0a1220;
  --panel: rgba(148, 190, 255, 0.045);
  --panel-border: rgba(148, 190, 255, 0.10);
  --ink: #e6edf7;
  --ink-dim: #93a1b5;
  --cyan: #22d3ee;
  --violet: #818cf8;
  --teal: #2dd4bf;
  --grad: linear-gradient(100deg, var(--cyan), var(--teal) 55%, var(--violet));
  --font-head: "Sora", system-ui, sans-serif;
  --font-body: "Inter", system-ui, sans-serif;
  --font-mono: "JetBrains Mono", ui-monospace, monospace;
  --maxw: 1100px;
}

* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.6;
  overflow-x: hidden;
}
.mono { font-family: var(--font-mono); }
h1, h2, h3 { font-family: var(--font-head); }

/* backdrop layers */
#net {
  position: fixed; inset: 0; z-index: -2;
  width: 100%; height: 100%;
}
.aurora {
  position: fixed; inset: 0; z-index: -1; pointer-events: none;
  background:
    radial-gradient(55% 45% at 78% -8%, rgba(34, 211, 238, 0.10), transparent 60%),
    radial-gradient(45% 40% at 8% 28%, rgba(129, 140, 248, 0.09), transparent 60%),
    radial-gradient(50% 45% at 88% 78%, rgba(45, 212, 191, 0.06), transparent 60%);
}

.grad {
  background: var(--grad);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

/* ============ nav ============ */
.nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 50;
  display: flex; align-items: center; justify-content: space-between;
  padding: 14px clamp(20px, 5vw, 56px);
  transition: background .3s, backdrop-filter .3s, border-color .3s;
  border-bottom: 1px solid transparent;
}
.nav.scrolled {
  background: rgba(6, 11, 20, 0.75);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom-color: var(--panel-border);
}
.nav-logo {
  font-family: var(--font-head); font-weight: 800; font-size: 22px;
  color: var(--ink); text-decoration: none; letter-spacing: 0.5px;
}
.nav-logo span { color: var(--cyan); }
.nav-links { display: flex; gap: 26px; }
.nav-links a {
  color: var(--ink-dim); text-decoration: none; font-size: 14px; font-weight: 500;
  transition: color .2s;
}
.nav-links a:hover { color: var(--cyan); }

/* ============ buttons ============ */
.btn {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 12px 22px; border-radius: 10px;
  font-family: var(--font-body); font-weight: 600; font-size: 14.5px;
  text-decoration: none; cursor: pointer; border: 1px solid transparent;
  transition: transform .15s, box-shadow .25s, background .25s, border-color .25s;
}
.btn-solid {
  background: var(--grad); color: #04121a;
  box-shadow: 0 4px 24px rgba(34, 211, 238, 0.25);
}
.btn-solid:hover { transform: translateY(-2px); box-shadow: 0 8px 32px rgba(34, 211, 238, 0.40); }
.btn-ghost {
  color: var(--ink); border-color: var(--panel-border);
  background: var(--panel);
}
.btn-ghost:hover { border-color: var(--cyan); color: var(--cyan); transform: translateY(-2px); }
.btn-icon {
  padding: 12px; color: var(--ink-dim); border-color: var(--panel-border); background: var(--panel);
}
.btn-icon:hover { color: var(--cyan); border-color: var(--cyan); transform: translateY(-2px); }
.btn-sm { padding: 8px 16px; font-size: 13px; border-radius: 8px; }
.btn-lg { padding: 15px 30px; font-size: 16px; }

/* ============ hero ============ */
.hero {
  min-height: 100svh;
  display: flex; flex-direction: column; justify-content: center;
  padding: 110px clamp(20px, 5vw, 56px) 40px;
  position: relative;
}
.hero-inner {
  max-width: var(--maxw); margin: 0 auto; width: 100%;
  display: grid; grid-template-columns: 1.5fr 1fr; gap: 48px; align-items: center;
}
.hero-eyebrow {
  display: inline-flex; align-items: center; gap: 10px;
  font-size: 13.5px; color: var(--teal); font-weight: 500;
  border: 1px solid rgba(45, 212, 191, 0.25); border-radius: 100px;
  padding: 7px 16px; background: rgba(45, 212, 191, 0.06);
  margin-bottom: 26px;
}
.pulse-dot {
  width: 8px; height: 8px; border-radius: 50%; background: var(--teal);
  box-shadow: 0 0 0 0 rgba(45, 212, 191, 0.6);
  animation: pulse 2s infinite;
}
@keyframes pulse {
  0% { box-shadow: 0 0 0 0 rgba(45, 212, 191, 0.55); }
  70% { box-shadow: 0 0 0 9px rgba(45, 212, 191, 0); }
  100% { box-shadow: 0 0 0 0 rgba(45, 212, 191, 0); }
}
.hero h1 {
  font-size: clamp(52px, 8.5vw, 96px);
  line-height: 1.02; font-weight: 800; letter-spacing: -2px;
}
.hero-role {
  margin-top: 18px; font-size: clamp(17px, 2.2vw, 21px);
  font-weight: 600; color: var(--ink);
}
.hero-type {
  margin-top: 8px; font-family: var(--font-mono);
  font-size: clamp(13px, 1.8vw, 15.5px); color: var(--cyan); min-height: 24px;
}
.caret {
  display: inline-block; width: 9px; height: 17px; margin-left: 3px;
  background: var(--cyan); vertical-align: text-bottom;
  animation: blink 1s step-end infinite;
}
@keyframes blink { 50% { opacity: 0; } }
.hero-bio {
  margin-top: 22px; max-width: 540px;
  color: var(--ink-dim); font-size: 16.5px;
}
.hero-bio strong { color: var(--ink); }
.hero-cta { margin-top: 34px; display: flex; gap: 14px; flex-wrap: wrap; align-items: center; }

/* portrait */
.hero-portrait { position: relative; justify-self: center; }
.portrait-ring {
  width: clamp(210px, 24vw, 280px); height: clamp(210px, 24vw, 280px);
  border-radius: 50%; padding: 5px;
  background: conic-gradient(from 0deg, var(--cyan), var(--violet), var(--teal), var(--cyan));
  animation: spin 9s linear infinite;
  box-shadow: 0 0 70px rgba(34, 211, 238, 0.22), 0 0 140px rgba(129, 140, 248, 0.12);
}
.portrait-ring img {
  width: 100%; height: 100%; border-radius: 50%; object-fit: cover;
  border: 5px solid var(--bg); display: block;
  animation: spin 9s linear infinite reverse;
}
@keyframes spin { to { transform: rotate(360deg); } }
.portrait-chip {
  position: absolute; padding: 7px 14px; border-radius: 100px;
  font-size: 12px; color: var(--ink);
  background: rgba(10, 18, 32, 0.85); border: 1px solid var(--panel-border);
  backdrop-filter: blur(8px); white-space: nowrap;
  animation: floaty 5s ease-in-out infinite;
}
.chip-a { top: 4%; right: -8%; color: var(--cyan); border-color: rgba(34,211,238,.3); }
.chip-b { bottom: 12%; left: -14%; color: var(--violet); border-color: rgba(129,140,248,.3); animation-delay: -1.8s; }
.chip-c { bottom: -4%; right: 2%; color: var(--teal); border-color: rgba(45,212,191,.3); animation-delay: -3.2s; }
@keyframes floaty { 50% { transform: translateY(-9px); } }

/* ============ explore (what's inside) ============ */
.explore { max-width: var(--maxw); margin: 46px auto 0; width: 100%; }
.explore-title { font-size: 12px; color: var(--ink-dim); margin-bottom: 14px; }
.explore-grid { display: grid; grid-template-columns: repeat(6, 1fr); gap: 12px; }
.explore-card {
  display: flex; flex-direction: column; gap: 4px;
  padding: 14px 16px; border-radius: 12px; text-decoration: none;
  background: var(--panel); border: 1px solid var(--panel-border);
  transition: transform .18s, border-color .2s, background .2s;
}
.explore-card:hover { transform: translateY(-3px); border-color: var(--cyan); background: rgba(34, 211, 238, 0.07); }
.explore-card strong { font-family: var(--font-head); font-size: 14.5px; font-weight: 700; color: var(--cyan); }
.explore-card span { font-size: 11.5px; color: var(--ink-dim); line-height: 1.45; }

/* ============ stats ============ */
.stats {
  max-width: var(--maxw); margin: 0 auto;
  padding: 24px clamp(20px, 5vw, 56px);
  display: grid; grid-template-columns: repeat(5, 1fr); gap: 18px;
  border-top: 1px solid var(--panel-border);
  border-bottom: 1px solid var(--panel-border);
}
.stat { text-align: center; padding: 10px 4px; }
.stat-num {
  font-family: var(--font-head); font-weight: 800;
  font-size: clamp(30px, 4vw, 44px); letter-spacing: -1px;
  background: var(--grad); -webkit-background-clip: text; background-clip: text; color: transparent;
}
.stat-num em { font-style: normal; font-size: 0.55em; }
.stat p { font-size: 12.5px; color: var(--ink-dim); margin-top: 4px; }

/* ============ logo band ============ */
.logo-band {
  max-width: var(--maxw); margin: 0 auto;
  padding: 36px clamp(20px, 5vw, 56px) 6px;
}
.logo-band-title {
  text-align: center; font-size: 12.5px; color: var(--ink-dim);
  margin-bottom: 30px; letter-spacing: 0.5px;
}
.logo-groups { display: flex; flex-direction: column; gap: 8px; }
.logo-group {
  display: grid; grid-template-columns: 280px 1fr; gap: 18px; align-items: center;
  padding: 10px 0; border-bottom: 1px solid rgba(148, 190, 255, 0.06);
}
.logo-group:last-child { border-bottom: none; }
.logo-group-label {
  font-size: 11px; color: var(--ink-dim); letter-spacing: 0.6px;
  text-align: right; line-height: 1.5;
}
.logo-row { display: flex; flex-wrap: wrap; gap: 4px 6px; }
.logo-cell {
  display: flex; flex-direction: column; align-items: center; gap: 7px;
  color: #5a6778; min-width: 92px;
  padding: 10px 8px; border-radius: 12px;
  transition: color .25s, background .25s, transform .2s;
}
.logo-cell svg { width: 30px; height: 30px; }
.logo-cell svg text { font-family: var(--font-mono); }
.logo-cell span { font-family: var(--font-mono); font-size: 10px; letter-spacing: 0.3px; text-align: center; }
.logo-cell:hover { color: var(--cyan); background: var(--panel); transform: translateY(-3px); }
.fw-row { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; }
.fw-pill {
  font-family: var(--font-mono); font-size: 12px; color: #5a6778;
  border: 1.5px solid rgba(90, 103, 120, 0.5); border-radius: 8px;
  padding: 9px 18px; letter-spacing: 1px;
  transition: color .25s, border-color .25s;
}
.fw-pill:hover { color: var(--cyan); border-color: var(--cyan); }

/* ============ sections ============ */
.section {
  max-width: var(--maxw); margin: 0 auto;
  padding: clamp(52px, 8vh, 80px) clamp(20px, 5vw, 56px) 16px;
}
.section-eyebrow { color: var(--cyan); font-size: 13.5px; margin-bottom: 10px; }
.section h2 {
  font-size: clamp(28px, 4.2vw, 44px); font-weight: 800;
  letter-spacing: -1.2px; line-height: 1.1; margin-bottom: 28px;
}

/* ============ now card ============ */
.now-card {
  background: linear-gradient(160deg, rgba(34, 211, 238, 0.06), rgba(129, 140, 248, 0.05));
  border: 1px solid rgba(34, 211, 238, 0.18);
  border-radius: 20px; padding: clamp(24px, 4vw, 42px);
  box-shadow: 0 20px 60px rgba(3, 8, 16, 0.5);
}
.now-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 18px; flex-wrap: wrap; margin-bottom: 28px; }
.now-head h3 { font-size: clamp(22px, 3vw, 30px); font-weight: 700; }
.now-role { color: var(--ink-dim); font-size: 14.5px; margin-top: 4px; }
.live-badge {
  display: inline-flex; align-items: center; gap: 9px;
  font-size: 12.5px; font-weight: 600; color: var(--teal);
  border: 1px solid rgba(45, 212, 191, 0.3); border-radius: 100px;
  padding: 7px 15px; background: rgba(45, 212, 191, 0.07);
}
.now-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.now-item {
  background: rgba(6, 11, 20, 0.45); border: 1px solid var(--panel-border);
  border-radius: 14px; padding: 22px;
  transition: transform .2s, border-color .25s;
}
.now-item:hover { transform: translateY(-4px); border-color: rgba(34, 211, 238, 0.35); }
.now-item h4 { font-family: var(--font-head); font-size: 16px; margin-bottom: 9px; color: var(--cyan); }
.now-item p { font-size: 14px; color: var(--ink-dim); }

/* ============ timeline ============ */
.timeline { position: relative; padding-left: 34px; }
.timeline::before {
  content: ""; position: absolute; left: 8px; top: 6px; bottom: 6px; width: 2px;
  background: linear-gradient(to bottom, var(--cyan), rgba(129, 140, 248, 0.35), rgba(148, 190, 255, 0.08));
}
.t-item { position: relative; margin-bottom: 16px; }
.t-marker {
  position: absolute; left: -34px; top: 26px;
  width: 18px; height: 18px; border-radius: 50%;
  background: var(--bg); border: 3px solid var(--violet);
}
.t-marker.current { border-color: var(--teal); box-shadow: 0 0 16px rgba(45, 212, 191, 0.55); }
.t-marker.aws { border-color: #ff9900; }
.t-card {
  background: var(--panel); border: 1px solid var(--panel-border);
  border-radius: 16px; padding: 26px 28px;
  transition: transform .2s, border-color .25s, background .25s;
}
.t-card:hover { transform: translateX(6px); border-color: rgba(34, 211, 238, 0.3); background: rgba(148, 190, 255, 0.07); }
.t-head { display: flex; justify-content: space-between; align-items: baseline; gap: 14px; flex-wrap: wrap; }
.t-head h3 { font-size: 20px; font-weight: 700; }
.t-date { font-size: 12.5px; color: var(--cyan); }
.t-role { color: var(--violet); font-weight: 600; font-size: 14.5px; margin: 4px 0 10px; }
.t-card > p:not(.t-role) { color: var(--ink-dim); font-size: 14.5px; }

.tags { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 14px; }
.tags span {
  font-family: var(--font-mono); font-size: 11.5px; color: var(--ink-dim);
  border: 1px solid var(--panel-border); border-radius: 6px; padding: 4px 10px;
  background: rgba(6, 11, 20, 0.4);
}

/* ============ projects ============ */
.proj-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.proj-card {
  background: var(--panel); border: 1px solid var(--panel-border);
  border-radius: 16px; padding: 28px;
  transition: transform .2s, border-color .25s, box-shadow .25s;
  position: relative; overflow: hidden;
}
.proj-card::after {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background: radial-gradient(400px 200px at var(--mx, 50%) var(--my, 0%), rgba(34, 211, 238, 0.08), transparent 65%);
  opacity: 0; transition: opacity .3s;
}
.proj-card:hover::after { opacity: 1; }
.proj-card:hover { transform: translateY(-5px); border-color: rgba(34, 211, 238, 0.3); box-shadow: 0 18px 44px rgba(3, 8, 16, 0.55); }
.proj-card.featured { grid-column: span 2; }
.proj-metric {
  font-family: var(--font-head); font-weight: 800;
  font-size: clamp(30px, 3.6vw, 42px); letter-spacing: -1px; display: block; margin-bottom: 12px;
}
.proj-card h3 { font-size: 17px; font-weight: 700; margin-bottom: 9px; line-height: 1.35; }
.proj-card p { font-size: 14px; color: var(--ink-dim); }

/* ============ expertise ============ */
.skill-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.skill-card {
  background: var(--panel); border: 1px solid var(--panel-border);
  border-radius: 16px; padding: 24px;
  transition: transform .2s, border-color .25s;
}
.skill-card:hover { transform: translateY(-4px); border-color: rgba(129, 140, 248, 0.35); }
.skill-card h4 { font-family: var(--font-head); font-size: 15.5px; margin-bottom: 14px; display: flex; align-items: center; gap: 9px; }
.skill-ico { color: var(--cyan); font-size: 17px; }

.certs { margin-top: 34px; }
.certs h3 { font-size: 20px; font-weight: 700; margin-bottom: 18px; }
.cert-row { display: flex; flex-wrap: wrap; gap: 10px; }
.cert {
  font-size: 13px; font-weight: 500; color: var(--ink);
  border: 1px solid rgba(45, 212, 191, 0.25); border-radius: 100px;
  padding: 9px 18px; background: rgba(45, 212, 191, 0.05);
  transition: border-color .2s, background .2s;
}
.cert:hover { border-color: var(--teal); background: rgba(45, 212, 191, 0.11); }

/* ============ case studies ============ */
.case { margin-top: 16px; border-top: 1px solid var(--panel-border); padding-top: 12px; }
.case summary {
  cursor: pointer; list-style: none;
  font-family: var(--font-mono); font-size: 12.5px; color: var(--cyan);
  display: flex; align-items: center; gap: 8px;
  transition: color .2s;
}
.case summary::-webkit-details-marker { display: none; }
.case summary::before { content: "+"; font-size: 15px; transition: transform .25s; }
.case[open] summary::before { transform: rotate(45deg); }
.case summary:hover { color: var(--teal); }
.case-body { padding-top: 12px; }
.case-body p { font-size: 13.5px; color: var(--ink-dim); margin-bottom: 8px; }
.case-body b { color: var(--ink); font-weight: 600; }

/* ============ testimonials ============ */
.quote-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }
.quote-card {
  background: var(--panel); border: 1px solid var(--panel-border);
  border-radius: 16px; padding: 30px 30px 26px; position: relative;
  transition: transform .2s, border-color .25s;
}
.quote-card:hover { transform: translateY(-4px); border-color: rgba(45, 212, 191, 0.35); }
.quote-mark {
  font-family: var(--font-head); font-size: 58px; font-weight: 800;
  line-height: 0.6; margin-bottom: 16px; display: block;
}
.quote-card blockquote { font-size: 15px; color: var(--ink); line-height: 1.65; font-style: italic; }
.quote-card figcaption { margin-top: 18px; font-weight: 600; font-size: 14px; color: var(--teal); }
.quote-card figcaption span { color: var(--ink-dim); font-weight: 400; font-size: 12.5px; }
.quote-more { margin-top: 26px; }
.quote-more a { color: var(--ink-dim); font-size: 14px; text-decoration: none; transition: color .2s; }
.quote-more a:hover { color: var(--cyan); }

/* ============ insights ============ */
.insight-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.insight-card {
  background: var(--panel); border: 1px solid var(--panel-border);
  border-radius: 16px; padding: 28px;
  transition: transform .2s, border-color .25s;
}
.insight-card:hover { transform: translateY(-5px); border-color: rgba(129, 140, 248, 0.4); }
.insight-tag {
  font-size: 11px; color: var(--violet); text-transform: uppercase; letter-spacing: 1.5px;
  display: inline-block; margin-bottom: 14px;
}
.insight-card h3 { font-size: 18px; font-weight: 700; line-height: 1.35; margin-bottom: 12px; }
.insight-card p { font-size: 14px; color: var(--ink-dim); }

/* ============ talks ============ */
.talk-list { display: flex; flex-direction: column; gap: 14px; }
.talk-item {
  display: grid; grid-template-columns: 150px 1fr; gap: 22px; align-items: start;
  background: var(--panel); border: 1px solid var(--panel-border);
  border-radius: 16px; padding: 24px 28px;
  transition: transform .2s, border-color .25s;
}
.talk-item:hover { transform: translateX(6px); border-color: rgba(45, 212, 191, 0.35); }
.talk-year { font-size: 12px; color: var(--teal); padding-top: 4px; white-space: nowrap; }
.talk-body h3 { font-size: 18px; font-weight: 700; line-height: 1.3; }
.talk-venue { color: var(--violet); font-size: 13px; font-weight: 600; margin: 4px 0 8px; }
.talk-body > p:not(.talk-venue) { font-size: 14px; color: var(--ink-dim); }

/* featured cert */
.cert-featured {
  border-color: rgba(129, 140, 248, 0.45);
  background: rgba(129, 140, 248, 0.08);
  color: var(--ink);
}
.cert-featured:hover { border-color: var(--violet); background: rgba(129, 140, 248, 0.14); }

/* ============ white papers ============ */
.paper-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.paper-card {
  border: 1px solid var(--panel-border); border-radius: 16px; overflow: hidden;
  background: var(--panel); display: flex; flex-direction: column;
  transition: transform .2s, border-color .25s, box-shadow .25s;
}
.paper-card:hover { transform: translateY(-5px); border-color: rgba(34, 211, 238, 0.35); box-shadow: 0 18px 44px rgba(3, 8, 16, 0.55); }
.paper-cover {
  background:
    radial-gradient(120% 140% at 85% -20%, rgba(34, 211, 238, 0.16), transparent 55%),
    radial-gradient(100% 120% at 0% 120%, rgba(129, 140, 248, 0.14), transparent 55%),
    #04070d;
  padding: 26px 24px 22px;
  border-bottom: 1px solid var(--panel-border);
}
.paper-label { font-size: 10px; letter-spacing: 2.5px; color: var(--cyan); display: block; margin-bottom: 12px; }
.paper-label::after {
  content: ""; display: block; width: 34px; height: 3px; margin-top: 10px;
  background: var(--grad); border-radius: 2px;
}
.paper-cover h3 { font-size: 21px; font-weight: 800; letter-spacing: -0.4px; line-height: 1.2; }
.paper-body { padding: 20px 24px 22px; display: flex; flex-direction: column; flex: 1; }
.paper-body p { font-size: 13.5px; color: var(--ink-dim); flex: 1; }
.paper-meta {
  display: flex; justify-content: space-between; align-items: center; gap: 10px;
  margin-top: 18px;
}
.paper-meta > span { font-size: 11px; color: var(--ink-dim); }

/* ============ contact form ============ */
.contact-form {
  max-width: 640px; margin: 0 auto 38px; text-align: left;
  background: var(--panel); border: 1px solid var(--panel-border);
  border-radius: 20px; padding: clamp(22px, 4vw, 34px);
}
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.contact-form label {
  display: block; font-size: 13px; font-weight: 600; color: var(--ink-dim);
  margin-bottom: 16px;
}
.contact-form input, .contact-form textarea {
  display: block; width: 100%; margin-top: 7px;
  background: rgba(6, 11, 20, 0.6); border: 1px solid var(--panel-border);
  border-radius: 10px; padding: 12px 14px;
  color: var(--ink); font-family: var(--font-body); font-size: 14.5px;
  transition: border-color .2s, box-shadow .2s;
  resize: vertical;
}
.contact-form input:focus, .contact-form textarea:focus {
  outline: none; border-color: var(--cyan);
  box-shadow: 0 0 0 3px rgba(34, 211, 238, 0.12);
}
.form-actions { display: flex; gap: 14px; flex-wrap: wrap; margin-top: 4px; }
.contact-form button { border: none; }
.form-status { font-size: 12.5px; color: var(--teal); margin-top: 14px; min-height: 18px; }

/* ============ contact ============ */
.contact { text-align: center; padding-bottom: 60px; }
.contact h2 { margin-bottom: 18px; }
.contact-sub { color: var(--ink-dim); max-width: 520px; margin: 0 auto 36px; }
.contact-cta { display: flex; gap: 16px; justify-content: center; flex-wrap: wrap; }
.contact-links { margin-top: 30px; display: flex; gap: 28px; justify-content: center; }
.contact-links a { color: var(--ink-dim); text-decoration: none; font-size: 14.5px; font-weight: 500; transition: color .2s; }
.contact-links a:hover { color: var(--cyan); }

/* ============ footer ============ */
.footer {
  border-top: 1px solid var(--panel-border);
  padding: 28px clamp(20px, 5vw, 56px);
  display: flex; justify-content: space-between; flex-wrap: wrap; gap: 10px;
  color: var(--ink-dim); font-size: 13px;
  max-width: var(--maxw); margin: 40px auto 0;
}
.footer-note { color: rgba(147, 161, 181, 0.55); font-size: 12px; }

/* ============ skip link & focus ============ */
.skip-link {
  position: absolute; left: 16px; top: -60px; z-index: 100;
  background: var(--cyan); color: #04121a; font-weight: 600; font-size: 14px;
  padding: 10px 18px; border-radius: 0 0 10px 10px; text-decoration: none;
  transition: top .2s;
}
.skip-link:focus { top: 0; }
a:focus-visible, button:focus-visible, input:focus-visible, textarea:focus-visible, summary:focus-visible {
  outline: 2px solid var(--cyan); outline-offset: 3px; border-radius: 4px;
}

/* ============ architecture diagram ============ */
.arch-hint { font-size: 12px; color: var(--ink-dim); margin: -14px 0 18px; }
.arch-wrap { position: relative; overflow-x: auto; }
.arch { min-width: 720px; width: 100%; height: auto; display: block; }
.arch .box {
  fill: rgba(148, 190, 255, 0.045); stroke: rgba(148, 190, 255, 0.22);
  stroke-width: 1.2; transition: fill .2s, stroke .2s;
}
.arch .box-container { fill: rgba(148, 190, 255, 0.02); stroke-dasharray: 6 5; }
.arch .box-teal { stroke: rgba(45, 212, 191, 0.45); }
.arch .box-cyan { stroke: rgba(34, 211, 238, 0.5); }
.arch .box-violet { stroke: rgba(129, 140, 248, 0.45); }
.arch text { font-family: var(--font-body); fill: var(--ink); }
.arch .t-title { font-size: 17px; font-weight: 600; font-family: var(--font-head); }
.arch .t-title-sm { font-size: 14.5px; font-weight: 600; font-family: var(--font-head); }
.arch .t-sub { font-size: 12px; fill: var(--ink-dim); font-family: var(--font-mono); }
.arch-flow line {
  stroke: #3d5a7a; stroke-width: 1.4;
  stroke-dasharray: 5 5;
  animation: flow 1.2s linear infinite;
}
@keyframes flow { to { stroke-dashoffset: -20; } }
.anode { cursor: pointer; transition: opacity .35s; }
.anode:hover .box, .anode.active .box { fill: rgba(34, 211, 238, 0.10); stroke: var(--cyan); }

/* scenario states */
.anode.dim { opacity: 0.18; }
.anode.s-hit .box {
  stroke: #f87171; fill: rgba(248, 113, 113, 0.10);
  animation: hitpulse 1.1s ease-in-out infinite;
}
.anode.s-guard .box {
  stroke: var(--teal); fill: rgba(45, 212, 191, 0.12);
  animation: guardpulse 1.6s ease-in-out infinite;
}
@keyframes hitpulse { 50% { fill: rgba(248, 113, 113, 0.22); } }
@keyframes guardpulse { 50% { fill: rgba(45, 212, 191, 0.24); } }

/* scenario bar */
.scenario-bar { display: flex; flex-wrap: wrap; gap: 10px; margin-bottom: 20px; }
.scenario-btn {
  font-size: 12px; padding: 9px 16px; border-radius: 100px; cursor: pointer;
  color: var(--ink-dim); background: var(--panel);
  border: 1px solid var(--panel-border);
  transition: color .2s, border-color .2s, background .2s;
}
.scenario-btn:hover { color: var(--cyan); border-color: rgba(34, 211, 238, 0.45); }
.scenario-btn.running {
  color: var(--teal); border-color: var(--teal);
  background: rgba(45, 212, 191, 0.08);
}

/* scenario caption */
.arch-caption {
  min-height: 26px; margin-top: 14px;
  font-size: 13px; color: var(--ink);
}
.arch-caption.verdict { color: var(--teal); }

/* insight panel */
.arch-panel {
  margin-top: 14px; border: 1px solid var(--panel-border);
  border-radius: 16px; background: var(--panel);
  padding: 22px 26px; min-height: 96px;
}
.arch-panel-empty { font-size: 12.5px; color: var(--ink-dim); }
.arch-panel-body h3 {
  font-size: 18px; font-weight: 700; margin-bottom: 14px;
  background: var(--grad); -webkit-background-clip: text; background-clip: text; color: transparent;
  display: inline-block;
}
.arch-panel-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; }
.arch-panel-label {
  display: block; font-size: 10.5px; letter-spacing: 1.5px; text-transform: uppercase;
  color: var(--cyan); margin-bottom: 7px;
}
.arch-panel-grid p { font-size: 13.5px; color: var(--ink-dim); line-height: 1.6; }

/* ============ services ============ */
.svc-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.svc-card {
  background: var(--panel); border: 1px solid var(--panel-border);
  border-radius: 16px; padding: 30px 28px;
  display: flex; flex-direction: column;
  transition: transform .2s, border-color .25s;
}
.svc-card:hover { transform: translateY(-5px); border-color: rgba(45, 212, 191, 0.4); }
.svc-num { font-family: var(--font-head); font-weight: 800; font-size: 30px; margin-bottom: 14px; }
.svc-card h3 { font-size: 19px; font-weight: 700; line-height: 1.3; margin-bottom: 10px; }
.svc-card p { font-size: 14px; color: var(--ink-dim); flex: 1; }
.svc-card a {
  margin-top: 18px; color: var(--cyan); font-weight: 600; font-size: 14px;
  text-decoration: none;
}
.svc-card a:hover { color: var(--teal); }

/* ============ proof band ============ */
.proof-band {
  max-width: var(--maxw); margin: 30px auto 0; text-align: center;
  padding: 0 clamp(20px, 5vw, 56px);
}
.proof-title { font-size: 12px; color: var(--ink-dim); margin-bottom: 16px; }
.proof-row { display: flex; flex-wrap: wrap; gap: 10px; justify-content: center; }
.proof {
  font-family: var(--font-mono); font-size: 11.5px; color: var(--teal);
  border: 1px solid rgba(45, 212, 191, 0.28); border-radius: 100px;
  padding: 7px 14px; background: rgba(45, 212, 191, 0.05);
}

/* ============ hidden terminal ============ */
.term {
  position: fixed; top: 0; left: 50%; transform: translate(-50%, -105%);
  width: min(720px, 94vw); max-height: 62vh; z-index: 200;
  display: flex; flex-direction: column;
  background: rgba(4, 8, 15, 0.97); border: 1px solid rgba(34, 211, 238, 0.35);
  border-top: none; border-radius: 0 0 14px 14px;
  box-shadow: 0 30px 80px rgba(2, 6, 12, 0.8), 0 0 40px rgba(34, 211, 238, 0.08);
  transition: transform .28s ease;
}
.term.open { transform: translate(-50%, 0); }
.term-bar {
  display: flex; align-items: center; gap: 12px;
  padding: 10px 14px; border-bottom: 1px solid rgba(148, 190, 255, 0.12);
}
.term-dots { display: flex; gap: 6px; }
.term-dots i { width: 11px; height: 11px; border-radius: 50%; background: #2a3648; }
.term-dots i:first-child { background: rgba(255, 95, 87, 0.7); }
.term-dots i:nth-child(2) { background: rgba(255, 189, 46, 0.7); }
.term-dots i:nth-child(3) { background: rgba(40, 201, 64, 0.7); }
.term-title { flex: 1; font-size: 11.5px; color: var(--ink-dim); text-align: center; }
.term-close {
  background: none; border: none; color: var(--ink-dim); font-size: 18px;
  cursor: pointer; line-height: 1; padding: 2px 6px;
}
.term-close:hover { color: var(--cyan); }
.term-out {
  flex: 1; overflow-y: auto; padding: 14px 16px 6px;
  font-size: 13px; line-height: 1.6; min-height: 120px;
}
.term-out div { white-space: pre-wrap; word-break: break-word; }
.term-out .t-cmd { color: var(--ink); }
.term-out .t-res { color: var(--ink-dim); }
.term-out .t-ok { color: var(--teal); }
.term-out .t-err { color: #f87171; }
.term-out .t-accent { color: var(--cyan); }
.term-line {
  display: flex; align-items: center; gap: 10px;
  padding: 8px 16px 14px;
}
.term-prompt { color: var(--teal); font-size: 13px; white-space: nowrap; }
.term-line input {
  flex: 1; background: none; border: none; outline: none;
  color: var(--ink); font-family: var(--font-mono); font-size: 13px;
  caret-color: var(--cyan);
}
kbd {
  font-family: var(--font-mono); font-size: 11px; color: var(--cyan);
  border: 1px solid rgba(34, 211, 238, 0.3); border-radius: 4px;
  padding: 1px 5px; background: rgba(34, 211, 238, 0.06);
}
.term-hint {
  background: none; border: none; padding: 0; cursor: pointer;
  font-size: 12px; color: rgba(147, 161, 181, 0.55);
  transition: color .2s;
}
.term-hint:hover { color: var(--cyan); }
.term-hint:hover kbd { border-color: var(--cyan); }

/* hero terminal button */
.btn-term {
  color: var(--cyan); border-color: rgba(34, 211, 238, 0.4);
  font-family: var(--font-mono); font-size: 13.5px;
}
.btn-term:hover { border-color: var(--cyan); background: rgba(34, 211, 238, 0.08); }
.term-caret {
  display: inline-block; width: 8px; height: 15px; margin-left: 6px;
  background: var(--cyan); vertical-align: text-bottom;
  animation: blink 1s step-end infinite;
}

/* floating terminal button */
.term-fab {
  position: fixed; right: 22px; bottom: 22px; z-index: 90;
  width: 54px; height: 54px; border-radius: 14px; cursor: pointer;
  background: rgba(6, 11, 20, 0.92); color: var(--cyan);
  border: 1px solid rgba(34, 211, 238, 0.5);
  font-size: 18px; font-weight: 500; line-height: 1;
  box-shadow: 0 8px 30px rgba(3, 8, 16, 0.6), 0 0 0 0 rgba(34, 211, 238, 0.35);
  animation: fab-pulse 2.6s ease-out infinite;
  transition: transform .18s, background .2s, border-color .2s;
}
.term-fab:hover {
  transform: translateY(-3px); background: rgba(34, 211, 238, 0.12);
  border-color: var(--cyan); animation: none;
}
@keyframes fab-pulse {
  0% { box-shadow: 0 8px 30px rgba(3, 8, 16, 0.6), 0 0 0 0 rgba(34, 211, 238, 0.35); }
  70% { box-shadow: 0 8px 30px rgba(3, 8, 16, 0.6), 0 0 0 14px rgba(34, 211, 238, 0); }
  100% { box-shadow: 0 8px 30px rgba(3, 8, 16, 0.6), 0 0 0 0 rgba(34, 211, 238, 0); }
}

/* ============ reveal animations ============ */
.reveal { opacity: 0; transform: translateY(26px); transition: opacity .7s ease, transform .7s ease; }
.reveal.in { opacity: 1; transform: none; }
.reveal.d1 { transition-delay: .08s; }
.reveal.d2 { transition-delay: .16s; }
.reveal.d3 { transition-delay: .24s; }
.reveal.d4 { transition-delay: .32s; }

@media (prefers-reduced-motion: reduce) {
  * { animation: none !important; transition: none !important; }
  .reveal { opacity: 1; transform: none; }
  html { scroll-behavior: auto; }
}

/* ============ responsive ============ */
@media (max-width: 900px) {
  .hero-inner { grid-template-columns: 1fr; gap: 40px; }
  .hero-portrait { order: -1; }
  .hero { padding-top: 90px; }
  .stats { grid-template-columns: repeat(3, 1fr); }
  .now-grid, .proj-grid, .skill-grid { grid-template-columns: 1fr 1fr; }
  .insight-grid { grid-template-columns: 1fr; }
  .paper-grid { grid-template-columns: 1fr; }
  .talk-item { grid-template-columns: 1fr; gap: 6px; }
  .logo-group { grid-template-columns: 1fr; gap: 8px; }
  .logo-group-label { text-align: left; }
  .svc-grid { grid-template-columns: 1fr; }
  .arch-panel-grid { grid-template-columns: 1fr; gap: 14px; }
  .explore-grid { grid-template-columns: repeat(3, 1fr); }
  .proj-card.featured { grid-column: span 2; }
  .nav-links { display: none; }
}
@media (max-width: 600px) {
  .stats { grid-template-columns: repeat(2, 1fr); }
  .now-grid, .proj-grid, .skill-grid, .quote-grid, .form-row { grid-template-columns: 1fr; }
  .proj-card.featured { grid-column: span 1; }
  .chip-b { left: -4%; }
  .chip-a { right: -2%; }
  .logo-cell { min-width: 76px; }
  .explore-grid { grid-template-columns: repeat(2, 1fr); }
}
