:root {
  --bg: #0b0b0c;
  --bg2: #141416;
  --card: #1a1a1d;
  --text: #f4f1ec;
  --muted: #a6a6ad;
  --line: rgba(255, 255, 255, 0.12);
  --red: #ff4b3e;
  --red-d: #d9362b;
  --gold: #ffc23d;
  --radius: 18px;
  --gutter: clamp(16px, 5vw, 56px);
  --head: "Oswald", "Arial Narrow", Impact, sans-serif;
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body { margin: 0; font-family: "Rubik", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif; color: var(--text); background: var(--bg); line-height: 1.6; font-size: 17px; overflow-x: hidden; }
a { color: inherit; }
:focus-visible { outline: 3px solid var(--gold); outline-offset: 3px; border-radius: 6px; }
.skip { position: absolute; left: -999px; top: 8px; background: var(--red); color: #fff; padding: 10px 14px; z-index: 20; border-radius: 8px; }
.skip:focus { left: 8px; }

/* Шапка */
.top { display: flex; align-items: center; gap: 24px; padding: 12px var(--gutter); position: sticky; top: 0; background: rgba(11, 11, 12, 0.85); backdrop-filter: blur(10px); border-bottom: 1px solid var(--line); z-index: 10; }
.brand { display: inline-flex; align-items: center; gap: 10px; font-family: var(--head); font-weight: 700; font-size: 24px; letter-spacing: 0.04em; text-transform: uppercase; text-decoration: none; margin-right: auto; }
.logo { width: 26px; height: 26px; border-radius: 50%; background: radial-gradient(circle at 50% 50%, var(--red) 0 36%, transparent 38%), conic-gradient(from 0deg, var(--gold) 0 6%, transparent 6% 12%, var(--gold) 12% 18%, transparent 18% 24%, var(--gold) 24% 30%, transparent 30% 36%, var(--gold) 36% 42%, transparent 42% 48%, var(--gold) 48% 54%, transparent 54% 60%, var(--gold) 60% 66%, transparent 66% 72%, var(--gold) 72% 78%, transparent 78% 84%, var(--gold) 84% 90%, transparent 90%); animation: spin 24s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.top nav { display: flex; gap: 22px; }
.top nav a { text-decoration: none; font-size: 15px; color: var(--muted); padding: 10px 0; transition: color 0.15s; }
.top nav a:hover { color: var(--text); }
.lang { font-size: 14px; text-decoration: none; border: 1px solid var(--line); border-radius: 999px; padding: 10px 16px; min-height: 44px; display: inline-flex; align-items: center; transition: background 0.15s; }
.lang:hover { background: var(--card); }

/* Главный экран */
.hero { display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(0, 0.8fr); gap: clamp(28px, 5vw, 72px); align-items: center; padding: clamp(36px, 7vw, 90px) var(--gutter) clamp(28px, 5vw, 56px); max-width: 1280px; margin: 0 auto; }
h1, h2 { font-family: var(--head); text-transform: uppercase; font-weight: 600; letter-spacing: 0.005em; line-height: 1.02; }
h1 { font-size: clamp(40px, 7vw, 84px); margin: 0 0 22px; }
h1 em { font-style: normal; color: var(--red); }
.reveal span { display: inline-block; opacity: 0; transform: translateY(0.5em); animation: rise 0.7s cubic-bezier(0.2, 0.8, 0.2, 1) forwards; animation-delay: calc(var(--w) * 90ms + 150ms); }
@keyframes rise { to { opacity: 1; transform: none; } }
.lead { font-size: clamp(17px, 2vw, 20px); color: var(--muted); max-width: 52ch; margin: 0 0 30px; }
.actions { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; }
.btn { display: inline-flex; align-items: center; justify-content: center; min-height: 50px; padding: 12px 26px; border-radius: 12px; font-weight: 600; text-decoration: none; font-size: 16px; border: 2px solid transparent; transition: transform 0.15s ease-out, box-shadow 0.15s ease-out, background 0.15s; }
.btn:hover { transform: translateY(-2px); }
.btn:active { transform: scale(0.98); }
.btn-main { background: var(--red); color: #fff; box-shadow: 0 5px 0 var(--red-d); }
.btn-main:hover { box-shadow: 0 7px 0 var(--red-d), 0 12px 30px rgba(255, 75, 62, 0.35); }
.btn-wa { background: #25d366; color: #06210f; box-shadow: 0 5px 0 #17a14d; }
.btn-line { border-color: var(--line); color: var(--text); }
.btn-line:hover { background: var(--card); }

/* Телефон с диалогом */
.phone { background: #0f1512; border-radius: 30px; max-width: 380px; width: 100%; justify-self: center; overflow: hidden; border: 1px solid var(--line); box-shadow: 0 30px 80px rgba(255, 75, 62, 0.12), 0 0 0 8px #18181b; }
.phone-bar { background: #1f2c27; padding: 14px 18px; font-weight: 500; font-size: 15px; display: flex; align-items: center; gap: 10px; }
.phone-bar::before { content: ""; width: 9px; height: 9px; border-radius: 50%; background: #25d366; box-shadow: 0 0 0 0 rgba(37, 211, 102, 0.6); animation: live 2s infinite; }
@keyframes live { 70% { box-shadow: 0 0 0 9px rgba(37, 211, 102, 0); } 100% { box-shadow: 0 0 0 0 rgba(37, 211, 102, 0); } }
.chat { padding: 18px 14px 22px; display: flex; flex-direction: column; gap: 10px; min-height: 340px; background: #0b100e; }
.msg { margin: 0; padding: 10px 14px; border-radius: 14px; max-width: 86%; font-size: 15px; line-height: 1.45; }
.msg.in { align-self: flex-end; background: #005c4b; border-bottom-right-radius: 4px; }
.msg.out { align-self: flex-start; background: #202c33; border-bottom-left-radius: 4px; }
.js .msg { opacity: 0; }
.js .play .msg { animation: pop 0.45s ease-out forwards; animation-delay: calc(0.4s + var(--i) * 1.7s); }
@keyframes pop { from { opacity: 0; transform: translateY(8px) scale(0.97); } to { opacity: 1; transform: none; } }

/* Бегущая строка инструментов */
.tools { border-block: 1px solid var(--line); overflow: hidden; padding: 16px 0; margin-top: 10px; }
.tools-track { display: flex; gap: 40px; width: max-content; animation: slide 32s linear infinite; font-family: var(--head); text-transform: uppercase; font-size: 22px; letter-spacing: 0.06em; color: var(--muted); }
.tools-track span { white-space: nowrap; }
.tools-track span::after { content: "✦"; margin-left: 40px; color: var(--red); }
@keyframes slide { to { transform: translateX(-50%); } }

/* Разделы */
.block { padding: clamp(48px, 8vw, 104px) var(--gutter); }
.block > * { max-width: 1180px; margin-left: auto; margin-right: auto; }
.alt { background: var(--bg2); }
h2 { font-size: clamp(32px, 5vw, 60px); margin-top: 0; margin-bottom: 20px; }
h3 { margin: 0; font-size: 22px; font-weight: 600; }
.sub { color: var(--muted); max-width: 62ch; margin-bottom: 34px; }

/* Сотрудники: полосы, активная раскрывается */
.crew { list-style: none; padding: 0; margin: 0 auto; display: flex; gap: 10px; height: min(560px, 70vh); }
.crew li { flex: 1 1 0; min-width: 0; transition: flex 0.6s cubic-bezier(0.2, 0.8, 0.2, 1); position: relative; }
.crew li.on { flex: 6 1 0; }
.crew button { all: unset; box-sizing: border-box; cursor: pointer; display: block; width: 100%; height: 100%; border-radius: var(--radius); overflow: hidden; position: relative; background: hsl(var(--h) 55% 38%); }
.crew button:focus-visible { outline: 3px solid var(--gold); outline-offset: 3px; }
.art { position: absolute; inset: 0; filter: grayscale(1) brightness(0.55); transition: filter 0.6s; }
.on .art { filter: none; }
.art svg { width: 100%; height: 100%; object-fit: cover; }
.rail { position: absolute; left: 50%; bottom: 18px; transform: translateX(-50%) rotate(-90deg); transform-origin: center; font-family: var(--head); font-size: 22px; letter-spacing: 0.08em; text-transform: uppercase; white-space: nowrap; transition: opacity 0.3s; margin-left: -4px; }
.on .rail { opacity: 0; }
.info { position: absolute; left: 0; right: 0; bottom: 0; padding: 60px 22px 22px; background: linear-gradient(0deg, rgba(0, 0, 0, 0.88), rgba(0, 0, 0, 0)); opacity: 0; transform: translateY(14px); transition: opacity 0.4s 0.2s, transform 0.4s 0.2s; }
.on .info { opacity: 1; transform: none; }
.info b { font-family: var(--head); font-size: 34px; text-transform: uppercase; letter-spacing: 0.02em; display: block; line-height: 1.1; }
.info span { color: var(--gold); font-weight: 500; font-size: 15px; }
.info p { margin: 8px 0 0; color: #ddd; font-size: 16px; max-width: 46ch; }
.crew-hint { color: var(--muted); font-size: 14px; margin: 14px auto 0; }

/* Услуги */
.svc { display: grid; grid-template-columns: minmax(0, 0.8fr) minmax(0, 2fr); gap: 20px 48px; padding: 32px 0; border-top: 1px solid var(--line); }
.svc-head h3 { font-family: var(--head); text-transform: uppercase; font-size: 30px; font-weight: 600; }
.svc-head p { margin: 6px 0 0; color: var(--red); font-size: 15px; font-weight: 500; }
.svc-list { margin: 0; display: grid; gap: 22px; }
.svc-list div { display: grid; gap: 2px; padding-left: 18px; border-left: 3px solid transparent; transition: border-color 0.2s, transform 0.2s; }
.svc-list div:hover { border-left-color: var(--red); transform: translateX(4px); }
dt { font-weight: 600; font-size: 19px; }
dd { margin: 0; color: var(--muted); max-width: 62ch; }

/* Образование */
.edu { padding-left: 0; list-style: none; display: grid; gap: 14px; margin-bottom: 30px; max-width: 760px; }
.edu li { padding-left: 26px; position: relative; }
.edu li::before { content: ""; position: absolute; left: 0; top: 0.6em; width: 10px; height: 10px; background: var(--red); transform: rotate(45deg); }

/* Шаги */
.how { counter-reset: step; list-style: none; padding: 0; margin: 0 auto; display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 26px; }
.how li { counter-increment: step; border-top: 3px solid var(--red); padding-top: 16px; }
.how li::before { content: counter(step); display: block; font-family: var(--head); font-size: 44px; color: var(--red); line-height: 1; margin-bottom: 6px; }
.how p { margin: 6px 0 0; color: var(--muted); font-size: 16px; }

.contact { text-align: left; background: radial-gradient(ellipse at 80% 0, rgba(255, 75, 62, 0.22), transparent 60%), var(--bg2); }
.note { margin: 0; color: var(--muted); max-width: 46ch; }
.foot { display: flex; flex-wrap: wrap; gap: 12px 28px; justify-content: space-between; padding: 24px var(--gutter); font-size: 14px; color: var(--muted); border-top: 1px solid var(--line); }

/* Появление разделов при прокрутке: один спокойный приём для заголовков */
.js .block h2 { opacity: 0; transform: translateY(24px); transition: opacity 0.7s, transform 0.7s cubic-bezier(0.2, 0.8, 0.2, 1); }
.js .block h2.seen { opacity: 1; transform: none; }

@media (max-width: 860px) {
  .top { gap: 12px; }
  .top nav { display: none; }
  .hero { grid-template-columns: 1fr; }
  .svc { grid-template-columns: 1fr; gap: 14px; }
  .btn { width: 100%; }
  .crew { flex-direction: column; height: auto; }
  .crew li { flex: none; height: 76px; transition: height 0.5s cubic-bezier(0.2, 0.8, 0.2, 1); }
  .crew li.on { height: 420px; }
  .rail { transform: none; left: 20px; bottom: auto; top: 50%; margin-top: -14px; }
  .art svg { object-position: right center; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .reveal span, .js .msg, .js .play .msg, .js .block h2 { animation: none; opacity: 1; transform: none; transition: none; }
  .tools-track, .logo, .phone-bar::before { animation: none; }
  .crew li, .art, .info { transition: none; }
}

@media (max-width: 860px) {
  .crew li:not(.on) .art { opacity: 0.22; }
  .art { transition: filter 0.6s, opacity 0.6s; }
}
