/* Страница скачивания Voices. Палитра — из веб-клиента (voices_web_v2, src/styles/_vars.scss). */

:root {
    --background: #121214;
    --panel: #1a1a1e;
    --interact: #222327;
    --surface: #242429;
    --border: #2e2e33;
    --text: #efeff1;
    --text-subtle: #abacb2;
    --text-muted: #96979e;
    --accent: #5865f2;
    --accent-hover: #4452bb;
    --success: #3d9e60;
    --error: #da3e44;
    --brand: linear-gradient(135deg, #8b5cf6 0%, #5865f2 55%, #22b8f0 100%);
    --radius: 12px;
    --ease: cubic-bezier(0.2, 0.8, 0.2, 1);
    color-scheme: dark;
}

* {
    box-sizing: border-box;
}

html {
    background: var(--background);
}

body {
    margin: 0;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    font-family: 'Noto Sans', system-ui, -apple-system, 'Segoe UI', sans-serif;
    font-size: 16px;
    line-height: 1.5;
    color: var(--text);
    /* Мягкое свечение бренда сверху — как фон у окна логина. */
    background:
        radial-gradient(60rem 30rem at 70% -10%, rgba(88, 101, 242, 0.22), transparent 70%),
        radial-gradient(40rem 24rem at 10% 10%, rgba(139, 92, 246, 0.12), transparent 70%),
        var(--background);
}

a {
    color: inherit;
}

main {
    flex: 1;
    width: 100%;
    max-width: 1160px;
    margin: 0 auto;
    padding: 0 24px;
}

/* --- Шапка --- */

.top {
    width: 100%;
    max-width: 1160px;
    margin: 0 auto;
    padding: 20px 24px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.brand {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    font-weight: 700;
    font-size: 18px;
    text-decoration: none;
}

.top__link {
    color: var(--text-subtle);
    font-size: 14px;
    font-weight: 500;
    text-decoration: none;
    padding: 8px 14px;
    border-radius: 999px;
    transition: background-color 0.18s var(--ease), color 0.18s var(--ease);
}

.top__link:hover {
    color: var(--text);
    background: rgba(149, 149, 162, 0.16);
}

/* --- Первый экран --- */

.hero {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1.1fr);
    gap: 56px;
    align-items: center;
    padding: 48px 0 88px;
}

.eyebrow {
    margin: 0 0 12px;
    font-size: 13px;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: #7487f8;
}

h1 {
    margin: 0;
    font-size: clamp(36px, 5vw, 56px);
    line-height: 1.08;
    letter-spacing: -0.02em;
}

.lead {
    margin: 20px 0 32px;
    max-width: 30em;
    font-size: 18px;
    color: var(--text-subtle);
}

.hero__actions {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 10px;
}

.button {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    padding: 16px 28px;
    border-radius: 999px;
    font-size: 17px;
    font-weight: 700;
    text-decoration: none;
    color: #fff;
    background: var(--accent);
    box-shadow: 0 10px 30px rgba(88, 101, 242, 0.35);
    transition: background-color 0.18s var(--ease), transform 0.18s var(--ease), box-shadow 0.18s var(--ease);
}

.button svg {
    width: 20px;
    height: 20px;
    fill: currentColor;
}

.button:hover {
    background: var(--accent-hover);
    transform: translateY(-1px);
    box-shadow: 0 14px 36px rgba(88, 101, 242, 0.45);
}

.button:focus-visible,
.top__link:focus-visible,
.hero__alt a:focus-visible {
    outline: 2px solid #7487f8;
    outline-offset: 3px;
}

.button.is-disabled {
    background: var(--interact);
    color: var(--text-muted);
    box-shadow: none;
    cursor: default;
    transform: none;
}

.hero__meta {
    margin: 0;
    font-size: 13px;
    color: var(--text-muted);
}

.hero__alt {
    margin: 24px 0 0;
    font-size: 14px;
    color: var(--text-muted);
}

.hero__alt a {
    color: var(--text-subtle);
    text-underline-offset: 3px;
}

.hero__alt a:hover {
    color: var(--text);
}

.hero__alt .dot {
    margin: 0 8px;
    opacity: 0.5;
}

/* --- Макет окна --- */

.mock {
    position: relative;
    padding: 0 0 40px 0;
}

.mock__window {
    border-radius: 14px;
    overflow: hidden;
    background: var(--background);
    border: 1px solid var(--border);
    box-shadow: 0 30px 80px rgba(0, 0, 0, 0.55), 0 0 0 1px rgba(255, 255, 255, 0.02);
}

.mock__titlebar {
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 14px;
    padding: 0 14px;
    background: var(--background);
}

.mock__titlebar span {
    width: 10px;
    height: 2px;
    background: var(--text-muted);
    opacity: 0.6;
}

.mock__body {
    display: grid;
    grid-template-columns: 56px 150px 1fr;
    height: 330px;
}

.mock__rail {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    padding-top: 8px;
}

.mock__server {
    width: 38px;
    height: 38px;
    border-radius: 50%;
    background: var(--interact);
}

.mock__server.is-active {
    border-radius: 12px;
    background: var(--brand);
}

.mock__server.is-add {
    display: grid;
    place-items: center;
    font-style: normal;
    color: var(--success);
    font-size: 20px;
}

.mock__channels {
    padding: 12px 10px;
    background: var(--panel);
    border-top-left-radius: 10px;
    font-size: 12px;
    color: var(--text-muted);
}

.mock__channels b {
    display: block;
    margin-bottom: 10px;
    color: var(--text);
    font-size: 13px;
}

.mock__channels p {
    margin: 0 0 6px;
    padding: 3px 6px;
    border-radius: 6px;
}

.mock__channels .is-voice {
    color: var(--text);
    background: rgba(150, 150, 160, 0.2);
}

.mock__member {
    display: flex;
    align-items: center;
    gap: 6px;
    margin: 6px 0 0 14px;
}

.mock__member i {
    width: 16px;
    height: 16px;
    border-radius: 50%;
}

.mock__stage {
    position: relative;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
    padding: 10px 10px 56px;
    background: #0e0e10;
}

.mock__tile {
    position: relative;
    display: grid;
    place-items: center;
    border-radius: 10px;
    background: var(--interact);
}

.mock__tile i,
.mock__toast i {
    display: grid;
    place-items: center;
    width: 46px;
    height: 46px;
    border-radius: 50%;
    font-style: normal;
    font-weight: 700;
    color: #fff;
}

.mock__tile span {
    position: absolute;
    left: 8px;
    bottom: 6px;
    padding: 1px 6px;
    border-radius: 4px;
    font-size: 11px;
    background: rgba(0, 0, 0, 0.45);
}

/* Говорящий — зелёная обводка, как в звонке. */
.mock__tile.is-speaking {
    box-shadow: inset 0 0 0 2px var(--success);
}

.mock__tile.is-speaking i {
    animation: speak 1.6s var(--ease) infinite;
}

@keyframes speak {
    0%,
    100% {
        box-shadow: 0 0 0 0 rgba(61, 158, 96, 0.6);
    }
    50% {
        box-shadow: 0 0 0 6px rgba(61, 158, 96, 0);
    }
}

.mock__controls {
    position: absolute;
    left: 50%;
    bottom: 12px;
    transform: translateX(-50%);
    display: flex;
    gap: 8px;
}

.mock__controls i {
    width: 34px;
    height: 34px;
    border-radius: 50%;
    background: var(--surface);
}

.mock__controls .is-hangup {
    width: 48px;
    border-radius: 999px;
    background: var(--error);
}

.mock__toast {
    position: absolute;
    /* Слева внизу — под списком каналов пусто, кнопки звонка остаются видны. */
    left: -20px;
    bottom: 0;
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 18px 12px 12px;
    border-radius: var(--radius);
    background: var(--surface);
    border: 1px solid var(--border);
    box-shadow: 0 16px 40px rgba(0, 0, 0, 0.5);
    animation: toast-in 0.6s 0.4s var(--ease) both;
}

.mock__toast i {
    width: 36px;
    height: 36px;
    font-size: 14px;
}

.mock__toast b {
    display: block;
    font-size: 14px;
}

.mock__toast span {
    font-size: 13px;
    color: var(--text-subtle);
}

@keyframes toast-in {
    from {
        opacity: 0;
        transform: translateY(12px);
    }
}

.a1 {
    background: linear-gradient(135deg, #8b5cf6, #5865f2);
}
.a2 {
    background: linear-gradient(135deg, #22b8f0, #3d9e60);
}
.a3 {
    background: linear-gradient(135deg, #f59e0b, #da3e44);
}
.a4 {
    background: linear-gradient(135deg, #ec4899, #8b5cf6);
}

/* --- Возможности --- */

h2 {
    margin: 0 0 28px;
    font-size: 30px;
    letter-spacing: -0.01em;
}

.features {
    padding-bottom: 88px;
}

.features__grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 16px;
}

.feature {
    padding: 24px;
    border-radius: var(--radius);
    background: var(--panel);
    border: 1px solid var(--border);
    transition: border-color 0.18s var(--ease), transform 0.18s var(--ease);
}

.feature:hover {
    border-color: rgba(116, 135, 248, 0.5);
    transform: translateY(-2px);
}

.feature svg {
    width: 40px;
    height: 40px;
    padding: 9px;
    border-radius: 10px;
    background: rgba(88, 101, 242, 0.16);
    fill: none;
    stroke: #7487f8;
    stroke-width: 1.8;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.feature h3 {
    margin: 16px 0 6px;
    font-size: 17px;
}

.feature p {
    margin: 0;
    font-size: 14px;
    color: var(--text-subtle);
}

/* --- Установка --- */

.steps {
    padding-bottom: 96px;
}

.steps__list {
    list-style: none;
    margin: 0;
    padding: 0;
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 16px;
    counter-reset: step;
}

.steps__list li {
    counter-increment: step;
    position: relative;
    padding: 24px 24px 24px 76px;
    border-radius: var(--radius);
    background: var(--panel);
    border: 1px solid var(--border);
}

.steps__list li::before {
    content: counter(step);
    position: absolute;
    left: 24px;
    top: 22px;
    width: 36px;
    height: 36px;
    display: grid;
    place-items: center;
    border-radius: 50%;
    font-weight: 700;
    background: var(--brand);
}

.steps__list b {
    display: block;
    margin-bottom: 4px;
}

.steps__list span {
    font-size: 14px;
    color: var(--text-subtle);
}

/* --- Подвал --- */

.bottom {
    width: 100%;
    max-width: 1160px;
    margin: 0 auto;
    padding: 24px;
    display: flex;
    justify-content: space-between;
    font-size: 13px;
    color: var(--text-muted);
    border-top: 1px solid var(--border);
}

.bottom a {
    color: var(--text-subtle);
    text-decoration: none;
}

.bottom a:hover {
    color: var(--text);
}

/* --- Страница, собранная для телефона --- */

/* Макет окна компьютера там не к месту, а без него герою нужна вся ширина. */
.is-phone .mock {
    display: none;
}

.is-phone .hero {
    grid-template-columns: 1fr;
}

/* --- Узкие экраны --- */

@media (max-width: 960px) {
    .hero {
        grid-template-columns: 1fr;
        gap: 40px;
        padding-top: 24px;
    }

    .features__grid,
    .steps__list {
        grid-template-columns: 1fr 1fr;
    }
}

@media (max-width: 640px) {
    main,
    .top,
    .bottom {
        padding-left: 16px;
        padding-right: 16px;
    }

    .mock__body {
        grid-template-columns: 44px 1fr;
        height: 260px;
    }

    .mock__server {
        width: 30px;
        height: 30px;
    }

    .mock__channels {
        display: none;
    }

    .mock__toast {
        left: 8px;
    }

    .features__grid,
    .steps__list {
        grid-template-columns: 1fr;
    }

    .button {
        width: 100%;
        justify-content: center;
    }

    .hero__actions {
        align-items: stretch;
    }
}

@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation: none !important;
        transition: none !important;
    }
}
