/* ==========================================================================
   Visual Art Solutions | by Nirvana Vision
   ========================================================================== */

:root {
  --bg: #050505;
  --fg: #f1ece2;
  --accent: #ff4a1c;
  --muted: rgba(241, 236, 226, .56);
  --line: rgba(241, 236, 226, .14);
  --panel: #0e0d0c;
  --panel-2: #161412;
  --gutter: clamp(16px, 4vw, 56px);
  --max: 1440px;
  --font-display: "Anton", "Impact", "Arial Narrow", sans-serif;
  --font-body: "Inter", system-ui, -apple-system, "Segoe UI", sans-serif;
  --font-mono: "JetBrains Mono", ui-monospace, "SFMono-Regular", Menlo, monospace;
  --ease: cubic-bezier(.16, 1, .3, 1);
  color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--fg);
  font-family: var(--font-body);
  font-size: clamp(16px, 1.05vw, 18px);
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
img, svg, canvas { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; background: none; border: 0; cursor: pointer; }
::selection { background: var(--accent); color: var(--bg); }

.mono { font-family: var(--font-mono); text-transform: uppercase; letter-spacing: .08em; font-size: .75rem; }
.display { font-family: var(--font-display); font-weight: 400; text-transform: uppercase; line-height: .9; letter-spacing: -.005em; }
.eyebrow { color: var(--muted); margin: 0 0 1.5rem; display: flex; align-items: center; gap: .75rem; }
.eyebrow::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: var(--accent); }

.skip-link {
  position: fixed; top: 8px; left: 8px; z-index: 1000; padding: .6rem 1rem;
  background: var(--accent); color: var(--bg); transform: translateY(-200%);
}
.skip-link:focus { transform: none; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }

/* ---------- Loading state ---------- */
body.is-loading main, body.is-loading .site-header { opacity: 0; }
main, .site-header { transition: opacity .6s var(--ease); }

/* ---------- Header ---------- */
.site-header {
  position: fixed; inset: 0 0 auto 0; z-index: 50;
  display: flex; align-items: center; justify-content: space-between;
  padding: 20px var(--gutter);
  mix-blend-mode: difference;
}
.logo { font-family: var(--font-display); font-size: 28px; letter-spacing: .02em; line-height: 1; }
.nav-inline { display: flex; gap: 2rem; }
.nav-inline a { font-family: var(--font-mono); font-size: .75rem; text-transform: uppercase; letter-spacing: .08em; position: relative; }
.nav-inline a::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: -4px; height: 1px; background: currentColor;
  transform: scaleX(0); transform-origin: right; transition: transform .5s var(--ease);
}
.nav-inline a:hover::after { transform: scaleX(1); transform-origin: left; }
.menu-toggle { display: none; align-items: center; gap: .75rem; font-family: var(--font-mono); font-size: .75rem; letter-spacing: .08em; text-transform: uppercase; }
.menu-toggle__lines { display: grid; gap: 5px; width: 22px; }
.menu-toggle__lines i { display: block; height: 1.5px; background: currentColor; transition: transform .5s var(--ease); }
.menu-open .menu-toggle__lines i:first-child { transform: translateY(3.25px) rotate(45deg); }
.menu-open .menu-toggle__lines i:last-child { transform: translateY(-3.25px) rotate(-45deg); }

.menu-overlay {
  position: fixed; inset: 0; z-index: 40; background: var(--bg);
  display: flex; flex-direction: column; justify-content: space-between;
  padding: 110px var(--gutter) 32px;
  clip-path: inset(0 0 100% 0); transition: clip-path .8s var(--ease);
  pointer-events: none;
}
.menu-open .menu-overlay { clip-path: inset(0 0 0 0); pointer-events: auto; }
.menu-overlay__nav { display: grid; gap: .25rem; }
.menu-overlay__nav a {
  font-family: var(--font-display); text-transform: uppercase; font-size: clamp(3rem, 14vw, 7rem); line-height: .95;
  display: flex; align-items: baseline; gap: 1rem; transform: translateY(40px); opacity: 0;
  transition: transform .8s var(--ease), opacity .8s var(--ease), color .3s;
}
.menu-overlay__nav a small { font-family: var(--font-mono); font-size: .75rem; color: var(--accent); }
.menu-overlay__nav a:hover { color: var(--accent); }
.menu-open .menu-overlay__nav a { transform: none; opacity: 1; }
.menu-overlay__foot { display: flex; justify-content: space-between; flex-wrap: wrap; gap: 1rem; color: var(--muted); }

/* ---------- Cursor ---------- */
.cursor { position: fixed; top: 0; left: 0; z-index: 999; pointer-events: none; mix-blend-mode: difference; }
.cursor span {
  display: block; width: 10px; height: 10px; margin: -5px 0 0 -5px; border-radius: 50%; background: var(--fg);
  transition: width .35s var(--ease), height .35s var(--ease), margin .35s var(--ease);
}
.cursor.is-hover span { width: 56px; height: 56px; margin: -28px 0 0 -28px; }
@media (hover: none), (pointer: coarse) { .cursor { display: none; } }

/* ---------- Thread ---------- */
.thread { position: absolute; top: 0; left: 0; width: 100%; pointer-events: none; z-index: 0; overflow: visible; }
.thread path { fill: none; stroke-linecap: round; stroke-linejoin: round; }
.thread__ghost { stroke: var(--line); stroke-width: 1; stroke-dasharray: 2 8; }
.thread__line { stroke: var(--accent); stroke-width: 2; }
.thread__tip { fill: var(--accent); filter: drop-shadow(0 0 10px var(--accent)); }

main, .site-footer { position: relative; z-index: 1; }
section { padding: clamp(80px, 14vh, 180px) var(--gutter); max-width: var(--max); margin: 0 auto; }

/* ---------- Split text ---------- */
[data-split] .w { display: inline-block; overflow: hidden; vertical-align: top; padding-bottom: .04em; }
[data-split] .w > span { display: inline-block; transform: translateY(105%); transition: transform 1.1s var(--ease); transition-delay: calc(var(--i) * 45ms); }
[data-split].is-in .w > span { transform: none; }
[data-split] .accent { color: var(--accent); }

[data-reveal] { opacity: 0; transform: translateY(28px); transition: opacity 1s var(--ease), transform 1s var(--ease); }
[data-reveal].is-in { opacity: 1; transform: none; }

/* ---------- Hero ---------- */
.hero { min-height: 100svh; display: flex; flex-direction: column; justify-content: flex-end; padding-top: 140px; padding-bottom: 48px; }
.hero__title { font-size: clamp(3.2rem, min(10.5vw, 17vh), 11.5rem); margin: 0; max-width: 15ch; }
.hero__bottom { display: flex; justify-content: space-between; align-items: flex-end; gap: 2rem; margin-top: clamp(2rem, 5vh, 4rem); flex-wrap: wrap; }
.hero__sub { max-width: 34rem; color: var(--muted); margin: 0; font-size: clamp(1rem, 1.3vw, 1.2rem); }
.hero__cta { display: flex; align-items: center; gap: 1rem; }
.hero__cta-line { width: 1px; height: 56px; background: var(--line); position: relative; overflow: hidden; }
.hero__cta-line::after {
  content: ""; position: absolute; left: 0; top: -40%; width: 100%; height: 40%; background: var(--accent);
  animation: drip 2s var(--ease) infinite;
}
@keyframes drip { to { top: 100%; } }

/* ---------- Intro ---------- */
.intro { display: grid; grid-template-columns: repeat(12, 1fr); gap: 2rem; }
.intro__heading { grid-column: 1 / span 7; font-family: var(--font-body); font-weight: 500; font-size: clamp(1.8rem, 3.6vw, 3.4rem); line-height: 1.08; letter-spacing: -.02em; margin: 0; }
.intro__body { grid-column: 8 / span 5; color: var(--muted); margin: 0; align-self: end; }
.intro__keywords { grid-column: 1 / -1; display: flex; align-items: center; gap: 0; margin-top: clamp(3rem, 8vh, 6rem); }
.kw { display: flex; align-items: center; gap: .75rem; color: var(--muted); transition: color .6s var(--ease); white-space: nowrap; }
.kw__dot { width: 12px; height: 12px; border-radius: 50%; border: 1px solid currentColor; transition: background .6s var(--ease), border-color .6s; }
.kw.is-on { color: var(--fg); }
.kw.is-on .kw__dot { background: var(--accent); border-color: var(--accent); box-shadow: 0 0 16px var(--accent); }
.kw__link { flex: 1; height: 1px; background: var(--line); margin: 0 1rem; position: relative; overflow: hidden; }
.kw__link::after { content: ""; position: absolute; inset: 0; background: var(--accent); transform: scaleX(var(--p, 0)); transform-origin: left; }

/* ---------- Capabilities ---------- */
.section-title { font-size: clamp(2.8rem, 8vw, 8.5rem); margin: 0 0 clamp(3rem, 8vh, 6rem); max-width: 16ch; }
.capabilities__grid { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(2rem, 5vw, 6rem); }
.capabilities .section-title { margin-bottom: 2rem; }
.capabilities__intro { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 1.5rem 3rem; margin-bottom: clamp(3rem, 7vh, 5rem); }
.capabilities__sub { color: var(--muted); max-width: 38rem; margin: 0; }
.capabilities__sub:empty { display: none; }
.cap-item__demo { grid-column: 2; color: var(--accent); margin-top: .35rem; justify-self: start; }
.cap-item__demo span { display: inline-block; transition: transform .4s var(--ease); }
.cap-item__demo:hover span { transform: translateX(4px); }
.cap-col h3 { margin: 0 0 1rem; color: var(--accent); }
.cap-list { list-style: none; margin: 0; padding: 0; border-top: 1px solid var(--line); }
.cap-item { border-bottom: 1px solid var(--line); padding: 1.25rem 0; display: grid; grid-template-columns: 2.5rem 1fr; gap: .25rem 1rem; position: relative; }
.cap-item::before {
  content: ""; position: absolute; left: 0; bottom: -1px; height: 1px; width: 100%; background: var(--accent);
  transform: scaleX(0); transform-origin: left; transition: transform .7s var(--ease);
}
.cap-item:hover::before { transform: scaleX(1); }
.cap-item__n { color: var(--muted); grid-row: span 2; padding-top: .35rem; }
.cap-item__term { font-size: clamp(1.2rem, 1.8vw, 1.6rem); font-weight: 600; letter-spacing: -.01em; transition: transform .6s var(--ease); }
.cap-item:hover .cap-item__term { transform: translateX(8px); }
.cap-item__text { color: var(--muted); font-size: .95rem; }

/* ---------- Projects ---------- */
.projects__head { margin-bottom: clamp(3rem, 8vh, 6rem); }
.projects__head .section-title { margin-bottom: 1.5rem; }
.projects__sub { color: var(--muted); max-width: 36rem; margin: 0; }
.projects__list { display: grid; gap: clamp(5rem, 14vh, 10rem); }
.project { display: grid; grid-template-columns: repeat(12, 1fr); gap: 2rem; align-items: center; }
.project__meta { grid-column: 1 / span 5; }
.project__visual { grid-column: 6 / span 7; }
.project:nth-child(even) .project__meta { grid-column: 8 / span 5; order: 2; }
.project:nth-child(even) .project__visual { grid-column: 1 / span 7; order: 1; }
.project__num { display: flex; gap: 1rem; color: var(--muted); margin-bottom: 1.5rem; }
.project__num b { color: var(--accent); font-weight: 500; }
.project__name { font-size: clamp(3.2rem, 8vw, 7.5rem); margin: 0 0 1.25rem; }
.project__summary { color: var(--muted); margin: 0 0 2rem; max-width: 30rem; }
.link-arrow { display: inline-flex; align-items: center; gap: .75rem; padding-bottom: .4rem; border-bottom: 1px solid var(--line); transition: border-color .4s, gap .5s var(--ease); }
.link-arrow:hover { border-color: var(--accent); gap: 1.25rem; }
.link-arrow span:last-child { color: var(--accent); }

/* ---------- Mockups ---------- */
.mock {
  position: relative; background: var(--panel); border: 1px solid var(--line); border-radius: 14px;
  aspect-ratio: 4 / 3; overflow: hidden; padding: clamp(14px, 2vw, 24px);
  display: flex; flex-direction: column; gap: 12px;
  transform: perspective(1200px) rotateX(var(--rx, 0deg)) rotateY(var(--ry, 0deg));
  transition: transform .6s var(--ease), border-color .4s;
  font-size: clamp(11px, 1vw, 14px);
}
.project__visual:hover .mock { border-color: rgba(255, 74, 28, .5); }
.mock__bar { display: flex; align-items: center; justify-content: space-between; gap: 8px; color: var(--muted); }
.mock__dots { display: flex; gap: 6px; }
.mock__dots i { width: 8px; height: 8px; border-radius: 50%; background: var(--line); }
.mock__badge { background: var(--accent); color: var(--bg); padding: .35em .8em; border-radius: 99px; font-family: var(--font-mono); font-size: .8em; text-transform: uppercase; letter-spacing: .06em; opacity: 0; transform: scale(.85); transition: all .6s var(--ease); transition-delay: var(--bd, 2.4s); white-space: nowrap; }
.mock.is-live .mock__badge { opacity: 1; transform: none; }
.mock--image { padding-bottom: 0; }
.mock__media { flex: 1; min-height: 0; margin: 0 calc(-1 * clamp(14px, 2vw, 24px)); border-top: 1px solid var(--line); overflow: hidden; background: radial-gradient(120% 90% at 70% 30%, #3a0f1c 0%, #140a0d 55%, #0b0909 100%); display: grid; place-items: center; }
.mock__media img { width: 92%; height: 92%; object-fit: contain; display: block; transform: scale(1.06); transition: transform 1.6s var(--ease); }
.mock.is-live .mock__media img { transform: none; }
.mock__body { flex: 1; display: flex; flex-direction: column; gap: 10px; min-height: 0; }
.stag > * { opacity: 0; transform: translateY(10px); transition: opacity .5s var(--ease), transform .5s var(--ease); transition-delay: calc(var(--i) * 380ms + 200ms); }
.mock.is-live .stag > * { opacity: 1; transform: none; }

/* chat */
.chat__user { align-self: flex-end; background: var(--fg); color: var(--bg); padding: .7em 1em; border-radius: 14px 14px 4px 14px; max-width: 80%; font-weight: 500; }
.chat__step { display: flex; align-items: center; gap: .7em; color: var(--muted); font-family: var(--font-mono); font-size: .9em; }
.chat__step::before { content: ""; width: .8em; height: .8em; border-radius: 50%; border: 1px solid var(--accent); flex: none; }
.mock.is-live .chat__step::before { background: var(--accent); transition: background .3s; transition-delay: inherit; }
.chat__final { color: var(--fg) !important; }

/* scan */
.scan { display: grid; grid-template-columns: 1fr 1.1fr; gap: 14px; flex: 1; min-height: 0; }
.scan__doc { position: relative; background: var(--panel-2); border-radius: 8px; padding: 14px; display: grid; align-content: start; gap: 8px; overflow: hidden; }
.scan__doc i { display: block; height: 7px; border-radius: 4px; background: rgba(241, 236, 226, .12); }
.scan__doc i:nth-child(3n) { width: 60%; } .scan__doc i:nth-child(4n) { width: 80%; }
.scan__beam { position: absolute; left: 0; right: 0; height: 30%; top: -30%; background: linear-gradient(to bottom, transparent, rgba(255, 74, 28, .35)); border-bottom: 2px solid var(--accent); }
.mock.is-live .scan__beam { animation: beam 2.2s var(--ease) infinite; }
@keyframes beam { to { top: 100%; } }
.scan__fields { display: grid; align-content: start; gap: 8px; }
.scan__field { border: 1px solid var(--line); border-radius: 8px; padding: .55em .8em; display: grid; gap: 2px; }
.scan__field span { color: var(--muted); font-family: var(--font-mono); font-size: .75em; text-transform: uppercase; }
.scan__status { font-family: var(--font-mono); color: var(--accent); font-size: .85em; }
.mock.is-live .scan__status::after { content: "_"; animation: blink 1s steps(1) infinite; }
@keyframes blink { 50% { opacity: 0; } }

/* flow */
.flow { flex: 1; display: flex; align-items: center; justify-content: space-between; position: relative; gap: 8px; }
.flow__line { position: absolute; left: 6%; right: 6%; top: 50%; height: 1px; background: var(--line); }
.flow__pulse { position: absolute; top: 50%; left: 6%; width: 10px; height: 10px; margin-top: -5px; border-radius: 50%; background: var(--accent); box-shadow: 0 0 14px var(--accent); opacity: 0; }
.mock.is-live .flow__pulse { animation: pulse-run 2.6s var(--ease) infinite; }
@keyframes pulse-run { 0% { left: 6%; opacity: 1; } 90% { opacity: 1; } 100% { left: 94%; opacity: 0; } }
.flow__node { position: relative; z-index: 1; background: var(--panel-2); border: 1px solid var(--line); border-radius: 10px; padding: .9em .8em; text-align: center; flex: 1; font-family: var(--font-mono); font-size: .8em; text-transform: uppercase; }
.flow__node:last-child { border-color: var(--accent); color: var(--accent); }
.flow__sources { display: flex; gap: 8px; }
.flow__sources span { flex: 1; height: 34px; border-radius: 6px; background: var(--panel-2); border: 1px dashed var(--line); }

/* pipeline */
.pipe__row { display: flex; align-items: center; gap: .8em; padding: .6em .8em; border: 1px solid var(--line); border-radius: 8px; }
.pipe__check { width: 1.4em; height: 1.4em; border-radius: 50%; border: 1px solid var(--line); display: grid; place-items: center; font-size: .8em; color: var(--bg); flex: none; transition: all .4s var(--ease); transition-delay: inherit; }
.mock.is-live .pipe__check { background: var(--accent); border-color: var(--accent); }
.pipe__swatches { display: grid; grid-template-columns: repeat(6, 1fr); gap: 6px; margin-top: auto; }
.pipe__swatches i { aspect-ratio: 1; border-radius: 6px; background: linear-gradient(135deg, var(--accent), #2a1a12); opacity: .2; transition: opacity .6s; }
.mock.is-live .pipe__swatches i { opacity: 1; transition-delay: calc(var(--i) * 90ms + 1.8s); }
.pipe__swatches i:nth-child(odd) { background: linear-gradient(135deg, var(--fg), #3a3530); }

/* meeting */
.wave { display: flex; align-items: center; gap: 3px; height: 26%; }
.wave i { flex: 1; background: var(--fg); opacity: .3; border-radius: 2px; height: calc(var(--h) * 1%); transform-origin: center; }
.mock.is-live .wave i { animation: wave 1.2s ease-in-out infinite alternate; animation-delay: calc(var(--i) * -70ms); }
@keyframes wave { to { transform: scaleY(.25); opacity: .8; } }
.meet__item { border-left: 2px solid var(--accent); padding: .3em .8em; background: var(--panel-2); border-radius: 0 6px 6px 0; }

/* dashboard */
.dash__stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.dash__stat { border: 1px solid var(--line); border-radius: 8px; padding: .6em .8em; display: grid; }
.dash__stat span { color: var(--muted); font-family: var(--font-mono); font-size: .75em; text-transform: uppercase; }
.dash__stat b { font-size: 1.5em; font-weight: 600; }
.dash__chart { flex: 1; display: flex; align-items: flex-end; gap: 6px; min-height: 0; border-bottom: 1px solid var(--line); }
.dash__chart i { flex: 1; background: var(--fg); opacity: .25; border-radius: 3px 3px 0 0; height: 4%; transition: height 1.2s var(--ease); transition-delay: calc(var(--i) * 60ms + .3s); }
.dash__chart i:last-child { background: var(--accent); opacity: 1; }
.mock.is-live .dash__chart i { height: calc(var(--h) * 1%); }
.dash__insight { font-family: var(--font-mono); font-size: .85em; color: var(--accent); }

/* ---------- About ---------- */
.about__body { display: grid; grid-template-columns: repeat(12, 1fr); gap: 2rem; }
.about__img { grid-column: 1 / span 3; grid-row: span 2; margin: 0; }
.about__img:empty { display: none; }
.about__img img { width: 100%; border-radius: 12px; filter: grayscale(.2) contrast(1.05); }
.logo img { height: 32px; width: auto; }
.about__body p { grid-column: 5 / span 8; font-size: clamp(1.15rem, 1.8vw, 1.6rem); line-height: 1.45; margin: 0; }
.about__sign { grid-column: 5 / span 8; display: flex; flex-direction: column; gap: .5rem; margin-top: 2rem; }
.signature { font-family: var(--font-display); text-transform: uppercase; font-size: clamp(2rem, 4vw, 3.5rem); color: var(--accent); }
.about__sign .mono { color: var(--muted); }

/* ---------- Teaser / untangle ---------- */
.teaser { text-align: center; }
.teaser__heading { font-size: clamp(2.6rem, 8vw, 8rem); margin: 0 auto 2rem; max-width: 14ch; }
.untangle { position: relative; height: clamp(320px, 55vh, 520px); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); touch-action: none; user-select: none; -webkit-user-select: none; }
.untangle__canvas { position: absolute; inset: 0; width: 100%; height: 100%; cursor: grab; }
.untangle.is-dragging .untangle__canvas { cursor: grabbing; }
.untangle__hint { position: absolute; left: 0; bottom: 1rem; margin: 0; color: var(--muted); pointer-events: none; transition: opacity .5s; }
.untangle__cta {
  position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%) scale(.9); font-size: clamp(3rem, 10vw, 9rem);
  opacity: 0; pointer-events: none; transition: opacity .8s var(--ease), transform .8s var(--ease), color .3s; white-space: nowrap;
}
.untangle.is-solved .untangle__cta { opacity: 1; transform: translate(-50%, -50%); pointer-events: auto; }
.untangle.is-solved .untangle__hint { opacity: 0; }
.untangle__cta:hover { color: var(--accent); }

/* ---------- Contact ---------- */
.contact { display: grid; grid-template-columns: repeat(12, 1fr); gap: 2rem; }
.contact__intro { grid-column: 1 / span 5; }
.contact__title { font-size: clamp(3.4rem, 10vw, 9rem); margin: 0 0 1.5rem; }
.contact__sub { color: var(--muted); margin: 0 0 2rem; font-size: 1.15rem; }
.contact__mail { border-bottom: 1px solid var(--accent); padding-bottom: .2rem; text-transform: none; font-size: .9rem; }
.contact__form { grid-column: 7 / span 6; display: grid; gap: 1.75rem; align-content: start; }
.field { display: grid; gap: .5rem; }
.field__label { color: var(--muted); }
.field input, .field textarea {
  font: inherit; color: var(--fg); background: transparent; border: 0; border-bottom: 1px solid var(--line);
  padding: .6rem 0; border-radius: 0; resize: vertical; transition: border-color .3s;
}
.field input:focus, .field textarea:focus { outline: none; border-color: var(--accent); }
.field.has-error input, .field.has-error textarea { border-color: #ff2b2b; }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.btn {
  justify-self: start; display: inline-flex; align-items: center; gap: .75rem; padding: 1rem 1.6rem; border-radius: 99px;
  background: var(--fg); color: var(--bg); font-family: var(--font-mono); text-transform: uppercase; letter-spacing: .08em; font-size: .8rem;
  transition: background .3s, transform .4s var(--ease);
}
.btn:hover { background: var(--accent); }
.btn[disabled] { opacity: .5; pointer-events: none; }
.form-status { min-height: 1.2em; margin: 0; color: var(--muted); text-transform: none; }
.form-status.is-ok { color: var(--fg); }
.form-status.is-err { color: #ff6b4a; }

/* ---------- Footer ---------- */
.site-footer { display: flex; align-items: center; justify-content: space-between; gap: 1.5rem; flex-wrap: wrap; padding: 40px var(--gutter); border-top: 1px solid var(--line); max-width: var(--max); margin: 0 auto; }
.site-footer__socials { display: flex; gap: 1.5rem; flex-wrap: wrap; }
.site-footer__socials a:hover, .back-top:hover { color: var(--accent); }
.site-footer__copy { color: var(--muted); margin: 0; }
.back-top::before { content: "↑ "; color: var(--accent); }

/* ---------- Project page ---------- */
.p-hero { min-height: 92svh; display: flex; flex-direction: column; justify-content: flex-end; padding-top: 140px; }
.p-hero__title { font-size: clamp(4rem, 16vw, 16rem); margin: 0; }
.p-hero__summary { max-width: 40rem; color: var(--muted); font-size: clamp(1.05rem, 1.5vw, 1.35rem); margin: 1.5rem 0 3rem; }
.p-hero__visual { max-width: 900px; width: 100%; }
.p-hero > .link-arrow { align-self: flex-start; margin: -1.5rem 0 3rem; }
.p-figure { margin: 1rem 0 0; }
.p-figure img { display: block; width: 100%; max-height: 560px; object-fit: contain; }
.p-meta { display: grid; grid-template-columns: repeat(3, 1fr); gap: 2rem; border-top: 1px solid var(--line); padding-top: 2rem; }
.p-meta dt { color: var(--muted); margin-bottom: .5rem; }
.p-meta dd { margin: 0; font-size: 1.05rem; }
.p-toc { display: flex; flex-wrap: wrap; gap: .5rem 1.5rem; padding-top: 0; padding-bottom: 0; }
.p-toc span { color: var(--muted); width: 100%; }
.p-toc a:hover { color: var(--accent); }
.p-section { display: grid; grid-template-columns: repeat(12, 1fr); gap: 2rem; }
.p-section__kicker { grid-column: 1 / span 3; color: var(--muted); }
.p-section__kicker b { color: var(--accent); font-weight: 500; }
.p-section__content { grid-column: 4 / span 9; }
.p-section h2 { font-family: var(--font-body); font-weight: 500; font-size: clamp(1.8rem, 3.6vw, 3.2rem); line-height: 1.1; letter-spacing: -.02em; margin: 0 0 1.5rem; }
.p-section p { color: var(--muted); max-width: 44rem; margin: 0; font-size: 1.1rem; }
.p-items { list-style: none; padding: 0; margin: 2.5rem 0 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 1rem; }
.p-items li { border: 1px solid var(--line); border-radius: 12px; padding: 1.4rem; display: grid; gap: .5rem; }
.p-items li .mono { color: var(--accent); }
.p-items b { font-size: 1.15rem; font-weight: 600; }
.p-items li span:last-child { color: var(--muted); }
.metrics { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1rem; margin-top: 2.5rem; }
.metric { background: var(--panel); border: 1px solid var(--line); border-radius: 14px; padding: 1.6rem; display: grid; gap: .6rem; }
.metric .mono { color: var(--muted); }
.metric b { font-family: var(--font-display); font-weight: 400; font-size: clamp(2.6rem, 5vw, 4.5rem); line-height: 1; color: var(--accent); }
.metric span:last-child { color: var(--muted); font-size: .95rem; }
.p-next { display: block; border-top: 1px solid var(--line); }
.p-next__label { color: var(--muted); margin-bottom: 1.5rem; }
.p-next__name { font-size: clamp(4rem, 14vw, 13rem); margin: 0; transition: color .4s; }
.p-next:hover .p-next__name { color: var(--accent); }
.p-next__tag { color: var(--muted); margin: 1rem 0 0; }
.p-next__end { margin-top: 3rem; color: var(--accent); }
.not-found { min-height: 80svh; display: grid; place-content: center; text-align: center; gap: 1.5rem; }

/* ---------- Responsive ---------- */
@media (max-width: 900px) {
  .nav-inline { display: none; }
  .menu-toggle { display: inline-flex; }
  .intro, .about__body, .contact, .p-section { grid-template-columns: 1fr; }
  .intro > *, .about__body > *, .contact > *, .p-section > * { grid-column: 1 / -1 !important; }
  .capabilities__grid { grid-template-columns: 1fr; }
  .project { grid-template-columns: 1fr; }
  .project .project__meta, .project .project__visual, .project:nth-child(even) .project__meta, .project:nth-child(even) .project__visual { grid-column: 1 / -1; order: 0; }
  .project__visual { order: 2 !important; }
  .p-meta, .metrics { grid-template-columns: 1fr; }
  .intro__keywords { flex-wrap: wrap; row-gap: 1rem; }
  .kw__link { min-width: 24px; }
  .mock { aspect-ratio: 4 / 3.4; }
}
@media (max-width: 520px) {
  .scan { grid-template-columns: 1fr; }
  .scan__doc { display: none; }
  .dash__stat b { font-size: 1.2em; }
}

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