/* ==========================================================================
   voisep — VSEP: finance AI & data platform architecture site
   Plain CSS, custom properties, dark-first with a light theme.
   Asset paths are relative on purpose (site may be mounted under a prefix).
   ========================================================================== */

:root {
  --font-display: "Space Grotesk", "Inter", system-ui, sans-serif;
  --font-body: "Inter", system-ui, -apple-system, "Segoe UI", sans-serif;
  --font-mono: "JetBrains Mono", ui-monospace, SFMono-Regular, Menlo, monospace;

  --bg: #070b14;
  --bg-2: #0c1220;
  --surface: rgba(255, 255, 255, 0.04);
  --surface-2: rgba(255, 255, 255, 0.07);
  --border: rgba(255, 255, 255, 0.09);
  --border-strong: rgba(255, 255, 255, 0.18);
  --text: #e7ecf5;
  --text-2: #a9b4c8;
  --text-3: #6f7c94;
  --c1: #22d3ee; /* cyan */
  --c2: #8b5cf6; /* violet */
  --c3: #f472b6; /* pink */
  --ok: #34d399;
  --shadow: 0 20px 60px rgba(0, 0, 0, 0.45);
  --radius: 18px;
  --radius-sm: 12px;
  --wrap: 1160px;
  --ease: cubic-bezier(0.2, 0.7, 0.2, 1);
}

:root[data-theme="light"] {
  --bg: #f6f8fc;
  --bg-2: #ffffff;
  --surface: rgba(10, 20, 40, 0.035);
  --surface-2: rgba(10, 20, 40, 0.06);
  --border: rgba(10, 20, 40, 0.1);
  --border-strong: rgba(10, 20, 40, 0.2);
  --text: #0d1526;
  --text-2: #3f4b63;
  --text-3: #6f7c94;
  --c1: #0891b2;
  --c2: #6d28d9;
  --c3: #db2777;
  --ok: #059669;
  --shadow: 0 20px 60px rgba(20, 30, 60, 0.12);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 17px;
  line-height: 1.65;
  color: var(--text);
  background: var(--bg);
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

img, svg { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
p { margin: 0 0 1rem; }
h1, h2, h3, h4 { font-family: var(--font-display); line-height: 1.12; margin: 0 0 0.6em; letter-spacing: -0.01em; }
h1 { font-size: clamp(2.3rem, 5.2vw, 4.2rem); font-weight: 700; letter-spacing: -0.025em; }
h2 { font-size: clamp(1.8rem, 3.4vw, 2.7rem); font-weight: 700; letter-spacing: -0.02em; }
h3 { font-size: 1.25rem; font-weight: 600; }
h4 { font-size: 1.1rem; font-weight: 600; }
code { font-family: var(--font-mono); font-size: 0.9em; }
strong { font-weight: 600; color: var(--text); }

.wrap { width: min(var(--wrap), calc(100% - 2.5rem)); margin-inline: auto; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip { position: absolute; left: -999px; top: 8px; background: var(--c1); color: #000; padding: 0.5rem 1rem; border-radius: 8px; z-index: 100; }
.skip:focus { left: 8px; }

/* ---------- ambient background ---------- */
.bg { position: fixed; inset: 0; z-index: -1; overflow: hidden; pointer-events: none; }
.orb { position: absolute; border-radius: 50%; filter: blur(90px); opacity: 0.55; animation: drift 26s var(--ease) infinite alternate; }
.orb-a { width: 55vw; height: 55vw; left: -15vw; top: -20vw; background: radial-gradient(circle, var(--c2), transparent 65%); }
.orb-b { width: 45vw; height: 45vw; right: -12vw; top: 10vh; background: radial-gradient(circle, var(--c1), transparent 65%); animation-delay: -8s; animation-duration: 32s; }
.orb-c { width: 40vw; height: 40vw; left: 30vw; bottom: -25vw; background: radial-gradient(circle, var(--c3), transparent 65%); animation-delay: -16s; animation-duration: 38s; opacity: 0.35; }
:root[data-theme="light"] .orb { opacity: 0.28; }
@keyframes drift {
  from { transform: translate3d(0, 0, 0) scale(1); }
  to { transform: translate3d(6vw, 5vh, 0) scale(1.12); }
}
.grid {
  position: absolute; inset: 0;
  background-image:
    linear-gradient(var(--border) 1px, transparent 1px),
    linear-gradient(90deg, var(--border) 1px, transparent 1px);
  background-size: 64px 64px;
  mask-image: radial-gradient(ellipse 70% 60% at 50% 0%, #000 30%, transparent 80%);
  -webkit-mask-image: radial-gradient(ellipse 70% 60% at 50% 0%, #000 30%, transparent 80%);
  opacity: 0.7;
}
.noise {
  position: absolute; inset: 0; opacity: 0.06; mix-blend-mode: overlay;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='160' height='160'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='2' stitchTiles='stitch'/></filter><rect width='100%' height='100%' filter='url(%23n)'/></svg>");
}

/* ---------- scroll progress ---------- */
.progress { position: fixed; top: 0; left: 0; right: 0; height: 2px; z-index: 60; background: transparent; }
.progress span { display: block; height: 100%; width: 0; background: linear-gradient(90deg, var(--c1), var(--c2), var(--c3)); transition: width 0.1s linear; }

/* ---------- header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 50;
  backdrop-filter: saturate(160%) blur(14px);
  -webkit-backdrop-filter: saturate(160%) blur(14px);
  background: color-mix(in srgb, var(--bg) 70%, transparent);
  border-bottom: 1px solid transparent;
  transition: border-color 0.3s, background 0.3s;
}
.site-header.scrolled { border-bottom-color: var(--border); }
.nav-row { display: flex; align-items: center; gap: 1rem; height: 68px; }
.brand { display: inline-flex; align-items: center; gap: 0.65rem; font-family: var(--font-display); font-weight: 600; }
.brand-mark {
  display: grid; place-items: center; width: 36px; height: 36px; border-radius: 10px;
  /* inline glyph */
  font-size: 0.85rem; font-weight: 700; color: #04101a;
  background: linear-gradient(135deg, var(--c1), var(--c2));
  box-shadow: 0 6px 20px color-mix(in srgb, var(--c2) 40%, transparent);
}
.nav { margin-left: auto; }
.nav-links { list-style: none; margin: 0; padding: 0; display: flex; gap: 0.25rem; align-items: center; }
.nav-links a {
  display: inline-block; padding: 0.45rem 0.8rem; border-radius: 999px;
  font-size: 0.95rem; color: var(--text-2); transition: color 0.2s, background 0.2s;
}
.nav-links a:hover, .nav-links a.active { color: var(--text); background: var(--surface-2); }
.nav-links a.nav-cta { color: var(--text); border: 1px solid var(--border-strong); }
.nav-links a.nav-cta:hover { border-color: var(--c1); }
.nav-toggle { display: none; }

.theme-toggle {
  width: 40px; height: 40px; border-radius: 50%; border: 1px solid var(--border); background: var(--surface);
  color: var(--text-2); cursor: pointer; display: grid; place-items: center; transition: border-color 0.2s, color 0.2s, transform 0.3s;
}
.theme-toggle:hover { color: var(--text); border-color: var(--border-strong); transform: rotate(15deg); }
.theme-toggle svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
:root[data-theme="dark"] .icon-moon, :root[data-theme="light"] .icon-sun { display: none; }

/* ---------- buttons ---------- */
.btn {
  display: inline-flex; align-items: center; gap: 0.5rem;
  padding: 0.8rem 1.35rem; border-radius: 999px; font-weight: 600; font-size: 0.98rem;
  border: 1px solid var(--border-strong); color: var(--text); background: var(--surface);
  cursor: pointer; transition: transform 0.25s var(--ease), box-shadow 0.25s, border-color 0.2s, background 0.2s;
  font-family: var(--font-body);
}
.btn:hover { transform: translateY(-2px); border-color: var(--c1); }
.btn-primary {
  border: none; color: #04101a;
  background: linear-gradient(135deg, var(--c1), var(--c2));
  box-shadow: 0 10px 30px color-mix(in srgb, var(--c2) 35%, transparent);
}
.btn-primary:hover { box-shadow: 0 14px 40px color-mix(in srgb, var(--c1) 45%, transparent); }
:root[data-theme="light"] .btn-primary { color: #fff; }
.btn-ghost { background: transparent; }
.btn-icon { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }

/* ---------- type helpers ---------- */
.kicker {
  display: inline-block; font-family: var(--font-mono); font-size: 0.78rem; letter-spacing: 0.14em; text-transform: uppercase;
  color: var(--c1); margin-bottom: 0.8rem;
}
.kicker::before { content: "// "; color: var(--text-3); }
.lede { font-size: 1.15rem; color: var(--text-2); max-width: 62ch; }
.grad { background: linear-gradient(90deg, var(--c1), var(--c2)); -webkit-background-clip: text; background-clip: text; color: transparent; }
.grad-b { background: linear-gradient(90deg, var(--c2), var(--c3)); -webkit-background-clip: text; background-clip: text; color: transparent; }
.eyebrow { display: inline-flex; align-items: center; gap: 0.6rem; font-family: var(--font-mono); font-size: 0.82rem; color: var(--text-2); padding: 0.4rem 0.9rem; border: 1px solid var(--border); border-radius: 999px; background: var(--surface); }
.pulse { width: 8px; height: 8px; border-radius: 50%; background: var(--ok); box-shadow: 0 0 0 0 color-mix(in srgb, var(--ok) 60%, transparent); animation: pulse 2s infinite; }
@keyframes pulse { 0% { box-shadow: 0 0 0 0 color-mix(in srgb, var(--ok) 55%, transparent); } 70% { box-shadow: 0 0 0 10px transparent; } 100% { box-shadow: 0 0 0 0 transparent; } }

/* ---------- sections ---------- */
.section { padding: clamp(4rem, 9vw, 7.5rem) 0; }
section[id], [id] { scroll-margin-top: 84px; } /* sticky header is 68px */
.section-head { max-width: 780px; margin-bottom: clamp(2rem, 5vw, 3.5rem); }
.section-head .lede { margin-bottom: 0; }

/* ---------- reveal on scroll ---------- */
.reveal { opacity: 0; transform: translateY(22px); transition: opacity 0.8s var(--ease), transform 0.8s var(--ease); }
.reveal.in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) { .reveal { opacity: 1; transform: none; transition: none; } }

/* ---------- hero ---------- */
.hero {
  display: grid; grid-template-columns: 1.1fr 0.9fr; gap: clamp(2rem, 5vw, 4rem); align-items: center;
  min-height: calc(100vh - 68px); padding: clamp(3rem, 8vw, 6rem) 0 3rem;
}
.hero-copy .lede { margin: 1.4rem 0 2rem; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 0.8rem; margin-bottom: 2.4rem; }
.hero-facts { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(4, 1fr); gap: 1rem; max-width: 620px; }
.hero-facts li { display: flex; flex-direction: column; gap: 0.1rem; padding-left: 0.9rem; border-left: 2px solid var(--border-strong); }
.hero-facts strong { font-family: var(--font-display); font-size: 1.05rem; }
.hero-facts span { font-size: 0.82rem; color: var(--text-3); line-height: 1.3; }

.art-card {
  border: 1px solid var(--border); border-radius: var(--radius); background: color-mix(in srgb, var(--bg-2) 75%, transparent);
  box-shadow: var(--shadow); overflow: hidden; backdrop-filter: blur(10px);
  transform: perspective(1200px) rotateY(-6deg) rotateX(3deg);
  transition: transform 0.8s var(--ease);
}
.art-card:hover { transform: perspective(1200px) rotateY(0) rotateX(0); }
.art-head { display: flex; align-items: center; gap: 0.45rem; padding: 0.7rem 1rem; border-bottom: 1px solid var(--border); }
.art-head .dot { width: 10px; height: 10px; border-radius: 50%; }
.dot.r { background: #ff5f57; } .dot.y { background: #febc2e; } .dot.g { background: #28c840; }
.art-title { margin-left: auto; font-family: var(--font-mono); font-size: 0.75rem; color: var(--text-3); }
.art-foot { padding: 0.7rem 1rem; border-top: 1px solid var(--border); font-size: 0.78rem; color: var(--text-3); }
.art-foot .ok { color: var(--ok); }
.pipeline { width: 100%; height: auto; padding: 0.6rem; }
.pipeline .node rect { fill: var(--surface-2); stroke: var(--border-strong); stroke-width: 1; }
.pipeline .node.hub rect { fill: color-mix(in srgb, var(--c2) 18%, transparent); stroke: var(--c2); }
.pipeline .node text { fill: var(--text); font-family: var(--font-mono); font-size: 13px; text-anchor: middle; font-weight: 500; }
.pipeline .node text.sub { fill: var(--text-3); font-size: 10px; }
.pipeline .node { opacity: 0; animation: nodein 0.6s var(--ease) forwards; animation-delay: var(--d); }
@keyframes nodein { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }
.pipeline .edge { stroke: var(--border-strong); stroke-width: 1.5; stroke-dasharray: 4 4; }
.pipeline .packet { fill: var(--c1); filter: drop-shadow(0 0 6px var(--c1)); }
.pipeline .packet.b { fill: var(--c3); filter: drop-shadow(0 0 6px var(--c3)); }

/* ---------- ticker ---------- */
.ticker { overflow: hidden; border-block: 1px solid var(--border); padding: 0.9rem 0; margin-top: 1rem;
  mask-image: linear-gradient(90deg, transparent, #000 10%, #000 90%, transparent);
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 10%, #000 90%, transparent); }
.ticker-track { display: flex; gap: 2.5rem; width: max-content; animation: ticker 40s linear infinite; }
.ticker:hover .ticker-track { animation-play-state: paused; }
.ticker-track span { font-family: var(--font-mono); font-size: 0.85rem; color: var(--text-3); white-space: nowrap; }
.ticker-track span::before { content: "◆"; color: var(--c2); margin-right: 0.8rem; font-size: 0.6rem; vertical-align: middle; }
@keyframes ticker { to { transform: translateX(-50%); } }

/* ---------- about ---------- */
.about { display: grid; grid-template-columns: 320px 1fr; gap: clamp(2rem, 5vw, 4.5rem); align-items: center; }
.about-photo { position: relative; }
.photo-ring {
  position: relative; border-radius: 50%; padding: 4px;
  background: conic-gradient(from 180deg, var(--c1), var(--c2), var(--c3), var(--c1));
  animation: spin 12s linear infinite;
}
.photo-ring img, .photo-glyph { border-radius: 50%; width: 100%; height: auto; aspect-ratio: 1; object-fit: cover; animation: spin 12s linear infinite reverse; background: var(--bg-2); }
.photo-glyph { display: grid; place-items: center; }
.photo-glyph svg { width: 62%; height: 62%; fill: none; stroke-width: 3; stroke-linejoin: round; stroke-linecap: round; }
.photo-glyph .g1 { stroke: var(--c1); fill: color-mix(in srgb, var(--c1) 18%, transparent); }
.photo-glyph .g2 { stroke: var(--c2); }
.photo-glyph .g3 { stroke: var(--c3); }
.photo-glyph .gd { fill: var(--c1); stroke: none; }
.brand-mark svg { width: 20px; height: 20px; fill: none; stroke: #04101a; stroke-width: 2; stroke-linejoin: round; }
@keyframes spin { to { transform: rotate(360deg); } }
@media (prefers-reduced-motion: reduce) { .photo-ring, .photo-ring img, .photo-glyph { animation: none; } }
.photo-badge {
  display: inline-flex; align-items: center; gap: 0.4rem;
  position: absolute; right: -10px; bottom: 18px; padding: 0.45rem 0.8rem; border-radius: 999px; font-size: 0.85rem;
  background: var(--bg-2); border: 1px solid var(--border-strong); box-shadow: var(--shadow);
}
.about-text h2 { max-width: 18ch; }
.about-text p { color: var(--text-2); }
.about-principles { list-style: none; margin: 1.5rem 0 0; padding: 0; display: grid; grid-template-columns: repeat(2, 1fr); gap: 0.6rem 1.2rem; }
.about-principles li { padding: 0.7rem 0.9rem; border: 1px solid var(--border); border-radius: var(--radius-sm); background: var(--surface); color: var(--text-2); font-size: 0.95rem; }

/* ---------- cards ---------- */
.cards { display: grid; gap: 1.2rem; }
.services-grid { grid-template-columns: repeat(2, 1fr); }
.lab-grid { grid-template-columns: repeat(4, 1fr); }
.card {
  position: relative; padding: 1.7rem; border-radius: var(--radius); border: 1px solid var(--border); background: var(--surface);
  overflow: hidden; transition: transform 0.35s var(--ease), border-color 0.3s, background 0.3s;
}
.card::before {
  content: ""; position: absolute; inset: 0; pointer-events: none; opacity: 0; transition: opacity 0.35s;
  background: radial-gradient(600px circle at var(--mx, 50%) var(--my, 50%), color-mix(in srgb, var(--c1) 12%, transparent), transparent 40%);
}
.card:hover { transform: translateY(-4px); border-color: var(--border-strong); }
.card:hover::before { opacity: 1; }
.card p { color: var(--text-2); font-size: 0.98rem; }
.card a { color: var(--c1); text-decoration: underline; text-underline-offset: 3px; }
.card-icon { width: 46px; height: 46px; border-radius: 12px; display: grid; place-items: center; margin-bottom: 1.1rem; background: linear-gradient(135deg, color-mix(in srgb, var(--c1) 25%, transparent), color-mix(in srgb, var(--c2) 25%, transparent)); border: 1px solid var(--border); }
.card-icon svg { width: 22px; height: 22px; fill: none; stroke: var(--c1); stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
.ticks { list-style: none; margin: 0.9rem 0 0; padding: 0; display: grid; gap: 0.4rem; }
.ticks li { position: relative; padding-left: 1.5rem; color: var(--text-2); font-size: 0.93rem; }
.ticks li::before { content: "✓"; position: absolute; left: 0; color: var(--ok); font-weight: 700; }
.card.mini { padding: 1.4rem; }
.card.mini h3 { margin-top: 0.7rem; }
.tag { display: inline-block; font-family: var(--font-mono); font-size: 0.7rem; letter-spacing: 0.1em; text-transform: uppercase; color: var(--c2); padding: 0.25rem 0.55rem; border: 1px solid color-mix(in srgb, var(--c2) 40%, transparent); border-radius: 6px; }

/* ---------- pricing ---------- */
.pricing {
  margin-top: 1.8rem; display: grid; grid-template-columns: auto 1fr auto; gap: 1.5rem; align-items: center;
  padding: 1.4rem 1.8rem; border-radius: var(--radius); border: 1px solid var(--border);
  background: linear-gradient(120deg, color-mix(in srgb, var(--c2) 10%, var(--surface)), color-mix(in srgb, var(--c1) 8%, var(--surface)));
}
.price { display: flex; align-items: baseline; gap: 0.3rem; font-family: var(--font-display); }
.price-num { font-size: 2.4rem; font-weight: 700; letter-spacing: -0.02em; }
.price-unit { color: var(--text-3); }
.price-text { color: var(--text-2); }

/* ---------- architecture diagram ---------- */
.arch { display: grid; gap: 0.7rem; padding: 1.4rem; border-radius: var(--radius); border: 1px solid var(--border); background: var(--surface); }
.arch-layer {
  display: grid; grid-template-columns: 170px 1fr; gap: 1rem; align-items: center; padding: 0.9rem 1.1rem;
  border-radius: var(--radius-sm); border: 1px solid var(--border); background: var(--bg-2);
  opacity: 0; transform: translateX(-10px); animation: layerin 0.6s var(--ease) forwards; animation-delay: calc(var(--i) * 0.12s + 0.2s);
  animation-play-state: paused;
}
.arch.in .arch-layer { animation-play-state: running; }
@keyframes layerin { to { opacity: 1; transform: none; } }
.arch-layer.hub { border-color: color-mix(in srgb, var(--c2) 55%, transparent); background: color-mix(in srgb, var(--c2) 12%, var(--bg-2)); }
.arch-label { font-family: var(--font-display); font-weight: 600; display: flex; align-items: center; gap: 0.7rem; }
.arch-label .num { font-family: var(--font-mono); font-size: 0.75rem; color: var(--c1); font-weight: 500; }
.arch-items { display: flex; flex-wrap: wrap; gap: 0.45rem; }
.arch-items span { font-size: 0.85rem; color: var(--text-2); padding: 0.3rem 0.65rem; border-radius: 999px; border: 1px solid var(--border); background: var(--surface); }
.arch-cross { display: grid; grid-template-columns: repeat(4, 1fr); gap: 0.6rem; margin-top: 0.3rem; }
.arch-cross span { display: inline-flex; align-items: center; justify-content: center; gap: 0.5rem; font-size: 0.85rem; color: var(--text-2); padding: 0.6rem 0.8rem; text-align: center; border-radius: var(--radius-sm); border: 1px dashed var(--border-strong); }
.arch-cross svg, .photo-badge svg { width: 16px; height: 16px; flex: none; fill: none; stroke: var(--c1); stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }

.principles { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1.2rem; margin-top: 2.2rem; }
.principle { padding: 1.2rem 1.3rem; border-left: 2px solid var(--border-strong); }
.principle:hover { border-left-color: var(--c1); }
.p-num { font-family: var(--font-mono); color: var(--c1); font-size: 0.8rem; }
.principle h3 { margin-top: 0.4rem; font-size: 1.1rem; }
.principle p { color: var(--text-2); font-size: 0.93rem; margin: 0; }

.steps { list-style: none; counter-reset: step; margin: 2.5rem 0 0; padding: 0; display: grid; grid-template-columns: repeat(4, 1fr); gap: 0; position: relative; }
.steps::before { content: ""; position: absolute; left: 5%; right: 5%; top: 17px; height: 1px; background: linear-gradient(90deg, var(--c1), var(--c2), var(--c3)); opacity: 0.6; }
.steps li { position: relative; text-align: center; padding-top: 3rem; }
.steps li::before {
  counter-increment: step; content: counter(step);
  position: absolute; top: 0; left: 50%; transform: translateX(-50%);
  width: 34px; height: 34px; border-radius: 50%; display: grid; place-items: center;
  font-family: var(--font-mono); font-size: 0.8rem; font-weight: 600; color: #04101a;
  background: linear-gradient(135deg, var(--c1), var(--c2)); box-shadow: 0 0 0 6px var(--bg);
}
.steps strong { display: block; font-family: var(--font-display); }
.steps span { display: block; font-size: 0.85rem; color: var(--text-3); max-width: 22ch; margin-inline: auto; }

/* ---------- CV ---------- */
.cv-head { display: flex; align-items: end; justify-content: space-between; gap: 1rem; max-width: none; }
.cv-grid { display: grid; grid-template-columns: 1.5fr 1fr; gap: clamp(1.5rem, 4vw, 3.5rem); align-items: start; }
.cv-h { font-family: var(--font-mono); font-size: 0.8rem; letter-spacing: 0.14em; text-transform: uppercase; color: var(--text-3); margin: 2rem 0 1.2rem; }
.cv-h:first-child { margin-top: 0; }
.timeline { list-style: none; margin: 0; padding: 0; position: relative; }
.timeline::before { content: ""; position: absolute; left: 118px; top: 6px; bottom: 6px; width: 1px; background: var(--border-strong); }
.timeline li { display: grid; grid-template-columns: 100px 1fr; gap: 2.4rem; padding-bottom: 1.8rem; position: relative; }
.timeline li::after {
  content: ""; position: absolute; left: 113px; top: 8px; width: 11px; height: 11px; border-radius: 50%;
  background: var(--bg); border: 2px solid var(--c1); box-shadow: 0 0 0 4px var(--bg);
}
.tl-when { font-family: var(--font-mono); font-size: 0.8rem; color: var(--text-3); padding-top: 0.25rem; text-align: right; }
.tl-body h4 { margin-bottom: 0.15rem; }
.tl-org { color: var(--c1); font-size: 0.9rem; margin-bottom: 0.5rem; }
.tl-body p:last-child { color: var(--text-2); font-size: 0.95rem; margin: 0; }
.side-card { padding: 1.3rem 1.4rem; border-radius: var(--radius); border: 1px solid var(--border); background: var(--surface); margin-bottom: 1rem; }
.side-card h3 { font-size: 0.8rem; font-family: var(--font-mono); letter-spacing: 0.12em; text-transform: uppercase; color: var(--text-3); margin-bottom: 1rem; }
.skill-bars { display: grid; gap: 0.75rem; }
.skill { display: grid; gap: 0.3rem; font-size: 0.9rem; }
.skill i { display: block; height: 6px; border-radius: 999px; background: var(--surface-2); position: relative; overflow: hidden; }
.skill i::after { content: ""; position: absolute; inset: 0; width: 0; border-radius: 999px; background: linear-gradient(90deg, var(--c1), var(--c2)); transition: width 1.2s var(--ease); }
.in .skill i::after { width: var(--w); }
.chips { display: flex; flex-wrap: wrap; gap: 0.45rem; }
.chips span { font-size: 0.85rem; padding: 0.35rem 0.7rem; border-radius: 999px; border: 1px solid var(--border); background: var(--bg-2); color: var(--text-2); }
.links { display: grid; gap: 0.6rem; }
.side-card .links a { color: var(--text); font-weight: 500; }
.side-card .links a:hover { color: var(--c1); }

/* ---------- contact ---------- */
.contact { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(2rem, 5vw, 4rem); align-items: start; }
.link-card { display: flex; align-items: center; gap: 1rem; padding: 0.9rem 1.1rem; border-radius: var(--radius-sm); border: 1px solid var(--border); background: var(--surface); transition: border-color 0.2s, transform 0.3s var(--ease); }
.link-card:hover { border-color: var(--c1); transform: translateX(4px); }
.link-card small { display: block; color: var(--text-3); font-size: 0.82rem; }
.link-icon { width: 40px; height: 40px; border-radius: 10px; display: grid; place-items: center; background: var(--surface-2); color: var(--text); }
.link-icon svg { width: 18px; height: 18px; }
.contact-form { padding: 1.6rem; border-radius: var(--radius); border: 1px solid var(--border); background: color-mix(in srgb, var(--bg-2) 70%, transparent); box-shadow: var(--shadow); display: grid; gap: 1rem; }
.field { display: grid; gap: 0.35rem; }
.field label { font-size: 0.85rem; color: var(--text-2); }
.field input, .field select, .field textarea {
  width: 100%; padding: 0.8rem 0.95rem; border-radius: 10px; border: 1px solid var(--border-strong); background: var(--surface);
  color: var(--text); font: inherit; font-size: 0.97rem; transition: border-color 0.2s, box-shadow 0.2s;
}
.field textarea { resize: vertical; min-height: 120px; }
.field input:focus, .field select:focus, .field textarea:focus { outline: none; border-color: var(--c1); box-shadow: 0 0 0 4px color-mix(in srgb, var(--c1) 20%, transparent); }
.field select option { color: #000; }
.hp { position: absolute; left: -9999px; }
.form-status { margin: 0; font-size: 0.9rem; color: var(--text-2); min-height: 1.2em; }
.form-status.ok { color: var(--ok); }
.form-status.err { color: var(--c3); }

/* ---------- footer ---------- */
.site-footer { border-top: 1px solid var(--border); padding: 1.6rem 0; font-size: 0.9rem; color: var(--text-3); }
.foot-row { display: flex; justify-content: space-between; gap: 1rem; flex-wrap: wrap; }
.foot-row p { margin: 0; }
.foot-links a:hover { color: var(--text); }

/* ---------- responsive ---------- */
@media (max-width: 1000px) {
  .services-grid { grid-template-columns: 1fr 1fr; }
  .lab-grid { grid-template-columns: 1fr 1fr; }
  .principles { grid-template-columns: 1fr 1fr; }
  .arch-cross { grid-template-columns: 1fr 1fr; }
  .steps { grid-template-columns: 1fr 1fr; gap: 1.5rem 0; }
  .steps::before { display: none; }
  .cv-grid { grid-template-columns: 1fr; }
}
@media (max-width: 820px) {
  .hero { grid-template-columns: 1fr; min-height: 0; padding-top: 3rem; }
  .hero-art { max-width: 560px; }
  .art-card { transform: none; }
  .hero-facts { grid-template-columns: 1fr 1fr; }
  .about { grid-template-columns: 1fr; }
  .about-photo { max-width: 260px; }
  .contact { grid-template-columns: 1fr; }
  .pricing { grid-template-columns: 1fr; text-align: center; justify-items: center; }
  .arch-layer { grid-template-columns: 1fr; gap: 0.6rem; }
  .cv-head { flex-direction: column; align-items: start; }

  .nav-toggle {
    display: inline-grid; gap: 5px; width: 40px; height: 40px; place-content: center; border-radius: 50%;
    border: 1px solid var(--border); background: var(--surface); cursor: pointer; color: var(--text);
  }
  .nav-toggle span { display: block; width: 18px; height: 2px; background: currentColor; border-radius: 2px; transition: transform 0.3s, opacity 0.3s; }
  .nav-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
  .nav-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
  .nav-toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }
  .nav-links {
    position: absolute; left: 0; right: 0; top: 68px; flex-direction: column; align-items: stretch; gap: 0.2rem;
    padding: 0.8rem 1.25rem 1.2rem; background: var(--bg-2); border-bottom: 1px solid var(--border); box-shadow: var(--shadow);
    transform: translateY(-10px); opacity: 0; pointer-events: none; transition: transform 0.3s var(--ease), opacity 0.3s;
  }
  .nav-links.open { transform: none; opacity: 1; pointer-events: auto; }
  .nav-links a { display: block; padding: 0.8rem 0.9rem; font-size: 1.05rem; }
}
@media (max-width: 560px) {
  body { font-size: 16px; }
  .services-grid, .lab-grid, .principles, .arch-cross, .steps { grid-template-columns: 1fr; }
  .timeline::before { left: 0; }
  .timeline li { grid-template-columns: 1fr; gap: 0.2rem; padding-left: 1.4rem; }
  .timeline li::after { left: -5px; }
  .tl-when { text-align: left; }
  .brand-text { display: none; }
  .about-principles { grid-template-columns: 1fr; }
}

/* ---------- print: the CV, and only the CV ---------- */
@media print {
  .bg, .progress, .site-header, .hero, .ticker, #about, #services, #platforms, #lab, #contact, .site-footer, #print-cv, .skill i { display: none !important; }
  body { background: #fff; color: #000; font-size: 11pt; }
  .reveal { opacity: 1 !important; transform: none !important; }
  .section { padding: 0; }
  .cv-grid { grid-template-columns: 1.6fr 1fr; gap: 1.5rem; }
  .timeline::before, .timeline li::after { display: none; }
  .timeline li { grid-template-columns: 90px 1fr; gap: 1rem; padding-bottom: 0.8rem; }
  .side-card, .chips span { border-color: #ccc; background: #fff; }
  .tl-org, .kicker { color: #333; }
  .kicker::before { content: ""; }
  h2::after { content: " — VSEP"; font-weight: 500; }
}
