:root {
  color-scheme: dark;
  --ink: #0B0E14;
  --panel: #151A22;
  --paper: #EDF0F5;
  --muted: #8E98A8;
  --accent: #5B8CFF;
  --accent-hover: #7BA4FF;
  --accent-deep: #3657A3;
  --on-accent: #0B0E14;
  --ok: #A8B99B;
  --line: rgba(237,240,245,.17);
  --display: 'Golos Text', sans-serif;
  --body: 'Manrope', sans-serif;
  --space: clamp(22px, 5vw, 88px);
  --shadow: 0 0 0 .5px rgba(255,255,255,.1);
}
* { box-sizing: border-box; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; border: 0; }

html {
  scroll-behavior: smooth;
  scroll-padding-top: 70px;
}

body { margin: 0; background: var(--ink); color: var(--paper); font-family: var(--body); font-size: 16px; line-height: 1.6; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; }
button, a, summary { touch-action: manipulation; -webkit-tap-highlight-color: transparent; }
::selection { background: var(--accent); color: var(--on-accent); }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 5px; }
h1, h2, h3, p { margin: 0; }
h1, h2, h3 { font-family: var(--display); font-weight: 500; line-height: 1.04; letter-spacing: -0.035em; }

.skip { position: fixed; left: 20px; top: -100px; padding: 12px; background: var(--paper); color: var(--ink); z-index: 1001; }
.skip:focus { top: 20px; }

.header {
  height: 70px;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 var(--space);
  gap: 30px;
  background: rgba(11, 14, 20, 0.9);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--line);
}
.brand { font: 800 44px/1 var(--display); letter-spacing: -.12em; }
.brand-dot { color: var(--accent); }
nav { display: flex; gap: 38px; margin-left: 8vw; }
nav a, .header-contact { font-size: 13px; }
.header-contact span { margin-left: 16px; }
.text-link { display: inline-block; position: relative; width: fit-content; }
.text-link:after { content: ''; height: 1px; background: currentColor; position: absolute; bottom: -4px; left: 0; width: 100%; transform: scaleX(0); transform-origin: right; transition: transform .35s; }
.text-link:hover:after, .text-link:focus-visible:after { transform: scaleX(1); transform-origin: left; }

.work {
  margin: 0;
  padding: 0;
}

.film {
  height: 330svh;
  min-height: 1500px;
  position: relative;
  margin-bottom: 0;
}
.screen { position: sticky; top: 0; height: 100svh; min-height: 650px; overflow: hidden; background: var(--ink); }
.screen:after { content: ''; position: absolute; inset: 0; pointer-events: none; opacity: .13; background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 180 180' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Cpath fill='%23fff' filter='url(%23n)' opacity='.28' d='M0 0h180v180H0z'/%3E%3C/svg%3E"); }
.scene-aurora { position: absolute; inset: -10%; pointer-events: none; background: linear-gradient(120deg, #111A2B, #192338, #151A22, #111A2B); opacity: .25; animation: aurora 20s ease-in-out infinite; animation-play-state: paused; }
.scene-aurora.is-running { animation-play-state: running; }
@keyframes aurora { 0%, 100% { transform: translate3d(-5%, -3%, 0); } 50% { transform: translate3d(5%, 3%, 0); } }

.frames { position: absolute; inset: 165px var(--space) 110px; }
.frame { position: absolute; inset: 0; display: grid; grid-template-columns: 1.15fr 1fr; align-items: center; gap: 20px; opacity: 0; visibility: hidden; pointer-events: none; }
.frame--first { opacity: 1; visibility: visible; pointer-events: auto; }
.frame.is-active { z-index: 10; }
.frame-copy { position: relative; z-index: 2; }
.chapter { font-size: 12px; margin-bottom: 25px; color: var(--accent); }
.frame h1, .frame h2 { font-size: clamp(64px, 7.7vw, 128px); font-weight: 500; }
.frame--first h1 { font-size: clamp(44px, 5.4vw, 88px); line-height: 1.06; letter-spacing: -.055em; }
.period { color: var(--accent); }
.frame-description { font-size: clamp(13px, 1.1vw, 17px); line-height: 1.8; margin-top: 28px; color: var(--muted); max-width: 48ch; }
.pill { display: inline-flex; align-items: center; justify-content: space-between; gap: 40px; border: 1px solid var(--accent); border-radius: 100px; padding: 15px 23px; margin-top: 30px; font-size: 12px; background: #5B8CFF05; transition: background .25s; }
.pill:hover { background: #5B8CFF15; }
.pill span { font-size: 20px; line-height: 1; }

.art { position: relative; aspect-ratio: 1; width: 100%; max-width: 620px; justify-self: end; }
.art--orbit { display: grid; place-items: center; }
.orbit { position: absolute; border: 1px solid #5B8CFF4d; border-radius: 50%; width: 94%; height: 94%; transform: rotate(-28deg) scaleY(.62); }
.orbit-two { transform: rotate(37deg) scaleY(.62); width: 87%; height: 87%; }
.orbit-three { transform: rotate(92deg) scaleY(.62); width: 82%; height: 82%; border-color: #5B8CFF24; }
.core { width: 49%; height: 49%; display: grid; place-items: center; border-radius: 50%; background: radial-gradient(circle at 30% 25%, #CBDCFF 0, var(--accent-hover) 14%, var(--accent-deep) 40%, #1B2A4A 64%, #101725 82%); box-shadow: inset -12px -18px 25px #080E1C, 0 0 80px #5B8CFF1a; transform: rotate(-15deg); }
.core span { font: 600 clamp(50px, 7vw, 110px)/1 var(--display); letter-spacing: -.09em; color: #CBDCFF; opacity: .85; text-shadow: 0 3px 25px #5B8CFF44; }
.satellite { position: absolute; border: 1px solid #5B8CFF42; border-radius: 30px; background: #151A22; padding: 8px 21px; font-size: 12px; box-shadow: var(--shadow); }
.satellite-one { top: 20%; right: 6%; transform: rotate(8deg); }
.satellite-two { left: 3%; bottom: 21%; transform: rotate(-8deg); }
.satellite-three { right: 4%; bottom: 19%; transform: rotate(6deg); }
.satellite { animation: pill-float 4s ease-in-out 1; }
.satellite-two { animation-delay: .4s; }
.satellite-three { animation-delay: .8s; }
@keyframes pill-float { 50% { translate: 0 -9px; } }

.screen-bottom { position: absolute; bottom: 34px; left: var(--space); right: var(--space); display: flex; justify-content: space-between; align-items: center; gap: 24px; z-index: 3; }
.scroll-hint { display: inline-flex; align-items: center; justify-content: center; min-width: 44px; min-height: 44px; font-size: 10px; color: var(--muted); }
.scroll-hint span { margin-left: 20px; }
.film-position { display: flex; align-items: center; gap: 13px; font-size: 10px; color: var(--muted); }
.film-track { width: 130px; height: 1px; background: #5B8CFF44; overflow: hidden; }
.film-track i { display: block; width: 100%; height: 1px; background: var(--accent); transform: scaleX(.02); transform-origin: left; }

.art--dialog, .art--data { display: grid; place-items: center; }
.chat-window { width: 90%; padding: 25px; border: 1px solid #5B8CFF30; border-radius: 20px; background: linear-gradient(135deg, #192338, #151A22); box-shadow: var(--shadow); transform: rotate(-4deg); }
.chat-caption { font-size: 11px; color: var(--accent); margin-bottom: 18px; }
.chat-head { display: flex; align-items: center; gap: 12px; font-size: 13px; padding-bottom: 12px; }
.chat-head small { display: block; font-size: 10px; color: var(--muted); }
.chat-avatar { width: 40px; height: 40px; flex-shrink: 0; background: var(--accent); color: var(--on-accent); border-radius: 50%; display: grid; place-items: center; font-weight: 800; font-size: 24px; }
.chat-head i { width: 6px; height: 6px; border-radius: 50%; background: var(--accent); margin-left: auto; }
.bubble { font-size: 12px; padding: 12px 16px; border-radius: 15px; max-width: 90%; margin: 10px 0; }
.bubble--out { margin-left: auto; background: #24385C; border-bottom-right-radius: 3px; }
.bubble--in { background: #202936; border-bottom-left-radius: 3px; }
.chat-foot { display: flex; justify-content: center; gap: 20px; color: var(--muted); font-size: 10px; margin-top: 18px; }

.data-window { width: 95%; background: #151A22; border: 1px solid #5B8CFF44; box-shadow: var(--shadow); transform: rotate(5deg); border-radius: 10px; overflow: hidden; }
.window-head { padding: 16px; display: flex; align-items: center; gap: 5px; border-bottom: 1px solid var(--line); }
.window-head > span { width: 6px; height: 6px; border-radius: 50%; background: #8E98A8; }
.window-head em { font-size: 10px; font-style: normal; margin-left: auto; color: var(--muted); }
.code-line { font-size: 11px; padding: 24px 22px 10px; font-family: monospace; color: var(--muted); }
.code-line b { font-weight: 400; color: var(--accent); }
.pipeline { padding: 10px 22px; }
.pipeline > div { position: relative; padding: 13px 16px; border: 1px solid var(--line); display: flex; justify-content: space-between; align-items: center; font-size: 12px; }
.pipeline small { font-size: 10px; color: var(--muted); }
.pipeline > i { display: block; text-align: center; font-style: normal; color: var(--accent); font-size: 15px; }
.pipeline .pipeline-result { border-color: #5B8CFF66; background: #5B8CFF0a; padding-right: 35px; }
.pipeline strong { position: absolute; right: 12px; color: var(--ok); }
.terminal-line { font-size: 10px; color: var(--muted); border-top: 1px solid var(--line); margin-top: 20px; padding: 15px 22px; }

.section { padding: 115px var(--space); }
.section-heading { display: flex; justify-content: space-between; align-items: end; margin-bottom: 60px; gap: 30px; }
.section-heading h2 { font-size: clamp(34px, 4.6vw, 72px); }
.section-aside { font-size: 12px; line-height: 1.8; color: var(--muted); }

.tags { display: flex; gap: 8px; list-style: none; padding: 0; margin: 18px 0 0; flex-wrap: wrap; }
.tags li { font-size: 12px; border: 1px solid var(--line); border-radius: 30px; padding: 6px 14px; }

.faq-list { max-width: 1000px; }
.faq details { border-top: 1px solid var(--line); padding: 24px 0; }
.faq details:last-child { border-bottom: 1px solid var(--line); }
.faq summary { cursor: pointer; font-weight: 600; font-size: clamp(16px, 1.5vw, 22px); line-height: 1.5; padding-right: 10px; }
.faq details[open] > summary::marker { color: var(--accent); }
.faq details p { max-width: 64ch; color: var(--muted); font-size: 15px; line-height: 1.8; margin: 20px 0 0; }

.contact { background: var(--ink); color: var(--paper); }
.contact :focus-visible { outline-color: var(--accent); }
.contact-copy { max-width: 680px; }
.contact h2 { font-size: clamp(30px, 5vw, 72px); line-height: 1.2; margin: 0 0 28px; letter-spacing: -.025em; word-spacing: normal; }
.contact-bottom { display: flex; flex-direction: column; align-items: flex-start; gap: 12px; }
.contact-cta { padding: 8px 0 12px; font-size: clamp(20px, 2.2vw, 28px); letter-spacing: -.04em; display: flex; gap: 32px; align-items: center; max-width: 100%; min-height: 44px; color: var(--accent); }
.contact-cta:hover { color: var(--accent-hover); }
.contact-cta span { font-size: 35px; }
.contact-languages { font-size: 13px; }
.contact-socials { display: flex; align-items: center; gap: 28px; margin-top: 8px; font-size: 14px; }
.contact-socials a { display: inline-flex; align-items: center; min-height: 44px; }

/* Демо и проекты */

.demo,
.project-row {
  display: flex;
  flex-direction: column;
  justify-content: center;
  min-height: 100dvh;
  margin: 0;
  padding: 110px var(--space) 40px;
  box-sizing: border-box;
  overflow: visible;
  background: var(--ink);
  position: relative;
  z-index: 10;
}

/* Sections already reserve header space; anchors align to the viewport edge. */
#demo, #work { scroll-margin-top: -70px; }

.demo-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 40px;
  align-items: center;
  width: 100%;
  max-width: 1400px;
  margin: 0 auto;
  height: auto;
  flex-shrink: 0;
  min-height: 0;
  grid-template-rows: auto;
  justify-content: center;
}

.demo-copy h2 { font-size: clamp(34px, 4.4vw, 68px); margin-bottom: 20px; }
.demo-copy p { color: var(--muted); font-size: 15px; line-height: 1.8; margin-bottom: 30px; max-width: 48ch; }
.demo-cta { font-size: 16px; background: var(--accent); color: var(--on-accent); font-weight: 600; padding: 16px 28px; display: inline-flex; border-radius: 100px; transition: background 0.25s; }
.demo-cta:hover { background: var(--accent-hover); }

.browser-frame { width: 100%; overflow: hidden; border: 1px solid var(--line); border-radius: 14px; background: var(--panel); box-shadow: 0 18px 55px rgba(0,0,0,0.3); }
.browser-frame-head { height: 38px; display: flex; align-items: center; gap: 12px; padding: 0 14px; background: #10151D; border-bottom: 1px solid var(--line); font-size: 11px; color: var(--muted); }
.browser-dots { display: flex; gap: 5px; flex-shrink: 0; }
.browser-dots i { width: 8px; height: 8px; border-radius: 50%; background: #667080; }
.browser-logo { font: 700 16px/1 var(--display); letter-spacing: -0.06em; color: var(--accent); }
.browser-frame video { display: block; width: 100%; max-height: 100%; aspect-ratio: 16/9; object-fit: contain; background: var(--ink); }

.project-inner {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 5vw;
  align-items: center;
  width: 100%;
  max-width: 1400px;
  margin: 0 auto;
  height: auto;
  flex-shrink: 0;
  min-height: 0;
  grid-template-rows: auto;
  justify-content: center;
}
.project-row--reverse .project-media { order: 2; }
.project-media, .demo-video { width: 100%; height: 100%; min-height: 0; min-width: 0; margin: 0; display: flex; align-items: center; justify-content: center; }
.demo-copy, .project-content { min-width: 0; }
.demo-source { display: block; margin-top: 20px; font-size: 13px; }
/* Constrain the entire frame, including its 38px toolbar. */
.project-media .browser-frame, .demo-video .browser-frame { max-height: 100%; display: flex; flex-direction: column; }
.browser-frame-head { flex: 0 0 38px; }
.project-art { min-height: 0; display: flex; }
.project-art img { min-height: 0; max-height: 70vh; }
.browser-frame video { min-height: 0; max-height: 65vh; }
.project-media .browser-frame { width: 100%; }
.project-art img { display: block; width: 100%; height: auto; object-fit: contain; }

.project-content { display: flex; flex-direction: column; align-items: flex-start; }
.project-type { font-size: 12px; color: var(--muted); font-weight: 400; margin-bottom: 15px; }
.project-title { font-size: clamp(28px, 4vw, 56px); letter-spacing: -0.04em; line-height: 1.1; margin-bottom: 20px; }
.project-description { font-size: 16px; line-height: 1.65; color: var(--muted); margin-bottom: 24px; max-width: 45ch; }
.project-links { display: flex; align-items: center; gap: 24px; margin-top: 10px; }

.project-link { font-size: 15px; font-weight: 500; position: relative; }
.project-link:after { content: ''; position: absolute; bottom: -4px; left: 0; width: 100%; height: 1px; background: currentColor; transform: scaleX(0); transform-origin: right; transition: transform 0.3s; }
.project-link:hover:after { transform: scaleX(1); transform-origin: left; }


/* Адаптивная вёрстка */

@media(min-width:1700px){.frames{max-width:1600px;margin:auto}.section{padding-left:max(var(--space),calc((100vw - 1600px)/2));padding-right:max(var(--space),calc((100vw - 1600px)/2))}}

@media (max-width: 1100px) {
  .project-inner { gap: 32px; }
  .demo-grid { gap: 32px; }
}

@media (max-width: 900px) {
  .header-contact{font-size:11px}nav{margin-left:0;gap:25px}
  .frames{inset:150px var(--space) 100px}.frame h1,.frame h2{font-size:clamp(54px,8vw,85px)}
  .frame--first h1{font-size:clamp(36px,5.4vw,49px)}.frame{grid-template-columns:1.1fr 1fr;gap:0}
  .frame-description{font-size:12px}.chat-window{padding:16px;width:100%}.bubble{font-size:10px;padding:10px}
  .code-line{font-size:9px;padding:18px 12px}.pipeline{padding:10px 12px}.pipeline small{font-size:8px}
  .pipeline>div{font-size:10px;padding:10px}.terminal-line{font-size:8px;padding:12px}
  .section{padding-top:85px;padding-bottom:85px}.section-aside{font-size:11px}
  .demo-grid, .project-inner { grid-template-columns: 1fr; grid-template-rows: auto; height: auto; gap: 40px; }
  .project-row--reverse .project-media { order: 0; }
  .project-media, .demo-video { height: auto; }
  .project-media .browser-frame, .demo-video .browser-frame { max-height: none; }
  .demo, .project-row {
    overflow: visible;
  }
}

@media (max-width: 600px) {
  :root{--space:24px}.header{gap:15px}.brand{font-size:38px}nav{gap:14px}nav a{font-size:11px}
  .header-contact{font-size:0}.header-contact span{font-size:22px;margin:0}
  .film{height:340svh;min-height:1600px}.screen{min-height:690px}.scene-aurora{animation:none}
  .frames{inset:125px 24px 85px}.frame{display:block}.frame h1,.frame h2{font-size:clamp(50px,12.7vw,76px)}
  .frame--first h1{font-size:clamp(35px,9.4vw,56px)}.chapter{font-size:10px;margin-bottom:15px}
  .frame-description{margin-top:20px;font-size:12px}.pill{margin-top:22px;padding:12px 18px;font-size:10px;gap:28px}
  .art{position:absolute;right:-20px;bottom:0;width:220px;z-index:0}.frame-copy{z-index:1}
  .art--orbit{width:260px;right:-55px;bottom:-22px;opacity:.8}.art--data{bottom:30px;right:0;width:215px;opacity:.65}
  .art--dialog{position:relative;right:auto;bottom:auto;aspect-ratio:auto;max-width:390px;width:100%;margin-top:26px}
  .core span{font-size:58px}.satellite{font-size:8px;padding:5px 12px}
  .screen-bottom{bottom:22px;gap:12px}.scroll-hint{font-size:0}.scroll-hint span{font-size:20px;margin:0}
  .film-track{width:65px}.film-position{gap:8px;font-size:9px}
  .chat-window{padding:14px;transform:none}.chat-caption{font-size:10px;margin-bottom:10px}
  .chat-head{display:none}.bubble{font-size:11px;margin:8px 0;padding:8px 10px;line-height:1.4}.chat-foot{display:none}
  .code-line{font-size:8px}.pipeline small{font-size:6px}.pipeline>div{font-size:8px;padding:7px}.terminal-line{font-size:6px;margin-top:10px}
  .section{padding-top:65px;padding-bottom:65px}.section-heading{display:block;margin-bottom:30px}.section-heading h2{font-size:36px}
  .section-aside{margin-top:23px;font-size:12px}
  .contact-cta{font-size:20px;gap:24px}.faq details{padding:20px 0}.faq details p{font-size:14px}

  .project-title { font-size: 28px; }
  .project-links { flex-direction: column; align-items: flex-start; gap: 16px; }
}

html:not(.js) .film,.static-scene .film{height:auto;min-height:0}
html:not(.js) .screen,.static-scene .screen{position:relative;height:auto;min-height:0;padding:160px var(--space) 90px}
html:not(.js) .frames,.static-scene .frames{position:relative;inset:auto}
html:not(.js) .frame,.static-scene .frame{position:relative;inset:auto;opacity:1!important;visibility:visible!important;pointer-events:auto!important;min-height:550px;transform:none!important}
html:not(.js) .film-position,.static-scene .film-position{display:none}
html:not(.js) .scene-aurora{animation:none}

@media(prefers-reduced-motion:reduce){html{scroll-behavior:auto}*,*:before,*:after{animation:none!important;transition:none!important}}
@media(max-height:740px) and (min-width:601px){.screen{min-height:580px}.frames{top:145px;bottom:85px}.frame h2{font-size:clamp(55px,6.5vw,90px)}.art{max-width:380px}.chapter{margin-bottom:15px}.frame-description{margin-top:20px}.pill{margin-top:20px}.chat-window{padding:16px}.bubble{font-size:10px;padding:8px 12px}.chat-head{padding-bottom:8px}}

@media(forced-colors:active){.scene-aurora,.screen:after{display:none!important}.core{background:Canvas;border:1px solid CanvasText;box-shadow:none}.core span{color:CanvasText;text-shadow:none}.orbit{border-color:CanvasText}.contact{background:Canvas;color:CanvasText}.contact :focus-visible{outline-color:Highlight}.pill,.browser-frame,.chat-window{border-color:ButtonText}.faq details[open]>summary::marker{color:CanvasText}}

.faq {
  padding-top: 90px;
  padding-bottom: 80px;
  padding-left: var(--space);
  padding-right: var(--space);
  scroll-margin-top: 70px;
}
