/* CodeCraft by Chandan — shared styles for index + generated policy pages. */
:root {
  color-scheme: dark;
  --bg: #050507;
  --surface: #0d0d12;
  --surface-2: #14141b;
  --border: #23232d;
  --border-strong: #33333f;
  --text: #f5f5f7;
  --muted: #9a9aa8;
  --faint: #6b6b78;
  --primary: #7c3aed;
  --primary-2: #8b5cf6;
  --accent: #3b82f6;
  --green: #10b981;
  --radius: 32px;
  --radius-sm: 999px;
  --pill: 999px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  min-height: 100vh;
  overflow-x: hidden;
}
body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -1;
  background:
    radial-gradient(900px 600px at 0% 0%, rgba(124, 58, 237, 0.16), transparent 60%),
    radial-gradient(800px 600px at 100% 100%, rgba(59, 130, 246, 0.09), transparent 60%),
    var(--bg);
}
a { color: inherit; text-decoration: none; }
img { display: block; max-width: 100%; }
.container { width: 100%; max-width: 1240px; margin: 0 auto; padding: 0 24px; }

/* ---------- Header ---------- */
.header {
  position: sticky;
  top: 0;
  z-index: 50;
  padding: 16px 24px 0;
  pointer-events: none;
}
.header-inner {
  pointer-events: auto;
  display: flex;
  align-items: center;
  gap: 24px;
  height: 68px;
  max-width: 1192px;
  margin: 0 auto;
  padding: 0 10px 0 10px;
  border-radius: var(--pill);
  background: rgba(16, 15, 22, 0.62);
  backdrop-filter: blur(20px) saturate(160%);
  -webkit-backdrop-filter: blur(20px) saturate(160%);
  border: 1px solid rgba(255, 255, 255, 0.08);
  box-shadow:
    0 20px 50px rgba(0, 0, 0, 0.55),
    0 0 0 1px rgba(124, 58, 237, 0.06),
    inset 0 1px 0 rgba(255, 255, 255, 0.06);
  transition: background 0.3s, box-shadow 0.3s, transform 0.3s;
}
.header.scrolled .header-inner {
  background: rgba(12, 11, 18, 0.82);
  box-shadow:
    0 24px 60px rgba(0, 0, 0, 0.7),
    0 0 0 1px rgba(124, 58, 237, 0.14),
    0 0 40px rgba(124, 58, 237, 0.12),
    inset 0 1px 0 rgba(255, 255, 255, 0.07);
}
.header .search input { height: 48px; border-radius: var(--pill); background: rgba(255, 255, 255, 0.04); }
.header .btn-sm { height: 48px; padding: 0 22px; border-radius: var(--pill); background: rgba(255, 255, 255, 0.04); border-color: rgba(255, 255, 255, 0.1); }
.brand { display: flex; align-items: center; gap: 12px; font-weight: 800; font-size: 20px; letter-spacing: -0.02em; flex-shrink: 0; }
.brand-mark {
  width: 48px; height: 48px;
  border-radius: 50%;
  display: grid; place-items: center;
  background: linear-gradient(135deg, var(--primary-2), var(--accent));
  box-shadow: 0 6px 24px rgba(124, 58, 237, 0.45);
}
.brand-mark svg { width: 24px; height: 24px; }
.brand small { display: block; font-size: 11px; font-weight: 600; color: var(--faint); letter-spacing: 0.08em; text-transform: uppercase; margin-top: -2px; }

.search {
  flex: 1;
  max-width: 660px;
  margin: 0 auto;
  position: relative;
}
.search > svg { position: absolute; left: 16px; top: 50%; transform: translateY(-50%); width: 18px; height: 18px; color: var(--muted); pointer-events: none; }
.search input {
  width: 100%;
  height: 44px;
  padding: 0 16px 0 46px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border-strong);
  background: var(--surface-2);
  color: var(--text);
  font: inherit;
  font-size: 15px;
  outline: none;
  transition: border-color 0.2s, box-shadow 0.2s;
}
.search input::placeholder { color: var(--faint); }
.search input:focus { border-color: var(--primary-2); box-shadow: 0 0 0 4px rgba(124, 58, 237, 0.18); }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  height: 48px; padding: 0 30px;
  border-radius: var(--radius-sm);
  font-weight: 800; font-size: 13px; letter-spacing: 0.08em; text-transform: uppercase;
  border: 1px solid var(--border-strong);
  background: var(--surface-2);
  color: var(--text);
  cursor: pointer;
  transition: transform 0.15s, border-color 0.2s, background 0.2s, box-shadow 0.2s;
  white-space: nowrap;
}
.btn:hover { transform: translateY(-1px); border-color: #4a4a58; }
.btn-primary {
  background: linear-gradient(135deg, var(--primary), var(--primary-2));
  border-color: transparent;
  box-shadow: 0 10px 30px rgba(124, 58, 237, 0.4);
}
.btn-primary:hover { box-shadow: 0 14px 38px rgba(124, 58, 237, 0.55); border-color: transparent; }
.btn-light { background: #fff; color: #0a0a0f; border-color: #fff; }
.btn-light:hover { background: #ececf1; border-color: #ececf1; }
.btn-sm { height: 38px; padding: 0 16px; font-size: 11px; letter-spacing: 0.1em; }

.doc-btn {
  display: flex; align-items: center; justify-content: center;
  height: 42px; padding: 0 18px;
  border-radius: var(--pill);
  font-size: 11px; font-weight: 700; letter-spacing: 0.1em; text-transform: uppercase;
  border: 1px solid var(--border-strong);
  background: var(--surface-2);
  color: #e4e4ea;
  transition: border-color 0.2s, background 0.2s, color 0.2s, transform 0.15s;
}
.doc-btn:hover { transform: translateY(-1px); border-color: #4a4a58; background: #1b1b24; }
.doc-btn.accent { background: rgba(124, 58, 237, 0.12); border-color: rgba(124, 58, 237, 0.35); color: #a78bfa; }
.doc-btn.accent:hover { background: rgba(124, 58, 237, 0.22); border-color: rgba(139, 92, 246, 0.6); color: #c4b5fd; }

/* ---------- Cards ---------- */
.card {
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.025), rgba(255, 255, 255, 0.01)), var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.04);
  transition: border-color 0.25s, transform 0.25s, box-shadow 0.25s;
}
.card.hover:hover { border-color: #383846; transform: translateY(-2px); box-shadow: 0 20px 50px rgba(0, 0, 0, 0.45); }

/* ---------- Hero ---------- */
.hero {
  margin-top: 24px;
  padding: 64px;
  display: grid;
  grid-template-columns: 1.05fr 1fr;
  gap: 48px;
  align-items: center;
  background:
    radial-gradient(600px 300px at 20% 0%, rgba(124, 58, 237, 0.12), transparent 70%),
    var(--surface);
}
.badge {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 7px 16px;
  border-radius: 999px;
  border: 1px solid rgba(139, 92, 246, 0.35);
  background: rgba(124, 58, 237, 0.1);
  color: #a78bfa;
  font-size: 11px; font-weight: 800; letter-spacing: 0.16em; text-transform: uppercase;
}
.badge svg { width: 14px; height: 14px; }
.hero h1 {
  font-size: clamp(42px, 6vw, 68px);
  line-height: 1.02;
  letter-spacing: -0.045em;
  font-weight: 900;
  margin: 26px 0 22px;
}
.grad {
  background: linear-gradient(90deg, #8b5cf6, #6366f1 55%, #3b82f6);
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
.hero p.lead { color: var(--muted); font-size: 15px; max-width: 520px; margin: 0 0 32px; }
.hero-actions { display: flex; gap: 16px; flex-wrap: wrap; }

.hero-visual {
  position: relative;
  aspect-ratio: 16 / 10;
  border-radius: 28px;
  overflow: hidden;
  border: 1px solid var(--border-strong);
  background:
    radial-gradient(circle at 70% 30%, rgba(139, 92, 246, 0.35), transparent 55%),
    radial-gradient(circle at 20% 90%, rgba(59, 130, 246, 0.25), transparent 50%),
    linear-gradient(160deg, #15121f, #0a0a10);
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.5), inset 0 1px 0 rgba(255, 255, 255, 0.05);
}
.hero-visual svg { position: absolute; inset: 0; width: 100%; height: 100%; }
.float { animation: float 6s ease-in-out infinite; }
.float.d2 { animation-delay: -2s; }
.float.d3 { animation-delay: -4s; }
@keyframes float { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-8px); } }

/* ---------- Sections ---------- */
.section { margin-top: 72px; }
.section-head h2 { font-size: clamp(28px, 3.4vw, 34px); font-weight: 900; letter-spacing: -0.035em; margin: 0 0 6px; }
.section-head p { color: var(--muted); margin: 0 0 28px; font-size: 15px; }

/* ---------- App portfolio ---------- */
.apps { display: grid; grid-template-columns: repeat(12, 1fr); gap: 28px; }
.app-card { padding: 32px; grid-column: span 5; display: flex; flex-direction: column; }
.app-card.featured { grid-column: span 7; flex-direction: row; gap: 32px; }
.app-icon {
  width: 64px; height: 64px;
  border-radius: 50%;
  padding: 3px;
  background: linear-gradient(135deg, rgba(139, 92, 246, 0.9), rgba(59, 130, 246, 0.7));
  flex-shrink: 0;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
  border: 1px solid rgba(255, 255, 255, 0.08);
  object-fit: cover;
}
.featured .app-icon-wrap {
  width: 136px; height: 136px; flex-shrink: 0;
  border-radius: 50%;
  box-shadow: 0 0 60px rgba(124, 58, 237, 0.25), inset 0 1px 0 rgba(255, 255, 255, 0.06);
  display: grid; place-items: center;
  background: linear-gradient(160deg, #1f2430, #12141b);
  border: 1px solid var(--border-strong);
}
.featured .app-icon { width: 96px; height: 96px; border-radius: 50%; }
.app-head { display: flex; align-items: center; gap: 20px; margin-bottom: 26px; }
.app-name { font-size: 20px; font-weight: 800; letter-spacing: -0.02em; margin: 0; transition: color 0.2s; }
.featured .app-name { font-size: 26px; }
.app-card:hover .app-name { color: #a78bfa; }
.app-cat { font-size: 11px; font-weight: 700; color: var(--faint); letter-spacing: 0.12em; text-transform: uppercase; }
.featured .app-cat { font-size: 12px; letter-spacing: 0.24em; margin-top: 4px; }
.app-desc { color: var(--muted); font-size: 14px; margin: 14px 0 26px; max-width: 460px; }
.doc-row { display: grid; grid-template-columns: repeat(2, 1fr); gap: 12px; margin-top: auto; }
.doc-stack { display: grid; gap: 12px; margin-top: auto; }
.empty { display: none; color: var(--muted); padding: 40px; text-align: center; grid-column: 1 / -1; }

/* ---------- Features / FAQ ---------- */
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 28px; }
.feature { padding: 40px; }
.feature .ico {
  width: 76px; height: 76px; margin-bottom: 28px;
  border-radius: 50%;
  display: grid; place-items: center;
  background: radial-gradient(circle at 30% 25%, rgba(139, 92, 246, 0.22), rgba(124, 58, 237, 0.05) 70%);
  border: 1px solid rgba(139, 92, 246, 0.25);
  box-shadow: 0 0 40px rgba(124, 58, 237, 0.18), inset 0 1px 0 rgba(255, 255, 255, 0.06);
}
.feature .ico svg { width: 38px; height: 38px; filter: drop-shadow(0 4px 16px rgba(124, 58, 237, 0.45)); }
.feature h3 { font-size: 21px; font-weight: 800; letter-spacing: -0.02em; margin: 0 0 18px; }
.feature p, .faq p { color: var(--muted); font-size: 14px; margin: 0; }
.faq { padding: 32px; }
.faq .chip { width: 48px; height: 48px; border-radius: 50%; display: grid; place-items: center; margin-bottom: 30px; }
.faq .chip svg { width: 18px; height: 18px; }
.chip.violet { background: rgba(124, 58, 237, 0.15); border: 1px solid rgba(124, 58, 237, 0.35); color: #a78bfa; }
.chip.blue { background: rgba(59, 130, 246, 0.14); border: 1px solid rgba(59, 130, 246, 0.35); color: #60a5fa; }
.chip.green { background: rgba(16, 185, 129, 0.14); border: 1px solid rgba(16, 185, 129, 0.35); color: #34d399; }
.faq h3 { font-size: 18px; font-weight: 800; letter-spacing: -0.015em; margin: 0 0 14px; }
.faq p { line-height: 1.7; }
.faq a, .prose a { color: #a78bfa; }

.cta { padding: 48px; display: flex; align-items: center; justify-content: space-between; gap: 32px; margin-top: 28px; }
.cta h2 { font-size: 27px; font-weight: 800; letter-spacing: -0.025em; margin: 0 0 8px; }
.cta p { color: var(--muted); margin: 0; max-width: 420px; }
.cta .btn { height: 58px; padding: 0 44px; border-radius: var(--pill); box-shadow: 0 10px 40px rgba(255, 255, 255, 0.12); }

.footer { color: var(--faint); font-size: 13px; padding: 40px 0 48px; margin-top: 56px; display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; }
.footer a:hover { color: var(--text); }

/* ---------- Policy pages ---------- */
.doc-hero { margin-top: 24px; padding: 40px; display: flex; align-items: center; gap: 28px; flex-wrap: wrap; }
.doc-hero .app-icon { width: 88px; height: 88px; border-radius: 50%; }
.doc-hero h1 { font-size: clamp(30px, 4vw, 42px); font-weight: 900; letter-spacing: -0.04em; margin: 10px 0 0; line-height: 1.1; }
.crumbs { color: var(--faint); font-size: 13px; font-weight: 600; }
.crumbs a:hover { color: var(--text); }
.tabs { margin-left: auto; display: flex; gap: 6px; padding: 6px; border-radius: var(--pill); background: var(--surface-2); border: 1px solid var(--border); }
.tabs a { padding: 10px 20px; border-radius: var(--pill); font-size: 12px; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; color: var(--muted); transition: background 0.2s, color 0.2s; }
.tabs a:hover { color: var(--text); }
.tabs a.on { background: linear-gradient(135deg, var(--primary), var(--primary-2)); color: #fff; box-shadow: 0 6px 20px rgba(124, 58, 237, 0.4); }

.doc-layout > * { min-width: 0; }
.doc-layout { display: grid; grid-template-columns: 280px minmax(0, 1fr); gap: 28px; margin-top: 28px; align-items: start; }
.toc { position: sticky; top: 112px; padding: 24px; }
.toc h4 { margin: 0 0 14px; font-size: 11px; font-weight: 800; letter-spacing: 0.16em; text-transform: uppercase; color: var(--faint); }
.toc ol { list-style: none; margin: 0; padding: 0; counter-reset: toc; }
.toc li { counter-increment: toc; }
.toc a { display: flex; gap: 10px; padding: 9px 14px; border-radius: var(--pill); font-size: 13px; color: var(--muted); line-height: 1.45; transition: background 0.2s, color 0.2s; }
.toc a::before { content: counter(toc, decimal-leading-zero); color: var(--faint); font-variant-numeric: tabular-nums; font-weight: 700; font-size: 11px; padding-top: 2px; }
.toc a:hover, .toc a.on { background: var(--surface-2); color: var(--text); }
.toc a.on::before { color: #a78bfa; }

.prose { padding: 48px 56px; font-size: 15.5px; color: #c9c9d3; line-height: 1.8; }
.prose > p:first-child { font-size: 17px; color: var(--text); }
.prose h2 { color: var(--text); font-size: 20px; font-weight: 800; letter-spacing: -0.02em; margin: 40px 0 12px; padding-top: 32px; border-top: 1px solid var(--border); scroll-margin-top: 112px; line-height: 1.35; }
.prose p { margin: 0 0 16px; }
.meta { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 14px; }
.pill { display: inline-flex; align-items: center; gap: 6px; padding: 5px 12px; border-radius: 999px; font-size: 12px; font-weight: 600; color: var(--muted); background: var(--surface-2); border: 1px solid var(--border); }
.pill .dot { width: 6px; height: 6px; border-radius: 50%; background: var(--green); box-shadow: 0 0 10px var(--green); }

/* ---------- Header extras ---------- */
.icon-btn {
  display: none;
  width: 44px; height: 44px; flex-shrink: 0;
  place-items: center;
  border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: rgba(255, 255, 255, 0.04);
  color: var(--text);
  cursor: pointer;
  transition: background 0.2s, border-color 0.2s;
}
.icon-btn svg { width: 18px; height: 18px; }
.icon-btn:hover, .header.search-open .icon-btn { background: rgba(124, 58, 237, 0.18); border-color: rgba(139, 92, 246, 0.5); }
.toc ol { position: relative; }

/* ---------- Responsive ---------- */

/* Laptop (1025-1280) */
@media (max-width: 1280px) {
  .hero { padding: 52px; gap: 40px; }
  .apps, .grid-3 { gap: 24px; }
  .feature { padding: 34px; }
  .doc-layout { grid-template-columns: 250px minmax(0, 1fr); }
  .prose { padding: 44px 48px; }
}

/* Tablet (721-1024) */
@media (max-width: 1024px) {
  .container { padding: 0 20px; }
  .header { padding: 14px 20px 0; }
  .header-inner { height: 64px; gap: 16px; }
  .header .search input, .header .btn-sm { height: 44px; }
  .brand-mark { width: 44px; height: 44px; }

  .hero { grid-template-columns: 1fr; padding: 48px; gap: 40px; text-align: center; }
  .hero p.lead { margin-left: auto; margin-right: auto; }
  .hero-actions { justify-content: center; }
  .hero-visual { max-width: 640px; width: 100%; margin: 0 auto; }

  .section { margin-top: 60px; }
  .section-head { text-align: center; }
  .app-card, .app-card.featured { grid-column: span 12; }
  .app-card.featured { align-items: center; }
  .app-card:not(.featured) .app-desc { max-width: none; }
  .doc-stack { grid-template-columns: repeat(2, 1fr); }

  .grid-3 { grid-template-columns: 1fr 1fr; }
  .grid-3 > :last-child:nth-child(odd) { grid-column: 1 / -1; }

  .cta { padding: 40px; }

  /* Policy pages: hero stacks, TOC becomes a sticky swipeable pill bar */
  .doc-hero { padding: 32px; }
  .tabs { margin-left: 0; flex-basis: 100%; }
  .tabs a { flex: 1; text-align: center; }
  .doc-layout { grid-template-columns: minmax(0, 1fr); gap: 20px; margin-top: 20px; }
  .toc {
    position: sticky; top: 92px; z-index: 40;
    padding: 6px;
    border-radius: var(--pill);
    background: rgba(16, 15, 22, 0.72);
    backdrop-filter: blur(20px) saturate(160%);
    -webkit-backdrop-filter: blur(20px) saturate(160%);
    box-shadow: 0 16px 40px rgba(0, 0, 0, 0.5), inset 0 1px 0 rgba(255, 255, 255, 0.05);
  }
  .toc h4 { display: none; }
  .toc ol {
    display: flex; gap: 6px;
    overflow-x: auto;
    scrollbar-width: none;
    -webkit-mask-image: linear-gradient(90deg, #000, #000 calc(100% - 28px), transparent);
            mask-image: linear-gradient(90deg, #000, #000 calc(100% - 28px), transparent);
    padding: 0 12px;
  }
  .toc ol::-webkit-scrollbar { display: none; }
  .toc li { flex-shrink: 0; }
  .toc a { white-space: nowrap; padding: 9px 16px; }
  .toc a.on { background: linear-gradient(135deg, var(--primary), var(--primary-2)); color: #fff; box-shadow: 0 6px 18px rgba(124, 58, 237, 0.4); }
  .toc a.on::before { color: rgba(255, 255, 255, 0.75); }
  .prose h2 { scroll-margin-top: 170px; }
  .prose { padding: 40px; }
}

/* Mobile (<=720) */
@media (max-width: 720px) {
  :root { --radius: 26px; }
  .container { padding: 0 16px; }
  .header { padding: 10px 12px 0; padding-top: max(10px, env(safe-area-inset-top)); }
  .header-inner { height: auto; min-height: 60px; flex-wrap: wrap; padding: 8px; gap: 8px; border-radius: 30px; }
  .brand { font-size: 17px; gap: 10px; }
  .brand-mark { width: 42px; height: 42px; }
  .brand-mark svg { width: 21px; height: 21px; }
  .brand small { font-size: 9.5px; }
  .icon-btn { display: grid; margin-left: auto; }
  .header .btn-sm { height: 44px; padding: 0 16px; }
  .search { display: none; order: 3; flex-basis: 100%; max-width: none; }
  .header.search-open .search { display: block; animation: drop 0.22s ease-out; }
  .header.search-open .header-inner { border-radius: 26px; }

  .hero { padding: 36px 20px 20px; gap: 32px; margin-top: 18px; }
  .hero h1 { font-size: clamp(38px, 11vw, 52px); margin: 20px 0 16px; }
  .hero p.lead { font-size: 14.5px; margin-bottom: 26px; }
  .hero-actions { flex-direction: column; gap: 12px; }
  .hero-actions .btn { width: 100%; height: 52px; }
  .hero-visual { border-radius: 22px; }

  .section { margin-top: 48px; }
  .section-head p { margin-bottom: 22px; }
  .apps, .grid-3 { gap: 16px; }
  .app-card { padding: 24px; }
  .app-card.featured { flex-direction: column; gap: 18px; text-align: center; }
  .app-card.featured .app-desc { margin-left: auto; margin-right: auto; }
  .featured .app-icon-wrap { width: 112px; height: 112px; }
  .featured .app-icon { width: 80px; height: 80px; }
  .featured .app-name { font-size: 24px; }
  .featured .app-cat { letter-spacing: 0.18em; }
  .app-head { margin-bottom: 18px; }
  .doc-btn { height: 46px; font-size: 11.5px; }

  .grid-3 { grid-template-columns: 1fr; }
  .feature, .faq { padding: 26px; }
  .feature { display: grid; grid-template-columns: auto 1fr; column-gap: 18px; align-items: center; }
  .feature .ico { width: 60px; height: 60px; margin: 0; }
  .feature .ico svg { width: 30px; height: 30px; }
  .feature h3 { margin: 0; font-size: 19px; }
  .feature p { grid-column: 1 / -1; margin-top: 16px; }
  .faq .chip { margin-bottom: 20px; }

  .cta { flex-direction: column; align-items: stretch; text-align: center; padding: 32px 22px; gap: 24px; }
  .cta p { margin: 0 auto; }
  .cta .btn { width: 100%; height: 54px; }

  .footer { flex-direction: column; align-items: center; text-align: center; gap: 8px; padding: 32px 0 calc(36px + env(safe-area-inset-bottom)); margin-top: 40px; }

  .doc-hero { padding: 26px 20px; gap: 18px; margin-top: 18px; flex-direction: column; text-align: center; }
  .doc-hero .app-icon { width: 76px; height: 76px; }
  .doc-hero .meta { justify-content: center; }
  .tabs { width: 100%; flex-basis: auto; }
  .tabs a { padding: 11px 6px; font-size: 10.5px; letter-spacing: 0.06em; white-space: nowrap; }
  .toc { top: 80px; }
  .toc a { font-size: 12.5px; padding: 8px 14px; }
  .prose { padding: 28px 20px; font-size: 15px; line-height: 1.75; }
  .prose > p:first-child { font-size: 16px; }
  .prose h2 { font-size: 18px; margin-top: 32px; padding-top: 26px; scroll-margin-top: 150px; }
}

/* Small phones (<=400) */
@media (max-width: 400px) {
  .container { padding: 0 12px; }
  .header { padding-left: 8px; padding-right: 8px; }
  .brand small { display: none; }
  .header .btn-sm { padding: 0 14px; font-size: 10.5px; }
  .doc-row, .doc-stack { grid-template-columns: 1fr; }
  .meta .pill { font-size: 11px; }
}

/* Touch devices: no hover lift */
@media (hover: none) {
  .card.hover:hover, .btn:hover, .doc-btn:hover { transform: none; }
}
@keyframes drop { from { opacity: 0; transform: translateY(-6px); } to { opacity: 1; transform: none; } }
@media (prefers-reduced-motion: reduce) {
  .float { animation: none; }
  html { scroll-behavior: auto; }
}

/* ---------- Header nav link ---------- */
.nav-link {
  display: inline-flex; align-items: center; gap: 8px;
  height: 44px; padding: 0 18px;
  border-radius: var(--pill);
  font-size: 13px; font-weight: 700;
  color: var(--muted);
  border: 1px solid transparent;
  transition: color 0.2s, background 0.2s, border-color 0.2s;
  flex-shrink: 0;
}
.nav-link svg { width: 17px; height: 17px; }
.nav-link:hover { color: var(--text); background: rgba(255, 255, 255, 0.05); }
.nav-link.on { color: #c4b5fd; background: rgba(124, 58, 237, 0.16); border-color: rgba(139, 92, 246, 0.4); }

/* ---------- Portfolio ---------- */
.eyebrow { font-size: 12px; font-weight: 800; letter-spacing: 0.18em; text-transform: uppercase; color: #a78bfa; margin-bottom: 10px; }

.p-hero {
  margin-top: 24px; padding: 56px 64px;
  display: grid; grid-template-columns: 1.15fr 0.85fr; gap: 56px; align-items: center;
  background:
    radial-gradient(600px 340px at 15% 0%, rgba(124, 58, 237, 0.14), transparent 70%),
    radial-gradient(500px 400px at 100% 100%, rgba(59, 130, 246, 0.08), transparent 70%),
    var(--surface);
  overflow: hidden;
}
.p-hero h1 { font-size: clamp(40px, 5.6vw, 68px); line-height: 1.04; letter-spacing: -0.045em; font-weight: 900; margin: 24px 0 20px; }
.p-hero .lead { color: var(--muted); font-size: 16px; max-width: 540px; margin: 0 0 32px; }
.p-founder { display: flex; align-items: center; gap: 14px; margin-top: 36px; padding: 10px 22px 10px 10px; border-radius: var(--pill); background: rgba(255, 255, 255, 0.03); border: 1px solid var(--border); width: fit-content; }
.p-founder .brand-mark svg { color: #fff; }
.p-founder strong { display: block; font-size: 14px; }
.p-founder span:not(.brand-mark) { font-size: 12.5px; color: var(--faint); }

.p-photo { position: relative; justify-self: center; width: 100%; max-width: 380px; }
.p-photo::before {
  content: ""; position: absolute; inset: -14%;
  background: radial-gradient(circle, rgba(124, 58, 237, 0.45), transparent 62%);
  filter: blur(20px); z-index: 0;
}
.p-frame {
  position: relative; z-index: 1;
  border-radius: 200px 200px 36px 36px;
  padding: 4px;
  background: linear-gradient(160deg, #a78bfa, #6366f1 45%, rgba(59, 130, 246, 0.4));
  box-shadow: 0 40px 90px rgba(0, 0, 0, 0.6);
}
.p-frame img { width: 100%; height: auto; aspect-ratio: 4 / 5; object-fit: cover; border-radius: 196px 196px 32px 32px; }
.float-chip {
  position: absolute; z-index: 2;
  display: inline-flex; align-items: center; gap: 8px;
  padding: 10px 16px; border-radius: var(--pill);
  font-size: 13px; font-weight: 700; white-space: nowrap;
  background: rgba(16, 15, 22, 0.78);
  backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px);
  border: 1px solid rgba(255, 255, 255, 0.1);
  box-shadow: 0 14px 34px rgba(0, 0, 0, 0.5);
}
.float-chip svg { width: 16px; height: 16px; color: #a78bfa; }
.float-chip b { color: #a78bfa; }
.c1 { top: 18%; left: -12%; }
.c2 { top: 46%; right: -10%; }
.c3 { bottom: 8%; left: -6%; }

.stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 24px; margin-top: 28px; }
.stat { padding: 28px 30px; text-align: center; }
.stat b { display: block; font-size: 38px; font-weight: 900; letter-spacing: -0.04em; line-height: 1.1; background: linear-gradient(90deg, #fff, #c4b5fd); -webkit-background-clip: text; background-clip: text; color: transparent; }
.stat span { font-size: 13px; color: var(--muted); font-weight: 600; }

.about { padding: 48px 56px; display: grid; grid-template-columns: 0.8fr 1.2fr; gap: 48px; align-items: center; }
.about h2 { font-size: clamp(26px, 3vw, 34px); font-weight: 900; letter-spacing: -0.035em; line-height: 1.15; margin: 0; }
.about p { color: var(--muted); font-size: 16px; line-height: 1.8; margin: 0; }

.skills { display: grid; grid-template-columns: repeat(4, 1fr); gap: 24px; }
.skill { padding: 30px; }
.skill h3 { font-size: 18px; font-weight: 800; letter-spacing: -0.015em; margin: 22px 0 16px; }

.work-ico { width: 56px; height: 56px; border-radius: 50%; display: grid; place-items: center; flex-shrink: 0; }
.work-ico svg { width: 24px; height: 24px; }
.work-ico.violet { background: rgba(124, 58, 237, 0.15); border: 1px solid rgba(124, 58, 237, 0.35); color: #a78bfa; box-shadow: 0 0 30px rgba(124, 58, 237, 0.18); }
.work-ico.blue { background: rgba(59, 130, 246, 0.14); border: 1px solid rgba(59, 130, 246, 0.35); color: #60a5fa; box-shadow: 0 0 30px rgba(59, 130, 246, 0.15); }
.work-ico.green { background: rgba(16, 185, 129, 0.14); border: 1px solid rgba(16, 185, 129, 0.35); color: #34d399; box-shadow: 0 0 30px rgba(16, 185, 129, 0.12); }
.work-ico.amber { background: rgba(245, 158, 11, 0.13); border: 1px solid rgba(245, 158, 11, 0.35); color: #fbbf24; box-shadow: 0 0 30px rgba(245, 158, 11, 0.12); }

.tags { display: flex; flex-wrap: wrap; gap: 8px; }
.tags span { padding: 6px 13px; border-radius: var(--pill); font-size: 12px; font-weight: 600; color: #d4d4dc; background: rgba(255, 255, 255, 0.04); border: 1px solid var(--border-strong); }

.works { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.work { padding: 30px; display: flex; flex-direction: column; gap: 18px; }
.work-lg { grid-column: span 2; }
.work:not(.work-lg) .doc-row { grid-template-columns: 1fr; gap: 10px; }
.doc-btn { white-space: nowrap; }
.work-wide { grid-column: span 3; }
.work-top { display: flex; align-items: center; gap: 16px; }
.work-top h3 { margin: 0; font-size: 19px; font-weight: 800; letter-spacing: -0.02em; }
.work-lg .work-top h3 { font-size: 24px; }
.work-lg .app-icon { width: 76px; height: 76px; }
.work > p { color: var(--muted); font-size: 14.5px; margin: 0; line-height: 1.7; }
.work-lg > p { font-size: 16px; }
.work .doc-row { margin-top: auto; }
.status { margin-left: auto; padding: 6px 12px; border-radius: var(--pill); font-size: 11px; font-weight: 800; letter-spacing: 0.08em; text-transform: uppercase; white-space: nowrap; }
.status.live { color: #34d399; background: rgba(16, 185, 129, 0.12); border: 1px solid rgba(16, 185, 129, 0.35); }
.status.dev { color: #fbbf24; background: rgba(245, 158, 11, 0.1); border: 1px solid rgba(245, 158, 11, 0.35); }
.ticks { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.ticks li { display: flex; gap: 10px; align-items: flex-start; font-size: 14.5px; color: #d4d4dc; }
.ticks svg { width: 18px; height: 18px; flex-shrink: 0; margin-top: 2px; color: #34d399; }
.pipeline { display: flex; flex-wrap: wrap; gap: 12px; }
.pipeline span { padding: 12px 22px; border-radius: var(--pill); font-weight: 700; font-size: 14px; background: rgba(245, 158, 11, 0.06); border: 1px dashed rgba(245, 158, 11, 0.4); color: #fde68a; }

.arch { padding: 40px; }
.arch-row { display: grid; grid-template-columns: 110px 1fr; gap: 20px; align-items: center; }
.arch-label { font-size: 12px; font-weight: 800; letter-spacing: 0.16em; text-transform: uppercase; color: var(--faint); }
.arch-nodes { display: flex; flex-wrap: wrap; gap: 10px; }
.arch-nodes span { padding: 11px 18px; border-radius: var(--pill); font-size: 13.5px; font-weight: 600; background: var(--surface-2); border: 1px solid var(--border-strong); }
.arch-nodes span.hl { background: rgba(124, 58, 237, 0.12); border-color: rgba(139, 92, 246, 0.4); color: #c4b5fd; }
.arch-link { height: 34px; margin-left: 130px; border-left: 2px dashed rgba(139, 92, 246, 0.45); position: relative; }
.arch-link::after { content: ""; position: absolute; left: -6px; bottom: -2px; border: 5px solid transparent; border-top: 7px solid rgba(139, 92, 246, 0.7); }
.portfolio .cta { margin-top: 72px; }
.cta .btn svg { width: 18px; height: 18px; }

@media (max-width: 1280px) {
  .p-hero { padding: 48px; gap: 40px; }
  .skills { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 1024px) {
  .p-hero { grid-template-columns: 1fr; text-align: center; padding: 48px 40px; }
  .p-hero .lead { margin-left: auto; margin-right: auto; }
  .p-hero .hero-actions { justify-content: center; }
  .p-founder { margin-left: auto; margin-right: auto; text-align: left; }
  .p-photo { grid-row: 1; max-width: 320px; }
  .stats { grid-template-columns: repeat(2, 1fr); }
  .about { grid-template-columns: 1fr; gap: 20px; padding: 40px; }
  .works { grid-template-columns: repeat(2, 1fr); }
  .work-lg, .work-wide { grid-column: span 2; grid-row: auto; }
  .arch-link { margin-left: 24px; }
  .arch-row { grid-template-columns: 1fr; gap: 12px; }
}
@media (max-width: 720px) {
  .nav-link { width: 44px; height: 44px; padding: 0; justify-content: center; border-color: rgba(255, 255, 255, 0.1); background: rgba(255, 255, 255, 0.04); }
  .nav-link span { display: none; }
  .header-inner > div + .nav-link { margin-left: auto; }
  .p-hero { padding: 32px 20px; gap: 32px; margin-top: 18px; }
  .p-hero h1 { font-size: clamp(36px, 10.5vw, 48px); }
  .p-hero .lead { font-size: 15px; }
  .p-photo { max-width: 240px; }
  .c1 { left: -16%; } .c2 { right: -16%; } .c3 { left: -10%; }
  .float-chip { font-size: 12px; padding: 8px 12px; }
  .p-founder { padding-right: 16px; }
  .stats { gap: 12px; margin-top: 16px; }
  .stat { padding: 20px 12px; }
  .stat b { font-size: 30px; }
  .stat span { font-size: 12px; }
  .about { padding: 28px 22px; }
  .about p { font-size: 15px; }
  .skills, .works { grid-template-columns: 1fr; gap: 16px; }
  .work-lg, .work-wide { grid-column: auto; }
  .work, .skill { padding: 24px; }
  .work-top { flex-wrap: wrap; }
  .work-lg .app-icon { width: 64px; height: 64px; }
  .arch { padding: 26px 20px; }
  .arch-nodes span { font-size: 12.5px; padding: 9px 14px; }
  .portfolio .cta { margin-top: 48px; }
}

/* ---------- Motion & polish (driven by assets/site.js) ---------- */
.reveal { opacity: 0; transform: translateY(26px) scale(0.985); transition: opacity 0.7s cubic-bezier(.2,.7,.2,1) var(--d, 0ms), transform 0.7s cubic-bezier(.2,.7,.2,1) var(--d, 0ms); }
.reveal.in { opacity: 1; transform: none; }

.card { position: relative; isolation: isolate; }
.card::after {
  content: "";
  position: absolute; inset: 0; z-index: -1;
  border-radius: inherit;
  background: radial-gradient(420px circle at var(--mx, 50%) var(--my, -200px), rgba(139, 92, 246, 0.10), transparent 60%);
  opacity: 0;
  transition: opacity 0.35s;
  pointer-events: none;
}
.card:hover::after { opacity: 1; }
.card.hover:hover { border-color: rgba(139, 92, 246, 0.32); }

.to-top {
  position: fixed; right: 22px; bottom: calc(22px + env(safe-area-inset-bottom)); z-index: 60;
  width: 50px; height: 50px; border-radius: 50%;
  display: grid; place-items: center;
  color: #fff; cursor: pointer;
  border: 1px solid rgba(255, 255, 255, 0.14);
  background: linear-gradient(135deg, var(--primary), var(--primary-2));
  box-shadow: 0 14px 34px rgba(124, 58, 237, 0.45);
  opacity: 0; transform: translateY(16px) scale(0.9); pointer-events: none;
  transition: opacity 0.3s, transform 0.3s;
}
.to-top svg { width: 20px; height: 20px; }
.to-top.show { opacity: 1; transform: none; pointer-events: auto; }
.to-top:hover { transform: translateY(-2px); }

/* Animated gradient on headline accent */
.grad { background-size: 200% 100%; animation: shine 8s ease-in-out infinite; }
@keyframes shine { 0%, 100% { background-position: 0% 50%; } 50% { background-position: 100% 50%; } }

/* ---------- Hub: meet the developer ---------- */
.dev-card {
  display: grid; grid-template-columns: auto 1fr auto; gap: 40px; align-items: center;
  padding: 40px 48px;
  background:
    radial-gradient(500px 260px at 0% 50%, rgba(124, 58, 237, 0.16), transparent 70%),
    var(--surface);
}
.dev-photo { position: relative; width: 148px; height: 148px; border-radius: 50%; padding: 4px; background: conic-gradient(from 200deg, #a78bfa, #3b82f6, #6366f1, #a78bfa); box-shadow: 0 0 60px rgba(124, 58, 237, 0.35); }
.dev-photo img { width: 100%; height: 100%; border-radius: 50%; object-fit: cover; object-position: 50% 12%; border: 4px solid var(--surface); }
.dev-photo .online { position: absolute; right: 10px; bottom: 10px; width: 18px; height: 18px; border-radius: 50%; background: var(--green); border: 3px solid var(--surface); box-shadow: 0 0 12px var(--green); }
.dev-card h2 { font-size: clamp(24px, 2.8vw, 32px); font-weight: 900; letter-spacing: -0.035em; margin: 0 0 6px; }
.dev-card .role { color: #a78bfa; font-weight: 700; font-size: 14px; margin-bottom: 12px; }
.dev-card p { color: var(--muted); margin: 0 0 18px; max-width: 520px; font-size: 14.5px; }
.mini-stats { display: flex; gap: 28px; flex-wrap: wrap; }
.mini-stats div b { display: block; font-size: 24px; font-weight: 900; letter-spacing: -0.03em; }
.mini-stats div span { font-size: 12px; color: var(--faint); font-weight: 600; }
.dev-card .btn svg { width: 18px; height: 18px; }

/* ---------- Portfolio: sticky section nav ---------- */
.subnav-wrap { position: sticky; top: 100px; z-index: 40; display: flex; justify-content: center; margin-top: 28px; pointer-events: none; }
.subnav {
  pointer-events: auto;
  display: flex; gap: 4px; padding: 6px;
  border-radius: var(--pill);
  background: rgba(16, 15, 22, 0.72);
  backdrop-filter: blur(20px) saturate(160%); -webkit-backdrop-filter: blur(20px) saturate(160%);
  border: 1px solid rgba(255, 255, 255, 0.08);
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.5), inset 0 1px 0 rgba(255, 255, 255, 0.05);
  max-width: 100%; overflow-x: auto; scrollbar-width: none;
}
.subnav::-webkit-scrollbar { display: none; }
.subnav a { padding: 9px 18px; border-radius: var(--pill); font-size: 13px; font-weight: 700; color: var(--muted); white-space: nowrap; transition: color 0.2s, background 0.2s, box-shadow 0.2s; }
.subnav a:hover { color: var(--text); }
.subnav a.on { color: #fff; background: linear-gradient(135deg, var(--primary), var(--primary-2)); box-shadow: 0 6px 18px rgba(124, 58, 237, 0.4); }
.portfolio main section[id], .portfolio main [id="contact"] { scroll-margin-top: 170px; }

@media (max-width: 1024px) {
  .dev-card { grid-template-columns: auto 1fr; padding: 36px; }
  .dev-card > .btn { grid-column: 1 / -1; justify-self: start; }
  .subnav-wrap { top: 92px; }
}
@media (max-width: 720px) {
  .dev-card { grid-template-columns: 1fr; text-align: center; justify-items: center; gap: 22px; padding: 30px 22px; }
  .dev-card p { margin-left: auto; margin-right: auto; }
  .mini-stats { justify-content: center; gap: 22px; }
  .dev-card > .btn { justify-self: stretch; }
  .dev-photo { width: 124px; height: 124px; }
  .subnav-wrap { top: 80px; margin-top: 18px; }
  .subnav a { padding: 8px 14px; font-size: 12.5px; }
  .to-top { width: 46px; height: 46px; right: 16px; }
  .portfolio main section[id], .portfolio main [id="contact"] { scroll-margin-top: 140px; }
}
@media (prefers-reduced-motion: reduce) {
  .grad { animation: none; }
}

.card.toc { position: sticky; }

/* ---------- Portfolio: full-width section nav ---------- */
.subnav-wrap { justify-content: stretch; }
.subnav { width: 100%; }
.subnav a { flex: 1 0 auto; text-align: center; }

/* ---------- Sample-content badge ---------- */
.sample {
  display: inline-flex; align-items: center;
  padding: 3px 10px; border-radius: var(--pill);
  font-size: 10.5px; font-weight: 800; letter-spacing: 0.1em; text-transform: uppercase;
  color: #fbbf24; background: rgba(245, 158, 11, 0.1); border: 1px dashed rgba(245, 158, 11, 0.5);
}
.is-sample { border-style: dashed; }

/* ---------- Education timeline ---------- */
.timeline { position: relative; display: grid; gap: 20px; padding-left: 36px; }
.timeline::before { content: ""; position: absolute; left: 13px; top: 28px; bottom: 28px; width: 2px; background: linear-gradient(#8b5cf6, rgba(59, 130, 246, 0.5), transparent); }
.tl-item { padding: 26px 30px; }
.tl-dot {
  position: absolute; left: -50px; top: 24px;
  width: 30px; height: 30px; border-radius: 50%;
  display: grid; place-items: center;
  background: linear-gradient(135deg, var(--primary), var(--accent));
  box-shadow: 0 0 0 5px var(--bg), 0 0 24px rgba(124, 58, 237, 0.55);
  color: #fff;
}
.tl-dot svg { width: 15px; height: 15px; }
.tl-head { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.tl-head h3 { margin: 0; font-size: 19px; font-weight: 800; letter-spacing: -0.02em; }
.tl-period { margin-left: auto; padding: 5px 14px; border-radius: var(--pill); font-size: 12px; font-weight: 700; color: #c4b5fd; background: rgba(124, 58, 237, 0.12); border: 1px solid rgba(139, 92, 246, 0.35); }
.tl-org { color: #a78bfa; font-weight: 600; font-size: 14px; margin: 6px 0 10px; }
.tl-item p { margin: 0; color: var(--muted); font-size: 14.5px; }

/* ---------- Testimonials ---------- */
.quotes { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.quote { margin: 0; padding: 30px; display: flex; flex-direction: column; gap: 18px; }
.quote .sample { position: absolute; top: 26px; right: 26px; }
.q-mark { width: 46px; height: 46px; border-radius: 50%; display: grid; place-items: center; color: #a78bfa; background: rgba(124, 58, 237, 0.14); border: 1px solid rgba(139, 92, 246, 0.35); }
.q-mark svg { width: 20px; height: 20px; }
.quote blockquote { margin: 0; font-size: 15.5px; line-height: 1.7; color: #e4e4ea; flex: 1; }
.quote figcaption { display: flex; align-items: center; gap: 12px; padding-top: 18px; border-top: 1px solid var(--border); }
.avatar { width: 42px; height: 42px; border-radius: 50%; display: grid; place-items: center; font-weight: 800; font-size: 14px; color: #fff; background: linear-gradient(135deg, var(--primary), var(--accent)); flex-shrink: 0; }
.quote figcaption b { display: block; font-size: 14px; }
.quote figcaption small { color: var(--faint); font-size: 12.5px; }

/* ---------- Legal hub (portfolio) ---------- */
.legal-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.legal-card { padding: 26px; display: flex; gap: 18px; align-items: flex-start; }
.legal-card .app-icon { width: 56px; height: 56px; }
.legal-body h3 { margin: 0; font-size: 18px; font-weight: 800; letter-spacing: -0.015em; }
.legal-links { display: grid; gap: 8px; margin-top: 16px; }
.legal-links a { display: inline-flex; align-items: center; gap: 8px; font-size: 14px; font-weight: 600; color: #c4b5fd; transition: color 0.2s, transform 0.2s; }
.legal-links a:hover { color: #fff; transform: translateX(3px); }
.legal-links svg { width: 16px; height: 16px; }
.legal-all { align-items: center; background: radial-gradient(400px 200px at 0% 0%, rgba(124, 58, 237, 0.16), transparent 70%), var(--surface); }
.legal-all .go { margin-left: auto; width: 44px; height: 44px; border-radius: 50%; display: grid; place-items: center; background: linear-gradient(135deg, var(--primary), var(--primary-2)); color: #fff; box-shadow: 0 8px 24px rgba(124, 58, 237, 0.45); transition: transform 0.2s; flex-shrink: 0; }
.legal-all .go svg { width: 18px; height: 18px; }
.legal-all:hover .go { transform: translateX(4px); }

/* ---------- Contact form + map ---------- */
.contact { display: grid; grid-template-columns: 1.15fr 0.85fr; gap: 24px; align-items: stretch; }
.contact-form { padding: 36px; display: grid; gap: 18px; }
.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
.field { display: grid; gap: 8px; }
.field > span { font-size: 12px; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; color: var(--muted); }
.field input, .field select, .field textarea {
  width: 100%; font: inherit; font-size: 15px; color: var(--text);
  padding: 14px 20px;
  border-radius: 18px;
  border: 1px solid var(--border-strong);
  background: rgba(255, 255, 255, 0.03);
  outline: none;
  transition: border-color 0.2s, box-shadow 0.2s, background 0.2s;
}
.field input, .field select { border-radius: var(--pill); height: 52px; padding: 0 22px; }
.field select { appearance: none; -webkit-appearance: none; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%239a9aa8' stroke-width='2' stroke-linecap='round'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 18px center; background-size: 18px; padding-right: 48px; }
.field select option { background: #14141b; }
.field textarea { resize: vertical; min-height: 150px; border-radius: 24px; }
.field input::placeholder, .field textarea::placeholder { color: var(--faint); }
.field input:focus, .field select:focus, .field textarea:focus { border-color: var(--primary-2); background: rgba(124, 58, 237, 0.05); box-shadow: 0 0 0 4px rgba(124, 58, 237, 0.18); }
.field.invalid input, .field.invalid textarea { border-color: #f87171; box-shadow: 0 0 0 4px rgba(248, 113, 113, 0.15); }
.form-actions { display: flex; gap: 12px; flex-wrap: wrap; }
.form-actions .btn { height: 54px; padding: 0 30px; }
.form-actions .btn svg { width: 18px; height: 18px; }
.form-note { margin: 0; font-size: 13px; color: var(--faint); }
.form-note.ok { color: #34d399; }
.form-note.err { color: #f87171; }

.contact-side { display: grid; grid-template-rows: 1fr auto; gap: 24px; }
.map-card { overflow: hidden; min-height: 300px; padding: 0; }
.map-card iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; filter: invert(0.92) hue-rotate(180deg) saturate(0.7) brightness(0.95) contrast(0.9); }
.map-card::before { content: ""; position: absolute; inset: 0; z-index: 1; pointer-events: none; border-radius: inherit; box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.06), inset 0 -80px 80px -40px rgba(5, 5, 7, 0.85); }
.map-chip { position: absolute; left: 18px; bottom: 18px; z-index: 2; display: inline-flex; align-items: center; gap: 8px; padding: 10px 18px; border-radius: var(--pill); font-size: 13px; font-weight: 700; background: rgba(16, 15, 22, 0.82); backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px); border: 1px solid rgba(255, 255, 255, 0.1); }
.map-chip svg { width: 16px; height: 16px; color: #a78bfa; }
.info-card { padding: 22px 24px; display: grid; gap: 16px; }
.info-card > * { display: flex; align-items: center; gap: 14px; min-width: 0; }
.info-card .work-ico { width: 46px; height: 46px; }
.info-card .work-ico svg { width: 20px; height: 20px; }
.info-card small { display: block; font-size: 11.5px; font-weight: 700; letter-spacing: 0.1em; text-transform: uppercase; color: var(--faint); }
.info-card b { display: block; font-size: 14.5px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.info-card a:hover b { color: #c4b5fd; }

@media (max-width: 1024px) {
  .quotes { grid-template-columns: 1fr 1fr; }
  .quotes > :last-child:nth-child(odd) { grid-column: 1 / -1; }
  .legal-grid { grid-template-columns: 1fr 1fr; }
  .legal-all { grid-column: 1 / -1; }
  .contact { grid-template-columns: 1fr; }
  .contact-side { grid-template-columns: 1.3fr 1fr; grid-template-rows: auto; }
}
@media (max-width: 720px) {
  .subnav-wrap { margin-left: -4px; margin-right: -4px; }
  .subnav a { flex: 0 0 auto; }
  .timeline { padding-left: 30px; gap: 16px; }
  .timeline::before { left: 10px; }
  .tl-dot { left: -40px; width: 26px; height: 26px; }
  .tl-item { padding: 22px; }
  .tl-period { margin-left: 0; }
  .quotes, .legal-grid { grid-template-columns: 1fr; gap: 16px; }
  .quote { padding: 24px; }
  .contact-form { padding: 24px 20px; }
  .field-row { grid-template-columns: 1fr; }
  .form-actions .btn { flex: 1 1 100%; }
  .contact-side { grid-template-columns: 1fr; gap: 16px; }
  .map-card { min-height: 240px; }
}

/* ---------- Social icons ---------- */
.socials { display: flex; flex-wrap: wrap; gap: 12px; }
.social {
  width: 48px; height: 48px; border-radius: 50%;
  display: grid; place-items: center;
  color: #8b5cf6;
  border: 2px solid #7c3aed;
  background: rgba(124, 58, 237, 0.06);
  transition: transform 0.2s, background 0.25s, color 0.25s, box-shadow 0.25s, border-color 0.25s;
}
.social svg { width: 20px; height: 20px; }
a.social:hover {
  color: #fff; border-color: transparent;
  background: linear-gradient(135deg, var(--primary), var(--primary-2));
  box-shadow: 0 10px 26px rgba(124, 58, 237, 0.5);
  transform: translateY(-3px);
}
.social.todo { border-style: dashed; opacity: 0.55; cursor: help; }
.hero-socials { margin-top: 28px; }
.info-socials { padding-top: 16px; border-top: 1px solid var(--border); }
.info-card > .socials { display: flex; }
.info-socials .social { width: 42px; height: 42px; }
.info-socials .social svg { width: 18px; height: 18px; }
.dev-socials { margin-top: 18px; }
.dev-socials .social { width: 40px; height: 40px; }
.dev-socials .social svg { width: 17px; height: 17px; }
@media (max-width: 1024px) {
  .hero-socials { justify-content: center; }
}
@media (max-width: 720px) {
  .dev-socials { justify-content: center; }
  .socials { gap: 10px; }
  .hero-socials .social { width: 44px; height: 44px; }
}

/* ---------- Services ---------- */
.services { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.service { padding: 32px; display: flex; flex-direction: column; gap: 16px; }
.service h3 { margin: 6px 0 0; font-size: 20px; font-weight: 800; letter-spacing: -0.02em; }
.service > p { margin: 0; color: var(--muted); font-size: 14.5px; line-height: 1.7; }
.service .ticks li { font-size: 13.5px; }
.svc-link { margin-top: auto; padding-top: 18px; border-top: 1px solid var(--border); display: inline-flex; align-items: center; gap: 8px; font-size: 13px; font-weight: 800; letter-spacing: 0.06em; text-transform: uppercase; color: #a78bfa; transition: color 0.2s, gap 0.2s; }
.svc-link svg { width: 16px; height: 16px; }
.svc-link:hover { color: #fff; gap: 12px; }
@media (max-width: 1024px) { .services { grid-template-columns: 1fr 1fr; } }
@media (max-width: 720px) { .services { grid-template-columns: 1fr; gap: 16px; } .service { padding: 24px; } }

/* ---------- Header: Legal Hub / Portfolio switch ---------- */
.switch {
  position: relative; flex-shrink: 0;
  display: grid; grid-template-columns: 1fr 1fr;
  padding: 4px; border-radius: var(--pill);
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.1);
  box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.4);
}
.switch a {
  position: relative; z-index: 1;
  display: flex; align-items: center; justify-content: center; gap: 7px;
  height: 38px; padding: 0 16px;
  border-radius: var(--pill);
  font-size: 13px; font-weight: 700; white-space: nowrap;
  color: var(--muted);
  transition: color 0.3s;
}
.switch a svg { width: 16px; height: 16px; }
.switch a:hover { color: var(--text); }
.switch[data-active="hub"] a[data-to="hub"], .switch[data-active="portfolio"] a[data-to="portfolio"] { color: #fff; }
.switch-thumb {
  position: absolute; top: 4px; bottom: 4px; left: 4px;
  width: calc(50% - 4px);
  border-radius: var(--pill);
  background: linear-gradient(135deg, var(--primary), var(--primary-2));
  box-shadow: 0 6px 18px rgba(124, 58, 237, 0.5), inset 0 1px 0 rgba(255, 255, 255, 0.2);
  transition: transform 0.35s cubic-bezier(.4, 1.3, .5, 1);
}
.switch[data-active="portfolio"] .switch-thumb { transform: translateX(100%); }
.support-btn svg { display: none; width: 18px; height: 18px; }
main, footer { transition: opacity 0.28s ease, transform 0.28s ease; }
body.leaving main, body.leaving footer { opacity: 0; transform: translateY(10px); }

/* ---------- Portfolio: legal hub section ---------- */
.legal-grid { grid-template-columns: repeat(auto-fit, minmax(340px, 1fr)); }
.legal-app { padding: 26px; display: flex; flex-direction: column; gap: 20px; }
.la-head { display: flex; align-items: center; gap: 16px; }
.la-head .app-icon { width: 60px; height: 60px; }
.la-title h3 { margin: 0; font-size: 19px; font-weight: 800; letter-spacing: -0.02em; }
.status .live-dot { display: inline-block; width: 7px; height: 7px; border-radius: 50%; background: #34d399; box-shadow: 0 0 10px #34d399; margin-right: 7px; vertical-align: 1px; animation: pulse 2s ease-in-out infinite; }
@keyframes pulse { 50% { opacity: 0.35; } }
.la-docs { display: grid; gap: 10px; }
.la-doc {
  display: flex; align-items: center; gap: 14px;
  padding: 12px 12px 12px 12px;
  border-radius: var(--pill);
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--border);
  transition: background 0.25s, border-color 0.25s, transform 0.25s;
}
.la-doc:hover { background: rgba(124, 58, 237, 0.08); border-color: rgba(139, 92, 246, 0.4); transform: translateX(3px); }
.la-ico { width: 42px; height: 42px; border-radius: 50%; display: grid; place-items: center; flex-shrink: 0; }
.la-ico svg { width: 19px; height: 19px; }
.la-ico.violet { color: #a78bfa; background: rgba(124, 58, 237, 0.15); border: 1px solid rgba(124, 58, 237, 0.35); }
.la-ico.blue { color: #60a5fa; background: rgba(59, 130, 246, 0.14); border: 1px solid rgba(59, 130, 246, 0.35); }
.la-text { flex: 1; min-width: 0; }
.la-text b { display: block; font-size: 15px; }
.la-text small { color: var(--faint); font-size: 12.5px; }
.la-go { width: 38px; height: 38px; border-radius: 50%; display: grid; place-items: center; flex-shrink: 0; color: var(--muted); background: rgba(255, 255, 255, 0.04); transition: background 0.25s, color 0.25s; }
.la-go svg { width: 16px; height: 16px; }
.la-doc:hover .la-go { color: #fff; background: linear-gradient(135deg, var(--primary), var(--primary-2)); }

.legal-banner {
  margin-top: 24px; padding: 26px 28px;
  display: flex; align-items: center; gap: 22px;
  border-color: rgba(139, 92, 246, 0.3);
  background:
    radial-gradient(500px 220px at 0% 50%, rgba(124, 58, 237, 0.28), transparent 70%),
    radial-gradient(400px 200px at 100% 50%, rgba(59, 130, 246, 0.14), transparent 70%),
    var(--surface);
}
.lb-ico { width: 64px; height: 64px; border-radius: 50%; display: grid; place-items: center; flex-shrink: 0; color: #fff; background: linear-gradient(135deg, var(--primary), var(--accent)); box-shadow: 0 0 40px rgba(124, 58, 237, 0.5); }
.lb-ico svg { width: 28px; height: 28px; }
.lb-text { flex: 1; min-width: 0; }
.lb-text b { display: block; font-size: 21px; font-weight: 800; letter-spacing: -0.02em; }
.lb-text small { color: var(--muted); font-size: 14px; }
.lb-btn { flex-shrink: 0; }
.lb-btn svg { width: 18px; height: 18px; transition: transform 0.2s; }
.legal-banner:hover .lb-btn svg { transform: translateX(4px); }

/* Experience reuses the timeline */
.exp .tl-dot { background: linear-gradient(135deg, var(--accent), var(--primary)); }
.exp .ticks { margin-top: 14px; }

@media (max-width: 1024px) {
  .switch a { padding: 0 12px; }
}
@media (max-width: 720px) {
  .switch a { width: 40px; height: 36px; padding: 0; }
  .switch a span { display: none; }
  .support-btn { width: 44px; padding: 0 !important; border-radius: 50%; }
  .support-btn span { display: none; }
  .support-btn svg { display: block; }
  .header-inner > div + .switch { margin-left: auto; }
  .legal-grid { grid-template-columns: 1fr; }
  .legal-app { padding: 20px; }
  .la-head { flex-wrap: wrap; }
  .legal-banner { flex-direction: column; text-align: center; padding: 28px 22px; }
  .lb-btn { width: 100%; }
}
@media (max-width: 380px) {
  .brand > span:not(.brand-mark) { display: none; }
}
@media (prefers-reduced-motion: reduce) {
  .status .live-dot { animation: none; }
}

/* ---------- Projects: 6-column bento + premium app cards ---------- */
.works { grid-template-columns: repeat(6, 1fr); }
.works > .work { grid-column: span 2; }
.works > .work-app { grid-column: span 3; }
.works > .work-wide { grid-column: 1 / -1; }

.work-app { --accent: 124, 58, 237; padding: 32px; gap: 20px; overflow: hidden; }
.wa-glow { position: absolute; top: -120px; right: -80px; width: 320px; height: 320px; border-radius: 50%; background: radial-gradient(circle, rgba(var(--accent), 0.28), transparent 65%); pointer-events: none; z-index: -1; transition: transform 0.6s ease; }
.work-app:hover .wa-glow { transform: scale(1.15) translate(-10px, 10px); }
.work-app:hover { border-color: rgba(var(--accent), 0.45); }
.wa-head { display: flex; align-items: center; gap: 18px; }
.wa-icon { position: relative; flex-shrink: 0; }
.wa-icon::before { content: ""; position: absolute; inset: -8px; border-radius: 50%; background: radial-gradient(circle, rgba(var(--accent), 0.45), transparent 70%); filter: blur(6px); }
.wa-icon .app-icon { position: relative; width: 78px; height: 78px; }
.wa-title { flex: 1; min-width: 0; }
.wa-title h3 { margin: 0; font-size: 24px; font-weight: 900; letter-spacing: -0.03em; line-height: 1.15; }
.wa-meta { display: flex; align-items: center; flex-wrap: wrap; gap: 8px; margin-top: 6px; font-size: 11.5px; font-weight: 700; letter-spacing: 0.12em; text-transform: uppercase; color: var(--faint); }
.wa-meta .ver { letter-spacing: 0.04em; text-transform: none; padding: 2px 9px; border-radius: var(--pill); color: #e4e4ea; background: rgba(255, 255, 255, 0.06); border: 1px solid var(--border-strong); }
.wa-head .status { align-self: flex-start; }
.work-app > p { font-size: 15.5px; }

.stores { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; margin-top: auto; padding-top: 4px; }
.store {
  display: flex; align-items: center; gap: 10px;
  height: 58px; padding: 0 16px;
  border-radius: 18px;
  background: #000;
  border: 1px solid rgba(255, 255, 255, 0.18);
  color: #fff;
  transition: transform 0.2s, border-color 0.2s, box-shadow 0.2s, background 0.2s;
  min-width: 0;
}
.store svg { width: 26px; height: 26px; flex-shrink: 0; }
.store > span { display: flex; flex-direction: column; line-height: 1.15; min-width: 0; }
.store small { font-size: 10px; font-weight: 600; letter-spacing: 0.04em; text-transform: uppercase; color: rgba(255, 255, 255, 0.7); white-space: nowrap; }
.store b { font-size: 15.5px; font-weight: 700; letter-spacing: -0.01em; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
a.store:hover { transform: translateY(-2px); border-color: rgba(var(--accent), 0.7); box-shadow: 0 12px 30px rgba(var(--accent), 0.35); }
.store-apk svg { color: #3ddc84; }
.store.soon { cursor: default; background: rgba(255, 255, 255, 0.02); border-style: dashed; border-color: rgba(255, 255, 255, 0.14); }
.store.soon svg { opacity: 0.45; filter: grayscale(0.6); }
.store.soon b { color: rgba(255, 255, 255, 0.55); }
.store.soon small { color: #fbbf24; }

.wa-legal { display: flex; align-items: center; flex-wrap: wrap; gap: 10px; padding-top: 16px; border-top: 1px solid var(--border); font-size: 13.5px; color: var(--faint); }
.wa-legal a { display: inline-flex; align-items: center; gap: 7px; font-weight: 600; color: #c4b5fd; transition: color 0.2s; }
.wa-legal a:hover { color: #fff; }
.wa-legal svg { width: 15px; height: 15px; }

@media (max-width: 1280px) {
  .stores { grid-template-columns: 1fr 1fr; }
  .store-apk { grid-column: 1 / -1; }
}
@media (max-width: 1024px) {
  .works > .work-app { grid-column: 1 / -1; }
  .works > .work { grid-column: span 3; }
  .works > .work:not(.work-app):not(.work-wide):nth-last-child(2) { grid-column: 1 / -1; }
  .stores { grid-template-columns: repeat(3, 1fr); }
  .store-apk { grid-column: auto; }
}
@media (max-width: 720px) {
  .works > .work, .works > .work-app, .works > .work:not(.work-app):not(.work-wide):nth-last-child(2) { grid-column: 1 / -1; }
  .work-app { padding: 24px 20px; }
  .wa-head { flex-wrap: wrap; }
  .wa-icon .app-icon { width: 64px; height: 64px; }
  .wa-title h3 { font-size: 21px; }
  .stores { grid-template-columns: 1fr; }
  .store { height: 56px; }
}

/* ---------- Site-wide search dropdown ---------- */
.search kbd {
  position: absolute; right: 14px; top: 50%; transform: translateY(-50%);
  min-width: 24px; height: 24px; padding: 0 7px;
  display: grid; place-items: center;
  border-radius: 8px; font: 700 12px/1 "Inter", sans-serif; color: var(--faint);
  background: rgba(255, 255, 255, 0.05); border: 1px solid var(--border-strong);
  pointer-events: none; transition: opacity 0.2s;
}
.search input:focus ~ kbd, .search input:not(:placeholder-shown) ~ kbd { opacity: 0; }
.search input::-webkit-search-cancel-button { filter: invert(0.6); cursor: pointer; }
.search-results {
  position: absolute; left: 0; right: 0; top: calc(100% + 10px); z-index: 80;
  max-height: min(440px, 70vh); overflow-y: auto;
  padding: 8px;
  border-radius: 24px;
  background: rgba(14, 13, 20, 0.96);
  backdrop-filter: blur(20px) saturate(160%); -webkit-backdrop-filter: blur(20px) saturate(160%);
  border: 1px solid rgba(255, 255, 255, 0.1);
  box-shadow: 0 30px 70px rgba(0, 0, 0, 0.7), 0 0 0 1px rgba(124, 58, 237, 0.12);
  animation: drop 0.18s ease-out;
}
.search-results[hidden] { display: none; }
.sr-item { display: flex; align-items: center; gap: 12px; padding: 10px 12px; border-radius: 16px; transition: background 0.15s; }
.sr-item.on, .sr-item:hover { background: rgba(124, 58, 237, 0.14); }
.sr-ico { width: 36px; height: 36px; border-radius: 50%; display: grid; place-items: center; flex-shrink: 0; color: #a78bfa; background: rgba(124, 58, 237, 0.14); border: 1px solid rgba(139, 92, 246, 0.3); }
.sr-ico svg { width: 16px; height: 16px; }
.sr-ico.t-doc { color: #60a5fa; background: rgba(59, 130, 246, 0.14); border-color: rgba(59, 130, 246, 0.3); }
.sr-ico.t-app { color: #34d399; background: rgba(16, 185, 129, 0.14); border-color: rgba(16, 185, 129, 0.3); }
.sr-ico.t-service { color: #fbbf24; background: rgba(245, 158, 11, 0.12); border-color: rgba(245, 158, 11, 0.3); }
.sr-text { flex: 1; min-width: 0; }
.sr-text b { display: block; font-size: 14px; font-weight: 700; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.sr-text small { display: block; font-size: 12px; color: var(--faint); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.sr-text mark { background: none; color: #c4b5fd; }
.sr-type { font-size: 10px; font-weight: 800; letter-spacing: 0.1em; text-transform: uppercase; color: var(--faint); padding: 4px 9px; border-radius: var(--pill); border: 1px solid var(--border-strong); flex-shrink: 0; }
.sr-empty { padding: 18px; text-align: center; color: var(--muted); font-size: 14px; }
@media (max-width: 720px) {
  .search kbd { display: none; }
  .search-results { border-radius: 20px; max-height: 60vh; }
  .sr-type { display: none; }
}

/* ---------- Portfolio hero v2 ---------- */
.p-bg { position: absolute; inset: 0; z-index: -1; border-radius: inherit; overflow: hidden; pointer-events: none; }
.p-bg::before {
  content: ""; position: absolute; inset: 0;
  background-image: linear-gradient(rgba(255, 255, 255, 0.035) 1px, transparent 1px), linear-gradient(90deg, rgba(255, 255, 255, 0.035) 1px, transparent 1px);
  background-size: 44px 44px;
  -webkit-mask-image: radial-gradient(ellipse 70% 70% at 60% 40%, #000, transparent 75%);
          mask-image: radial-gradient(ellipse 70% 70% at 60% 40%, #000, transparent 75%);
}
.blob { position: absolute; border-radius: 50%; filter: blur(70px); opacity: 0.55; animation: drift 18s ease-in-out infinite alternate; }
.b1 { width: 420px; height: 420px; left: -120px; top: -140px; background: #6d28d9; }
.b2 { width: 380px; height: 380px; right: 4%; top: 18%; background: #4338ca; opacity: 0.4; animation-delay: -6s; }
.b3 { width: 300px; height: 300px; left: 38%; bottom: -180px; background: #2563eb; opacity: 0.28; animation-delay: -12s; }
@keyframes drift { 0% { transform: translate(0, 0) scale(1); } 50% { transform: translate(40px, 30px) scale(1.1); } 100% { transform: translate(-30px, 20px) scale(0.95); } }

.p-hero { min-height: 640px; padding-bottom: 72px; }
.p-hero h1 { margin: 22px 0 14px; }
.p-hero h1 .hi { display: block; font-size: 0.62em; letter-spacing: -0.035em; color: #e9e9f0; margin-bottom: 4px; }
.p-hero h1 .name { display: inline-block; background-size: 200% 100%; }
.wave { display: inline-block; transform-origin: 70% 75%; animation: wave 2.6s ease-in-out infinite; }
@keyframes wave { 0%, 60%, 100% { transform: rotate(0); } 10%, 30% { transform: rotate(16deg); } 20% { transform: rotate(-8deg); } 40% { transform: rotate(-4deg); } 50% { transform: rotate(10deg); } }

.p-rotator { margin: 0 0 16px; font-size: clamp(19px, 2vw, 24px); font-weight: 800; letter-spacing: -0.02em; color: var(--muted); min-height: 1.4em; }
.p-rotator .rot { color: #fff; background: linear-gradient(90deg, #c4b5fd, #93c5fd); -webkit-background-clip: text; background-clip: text; color: transparent; }
.p-rotator .rot::after { content: ""; display: inline-block; width: 3px; height: 1.05em; margin-left: 4px; vertical-align: -0.15em; border-radius: 2px; background: #a78bfa; animation: blink 1s steps(2) infinite; }
@keyframes blink { 50% { opacity: 0; } }

.hero-actions .btn svg { width: 18px; height: 18px; }
.hero-actions .btn-primary svg { transition: transform 0.2s; }
.hero-actions .btn-primary:hover svg { transform: translateX(4px); }

.p-foot { display: flex; align-items: center; flex-wrap: wrap; gap: 20px 28px; margin-top: 36px; }
.p-foot .p-founder { margin-top: 0; }
.p-social { display: grid; gap: 10px; }
.p-social small { font-size: 11px; font-weight: 800; letter-spacing: 0.16em; text-transform: uppercase; color: var(--faint); }
.p-social .hero-socials { margin-top: 0; gap: 10px; }
.p-social .social { width: 42px; height: 42px; }
.p-social .social svg { width: 18px; height: 18px; }

@property --spin { syntax: "<angle>"; inherits: false; initial-value: 0deg; }
.p-frame {
  background: conic-gradient(from var(--spin), #a78bfa, #6366f1, #3b82f6, #22d3ee, #a78bfa);
  animation: spinBorder 6s linear infinite;
  box-shadow: 0 40px 90px rgba(0, 0, 0, 0.6), 0 0 60px rgba(124, 58, 237, 0.35);
}
@keyframes spinBorder { to { --spin: 360deg; } }
.p-frame img { filter: saturate(1.05) contrast(1.03); }

.p-orbit { position: absolute; z-index: 0; left: -14%; right: -14%; top: -8%; aspect-ratio: 1; border-radius: 50%; border: 1.5px dashed rgba(139, 92, 246, 0.35); animation: orbit 40s linear infinite; }
.p-orbit span { position: absolute; top: -6px; left: 50%; width: 12px; height: 12px; margin-left: -6px; border-radius: 50%; background: #a78bfa; box-shadow: 0 0 18px #a78bfa, 0 0 4px #fff; }
.p-orbit.o2 { left: -26%; right: -26%; top: -16%; border: 1px solid rgba(59, 130, 246, 0.14); animation-duration: 70s; animation-direction: reverse; }
.p-orbit.o2 span { width: 8px; height: 8px; margin-left: -4px; top: -4px; background: #60a5fa; box-shadow: 0 0 14px #60a5fa; }
@keyframes orbit { to { transform: rotate(360deg); } }

.float-chip { padding: 7px 16px 7px 7px; gap: 10px; }
.float-chip .ci { width: 30px; height: 30px; border-radius: 50%; display: grid; place-items: center; background: rgba(124, 58, 237, 0.25); border: 1px solid rgba(139, 92, 246, 0.45); }
.float-chip .ci svg { width: 15px; height: 15px; color: #c4b5fd; }
.float-chip .ci.blue { background: rgba(59, 130, 246, 0.22); border-color: rgba(59, 130, 246, 0.45); }
.float-chip .ci.blue svg { color: #93c5fd; }
.float-chip .ci.green { background: rgba(16, 185, 129, 0.2); border-color: rgba(16, 185, 129, 0.45); }
.float-chip .ci.green svg { color: #6ee7b7; }
.float-chip .ci.amber { background: rgba(245, 158, 11, 0.18); border-color: rgba(245, 158, 11, 0.45); }
.float-chip .ci.amber svg { color: #fcd34d; }
.float-chip b { color: #fff; }
.c4 { top: 2%; right: -6%; animation-delay: -3s; }

.scroll-cue { position: absolute; left: 50%; bottom: 18px; transform: translateX(-50%); opacity: 0.6; transition: opacity 0.2s; }
.scroll-cue:hover { opacity: 1; }
.mouse { display: block; width: 24px; height: 38px; border-radius: 14px; border: 2px solid rgba(255, 255, 255, 0.35); position: relative; }
.mouse i { position: absolute; left: 50%; top: 7px; width: 4px; height: 8px; margin-left: -2px; border-radius: 2px; background: #a78bfa; animation: scrollDot 1.8s ease-in-out infinite; }
@keyframes scrollDot { 0% { transform: translateY(0); opacity: 1; } 70% { transform: translateY(12px); opacity: 0; } 100% { opacity: 0; } }

@media (max-width: 1024px) {
  .p-hero { min-height: 0; padding-bottom: 56px; }
  .p-foot { justify-content: center; }
  .p-social { justify-items: center; }
  .p-photo { margin: 30px auto 10px; }
  .scroll-cue { display: none; }
}
@media (max-width: 720px) {
  .p-hero { padding-bottom: 32px; }
  .p-hero h1 .hi { font-size: 0.6em; }
  .p-rotator { font-size: 18px; }
  .hero-actions .btn svg { display: none; }
  .p-foot { flex-direction: column; gap: 22px; margin-top: 28px; }
  .p-social .social { width: 40px; height: 40px; }
  .c4 { display: none; }
  .float-chip { padding: 5px 12px 5px 5px; gap: 8px; }
  .float-chip .ci { width: 24px; height: 24px; }
  .float-chip .ci svg { width: 12px; height: 12px; }
  .p-orbit.o2 { display: none; }
  .blob { filter: blur(50px); }
}
@media (prefers-reduced-motion: reduce) {
  .blob, .wave, .p-orbit, .p-frame, .mouse i, .p-rotator .rot::after { animation: none; }
}
@media (max-width: 720px) { .p-hero .badge { font-size: 9.5px; letter-spacing: 0.1em; padding: 7px 12px; } }

/* ---------- Portfolio stats v2 ---------- */
.stats .stat {
  --tone: 124, 58, 237;
  display: flex; align-items: center; gap: 18px;
  padding: 26px 24px;
  text-align: left;
  overflow: hidden;
  background:
    radial-gradient(260px 160px at 0% 0%, rgba(var(--tone), 0.16), transparent 70%),
    var(--surface);
}
.stats .stat::before {
  content: ""; position: absolute; top: 0; left: 24px; right: 24px; height: 2px;
  border-radius: 2px;
  background: linear-gradient(90deg, transparent, rgba(var(--tone), 0.9), transparent);
  box-shadow: 0 0 18px rgba(var(--tone), 0.8);
}
.stats .stat.hover:hover { border-color: rgba(var(--tone), 0.45); box-shadow: 0 20px 50px rgba(0, 0, 0, 0.45), 0 0 40px rgba(var(--tone), 0.15); }
.stat-ico {
  width: 58px; height: 58px; border-radius: 50%; flex-shrink: 0;
  display: grid; place-items: center;
  color: rgb(var(--tone));
  background: rgba(var(--tone), 0.14);
  border: 1px solid rgba(var(--tone), 0.4);
  box-shadow: 0 0 30px rgba(var(--tone), 0.25), inset 0 1px 0 rgba(255, 255, 255, 0.08);
  transition: transform 0.3s;
}
.stat-ico svg { width: 24px; height: 24px; filter: brightness(1.35); }
.stats .stat:hover .stat-ico { transform: scale(1.08) rotate(-6deg); }
.stat-body { min-width: 0; }
.stats .stat b { font-size: 36px; line-height: 1; background: linear-gradient(90deg, #fff, rgba(var(--tone), 1) 160%); -webkit-background-clip: text; background-clip: text; color: transparent; font-variant-numeric: tabular-nums; }
.stats .stat-body > span { display: block; margin-top: 6px; font-size: 14px; font-weight: 700; color: #e4e4ea; }
.stats .stat small { display: block; margin-top: 2px; font-size: 12px; color: var(--faint); line-height: 1.4; }

@media (max-width: 720px) {
  .stats .stat { flex-direction: column; align-items: flex-start; gap: 12px; padding: 20px 16px; }
  .stat-ico { width: 46px; height: 46px; }
  .stat-ico svg { width: 20px; height: 20px; }
  .stats .stat b { font-size: 28px; }
  .stats .stat-body > span { font-size: 13px; }
  .stats .stat small { font-size: 11px; }
}

/* ---------- Portfolio hero: full-width aligned text column ---------- */
.p-intro { width: 100%; min-width: 0; }
.p-hero .lead { max-width: none; }
.p-hero .hero-actions { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.p-hero .hero-actions .btn { width: 100%; height: 56px; }
.p-foot {
  display: flex; align-items: center; justify-content: space-between; gap: 18px;
  margin-top: 28px; padding: 12px 14px 12px 12px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.025);
  border: 1px solid var(--border);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.04);
}
.p-foot .p-founder { padding: 0; background: none; border: 0; flex-shrink: 0; }
.p-social { display: flex; align-items: center; gap: 14px; }
.p-social small { display: none; }
.p-social .hero-socials { flex-wrap: nowrap; gap: 8px; }
.p-social .social { width: 40px; height: 40px; }
.p-social .social svg { width: 17px; height: 17px; }
@media (max-width: 1280px) {
  .p-foot { flex-direction: column; align-items: stretch; border-radius: 28px; padding: 16px; }
  .p-foot .p-founder { justify-content: flex-start; }
  .p-social { justify-content: space-between; padding-top: 14px; border-top: 1px solid var(--border); }
  .p-social small { display: block; }
}
@media (max-width: 1024px) {
  .p-intro { max-width: 640px; margin: 0 auto; }
  .p-foot .p-founder { margin: 0; }
}
@media (max-width: 720px) {
  .p-hero .hero-actions { grid-template-columns: 1fr; gap: 12px; }
  .p-hero .hero-actions .btn { height: 52px; }
  .p-foot { padding: 14px; gap: 14px; }
  .p-social { flex-direction: column; gap: 10px; }
  .p-social .hero-socials { width: 100%; justify-content: space-between; }
  .p-social .social { width: 38px; height: 38px; }
}
/* Hero foot: always the stacked full-width card (row layout was too tight) */
.p-foot { flex-direction: column; align-items: stretch; flex-wrap: nowrap; border-radius: 28px; padding: 16px 18px; gap: 14px; }
.p-social { justify-content: space-between; padding-top: 14px; border-top: 1px solid var(--border); }
.p-social small { display: block; }
@media (max-width: 720px) { .p-social { flex-direction: column; } }

/* ---------- Portfolio hero: circular portrait, concentric orbits ---------- */
.p-hero { grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.9fr); align-items: center; }
.p-photo { position: relative; width: 100%; max-width: 470px; aspect-ratio: 1; justify-self: center; align-self: center; }
.p-photo::before { inset: 0; background: radial-gradient(circle, rgba(124, 58, 237, 0.5) 0%, rgba(59, 130, 246, 0.18) 45%, transparent 68%); filter: blur(10px); }
.p-frame { position: absolute; inset: 13%; border-radius: 50%; padding: 5px; }
.p-frame::after { content: ""; position: absolute; inset: -14px; border-radius: 50%; border: 1px solid rgba(167, 139, 250, 0.22); pointer-events: none; }
.p-frame img { width: 100%; height: 100%; aspect-ratio: auto; border-radius: 50%; object-fit: cover; object-position: 50% 16%; border: 5px solid #0d0d12; }
.p-orbit { inset: 3%; left: 3%; right: 3%; top: 3%; aspect-ratio: auto; }
.p-orbit.o2 { inset: -7%; left: -7%; right: -7%; top: -7%; }

.c1 { top: 20%; left: -3%; right: auto; bottom: auto; }
.c2 { top: 54%; right: -7%; left: auto; bottom: auto; }
.c3 { bottom: 8%; left: 2%; top: auto; right: auto; }
.c4 { top: 4%; right: 2%; left: auto; bottom: auto; }

@media (max-width: 1024px) {
  .p-hero { grid-template-columns: 1fr; }
  .p-photo { max-width: 400px; margin: 10px auto 20px; }
}
@media (max-width: 720px) {
  .p-photo { max-width: 290px; margin: 0 auto 6px; }
  .p-frame { inset: 11%; padding: 4px; }
  .p-frame::after { inset: -10px; }
  .p-frame img { border-width: 4px; }
  .c1 { top: 14%; left: -6%; }
  .c2 { top: 56%; right: -8%; }
  .c3 { bottom: 4%; left: 0; }
}
.p-hero { padding-bottom: 56px; }
@media (max-width: 720px) { .p-hero { padding-bottom: 32px; } }

/* ---------- Portfolio: About v2 ---------- */
.about2 {
  display: grid; grid-template-columns: minmax(0, 0.95fr) minmax(0, 1.05fr); gap: 56px; align-items: center;
  padding: 56px;
  overflow: hidden;
  background:
    radial-gradient(520px 320px at 0% 0%, rgba(124, 58, 237, 0.18), transparent 70%),
    radial-gradient(420px 300px at 100% 100%, rgba(59, 130, 246, 0.1), transparent 70%),
    var(--surface);
}
.about-mark {
  position: absolute; right: -10px; top: -34px; z-index: -1;
  font-size: 170px; font-weight: 900; letter-spacing: -0.06em; line-height: 1;
  color: transparent; -webkit-text-stroke: 1px rgba(255, 255, 255, 0.05);
  pointer-events: none; user-select: none;
}
.about2 .eyebrow { display: inline-flex; align-items: center; gap: 10px; }
.about2 .eyebrow i { width: 26px; height: 2px; border-radius: 2px; background: linear-gradient(90deg, #a78bfa, #60a5fa); }
.about2 h2 { font-size: clamp(30px, 3.4vw, 42px); font-weight: 900; letter-spacing: -0.04em; line-height: 1.1; margin: 4px 0 28px; }
.facts { list-style: none; margin: 0 0 30px; padding: 0; display: grid; gap: 12px; }
.facts li { display: flex; align-items: center; gap: 14px; padding: 10px 18px 10px 10px; border-radius: var(--pill); background: rgba(255, 255, 255, 0.025); border: 1px solid var(--border); width: fit-content; min-width: 280px; transition: border-color 0.25s, background 0.25s; }
.facts li:hover { border-color: rgba(139, 92, 246, 0.35); background: rgba(124, 58, 237, 0.06); }
.facts .work-ico { width: 42px; height: 42px; }
.facts .work-ico svg { width: 18px; height: 18px; }
.facts small { display: block; font-size: 11px; font-weight: 700; letter-spacing: 0.12em; text-transform: uppercase; color: var(--faint); }
.facts b { display: block; font-size: 15px; }
.about-cta { display: flex; gap: 12px; flex-wrap: wrap; }
.about-cta .btn svg { width: 18px; height: 18px; }

.about-lead { margin: 0 0 28px; font-size: 17px; line-height: 1.85; color: var(--muted); }
.about-lead strong { color: #fff; font-weight: 600; }
.values { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; }
.value {
  display: flex; flex-direction: column; gap: 10px;
  padding: 20px; border-radius: 24px;
  background: rgba(255, 255, 255, 0.025); border: 1px solid var(--border);
  transition: transform 0.25s, border-color 0.25s, background 0.25s;
}
.value:hover { transform: translateY(-3px); border-color: rgba(139, 92, 246, 0.35); background: rgba(124, 58, 237, 0.06); }
.value .work-ico { width: 44px; height: 44px; }
.value .work-ico svg { width: 20px; height: 20px; }
.value b { font-size: 15px; font-weight: 800; letter-spacing: -0.01em; }
.value small { font-size: 12.5px; color: var(--faint); line-height: 1.5; }

@media (max-width: 1024px) {
  .about2 { grid-template-columns: 1fr; gap: 36px; padding: 44px 40px; }
  .about-mark { font-size: 130px; }
}
@media (max-width: 720px) {
  .about2 { padding: 30px 20px; gap: 28px; }
  .about-mark { font-size: 90px; top: -20px; }
  .facts li { min-width: 0; width: 100%; }
  .about-cta .btn { flex: 1; }
  .about-lead { font-size: 15.5px; }
  .values { grid-template-columns: 1fr; }
  .value { flex-direction: row; align-items: center; flex-wrap: wrap; column-gap: 14px; }
  .value small { flex-basis: 100%; }
}
/* About: facts + buttons span the full left column */
.about-left { min-width: 0; }
.facts li { width: 100%; min-width: 0; }
.about-cta { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.about-cta .btn { width: 100%; height: 56px; }
@media (max-width: 720px) { .about-cta { grid-template-columns: 1fr; } .about-cta .btn { height: 52px; } }

/* ---------- Services v2 ---------- */
.svc-head .eyebrow, .section-head .eyebrow { display: inline-flex; align-items: center; gap: 10px; }
.section-head .eyebrow i { width: 26px; height: 2px; border-radius: 2px; background: linear-gradient(90deg, #a78bfa, #60a5fa); }
.service {
  --tone: 139, 92, 246;
  padding: 34px 32px 28px;
  gap: 16px;
  overflow: hidden;
  background:
    radial-gradient(320px 200px at 0% 0%, rgba(var(--tone), 0.12), transparent 70%),
    var(--surface);
}
/* gradient border that lights up on hover */
.service::before {
  content: ""; position: absolute; inset: 0; border-radius: inherit; padding: 1px;
  background: linear-gradient(140deg, rgba(var(--tone), 0.9), transparent 40%, transparent 60%, rgba(var(--tone), 0.6));
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask-composite: xor; mask-composite: exclude;
  opacity: 0; transition: opacity 0.35s; pointer-events: none;
}
.service:hover::before { opacity: 1; }
.service.hover:hover { border-color: transparent; box-shadow: 0 24px 60px rgba(0, 0, 0, 0.5), 0 0 50px rgba(var(--tone), 0.14); }

.svc-num {
  position: absolute; top: 18px; right: 24px;
  font-size: 64px; font-weight: 900; letter-spacing: -0.05em; line-height: 1;
  color: transparent; -webkit-text-stroke: 1px rgba(var(--tone), 0.35);
  transition: -webkit-text-stroke-color 0.3s, transform 0.3s;
}
.service:hover .svc-num { -webkit-text-stroke-color: rgba(var(--tone), 0.8); transform: translateY(-3px); }
.svc-ico {
  width: 62px; height: 62px; border-radius: 50%;
  display: grid; place-items: center;
  color: rgb(var(--tone));
  background: radial-gradient(circle at 30% 25%, rgba(var(--tone), 0.3), rgba(var(--tone), 0.08) 70%);
  border: 1px solid rgba(var(--tone), 0.45);
  box-shadow: 0 0 34px rgba(var(--tone), 0.28), inset 0 1px 0 rgba(255, 255, 255, 0.1);
  transition: transform 0.35s;
}
.svc-ico svg { width: 26px; height: 26px; filter: brightness(1.3); }
.service:hover .svc-ico { transform: scale(1.06) rotate(-6deg); }
.service h3 { margin: 8px 0 0; font-size: 21px; }
.service > p { font-size: 14.5px; }
.svc-points { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.svc-points li { display: flex; gap: 10px; align-items: center; font-size: 14px; color: #d4d4dc; }
.svc-points svg { width: 20px; height: 20px; padding: 4px; flex-shrink: 0; border-radius: 50%; color: rgb(var(--tone)); background: rgba(var(--tone), 0.14); filter: brightness(1.25); }
.svc-cta {
  margin-top: auto;
  display: flex; align-items: center; justify-content: space-between;
  height: 54px; padding: 0 7px 0 24px;
  border-radius: 999px;
  font-size: 13px; font-weight: 800; letter-spacing: 0.08em; text-transform: uppercase;
  color: #e4e4ea;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--border-strong);
  transition: background 0.3s, border-color 0.3s, color 0.3s;
}
.svc-cta i { width: 40px; height: 40px; border-radius: 50%; display: grid; place-items: center; background: rgba(var(--tone), 0.16); color: rgb(var(--tone)); transition: background 0.3s, color 0.3s, transform 0.3s; }
.svc-cta svg { width: 18px; height: 18px; }
.service:hover .svc-cta, .svc-cta:focus-visible { border-color: rgba(var(--tone), 0.5); background: rgba(var(--tone), 0.08); color: #fff; }
.svc-cta:hover i, .service:hover .svc-cta i { background: rgb(var(--tone)); color: #fff; transform: rotate(-45deg); }
.services { margin-top: 4px; }
@media (max-width: 720px) {
  .service { padding: 26px 22px 22px; }
  .svc-num { font-size: 52px; top: 16px; right: 18px; }
  .svc-ico { width: 54px; height: 54px; }
  .svc-ico svg { width: 22px; height: 22px; }
}
.svc-points svg { width: 22px; height: 22px; padding: 4px; stroke-width: 3; background: rgba(var(--tone), 0.2); filter: brightness(1.5); }
.about2 h2 { margin-top: 0; }

/* ---------- Timeline v2 (Education & Experience) ---------- */
.timeline { --tl: 139, 92, 246; }
.timeline.exp { --tl: 59, 130, 246; }
.tl-item {
  padding: 28px 30px;
  background:
    radial-gradient(300px 180px at 0% 0%, rgba(var(--tl), 0.12), transparent 70%),
    var(--surface);
}
.tl-item:not(.is-sample) { border-color: rgba(var(--tl), 0.22); }
.tl-top { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin-bottom: 14px; }
.tl-period { margin-left: 0; display: inline-flex; align-items: center; gap: 7px; padding: 6px 14px 6px 10px; color: #e4e4ea; background: rgba(var(--tl), 0.14); border-color: rgba(var(--tl), 0.4); }
.tl-period svg { width: 15px; height: 15px; color: rgb(var(--tl)); filter: brightness(1.4); }
.tl-title { margin: 0; font-size: 21px; font-weight: 800; letter-spacing: -0.02em; }
.tl-org { display: flex; align-items: center; gap: 8px; color: #c4b5fd; }
.timeline.exp .tl-org { color: #93c5fd; }
.tl-org svg { width: 16px; height: 16px; flex-shrink: 0; }
.tl-dot {
  width: 40px; height: 40px;
  background: linear-gradient(135deg, rgb(var(--tl)), var(--accent));
  box-shadow: 0 0 0 6px var(--bg), 0 0 0 7px rgba(var(--tl), 0.35), 0 0 28px rgba(var(--tl), 0.6);
}
.tl-dot svg { width: 18px; height: 18px; }
.timeline > .tl-item:first-child .tl-dot::after {
  content: ""; position: absolute; inset: -7px; border-radius: 50%;
  border: 2px solid rgba(var(--tl), 0.6);
  animation: ping 2.4s cubic-bezier(0, 0, .2, 1) infinite;
}
@keyframes ping { 0% { transform: scale(1); opacity: 0.9; } 80%, 100% { transform: scale(1.7); opacity: 0; } }
.timeline::before { background: linear-gradient(rgba(var(--tl), 0.9), rgba(var(--tl), 0.25) 70%, transparent); box-shadow: 0 0 12px rgba(var(--tl), 0.5); }

/* Desktop: alternating zig-zag around a centre line */
@media (min-width: 1025px) {
  .timeline { padding-left: 0; gap: 26px; }
  .timeline::before { left: 50%; margin-left: -1px; top: 10px; bottom: 10px; }
  .tl-item { width: calc(50% - 52px); }
  .tl-item:nth-child(odd) { margin-right: auto; }
  .tl-item:nth-child(even) { margin-left: auto; }
  .tl-item:nth-child(odd) .tl-dot { left: auto; right: -72px; }
  .tl-item:nth-child(even) .tl-dot { left: -72px; }
  .tl-dot { top: 30px; }
  /* small pointer toward the centre line */
  .tl-item::before {
    content: ""; position: absolute; top: 44px; width: 14px; height: 14px;
    background: var(--surface); border: 1px solid rgba(var(--tl), 0.22); transform: rotate(45deg);
  }
  .tl-item.is-sample::before { border-style: dashed; border-color: var(--border); }
  .tl-item:nth-child(odd)::before { right: -8px; border-left: 0; border-bottom: 0; }
  .tl-item:nth-child(even)::before { left: -8px; border-right: 0; border-top: 0; }
  .tl-item:nth-child(even) + .tl-item, .tl-item:nth-child(n+2) { margin-top: -40px; }
  .tl-item:first-child { margin-top: 0; }
}
@media (max-width: 1024px) {
  .timeline { padding-left: 44px; }
  .timeline::before { left: 19px; }
  .tl-dot { left: -44px; top: 26px; width: 38px; height: 38px; }
}
@media (max-width: 720px) {
  .timeline { padding-left: 38px; }
  .timeline::before { left: 15px; }
  .tl-dot { left: -38px; width: 32px; height: 32px; box-shadow: 0 0 0 4px var(--bg), 0 0 0 5px rgba(var(--tl), 0.35), 0 0 20px rgba(var(--tl), 0.6); }
  .tl-dot svg { width: 15px; height: 15px; }
  .tl-item { padding: 22px 20px; }
  .tl-title { font-size: 18px; }
}
@media (prefers-reduced-motion: reduce) { .timeline > .tl-item:first-child .tl-dot::after { animation: none; } }

/* ---------- Timeline as a winding road (desktop) ---------- */
@media (min-width: 1025px) {
  .timeline { position: relative; }
  .timeline::before { display: none; }
  .timeline > .tl-item { z-index: 1; }
  .tl-item::before { display: none; }
  .tl-item:nth-child(odd) .tl-dot { left: auto; right: -42px; }
  .tl-item:nth-child(even) .tl-dot { right: auto; left: -42px; }
  .tl-dot { width: 44px; height: 44px; top: 34px; }
  .tl-dot svg { width: 19px; height: 19px; }
}
.road {
  position: absolute; left: 0; top: 0; z-index: 0; overflow: visible; pointer-events: none;
  -webkit-mask-image: linear-gradient(transparent 0, #000 60px, #000 calc(100% - 120px), transparent);
          mask-image: linear-gradient(transparent 0, #000 60px, #000 calc(100% - 120px), transparent);
}
.road path { fill: none; stroke-linecap: round; }
.road .glow { stroke: rgba(var(--tl), 0.22); stroke-width: 54; filter: blur(14px); }
.road .edge { stroke: rgba(var(--tl), 0.35); stroke-width: 34; }
.road .asphalt { stroke: #121119; stroke-width: 30; }
.road .lane { stroke: rgb(var(--tl)); stroke-width: 2.5; stroke-dasharray: 12 14; filter: drop-shadow(0 0 4px rgba(var(--tl), 0.9)); animation: lane 1.6s linear infinite; }
@keyframes lane { to { stroke-dashoffset: -26; } }
@media (prefers-reduced-motion: reduce) { .road .lane { animation: none; } }

/* ---------- Skills v2 ---------- */
.marquee {
  position: relative; overflow: hidden; margin: 0 0 24px;
  padding: 14px 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid var(--border);
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 10%, #000 90%, transparent);
          mask-image: linear-gradient(90deg, transparent, #000 10%, #000 90%, transparent);
}
.marquee-track { display: flex; gap: 36px; padding-right: 36px; width: max-content; animation: marquee 40s linear infinite; }
.marquee:hover .marquee-track { animation-play-state: paused; }
.marquee-track span { display: inline-flex; align-items: center; gap: 10px; font-size: 15px; font-weight: 700; color: #d4d4dc; white-space: nowrap; }
.marquee-track svg { width: 18px; height: 18px; padding: 3px; border-radius: 50%; color: #c4b5fd; background: rgba(124, 58, 237, 0.2); stroke-width: 3; }
@keyframes marquee { to { transform: translateX(-50%); } }

.skill2 {
  --tone: 139, 92, 246;
  padding: 28px; overflow: hidden;
  display: flex; flex-direction: column; gap: 22px;
  background:
    radial-gradient(280px 180px at 0% 0%, rgba(var(--tone), 0.14), transparent 70%),
    var(--surface);
}
.skill2::before {
  content: ""; position: absolute; inset: 0; border-radius: inherit; padding: 1px;
  background: linear-gradient(140deg, rgba(var(--tone), 0.9), transparent 45%, transparent 60%, rgba(var(--tone), 0.5));
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask-composite: xor; mask-composite: exclude;
  opacity: 0; transition: opacity 0.35s; pointer-events: none;
}
.skill2:hover::before { opacity: 1; }
.skill2.hover:hover { border-color: transparent; box-shadow: 0 24px 60px rgba(0, 0, 0, 0.5), 0 0 46px rgba(var(--tone), 0.14); }
.sk-watermark { position: absolute; right: -26px; bottom: -30px; z-index: -1; color: rgba(var(--tone), 0.08); transition: transform 0.5s, color 0.4s; }
.sk-watermark svg { width: 150px; height: 150px; stroke-width: 1.4; }
.skill2:hover .sk-watermark { transform: rotate(-10deg) scale(1.06); color: rgba(var(--tone), 0.14); }
.sk-head { display: flex; align-items: center; gap: 14px; }
.sk-ico {
  width: 54px; height: 54px; border-radius: 50%; flex-shrink: 0;
  display: grid; place-items: center;
  color: rgb(var(--tone));
  background: radial-gradient(circle at 30% 25%, rgba(var(--tone), 0.32), rgba(var(--tone), 0.08) 70%);
  border: 1px solid rgba(var(--tone), 0.45);
  box-shadow: 0 0 30px rgba(var(--tone), 0.28), inset 0 1px 0 rgba(255, 255, 255, 0.1);
}
.sk-ico svg { width: 24px; height: 24px; filter: brightness(1.3); }
.sk-head h3 { margin: 0; font-size: 18px; font-weight: 800; letter-spacing: -0.015em; }
.sk-head small { font-size: 12px; font-weight: 700; color: rgb(var(--tone)); filter: brightness(1.4); letter-spacing: 0.04em; }
.sk-chips { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 8px; }
.sk-chips li {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 8px 14px 8px 11px; border-radius: 999px;
  font-size: 13px; font-weight: 600; color: #e4e4ea;
  background: rgba(255, 255, 255, 0.035); border: 1px solid var(--border-strong);
  transition: background 0.2s, border-color 0.2s, transform 0.2s;
}
.sk-chips li i { width: 7px; height: 7px; border-radius: 50%; background: rgb(var(--tone)); box-shadow: 0 0 8px rgba(var(--tone), 0.9); }
.sk-chips li:hover { background: rgba(var(--tone), 0.14); border-color: rgba(var(--tone), 0.5); transform: translateY(-2px); }
@media (max-width: 720px) {
  .marquee { padding: 11px 0; margin-bottom: 18px; }
  .marquee-track { gap: 26px; padding-right: 26px; animation-duration: 30s; }
  .marquee-track span { font-size: 13.5px; }
  .skill2 { padding: 22px; }
  .sk-watermark svg { width: 120px; height: 120px; }
}
@media (prefers-reduced-motion: reduce) { .marquee-track { animation: none; } }
/* Skills: chips fill the card width in an even grid */
.sk-chips { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.sk-chips li { width: 100%; justify-content: flex-start; padding: 10px 14px; min-width: 0; }
.sk-chips li:last-child:nth-child(odd) { grid-column: 1 / -1; }
.sk-head { gap: 12px; }
.sk-ico { width: 48px; height: 48px; }
.sk-ico svg { width: 21px; height: 21px; }
.sk-head > div { min-width: 0; }
.sk-head h3 { font-size: 17px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.sk-chips li { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.sk-chips li i { flex-shrink: 0; }
/* Skills: 2x2 on desktop so chip names never truncate */
@media (min-width: 721px) { .skills { grid-template-columns: repeat(2, minmax(0, 1fr)); } .sk-chips { grid-template-columns: repeat(3, minmax(0, 1fr)); } .sk-chips li:last-child:nth-child(odd) { grid-column: auto; } }
@media (min-width: 721px) and (max-width: 1024px) { .sk-chips { grid-template-columns: repeat(2, minmax(0, 1fr)); } .sk-chips li:last-child:nth-child(odd) { grid-column: 1 / -1; } }

/* ---------- Projects: premium app cards v3 ---------- */
.work-app.pa { --tone: 139, 92, 246; padding: 0; gap: 0; overflow: hidden; }
.pa::before {
  content: ""; position: absolute; inset: 0; border-radius: inherit; padding: 1px; z-index: 2;
  background: linear-gradient(140deg, rgba(var(--tone), 0.9), transparent 40%, transparent 60%, rgba(var(--tone), 0.5));
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask-composite: xor; mask-composite: exclude;
  opacity: 0; transition: opacity 0.35s; pointer-events: none;
}
.pa:hover::before { opacity: 1; }
.work-app.pa:hover { border-color: transparent; box-shadow: 0 30px 70px rgba(0, 0, 0, 0.55), 0 0 60px rgba(var(--tone), 0.16); }

.pa-banner {
  position: relative; height: 210px; overflow: hidden;
  background:
    radial-gradient(400px 220px at 75% 100%, rgba(var(--tone), 0.55), transparent 70%),
    linear-gradient(160deg, rgba(var(--tone), 0.28), rgba(10, 10, 16, 0.9) 70%);
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}
.pa-banner::before {
  content: ""; position: absolute; inset: 0;
  background-image: linear-gradient(rgba(255, 255, 255, 0.05) 1px, transparent 1px), linear-gradient(90deg, rgba(255, 255, 255, 0.05) 1px, transparent 1px);
  background-size: 28px 28px;
  -webkit-mask-image: radial-gradient(ellipse at 70% 60%, #000, transparent 75%);
          mask-image: radial-gradient(ellipse at 70% 60%, #000, transparent 75%);
}
.pa-bg { position: absolute; left: -40px; top: -60px; width: 260px; height: 260px; border-radius: 50%; filter: blur(50px) saturate(1.4); opacity: 0.45; }
.pa-phone {
  position: absolute; right: 44px; top: 34px;
  width: 150px; height: 230px;
  border-radius: 28px;
  padding-top: 46px;
  display: flex; flex-direction: column; align-items: center; gap: 12px;
  background: linear-gradient(170deg, #1d1b2a, #0c0b12);
  border: 4px solid #2a2838;
  box-shadow: 0 24px 50px rgba(0, 0, 0, 0.6), 0 0 0 1px rgba(255, 255, 255, 0.06), 0 0 50px rgba(var(--tone), 0.35);
  transform: rotate(-6deg) translateY(8px);
  transition: transform 0.5s cubic-bezier(.2, .8, .2, 1);
}
.pa:hover .pa-phone { transform: rotate(-2deg) translateY(-6px); }
.pa-notch { position: absolute; top: 9px; left: 50%; width: 46px; height: 10px; margin-left: -23px; border-radius: 6px; background: #000; }
.pa-phone img { width: 62px; height: 62px; border-radius: 50%; box-shadow: 0 0 30px rgba(var(--tone), 0.7); }
.pa-phone b { font-size: 12px; font-weight: 800; letter-spacing: -0.01em; color: #fff; text-align: center; padding: 0 10px; }
.pa-load { width: 70px; height: 4px; border-radius: 4px; background: rgba(255, 255, 255, 0.08); overflow: hidden; position: relative; }
.pa-load::after { content: ""; position: absolute; inset: 0; width: 40%; border-radius: 4px; background: rgb(var(--tone)); animation: load 1.8s ease-in-out infinite; }
@keyframes load { 0% { transform: translateX(-100%); } 100% { transform: translateX(260%); } }
.pa-banner .status { position: absolute; left: 24px; top: 22px; backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px); }

.pa-body { position: relative; padding: 0 30px 30px; display: flex; flex-direction: column; gap: 18px; flex: 1; }
.pa-head { display: flex; align-items: flex-end; gap: 16px; margin-top: -44px; }
.pa-icon { width: 92px !important; height: 92px !important; padding: 4px; box-shadow: 0 16px 40px rgba(0, 0, 0, 0.6), 0 0 0 5px var(--surface), 0 0 34px rgba(var(--tone), 0.5) !important; }
.pa-head .wa-title { padding-bottom: 6px; }
.pa-head h3 { margin: 0; font-size: 24px; font-weight: 900; letter-spacing: -0.03em; }
.pa-desc { margin: 0; color: var(--muted); font-size: 15px; line-height: 1.7; }
.pa-feats { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.pa-feats li {
  display: flex; align-items: center; gap: 12px;
  padding: 10px 14px 10px 10px; border-radius: 16px;
  font-size: 14px; color: #e4e4ea;
  background: rgba(255, 255, 255, 0.025); border: 1px solid var(--border);
  transition: border-color 0.2s, background 0.2s;
}
.pa-feats li:hover { border-color: rgba(var(--tone), 0.4); background: rgba(var(--tone), 0.06); }
.pa-feats li span { width: 28px; height: 28px; border-radius: 50%; flex-shrink: 0; display: grid; place-items: center; color: rgb(var(--tone)); background: rgba(var(--tone), 0.16); }
.pa-feats li svg { width: 15px; height: 15px; stroke-width: 3; filter: brightness(1.4); }
.pa .stores { margin-top: auto; }
a.store:hover { border-color: rgba(var(--tone), 0.7); box-shadow: 0 12px 30px rgba(var(--tone), 0.35); }

@media (max-width: 720px) {
  .pa-banner { height: 170px; }
  .pa-phone { right: 22px; top: 28px; width: 120px; height: 190px; padding-top: 38px; border-radius: 24px; }
  .pa-phone img { width: 50px; height: 50px; }
  .pa-phone b { font-size: 10.5px; }
  .pa-body { padding: 0 20px 22px; }
  .pa-head { margin-top: -36px; }
  .pa-icon { width: 76px !important; height: 76px !important; }
  .pa-head h3 { font-size: 21px; }
}
@media (prefers-reduced-motion: reduce) { .pa-load::after { animation: none; } }
/* Projects: only the icon overlaps the banner; title sits below it */
.pa-head { align-items: flex-start; margin-top: -46px; }
.pa-head .wa-title { padding: 54px 0 0; }
@media (max-width: 720px) { .pa-head { margin-top: -38px; } .pa-head .wa-title { padding-top: 44px; } .pa-phone { right: 18px; top: 22px; width: 104px; height: 168px; padding-top: 32px; } .pa-phone img { width: 44px; height: 44px; } }

/* ---------- Projects: infrastructure cards + pipeline ---------- */
.infra {
  --tone: 139, 92, 246;
  padding: 28px; gap: 16px; overflow: hidden;
  background:
    radial-gradient(300px 180px at 0% 0%, rgba(var(--tone), 0.14), transparent 70%),
    var(--surface);
}
.infra::before {
  content: ""; position: absolute; inset: 0; border-radius: inherit; padding: 1px;
  background: linear-gradient(140deg, rgba(var(--tone), 0.9), transparent 45%, transparent 60%, rgba(var(--tone), 0.5));
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask-composite: xor; mask-composite: exclude;
  opacity: 0; transition: opacity 0.35s; pointer-events: none;
}
.infra:hover::before { opacity: 1; }
.infra.hover:hover { border-color: transparent; box-shadow: 0 24px 60px rgba(0, 0, 0, 0.5), 0 0 46px rgba(var(--tone), 0.14); }
.if-top { display: flex; align-items: center; gap: 14px; }
.if-top > div { flex: 1; min-width: 0; }
.if-top small { display: block; font-size: 11px; font-weight: 800; letter-spacing: 0.14em; text-transform: uppercase; color: rgb(var(--tone)); filter: brightness(1.45); }
.if-top h3 { margin: 2px 0 0; font-size: 19px; font-weight: 800; letter-spacing: -0.02em; }
.if-count { display: grid; justify-items: center; padding: 6px 12px; border-radius: 16px; background: rgba(var(--tone), 0.12); border: 1px solid rgba(var(--tone), 0.35); font-size: 20px; font-weight: 900; line-height: 1.1; }
.if-count small { font-size: 9.5px; letter-spacing: 0.1em; color: var(--muted); filter: none; }
.infra > p { font-size: 14px; }
.if-code { border-radius: 18px; overflow: hidden; background: #08080d; border: 1px solid var(--border-strong); font-family: ui-monospace, "Cascadia Code", "JetBrains Mono", Consolas, monospace; }
.if-bar { display: flex; align-items: center; gap: 6px; padding: 9px 12px; background: rgba(255, 255, 255, 0.03); border-bottom: 1px solid var(--border); }
.if-bar i { width: 9px; height: 9px; border-radius: 50%; background: #ff5f57; }
.if-bar i:nth-child(2) { background: #febc2e; }
.if-bar i:nth-child(3) { background: #28c840; }
.if-bar span { margin-left: 8px; font-size: 11.5px; color: var(--faint); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.if-code ul { list-style: none; margin: 0; padding: 10px 12px; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 4px 12px; }
.if-code li { display: flex; align-items: center; gap: 7px; font-size: 12.5px; color: #c9c9d3; min-width: 0; }
.if-code li span { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.if-code li svg { width: 14px; height: 14px; flex-shrink: 0; color: rgb(var(--tone)); filter: brightness(1.4); }
.if-code li.more { color: var(--faint); font-style: italic; }
.infra .tags { margin-top: auto; }

.pipe {
  display: grid; grid-template-columns: minmax(0, 0.8fr) minmax(0, 1.6fr); gap: 32px; align-items: center;
  padding: 32px;
  background:
    radial-gradient(500px 240px at 0% 0%, rgba(245, 158, 11, 0.14), transparent 70%),
    var(--surface);
  border-color: rgba(245, 158, 11, 0.22);
}
.pipe .status { margin: 0 0 14px; display: inline-flex; align-items: center; }
.live-dot.dev { background: #fbbf24; box-shadow: 0 0 10px #fbbf24; }
.pipe h3 { margin: 0 0 8px; font-size: 24px; font-weight: 900; letter-spacing: -0.03em; }
.pipe p { margin: 0; color: var(--muted); font-size: 14.5px; }
.pipe-apps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; }
.pipe-app {
  display: flex; flex-direction: column; align-items: flex-start; gap: 6px;
  padding: 18px; border-radius: 22px;
  background: rgba(245, 158, 11, 0.04);
  border: 1px dashed rgba(245, 158, 11, 0.35);
  transition: transform 0.25s, background 0.25s, border-color 0.25s;
}
.pipe-app:hover { transform: translateY(-3px); background: rgba(245, 158, 11, 0.08); border-style: solid; }
.pipe-ico { width: 46px; height: 46px; border-radius: 50%; display: grid; place-items: center; margin-bottom: 6px; color: #fbbf24; background: rgba(245, 158, 11, 0.14); border: 1px solid rgba(245, 158, 11, 0.4); box-shadow: 0 0 24px rgba(245, 158, 11, 0.2); }
.pipe-ico svg { width: 22px; height: 22px; }
.pipe-app b { font-size: 16px; font-weight: 800; }
.pipe-app small { font-size: 12.5px; color: var(--faint); }
.pipe-tag { margin-top: 6px; font-size: 10.5px; font-weight: 800; letter-spacing: 0.1em; text-transform: uppercase; color: #fbbf24; }

@media (max-width: 1024px) {
  .pipe { grid-template-columns: 1fr; }
}
@media (max-width: 720px) {
  .infra { padding: 22px; }
  .pipe { padding: 24px 20px; gap: 20px; }
  .pipe-apps { grid-template-columns: 1fr; }
  .pipe-app { flex-direction: row; flex-wrap: wrap; align-items: center; column-gap: 12px; }
  .pipe-app .pipe-ico { margin: 0; }
  .pipe-app small, .pipe-tag { flex-basis: 100%; }
}

/* ---------- Infra cards v2: aligned rows via subgrid, file-tree panel ---------- */
@media (min-width: 1025px) {
  .works > .infra { display: grid; grid-row: span 4; grid-template-rows: subgrid; row-gap: 16px; align-content: start; }
  .works > .infra > * { align-self: start; }
  .works > .infra > .tags { align-self: end; margin-top: 0; }
}
.if-top h3 { font-size: 20px; white-space: nowrap; }
.if-top .sk-ico { width: 50px; height: 50px; }
.infra > p { margin: 0; }
.if-code { box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.04), 0 10px 30px rgba(0, 0, 0, 0.35); }
.if-bar span { flex: 1; min-width: 0; }
.if-bar b {
  flex-shrink: 0; padding: 3px 10px; border-radius: 999px;
  font: 800 10.5px/1.4 "Inter", sans-serif; letter-spacing: 0.06em; text-transform: uppercase;
  color: rgb(var(--tone)); background: rgba(var(--tone), 0.14); border: 1px solid rgba(var(--tone), 0.35); filter: brightness(1.25);
}
.if-code ul { grid-template-columns: 1fr; gap: 2px; padding: 10px 8px 12px; }
.if-code li { padding: 4px 8px; border-radius: 8px; font-size: 13px; transition: background 0.2s, color 0.2s; }
.if-code li:hover { background: rgba(var(--tone), 0.1); color: #fff; }
.if-code li em { font-style: normal; color: rgba(255, 255, 255, 0.18); margin-right: -2px; }
.if-code li.more span { font-style: italic; color: var(--faint); }
@media (min-width: 1025px) { .works > .infra > .tags { align-self: start; } }
/* Project tags stretch to fill each row edge to edge */
.infra .tags, .pa .tags { width: 100%; }
.infra .tags span, .pa .tags span { flex: 1 1 auto; text-align: center; padding: 8px 14px; }

/* ---------- How I build: layered architecture ---------- */
.arch2 {
  padding: 28px;
  background:
    radial-gradient(600px 260px at 50% 0%, rgba(124, 58, 237, 0.12), transparent 70%),
    radial-gradient(600px 260px at 50% 100%, rgba(245, 158, 11, 0.07), transparent 70%),
    var(--surface);
}
.ar-tier {
  --tone: 139, 92, 246;
  position: relative;
  display: grid; grid-template-columns: 300px minmax(0, 1fr); gap: 24px; align-items: center;
  padding: 18px;
  border-radius: 26px;
  background: linear-gradient(90deg, rgba(var(--tone), 0.1), rgba(var(--tone), 0.02) 60%);
  border: 1px solid rgba(var(--tone), 0.28);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.04);
  transition: border-color 0.3s, box-shadow 0.3s;
}
.ar-tier:hover { border-color: rgba(var(--tone), 0.55); box-shadow: 0 0 40px rgba(var(--tone), 0.12), inset 0 1px 0 rgba(255, 255, 255, 0.05); }
.ar-label { display: flex; align-items: center; gap: 14px; min-width: 0; }
.ar-num { font-size: 34px; font-weight: 900; letter-spacing: -0.05em; line-height: 1; color: transparent; -webkit-text-stroke: 1px rgba(var(--tone), 0.6); }
.ar-ico { width: 50px; height: 50px; border-radius: 50%; flex-shrink: 0; display: grid; place-items: center; color: rgb(var(--tone)); background: radial-gradient(circle at 30% 25%, rgba(var(--tone), 0.35), rgba(var(--tone), 0.08) 70%); border: 1px solid rgba(var(--tone), 0.5); box-shadow: 0 0 28px rgba(var(--tone), 0.3); }
.ar-ico svg { width: 22px; height: 22px; filter: brightness(1.3); }
.ar-label b { display: block; font-size: 18px; font-weight: 900; letter-spacing: -0.02em; }
.ar-label small { display: block; font-size: 12.5px; color: var(--faint); line-height: 1.4; }
.ar-nodes { display: flex; flex-wrap: wrap; gap: 10px; }
.ar-node {
  flex: 1 1 auto;
  display: inline-flex; align-items: center; justify-content: center; gap: 9px;
  height: 48px; padding: 0 16px 0 8px;
  border-radius: 999px;
  font-size: 13.5px; font-weight: 700; white-space: nowrap; color: #ececf2;
  background: rgba(10, 10, 16, 0.7);
  border: 1px solid rgba(255, 255, 255, 0.08);
  transition: transform 0.2s, border-color 0.2s, background 0.2s;
}
.ar-node:hover { transform: translateY(-2px); border-color: rgba(var(--tone), 0.6); background: rgba(var(--tone), 0.12); }
.ar-node i { width: 32px; height: 32px; border-radius: 50%; flex-shrink: 0; display: grid; place-items: center; overflow: hidden; color: rgb(var(--tone)); background: rgba(var(--tone), 0.16); }
.ar-node i svg { width: 16px; height: 16px; filter: brightness(1.35); }
.ar-node i img { width: 100%; height: 100%; object-fit: cover; }

/* data-flow connectors between tiers */
.ar-flow { position: relative; height: 46px; display: flex; justify-content: space-evenly; padding: 0 12%; }
.ar-flow span { position: relative; width: 2px; height: 100%; background: linear-gradient(rgba(var(--from), 0.7), rgba(var(--to), 0.7)); opacity: 0.55; }
.ar-flow span i { position: absolute; left: 50%; top: 0; width: 6px; height: 6px; margin-left: -3px; border-radius: 50%; background: #fff; box-shadow: 0 0 10px rgb(var(--to)), 0 0 4px #fff; animation: flowDot 1.8s linear infinite; animation-delay: calc(var(--i) * -0.36s); }
@keyframes flowDot { 0% { transform: translateY(-4px); opacity: 0; } 15% { opacity: 1; } 85% { opacity: 1; } 100% { transform: translateY(44px); opacity: 0; } }

@media (max-width: 1024px) {
  .ar-tier { grid-template-columns: 1fr; gap: 16px; }
  .ar-flow { padding: 0 8%; }
}
@media (max-width: 720px) {
  .arch2 { padding: 16px; }
  .ar-tier { padding: 16px; border-radius: 22px; }
  .ar-num { font-size: 26px; }
  .ar-ico { width: 44px; height: 44px; }
  .ar-node { height: 44px; font-size: 12.5px; white-space: normal; text-align: left; }
  .ar-flow { height: 36px; }
  .ar-flow span:nth-child(n+4) { display: none; }
}
@media (prefers-reduced-motion: reduce) { .ar-flow span i { animation: none; top: 50%; } }
/* Even node grids per tier */
.ar-nodes { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; }
.ar-node { justify-content: flex-start; min-width: 0; }
@media (max-width: 720px) { .ar-nodes { grid-template-columns: repeat(2, minmax(0, 1fr)); } .ar-nodes.n3 { grid-template-columns: 1fr; } }
.ar-node > span { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
@media (max-width: 720px) { .ar-node > span { white-space: normal; } }

/* ---------- Testimonials v2: bento ---------- */
.quotes2 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 24px; }
.q2 {
  --tone: 139, 92, 246;
  margin: 0; padding: 30px; overflow: hidden;
  display: flex; flex-direction: column; gap: 20px;
  background:
    radial-gradient(320px 200px at 100% 0%, rgba(var(--tone), 0.14), transparent 70%),
    var(--surface);
}
.q2.hover:hover { border-color: rgba(var(--tone), 0.45); box-shadow: 0 24px 60px rgba(0, 0, 0, 0.5), 0 0 46px rgba(var(--tone), 0.14); }
.q-feat { grid-column: span 2; padding: 38px 40px; }
.q-water { position: absolute; right: -10px; bottom: -30px; z-index: -1; color: rgba(var(--tone), 0.07); transform: rotate(180deg); }
.q-water svg { width: 170px; height: 170px; }
.q-feat .q-water svg { width: 230px; height: 230px; }
.q-top { display: flex; align-items: center; gap: 12px; }
.q-top .sample { position: static; margin-left: auto; }
.q-mark2 {
  width: 50px; height: 50px; border-radius: 50%; flex-shrink: 0;
  display: grid; place-items: center; color: #fff;
  background: linear-gradient(135deg, rgb(var(--tone)), var(--accent));
  box-shadow: 0 0 30px rgba(var(--tone), 0.45);
}
.q-mark2 svg { width: 22px; height: 22px; }
.q-stars { color: #fbbf24; letter-spacing: 2px; font-size: 16px; text-shadow: 0 0 10px rgba(251, 191, 36, 0.5); }
.q2 blockquote { margin: 0; flex: 1; font-size: 16.5px; line-height: 1.7; color: #ececf2; }
.q-feat blockquote { font-size: 22px; line-height: 1.55; font-weight: 600; letter-spacing: -0.01em; }
.q2 figcaption { display: flex; align-items: center; gap: 14px; padding-top: 18px; border-top: 1px solid var(--border); }
.avatar2 { width: 50px; height: 50px; border-radius: 50%; padding: 2px; flex-shrink: 0; background: conic-gradient(from 200deg, rgb(var(--tone)), var(--accent), rgb(var(--tone))); }
.avatar2 span { width: 100%; height: 100%; border-radius: 50%; display: grid; place-items: center; font-size: 15px; font-weight: 800; color: #fff; background: #14131c; }
.q2 figcaption b { display: block; font-size: 15px; }
.q2 figcaption small { color: var(--faint); font-size: 13px; }

.q-cta {
  grid-column: span 2;
  display: grid; grid-template-columns: auto 1fr auto; grid-template-areas: "ico title btn" "ico text btn";
  align-items: center; column-gap: 20px; row-gap: 4px;
  padding: 30px 32px;
  border-style: dashed; border-color: rgba(139, 92, 246, 0.4);
  background:
    radial-gradient(420px 200px at 0% 50%, rgba(124, 58, 237, 0.18), transparent 70%),
    var(--surface);
  transition: border-color 0.3s, background 0.3s, transform 0.3s;
}
.q-cta:hover { border-style: solid; border-color: rgba(139, 92, 246, 0.7); transform: translateY(-2px); }
.q-cta-ico { grid-area: ico; width: 62px; height: 62px; border-radius: 50%; display: grid; place-items: center; color: #c4b5fd; background: rgba(124, 58, 237, 0.16); border: 1px solid rgba(139, 92, 246, 0.45); box-shadow: 0 0 30px rgba(124, 58, 237, 0.3); }
.q-cta-ico svg { width: 26px; height: 26px; }
.q-cta b { grid-area: title; font-size: 21px; font-weight: 900; letter-spacing: -0.02em; align-self: end; }
.q-cta small { grid-area: text; color: var(--muted); font-size: 14px; align-self: start; }
.q-cta .btn { grid-area: btn; }
.q-cta .btn svg { width: 18px; height: 18px; }

@media (max-width: 1024px) {
  .quotes2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .q-feat, .q-cta { grid-column: 1 / -1; }
}
@media (max-width: 720px) {
  .quotes2 { grid-template-columns: 1fr; gap: 16px; }
  .q2, .q-feat { padding: 24px; }
  .q-feat blockquote { font-size: 18px; }
  .q-cta { grid-template-columns: 1fr; grid-template-areas: "ico" "title" "text" "btn"; justify-items: center; text-align: center; row-gap: 10px; padding: 28px 22px; }
  .q-cta .btn { width: 100%; margin-top: 8px; }
}

/* ---------- Testimonials polish ---------- */
.q-water {
  right: 18px; top: -18px; bottom: auto; transform: none;
  font-family: Georgia, "Times New Roman", serif; font-size: 220px; line-height: 1; font-weight: 700;
  background: linear-gradient(160deg, rgba(var(--tone), 0.22), rgba(var(--tone), 0.02) 70%);
  -webkit-background-clip: text; background-clip: text; color: transparent;
  transition: transform 0.5s ease;
}
.q-feat .q-water { font-size: 300px; top: -34px; right: 30px; }
.q2:hover .q-water { transform: translateY(6px) rotate(-4deg); }
.q2.hover:hover { transform: translateY(-4px); }
.q2 blockquote { display: flex; align-items: center; }
.q-feat blockquote {
  font-size: clamp(20px, 2.1vw, 26px); line-height: 1.5;
  padding-left: 22px; border-left: 3px solid; border-image: linear-gradient(rgb(var(--tone)), var(--accent)) 1;
}
.q-top .q-mark2 { width: 44px; height: 44px; }
.q-top .q-mark2 svg { width: 19px; height: 19px; }
.q2 figcaption { margin-top: auto; }
.q-cta { border-style: solid; border-color: transparent; background-clip: padding-box; }
.q-cta::before {
  content: ""; position: absolute; inset: 0; border-radius: inherit; padding: 1px; pointer-events: none;
  background: conic-gradient(from var(--spin), rgba(139, 92, 246, 0.9), rgba(59, 130, 246, 0.6), rgba(236, 72, 153, 0.6), rgba(139, 92, 246, 0.9));
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask-composite: xor; mask-composite: exclude;
  animation: spinBorder 6s linear infinite;
}
@media (max-width: 720px) {
  .q-water { font-size: 160px; }
  .q-feat .q-water { font-size: 190px; }
  .q-feat blockquote { padding-left: 16px; }
}
@media (prefers-reduced-motion: reduce) { .q-cta::before { animation: none; } }

/* ---------- Testimonials v3: spotlight carousel ---------- */
.ts { --tone: 139, 92, 246; display: grid; grid-template-columns: minmax(0, 1.55fr) minmax(0, 1fr); gap: 24px; align-items: stretch; }
.ts-stage {
  position: relative; overflow: hidden;
  display: flex; flex-direction: column;
  padding: 40px 44px 30px;
  min-height: 420px;
  background:
    radial-gradient(520px 300px at 100% 0%, rgba(var(--tone), 0.2), transparent 70%),
    radial-gradient(400px 260px at 0% 100%, rgba(59, 130, 246, 0.08), transparent 70%),
    var(--surface);
  border-color: rgba(var(--tone), 0.3);
  transition: border-color 0.6s, background 0.6s;
}
.ts-water {
  position: absolute; right: 30px; top: -50px; z-index: -1; pointer-events: none;
  font-family: Georgia, "Times New Roman", serif; font-size: 340px; line-height: 1; font-weight: 700;
  background: linear-gradient(160deg, rgba(var(--tone), 0.3), rgba(var(--tone), 0.02) 70%);
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
.ts-slides { display: grid; flex: 1; }
.ts-slide {
  grid-area: 1 / 1; margin: 0;
  display: flex; flex-direction: column; gap: 26px;
  opacity: 0; transform: translateY(14px); visibility: hidden;
  transition: opacity 0.5s ease, transform 0.5s ease, visibility 0.5s;
}
.ts-slide.on { opacity: 1; transform: none; visibility: visible; }
.ts-meta { display: flex; align-items: center; gap: 12px; }
.ts-meta .q-mark2 { background: linear-gradient(135deg, rgb(var(--tone)), var(--accent)); box-shadow: 0 0 30px rgba(var(--tone), 0.45); }
.ts-meta .sample { position: static; }
.ts-count { margin-left: auto; font-size: 13px; font-weight: 800; letter-spacing: 0.1em; color: var(--faint); font-variant-numeric: tabular-nums; }
.ts-stars { color: #fbbf24; letter-spacing: 2px; font-size: 17px; text-shadow: 0 0 10px rgba(251, 191, 36, 0.5); }
.ts-slide blockquote {
  margin: 0; flex: 1;
  display: flex; align-items: center;
  font-size: clamp(22px, 2.4vw, 30px); line-height: 1.45; font-weight: 600; letter-spacing: -0.015em; color: #f2f2f7;
}
.ts-slide figcaption { display: flex; align-items: center; gap: 14px; }
.ts-slide figcaption b { display: block; font-size: 16px; }
.ts-slide figcaption small { color: var(--faint); font-size: 13.5px; }
.ts-slide .avatar2 { width: 54px; height: 54px; }

.ts-controls { display: flex; align-items: center; justify-content: space-between; gap: 16px; margin-top: 28px; padding-top: 22px; border-top: 1px solid var(--border); }
.ts-dots { display: flex; gap: 8px; flex: 1; max-width: 320px; }
.ts-dot { flex: 1; height: 6px; padding: 0; border: 0; border-radius: 999px; background: rgba(255, 255, 255, 0.1); cursor: pointer; overflow: hidden; }
.ts-dot i { display: block; height: 100%; width: 0; border-radius: inherit; background: linear-gradient(90deg, rgb(var(--tone)), var(--accent)); }
.ts-dot.on i { width: 100%; }
.ts.ticking .ts-dot.on i { animation: tsProgress 6s linear forwards; }
.ts.paused .ts-dot.on i { animation-play-state: paused; }
@keyframes tsProgress { from { width: 0; } to { width: 100%; } }
.ts-arrows { display: flex; gap: 10px; }
.ts-btn {
  width: 48px; height: 48px; border-radius: 50%; cursor: pointer;
  display: grid; place-items: center;
  color: #fff; background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--border-strong);
  transition: background 0.25s, border-color 0.25s, transform 0.2s;
}
.ts-btn svg { width: 18px; height: 18px; }
.ts-btn[data-step="-1"] svg { transform: rotate(180deg); }
.ts-btn:hover { background: linear-gradient(135deg, var(--primary), var(--primary-2)); border-color: transparent; transform: translateY(-2px); }

.ts-side { display: flex; flex-direction: column; gap: 16px; min-width: 0; }
.ts-list { display: grid; gap: 10px; }
.ts-item {
  --tone: 139, 92, 246;
  display: flex; align-items: center; gap: 14px;
  width: 100%; padding: 14px 16px; text-align: left; cursor: pointer;
  border-radius: 22px; color: inherit; font: inherit;
  background: var(--surface);
  border: 1px solid var(--border);
  transition: border-color 0.3s, background 0.3s, transform 0.25s;
}
.ts-item:hover { transform: translateX(4px); border-color: rgba(var(--tone), 0.35); }
.ts-item.on { border-color: rgba(var(--tone), 0.6); background: linear-gradient(90deg, rgba(var(--tone), 0.16), rgba(var(--tone), 0.03)); box-shadow: 0 0 30px rgba(var(--tone), 0.12); }
.ts-item .avatar2 { width: 46px; height: 46px; }
.ts-item-text { min-width: 0; display: grid; gap: 1px; }
.ts-item-text b { font-size: 14.5px; display: flex; align-items: center; gap: 8px; }
.ts-item-text b .sample { font-size: 9px; padding: 2px 7px; font-style: normal; }
.ts-item-text small { font-size: 12px; color: var(--faint); }
.ts-item-text > span { font-size: 13px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; margin-top: 3px; }
.ts-cta { grid-column: auto; flex: 1; grid-template-columns: auto 1fr; grid-template-areas: "ico title" "ico text" "btn btn"; padding: 24px; row-gap: 6px; }
.ts-cta .btn { margin-top: 12px; width: 100%; }

@media (max-width: 1024px) {
  .ts { grid-template-columns: 1fr; }
  .ts-side { display: grid; grid-template-columns: 1fr 1fr; align-items: stretch; }
}
@media (max-width: 720px) {
  .ts-stage { padding: 28px 22px 22px; min-height: 380px; }
  .ts-water { font-size: 220px; top: -30px; right: 10px; }
  .ts-slide blockquote { font-size: 20px; }
  .ts-side { grid-template-columns: 1fr; }
  .ts-list { display: none; }
  .ts-btn { width: 44px; height: 44px; }
  .ts-cta { grid-template-columns: 1fr; grid-template-areas: "ico" "title" "text" "btn"; justify-items: center; text-align: center; }
}

/* ---------- Legal hub v3 (portfolio) ---------- */
.lg2 {
  --tone: 168, 85, 247;
  overflow: hidden;
  background:
    radial-gradient(360px 200px at 0% 0%, rgba(var(--tone), 0.16), transparent 70%),
    var(--surface);
}
.lg2::before {
  content: ""; position: absolute; inset: 0; border-radius: inherit; padding: 1px;
  background: linear-gradient(140deg, rgba(var(--tone), 0.9), transparent 45%, transparent 60%, rgba(var(--tone), 0.5));
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask-composite: xor; mask-composite: exclude;
  opacity: 0; transition: opacity 0.35s; pointer-events: none;
}
.lg2:hover::before { opacity: 1; }
.lg2.hover:hover { border-color: transparent; box-shadow: 0 24px 60px rgba(0, 0, 0, 0.5), 0 0 46px rgba(var(--tone), 0.14); }
.lg-icon { position: relative; flex-shrink: 0; }
.lg-icon::before { content: ""; position: absolute; inset: -8px; border-radius: 50%; background: radial-gradient(circle, rgba(var(--tone), 0.5), transparent 70%); filter: blur(6px); }
.lg-icon .app-icon { position: relative; width: 66px; height: 66px; }
.lg2 .la-title h3 { font-size: 20px; }
.lg2 .la-doc { padding: 12px 12px 12px 12px; gap: 14px; }
.lg2 .la-doc:hover { border-color: rgba(var(--tone), 0.45); background: rgba(var(--tone), 0.07); }
.lg2 .la-doc:hover .la-go { background: linear-gradient(135deg, rgb(var(--tone)), var(--accent)); }
.la-chips { display: flex; gap: 6px; flex-shrink: 0; }
.la-chips span {
  display: inline-flex; align-items: center; gap: 5px;
  padding: 5px 10px; border-radius: 999px;
  font-size: 11.5px; font-weight: 700; color: #c9c9d3; white-space: nowrap;
  background: rgba(255, 255, 255, 0.04); border: 1px solid var(--border);
}
.la-chips svg { width: 13px; height: 13px; color: rgb(var(--tone)); filter: brightness(1.4); }

.lb2 { position: relative; overflow: hidden; padding: 28px 30px; border-color: transparent; }
.lb2::before {
  content: ""; position: absolute; inset: 0; border-radius: inherit; padding: 1px; pointer-events: none;
  background: conic-gradient(from var(--spin), rgba(139, 92, 246, 0.9), rgba(59, 130, 246, 0.6), rgba(16, 185, 129, 0.5), rgba(139, 92, 246, 0.9));
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask-composite: xor; mask-composite: exclude;
  animation: spinBorder 7s linear infinite;
}
.lb2 .lb-ico { position: relative; width: 70px; height: 70px; }
.lb2 .lb-ico i { position: absolute; inset: 0; border-radius: 50%; border: 2px solid rgba(139, 92, 246, 0.6); animation: ping 2.6s cubic-bezier(0, 0, .2, 1) infinite; }
.lb2 .lb-ico i + i { animation-delay: 1.3s; }
.lb-stats { display: flex; flex-wrap: wrap; gap: 8px 18px; margin-top: 8px; font-size: 13.5px; color: var(--muted); }
.lb-stats > span { display: inline-flex; align-items: center; gap: 6px; }
.lb-stats strong { color: #fff; font-size: 15px; }
.lb-stats svg { width: 15px; height: 15px; color: #34d399; stroke-width: 3; }
.lb2 .lb-btn { height: 54px; padding: 0 28px; }

@media (max-width: 1280px) {
  .la-chips span:last-child { display: none; }
}
@media (max-width: 720px) {
  .la-chips { display: none; }
  .lg-icon .app-icon { width: 56px; height: 56px; }
  .lb-stats { justify-content: center; }
  .lb2 { padding: 26px 20px; }
}
@media (prefers-reduced-motion: reduce) { .lb2::before, .lb2 .lb-ico i { animation: none; } }
.lg2 .la-head { flex-wrap: nowrap; }
.lg2 .la-title { min-width: 0; flex: 1; }
.lg2 .la-title h3, .lg2 .la-title .app-cat { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
@media (max-width: 720px) { .lg2 .la-head { gap: 12px; } .lg2 .la-title h3 { font-size: 18px; } .lg2 .status { padding: 5px 9px; } }

/* ---------- Contact v2 ---------- */
.cf2 {
  position: relative; overflow: hidden; padding: 34px;
  background:
    radial-gradient(420px 240px at 0% 0%, rgba(124, 58, 237, 0.16), transparent 70%),
    var(--surface);
}
.cf-head { display: flex; align-items: center; gap: 14px; padding-bottom: 20px; margin-bottom: 4px; border-bottom: 1px solid var(--border); }
.cf-ico { width: 52px; height: 52px; border-radius: 50%; flex-shrink: 0; display: grid; place-items: center; color: #fff; background: linear-gradient(135deg, var(--primary), var(--accent)); box-shadow: 0 0 30px rgba(124, 58, 237, 0.45); }
.cf-ico svg { width: 22px; height: 22px; }
.cf-head b { display: block; font-size: 20px; font-weight: 900; letter-spacing: -0.02em; }
.cf-head small { color: var(--faint); font-size: 13px; }

.fi { position: relative; }
.fi > svg { position: absolute; left: 18px; top: 50%; transform: translateY(-50%); width: 18px; height: 18px; color: var(--faint); pointer-events: none; transition: color 0.2s; }
.fi-area > svg { top: 18px; transform: none; }
.fi input, .fi textarea { padding-left: 50px !important; }
.fi:focus-within > svg { color: #a78bfa; }
.field > span { display: flex; align-items: center; justify-content: space-between; }
.cf-count { font-style: normal; font-weight: 600; letter-spacing: 0; text-transform: none; color: var(--faint); font-variant-numeric: tabular-nums; }

.cf-topics { border: 0; margin: 0; padding: 0; min-width: 0; }
.cf-topics legend { padding: 0; margin-bottom: 8px; }
.cf-topics legend span { font-size: 12px; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; color: var(--muted); }
.topics { display: flex; flex-wrap: wrap; gap: 8px; }
.topic { cursor: pointer; flex: 1 1 auto; }
.topic input { position: absolute; opacity: 0; pointer-events: none; }
.topic span {
  display: flex; align-items: center; justify-content: center; gap: 8px;
  height: 44px; padding: 0 16px; border-radius: 999px;
  font-size: 13.5px; font-weight: 600; color: #d4d4dc; white-space: nowrap;
  background: rgba(255, 255, 255, 0.03); border: 1px solid var(--border-strong);
  transition: background 0.2s, border-color 0.2s, color 0.2s, box-shadow 0.2s;
}
.topic span::before { content: ""; width: 8px; height: 8px; border-radius: 50%; border: 1.5px solid var(--faint); transition: background 0.2s, border-color 0.2s, box-shadow 0.2s; }
.topic:hover span { border-color: rgba(139, 92, 246, 0.45); }
.topic input:checked + span { color: #fff; background: linear-gradient(135deg, rgba(124, 58, 237, 0.35), rgba(59, 130, 246, 0.2)); border-color: rgba(139, 92, 246, 0.7); box-shadow: 0 0 24px rgba(124, 58, 237, 0.25); }
.topic input:checked + span::before { background: #a78bfa; border-color: #a78bfa; box-shadow: 0 0 8px #a78bfa; }
.topic input:focus-visible + span { outline: 2px solid #a78bfa; outline-offset: 2px; }

.cf-actions { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.cf-actions .btn { width: 100%; height: 56px; }
.form-note { display: flex; align-items: center; gap: 8px; }
.form-note svg { width: 15px; height: 15px; flex-shrink: 0; color: #34d399; }

.map2 iframe { top: -64px; height: calc(100% + 64px); }
.map-pin { position: absolute; left: 50%; top: 50%; z-index: 2; width: 0; height: 0; pointer-events: none; }
.map-pin i { position: absolute; left: -22px; top: -22px; width: 44px; height: 44px; border-radius: 50%; border: 2px solid rgba(167, 139, 250, 0.8); animation: ping 2.4s cubic-bezier(0, 0, .2, 1) infinite; }
.map-pin i + i { animation-delay: 1.2s; }
.map-pin b { position: absolute; left: -21px; top: -21px; width: 42px; height: 42px; border-radius: 50%; display: grid; place-items: center; color: #fff; background: linear-gradient(135deg, var(--primary), var(--accent)); box-shadow: 0 0 0 4px rgba(13, 13, 18, 0.8), 0 0 30px rgba(124, 58, 237, 0.8); }
.map-pin b svg { width: 20px; height: 20px; }

.info2 { padding: 22px; gap: 14px; }
.info-row { display: flex; align-items: center; gap: 14px; min-width: 0; padding: 10px; border-radius: 20px; background: rgba(255, 255, 255, 0.02); border: 1px solid var(--border); }
.info-main { flex: 1; min-width: 0; }
.info-main a:hover b { color: #c4b5fd; }
.copy-btn { display: inline-flex; align-items: center; gap: 6px; flex-shrink: 0; height: 36px; padding: 0 14px; border-radius: 999px; cursor: pointer; font: 700 12px "Inter", sans-serif; color: #d4d4dc; background: rgba(255, 255, 255, 0.04); border: 1px solid var(--border-strong); transition: background 0.2s, border-color 0.2s, color 0.2s; }
.copy-btn svg { width: 14px; height: 14px; }
.copy-btn:hover { border-color: rgba(139, 92, 246, 0.6); color: #fff; }
.copy-btn.done { color: #34d399; border-color: rgba(16, 185, 129, 0.6); background: rgba(16, 185, 129, 0.1); }
.info-social { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding-top: 6px; }
.info-social small { font-size: 11px; font-weight: 800; letter-spacing: 0.14em; text-transform: uppercase; color: var(--faint); }
.info2 .info-socials { padding-top: 0; border-top: 0; }

@media (max-width: 720px) {
  .cf2 { padding: 24px 18px; }
  .cf-actions { grid-template-columns: 1fr; }
  .topic { flex: 1 1 100%; }
  .topic span { justify-content: flex-start; }
  .info-social { flex-direction: column; align-items: flex-start; }
  .copy-btn span { display: none; }
  .copy-btn { width: 36px; padding: 0; justify-content: center; }
}
@media (prefers-reduced-motion: reduce) { .map-pin i { animation: none; } }

/* ---------- Contact: phone with country code + subject dropdown ---------- */
.cf-opt { font-style: normal; font-weight: 600; letter-spacing: 0.04em; text-transform: none; color: var(--faint); font-size: 11.5px; }
.phone {
  display: flex; align-items: stretch;
  height: 52px; border-radius: 999px;
  border: 1px solid var(--border-strong);
  background: rgba(255, 255, 255, 0.03);
  transition: border-color 0.2s, box-shadow 0.2s, background 0.2s;
}
.phone:focus-within { border-color: var(--primary-2); background: rgba(124, 58, 237, 0.05); box-shadow: 0 0 0 4px rgba(124, 58, 237, 0.18); }
.field.invalid .phone { border-color: #f87171; box-shadow: 0 0 0 4px rgba(248, 113, 113, 0.15); }
.cc {
  position: relative; flex-shrink: 0;
  display: flex; align-items: center; gap: 6px;
  padding: 0 12px 0 18px;
  border-right: 1px solid var(--border-strong);
  border-radius: 999px 0 0 999px;
  transition: background 0.2s;
}
.cc:hover { background: rgba(124, 58, 237, 0.1); }
.cc-label { font-size: 14px; font-weight: 800; letter-spacing: 0.02em; color: #e4e4ea; white-space: nowrap; font-variant-numeric: tabular-nums; }
.cc > svg { width: 15px; height: 15px; color: var(--faint); }
.cc select { position: absolute; inset: 0; width: 100%; height: 100%; opacity: 0; cursor: pointer; font: inherit; }
.cc select option, .fi-select select option { background: #14141b; color: #ececf2; }
.phone-num { flex: 1; min-width: 0; }
.phone-num input { height: 100% !important; border: 0 !important; background: transparent !important; box-shadow: none !important; border-radius: 0 999px 999px 0 !important; }
.phone-num > svg { left: 16px; }
.phone-num input { padding-left: 44px !important; }

.fi-select select {
  appearance: none; -webkit-appearance: none;
  width: 100%; height: 52px; padding: 0 48px 0 50px !important;
  border-radius: 999px; cursor: pointer;
  font: inherit; font-size: 15px; font-weight: 600; color: var(--text);
  background: rgba(255, 255, 255, 0.03) !important; background-image: none !important;
  border: 1px solid var(--border-strong);
}
.fi-select select:hover { border-color: rgba(139, 92, 246, 0.5); }
.fi-select > svg:last-child { left: auto; right: 18px; color: var(--muted); transition: transform 0.2s, color 0.2s; }
.fi-select:focus-within > svg:last-child { transform: translateY(-50%) rotate(180deg); color: #a78bfa; }

/* ---------- Custom glass dropdown (select[data-fancy]) ---------- */
.fx-native { pointer-events: none; }
.fx-host { cursor: pointer; outline: none; }
.fx-host:focus-visible { box-shadow: 0 0 0 3px rgba(167, 139, 250, 0.6); border-radius: 999px; }
.fi-select.fx-open select { border-color: var(--primary-2); background: rgba(124, 58, 237, 0.06) !important; box-shadow: 0 0 0 4px rgba(124, 58, 237, 0.18); }
.fi-select.fx-open > svg:last-child, .cc.fx-open > svg { transform: translateY(-50%) rotate(180deg); color: #a78bfa; }
.cc.fx-open > svg { transform: rotate(180deg); }
.cc.fx-open { background: rgba(124, 58, 237, 0.14); }

.fx-pop {
  position: fixed; z-index: 120;
  display: flex; flex-direction: column;
  max-height: 360px; overflow: hidden;
  padding: 8px;
  border-radius: 22px;
  background: rgba(16, 15, 24, 0.97);
  backdrop-filter: blur(20px) saturate(160%); -webkit-backdrop-filter: blur(20px) saturate(160%);
  border: 1px solid rgba(255, 255, 255, 0.1);
  box-shadow: 0 30px 70px rgba(0, 0, 0, 0.7), 0 0 0 1px rgba(124, 58, 237, 0.15), 0 0 40px rgba(124, 58, 237, 0.12);
  animation: fxIn 0.18s ease-out;
  transform-origin: top center;
}
.fx-pop.up { transform-origin: bottom center; }
.fx-pop[hidden] { display: none; }
@keyframes fxIn { from { opacity: 0; transform: translateY(-6px) scale(0.98); } to { opacity: 1; transform: none; } }
.fx-search { position: relative; display: block; margin-bottom: 6px; flex-shrink: 0; }
.fx-search svg { position: absolute; left: 14px; top: 50%; transform: translateY(-50%); width: 16px; height: 16px; color: var(--faint); pointer-events: none; }
.fx-search input {
  width: 100%; height: 42px; padding: 0 14px 0 40px;
  border-radius: 999px; outline: none;
  font: inherit; font-size: 14px; color: var(--text);
  background: rgba(255, 255, 255, 0.05); border: 1px solid var(--border-strong);
}
.fx-search input:focus { border-color: var(--primary-2); }
.fx-list { list-style: none; margin: 0; padding: 0 2px 0 0; overflow-y: auto; scrollbar-width: thin; scrollbar-color: rgba(139, 92, 246, 0.5) transparent; }
.fx-list::-webkit-scrollbar { width: 6px; }
.fx-list::-webkit-scrollbar-thumb { background: rgba(139, 92, 246, 0.45); border-radius: 6px; }
.fx-item {
  display: flex; align-items: center; gap: 12px;
  padding: 9px 12px; border-radius: 14px; cursor: pointer;
  font-size: 14px; color: #e4e4ea;
  transition: background 0.12s;
}
.fx-item[hidden] { display: none; }
.fx-item.on { background: rgba(124, 58, 237, 0.16); }
.fx-item.sel { color: #fff; font-weight: 700; }
.fx-badge {
  width: 34px; height: 34px; border-radius: 50%; flex-shrink: 0;
  display: grid; place-items: center;
  font-size: 11px; font-weight: 800; letter-spacing: 0.04em; color: #fff;
  background: linear-gradient(135deg, hsl(var(--h) 70% 55%), hsl(calc(var(--h) + 50) 70% 45%));
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.25);
}
.fx-name { flex: 1; min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.fx-meta { font-size: 13px; font-weight: 700; color: var(--muted); font-variant-numeric: tabular-nums; }
.fx-item.sel .fx-meta { color: #c4b5fd; }
.fx-check { width: 22px; height: 22px; flex-shrink: 0; border-radius: 50%; display: grid; place-items: center; color: #fff; opacity: 0; background: linear-gradient(135deg, var(--primary), var(--accent)); }
.fx-check svg { width: 12px; height: 12px; }
.fx-item.sel .fx-check { opacity: 1; }

.fx-name small { display: block; font-size: 12px; font-weight: 500; color: var(--faint); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; margin-top: 1px; }
.fx-item:has(small) { padding: 10px 14px; }
.cf-head { border-bottom: 0; padding-bottom: 6px; }
/* Contact info rows: full pill shape */
.info-row { border-radius: 999px; padding: 8px 10px 8px 8px; }
.info-row .work-ico { width: 50px; height: 50px; }
.info-row .copy-btn { height: 40px; padding: 0 16px; }
@media (max-width: 720px) { .info-row .copy-btn { width: 40px; padding: 0; } }
/* Sit the custom pin over Google's place marker (iframe is shifted up 64px, marker tip is the point) */
.map2 .map-pin { top: calc(50% - 52px); }

/* ---------- Footer v2 ---------- */
.ft-wrap { margin-top: 72px; padding-bottom: calc(28px + env(safe-area-inset-bottom)); }
.ft {
  position: relative; overflow: hidden;
  padding: 44px 44px 0;
  background:
    radial-gradient(600px 260px at 0% 0%, rgba(124, 58, 237, 0.16), transparent 70%),
    radial-gradient(500px 240px at 100% 100%, rgba(59, 130, 246, 0.1), transparent 70%),
    var(--surface);
}
.ft::before { content: ""; position: absolute; top: 0; left: 10%; right: 10%; height: 1px; background: linear-gradient(90deg, transparent, rgba(167, 139, 250, 0.8), rgba(96, 165, 250, 0.6), transparent); }
.ft-grid { display: grid; grid-template-columns: minmax(0, 1.5fr) minmax(0, 0.8fr) minmax(0, 1.2fr) minmax(0, 1.2fr); gap: 40px; padding-bottom: 36px; }
.ft-brand p { color: var(--muted); font-size: 14px; line-height: 1.7; margin: 18px 0 20px; max-width: 340px; }
.ft-brand .brand small { letter-spacing: 0.08em; }
.ft-socials .social { width: 40px; height: 40px; }
.ft-socials .social svg { width: 17px; height: 17px; }
.ft-col h4 { margin: 6px 0 18px; font-size: 12px; font-weight: 800; letter-spacing: 0.16em; text-transform: uppercase; color: var(--text); }
.ft-col ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 12px; }
.ft-col li a { display: inline-flex; align-items: center; gap: 8px; font-size: 14px; color: var(--muted); transition: color 0.2s, transform 0.2s; }
.ft-col li a::before { content: ""; width: 0; height: 2px; border-radius: 2px; background: linear-gradient(90deg, #a78bfa, #60a5fa); transition: width 0.25s; }
.ft-col li a:hover { color: #fff; }
.ft-col li a:hover::before { width: 12px; }
.ft-contact { display: flex; flex-direction: column; align-items: flex-start; gap: 12px; }
.ft-mail, .ft-loc { display: inline-flex; align-items: center; gap: 10px; font-size: 14px; color: var(--muted); max-width: 100%; }
.ft-mail span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ft-mail:hover { color: #fff; }
.ft-mail svg, .ft-loc svg { width: 17px; height: 17px; flex-shrink: 0; color: #a78bfa; }
.ft-btn { margin-top: 6px; height: 46px; padding: 0 24px; font-size: 12px; }
.ft-bottom {
  display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap;
  padding: 20px 0 24px; border-top: 1px solid var(--border);
  font-size: 13px; color: var(--faint);
}
.ft-made { display: inline-flex; align-items: center; gap: 8px; }
.ft-made .live-dot { display: inline-block; width: 7px; height: 7px; border-radius: 50%; background: #34d399; box-shadow: 0 0 10px #34d399; animation: pulse 2s ease-in-out infinite; }
.footer { display: none; }
@media (max-width: 1024px) {
  .ft-grid { grid-template-columns: 1fr 1fr; }
  .ft-brand { grid-column: 1 / -1; }
}
@media (max-width: 720px) {
  .ft-wrap { margin-top: 48px; }
  .ft { padding: 30px 22px 0; }
  .ft-grid { grid-template-columns: 1fr 1fr; gap: 28px 20px; }
  .ft-contact { grid-column: 1 / -1; }
  .ft-btn { width: 100%; }
  .ft-bottom { flex-direction: column; text-align: center; }
}
/* Crop Google's place card (address + reviews) out of the map; keep pin on the marker */
.map2 iframe { top: -140px; height: calc(100% + 140px); }
.map2 .map-pin { top: calc(50% - 90px); }

/* ---------- Project app cards: slimmer, lighter ---------- */
.pa-banner { height: 150px; }
.pa-phone { width: 118px; height: 184px; top: 26px; right: 36px; padding-top: 36px; gap: 9px; border-width: 3px; border-radius: 24px; }
.pa-phone img { width: 46px; height: 46px; }
.pa-phone b { font-size: 10.5px; }
.pa-notch { width: 38px; height: 8px; margin-left: -19px; top: 8px; }
.pa-banner .status { left: 20px; top: 18px; }
.pa-body { padding: 0 26px 26px; gap: 14px; }
.pa-head { margin-top: -34px; gap: 14px; }
.pa-icon { width: 68px !important; height: 68px !important; padding: 3px; box-shadow: 0 12px 30px rgba(0, 0, 0, 0.55), 0 0 0 4px var(--surface), 0 0 24px rgba(var(--tone), 0.45) !important; }
.pa-head .wa-title { padding-top: 40px; }
.pa-head h3 { font-size: 21px; }
.pa-head .wa-meta { margin-top: 4px; }
.pa-desc { font-size: 14px; line-height: 1.65; }
.pa-feats { gap: 8px; }
.pa-feats li { padding: 0; border: 0; background: none; font-size: 13.5px; color: #d4d4dc; gap: 10px; }
.pa-feats li:hover { background: none; border: 0; }
.pa-feats li span { width: 20px; height: 20px; }
.pa-feats li svg { width: 12px; height: 12px; }
.pa .tags { gap: 6px; }
.pa .tags span { padding: 5px 12px; font-size: 11.5px; flex: 0 1 auto; }
.pa .stores { gap: 8px; }
.pa .store { height: 50px; padding: 0 12px; border-radius: 16px; gap: 8px; }
.pa .store svg { width: 22px; height: 22px; }
.pa .store b { font-size: 14px; }
.pa .store small { font-size: 9px; }
@media (max-width: 720px) {
  .pa-banner { height: 130px; }
  .pa-phone { width: 96px; height: 150px; top: 22px; right: 16px; padding-top: 28px; }
  .pa-phone img { width: 38px; height: 38px; }
  .pa-head { margin-top: -30px; }
  .pa-icon { width: 60px !important; height: 60px !important; }
  .pa-head .wa-title { padding-top: 34px; }
  .pa-head h3 { font-size: 19px; }
  .pa-body { padding: 0 18px 20px; }
}
@media (max-width: 720px) { .pa-head .wa-title { padding-top: 44px; } .pa .stores { grid-template-columns: repeat(3, minmax(0, 1fr)); } .pa .store { flex-direction: column; justify-content: center; height: 64px; gap: 3px; padding: 0 6px; text-align: center; } .pa .store > span { align-items: center; } .pa .store b { font-size: 11.5px; } .pa .store small { font-size: 8px; } .pa .store svg { width: 18px; height: 18px; } }

/* ---------- Project app cards: full-width alignment ---------- */
.pa .tags { width: 100%; }
.pa .tags span { flex: 1 1 auto; text-align: center; }
.pa-feats { gap: 0; border-radius: 18px; border: 1px solid var(--border); background: rgba(255, 255, 255, 0.02); overflow: hidden; }
.pa-feats li { width: 100%; padding: 10px 14px; border-bottom: 1px solid var(--border); }
.pa-feats li:last-child { border-bottom: 0; }
.pa-feats li:hover { background: rgba(var(--tone), 0.06); }
.pa-head .wa-title { flex: 1; min-width: 0; }
.pa-desc { width: 100%; }

/* ---------- Timeline: milestone markers in the empty side (desktop) ---------- */
.tl-side { display: none; }
@media (min-width: 1025px) {
  .tl-item { overflow: visible; }
  .tl-side {
    position: absolute; top: 26px; z-index: 1;
    display: flex; align-items: center; gap: 18px;
    width: calc(100% - 40px); pointer-events: none;
  }
  .tl-item:nth-child(odd) .tl-side { left: calc(100% + 130px); }
  .tl-item:nth-child(even) .tl-side { right: calc(100% + 130px); flex-direction: row-reverse; text-align: right; }
  .tl-side b {
    font-size: 92px; font-weight: 900; line-height: 0.9; letter-spacing: -0.06em;
    color: transparent; -webkit-text-stroke: 1.5px rgba(var(--tl), 0.55);
    background: linear-gradient(180deg, rgba(var(--tl), 0.35), transparent 85%);
    -webkit-background-clip: text; background-clip: text;
    transition: -webkit-text-stroke-color 0.4s, transform 0.4s;
  }
  .tl-side span { display: grid; gap: 4px; font-size: 15px; font-weight: 700; color: #e4e4ea; white-space: nowrap; }
  .tl-side small { font-size: 11px; font-weight: 800; letter-spacing: 0.18em; text-transform: uppercase; color: rgb(var(--tl)); filter: brightness(1.45); }
  .tl-side i { flex: 1; max-width: 140px; height: 1px; background: linear-gradient(90deg, rgba(var(--tl), 0.6), transparent); position: relative; }
  .tl-item:nth-child(odd) .tl-side i { order: -1; background: linear-gradient(270deg, rgba(var(--tl), 0.6), transparent); }
  .tl-side i::after { content: ""; position: absolute; top: -3px; width: 7px; height: 7px; border-radius: 50%; background: rgb(var(--tl)); box-shadow: 0 0 10px rgb(var(--tl)); }
  .tl-item:nth-child(odd) .tl-side i::after { left: 0; }
  .tl-item:nth-child(even) .tl-side i::after { right: 0; }
  .tl-item:hover .tl-side b { -webkit-text-stroke-color: rgba(var(--tl), 1); transform: scale(1.04); }
}
@media (min-width: 1025px) {
  .tl-item:nth-child(even) .tl-side { flex-direction: row; justify-content: flex-end; text-align: left; }
  .tl-item:nth-child(even) .tl-side i { order: 2; background: linear-gradient(90deg, transparent, rgba(var(--tl), 0.6)); }
  .tl-item:nth-child(even) .tl-side i::after { right: 0; left: auto; }
}
/* Milestone markers: centred in the empty half, vertically centred on the card */
@media (min-width: 1025px) {
  .tl-side { top: 50%; transform: translateY(-50%); width: 100%; justify-content: center; gap: 18px; }
  .tl-item:nth-child(odd) .tl-side { left: calc(100% + 104px); }
  .tl-item:nth-child(even) .tl-side { right: calc(100% + 104px); justify-content: center; }
  .tl-side i { flex: 0 0 70px; max-width: 70px; }
  .tl-item:hover .tl-side b { transform: none; }
}

/* ---------- Skills ticker v2: two opposite rows of coloured chips ---------- */
.marquee2 {
  position: relative; display: grid; gap: 12px; margin: 0 0 26px; padding: 16px 0;
  border-radius: 28px; overflow: hidden;
  background: radial-gradient(600px 120px at 50% 50%, rgba(124, 58, 237, 0.1), transparent 70%), rgba(255, 255, 255, 0.015);
  border: 1px solid var(--border);
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent);
          mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent);
}
.mq-row { overflow: hidden; }
.mq-track { display: flex; gap: 12px; width: max-content; padding-right: 12px; animation: marquee 48s linear infinite; }
.mq-row.rev .mq-track { animation-direction: reverse; animation-duration: 56s; }
.marquee2:hover .mq-track { animation-play-state: paused; }
.mq-chip {
  display: inline-flex; align-items: center; gap: 9px;
  height: 42px; padding: 0 18px 0 14px; border-radius: 999px;
  font-size: 14px; font-weight: 700; color: #ececf2; white-space: nowrap;
  background: linear-gradient(135deg, rgba(var(--tone), 0.16), rgba(var(--tone), 0.04));
  border: 1px solid rgba(var(--tone), 0.35);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.05);
  transition: border-color 0.2s, box-shadow 0.2s;
}
.mq-chip i { width: 8px; height: 8px; border-radius: 50%; background: rgb(var(--tone)); box-shadow: 0 0 10px rgb(var(--tone)); }
.mq-chip:hover { border-color: rgba(var(--tone), 0.8); box-shadow: 0 0 20px rgba(var(--tone), 0.3); }
@media (max-width: 720px) {
  .marquee2 { padding: 12px 0; gap: 10px; border-radius: 22px; }
  .mq-chip { height: 36px; font-size: 12.5px; padding: 0 14px 0 11px; }
  .mq-track { animation-duration: 34s; }
  .mq-row.rev .mq-track { animation-duration: 40s; }
}
@media (prefers-reduced-motion: reduce) { .mq-track { animation: none; } }

/* ---------- Stats v3: vertical, aligned ---------- */
.stats .stat { flex-direction: column; align-items: stretch; gap: 18px; padding: 24px 24px 22px; }
.stat-top { display: flex; align-items: center; justify-content: space-between; }
.stats .stat-ico { width: 48px; height: 48px; }
.stats .stat-ico svg { width: 21px; height: 21px; }
.stat-tag { font-style: normal; font-size: 10.5px; font-weight: 800; letter-spacing: 0.14em; text-transform: uppercase; padding: 5px 11px; border-radius: 999px; color: rgb(var(--tone)); background: rgba(var(--tone), 0.12); border: 1px solid rgba(var(--tone), 0.35); filter: brightness(1.35); }
.stats .stat b { font-size: 46px; letter-spacing: -0.05em; }
.stats .stat-body > span { margin-top: 10px; font-size: 15px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.stats .stat small { margin-top: 4px; font-size: 12.5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.stat-mark { position: absolute; right: -18px; bottom: -22px; z-index: -1; color: rgba(var(--tone), 0.07); transition: transform 0.5s, color 0.4s; }
.stat-mark svg { width: 120px; height: 120px; stroke-width: 1.4; }
.stats .stat:hover .stat-mark { transform: rotate(-10deg) scale(1.05); color: rgba(var(--tone), 0.12); }
@media (max-width: 720px) {
  .stats .stat { padding: 18px 16px; gap: 14px; }
  .stats .stat-ico { width: 40px; height: 40px; }
  .stats .stat-ico svg { width: 18px; height: 18px; }
  .stat-tag { font-size: 9px; padding: 4px 8px; }
  .stats .stat b { font-size: 32px; }
  .stats .stat-body > span { font-size: 13px; white-space: normal; }
  .stats .stat small { white-space: normal; font-size: 11px; }
  .stat-mark svg { width: 90px; height: 90px; }
}
.stats .stat .stat-mark { display: block; margin: 0; color: rgba(var(--tone), 0.08); }
.stats .stat:hover .stat-mark { color: rgba(var(--tone), 0.14); }
.stats .stat .stat-tag { margin: 0; display: inline-block; }
.stats .stat small { white-space: normal; min-height: 2.8em; }

/* Skills ticker: fully rounded pill container + ring dots */
.marquee2 { border-radius: 999px; padding: 18px 0; -webkit-mask-image: linear-gradient(90deg, transparent, #000 10%, #000 90%, transparent); mask-image: linear-gradient(90deg, transparent, #000 10%, #000 90%, transparent); }
.mq-chip { padding: 0 18px 0 8px; gap: 10px; }
.mq-chip i { width: 26px; height: 26px; border-radius: 50%; background: radial-gradient(circle, rgb(var(--tone)) 0 4px, rgba(var(--tone), 0.18) 5px 100%); border: 1px solid rgba(var(--tone), 0.6); box-shadow: 0 0 12px rgba(var(--tone), 0.45); }
@media (max-width: 720px) {
  .marquee2 { border-radius: 40px; padding: 14px 0; }
  .mq-chip { padding: 0 14px 0 6px; }
  .mq-chip i { width: 22px; height: 22px; }
}

/* ---------- Portfolio: drifting skills in the page background ---------- */
.bg-ticker {
  position: fixed; inset: -20vh -20vw; z-index: -1;
  display: flex; flex-direction: column; justify-content: center; gap: 26px;
  transform: rotate(-10deg);
  opacity: 0.13;
  pointer-events: none; user-select: none;
  -webkit-mask-image: radial-gradient(ellipse 60% 55% at 50% 50%, #000 30%, transparent 80%);
          mask-image: radial-gradient(ellipse 60% 55% at 50% 50%, #000 30%, transparent 80%);
}
.bg-ticker .mq-row { overflow: visible; }
.bg-ticker .mq-track { gap: 16px; animation-duration: 120s; }
.bg-ticker .mq-row.rev .mq-track { animation-duration: 140s; }
.bg-ticker .mq-chip { height: 48px; font-size: 16px; padding: 0 22px 0 10px; }
.bg-ticker .mq-chip i { width: 28px; height: 28px; border-radius: 50%; background: radial-gradient(circle, rgb(var(--tone)) 0 4px, rgba(var(--tone), 0.18) 5px 100%); border: 1px solid rgba(var(--tone), 0.6); }
@media (max-width: 720px) {
  .bg-ticker { opacity: 0.1; gap: 18px; }
  .bg-ticker .mq-chip { height: 38px; font-size: 13px; }
}
@media (prefers-reduced-motion: reduce) { .bg-ticker .mq-track { animation: none; } }
.bg-ticker { opacity: 0.1; }
@media (max-width: 720px) { .bg-ticker { opacity: 0.08; } }

/* ---------- Header: 3-way switch (Apps | Legal Hub | Portfolio), Support removed ---------- */
.switch3 { grid-template-columns: repeat(3, 1fr); margin-left: auto; }
.switch3 .switch-thumb { width: calc((100% - 8px) / 3); }
.switch3[data-active="apps"] .switch-thumb { transform: translateX(0); }
.switch3[data-active="hub"] .switch-thumb { transform: translateX(100%); }
.switch3[data-active="portfolio"] .switch-thumb { transform: translateX(200%); }
.switch3[data-active="apps"] a[data-to="apps"] { color: #fff; }
@media (max-width: 720px) {
  .switch3 a { width: 40px; }
}

/* ---------- Apps landing page ---------- */
.ah-visual { position: relative; height: 380px; }
.ah-glow { position: absolute; inset: 10% 15%; border-radius: 50%; background: radial-gradient(circle, rgba(124, 58, 237, 0.55), rgba(59, 130, 246, 0.2) 50%, transparent 70%); filter: blur(30px); }
.ah-phone {
  position: absolute; top: 30px;
  width: 170px; height: 320px; border-radius: 32px; padding-top: 60px;
  display: flex; flex-direction: column; align-items: center; gap: 14px;
  background: linear-gradient(170deg, #1d1b2a, #0c0b12);
  border: 4px solid #2a2838;
  box-shadow: 0 30px 60px rgba(0, 0, 0, 0.6), 0 0 0 1px rgba(255, 255, 255, 0.06), 0 0 50px rgba(124, 58, 237, 0.35);
  --tone: 139, 92, 246;
  animation: float 6s ease-in-out infinite;
}
.ah-phone img { width: 76px; height: 76px; border-radius: 50%; box-shadow: 0 0 34px rgba(124, 58, 237, 0.7); }
.ah-phone b { font-size: 14px; font-weight: 800; color: #fff; text-align: center; padding: 0 12px; }
.ah-phone .pa-notch { top: 10px; width: 52px; height: 12px; margin-left: -26px; }
.ah-phone.p1 { left: 18%; transform: rotate(-8deg); }
.ah-phone.p2 { right: 16%; top: 60px; transform: rotate(7deg); animation-delay: -3s; --tone: 59, 130, 246; }
.ah .c1 { top: 12%; left: 2%; }
.ah .c2 { bottom: 10%; right: 2%; top: auto; }
.ah-stats { display: flex; gap: 12px; margin-top: 30px; flex-wrap: wrap; }
.ah-stats span { display: grid; padding: 12px 20px; border-radius: 20px; background: rgba(255, 255, 255, 0.03); border: 1px solid var(--border); min-width: 110px; }
.ah-stats b { font-size: 26px; font-weight: 900; letter-spacing: -0.03em; background: linear-gradient(90deg, #fff, #c4b5fd); -webkit-background-clip: text; background-clip: text; color: transparent; }
.ah-stats small { font-size: 12px; color: var(--muted); font-weight: 600; }
.apps-page .feature .ico { background: none; border: 0; box-shadow: none; width: auto; height: auto; }
.apps-page .feature .work-ico { width: 64px; height: 64px; }
.apps-page .feature .work-ico svg { width: 28px; height: 28px; }
.apps-page .hero-actions .btn svg { width: 18px; height: 18px; }
@media (max-width: 1024px) {
  .ah-visual { height: 340px; max-width: 520px; width: 100%; margin: 0 auto; }
  .ah-stats { justify-content: center; }
}
@media (max-width: 720px) {
  .ah-visual { height: 280px; }
  .ah-phone { width: 130px; height: 245px; padding-top: 44px; border-radius: 26px; }
  .ah-phone img { width: 58px; height: 58px; }
  .ah-phone b { font-size: 11.5px; }
  .ah-phone.p1 { left: 6%; }
  .ah-phone.p2 { right: 6%; }
  .ah-stats span { flex: 1; min-width: 0; padding: 10px 12px; text-align: center; }
  .ah-stats b { font-size: 22px; }
  .ah .float-chip { display: none; }
}

/* ---------- Apps hero: full-width aligned column ---------- */
.ah > div:first-child { min-width: 0; width: 100%; }
.ah .lead { max-width: none; }
.ah .hero-actions { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.ah .hero-actions .btn { width: 100%; height: 56px; }
.ah-stats { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; margin-top: 18px; }
.ah-stats > span {
  display: flex; align-items: center; gap: 12px; min-width: 0;
  padding: 14px 16px; border-radius: 22px;
  background: radial-gradient(160px 80px at 0% 0%, rgba(var(--tone), 0.16), transparent 70%), rgba(255, 255, 255, 0.025);
  border: 1px solid rgba(var(--tone), 0.28);
}
.ah-stats > span > i { width: 42px; height: 42px; border-radius: 50%; flex-shrink: 0; display: grid; place-items: center; color: rgb(var(--tone)); background: rgba(var(--tone), 0.15); border: 1px solid rgba(var(--tone), 0.4); box-shadow: 0 0 20px rgba(var(--tone), 0.25); }
.ah-stats > span > i svg { width: 19px; height: 19px; filter: brightness(1.3); }
.ah-stats > span > span { display: grid; min-width: 0; }
.ah-stats b { font-size: 26px; line-height: 1.1; }
.ah-stats small { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
@media (max-width: 720px) {
  .ah .hero-actions { grid-template-columns: 1fr; }
  .ah-stats > span { flex-direction: column; text-align: center; padding: 12px 8px; gap: 8px; }
  .ah-stats > span > i { width: 36px; height: 36px; }
  .ah-stats small { white-space: normal; font-size: 11px; }
}
.ah-stats > span > span { padding: 0; border: 0; background: none; min-width: 0; border-radius: 0; flex: 1; text-align: left; }
@media (max-width: 720px) { .ah-stats > span > span { text-align: center; } }
.ah-stats > span { padding: 12px 14px; gap: 10px; }
.ah-stats small { font-size: 12px; }
/* Apps banner inside the Projects grid */
.works > .apps-banner { grid-column: 1 / -1; margin-top: 0; }
.apps-banner .lb-ico { background: linear-gradient(135deg, #8b5cf6, #10b981); box-shadow: 0 0 40px rgba(16, 185, 129, 0.35); }
.idea-banner { margin-top: 28px; }
.idea-banner .lb-ico { background: linear-gradient(135deg, #8b5cf6, #3b82f6); box-shadow: 0 0 40px rgba(124, 58, 237, 0.45); }
.idea-banner .lb-text b { font-size: 24px; }
.idea-banner .lb-stats { font-size: 14.5px; }
.idea-banner { margin-top: 28px; }
.idea-banner .lb-ico { background: linear-gradient(135deg, #8b5cf6, #3b82f6); box-shadow: 0 0 40px rgba(124, 58, 237, 0.45); }
.idea-banner .lb-text b { font-size: 24px; }
.idea-banner .lb-stats { font-size: 14.5px; }

/* ---------- Legal Hub v2: FAQ accordion + bg ---------- */
.faq2 { display: grid; gap: 14px; }
.faq-item { padding: 0; overflow: hidden; }
.faq-item summary { display: flex; align-items: center; gap: 16px; padding: 20px 24px; cursor: pointer; list-style: none; }
.faq-item summary::-webkit-details-marker { display: none; }
.faq-num { font-size: 26px; font-weight: 900; letter-spacing: -0.04em; color: transparent; -webkit-text-stroke: 1px rgba(139, 92, 246, 0.7); flex-shrink: 0; }
.faq-item summary b { flex: 1; font-size: 17px; font-weight: 800; letter-spacing: -0.015em; }
.faq-plus { position: relative; width: 36px; height: 36px; border-radius: 50%; flex-shrink: 0; background: rgba(124, 58, 237, 0.14); border: 1px solid rgba(139, 92, 246, 0.4); transition: transform 0.3s, background 0.3s; }
.faq-plus::before, .faq-plus::after { content: ""; position: absolute; left: 50%; top: 50%; width: 12px; height: 2px; margin: -1px 0 0 -6px; border-radius: 2px; background: #c4b5fd; transition: transform 0.3s; }
.faq-plus::after { transform: rotate(90deg); }
.faq-item[open] .faq-plus { transform: rotate(45deg); background: linear-gradient(135deg, var(--primary), var(--primary-2)); }
.faq-item[open] .faq-plus::before, .faq-item[open] .faq-plus::after { background: #fff; }
.faq-item[open] { border-color: rgba(139, 92, 246, 0.4); background: radial-gradient(400px 160px at 0% 0%, rgba(124, 58, 237, 0.12), transparent 70%), var(--surface); }
.faq-item p { margin: 0; padding: 0 24px 22px 66px; color: var(--muted); font-size: 15px; line-height: 1.75; }
.faq-item p a { color: #a78bfa; }
.hub-page .legal-grid .empty { grid-column: 1 / -1; }
.hub-page .idea-banner, .apps-page .idea-banner { margin-top: 72px; }
@media (max-width: 720px) {
  .faq-item summary { padding: 16px 18px; gap: 12px; }
  .faq-num { font-size: 20px; }
  .faq-item summary b { font-size: 15px; }
  .faq-item p { padding: 0 18px 18px; font-size: 14px; }
  .hub-page .idea-banner, .apps-page .idea-banner { margin-top: 48px; }
}

/* ---------- Meet the developer v2: full-width aligned ---------- */
.dev2 { grid-template-columns: auto minmax(0, 1fr); gap: 44px; align-items: center; padding: 40px 44px; }
.dev2 .dev-photo { width: 200px; height: 200px; }
.dev-main { display: grid; gap: 22px; min-width: 0; }
.dev2 h2 { margin: 0 0 6px; }
.dev2 .role { margin-bottom: 10px; }
.dev2 p { margin: 0; max-width: none; }
.dev-stats { margin-top: 0; }
.dev-foot { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding-top: 20px; border-top: 1px solid var(--border); }
.dev-social { display: flex; align-items: center; gap: 14px; }
.dev-social small { font-size: 11px; font-weight: 800; letter-spacing: 0.16em; text-transform: uppercase; color: var(--faint); white-space: nowrap; }
.dev2 .dev-socials { margin-top: 0; }
.dev-foot .btn { height: 52px; padding: 0 28px; }
.dev-foot .btn svg { width: 18px; height: 18px; }
@media (max-width: 1024px) {
  .dev2 { grid-template-columns: auto minmax(0, 1fr); gap: 30px; padding: 32px; }
  .dev2 .dev-photo { width: 150px; height: 150px; }
}
@media (max-width: 720px) {
  .dev2 { grid-template-columns: 1fr; justify-items: center; text-align: center; padding: 28px 20px; gap: 22px; }
  .dev2 .dev-photo { width: 130px; height: 130px; }
  .dev-main { width: 100%; }
  .dev-foot { flex-direction: column; gap: 16px; }
  .dev-social { flex-direction: column; gap: 10px; }
  .dev-foot .btn { width: 100%; }
}

/* ---------- Policy pages v2 ---------- */
.dh2 { display: grid; gap: 26px; padding: 34px 36px; background: radial-gradient(520px 260px at 0% 0%, rgba(var(--tone), 0.18), transparent 70%), var(--surface); }
.dh-top { display: flex; align-items: center; gap: 26px; }
.dh2 .lg-icon .app-icon { width: 92px; height: 92px; }
.dh-title { flex: 1; min-width: 0; }
.dh2 h1 { margin: 6px 0 0; }
.dh2 .tabs { margin-left: auto; flex-shrink: 0; }
.dh-stats { grid-template-columns: repeat(4, minmax(0, 1fr)); margin-top: 0; }
.dh-stats b { font-size: 18px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.toc-progress { height: 4px; border-radius: 4px; background: rgba(255, 255, 255, 0.06); margin: -4px 0 16px; overflow: hidden; }
.toc-progress i { display: block; height: 100%; border-radius: inherit; background: linear-gradient(90deg, #8b5cf6, #3b82f6); transform: scaleX(0); transform-origin: left; transition: transform 0.15s linear; }
.prose h2 { display: flex; align-items: baseline; gap: 14px; }
.h-num { flex-shrink: 0; font-size: 13px; font-weight: 800; letter-spacing: 0.04em; padding: 4px 10px; border-radius: 999px; color: #c4b5fd; background: rgba(124, 58, 237, 0.14); border: 1px solid rgba(139, 92, 246, 0.35); transform: translateY(-3px); }
@media (max-width: 1024px) {
  .dh-top { flex-wrap: wrap; }
  .dh2 .tabs { margin-left: 0; flex-basis: 100%; }
  .dh-stats { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .toc-progress { display: none; }
}
@media (max-width: 720px) {
  .dh2 { padding: 24px 18px; gap: 18px; }
  .dh-top { flex-direction: column; text-align: center; gap: 14px; }
  .dh2 .lg-icon .app-icon { width: 76px; height: 76px; }
  .dh-stats b { font-size: 15px; white-space: normal; }
  .prose h2 { gap: 10px; }
}

/* ---------- FAQ v2: aligned, toned ---------- */
.faq-item { position: relative; transition: border-color 0.3s, background 0.3s, box-shadow 0.3s; }
.faq-item::before { content: ""; position: absolute; left: 0; top: 18px; bottom: 18px; width: 3px; border-radius: 0 3px 3px 0; background: linear-gradient(rgb(var(--tone)), var(--accent)); opacity: 0; transition: opacity 0.3s; }
.faq-item[open]::before { opacity: 1; }
.faq-item summary { padding: 18px 22px; gap: 18px; }
.faq-ico { width: 50px; height: 50px; border-radius: 50%; flex-shrink: 0; display: grid; place-items: center; color: rgb(var(--tone)); background: rgba(var(--tone), 0.14); border: 1px solid rgba(var(--tone), 0.4); box-shadow: 0 0 22px rgba(var(--tone), 0.2); transition: transform 0.3s; }
.faq-ico svg { width: 21px; height: 21px; filter: brightness(1.35); }
.faq-item:hover .faq-ico { transform: rotate(-6deg) scale(1.05); }
.faq-q { flex: 1; min-width: 0; display: grid; gap: 2px; }
.faq-q small { font-size: 11px; font-weight: 800; letter-spacing: 0.16em; text-transform: uppercase; color: rgb(var(--tone)); filter: brightness(1.4); }
.faq-q b { font-size: 17.5px; font-weight: 800; letter-spacing: -0.015em; }
.faq-item:hover { border-color: rgba(var(--tone), 0.35); }
.faq-item[open] { border-color: rgba(var(--tone), 0.5); background: radial-gradient(500px 180px at 0% 0%, rgba(var(--tone), 0.13), transparent 70%), var(--surface); box-shadow: 0 0 40px rgba(var(--tone), 0.1); }
.faq-item[open] .faq-plus { background: linear-gradient(135deg, rgb(var(--tone)), var(--primary-2)); border-color: transparent; }
.faq-item p { padding: 0 76px 22px 90px; }
@media (max-width: 720px) {
  .faq-item summary { padding: 14px 16px; gap: 12px; }
  .faq-ico { width: 40px; height: 40px; }
  .faq-ico svg { width: 17px; height: 17px; }
  .faq-q b { font-size: 15px; }
  .faq-item p { padding: 0 18px 18px 68px; }
}
.prose ~ .idea-banner, .doc-layout + .idea-banner { margin-top: 48px; }
.idea-banner .lb-stats { display: grid; gap: 6px; }
.idea-banner .lb-stats svg { color: #a78bfa; }

/* ---------- FAQ: two-column with help card ---------- */
.faq-wrap { display: grid; grid-template-columns: minmax(0, 0.85fr) minmax(0, 1.65fr); gap: 24px; align-items: start; }
.faq-help {
  position: sticky; top: 110px;
  display: grid; gap: 16px; padding: 30px; overflow: hidden;
  border-color: rgba(139, 92, 246, 0.35);
  background: radial-gradient(360px 220px at 0% 0%, rgba(124, 58, 237, 0.22), transparent 70%), radial-gradient(300px 200px at 100% 100%, rgba(59, 130, 246, 0.12), transparent 70%), var(--surface);
}
.faq-help .lb-ico { position: relative; width: 62px; height: 62px; border-radius: 50%; display: grid; place-items: center; color: #fff; background: linear-gradient(135deg, var(--primary), var(--accent)); box-shadow: 0 0 34px rgba(124, 58, 237, 0.45); }
.faq-help .lb-ico svg { width: 26px; height: 26px; }
.faq-help .lb-ico i { position: absolute; inset: 0; border-radius: 50%; border: 2px solid rgba(139, 92, 246, 0.6); animation: ping 2.6s cubic-bezier(0, 0, .2, 1) infinite; }
.faq-help .lb-ico i + i { animation-delay: 1.3s; }
.faq-help h3 { margin: 4px 0 0; font-size: 22px; font-weight: 900; letter-spacing: -0.025em; }
.faq-help p { margin: 0; color: var(--muted); font-size: 14.5px; line-height: 1.7; }
.faq-help .svc-points { --tone: 139, 92, 246; }
.faq-help-actions { display: grid; gap: 10px; margin-top: 4px; }
.faq-help-actions .btn { width: 100%; height: 50px; }
.faq-help-actions .btn svg { width: 17px; height: 17px; }
.faq-item::before { left: 12px; top: 26px; bottom: 26px; }
@media (max-width: 1024px) {
  .faq-wrap { grid-template-columns: 1fr; }
  .faq-help { position: static; order: 2; }
  .faq-help-actions { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 720px) {
  .faq-help { padding: 24px 20px; justify-items: center; text-align: center; }
  .faq-help .svc-points { justify-items: start; text-align: left; }
  .faq-help-actions { grid-template-columns: 1fr; width: 100%; }
  .faq-item::before { left: 8px; }
}
@media (prefers-reduced-motion: reduce) { .faq-help .lb-ico i { animation: none; } }
/* Policy pages: no sidebar, full-width article */
.doc-layout.doc-full { grid-template-columns: minmax(0, 1fr); }
.doc-full .prose { padding: 48px 64px; }
@media (max-width: 1024px) { .doc-full .prose { padding: 40px; } }
@media (max-width: 720px) { .doc-full .prose { padding: 28px 20px; } }

/* ---------- FAQ polish v3 ---------- */
.faq-item::before { display: none; }
.faq-item { transition: border-color 0.3s, background 0.3s, box-shadow 0.3s, transform 0.25s; }
.faq-item:not([open]):hover { transform: translateY(-2px); background: radial-gradient(400px 140px at 0% 50%, rgba(var(--tone), 0.08), transparent 70%), var(--surface); }
.faq-plus { background: rgba(var(--tone), 0.14); border-color: rgba(var(--tone), 0.45); }
.faq-plus::before, .faq-plus::after { background: rgb(var(--tone)); filter: brightness(1.45); }
.faq-item[open] .faq-plus { background: linear-gradient(135deg, rgb(var(--tone)), var(--accent)); box-shadow: 0 6px 18px rgba(var(--tone), 0.45); }
.faq-item[open] .faq-plus::before, .faq-item[open] .faq-plus::after { background: #fff; filter: none; }
.faq-item[open] .faq-ico { color: #fff; background: linear-gradient(135deg, rgb(var(--tone)), var(--accent)); border-color: transparent; box-shadow: 0 0 30px rgba(var(--tone), 0.5); }
.faq-item[open] .faq-ico svg { filter: none; }
.faq-item[open] summary { padding-bottom: 14px; }
.faq-item p { position: relative; margin: 0 22px 0 90px; padding: 16px 54px 22px 0; border-top: 1px solid rgba(var(--tone), 0.2); animation: faqIn 0.35s ease-out; }
@keyframes faqIn { from { opacity: 0; transform: translateY(-6px); } to { opacity: 1; transform: none; } }
@media (max-width: 720px) {
  .faq-item p { margin: 0 16px 0 68px; padding: 14px 0 18px; }
}
@media (prefers-reduced-motion: reduce) { .faq-item p { animation: none; } }

/* ---------- FAQ: equal-height columns ---------- */
@media (min-width: 1025px) {
  .faq-wrap { align-items: stretch; }
  .faq-help { position: relative; top: auto; align-content: center; }
  .faq2 { display: grid; grid-auto-rows: 1fr; gap: 14px; }
  .faq-item { display: flex; flex-direction: column; justify-content: center; min-height: 0; }
  .faq-item[open] { justify-content: flex-start; }
  .faq2:has(.faq-item[open]) { grid-auto-rows: auto; align-content: stretch; }
  .faq2:has(.faq-item[open]) .faq-item[open] { flex-grow: 1; }
}

/* ---------- App card: "View app details" button ---------- */
.pa-more {
  display: flex; align-items: center; gap: 12px;
  height: 54px; padding: 0 6px 0 8px; margin-top: 2px;
  border-radius: 999px; font-size: 13px; font-weight: 800; letter-spacing: 0.08em; text-transform: uppercase; color: #ececf2;
  background: linear-gradient(90deg, rgba(var(--tone), 0.18), rgba(var(--tone), 0.05));
  border: 1px solid rgba(var(--tone), 0.45);
  transition: border-color 0.25s, box-shadow 0.25s, transform 0.2s;
}
.pa-more > span { width: 40px; height: 40px; border-radius: 50%; display: grid; place-items: center; color: rgb(var(--tone)); background: rgba(var(--tone), 0.18); flex-shrink: 0; }
.pa-more > span svg { width: 18px; height: 18px; filter: brightness(1.4); }
.pa-more i { margin-left: auto; width: 42px; height: 42px; border-radius: 50%; display: grid; place-items: center; color: #fff; background: linear-gradient(135deg, rgb(var(--tone)), #3b82f6); box-shadow: 0 6px 18px rgba(var(--tone), 0.45); transition: transform 0.25s; }
.pa-more i svg { width: 17px; height: 17px; }
.pa-more:hover { border-color: rgba(var(--tone), 0.85); box-shadow: 0 0 30px rgba(var(--tone), 0.25); transform: translateY(-2px); }
.pa-more:hover i { transform: translateX(3px); }

/* ---------- App details page ---------- */
.ad-hero .crumbs { margin-bottom: 18px; }
.ad-id { display: flex; align-items: center; gap: 20px; margin-bottom: 18px; }
.ad-id .lg-icon .app-icon { width: 96px; height: 96px; }
.ad-id h1 { font-size: clamp(34px, 4.6vw, 56px); margin: 0 0 8px; }
.ad-id .status { margin-left: 4px; }
.ad-hero .lead { margin-bottom: 22px; }
.ad-hero .stores { --tone: var(--tone); }
.ad-phone { left: 50% !important; right: auto !important; transform: translateX(-50%) rotate(-6deg) !important; top: 20px !important; }
.ad-split { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; }
.ad-panel { padding: 30px; display: grid; gap: 12px; align-content: start; --tone: 139, 92, 246; }
.ad-panel:nth-child(2) { --tone: 16, 185, 129; }
.ad-panel h3 { margin: 6px 0 0; font-size: 21px; font-weight: 900; letter-spacing: -0.02em; }
.ad-panel > p { margin: 0; color: var(--muted); font-size: 14px; }
.ad-panel .tags span { flex: 1 1 auto; text-align: center; padding: 8px 14px; }
.ad-legal { grid-template-columns: 1fr; }
.ad-more { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.ad-other { display: flex; align-items: center; gap: 16px; padding: 18px 20px; }
.ad-other .lg-icon .app-icon { width: 56px; height: 56px; }
.ad-other .sk-ico { width: 56px; height: 56px; }
.ad-other-text { flex: 1; min-width: 0; display: grid; }
.ad-other-text b { font-size: 17px; }
.ad-other-text small { color: var(--faint); font-size: 12.5px; }
.ad-other:hover .la-go { color: #fff; background: linear-gradient(135deg, rgb(var(--tone)), #3b82f6); }
@media (max-width: 1024px) {
  .ad-id { justify-content: center; text-align: left; }
}
@media (max-width: 720px) {
  .ad-id { flex-direction: column; text-align: center; }
  .ad-id .lg-icon .app-icon { width: 80px; height: 80px; }
  .ad-split, .ad-more { grid-template-columns: 1fr; }
  .pa-more { font-size: 12px; }
}
.ad-hero .ah-stats b { white-space: nowrap; font-size: 22px; }

/* ---------- App details: title block alignment ---------- */
.ad-id { align-items: center; gap: 22px; }
.ad-id > div { min-width: 0; display: grid; gap: 12px; }
.ad-id .lg-icon .app-icon { width: 88px; height: 88px; }
.ad-id h1 { font-size: clamp(30px, 3.3vw, 44px); line-height: 1.05; letter-spacing: -0.04em; margin: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ad-id .wa-meta { margin: 0; gap: 10px; align-items: center; }
.ad-id .wa-meta .ver, .ad-id .status { height: 28px; display: inline-flex; align-items: center; padding: 0 12px; margin: 0; }
.ad-id .status .live-dot { margin-right: 7px; }
@media (max-width: 720px) {
  .ad-id { gap: 14px; }
  .ad-id > div { justify-items: center; }
  .ad-id h1 { white-space: normal; font-size: 30px; }
  .ad-id .wa-meta { justify-content: center; }
}

/* ---------- App details: how it works ---------- */
.steps { position: relative; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 24px; }
.steps::before { content: ""; position: absolute; top: 62px; left: 12%; right: 12%; height: 2px; background: linear-gradient(90deg, rgba(139, 92, 246, 0.6), rgba(16, 185, 129, 0.6), rgba(245, 158, 11, 0.6)); opacity: 0.5; }
.step { padding: 30px; display: grid; gap: 14px; align-content: start; overflow: hidden; background: radial-gradient(300px 180px at 0% 0%, rgba(var(--tone), 0.14), transparent 70%), var(--surface); }
.step-num { position: absolute; right: 22px; top: 14px; font-size: 64px; font-weight: 900; letter-spacing: -0.05em; color: transparent; -webkit-text-stroke: 1px rgba(var(--tone), 0.4); }
.step .svc-ico { position: relative; }
.step h3 { margin: 4px 0 0; font-size: 20px; font-weight: 800; letter-spacing: -0.02em; }
.step p { margin: 0; color: var(--muted); font-size: 14.5px; line-height: 1.7; }

/* ---------- App details: feature explorer ---------- */
.fx-filters { display: flex; flex-wrap: wrap; gap: 10px; margin-bottom: 22px; }
.fx-filter {
  display: inline-flex; align-items: center; gap: 10px;
  height: 44px; padding: 0 8px 0 18px; border-radius: 999px; cursor: pointer;
  font: 700 13.5px "Inter", sans-serif; color: var(--muted);
  background: rgba(255, 255, 255, 0.03); border: 1px solid var(--border-strong);
  transition: color 0.2s, background 0.2s, border-color 0.2s, box-shadow 0.2s;
}
.fx-filter em { font-style: normal; min-width: 28px; height: 28px; padding: 0 8px; border-radius: 999px; display: grid; place-items: center; font-size: 12px; color: #c4b5fd; background: rgba(124, 58, 237, 0.16); }
.fx-filter:hover { color: #fff; border-color: rgba(139, 92, 246, 0.5); }
.fx-filter.on { color: #fff; background: linear-gradient(135deg, var(--primary), var(--primary-2)); border-color: transparent; box-shadow: 0 8px 24px rgba(124, 58, 237, 0.4); }
.fx-filter.on em { color: #fff; background: rgba(255, 255, 255, 0.2); }
.feat-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 18px; }
.feat {
  display: flex; gap: 16px; align-items: flex-start; padding: 22px;
  background: radial-gradient(260px 140px at 0% 0%, rgba(var(--tone), 0.12), transparent 70%), var(--surface);
  animation: featIn 0.35s ease-out both;
}
.feat.hide { display: none; }
.feat.hover:hover { border-color: rgba(var(--tone), 0.45); box-shadow: 0 18px 44px rgba(0, 0, 0, 0.45), 0 0 34px rgba(var(--tone), 0.12); }
.feat-ico { width: 48px; height: 48px; border-radius: 50%; flex-shrink: 0; display: grid; place-items: center; color: rgb(var(--tone)); background: rgba(var(--tone), 0.15); border: 1px solid rgba(var(--tone), 0.4); box-shadow: 0 0 22px rgba(var(--tone), 0.2); transition: transform 0.3s; }
.feat-ico svg { width: 21px; height: 21px; filter: brightness(1.35); }
.feat:hover .feat-ico { transform: rotate(-6deg) scale(1.06); }
.feat-tag { font-size: 10.5px; font-weight: 800; letter-spacing: 0.14em; text-transform: uppercase; color: rgb(var(--tone)); filter: brightness(1.45); }
.feat h3 { margin: 4px 0 6px; font-size: 16.5px; font-weight: 800; letter-spacing: -0.015em; }
.feat p { margin: 0; color: var(--muted); font-size: 13.5px; line-height: 1.6; }
@keyframes featIn { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }
@media (max-width: 1024px) {
  .steps { grid-template-columns: 1fr; }
  .steps::before { display: none; }
  .feat-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 720px) {
  .fx-filters { flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; margin-left: -4px; margin-right: -4px; padding: 2px 4px; }
  .fx-filters::-webkit-scrollbar { display: none; }
  .fx-filter { flex-shrink: 0; height: 40px; font-size: 12.5px; }
  .feat-grid { grid-template-columns: 1fr; gap: 12px; }
  .feat { padding: 18px; }
  .step { padding: 24px; }
}
@media (prefers-reduced-motion: reduce) { .feat { animation: none; } }

/* Portfolio section tabs: hidden until About is ~70% visible */
.subnav-wrap { transition: opacity 0.35s ease, transform 0.35s ease, visibility 0.35s; }
.subnav-wrap.subnav-hidden { opacity: 0; visibility: hidden; transform: translateY(-14px); pointer-events: none; }
.subnav-wrap.subnav-hidden .subnav { pointer-events: none; }
@media (prefers-reduced-motion: reduce) { .subnav-wrap { transition: none; } }

/* Portfolio section tabs float under the header (no layout space reserved) */
.subnav-wrap {
  position: fixed; top: 96px; left: 50%; z-index: 45;
  width: min(1192px, calc(100% - 48px)); margin: 0;
  transform: translateX(-50%);
}
.subnav-wrap.subnav-hidden { transform: translate(-50%, -14px); }
.subnav-wrap + .section { margin-top: 56px; }
@media (max-width: 1024px) { .subnav-wrap { top: 92px; width: calc(100% - 40px); } }
@media (max-width: 720px) {
  .subnav-wrap { top: 80px; width: calc(100% - 24px); }
  .subnav-wrap + .section { margin-top: 40px; }
}

/* ---------- Feature explorer v2 ---------- */
.fx-bar {
  display: flex; flex-wrap: wrap; gap: 8px; padding: 8px; margin-bottom: 24px;
  border-radius: 999px;
  background: rgba(16, 15, 22, 0.7);
  backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px);
  border: 1px solid rgba(255, 255, 255, 0.08);
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.4), inset 0 1px 0 rgba(255, 255, 255, 0.05);
}
.fx-bar .fx-filter { flex: 1 1 auto; justify-content: center; height: 48px; padding: 0 8px 0 8px; gap: 10px; border-color: transparent; background: transparent; }
.fx-pi { width: 32px; height: 32px; border-radius: 50%; display: grid; place-items: center; color: rgb(var(--tone)); background: rgba(var(--tone), 0.15); transition: background 0.2s, color 0.2s; }
.fx-pi svg { width: 15px; height: 15px; filter: brightness(1.4); }
.fx-bar .fx-filter em { color: rgb(var(--tone)); background: rgba(var(--tone), 0.15); filter: brightness(1.3); }
.fx-bar .fx-filter:hover { color: #fff; background: rgba(var(--tone), 0.08); }
.fx-bar .fx-filter.on { color: #fff; background: linear-gradient(135deg, rgba(var(--tone), 0.95), rgba(var(--tone), 0.65)); box-shadow: 0 8px 24px rgba(var(--tone), 0.4); }
.fx-bar .fx-filter.on .fx-pi { color: #fff; background: rgba(255, 255, 255, 0.2); }
.fx-bar .fx-filter.on .fx-pi svg { filter: none; }
.fx-bar .fx-filter.on em { color: #fff; background: rgba(255, 255, 255, 0.22); filter: none; }

.feat2 { position: relative; overflow: hidden; flex-direction: column; gap: 16px; padding: 24px; }
.feat2::after { content: none; }
.feat2::before {
  content: ""; position: absolute; inset: 0; border-radius: inherit; padding: 1px;
  background: linear-gradient(140deg, rgba(var(--tone), 0.9), transparent 45%, transparent 60%, rgba(var(--tone), 0.5));
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask-composite: xor; mask-composite: exclude;
  opacity: 0; transition: opacity 0.35s; pointer-events: none;
}
.feat2:hover::before { opacity: 1; }
.feat2.hover:hover { border-color: transparent; }
.feat2 > .feat-ico { width: 52px; height: 52px; }
.feat-idx { position: absolute; top: 20px; right: 22px; font-size: 13px; font-weight: 800; letter-spacing: 0.06em; color: rgba(var(--tone), 0.9); filter: brightness(1.3); padding: 4px 10px; border-radius: 999px; background: rgba(var(--tone), 0.1); border: 1px solid rgba(var(--tone), 0.3); }
.feat-mark { position: absolute; right: -22px; bottom: -26px; z-index: -1; color: rgba(var(--tone), 0.07); transition: transform 0.5s, color 0.4s; }
.feat-mark svg { width: 130px; height: 130px; stroke-width: 1.3; }
.feat2:hover .feat-mark { transform: rotate(-10deg) scale(1.06); color: rgba(var(--tone), 0.13); }
.feat2 h3 { font-size: 18px; margin-top: 6px; }
.feat2 p { font-size: 14px; }
.feat-grid { align-items: stretch; }
@media (max-width: 1024px) {
  .fx-bar { border-radius: 28px; }
}
@media (max-width: 720px) {
  .fx-bar { flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; border-radius: 999px; }
  .fx-bar::-webkit-scrollbar { display: none; }
  .fx-bar .fx-filter { flex: 0 0 auto; height: 44px; padding: 0 6px; }
  .fx-pi { width: 28px; height: 28px; }
  .feat2 { padding: 20px; }
}

/* ---------- App details: Built with / Third-party panels v2 ---------- */
.ad-split { align-items: stretch; }
.ad-panel { display: flex; flex-direction: column; gap: 18px; padding: 28px; background: radial-gradient(360px 200px at 0% 0%, rgba(var(--tone), 0.14), transparent 70%), var(--surface); }
.ad-panel-head { display: flex; align-items: center; gap: 14px; }
.ad-panel-head > div { flex: 1; min-width: 0; }
.ad-panel-head h3 { margin: 0; font-size: 20px; font-weight: 900; letter-spacing: -0.02em; }
.ad-panel-head p { margin: 2px 0 0; color: var(--muted); font-size: 13.5px; }
.ad-count { min-width: 40px; height: 40px; padding: 0 12px; border-radius: 999px; display: grid; place-items: center; font-size: 15px; font-weight: 900; color: rgb(var(--tone)); filter: brightness(1.35); background: rgba(var(--tone), 0.12); border: 1px solid rgba(var(--tone), 0.35); }
.ad-rows { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.ad-row { display: flex; align-items: center; gap: 14px; padding: 10px 14px 10px 10px; border-radius: 999px; background: rgba(255, 255, 255, 0.025); border: 1px solid var(--border); transition: border-color 0.2s, background 0.2s, transform 0.2s; }
.ad-row:hover { border-color: rgba(var(--tone), 0.45); background: rgba(var(--tone), 0.06); transform: translateX(3px); }
.ad-row-ico { width: 38px; height: 38px; border-radius: 50%; flex-shrink: 0; display: grid; place-items: center; color: rgb(var(--tone)); background: rgba(var(--tone), 0.14); border: 1px solid rgba(var(--tone), 0.35); }
.ad-row-ico svg { width: 17px; height: 17px; filter: brightness(1.35); }
.ad-row-text { flex: 1; min-width: 0; display: grid; }
.ad-row-text b { font-size: 14.5px; font-weight: 700; }
.ad-row-text small { font-size: 12.5px; color: var(--faint); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ad-badge { font-style: normal; flex-shrink: 0; font-size: 10.5px; font-weight: 800; letter-spacing: 0.1em; text-transform: uppercase; padding: 4px 10px; border-radius: 999px; color: var(--muted); background: rgba(255, 255, 255, 0.05); border: 1px solid var(--border-strong); }
.ad-link { margin-top: auto; display: inline-flex; align-items: center; gap: 8px; font-size: 13px; font-weight: 800; letter-spacing: 0.06em; text-transform: uppercase; color: rgb(var(--tone)); filter: brightness(1.35); }
.ad-link svg { width: 16px; height: 16px; transition: transform 0.2s; }
.ad-link:hover svg { transform: translateX(4px); }
@media (max-width: 720px) {
  .ad-panel { padding: 22px 18px; }
  .ad-row { border-radius: 22px; }
  .ad-row-text small { white-space: normal; }
}

/* ---------- App details: More apps v2 ---------- */
.ad-other { position: relative; overflow: hidden; align-items: center; gap: 20px; padding: 24px; background: radial-gradient(320px 180px at 0% 50%, rgba(var(--tone), 0.18), transparent 70%), var(--surface); }
.ad-o-glow { position: absolute; right: -60px; top: -60px; width: 200px; height: 200px; border-radius: 50%; background: radial-gradient(circle, rgba(var(--tone), 0.3), transparent 70%); pointer-events: none; z-index: -1; transition: transform 0.5s; }
.ad-other:hover .ad-o-glow { transform: scale(1.2); }
.ad-other.hover:hover { border-color: rgba(var(--tone), 0.5); box-shadow: 0 20px 50px rgba(0, 0, 0, 0.5), 0 0 40px rgba(var(--tone), 0.15); }
.ad-other .lg-icon .app-icon { width: 72px; height: 72px; }
.ad-other-text { gap: 4px; }
.ad-o-meta { display: flex; align-items: center; gap: 8px; font-size: 11px; font-weight: 800; letter-spacing: 0.14em; text-transform: uppercase; color: rgb(var(--tone)); filter: brightness(1.4); }
.ad-o-meta em { font-style: normal; letter-spacing: 0.04em; text-transform: none; padding: 2px 8px; border-radius: 999px; color: #e4e4ea; background: rgba(255, 255, 255, 0.07); filter: none; }
.ad-other-text b { font-size: 19px; font-weight: 900; letter-spacing: -0.02em; }
.ad-other-text small { font-size: 13px; color: var(--muted); line-height: 1.5; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.ad-o-go { width: 48px; height: 48px; border-radius: 50%; flex-shrink: 0; display: grid; place-items: center; color: #fff; background: linear-gradient(135deg, rgb(var(--tone)), #3b82f6); box-shadow: 0 8px 22px rgba(var(--tone), 0.45); transition: transform 0.3s; }
.ad-o-go svg { width: 18px; height: 18px; }
.ad-other:hover .ad-o-go { transform: rotate(-45deg); }
.ad-all-icons { position: relative; display: flex; flex-shrink: 0; }
.ad-all-icons img, .ad-all-icons i { width: 48px; height: 48px; border-radius: 50%; border: 3px solid var(--surface); margin-left: -14px; object-fit: cover; }
.ad-all-icons img:first-child { margin-left: 0; }
.ad-all-icons i { display: grid; place-items: center; color: #fff; background: linear-gradient(135deg, var(--primary), var(--accent)); }
.ad-all-icons i svg { width: 20px; height: 20px; }
@media (max-width: 720px) {
  .ad-other { padding: 20px; gap: 14px; }
  .ad-other .lg-icon .app-icon { width: 56px; height: 56px; }
  .ad-o-go { width: 40px; height: 40px; }
  .ad-all-icons img, .ad-all-icons i { width: 40px; height: 40px; }
}

/* ---------- Responsive polish: tablet header + small phones ---------- */
/* Tablet & small laptop: collapse search into the round button (like phones) */
@media (min-width: 721px) and (max-width: 1100px) {
  .header-inner { flex-wrap: wrap; height: auto; min-height: 64px; padding: 8px 10px; row-gap: 10px; }
  .header .search { display: none; order: 3; flex-basis: 100%; max-width: none; margin: 0; }
  .header.search-open .search { display: block; animation: drop 0.22s ease-out; }
  .header.search-open .header-inner { border-radius: 32px; }
  .header .icon-btn { display: grid; margin-left: auto; width: 46px; height: 46px; }
  .header .switch3 { margin-left: 0; }
  .header .search kbd { display: none; }
}
/* Comfortable reading width for long paragraphs on large screens */
@media (min-width: 1440px) {
  .container { max-width: 1280px; }
  .header-inner { max-width: 1232px; }
}
/* Small phones (≤430): tighter stat tiles, badges and spacing */
@media (max-width: 430px) {
  .ah-stats { gap: 8px; }
  .ah-stats > span { padding: 12px 6px; gap: 6px; border-radius: 18px; }
  .ah-stats > span > i { width: 32px; height: 32px; }
  .ah-stats > span > i svg { width: 15px; height: 15px; }
  .ah-stats b, .ad-hero .ah-stats b { font-size: 18px; }
  .ah-stats small { font-size: 10.5px; line-height: 1.3; }
  .p-hero .badge, .hero .badge { font-size: 9px; letter-spacing: 0.08em; padding: 6px 12px; text-align: center; }
  .section { margin-top: 44px; }
  .section-head h2 { font-size: 26px; }
  .section-head p { font-size: 14px; }
}
/* Very small phones (≤360) */
@media (max-width: 360px) {
  .container { padding: 0 10px; }
  .p-hero h1 .name, .ad-id h1 { font-size: 28px; }
  .switch a { width: 34px; }
  .header .icon-btn { width: 40px; height: 40px; }
}

/* ======================================================================
   Spacing scale (tightened): one rhythm for every page and breakpoint.
   --gap = space between sections, --pad = inner padding of big cards.
   ====================================================================== */
:root { --gap: 48px; --pad: 44px; --head-gap: 20px; }
@media (max-width: 1024px) { :root { --gap: 40px; --pad: 32px; --head-gap: 18px; } }
@media (max-width: 720px)  { :root { --gap: 32px; --pad: 22px; --head-gap: 16px; } }

/* section-to-section */
.section, .portfolio .section,
.subnav-wrap + .section,
.stats + .subnav-wrap + .section { margin-top: var(--gap); }
.section-head p { margin-bottom: var(--head-gap); }
.section-head h2 { margin-bottom: 4px; }

/* closing banners / CTAs and footer */
.idea-banner, .hub-page .idea-banner, .apps-page .idea-banner,
.doc-layout + .idea-banner, .prose ~ .idea-banner,
.portfolio .cta, .cta { margin-top: var(--gap); }
.ft-wrap { margin-top: var(--gap); }
main > .section:first-child, main > .card:first-child { margin-top: 20px; }
.stats { margin-top: 16px; }
.doc-layout { margin-top: 16px; }

/* inner padding of the big hero / feature cards */
.hero, .p-hero, .ah, .about2, .dh2, .dev2 { padding: var(--pad); }
.p-hero { min-height: 0; padding-bottom: var(--pad); }
.doc-full .prose, .prose { padding: calc(var(--pad) - 4px) var(--pad); }
.arch2, .faq-help, .cf2, .ad-panel { padding: calc(var(--pad) - 12px); }
.ft { padding: calc(var(--pad) - 8px) calc(var(--pad) - 4px) 0; }
.ft-grid { padding-bottom: 28px; gap: 32px; }
.ft-bottom { padding: 16px 0 20px; }
.prose h2 { margin-top: 28px; padding-top: 24px; }

/* grids: slightly tighter gutters */
.services, .skills, .works, .quotes2, .legal-grid, .feat-grid, .grid-3, .steps, .ad-split, .ad-more, .contact { gap: 20px; }
@media (max-width: 720px) {
  .services, .skills, .works, .quotes2, .legal-grid, .feat-grid, .grid-3, .steps, .ad-split, .ad-more, .contact { gap: 14px; }
  .ft-grid { gap: 22px 16px; padding-bottom: 22px; }
  .ft-wrap { padding-bottom: 20px; }
}

/* ---------- No divider lines anywhere (spacing separates content instead) ---------- */
.prose h2, .quote figcaption, .q2 figcaption, .info-socials, .svc-link, .wa-legal,
.p-social, .ts-controls, .cf-head, .pa-feats li, .dev-foot, .faq-item p,
.ft-bottom, .pa-banner, .if-bar, .stat-top, .ad-panel-head { border-top: 0 !important; border-bottom: 0 !important; }
.ft::before { display: none; }
.prose h2 { padding-top: 0; margin-top: 32px; }
.faq-item p { padding-top: 4px; }
.pa-feats li { padding: 8px 14px; }
.pa-feats { gap: 2px; }
.ft-bottom { padding-top: 6px; }

/* ---------- Scan to connect: QR cards ---------- */
.qr-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 20px; }
.qr-card {
  --tone: 139, 92, 246;
  position: relative; overflow: hidden;
  display: flex; flex-direction: column; gap: 18px; padding: 22px;
  background:
    radial-gradient(320px 200px at 0% 0%, rgba(var(--tone), 0.22), transparent 70%),
    radial-gradient(260px 200px at 100% 100%, rgba(var(--tone), 0.12), transparent 70%),
    var(--surface);
}
.qr-card::before {
  content: ""; position: absolute; inset: 0; border-radius: inherit; padding: 1px; pointer-events: none;
  background: linear-gradient(140deg, rgba(var(--tone), 0.9), transparent 45%, transparent 60%, rgba(var(--tone), 0.55));
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask-composite: xor; mask-composite: exclude;
  opacity: 0.35; transition: opacity 0.35s;
}
.qr-card:hover::before { opacity: 1; }
.qr-card.hover:hover { border-color: transparent; transform: translateY(-4px); box-shadow: 0 26px 60px rgba(0, 0, 0, 0.55), 0 0 50px rgba(var(--tone), 0.22); }
.qr-glow { position: absolute; right: -70px; top: -70px; width: 220px; height: 220px; border-radius: 50%; background: radial-gradient(circle, rgba(var(--tone), 0.35), transparent 70%); z-index: -1; pointer-events: none; }

.qr-head { display: flex; align-items: center; gap: 12px; }
.qr-brand { width: 46px; height: 46px; border-radius: 50%; flex-shrink: 0; display: grid; place-items: center; color: #fff; background: rgb(var(--tone)); box-shadow: 0 8px 22px rgba(var(--tone), 0.45); }
.qr-brand svg { width: 21px; height: 21px; }
.qr-id { flex: 1; min-width: 0; display: grid; }
.qr-id b { font-size: 17px; font-weight: 900; letter-spacing: -0.02em; }
.qr-id small { font-size: 12.5px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.qr-scan { width: 36px; height: 36px; border-radius: 50%; display: grid; place-items: center; color: rgb(var(--tone)); background: rgba(var(--tone), 0.14); border: 1px solid rgba(var(--tone), 0.35); filter: brightness(1.3); }
.qr-scan svg { width: 16px; height: 16px; }

.qr-frame {
  position: relative; aspect-ratio: 1; padding: 16px;
  border-radius: 26px; background: #fff;
  box-shadow: 0 18px 40px rgba(0, 0, 0, 0.45), 0 0 0 6px rgba(var(--tone), 0.14);
  overflow: hidden;
}
.qr-frame img { display: block; width: 100%; height: 100%; image-rendering: pixelated; }
.qr-logo {
  position: absolute; left: 50%; top: 50%; width: 22%; aspect-ratio: 1; transform: translate(-50%, -50%);
  display: grid; place-items: center; border-radius: 50%;
  color: #fff; background: rgb(var(--tone)); box-shadow: 0 0 0 5px #fff, 0 6px 16px rgba(0, 0, 0, 0.25);
}
.qr-logo svg { width: 52%; height: 52%; }
.qr-c { position: absolute; width: 24px; height: 24px; border: 3px solid rgb(var(--tone)); opacity: 0; transition: opacity 0.3s, inset 0.3s; }
.qr-c.tl { left: 6px; top: 6px; border-right: 0; border-bottom: 0; border-radius: 10px 0 0 0; }
.qr-c.tr { right: 6px; top: 6px; border-left: 0; border-bottom: 0; border-radius: 0 10px 0 0; }
.qr-c.bl { left: 6px; bottom: 6px; border-right: 0; border-top: 0; border-radius: 0 0 0 10px; }
.qr-c.br { right: 6px; bottom: 6px; border-left: 0; border-top: 0; border-radius: 0 0 10px 0; }
.qr-card:hover .qr-c { opacity: 1; }
.qr-beam { position: absolute; left: 8%; right: 8%; top: 0; height: 3px; border-radius: 3px; background: linear-gradient(90deg, transparent, rgb(var(--tone)), transparent); box-shadow: 0 0 14px rgb(var(--tone)); opacity: 0; }
.qr-card:hover .qr-beam { opacity: 0.9; animation: qrBeam 1.8s ease-in-out infinite; }
@keyframes qrBeam { 0% { top: 6%; } 50% { top: 92%; } 100% { top: 6%; } }

.qr-cta { display: flex; align-items: center; justify-content: space-between; height: 50px; padding: 0 6px 0 20px; border-radius: 999px; font-size: 13px; font-weight: 800; letter-spacing: 0.06em; text-transform: uppercase; color: #fff; background: rgba(var(--tone), 0.16); border: 1px solid rgba(var(--tone), 0.4); transition: background 0.25s; }
.qr-cta i { width: 38px; height: 38px; border-radius: 50%; display: grid; place-items: center; background: rgb(var(--tone)); transition: transform 0.25s; }
.qr-cta i svg { width: 16px; height: 16px; }
.qr-card:hover .qr-cta { background: rgba(var(--tone), 0.28); }
.qr-card:hover .qr-cta i { transform: rotate(-45deg); }

/* per-platform touches */
.qr-x .qr-brand, .qr-x .qr-logo, .qr-x .qr-cta i { color: #0f0f14; }
.qr-x .qr-cta i svg { color: #0f0f14; }
.qr-instagram .qr-brand, .qr-instagram .qr-logo, .qr-instagram .qr-cta i { background: linear-gradient(45deg, #feda75, #fa7e1e 25%, #d62976 50%, #962fbf 75%, #4f5bd5); }
.qr-play .qr-brand, .qr-play .qr-logo { background: #0f0f14; }
.qr-github .qr-brand, .qr-github .qr-logo { background: #24292f; }

@media (max-width: 1024px) { .qr-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 720px) {
  .qr-grid { grid-template-columns: 1fr; }
  .qr-card { padding: 18px; }
  .qr-frame { max-width: 280px; width: 100%; margin: 0 auto; }
}
@media (prefers-reduced-motion: reduce) { .qr-card:hover .qr-beam { animation: none; } }
.tl-score { display: inline-flex; align-items: center; gap: 6px; padding: 6px 14px 6px 10px; border-radius: 999px; font-size: 12px; font-weight: 800; color: #6ee7b7; background: rgba(16, 185, 129, 0.12); border: 1px solid rgba(16, 185, 129, 0.4); }
.tl-score svg { width: 14px; height: 14px; stroke-width: 3; }

/* ---------- Experience v3: companies with role history ---------- */
.xp .tl-top { flex-wrap: wrap; }
.xp-type { padding: 5px 12px; border-radius: 999px; font-size: 11px; font-weight: 800; letter-spacing: 0.1em; text-transform: uppercase; color: #93c5fd; background: rgba(59, 130, 246, 0.12); border: 1px solid rgba(59, 130, 246, 0.35); }
.xp-type.t-internship { color: #fcd34d; background: rgba(245, 158, 11, 0.1); border-color: rgba(245, 158, 11, 0.35); }
.xp-type.t-selfemployed { color: #c4b5fd; background: rgba(124, 58, 237, 0.12); border-color: rgba(139, 92, 246, 0.35); }
.xp-now { display: inline-flex; align-items: center; gap: 7px; padding: 5px 12px; border-radius: 999px; font-size: 11px; font-weight: 800; letter-spacing: 0.1em; text-transform: uppercase; color: #34d399; background: rgba(16, 185, 129, 0.12); border: 1px solid rgba(16, 185, 129, 0.35); }
.xp-now .live-dot { display: inline-block; width: 7px; height: 7px; border-radius: 50%; background: #34d399; box-shadow: 0 0 10px #34d399; animation: pulse 2s ease-in-out infinite; }
.xp .tl-title { font-size: 22px; }
.xp > p { margin: 10px 0 0; }
.xp-roles { list-style: none; margin: 16px 0 0; padding: 0; display: grid; gap: 10px; position: relative; }
.xp-roles.multi::before { content: ""; position: absolute; left: 11px; top: 22px; bottom: 22px; width: 2px; background: linear-gradient(rgba(59, 130, 246, 0.8), rgba(59, 130, 246, 0.15)); }
.xp-role { position: relative; display: grid; gap: 10px; padding: 14px 16px 14px 38px; border-radius: 20px; background: rgba(255, 255, 255, 0.025); border: 1px solid var(--border); }
.xp-role.now { background: rgba(59, 130, 246, 0.07); border-color: rgba(59, 130, 246, 0.35); }
.xp-node { position: absolute; left: 6px; top: 18px; width: 12px; height: 12px; border-radius: 50%; background: #1e293b; border: 2px solid #60a5fa; }
.xp-role.now .xp-node { background: #60a5fa; box-shadow: 0 0 12px #60a5fa; }
.xp-role-head { display: grid; gap: 2px; }
.xp-role-head b { font-size: 15.5px; font-weight: 800; letter-spacing: -0.01em; }
.xp-role-head small { font-size: 12.5px; color: var(--faint); font-weight: 600; }
.xp-skills { display: flex; flex-wrap: wrap; gap: 6px; }
.xp-chip { padding: 4px 11px; border-radius: 999px; font-size: 11.5px; font-weight: 600; color: #d4d4dc; background: rgba(255, 255, 255, 0.04); border: 1px solid var(--border-strong); }
.xp .ticks { margin-top: 14px; }
.xp-cert { display: inline-flex; align-items: center; gap: 8px; margin-top: 14px; padding: 7px 14px 7px 10px; border-radius: 999px; font-size: 12.5px; font-weight: 700; color: #fcd34d; background: rgba(245, 158, 11, 0.08); border: 1px solid rgba(245, 158, 11, 0.35); }
.xp-cert svg { width: 15px; height: 15px; stroke-width: 3; }
@media (max-width: 720px) {
  .xp .tl-title { font-size: 19px; }
  .xp-role { padding: 12px 12px 12px 34px; }
}

/* ---------- Experience roles v2 ---------- */
.xp-roles { gap: 12px; }
.xp-roles.multi::before { left: 15px; top: 30px; bottom: 30px; width: 2px; background: linear-gradient(#60a5fa, rgba(96, 165, 250, 0.15)); box-shadow: 0 0 10px rgba(96, 165, 250, 0.6); }
.xp-role { padding: 16px 18px 16px 46px; border-radius: 22px; gap: 12px; transition: border-color 0.25s, background 0.25s, transform 0.25s; }
.xp-role:hover { transform: translateX(3px); border-color: rgba(96, 165, 250, 0.4); }
.xp-role.now { background: linear-gradient(110deg, rgba(59, 130, 246, 0.16), rgba(124, 58, 237, 0.06) 70%); border-color: rgba(96, 165, 250, 0.45); box-shadow: 0 0 30px rgba(59, 130, 246, 0.12); }
.xp-node { left: 8px; top: 24px; width: 16px; height: 16px; background: var(--surface); border: 2px solid #60a5fa; }
.xp-role.now .xp-node { background: #60a5fa; box-shadow: 0 0 0 4px rgba(96, 165, 250, 0.2), 0 0 14px #60a5fa; animation: pulse 2s ease-in-out infinite; }
.xp-role-head { display: flex; align-items: center; gap: 12px; }
.xp-ri { width: 38px; height: 38px; border-radius: 50%; flex-shrink: 0; display: grid; place-items: center; color: #93c5fd; background: rgba(59, 130, 246, 0.14); border: 1px solid rgba(59, 130, 246, 0.35); }
.xp-ri svg { width: 17px; height: 17px; }
.xp-role.now .xp-ri { color: #fff; background: linear-gradient(135deg, #3b82f6, #7c3aed); border-color: transparent; }
.xp-rt { flex: 1; min-width: 0; display: grid; gap: 3px; }
.xp-rt b { font-size: 16px; font-weight: 800; }
.xp-rt small { display: inline-flex; align-items: center; gap: 6px; font-size: 12.5px; color: var(--faint); font-weight: 600; }
.xp-rt small svg { width: 13px; height: 13px; }
.xp-promo { font-style: normal; display: inline-flex; align-items: center; gap: 6px; flex-shrink: 0; padding: 5px 11px; border-radius: 999px; font-size: 11px; font-weight: 800; letter-spacing: 0.08em; text-transform: uppercase; color: #fcd34d; background: rgba(245, 158, 11, 0.12); border: 1px solid rgba(245, 158, 11, 0.4); }
.xp-promo svg { width: 13px; height: 13px; }
.xp-skills { padding-left: 50px; }
.xp-chip { color: #bfdbfe; background: rgba(59, 130, 246, 0.08); border-color: rgba(59, 130, 246, 0.28); }
.xp-role.now .xp-chip { color: #fff; background: rgba(59, 130, 246, 0.16); border-color: rgba(96, 165, 250, 0.45); }
@media (max-width: 720px) {
  .xp-role { padding: 14px 14px 14px 40px; }
  .xp-roles.multi::before { left: 13px; }
  .xp-node { left: 6px; }
  .xp-role-head { flex-wrap: wrap; }
  .xp-skills { padding-left: 0; }
}
@media (max-width: 720px) { .xp-role-head { display: grid; grid-template-columns: auto 1fr; } .xp-promo { grid-column: 1 / -1; justify-self: start; } .xp-ri { width: 34px; height: 34px; } }

/* ---------- Experience: apps built ---------- */
.xp-built { margin-top: 14px; padding: 16px; border-radius: 22px; background: linear-gradient(120deg, rgba(16, 185, 129, 0.08), rgba(59, 130, 246, 0.05)); border: 1px solid rgba(16, 185, 129, 0.3); display: grid; gap: 12px; }
.xp-built-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; flex-wrap: wrap; }
.xp-built-head b { display: inline-flex; align-items: center; gap: 8px; font-size: 13px; font-weight: 800; letter-spacing: 0.06em; text-transform: uppercase; color: #6ee7b7; }
.xp-built-head b svg { width: 16px; height: 16px; }
.xp-built-head span { display: flex; flex-wrap: wrap; gap: 6px; }
.xp-built-head em { font-style: normal; padding: 3px 10px; border-radius: 999px; font-size: 11.5px; font-weight: 700; color: #d1fae5; background: rgba(16, 185, 129, 0.14); border: 1px solid rgba(16, 185, 129, 0.35); }
.xp-apps { display: grid; gap: 8px; }
.xp-app { display: flex; align-items: center; gap: 12px; padding: 10px 10px 10px 10px; border-radius: 999px; background: rgba(10, 10, 16, 0.6); border: 1px solid var(--border); }
.xp-app-ico { width: 40px; height: 40px; border-radius: 50%; flex-shrink: 0; display: grid; place-items: center; font-weight: 900; font-size: 17px; color: #fff; background: linear-gradient(135deg, #10b981, #3b82f6); }
.xp-app-text { flex: 1; min-width: 0; display: grid; }
.xp-app-text b { font-size: 15px; }
.xp-app-text small { font-size: 12px; color: var(--faint); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.xp-app-stores { display: flex; gap: 6px; flex-shrink: 0; }
.xp-st { display: inline-flex; align-items: center; gap: 6px; height: 34px; padding: 0 12px 0 9px; border-radius: 999px; font-size: 11.5px; font-weight: 700; color: #fff; background: #000; border: 1px solid rgba(255, 255, 255, 0.16); }
.xp-st svg { width: 16px; height: 16px; }
a.xp-st:hover { border-color: rgba(16, 185, 129, 0.7); box-shadow: 0 6px 18px rgba(16, 185, 129, 0.25); }
@media (max-width: 720px) {
  .xp-app { flex-wrap: wrap; border-radius: 20px; }
  .xp-app-stores { width: 100%; }
  .xp-st { flex: 1; justify-content: center; }
}

/* ---------- Role timeline v3: own gutter, flowing glow, centred markers ---------- */
.xp-roles { --rail: 30px; }
.xp-roles:not(.multi) .xp-node { display: none; }
.xp-roles:not(.multi) .xp-role { padding-left: 18px; }
.xp-roles.multi { padding-left: var(--rail); }
.xp-roles.multi .xp-role { padding-left: 18px; }
.xp-roles.multi::before {
  left: 10px; top: 35px; bottom: 35px; width: 2px; border-radius: 2px;
  background: linear-gradient(#60a5fa, #8b5cf6 60%, rgba(139, 92, 246, 0.2));
  box-shadow: 0 0 12px rgba(96, 165, 250, 0.55);
}
.xp-roles.multi::after {
  content: ""; position: absolute; left: 9px; top: 35px; width: 4px; height: 40px; border-radius: 4px;
  background: linear-gradient(transparent, #fff, transparent); opacity: 0.85; filter: blur(0.5px);
  animation: railFlow 2.8s ease-in-out infinite;
}
@keyframes railFlow { 0% { transform: translateY(0); opacity: 0; } 15% { opacity: 0.9; } 85% { opacity: 0.9; } 100% { transform: translateY(var(--rail-len, 120px)); opacity: 0; } }
.xp-roles.multi .xp-node {
  left: calc(-1 * var(--rail) + 1px); top: 25px;
  width: 20px; height: 20px; border-radius: 50%;
  background: var(--bg); border: 2px solid #60a5fa;
  box-shadow: 0 0 0 4px rgba(96, 165, 250, 0.12);
  display: grid; place-items: center; animation: none;
}
.xp-roles.multi .xp-node::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: #60a5fa; }
.xp-roles.multi .xp-role.now .xp-node { background: linear-gradient(135deg, #3b82f6, #8b5cf6); border-color: #fff; box-shadow: 0 0 0 4px rgba(96, 165, 250, 0.25), 0 0 18px rgba(96, 165, 250, 0.9); }
.xp-roles.multi .xp-role.now .xp-node::before { background: #fff; }
.xp-roles.multi .xp-role.now .xp-node::after { content: ""; position: absolute; inset: -6px; border-radius: 50%; border: 2px solid rgba(96, 165, 250, 0.7); animation: ping 2.2s cubic-bezier(0, 0, .2, 1) infinite; }
/* small connector from marker to card */
.xp-roles.multi .xp-role::before { content: ""; position: absolute; left: calc(-1 * var(--rail) + 21px); top: 34px; width: calc(var(--rail) - 21px); height: 2px; background: rgba(96, 165, 250, 0.5); }
@media (max-width: 720px) {
  .xp-roles { --rail: 26px; }
  .xp-roles.multi .xp-role { padding-left: 14px; }
  .xp-roles.multi::before { left: 8px; }
  .xp-roles.multi::after { left: 7px; }
}
@media (prefers-reduced-motion: reduce) { .xp-roles.multi::after, .xp-roles.multi .xp-role.now .xp-node::after { animation: none; } }
.xp-roles.multi::before { bottom: auto; height: var(--rail-h, calc(100% - 70px)); }
/* Role titles on a single line */
.xp-rt b { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; font-size: clamp(14px, 1.15vw, 16px); letter-spacing: -0.015em; }
.xp-rt small { white-space: nowrap; }
@media (max-width: 720px) { .xp-rt b { font-size: clamp(12.5px, 3.6vw, 15px); letter-spacing: -0.02em; } .xp-rt small { font-size: 11.5px; } }
/* Role skill chips span the full row */
.xp-skills { display: grid; grid-template-columns: repeat(auto-fit, minmax(70px, 1fr)); gap: 8px; padding-left: 50px; }
.xp-chip { text-align: center; padding: 6px 10px; }
@media (max-width: 720px) { .xp-skills { padding-left: 0; grid-template-columns: repeat(4, 1fr); } }
@media (max-width: 430px) { .xp-ri { display: none; } .xp-role-head { grid-template-columns: 1fr; } .xp-rt b { font-size: 13.5px; } }
/* Role chips: one line each, sized to text, still filling the row */
.xp-skills { display: flex; flex-wrap: wrap; gap: 8px; }
.xp-chip { flex: 1 1 auto; white-space: nowrap; height: 32px; display: inline-flex; align-items: center; justify-content: center; padding: 0 14px; }
@media (max-width: 400px) { .sk-chips li { font-size: 12px; padding: 9px 10px; gap: 6px; letter-spacing: -0.01em; } .sk-chips { gap: 8px; } }
.xp-skills { padding-left: 0 !important; }

/* ---------- Contact form: direct send + success state ---------- */
.hp { position: absolute !important; left: -9999px !important; width: 1px; height: 1px; opacity: 0; }
.cf2 { position: relative; }
.cf2.sent > :not(.cf-done) { visibility: hidden; }
.cf-done { position: absolute; inset: 0; z-index: 2; display: grid; place-content: center; justify-items: center; gap: 12px; padding: 30px; text-align: center; border-radius: inherit; background: radial-gradient(420px 260px at 50% 30%, rgba(16, 185, 129, 0.18), transparent 70%), var(--surface); animation: featIn 0.4s ease-out; }
.cf-done[hidden] { display: none; }
.cf-done-ico { width: 78px; height: 78px; border-radius: 50%; display: grid; place-items: center; color: #fff; background: linear-gradient(135deg, #10b981, #3b82f6); box-shadow: 0 0 0 10px rgba(16, 185, 129, 0.12), 0 0 40px rgba(16, 185, 129, 0.5); }
.cf-done-ico svg { width: 36px; height: 36px; stroke-width: 3; }
.cf-done b { font-size: 26px; font-weight: 900; letter-spacing: -0.02em; margin-top: 8px; }
.cf-done p { margin: 0; max-width: 380px; color: var(--muted); line-height: 1.6; }
.cf-done p span { color: #fff; font-weight: 700; }
.cf-done .btn { margin-top: 10px; }
.btn.loading { opacity: 0.75; pointer-events: none; }
.btn.loading svg { animation: spin 0.9s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }

/* ---------- Footer v3: simple two-row ---------- */
.ft2 { padding: 30px 34px 0; display: grid; gap: 0; }
.ft2 .ft-row { display: flex; align-items: center; gap: 24px; padding-bottom: 22px; }
.ft2 .ft-tag { flex: 1; margin: 0; color: var(--muted); font-size: 14.5px; }
.ft2 .ft-socials { margin: 0; gap: 8px; }
.ft2 .ft-socials .social { width: 40px; height: 40px; }
.ft2 .ft-mid { justify-content: space-between; padding: 18px 0 22px; }
.ft-links { display: flex; flex-wrap: wrap; gap: 6px; padding: 6px; border-radius: 999px; background: rgba(255, 255, 255, 0.03); border: 1px solid var(--border); }
.ft-links a { padding: 9px 16px; border-radius: 999px; font-size: 13.5px; font-weight: 600; color: var(--muted); transition: color 0.2s, background 0.2s; }
.ft-links a:hover { color: #fff; background: rgba(124, 58, 237, 0.18); }
.ft-cta { display: flex; align-items: center; gap: 18px; }
.ft2 .ft-mail { font-size: 14px; }
.ft2 .ft-btn { margin: 0; height: 46px; }
.ft2 .ft-bottom { padding: 16px 0 20px; font-size: 12.5px; }
@media (max-width: 1024px) {
  .ft2 .ft-row { flex-wrap: wrap; }
  .ft2 .ft-tag { flex-basis: 100%; order: 3; }
  .ft2 .ft-socials { margin-left: auto; }
  .ft2 .ft-mid { flex-direction: column; align-items: flex-start; gap: 16px; }
}
@media (max-width: 720px) {
  .ft2 { padding: 26px 18px 0; text-align: center; }
  .ft2 .ft-row { flex-direction: column; gap: 14px; }
  .ft2 .ft-tag { order: 0; }
  .ft2 .ft-socials { margin: 0; justify-content: center; }
  .ft2 .ft-mid { align-items: center; }
  .ft-links { justify-content: center; border-radius: 24px; }
  .ft-links a { padding: 8px 12px; font-size: 13px; }
  .ft-cta { flex-direction: column; gap: 12px; width: 100%; }
  .ft2 .ft-btn { width: 100%; }
}
@media (max-width: 720px) { .ft2 .ft-row { flex-wrap: nowrap; align-items: center; } .ft2 .ft-tag { flex: none; text-align: center; } .ft2 .ft-socials { flex-wrap: wrap; } }

/* ======================================================================
   Responsive pass 3 (phone / tablet / laptop / large screens)
   ====================================================================== */
/* Large desktop: use more of the screen */
@media (min-width: 1600px) {
  .container { max-width: 1400px; }
  .header-inner, .subnav-wrap { max-width: 1352px; }
  .subnav-wrap { width: min(1352px, calc(100% - 48px)); }
}
/* Scrollable pill bars fade at the edges instead of cutting off */
.subnav, .fx-bar { scroll-behavior: smooth; }
@media (max-width: 1100px) {
  .subnav { -webkit-mask-image: linear-gradient(90deg, transparent 0, #000 24px, #000 calc(100% - 36px), transparent); mask-image: linear-gradient(90deg, transparent 0, #000 24px, #000 calc(100% - 36px), transparent); }
}
/* Tablet */
@media (min-width: 721px) and (max-width: 1024px) {
  .qr-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
  .qr-card { padding: 16px; gap: 14px; }
  .qr-head { gap: 10px; }
  .qr-brand { width: 38px; height: 38px; }
  .qr-id b { font-size: 15px; }
  .qr-scan { display: none; }
  .qr-frame { padding: 12px; border-radius: 20px; }
  .qr-cta { height: 44px; font-size: 11.5px; padding-left: 14px; }
  .qr-cta i { width: 32px; height: 32px; }
  .fx-bar { flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; border-radius: 999px; -webkit-mask-image: linear-gradient(90deg, #000 calc(100% - 36px), transparent); mask-image: linear-gradient(90deg, #000 calc(100% - 36px), transparent); }
  .fx-bar::-webkit-scrollbar { display: none; }
  .fx-bar .fx-filter { flex: 0 0 auto; }
  .feat-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 720px) {
  .fx-bar { -webkit-mask-image: linear-gradient(90deg, #000 calc(100% - 30px), transparent); mask-image: linear-gradient(90deg, #000 calc(100% - 30px), transparent); }
}
/* Small phones: keep the name prominent */
@media (max-width: 360px) {
  .p-hero h1 .name { font-size: 32px; }
}
@media (min-width: 721px) and (max-width: 1024px) { .qr-cta { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; letter-spacing: 0.03em; font-size: 11px; } }
/* Mobile header: search button sits beside the switch, not centred */
@media (max-width: 1100px) { .header .icon-btn { margin-left: auto !important; } .header .switch3 { margin-left: 0 !important; } .header-inner { gap: 8px; } }
@media (max-width: 720px) {
  .ft-links { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; width: 100%; padding: 0; background: none; border: 0; border-radius: 0; }
  .ft-links a { display: flex; align-items: center; justify-content: center; height: 44px; padding: 0 12px; border-radius: 999px; font-size: 13.5px; color: #d4d4dc; background: rgba(255, 255, 255, 0.04); border: 1px solid var(--border-strong); }
  .ft-links a:last-child:nth-child(odd) { grid-column: 1 / -1; }
}

/* ---------- Mobile header: always one row (search row only when opened) ---------- */
@media (max-width: 720px) {
  .header-inner { flex-wrap: nowrap; align-items: center; min-height: 62px; padding: 8px 8px 8px 8px; gap: 8px; }
  .header.search-open .header-inner { flex-wrap: wrap; }
  .brand { min-width: 0; flex-shrink: 1; }
  .brand > span:not(.brand-mark) { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
  .brand small { display: none; }
  .header .icon-btn { width: 44px; height: 44px; flex-shrink: 0; }
  .header .switch3 { flex-shrink: 0; }
}

/* ---------- Tablet/phone timeline: glowing rail + flowing light (matches role rail) ---------- */
@media (max-width: 1024px) {
  .timeline::before {
    width: 2px; border-radius: 2px;
    background: linear-gradient(#60a5fa, rgb(var(--tl)) 55%, rgba(var(--tl), 0.15));
    box-shadow: 0 0 12px rgba(96, 165, 250, 0.55);
  }
  .timeline::after {
    content: ""; position: absolute; top: 28px; width: 4px; height: 60px; border-radius: 4px;
    left: 18px; background: linear-gradient(transparent, #fff, transparent); opacity: 0;
    animation: tlFlow 3.2s ease-in-out infinite; pointer-events: none;
  }
  @keyframes tlFlow { 0% { top: 28px; opacity: 0; } 12% { opacity: 0.9; } 88% { opacity: 0.9; } 100% { top: calc(100% - 90px); opacity: 0; } }
  .tl-dot {
    background: linear-gradient(135deg, #3b82f6, #8b5cf6);
    border: 2px solid rgba(255, 255, 255, 0.9);
    box-shadow: 0 0 0 4px var(--bg), 0 0 0 6px rgba(96, 165, 250, 0.35), 0 0 22px rgba(96, 165, 250, 0.7);
  }
  .timeline > .tl-item:first-child .tl-dot::after { inset: -8px; border-color: rgba(96, 165, 250, 0.7); }
}
@media (max-width: 720px) {
  .timeline::after { left: 14px; }
}
@media (prefers-reduced-motion: reduce) { .timeline::after { animation: none; display: none; } }
/* Rail ends at the last marker */
@media (max-width: 1024px) {
  .timeline::before { top: var(--tl-top, 28px); bottom: auto; height: var(--tl-h, calc(100% - 56px)); }
  .timeline::after { animation-name: tlFlow2; }
  @keyframes tlFlow2 { 0% { top: var(--tl-top, 28px); opacity: 0; } 12% { opacity: 0.9; } 88% { opacity: 0.9; } 100% { top: calc(var(--tl-top, 28px) + var(--tl-h, 300px) - 60px); opacity: 0; } }
}

/* ---------- Tablet (721–1024): app cards + pipeline span the full row ---------- */
@media (max-width: 1024px) {
  .works > .work.work-app, .works > .work.work-wide, .works > .pipe, .works > .apps-banner { grid-column: 1 / -1 !important; }
}
@media (min-width: 721px) and (max-width: 1024px) {
  /* full-width app card: banner left-aligned content, stores comfortably in one row */
  .pa .stores { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .pa .store { flex-direction: row; height: 54px; padding: 0 14px; gap: 10px; text-align: left; }
  .pa .store > span { align-items: flex-start; }
  .pa .store b { font-size: 14.5px; }
  .pipe { grid-template-columns: 1fr; }
  .pipe-apps { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
/* Tablet: legal cards one per row; doc rows stay on one line */
@media (max-width: 1180px) {
  .legal-grid { grid-template-columns: minmax(0, 1fr) !important; }
}
.la-text b, .la-text small { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
/* Tablet footer: centred stack */
@media (min-width: 721px) and (max-width: 1024px) {
  .ft2 .ft-mid { align-items: center; }
  .ft2 .ft-row:first-child { justify-content: space-between; }
}
@media (min-width: 721px) and (max-width: 1024px) { .contact-side { grid-template-columns: 1fr 1fr; } .contact-side .map-card { grid-column: 1 / -1; min-height: 260px; } .contact-side .info2 { grid-column: 1 / -1; } .info-social { flex-direction: row; } }
@media (max-width: 720px) { .xp-promo { grid-column: 1 / -1; justify-self: stretch; justify-content: center; height: 34px; } }

/* Hero badges: role + location as two pills */
.p-badges { display: flex; flex-wrap: wrap; gap: 8px; }
.p-badges .badge { white-space: nowrap; }
.b-loc { color: #93c5fd; border-color: rgba(59, 130, 246, 0.4); background: rgba(59, 130, 246, 0.1); }
@media (max-width: 1024px) { .p-badges { justify-content: center; } }
@media (max-width: 720px) {
  .p-badges .badge { font-size: 10px; letter-spacing: 0.1em; padding: 7px 13px; }
}
@media (max-width: 360px) {
  .p-badges .badge { font-size: 9px; letter-spacing: 0.06em; padding: 6px 10px; }
}
@media (max-width: 720px) { .ar-tier:nth-of-type(n+2) .ar-nodes { grid-template-columns: 1fr; } .ar-node > span { white-space: nowrap; } }
/* 6-step grid: connector line only makes sense for a single row */
.steps:has(.step:nth-child(4))::before { display: none; }

/* Feature cards: large outlined step number (matches services/steps) */
.feat2 .feat-idx {
  top: 14px; right: 20px; padding: 0; border: 0; background: none; filter: none;
  font-size: 54px; font-weight: 900; letter-spacing: -0.05em; line-height: 1;
  color: transparent; -webkit-text-stroke: 1px rgba(var(--tone), 0.45);
  transition: -webkit-text-stroke-color 0.3s, transform 0.3s;
}
.feat2:hover .feat-idx { -webkit-text-stroke-color: rgba(var(--tone), 0.85); transform: translateY(-2px); }
@media (max-width: 720px) { .feat2 .feat-idx { font-size: 44px; top: 12px; right: 16px; } }
/* lone last chip in a 3-column row spans the row */
@media (min-width: 1025px) { .sk-chips li:last-child:nth-child(3n+1) { grid-column: 1 / -1; } }
/* Infra cards: 4 tags as an even 2x2 grid */
.infra .tags { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
.infra .tags span { text-align: center; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
/* Skill chips: last row always fills the full width (desktop 3-col layout) */
@media (min-width: 1025px) {
  .sk-chips { grid-template-columns: repeat(6, minmax(0, 1fr)); }
  .sk-chips li { grid-column: span 2; }
  .sk-chips li:last-child:nth-child(3n+1) { grid-column: 1 / -1; }
  .sk-chips li:nth-last-child(2):nth-child(3n+1),
  .sk-chips li:last-child:nth-child(3n+2) { grid-column: span 3; }
}
.edu-skills { margin-top: 14px; }
.timeline:not(.exp) .edu-skills .xp-chip { color: #ddd6fe; background: rgba(124, 58, 237, 0.1); border-color: rgba(139, 92, 246, 0.35); }

/* Background ticker: fill the whole viewport, edge to edge (no centre-only mask). */
.bg-ticker {
  inset: -30vh -30vw;
  justify-content: space-evenly; gap: 0;
  -webkit-mask-image: none; mask-image: none;
}
@media (max-width: 720px) { .bg-ticker { inset: -20vh -60vw; } }
