/* VoIP Guru — component styles. Every value comes from tokens.css (var(--…)). */

.vg, .vg * { box-sizing: border-box; }
.vg { background: var(--surface-000); color: var(--ink-100); font-family: var(--font-sans); font-size: 16px; line-height: 26px; -webkit-font-smoothing: antialiased; }
:where(.vg) a { color: inherit; }
.vg :focus-visible { outline: 2px solid var(--focus); outline-offset: 3px; border-radius: 4px; }
.vg-container { width: 100%; max-width: calc(var(--container) + var(--gutter) * 2); margin: 0 auto; padding: 0 var(--gutter); }
.vg-label { font-family: var(--font-mono); font-size: 12px; line-height: 16px; letter-spacing: 0.14em; text-transform: uppercase; color: var(--ink-300); }
.vg-sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* ---------- Button ---------- */
.vg-btn { --mx: 50%; --my: 50%; position: relative; display: inline-flex; align-items: center; justify-content: center; gap: var(--space-3); height: 48px; padding: 0 var(--space-6); border-radius: var(--radius-pill); border: 1px solid transparent; font-family: var(--font-sans); font-size: 15px; line-height: 20px; font-weight: 600; letter-spacing: 0.01em; text-decoration: none; white-space: nowrap; cursor: pointer; isolation: isolate; overflow: hidden; background: none; color: inherit; transition: box-shadow var(--dur-base) var(--ease-out), border-color var(--dur-fast), background-color var(--dur-fast), color var(--dur-fast); -webkit-tap-highlight-color: transparent; }
.vg-btn.is-magnetic { transition: box-shadow var(--dur-base) var(--ease-out), border-color var(--dur-fast), background-color var(--dur-fast), color var(--dur-fast); will-change: transform; }
.vg-btn::before { content: ""; position: absolute; inset: 0; z-index: -1; border-radius: inherit; background: radial-gradient(90px circle at var(--mx) var(--my), var(--btn-light), transparent 72%); opacity: 0; transition: opacity var(--dur-base) var(--ease-out); }
.vg-btn:hover::before { opacity: 1; }
.vg-btn__label { position: relative; display: inline-flex; align-items: center; gap: var(--space-3); will-change: transform; }
.vg-btn--primary { background: var(--cta); color: var(--on-cta); --btn-light: rgba(255, 255, 255, 0.5); }
.vg-btn--primary:hover { box-shadow: var(--shadow-glow); }
.vg-btn--ghost { color: var(--ink-100); border-color: var(--line-300); --btn-light: var(--signal-soft); }
.vg-btn--ghost:hover { border-color: var(--signal-ink); }
.vg-btn--sm { height: 40px; padding: 0 var(--space-4); font-size: 14px; }
.vg-btn__arrow { display: inline-block; width: 1.1em; height: 1.1em; overflow: hidden; position: relative; }
.vg-btn__arrow i, .vg-link__arrow i { position: absolute; left: 0; top: 0; font-style: normal; line-height: 1.1em; transition: transform var(--dur-base) var(--ease-out); }
.vg-btn__arrow i + i, .vg-link__arrow i + i { transform: translateX(-120%); }
.vg-btn:hover .vg-btn__arrow i:first-child, .vg-link:hover .vg-link__arrow i:first-child { transform: translateX(120%); }
.vg-btn:hover .vg-btn__arrow i + i, .vg-link:hover .vg-link__arrow i + i { transform: translateX(0); }
.vg-ripple { position: absolute; z-index: -1; width: 12px; height: 12px; margin: -6px 0 0 -6px; border-radius: 50%; background: currentColor; opacity: 0.22; pointer-events: none; animation: vg-ripple 700ms var(--ease-out) forwards; }
@keyframes vg-ripple { to { transform: scale(40); opacity: 0; } }

/* text link with travelling arrow */
.vg-link { position: relative; display: inline-flex; align-items: center; gap: var(--space-2); font-size: 15px; line-height: 20px; font-weight: 600; color: var(--signal-ink); text-decoration: none; padding: 2px 0; }
.vg-link::after { content: ""; position: absolute; left: 0; right: 0; bottom: -2px; height: 1px; background: currentColor; transform: scaleX(0); transform-origin: right; transition: transform var(--dur-base) var(--ease-out); }
.vg-link:hover::after { transform: scaleX(1); transform-origin: left; }
.vg-link__arrow { position: relative; display: inline-block; width: 1.1em; height: 1.1em; overflow: hidden; }

/* ---------- Scramble ---------- */
[data-scramble] { display: inline-block; white-space: nowrap; }
.vg-scr { color: var(--signal-ink); font-family: var(--font-mono); font-weight: 400; }

/* ---------- Reveal ---------- */
[data-reveal] { opacity: 0; translate: 0 18px; transition: opacity var(--dur-slow) var(--ease-out) var(--d, 0ms), translate var(--dur-slow) var(--ease-out) var(--d, 0ms), transform var(--dur-base) var(--ease-out), box-shadow var(--dur-base); }
[data-reveal].is-in { opacity: 1; translate: none; }
.vg-w { display: inline-block; overflow: hidden; vertical-align: top; padding-bottom: 0.08em; margin-bottom: -0.08em; }
.vg-w > span { display: inline-block; transform: translateY(105%); transition: transform var(--dur-slow) var(--ease-out); transition-delay: var(--d, 0ms); }
.is-in .vg-w > span, .vg-w.is-in > span { transform: none; }

/* ---------- Logo (type only: no mark was supplied) ---------- */
.vg-logo { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; color: var(--ink-100); }
.vg-logo__mono { position: relative; display: inline-grid; place-items: center; width: 32px; height: 32px; border: 1px solid var(--line-300); border-radius: var(--radius-xs); font-family: var(--font-mono); font-weight: 700; font-size: 12px; letter-spacing: 0.02em; }
.vg-logo__mono::after { content: ""; position: absolute; right: -3px; top: -3px; width: 6px; height: 6px; border-radius: 50%; background: var(--signal); box-shadow: 0 0 0 3px var(--surface-000); animation: vg-blink 4s steps(1) infinite; }
.vg-logo__name { font-family: var(--font-display); font-weight: 500; font-size: 18px; line-height: 20px; letter-spacing: 0.01em; }
@keyframes vg-blink { 0%, 92% { opacity: 1; } 94% { opacity: 0.2; } 96% { opacity: 1; } 98% { opacity: 0.2; } }

/* ---------- Header ---------- */
.vg-header { position: relative; z-index: 10; height: var(--header-h); border-bottom: 1px solid transparent; transition: height var(--dur-base) var(--ease-out), background-color var(--dur-base), border-color var(--dur-base); }
.vg-header.is-scrolled { height: 60px; background: var(--surface-glass); border-bottom-color: var(--line-100); -webkit-backdrop-filter: blur(14px) saturate(140%); backdrop-filter: blur(14px) saturate(140%); }
.vg-header__in { height: 100%; display: flex; align-items: center; gap: var(--space-8); }
.vg-header__progress { position: absolute; left: 0; bottom: -1px; height: 1px; width: 100%; background: var(--signal); transform-origin: left; transform: scaleX(var(--progress, 0)); opacity: 0; transition: opacity var(--dur-base); }
.vg-header.is-scrolled .vg-header__progress { opacity: 1; }
.vg-nav { position: relative; display: flex; gap: var(--space-1); margin: 0 auto 0 var(--space-6); padding: 0; list-style: none; }
.vg-nav a { display: block; white-space: nowrap; padding: 10px 9px; font-size: 14px; line-height: 20px; font-weight: 500; color: var(--ink-200); text-decoration: none; transition: color var(--dur-fast); }
.vg-nav a:hover, .vg-nav a[aria-current] { color: var(--ink-100); }
.vg-nav__ind { position: absolute; bottom: 2px; left: 0; width: 4px; height: 4px; border-radius: 50%; background: var(--signal); transition: transform var(--dur-base) var(--ease-spring), opacity var(--dur-fast); pointer-events: none; }
.vg-header__actions { display: flex; align-items: center; gap: var(--space-4); }
.vg-lang { position: relative; }
.vg-lang__btn { display: inline-flex; align-items: center; gap: 6px; height: 40px; padding: 0 12px; border: 1px solid var(--line-300); border-radius: var(--radius-pill); background: none; color: var(--ink-100); font-family: var(--font-mono); font-size: 12px; letter-spacing: 0.1em; cursor: pointer; }
.vg-lang__btn svg { transition: transform var(--dur-base) var(--ease-out); }
.vg-lang__btn[aria-expanded="true"] svg { transform: rotate(180deg); }
.vg-lang__list { position: absolute; right: 0; top: calc(100% + 8px); min-width: 168px; margin: 0; padding: 6px; list-style: none; background: var(--surface-100); border: 1px solid var(--line-200); border-radius: var(--radius-md); box-shadow: var(--shadow-card); opacity: 0; transform: translateY(-6px) scale(0.98); transform-origin: top right; pointer-events: none; transition: opacity var(--dur-fast), transform var(--dur-base) var(--ease-out); }
.vg-lang__btn[aria-expanded="true"] + .vg-lang__list { opacity: 1; transform: none; pointer-events: auto; }
.vg-lang__list button { display: flex; justify-content: space-between; width: 100%; padding: 8px 10px; border: 0; border-radius: var(--radius-sm); background: none; color: var(--ink-200); font: 500 14px/20px var(--font-sans); text-align: left; cursor: pointer; }
.vg-lang__list button:hover, .vg-lang__list button[aria-selected="true"] { background: var(--surface-200); color: var(--ink-100); }
.vg-lang__list button span { font-family: var(--font-mono); font-size: 11px; color: var(--ink-300); letter-spacing: 0.1em; }

/* ---------- Backgrounds ---------- */
.vg-bg { position: absolute; inset: 0; overflow: hidden; pointer-events: none; -webkit-mask-image: radial-gradient(120% 90% at 70% 40%, #000 35%, transparent 85%); mask-image: radial-gradient(120% 90% at 70% 40%, #000 35%, transparent 85%); }
.vg-bg canvas { position: absolute; inset: 0; width: 100%; height: 100%; display: block; }
.vg-bg--full { -webkit-mask-image: none; mask-image: none; }

/* ---------- Hero ---------- */
.vg-hero { position: relative; overflow: hidden; padding: var(--space-32) 0 var(--space-24); min-height: 640px; }
.vg-hero__in { position: relative; z-index: 1; }
.vg-hero__eyebrow { display: inline-flex; align-items: center; gap: 10px; margin: 0 0 var(--space-6); }
.vg-hero h1 { margin: 0; max-width: 940px; font-family: var(--font-display); font-weight: 500; font-size: 72px; line-height: 74px; letter-spacing: -0.02em; }
.vg-hero h1 em { font-style: normal; color: var(--signal-ink); }
.vg-hero__lead { max-width: 600px; margin: var(--space-6) 0 0; font-size: 20px; line-height: 32px; color: var(--ink-200); }
.vg-hero__cta { display: flex; flex-wrap: wrap; gap: var(--space-3); margin-top: var(--space-12); }
.vg-hud { position: absolute; z-index: 1; right: var(--gutter); bottom: var(--space-6); display: flex; gap: var(--space-4); font-family: var(--font-mono); font-size: 12px; line-height: 16px; letter-spacing: 0.08em; color: var(--ink-300); font-variant-numeric: tabular-nums; }
.vg-hud b { font-weight: 400; color: var(--ink-200); }
.vg-live { position: relative; display: inline-block; width: 8px; height: 8px; border-radius: 50%; background: var(--signal); }
.vg-live::after { content: ""; position: absolute; inset: -4px; border-radius: 50%; border: 1px solid var(--signal); opacity: 0; animation: vg-ping 2.4s var(--ease-out) infinite; }
.vg-live--pulse { background: var(--pulse); }
.vg-live--pulse::after { border-color: var(--pulse); }
@keyframes vg-ping { 0% { transform: scale(0.6); opacity: 0.9; } 80%, 100% { transform: scale(1.8); opacity: 0; } }

/* ---------- Ticker ---------- */
.vg-ticker { position: relative; overflow: hidden; border-block: 1px solid var(--line-100); -webkit-mask-image: linear-gradient(90deg, transparent, #000 10%, #000 90%, transparent); mask-image: linear-gradient(90deg, transparent, #000 10%, #000 90%, transparent); }
.vg-ticker__track { display: flex; width: max-content; margin: 0; padding: 0; list-style: none; will-change: transform; }
.vg-ticker__item { display: inline-flex; align-items: center; gap: var(--space-6); padding: 22px var(--space-6) 22px 0; font-family: var(--font-mono); font-size: 13px; line-height: 16px; letter-spacing: 0.14em; text-transform: uppercase; color: var(--ink-200); white-space: nowrap; transition: color var(--dur-fast); }
.vg-ticker__item::before { content: ""; width: 6px; height: 6px; background: var(--line-300); transform: rotate(45deg); transition: background-color var(--dur-fast), transform var(--dur-base) var(--ease-spring); }
.vg-ticker__item:hover { color: var(--ink-100); }
.vg-ticker__item:hover::before { background: var(--signal); transform: rotate(225deg) scale(1.3); }

/* ---------- Section heading ---------- */
.vg-section { position: relative; padding: var(--space-24) 0; }
.vg-section + .vg-section::before { content: ""; position: absolute; top: 0; left: max(var(--gutter), calc(50% - var(--container) / 2)); right: max(var(--gutter), calc(50% - var(--container) / 2)); height: 1px; background: var(--line-100); }
.vg-cross { position: absolute; top: -6px; width: 11px; height: 11px; color: var(--line-300); }
.vg-cross::before, .vg-cross::after { content: ""; position: absolute; background: currentColor; }
.vg-cross::before { left: 5px; top: 0; width: 1px; height: 11px; }
.vg-cross::after { top: 5px; left: 0; height: 1px; width: 11px; }
.vg-sechead { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 420px); gap: var(--space-8); align-items: end; margin-bottom: var(--space-12); }
.vg-sechead__eyebrow { display: flex; align-items: center; gap: 10px; margin: 0 0 var(--space-4); }
.vg-sechead__eyebrow::before { content: "//"; color: var(--signal-ink); letter-spacing: 0; }
.vg-sechead h2 { margin: 0; font-family: var(--font-display); font-weight: 500; font-size: 48px; line-height: 52px; letter-spacing: -0.015em; }
.vg-sechead p { margin: 0; color: var(--ink-200); font-size: 16px; line-height: 26px; }

/* ---------- Spotlight surface (cards) ---------- */
.vg-spot { --mx: -1000px; --my: -1000px; --spot-o: 0; position: relative; }
.vg-spot::before { content: ""; position: absolute; inset: 0; border-radius: inherit; padding: 1px; pointer-events: none; background: radial-gradient(calc(var(--spotlight) * 0.6) circle at var(--mx) var(--my), var(--signal), transparent 70%); -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0); -webkit-mask-composite: xor; mask: linear-gradient(#000 0 0) content-box exclude, linear-gradient(#000 0 0); opacity: var(--spot-o); transition: opacity var(--dur-base); }
.vg-spot::after { content: ""; position: absolute; inset: 0; border-radius: inherit; pointer-events: none; background: radial-gradient(var(--spotlight) circle at var(--mx) var(--my), var(--signal-soft), transparent 60%); opacity: 0; transition: opacity var(--dur-base); }
.vg-spot:hover::after { opacity: 1; }

/* ---------- Product card ---------- */
.vg-cards { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--space-6); }
.vg-card { display: flex; flex-direction: column; gap: var(--space-4); padding: var(--space-8); background: var(--surface-100); border: 1px solid var(--line-100); border-radius: var(--radius-lg); transform: perspective(900px) rotateX(var(--rx, 0deg)) rotateY(var(--ry, 0deg)); transition: transform var(--dur-base) var(--ease-out), box-shadow var(--dur-base), opacity var(--dur-slow) var(--ease-out) var(--d, 0ms), translate var(--dur-slow) var(--ease-out) var(--d, 0ms); }
.vg-card:hover { box-shadow: var(--shadow-card); }
.vg-card__media { margin: calc(var(--space-8) * -1 + var(--space-3)) calc(var(--space-8) * -1 + var(--space-3)) 0; border: 1px solid var(--line-100); border-radius: calc(var(--radius-lg) - var(--space-3) + 2px); overflow: hidden; background: #13171a; aspect-ratio: 800 / 498; }
.vg-card__media img { display: block; width: 100%; height: 100%; object-fit: cover; transition: transform var(--dur-slow) var(--ease-out); }
.vg-card:hover .vg-card__media img { transform: scale(1.03); }
.vg-card__top {display: flex; align-items: center; justify-content: space-between; margin-bottom: var(--space-4); }
.vg-tile { display: grid; place-items: center; width: 48px; height: 48px; border-radius: var(--radius-sm); background: var(--surface-200); color: var(--ink-100); transition: color var(--dur-fast), background-color var(--dur-fast); }
.vg-card:hover .vg-tile, .vg-ai:hover .vg-tile { color: var(--signal-ink); }
.vg-card h3, .vg-ai h3 { margin: 0; font-family: var(--font-display); font-weight: 500; font-size: 26px; line-height: 30px; letter-spacing: -0.01em; }
.vg-card p, .vg-ai p { margin: 0; color: var(--ink-200); font-size: 16px; line-height: 26px; }
.vg-chips { display: flex; flex-wrap: wrap; gap: var(--space-2); margin: auto 0 0; padding: var(--space-2) 0 0; list-style: none; }
.vg-chips li { padding: 4px 10px; border: 1px solid var(--line-200); border-radius: var(--radius-pill); font-family: var(--font-mono); font-size: 11px; line-height: 16px; letter-spacing: 0.06em; color: var(--ink-200); transition: border-color var(--dur-fast), color var(--dur-fast); }
.vg-card:hover .vg-chips li { border-color: var(--line-300); color: var(--ink-100); }
.vg-card .vg-link { margin-top: var(--space-2); align-self: flex-start; }

/* icon micro-animations: strokes redraw on hover */
.vg-ic { width: 24px; height: 24px; fill: none; stroke: currentColor; stroke-width: 1.5; stroke-linecap: round; stroke-linejoin: round; overflow: visible; }
.vg-ic .a { stroke-dasharray: 40; stroke-dashoffset: 0; }
:hover > * > .vg-tile .vg-ic .a, :hover > .vg-tile .vg-ic .a { animation: vg-draw 900ms var(--ease-out); }
.vg-ic .a2 { animation-delay: 120ms !important; }
@keyframes vg-draw { from { stroke-dashoffset: 40; } to { stroke-dashoffset: 0; } }

/* ---------- Process ---------- */
.vg-steps { position: relative; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: var(--space-6); margin: 0; padding: 0; list-style: none; counter-reset: step; }
.vg-steps__track { position: absolute; left: 0; right: 0; top: 83px; height: 1px; background: var(--line-200); }
.vg-steps__fill { position: absolute; inset: 0; background: var(--signal); transform-origin: left; transform: scaleX(var(--fill, 0)); transition: transform 900ms var(--ease-out); }
.vg-steps__packet { position: absolute; top: -2px; left: 0; width: 28px; height: 5px; border-radius: 3px; background: linear-gradient(90deg, transparent, var(--signal)); opacity: 0; }
.vg-steps.is-done .vg-steps__packet { opacity: 1; animation: vg-run 3.2s linear infinite; }
@keyframes vg-run { from { left: 0; } to { left: calc(100% - 28px); } }
.vg-step { position: relative; padding-right: var(--space-4); }
.vg-step__num { display: block; height: 56px; font-family: var(--font-mono); font-size: 56px; line-height: 56px; letter-spacing: -0.04em; color: var(--line-300); transition: color var(--dur-slow) var(--ease-out); font-variant-numeric: tabular-nums; }
.vg-step.is-on .vg-step__num { color: var(--ink-100); }
.vg-step__node { position: relative; display: block; width: 11px; height: 11px; margin: 22px 0 var(--space-6); border-radius: 50%; border: 1px solid var(--line-300); background: var(--surface-000); transition: border-color var(--dur-base), background-color var(--dur-base); }
.vg-step.is-on .vg-step__node { border-color: var(--signal); background: var(--signal); }
.vg-step__node::after { content: ""; position: absolute; inset: -6px; border-radius: 50%; border: 1px solid var(--signal); opacity: 0; transform: scale(0.6); transition: opacity var(--dur-base), transform var(--dur-base) var(--ease-spring); }
.vg-step:hover .vg-step__node::after { opacity: 1; transform: none; }
.vg-step h3 { margin: 0 0 var(--space-3); font-family: var(--font-display); font-weight: 500; font-size: 20px; line-height: 24px; }
.vg-step p { margin: 0; color: var(--ink-200); font-size: 15px; line-height: 24px; }
/* о нас: схема направлений во всю ширину, под ней история в две колонки */
.vg-about { display: grid; gap: var(--space-8); }
.vg-about__figure { margin: 0; overflow: hidden; border: 1px solid var(--line-100); border-radius: var(--radius-lg); background: #03070f; aspect-ratio: 1200 / 746; }
.vg-about__figure img { display: block; width: 100%; height: 100%; object-fit: cover; }
.vg-about__prose { columns: 2; column-gap: var(--space-12); }
.vg-about__prose p { margin: 0 0 var(--space-6); break-inside: avoid; color: var(--ink-200); font-size: 16px; line-height: 26px; }
.vg-about__prose p:first-child { color: var(--ink-100); font-size: 18px; line-height: 28px; }
/* якорь не должен уезжать под закреплённую шапку */
.vg-section[id], .vg-footer[id] { scroll-margin-top: var(--header-h, 72px); }
@media (max-width: 860px) {
  .vg-about { gap: var(--space-6); }
  .vg-about__prose { columns: 1; }
  .vg-about__figure { border-radius: var(--radius-md); }
}
/* печать текста: недопечатанное место занято, но невидимо; курсор мигает только пока идёт набор */
.vg-untyped { visibility: hidden; }
.vg-caret { display: none; }
.is-typing > .vg-caret { display: inline-block; width: 2px; height: 1em; margin: 0 1px -0.12em; background: var(--signal); animation: vg-caret 0.8s steps(1) infinite; }
@keyframes vg-caret { 50% { opacity: 0; } }

/* ---------- AI product card ---------- */
.vg-ai { display: flex; flex-direction: column; background: var(--surface-100); border: 1px solid var(--line-100); border-radius: var(--radius-lg); overflow: hidden; transition: box-shadow var(--dur-base), opacity var(--dur-slow) var(--ease-out) var(--d, 0ms), translate var(--dur-slow) var(--ease-out) var(--d, 0ms); }
.vg-ai:hover { box-shadow: var(--shadow-card); }
.vg-ai__screen { position: relative; height: 176px; margin: var(--space-2); border-radius: calc(var(--radius-lg) - 6px); background: var(--surface-200); overflow: hidden; }
.vg-ai__screen::before { content: ""; position: absolute; inset: 0; background-image: radial-gradient(var(--dot) 1px, transparent 1.4px); background-size: 14px 14px; opacity: 0.8; }
.vg-ai__body { display: flex; flex: 1; flex-direction: column; gap: var(--space-3); padding: var(--space-6) var(--space-8) var(--space-8); }
.vg-ai__head { display: flex; align-items: center; gap: var(--space-3); }
.vg-ai__head .vg-tile { width: 40px; height: 40px; }
.vg-ai .vg-link { margin-top: auto; padding-top: var(--space-4); align-self: flex-start; }
.vg-ai .vg-link::after { bottom: -2px; }

/* demo screens: pure CSS loops, built by VG.demo() */
.vg-demo { position: absolute; inset: 18px; display: flex; flex-direction: column; gap: 10px; }
.vg-sk { height: 6px; border-radius: 3px; background: var(--line-200); }
.vg-sk--on { background: var(--signal); }
.vg-wave { display: flex; align-items: center; gap: 3px; height: 54px; position: relative; }
.vg-wave i { flex: 1; height: var(--h); border-radius: 2px; background: var(--line-300); animation: vg-bar-on 6s linear infinite; animation-delay: var(--t); }
@keyframes vg-bar-on { 0% { background: var(--line-300); } 2%, 88% { background: var(--signal); } 92%, 100% { background: var(--line-300); } }
.vg-wave::after { content: ""; position: absolute; top: -4px; bottom: -4px; left: 0; width: 1px; background: var(--ink-100); animation: vg-playhead 6s linear infinite; }
@keyframes vg-playhead { 0% { left: 0; opacity: 1; } 75% { left: 100%; opacity: 1; } 76%, 100% { left: 100%; opacity: 0; } }
.vg-type { transform-origin: left; animation: vg-type 6s var(--ease-out) infinite; animation-delay: var(--t); transform: scaleX(0); }
@keyframes vg-type { 0% { transform: scaleX(0); } 12%, 88% { transform: scaleX(1); } 96%, 100% { transform: scaleX(0); } }
.vg-qm { display: grid; grid-template-columns: 1fr auto; gap: 14px; align-items: center; height: 100%; }
.vg-qm__rows { display: flex; flex-direction: column; gap: 13px; }
.vg-qm__row { display: grid; grid-template-columns: 1fr auto; gap: 12px; align-items: center; }
.vg-qm__dots { display: flex; gap: 4px; }
.vg-qm__dots b { width: 8px; height: 8px; border-radius: 2px; background: var(--line-200); animation: vg-dot-on 6s steps(1) infinite; animation-delay: var(--t); }
@keyframes vg-dot-on { 0% { background: var(--line-200); } 1%, 90% { background: var(--signal); } }
.vg-qm__dots b.off { animation: none; }
.vg-ring { width: 92px; height: 92px; transform: rotate(-90deg); }
.vg-ring circle { fill: none; stroke-width: 6; }
.vg-ring .bg { stroke: var(--line-200); }
.vg-ring .fg { stroke: var(--signal); stroke-linecap: round; stroke-dasharray: 239; stroke-dashoffset: 239; animation: vg-ring 6s var(--ease-out) infinite; }
@keyframes vg-ring { 0%, 8% { stroke-dashoffset: 239; } 60%, 90% { stroke-dashoffset: 52; } 100% { stroke-dashoffset: 239; } }
.vg-msg { display: flex; align-items: center; gap: 8px; opacity: 0; animation: vg-msg 6s var(--ease-out) infinite; animation-delay: var(--t); }
.vg-msg b { flex: none; display: grid; place-items: center; width: 20px; height: 20px; border-radius: 50%; background: var(--line-200); font: 700 10px/1 var(--font-mono); color: var(--ink-100); }
.vg-msg .vg-sk { flex: 0 1 var(--w); height: 14px; border-radius: 7px; }
.vg-msg--task b { border-radius: var(--radius-xs); background: none; border: 1px solid var(--line-300); color: transparent; }
.vg-msg--task b::after { content: ""; width: 8px; height: 4px; border-left: 1.5px solid var(--on-cta); border-bottom: 1.5px solid var(--on-cta); transform: rotate(-45deg) translate(1px, -1px); }
.vg-msg--task b { animation: vg-check 6s steps(1) infinite; }
@keyframes vg-check { 0%, 70% { background: none; border-color: var(--line-300); } 71%, 100% { background: var(--cta); border-color: var(--cta); } }
@keyframes vg-msg { 0% { opacity: 0; transform: translateY(6px); } 6%, 90% { opacity: 1; transform: none; } 100% { opacity: 0; } }
.vg-msg--task .vg-sk { background: var(--signal-soft); border: 1px solid var(--signal); }

/* ---------- Notice ---------- */
.vg-notice { display: flex; align-items: center; gap: var(--space-4); margin-top: var(--space-6); padding: var(--space-4) var(--space-4) var(--space-4) var(--space-6); background: var(--surface-100); border: 1px solid var(--line-200); border-radius: var(--radius-md); background-image: linear-gradient(90deg, var(--pulse-soft), transparent 40%); }
.vg-notice p { flex: 1; margin: 0; font-size: 14px; line-height: 22px; color: var(--ink-100); }

/* ---------- Footer ---------- */
.vg-footer { position: relative; padding: var(--space-24) 0 var(--space-8); border-top: 1px solid var(--line-100); overflow: hidden; }
.vg-footer__grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1.2fr; gap: var(--space-8); }
.vg-footer__brand p { max-width: 300px; margin: var(--space-4) 0 0; color: var(--ink-200); font-size: 14px; line-height: 22px; }
.vg-footer h4 { margin: 0 0 var(--space-4); font-family: var(--font-mono); font-weight: 400; font-size: 12px; line-height: 16px; letter-spacing: 0.14em; text-transform: uppercase; color: var(--ink-300); }
.vg-footer ul { margin: 0; padding: 0; list-style: none; display: grid; gap: 10px; }
.vg-footer ul a { color: var(--ink-200); font-size: 14px; line-height: 22px; text-decoration: none; transition: color var(--dur-fast); }
.vg-footer ul a:hover { color: var(--ink-100); }
.vg-contact { display: inline-flex; align-items: center; gap: 8px; padding: 0; border: 0; background: none; color: var(--ink-100); font-family: var(--font-mono); font-size: 13px; line-height: 20px; letter-spacing: 0.02em; text-decoration: none; cursor: pointer; }
.vg-contact small { font-size: 11px; color: var(--ink-300); letter-spacing: 0.08em; text-transform: uppercase; transition: color var(--dur-fast); }
.vg-contact:hover small { color: var(--signal-ink); }
.vg-footer__word { --mx: -1000px; --my: -1000px; position: relative; margin: var(--space-16) 0 var(--space-6); font-family: var(--font-display); font-weight: 500; font-size: clamp(64px, 15.5vw, 212px); line-height: 0.82; letter-spacing: -0.03em; white-space: nowrap; color: transparent; -webkit-text-stroke: 1px var(--line-200); user-select: none; }
.vg-footer__word span { position: absolute; inset: 0; color: transparent; -webkit-text-stroke: 0; background: radial-gradient(260px circle at var(--mx) var(--my), var(--signal), transparent 70%); -webkit-background-clip: text; background-clip: text; }
.vg-footer__bottom { display: flex; justify-content: space-between; align-items: center; gap: var(--space-4); padding-top: var(--space-6); border-top: 1px solid var(--line-100); color: var(--ink-300); font-size: 13px; line-height: 20px; }
.vg-top { display: inline-flex; align-items: center; gap: 8px; padding: 0; border: 0; background: none; color: var(--ink-200); font-family: var(--font-mono); font-size: 12px; letter-spacing: 0.1em; text-transform: uppercase; cursor: pointer; }
.vg-top i { font-style: normal; display: inline-block; transition: transform var(--dur-base) var(--ease-spring); }
.vg-top:hover i { transform: translateY(-3px); }

/* ---------- Background switcher (showcase only) ---------- */
.vg-switch { display: inline-flex; padding: 4px; gap: 2px; border: 1px solid var(--line-200); border-radius: var(--radius-pill); background: var(--surface-glass); -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px); }
.vg-switch button { height: 32px; padding: 0 14px; border: 0; border-radius: var(--radius-pill); background: none; color: var(--ink-200); font: 500 13px/1 var(--font-sans); cursor: pointer; transition: background-color var(--dur-fast), color var(--dur-fast); }
.vg-switch button[aria-pressed="true"] { background: var(--cta); color: var(--on-cta); }

/* ---------- Responsive ---------- */
@media (max-width: 1024px) {
  .vg-cards { grid-template-columns: 1fr 1fr; }
  .vg-steps { grid-template-columns: 1fr 1fr; row-gap: var(--space-12); }
  .vg-steps__track { display: none; }
  .vg-footer__grid { grid-template-columns: 1fr 1fr; }
  .vg-nav { display: none; }
  .vg-header__actions { margin-left: auto; } /* раньше вправо отталкивало меню */
}
@media (max-width: 768px) {
  .vg-container { padding: 0 var(--space-4); }
  .vg-hero { padding: var(--space-24) 0 var(--space-16); min-height: 0; }
  /* от ширины экрана: самое длинное слово («Интеллектуальные», «Telecomunicaciones») влезает от 320px */
  .vg-hero h1 { font-size: clamp(28px, 9.2vw, 40px); line-height: 1.1; -webkit-hyphens: auto; hyphens: auto; overflow-wrap: break-word; }
  .vg-hero__lead { font-size: 17px; line-height: 28px; }
  .vg-sechead { grid-template-columns: 1fr; }
  .vg-sechead h2 { font-size: 32px; line-height: 36px; }
  .vg-section { padding: var(--space-16) 0; }
  .vg-cards, .vg-steps, .vg-footer__grid { grid-template-columns: 1fr; }
  /* меню скрыто с 1024px — на телефоне в шапке остаётся «Кабинет» (единственный вход в /app/),
     а «Связаться» дублирует «Заказать звонок» первого экрана */
  .vg-hud, .vg-header__actions .vg-btn--primary { display: none; }
  .vg-header__in { gap: var(--space-4); }
  .vg-header__actions { gap: var(--space-2); }
  .vg-logo__name { white-space: nowrap; }
  .vg-notice { flex-wrap: wrap; }
}
@media (max-width: 380px) {
  .vg-header .vg-logo__name { display: none; }
}

/* ---------- Reduced motion: everything still reads, nothing travels ---------- */
@media (prefers-reduced-motion: reduce) {
  .vg *, .vg *::before, .vg *::after { animation-duration: 1ms !important; animation-iteration-count: 1 !important; transition-duration: 1ms !important; }
  [data-reveal] { opacity: 1; translate: none; }
  .vg-w > span { transform: none; }
  .vg-type { transform: none; }
  .vg-msg { opacity: 1; }
}
