/* VEO 3.1 — Desktop layout: стиль syntx.ai — чистый, просторный, минималистичный */

/* Базовые оптимизации для стабильного layout на всех экранах */
body.veo-generation-body {
    overflow-x: hidden;
}
body.veo-generation-body .header,
body.veo-generation-body .veo-desktop-layout,
body.veo-generation-body .veo-prompt-control-bar {
    box-sizing: border-box;
}

/* Контур разделителей — как у блока ввода промпта (фиолетовый градиент) */
:root {
    --veo-divider-h: linear-gradient(90deg, transparent, rgba(99, 102, 241, 0.2), rgba(139, 92, 246, 0.2), rgba(6, 182, 212, 0.15), rgba(99, 102, 241, 0.2), transparent);
    --veo-divider-v: linear-gradient(180deg, transparent, rgba(99, 102, 241, 0.2), rgba(139, 92, 246, 0.2), rgba(6, 182, 212, 0.15), rgba(99, 102, 241, 0.2), transparent);
}

/* Хеддер — контур как у промпта, лого у левого края, баланс/кнопка/аватар справа */
body.veo-generation-body .header {
    border-bottom: none;
    padding: 0.4rem 0;
}
body.veo-generation-body .header-content {
    padding-left: clamp(0.75rem, 2vw, 1.25rem);
    padding-right: clamp(0.75rem, 2vw, 1.25rem);
    max-width: none;
    width: 100%;
    min-width: 0;
}
body.veo-generation-body .desktop-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: clamp(0.35rem, 1.5vw, 0.75rem);
    width: 100%;
    min-width: 0;
    flex-wrap: nowrap;
}
body.veo-generation-body .desktop-header .logo {
    flex-shrink: 0;
    min-width: 0;
}
body.veo-generation-body .desktop-header .desktop-nav {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 0;
    flex-shrink: 1;
}
body.veo-generation-body .desktop-header .desktop-nav .nav-link {
    white-space: nowrap;
}
/* Иконки навигации — синий неон (mask) */
body.veo-generation-body .header .desktop-nav .nav-link-icon {
    display: inline-block;
    width: 20px;
    height: 20px;
    flex-shrink: 0;
    background: linear-gradient(135deg, #60a5fa 0%, #3b82f6 50%, #2563eb 100%);
    background-size: 200% auto;
    -webkit-mask-size: contain;
    mask-size: contain;
    -webkit-mask-repeat: no-repeat;
    mask-repeat: no-repeat;
    -webkit-mask-position: center;
    mask-position: center;
    filter: drop-shadow(0 0 8px rgba(59, 130, 246, 0.6));
    animation: veo-nav-icon-neon 2.5s ease-in-out infinite;
}
@keyframes veo-nav-icon-neon {
    0%, 100% { filter: drop-shadow(0 0 8px rgba(59, 130, 246, 0.6)); }
    50% { filter: drop-shadow(0 0 12px rgba(59, 130, 246, 0.9)); }
}
@keyframes veo-nav-icon-neon-hover {
    0%, 100% { filter: drop-shadow(0 0 12px rgba(59, 130, 246, 0.9)); }
    50% { filter: drop-shadow(0 0 18px rgba(59, 130, 246, 1)); }
}
body.veo-generation-body .header .desktop-nav .nav-link-icon-home {
    -webkit-mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M3 9l9-7 9 7v11a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2z'/%3E%3Cpolyline points='9 22 9 12 15 12 15 22'/%3E%3C/svg%3E");
    mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M3 9l9-7 9 7v11a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2z'/%3E%3Cpolyline points='9 22 9 12 15 12 15 22'/%3E%3C/svg%3E");
}
body.veo-generation-body .header .desktop-nav .nav-link-icon-video {
    -webkit-mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolygon points='23 7 16 12 23 17 23 7'/%3E%3Crect x='1' y='5' width='15' height='14' rx='2' ry='2'/%3E%3C/svg%3E");
    mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolygon points='23 7 16 12 23 17 23 7'/%3E%3Crect x='1' y='5' width='15' height='14' rx='2' ry='2'/%3E%3C/svg%3E");
}
body.veo-generation-body .header .desktop-nav .nav-link-icon-image {
    -webkit-mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='3' y='3' width='18' height='18' rx='2' ry='2'/%3E%3Ccircle cx='8.5' cy='8.5' r='1.5'/%3E%3Cpolyline points='21 15 16 10 5 21'/%3E%3C/svg%3E");
    mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='3' y='3' width='18' height='18' rx='2' ry='2'/%3E%3Ccircle cx='8.5' cy='8.5' r='1.5'/%3E%3Cpolyline points='21 15 16 10 5 21'/%3E%3C/svg%3E");
}
body.veo-generation-body .header .desktop-nav .nav-link-icon-music {
    -webkit-mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M9 18V5l12-2v13'/%3E%3Ccircle cx='6' cy='18' r='3'/%3E%3Ccircle cx='18' cy='16' r='3'/%3E%3C/svg%3E");
    mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M9 18V5l12-2v13'/%3E%3Ccircle cx='6' cy='18' r='3'/%3E%3Ccircle cx='18' cy='16' r='3'/%3E%3C/svg%3E");
}
body.veo-generation-body .header .desktop-nav .nav-link-icon-text {
    -webkit-mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M21 15a2 2 0 0 1-2 2H7l-4 4V5a2 2 0 0 1 2-2h14a2 2 0 0 1 2 2z'/%3E%3C/svg%3E");
    mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M21 15a2 2 0 0 1-2 2H7l-4 4V5a2 2 0 0 1 2-2h14a2 2 0 0 1 2 2z'/%3E%3C/svg%3E");
}

/* Навигация хедера — иконки с градиентом, текст белый */
body.veo-generation-body .header .desktop-nav .nav-link {
    color: var(--text-primary);
}
body.veo-generation-body .header .desktop-nav .nav-link > span:last-child {
    color: var(--text-primary);
}
body.veo-generation-body .header .desktop-nav .nav-link::after {
    background: linear-gradient(90deg, #60a5fa, #3b82f6, #2563eb, #60a5fa);
    background-size: 200% auto;
    animation: veo-brand-shimmer 8s linear infinite;
}
body.veo-generation-body .header .desktop-nav .nav-link:hover .nav-link-icon,
body.veo-generation-body .header .desktop-nav .nav-link.active .nav-link-icon {
    animation: veo-nav-icon-neon-hover 1.5s ease-in-out infinite;
}
body.veo-generation-body .header .desktop-nav .nav-link.active::after {
    background: linear-gradient(90deg, #60a5fa, #3b82f6, #2563eb, #60a5fa);
    background-size: 200% auto;
}
body.veo-generation-body .desktop-header .desktop-header-right {
    flex-shrink: 0;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}
body.veo-generation-body .header::after {
    content: '';
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    height: 1px;
    background: var(--veo-divider-h);
}

/* Лого + название Vision Flow AI — космический шрифт */
body.veo-generation-body .header .logo,
body.veo-generation-body .header .mobile-logo {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}
body.veo-generation-body .header .header-brand-name {
    font-family: 'Orbitron', sans-serif;
    font-weight: 600;
    font-size: 1.25rem;
    letter-spacing: 0.08em;
    color: #ffffff;
}
@keyframes veo-brand-shimmer {
    0% { background-position: 0% center; }
    100% { background-position: 200% center; }
}
body.veo-generation-body .header .mobile-logo .header-brand-name {
    font-size: 1.05rem;
}

/* Лого — белый */
body.veo-generation-body .header .veo-logo-gradient {
    display: inline-block;
    flex-shrink: 0;
    width: 42px;
    height: 42px;
    background: #ffffff;
    -webkit-mask-image: var(--logo-url);
    mask-image: var(--logo-url);
    -webkit-mask-size: contain;
    mask-size: contain;
    -webkit-mask-repeat: no-repeat;
    mask-repeat: no-repeat;
    -webkit-mask-position: center;
    mask-position: center;
    animation: veo-logo-flip-h 5.5s ease-in-out infinite;
}
body.veo-generation-body .header .veo-logo-gradient-mobile {
    width: 36px;
    height: 36px;
}
body.veo-generation-body .header .logo:hover .veo-logo-gradient,
body.veo-generation-body .header .mobile-logo:hover .veo-logo-gradient {
    animation-duration: 3s;
}
@keyframes veo-logo-flip-h {
    0% { transform: scaleX(1); }
    9% { transform: scaleX(-1); }
    45% { transform: scaleX(-1); }
    55% { transform: scaleX(1); }
    100% { transform: scaleX(1); }
}

/* Кнопка КУПИТЬ — синий неон */
body.veo-generation-body .header .buy-balance-group .profile-buy-btn {
    position: relative;
    height: 32px;
    box-sizing: border-box;
    border: 1px solid rgba(59, 130, 246, 0.6);
    border-radius: var(--radius-xl);
    padding: 0.35rem 0.7rem;
    color: #fff;
    font-weight: 700;
    font-size: 0.75rem;
    letter-spacing: 0.08em;
    text-transform: none;
    background: linear-gradient(135deg, rgba(37, 99, 235, 0.4) 0%, rgba(59, 130, 246, 0.25) 50%, rgba(29, 78, 216, 0.4) 100%);
    box-shadow: 0 0 20px rgba(59, 130, 246, 0.4), 0 0 40px rgba(37, 99, 235, 0.2);
    transition: border-color 0.3s ease, box-shadow 0.3s ease;
    animation: veo-buy-btn-neon 2.5s ease-in-out infinite;
    overflow: visible;
}
@keyframes veo-buy-btn-neon {
    0%, 100% { box-shadow: 0 0 20px rgba(59, 130, 246, 0.4), 0 0 40px rgba(37, 99, 235, 0.2); }
    50% { box-shadow: 0 0 30px rgba(59, 130, 246, 0.6), 0 0 60px rgba(37, 99, 235, 0.3); }
}
body.veo-generation-body .header .buy-balance-group .profile-buy-btn::before {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: inherit;
    background: linear-gradient(110deg, transparent 25%, rgba(255, 255, 255, 0.2) 50%, transparent 75%);
    background-size: 200% 100%;
    background-position: 200% 0;
    opacity: 0.6;
    pointer-events: none;
    z-index: 0;
    animation: veo-buy-btn-shimmer 5s ease-in-out infinite;
}
@keyframes veo-buy-btn-shimmer {
    0% { background-position: 200% 0; }
    100% { background-position: -200% 0; }
}
body.veo-generation-body .header .buy-balance-group .profile-buy-btn::after {
    display: none;
}
body.veo-generation-body .header .buy-balance-group .profile-buy-btn:hover {
    border-color: rgba(59, 130, 246, 0.9);
    box-shadow: 0 0 25px rgba(59, 130, 246, 0.6), 0 0 50px rgba(37, 99, 235, 0.35);
    animation: veo-buy-btn-neon 2s ease-in-out infinite;
}
body.veo-generation-body .header .buy-balance-group .profile-buy-btn:hover::before {
    opacity: 1;
    animation: veo-buy-btn-shimmer 2.5s ease-in-out infinite;
}
body.veo-generation-body .header .buy-balance-group .profile-buy-btn:active {
    box-shadow: 0 0 15px rgba(59, 130, 246, 0.5);
}
body.veo-generation-body .header .buy-balance-group {
    background: rgba(99, 102, 241, 0.06);
    border: 1px solid rgba(99, 102, 241, 0.2);
    border-radius: var(--radius-2xl);
    padding: 0.2rem 0.4rem;
    gap: 0.35rem;
    transition: border-color 0.3s ease;
    box-shadow: none;
    overflow: visible;
}
body.veo-generation-body .header .buy-balance-group:hover {
    border-color: rgba(99, 102, 241, 0.35);
    box-shadow: none;
}

/* Связка звук + Войти/аватар — такой же контур, как у баланса и КУПИТЬ */
body.veo-generation-body .header .audio-avatar-group {
    display: flex;
    align-items: center;
    gap: 0.35rem;
    background: rgba(99, 102, 241, 0.06);
    border: 1px solid rgba(99, 102, 241, 0.2);
    border-radius: var(--radius-2xl);
    padding: 0.2rem 0.4rem;
    transition: border-color 0.3s ease;
}
body.veo-generation-body .header .audio-avatar-group:hover {
    border-color: rgba(99, 102, 241, 0.35);
}
body.veo-generation-body .header .audio-avatar-group .profile-separator,
body.veo-generation-body .header .buy-balance-group .profile-separator {
    color: rgba(255, 255, 255, 0.2);
    font-size: 0.75rem;
    margin: 0 0.05rem;
}
body.veo-generation-body .header .buy-balance-group .vf-currency-selector .vf-currency-trigger {
    padding: 0.35rem 0.65rem;
    height: 32px;
    min-height: 32px;
    box-sizing: border-box;
    display: flex;
    align-items: center;
    line-height: 1;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: var(--radius-xl);
    transition: border-color 0.3s ease, background 0.3s ease;
}
body.veo-generation-body .header .buy-balance-group .vf-currency-selector .vf-currency-trigger:hover {
    background: rgba(255, 255, 255, 0.07);
    border-color: rgba(99, 102, 241, 0.3);
}
body.veo-generation-body .header .audio-avatar-group.mobile-audio-avatar-group {
    margin-right: 0.25rem;
}

/* Иконка звука и аватар — синий неон с лёгкой анимацией */
body.veo-generation-body .header .audio-toggle-btn,
body.veo-generation-body .header .mobile-audio-toggle-btn {
    width: 32px;
    height: 32px;
    min-width: 32px;
    min-height: 32px;
    border-radius: var(--radius-xl);
    border: 1px solid rgba(59, 130, 246, 0.5);
    background: rgba(255, 255, 255, 0.04);
    animation: veo-neon-glow-pulse 3s ease-in-out infinite;
}
body.veo-generation-body .header .audio-toggle-btn.audio-muted,
body.veo-generation-body .header .mobile-audio-toggle-btn.audio-muted {
    box-shadow: 0 0 10px rgba(59, 130, 246, 0.25), 0 0 20px rgba(59, 130, 246, 0.1);
}
/* Звук включён — синий неон */
body.veo-generation-body .header .audio-toggle-btn:not(.audio-muted),
body.veo-generation-body .header .mobile-audio-toggle-btn:not(.audio-muted) {
    box-shadow: 0 0 12px rgba(59, 130, 246, 0.5), 0 0 24px rgba(59, 130, 246, 0.25);
    border-color: rgba(59, 130, 246, 0.6);
}
body.veo-generation-body .header .audio-toggle-btn:not(.audio-muted) .audio-icon,
body.veo-generation-body .header .mobile-audio-toggle-btn:not(.audio-muted) .audio-icon {
    color: #93c5fd;
}
/* Звук выключен — зачёркнутая иконка */
body.veo-generation-body .header .audio-toggle-btn.audio-muted,
body.veo-generation-body .header .mobile-audio-toggle-btn.audio-muted {
    opacity: 0.85;
}
body.veo-generation-body .header .audio-toggle-btn:hover,
body.veo-generation-body .header .mobile-audio-toggle-btn:hover {
    background: rgba(255, 255, 255, 0.08);
    border-color: rgba(59, 130, 246, 0.7);
}
body.veo-generation-body .header .audio-toggle-btn:not(.audio-muted):hover,
body.veo-generation-body .header .mobile-audio-toggle-btn:not(.audio-muted):hover {
    border-color: rgba(59, 130, 246, 0.8);
    box-shadow: 0 0 16px rgba(59, 130, 246, 0.6), 0 0 32px rgba(59, 130, 246, 0.3);
}
@keyframes veo-neon-glow-pulse {
    0%, 100% { box-shadow: 0 0 10px rgba(59, 130, 246, 0.25), 0 0 20px rgba(59, 130, 246, 0.1); }
    50% { box-shadow: 0 0 14px rgba(59, 130, 246, 0.35), 0 0 28px rgba(59, 130, 246, 0.15); }
}
@keyframes veo-neon-glow-pulse-strong {
    0%, 100% { box-shadow: 0 0 12px rgba(59, 130, 246, 0.5), 0 0 24px rgba(59, 130, 246, 0.25); }
    50% { box-shadow: 0 0 18px rgba(59, 130, 246, 0.6), 0 0 36px rgba(59, 130, 246, 0.3); }
}
body.veo-generation-body .header .audio-toggle-btn:not(.audio-muted),
body.veo-generation-body .header .mobile-audio-toggle-btn:not(.audio-muted) {
    animation: veo-neon-glow-pulse-strong 3s ease-in-out infinite;
}
body.veo-generation-body .header .profile-user-avatar {
    width: 32px;
    height: 32px;
    min-width: 32px;
    min-height: 32px;
    border-radius: 50%;
    border: 2px solid rgba(59, 130, 246, 0.6);
    animation: veo-neon-glow-pulse 3s ease-in-out infinite;
}
body.veo-generation-body .header .profile-user-avatar:hover {
    border-color: rgba(59, 130, 246, 0.95);
    box-shadow: 0 0 14px rgba(59, 130, 246, 0.5), 0 0 28px rgba(59, 130, 246, 0.2);
    transform: scale(1.03);
}

@media (prefers-reduced-motion: reduce) {
    body.veo-generation-body .header .audio-toggle-btn,
    body.veo-generation-body .header .mobile-audio-toggle-btn,
    body.veo-generation-body .header .profile-user-avatar,
    .profile-user-avatar {
        animation: none !important;
    }
}

/* Кнопка «Войти» — того же размера, что Купить и баланс */
body.veo-generation-body .header .profile-user-avatar.veo-avatar-login {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    min-width: auto;
    width: auto;
    height: 32px;
    min-height: 32px;
    padding: 0.4rem 0.85rem;
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid rgba(59, 130, 246, 0.6);
    border-radius: var(--radius-xl);
    box-shadow: 0 0 12px rgba(59, 130, 246, 0.35), 0 0 24px rgba(59, 130, 246, 0.15);
    transition: border-color 0.3s ease, background 0.3s ease, box-shadow 0.3s ease, transform 0.3s ease;
    overflow: visible;
    animation: veo-neon-glow-pulse 3s ease-in-out infinite;
}
body.veo-generation-body .header .profile-user-avatar.veo-avatar-login::before {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: inherit;
    background: linear-gradient(110deg, transparent 30%, rgba(165, 180, 252, 0.15) 50%, transparent 70%);
    background-size: 200% 100%;
    background-position: 200% 0;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
}
body.veo-generation-body .header .profile-user-avatar.veo-avatar-login:hover {
    border-color: rgba(59, 130, 246, 0.8);
    background: rgba(255, 255, 255, 0.12);
    box-shadow: 0 0 20px rgba(59, 130, 246, 0.35), 0 0 40px rgba(59, 130, 246, 0.15);
    transform: translateY(-1px) scale(1.02);
}
body.veo-generation-body .header .profile-user-avatar.veo-avatar-login:hover::before {
    opacity: 0.6;
    animation: veo-login-shimmer 0.8s ease-out forwards;
}
@keyframes veo-login-shimmer {
    0% { background-position: 200% 0; }
    100% { background-position: -200% 0; }
}
body.veo-generation-body .header .profile-user-avatar.veo-avatar-login:active {
    background: rgba(255, 255, 255, 0.08);
    transform: translateY(0);
}
body.veo-generation-body .header .profile-user-avatar.veo-avatar-login:hover .veo-login-icon img {
    transform: scale(1.05);
}
body.veo-generation-body .header .profile-user-avatar:not(.veo-avatar-login) .veo-login-icon {
    display: none;
}
body.veo-generation-body .header .profile-user-avatar.veo-avatar-login .veo-login-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 23px;
    height: 23px;
    flex-shrink: 0;
    min-width: 23px;
    min-height: 23px;
    color: rgba(224, 231, 255, 0.95);
}
body.veo-generation-body .header .profile-user-avatar.veo-avatar-login .veo-login-icon svg,
body.veo-generation-body .header .profile-user-avatar.veo-avatar-login .veo-login-icon img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}
body.veo-generation-body .header .profile-user-avatar.veo-avatar-login .veo-login-icon img {
    filter: invert(1) brightness(1.1);
    transition: transform 0.3s ease;
}
body.veo-generation-body .header .profile-user-avatar.veo-avatar-login .profile-avatar-letter {
    position: relative;
    z-index: 1;
    font-family: 'Orbitron', sans-serif;
    font-size: 0.75rem;
    font-weight: 600;
    letter-spacing: 0.08em;
    text-transform: none;
    color: rgba(224, 231, 255, 0.95);
    background: none;
    -webkit-background-clip: unset;
    -webkit-text-fill-color: unset;
    background-clip: unset;
    filter: none;
    animation: none;
}

/* Баланс — на уровне кнопки КУПИТЬ, живая иконка мозга */
body.veo-generation-body .header .buy-balance-group .profile-balance-header {
    display: flex;
    align-items: center;
    gap: 0.2rem;
    padding: 0.35rem 0.65rem;
    height: 32px;
    min-height: 32px;
    box-sizing: border-box;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: var(--radius-xl);
    transition: border-color 0.3s ease, background 0.3s ease;
    overflow: visible;
    line-height: 1;
}
body.veo-generation-body .header .buy-balance-group .profile-balance-header:hover {
    background: rgba(255, 255, 255, 0.07);
    border-color: rgba(99, 102, 241, 0.3);
}
body.veo-generation-body .header .buy-balance-group .profile-balance-amount-header,
body.veo-generation-body .header .buy-balance-group .vf-currency-amount {
    font-size: 0.9rem;
    font-weight: 700;
    line-height: 1;
    display: inline-flex;
    align-items: center;
}
body.veo-generation-body .header .buy-balance-group .profile-balance-amount-header {
    color: var(--text-primary);
    text-shadow: none;
}
body.veo-generation-body .header .buy-balance-group .profile-balance-icon-header {
    display: inline-flex;
    align-items: center;
    font-size: 0.9rem;
    line-height: 1;
    overflow: visible;
}
body.veo-generation-body .header .buy-balance-group .profile-balance-icon-header .veo-rocket-wrap {
    display: inline-flex;
    align-items: center;
    position: relative;
    animation: veo-rocket-spin 3s ease-in-out infinite;
}
@keyframes veo-rocket-spin {
    0%, 100% { transform: scale(1) rotate(-6deg); }
    50% { transform: scale(1.15) rotate(8deg); }
}
@keyframes veo-brain-alive {
    0%, 100% { transform: scale(1) rotate(0deg); }
    50% { transform: scale(1.15) rotate(5deg); }
}

@media (min-width: 600px) {
    body.veo-generation-body .app-container {
        display: flex;
        flex-direction: column;
        min-height: 100vh;
        padding-left: 0.5rem;
        padding-right: 0.5rem;
        overflow: visible !important;
    }
    
    body.veo-generation-body .veo-mobile-layout {
        display: none !important;
    }
    
    body.veo-generation-body main.veo-main {
        display: flex !important;
        flex-direction: column;
        flex: 1;
        min-height: calc(100vh - 60px);
    }
    
    body.veo-generation-body .veo-form {
        display: flex;
        flex: 1;
        min-height: 0;
    }
    
    body.veo-generation-body .veo-desktop-layout {
        display: flex;
        flex: 1;
        min-height: calc(100vh - 60px);
        min-width: 0;
        position: relative;
        z-index: 1;
        gap: 0;
        padding: 0;
        box-sizing: border-box;
    }

    /* Левый сайдбар — 3 кнопки, равные отступы от края до разделителя */
    .veo-left-sidebar {
        position: relative;
        width: 60px;
        min-width: 60px;
        background: var(--bg-primary);
        border-right: none;
        padding: 0.75rem 12px 1.5rem;
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: flex-start;
        gap: 1rem;
        box-sizing: border-box;
    }
    .veo-left-sidebar::after {
        content: '';
        position: absolute;
        top: 0;
        right: 0;
        bottom: 0;
        width: 1px;
        background: var(--veo-divider-v);
    }

    .veo-left-icon-btn {
        width: 36px;
        height: 36px;
        display: flex;
        align-items: center;
        justify-content: center;
        background: transparent;
        border: none;
        border-radius: 8px;
        color: rgba(255, 255, 255, 0.5);
        cursor: pointer;
        transition: background 0.15s, color 0.15s;
    }

    .veo-left-icon-btn:hover {
        background: rgba(124, 58, 237, 0.12);
    }

    .veo-left-sidebar-icon {
        display: block;
        width: 20px;
        height: 20px;
        background: #fff;
        -webkit-mask-size: contain;
        mask-size: contain;
        -webkit-mask-repeat: no-repeat;
        mask-repeat: no-repeat;
        -webkit-mask-position: center;
        mask-position: center;
    }
    .veo-left-icon-chats {
        -webkit-mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M21 15a2 2 0 0 1-2 2H7l-4 4V5a2 2 0 0 1 2-2h14a2 2 0 0 1 2 2z'/%3E%3C/svg%3E");
        mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M21 15a2 2 0 0 1-2 2H7l-4 4V5a2 2 0 0 1 2-2h14a2 2 0 0 1 2 2z'/%3E%3C/svg%3E");
    }
    .veo-left-icon-projects {
        -webkit-mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M14 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V8z'/%3E%3Cpolyline points='14 2 14 8 20 8'/%3E%3Cline x1='16' y1='13' x2='8' y2='13'/%3E%3Cline x1='16' y1='17' x2='8' y2='17'/%3E%3Cpolyline points='10 9 9 9 8 9'/%3E%3C/svg%3E");
        mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M14 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V8z'/%3E%3Cpolyline points='14 2 14 8 20 8'/%3E%3Cline x1='16' y1='13' x2='8' y2='13'/%3E%3Cline x1='16' y1='17' x2='8' y2='17'/%3E%3Cpolyline points='10 9 9 9 8 9'/%3E%3C/svg%3E");
    }
    .veo-left-new-chat .veo-new-chat-icon {
        -webkit-mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M12 5v14M5 12h14'/%3E%3C/svg%3E");
        mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M12 5v14M5 12h14'/%3E%3C/svg%3E");
    }
    .veo-left-icon-btn:hover .veo-left-sidebar-icon {
        background: #fff;
    }
    .veo-left-new-chat {
        width: 36px;
        height: 36px;
    }

    /* Центральная область — в стиле сайта Vision Flow: градиенты, золотые акценты, анимации */
    .veo-center-area {
        flex: 1;
        display: flex;
        flex-direction: column;
        min-width: 0;
        background: var(--bg-primary);
        padding: 1rem 2.5rem 2rem;
        position: relative;
        overflow: visible;
    }
    .veo-center-area > * {
        position: relative;
        z-index: 1;
    }
    /* Область сообщений — звёзды только здесь, не в поле ввода */
    .veo-chat-messages-wrap {
        position: relative;
        flex: 1;
        min-height: 0;
        max-height: 55vh;
        display: flex;
        flex-direction: column;
        overflow: hidden;
    }
    /* Белые космические звёзды — как в космосе, часть мерцает, часть движется, падающие через экран */
    .veo-chat-messages-wrap .veo-cosmic-stars {
        position: absolute;
        inset: 0;
        pointer-events: none;
        z-index: 4;
        overflow: visible;
    }
    .veo-cosmic-stars {
        pointer-events: none;
    }
    .veo-cosmic-star {
        position: absolute;
        border-radius: 50%;
        background: rgba(255, 255, 255, 1);
        box-shadow: 0 0 10px rgba(255, 255, 255, 1), 0 0 20px rgba(255, 255, 255, 0.7), 0 0 32px rgba(255, 255, 255, 0.4);
    }
    /* Цветные звёзды — яркие, насыщенные */
    .veo-cosmic-star--blue { background: rgba(147, 197, 253, 1); box-shadow: 0 0 12px rgba(147, 197, 253, 1), 0 0 24px rgba(147, 197, 253, 0.9), 0 0 40px rgba(147, 197, 253, 0.6); }
    .veo-cosmic-star--cyan { background: rgba(103, 232, 249, 1); box-shadow: 0 0 12px rgba(103, 232, 249, 1), 0 0 24px rgba(103, 232, 249, 0.9), 0 0 40px rgba(103, 232, 249, 0.6); }
    .veo-cosmic-star--gold { background: rgba(253, 224, 71, 1); box-shadow: 0 0 12px rgba(253, 224, 71, 1), 0 0 24px rgba(253, 224, 71, 0.9), 0 0 40px rgba(253, 224, 71, 0.6); }
    .veo-cosmic-star--lavender { background: rgba(196, 181, 253, 1); box-shadow: 0 0 12px rgba(196, 181, 253, 1), 0 0 24px rgba(196, 181, 253, 0.9), 0 0 40px rgba(196, 181, 253, 0.6); }
    .veo-cosmic-star--pink { background: rgba(249, 168, 212, 1); box-shadow: 0 0 12px rgba(249, 168, 212, 1), 0 0 24px rgba(249, 168, 212, 0.9), 0 0 40px rgba(249, 168, 212, 0.6); }
    .veo-cosmic-star--coral { background: rgba(251, 146, 60, 1); box-shadow: 0 0 12px rgba(251, 146, 60, 1), 0 0 24px rgba(251, 146, 60, 0.9), 0 0 40px rgba(251, 146, 60, 0.6); }
    .veo-cosmic-star--white { background: rgba(255, 255, 255, 1); box-shadow: 0 0 10px rgba(255, 255, 255, 1), 0 0 20px rgba(255, 255, 255, 0.7), 0 0 32px rgba(255, 255, 255, 0.4); }
    /* На больших экранах (≥1920px) — звёзды меньше и с меньшим blur, чтобы не пикселились */
    @media (min-width: 1920px) {
        .veo-cosmic-star {
            max-width: 2px !important;
            max-height: 2px !important;
        }
        .veo-cosmic-star--blue { box-shadow: 0 0 6px rgba(147, 197, 253, 1), 0 0 12px rgba(147, 197, 253, 0.9), 0 0 18px rgba(147, 197, 253, 0.6) !important; }
        .veo-cosmic-star--cyan { box-shadow: 0 0 6px rgba(103, 232, 249, 1), 0 0 12px rgba(103, 232, 249, 0.9), 0 0 18px rgba(103, 232, 249, 0.6) !important; }
        .veo-cosmic-star--gold { box-shadow: 0 0 6px rgba(253, 224, 71, 1), 0 0 12px rgba(253, 224, 71, 0.9), 0 0 18px rgba(253, 224, 71, 0.6) !important; }
        .veo-cosmic-star--lavender { box-shadow: 0 0 6px rgba(196, 181, 253, 1), 0 0 12px rgba(196, 181, 253, 0.9), 0 0 18px rgba(196, 181, 253, 0.6) !important; }
        .veo-cosmic-star--pink { box-shadow: 0 0 6px rgba(249, 168, 212, 1), 0 0 12px rgba(249, 168, 212, 0.9), 0 0 18px rgba(249, 168, 212, 0.6) !important; }
        .veo-cosmic-star--coral { box-shadow: 0 0 6px rgba(251, 146, 60, 1), 0 0 12px rgba(251, 146, 60, 0.9), 0 0 18px rgba(251, 146, 60, 0.6) !important; }
        .veo-cosmic-star--white { box-shadow: 0 0 6px rgba(255, 255, 255, 1), 0 0 12px rgba(255, 255, 255, 0.7), 0 0 18px rgba(255, 255, 255, 0.4) !important; }
        .veo-cosmic-star--shoot { width: 2px !important; height: 2px !important; box-shadow: 0 0 6px rgba(255, 255, 255, 0.9), 0 0 12px rgba(255, 255, 255, 0.5) !important; }
    }
    .veo-cosmic-star--twinkle {
        animation: veo-star-twinkle 2.5s ease-in-out infinite;
    }
    .veo-cosmic-star--twinkle:nth-child(1) { left: 8%; top: 12%; width: 2px; height: 2px; animation-delay: 0s; }
    .veo-cosmic-star--twinkle:nth-child(2) { left: 22%; top: 35%; width: 3px; height: 3px; animation-delay: 0.4s; }
    .veo-cosmic-star--twinkle:nth-child(3) { left: 45%; top: 8%; width: 1px; height: 1px; animation-delay: 0.8s; }
    .veo-cosmic-star--twinkle:nth-child(4) { left: 68%; top: 45%; width: 2px; height: 2px; animation-delay: 1.2s; }
    .veo-cosmic-star--twinkle:nth-child(5) { left: 85%; top: 25%; width: 2px; height: 2px; animation-delay: 1.6s; }
    .veo-cosmic-star--twinkle:nth-child(6) { left: 15%; top: 65%; width: 1px; height: 1px; animation-delay: 0.2s; }
    .veo-cosmic-star--twinkle:nth-child(7) { left: 55%; top: 72%; width: 2px; height: 2px; animation-delay: 0.6s; }
    .veo-cosmic-star--twinkle:nth-child(8) { left: 78%; top: 85%; width: 1px; height: 1px; animation-delay: 1s; }
    .veo-cosmic-star--twinkle:nth-child(9) { left: 35%; top: 55%; width: 2px; height: 2px; animation-delay: 1.4s; }
    .veo-cosmic-star--twinkle:nth-child(10) { left: 92%; top: 50%; width: 1px; height: 1px; animation-delay: 1.8s; }
    .veo-cosmic-star--twinkle:nth-child(11) { left: 12%; top: 28%; width: 2px; height: 2px; animation-delay: 0.3s; }
    .veo-cosmic-star--twinkle:nth-child(12) { left: 38%; top: 18%; width: 1px; height: 1px; animation-delay: 0.7s; }
    .veo-cosmic-star--twinkle:nth-child(13) { left: 58%; top: 42%; width: 2px; height: 2px; animation-delay: 1.1s; }
    .veo-cosmic-star--twinkle:nth-child(14) { left: 72%; top: 78%; width: 1px; height: 1px; animation-delay: 0.5s; }
    .veo-cosmic-star--twinkle:nth-child(15) { left: 5%; top: 48%; width: 2px; height: 2px; animation-delay: 1.5s; }
    .veo-cosmic-star--twinkle:nth-child(16) { left: 42%; top: 62%; width: 1px; height: 1px; animation-delay: 0.9s; }
    .veo-cosmic-star--twinkle:nth-child(17) { left: 88%; top: 15%; width: 2px; height: 2px; animation-delay: 0.1s; }
    .veo-cosmic-star--twinkle:nth-child(18) { left: 25%; top: 82%; width: 1px; height: 1px; animation-delay: 1.3s; }
    .veo-cosmic-star--twinkle:nth-child(19) { left: 65%; top: 5%; width: 2px; height: 2px; animation-delay: 0.6s; }
    .veo-cosmic-star--twinkle:nth-child(20) { left: 18%; top: 42%; width: 1px; height: 1px; animation-delay: 1.7s; }
    .veo-cosmic-star--twinkle:nth-child(21) { left: 52%; top: 28%; width: 2px; height: 2px; animation-delay: 0.2s; }
    .veo-cosmic-star--twinkle:nth-child(22) { left: 8%; top: 72%; width: 2px; height: 2px; animation-delay: 0.9s; }
    .veo-cosmic-star--twinkle:nth-child(23) { left: 75%; top: 52%; width: 1px; height: 1px; animation-delay: 1.4s; }
    .veo-cosmic-star--twinkle:nth-child(24) { left: 28%; top: 12%; width: 2px; height: 2px; animation-delay: 0.5s; }
    .veo-cosmic-star--twinkle:nth-child(25) { left: 62%; top: 68%; width: 2px; height: 2px; animation-delay: 1.1s; }
    .veo-cosmic-star--twinkle:nth-child(26) { left: 14%; top: 38%; width: 1px; height: 1px; animation-delay: 1.6s; }
    .veo-cosmic-star--twinkle:nth-child(27) { left: 82%; top: 42%; width: 2px; height: 2px; animation-delay: 0.3s; }
    .veo-cosmic-star--twinkle:nth-child(28) { left: 40%; top: 78%; width: 1px; height: 1px; animation-delay: 0.8s; }
    .veo-cosmic-star--twinkle:nth-child(29) { left: 6%; top: 22%; width: 2px; height: 2px; animation-delay: 1.3s; }
    .veo-cosmic-star--twinkle:nth-child(30) { left: 90%; top: 62%; width: 1px; height: 1px; animation-delay: 0.1s; }
    .veo-cosmic-star--twinkle:nth-child(46) { left: 3%; top: 58%; width: 2px; height: 2px; animation-delay: 0.4s; }
    .veo-cosmic-star--twinkle:nth-child(47) { left: 48%; top: 5%; width: 1px; height: 1px; animation-delay: 0.9s; }
    .veo-cosmic-star--twinkle:nth-child(48) { left: 95%; top: 35%; width: 2px; height: 2px; animation-delay: 1.5s; }
    .veo-cosmic-star--twinkle:nth-child(49) { left: 18%; top: 18%; width: 1px; height: 1px; animation-delay: 0.2s; }
    .veo-cosmic-star--twinkle:nth-child(50) { left: 72%; top: 58%; width: 2px; height: 2px; animation-delay: 1.1s; }
    .veo-cosmic-star--twinkle:nth-child(51) { left: 32%; top: 42%; width: 1px; height: 1px; animation-delay: 0.6s; }
    .veo-cosmic-star--twinkle:nth-child(52) { left: 88%; top: 78%; width: 2px; height: 2px; animation-delay: 1.8s; }
    .veo-cosmic-star--twinkle:nth-child(53) { left: 7%; top: 88%; width: 1px; height: 1px; animation-delay: 0.3s; }
    .veo-cosmic-star--twinkle:nth-child(54) { left: 55%; top: 22%; width: 2px; height: 2px; animation-delay: 1.4s; }
    .veo-cosmic-star--twinkle:nth-child(55) { left: 42%; top: 88%; width: 1px; height: 1px; animation-delay: 0.7s; }
    .veo-cosmic-star--twinkle:nth-child(56) { left: 78%; top: 8%; width: 2px; height: 2px; animation-delay: 1.2s; }
    .veo-cosmic-star--twinkle:nth-child(57) { left: 12%; top: 52%; width: 1px; height: 1px; animation-delay: 0.5s; }
    .veo-cosmic-star--twinkle:nth-child(58) { left: 62%; top: 48%; width: 2px; height: 2px; animation-delay: 1.6s; }
    .veo-cosmic-star--twinkle:nth-child(59) { left: 25%; top: 68%; width: 1px; height: 1px; animation-delay: 0.1s; }
    .veo-cosmic-star--twinkle:nth-child(60) { left: 92%; top: 12%; width: 2px; height: 2px; animation-delay: 1.3s; }
    .veo-cosmic-star--twinkle:nth-child(61) { left: 38%; top: 32%; width: 1px; height: 1px; animation-delay: 0.8s; }
    .veo-cosmic-star--twinkle:nth-child(62) { left: 68%; top: 38%; width: 2px; height: 2px; animation-delay: 1.7s; }
    .veo-cosmic-star--twinkle:nth-child(63) { left: 5%; top: 75%; width: 1px; height: 1px; animation-delay: 0.4s; }
    .veo-cosmic-star--twinkle:nth-child(64) { left: 82%; top: 48%; width: 2px; height: 2px; animation-delay: 1.0s; }
    .veo-cosmic-star--twinkle:nth-child(65) { left: 15%; top: 8%; width: 1px; height: 1px; animation-delay: 1.5s; }
    .veo-cosmic-star--twinkle:nth-child(76) { left: 4%; top: 42%; width: 2px; height: 2px; animation-delay: 0.2s; }
    .veo-cosmic-star--twinkle:nth-child(77) { left: 36%; top: 6%; width: 1px; height: 1px; animation-delay: 0.8s; }
    .veo-cosmic-star--twinkle:nth-child(78) { left: 94%; top: 48%; width: 2px; height: 2px; animation-delay: 1.4s; }
    .veo-cosmic-star--twinkle:nth-child(79) { left: 22%; top: 72%; width: 1px; height: 1px; animation-delay: 0.5s; }
    .veo-cosmic-star--twinkle:nth-child(80) { left: 66%; top: 14%; width: 2px; height: 2px; animation-delay: 1.1s; }
    .veo-cosmic-star--twinkle:nth-child(81) { left: 10%; top: 58%; width: 1px; height: 1px; animation-delay: 0.3s; }
    .veo-cosmic-star--twinkle:nth-child(82) { left: 54%; top: 82%; width: 2px; height: 2px; animation-delay: 1.7s; }
    .veo-cosmic-star--twinkle:nth-child(83) { left: 80%; top: 28%; width: 1px; height: 1px; animation-delay: 0.6s; }
    .veo-cosmic-star--twinkle:nth-child(84) { left: 16%; top: 34%; width: 2px; height: 2px; animation-delay: 1.2s; }
    .veo-cosmic-star--twinkle:nth-child(85) { left: 44%; top: 54%; width: 1px; height: 1px; animation-delay: 0.4s; }
    .veo-cosmic-star--twinkle:nth-child(86) { left: 86%; top: 68%; width: 2px; height: 2px; animation-delay: 1.5s; }
    .veo-cosmic-star--twinkle:nth-child(87) { left: 2%; top: 18%; width: 1px; height: 1px; animation-delay: 0.9s; }
    .veo-cosmic-star--twinkle:nth-child(88) { left: 60%; top: 62%; width: 2px; height: 2px; animation-delay: 1.0s; }
    .veo-cosmic-star--twinkle:nth-child(89) { left: 30%; top: 92%; width: 1px; height: 1px; animation-delay: 0.7s; }
    .veo-cosmic-star--twinkle:nth-child(90) { left: 74%; top: 38%; width: 2px; height: 2px; animation-delay: 1.6s; }
    .veo-cosmic-star--twinkle:nth-child(101) { left: 7%; top: 14%; width: 2px; height: 2px; animation-delay: 0.2s; }
    .veo-cosmic-star--twinkle:nth-child(102) { left: 24%; top: 52%; width: 1px; height: 1px; animation-delay: 0.6s; }
    .veo-cosmic-star--twinkle:nth-child(103) { left: 41%; top: 22%; width: 2px; height: 2px; animation-delay: 1s; }
    .veo-cosmic-star--twinkle:nth-child(104) { left: 59%; top: 68%; width: 1px; height: 1px; animation-delay: 0.4s; }
    .veo-cosmic-star--twinkle:nth-child(105) { left: 76%; top: 38%; width: 2px; height: 2px; animation-delay: 1.4s; }
    .veo-cosmic-star--twinkle:nth-child(106) { left: 93%; top: 78%; width: 1px; height: 1px; animation-delay: 0.8s; }
    .veo-cosmic-star--move:nth-child(107) { left: 12%; top: 44%; width: 2px; height: 2px; animation-delay: 0.5s; animation-duration: 11s; }
    .veo-cosmic-star--move:nth-child(108) { left: 33%; top: 16%; width: 1px; height: 1px; animation-delay: 1.2s; animation-duration: 14s; animation-name: veo-star-drift-2; }
    .veo-cosmic-star--move:nth-child(109) { left: 51%; top: 58%; width: 2px; height: 2px; animation-delay: 0.3s; animation-duration: 12s; }
    .veo-cosmic-star--move:nth-child(110) { left: 69%; top: 8%; width: 1px; height: 1px; animation-delay: 1.5s; animation-duration: 15s; animation-name: veo-star-drift-2; }
    .veo-cosmic-star--move:nth-child(111) { left: 86%; top: 62%; width: 2px; height: 2px; animation-delay: 0.7s; animation-duration: 13s; }
    .veo-cosmic-star--move:nth-child(112) { left: 18%; top: 88%; width: 1px; height: 1px; animation-delay: 1.1s; animation-duration: 16s; animation-name: veo-star-drift-2; }
    /* Белые звёзды — разные размеры (1px, 2px, 3px) */
    .veo-cosmic-star--white.veo-cosmic-star--twinkle:nth-child(113) { left: 4%; top: 6%; width: 1px; height: 1px; animation-delay: 0s; }
    .veo-cosmic-star--white.veo-cosmic-star--twinkle:nth-child(114) { left: 11%; top: 22%; width: 3px; height: 3px; animation-delay: 0.3s; }
    .veo-cosmic-star--white.veo-cosmic-star--twinkle:nth-child(115) { left: 19%; top: 48%; width: 1px; height: 1px; animation-delay: 0.6s; }
    .veo-cosmic-star--white.veo-cosmic-star--twinkle:nth-child(116) { left: 27%; top: 14%; width: 2px; height: 2px; animation-delay: 0.9s; }
    .veo-cosmic-star--white.veo-cosmic-star--twinkle:nth-child(117) { left: 34%; top: 72%; width: 1px; height: 1px; animation-delay: 0.2s; }
    .veo-cosmic-star--white.veo-cosmic-star--twinkle:nth-child(118) { left: 43%; top: 32%; width: 3px; height: 3px; animation-delay: 0.5s; }
    .veo-cosmic-star--white.veo-cosmic-star--twinkle:nth-child(119) { left: 51%; top: 88%; width: 2px; height: 2px; animation-delay: 0.8s; }
    .veo-cosmic-star--white.veo-cosmic-star--twinkle:nth-child(120) { left: 58%; top: 18%; width: 1px; height: 1px; animation-delay: 0.1s; }
    .veo-cosmic-star--white.veo-cosmic-star--twinkle:nth-child(121) { left: 66%; top: 56%; width: 3px; height: 3px; animation-delay: 0.4s; }
    .veo-cosmic-star--white.veo-cosmic-star--twinkle:nth-child(122) { left: 73%; top: 8%; width: 2px; height: 2px; animation-delay: 0.7s; }
    .veo-cosmic-star--white.veo-cosmic-star--twinkle:nth-child(123) { left: 81%; top: 42%; width: 1px; height: 1px; animation-delay: 0s; }
    .veo-cosmic-star--white.veo-cosmic-star--twinkle:nth-child(124) { left: 89%; top: 76%; width: 3px; height: 3px; animation-delay: 0.3s; }
    .veo-cosmic-star--white.veo-cosmic-star--twinkle:nth-child(125) { left: 96%; top: 28%; width: 1px; height: 1px; animation-delay: 0.6s; }
    .veo-cosmic-star--white.veo-cosmic-star--twinkle:nth-child(126) { left: 6%; top: 38%; width: 2px; height: 2px; animation-delay: 0.9s; }
    .veo-cosmic-star--white.veo-cosmic-star--twinkle:nth-child(127) { left: 14%; top: 64%; width: 1px; height: 1px; animation-delay: 0.2s; }
    .veo-cosmic-star--white.veo-cosmic-star--twinkle:nth-child(128) { left: 23%; top: 92%; width: 3px; height: 3px; animation-delay: 0.5s; }
    .veo-cosmic-star--white.veo-cosmic-star--twinkle:nth-child(129) { left: 31%; top: 44%; width: 2px; height: 2px; animation-delay: 0.8s; }
    .veo-cosmic-star--white.veo-cosmic-star--twinkle:nth-child(130) { left: 39%; top: 12%; width: 1px; height: 1px; animation-delay: 0.1s; }
    .veo-cosmic-star--white.veo-cosmic-star--twinkle:nth-child(131) { left: 47%; top: 58%; width: 3px; height: 3px; animation-delay: 0.4s; }
    .veo-cosmic-star--white.veo-cosmic-star--twinkle:nth-child(132) { left: 55%; top: 84%; width: 1px; height: 1px; animation-delay: 0.7s; }
    .veo-cosmic-star--white.veo-cosmic-star--twinkle:nth-child(133) { left: 63%; top: 24%; width: 2px; height: 2px; animation-delay: 0s; }
    .veo-cosmic-star--white.veo-cosmic-star--twinkle:nth-child(134) { left: 71%; top: 52%; width: 1px; height: 1px; animation-delay: 0.3s; }
    .veo-cosmic-star--white.veo-cosmic-star--twinkle:nth-child(135) { left: 79%; top: 16%; width: 3px; height: 3px; animation-delay: 0.6s; }
    .veo-cosmic-star--white.veo-cosmic-star--twinkle:nth-child(136) { left: 87%; top: 68%; width: 2px; height: 2px; animation-delay: 0.9s; }
    .veo-cosmic-star--white.veo-cosmic-star--twinkle:nth-child(137) { left: 2%; top: 52%; width: 1px; height: 1px; animation-delay: 0.2s; }
    .veo-cosmic-star--white.veo-cosmic-star--twinkle:nth-child(138) { left: 9%; top: 78%; width: 3px; height: 3px; animation-delay: 0.5s; }
    .veo-cosmic-star--white.veo-cosmic-star--twinkle:nth-child(139) { left: 17%; top: 34%; width: 2px; height: 2px; animation-delay: 0.8s; }
    .veo-cosmic-star--white.veo-cosmic-star--twinkle:nth-child(140) { left: 25%; top: 6%; width: 1px; height: 1px; animation-delay: 0.1s; }
    .veo-cosmic-star--white.veo-cosmic-star--twinkle:nth-child(141) { left: 37%; top: 62%; width: 3px; height: 3px; animation-delay: 0.4s; }
    .veo-cosmic-star--white.veo-cosmic-star--twinkle:nth-child(142) { left: 46%; top: 26%; width: 1px; height: 1px; animation-delay: 0.7s; }
    .veo-cosmic-star--white.veo-cosmic-star--twinkle:nth-child(143) { left: 54%; top: 94%; width: 2px; height: 2px; animation-delay: 0s; }
    .veo-cosmic-star--white.veo-cosmic-star--twinkle:nth-child(144) { left: 62%; top: 46%; width: 1px; height: 1px; animation-delay: 0.3s; }
    .veo-cosmic-star--white.veo-cosmic-star--twinkle:nth-child(145) { left: 70%; top: 82%; width: 3px; height: 3px; animation-delay: 0.6s; }
    .veo-cosmic-star--white.veo-cosmic-star--twinkle:nth-child(146) { left: 78%; top: 38%; width: 2px; height: 2px; animation-delay: 0.9s; }
    .veo-cosmic-star--white.veo-cosmic-star--twinkle:nth-child(147) { left: 86%; top: 14%; width: 1px; height: 1px; animation-delay: 0.2s; }
    .veo-cosmic-star--white.veo-cosmic-star--twinkle:nth-child(148) { left: 94%; top: 58%; width: 3px; height: 3px; animation-delay: 0.5s; }
    .veo-cosmic-star--white.veo-cosmic-star--twinkle:nth-child(149) { left: 8%; top: 44%; width: 1px; height: 1px; animation-delay: 0.8s; }
    .veo-cosmic-star--white.veo-cosmic-star--twinkle:nth-child(150) { left: 52%; top: 12%; width: 2px; height: 2px; animation-delay: 0.1s; }
    .veo-cosmic-star--white.veo-cosmic-star--twinkle:nth-child(151) { left: 74%; top: 66%; width: 1px; height: 1px; animation-delay: 0.4s; }
    .veo-cosmic-star--white.veo-cosmic-star--twinkle:nth-child(152) { left: 92%; top: 32%; width: 3px; height: 3px; animation-delay: 0.7s; }
    .veo-cosmic-star--white.veo-cosmic-star--move:nth-child(153) { left: 8%; top: 20%; width: 2px; height: 2px; animation-delay: 0s; animation-duration: 12s; }
    .veo-cosmic-star--white.veo-cosmic-star--move:nth-child(154) { left: 24%; top: 52%; width: 1px; height: 1px; animation-delay: 1s; animation-duration: 14s; animation-name: veo-star-drift-2; }
    .veo-cosmic-star--white.veo-cosmic-star--move:nth-child(155) { left: 42%; top: 8%; width: 3px; height: 3px; animation-delay: 0.5s; animation-duration: 11s; }
    .veo-cosmic-star--white.veo-cosmic-star--move:nth-child(156) { left: 58%; top: 72%; width: 1px; height: 1px; animation-delay: 1.5s; animation-duration: 16s; animation-name: veo-star-drift-2; }
    .veo-cosmic-star--white.veo-cosmic-star--move:nth-child(157) { left: 76%; top: 36%; width: 2px; height: 2px; animation-delay: 0.3s; animation-duration: 13s; }
    .veo-cosmic-star--white.veo-cosmic-star--move:nth-child(158) { left: 4%; top: 68%; width: 1px; height: 1px; animation-delay: 1.2s; animation-duration: 15s; animation-name: veo-star-drift-2; }
    .veo-cosmic-star--white.veo-cosmic-star--move:nth-child(159) { left: 36%; top: 44%; width: 3px; height: 3px; animation-delay: 0.7s; animation-duration: 10s; }
    .veo-cosmic-star--white.veo-cosmic-star--move:nth-child(160) { left: 68%; top: 16%; width: 2px; height: 2px; animation-delay: 0.2s; animation-duration: 17s; animation-name: veo-star-drift-2; }
    .veo-cosmic-star--white.veo-cosmic-star--move:nth-child(161) { left: 88%; top: 84%; width: 1px; height: 1px; animation-delay: 1.8s; animation-duration: 12s; }
    .veo-cosmic-star--white.veo-cosmic-star--move:nth-child(162) { left: 16%; top: 92%; width: 2px; height: 2px; animation-delay: 0.6s; animation-duration: 14s; animation-name: veo-star-drift-2; }
    .veo-cosmic-star--move {
        animation: veo-star-drift 10s ease-in-out infinite;
    }
    .veo-cosmic-star--move:nth-child(31) { left: 5%; top: 20%; width: 2px; height: 2px; animation-delay: 0s; animation-duration: 14s; }
    .veo-cosmic-star--move:nth-child(32) { left: 30%; top: 5%; width: 1px; height: 1px; animation-delay: 1s; animation-duration: 16s; animation-name: veo-star-drift-2; }
    .veo-cosmic-star--move:nth-child(33) { left: 60%; top: 30%; width: 2px; height: 2px; animation-delay: 2s; animation-duration: 11s; }
    .veo-cosmic-star--move:nth-child(34) { left: 80%; top: 60%; width: 1px; height: 1px; animation-delay: 0.5s; animation-duration: 13s; animation-name: veo-star-drift-2; }
    .veo-cosmic-star--move:nth-child(35) { left: 45%; top: 80%; width: 2px; height: 2px; animation-delay: 1.5s; animation-duration: 15s; }
    .veo-cosmic-star--move:nth-child(36) { left: 10%; top: 55%; width: 1px; height: 1px; animation-delay: 2.5s; animation-duration: 12s; animation-name: veo-star-drift-2; }
    .veo-cosmic-star--move:nth-child(37) { left: 70%; top: 12%; width: 2px; height: 2px; animation-delay: 0.75s; animation-duration: 17s; }
    .veo-cosmic-star--move:nth-child(38) { left: 50%; top: 45%; width: 1px; height: 1px; animation-delay: 1.25s; animation-duration: 10s; animation-name: veo-star-drift-2; }
    .veo-cosmic-star--move:nth-child(39) { left: 95%; top: 70%; width: 2px; height: 2px; animation-delay: 0.25s; animation-duration: 14s; }
    .veo-cosmic-star--move:nth-child(40) { left: 3%; top: 88%; width: 1px; height: 1px; animation-delay: 1.75s; animation-duration: 18s; animation-name: veo-star-drift-2; }
    .veo-cosmic-star--move:nth-child(41) { left: 20%; top: 40%; width: 2px; height: 2px; animation-delay: 0.5s; animation-duration: 15s; }
    .veo-cosmic-star--move:nth-child(42) { left: 55%; top: 15%; width: 1px; height: 1px; animation-delay: 1.5s; animation-duration: 13s; animation-name: veo-star-drift-2; }
    .veo-cosmic-star--move:nth-child(43) { left: 85%; top: 35%; width: 2px; height: 2px; animation-delay: 2s; animation-duration: 16s; }
    .veo-cosmic-star--move:nth-child(44) { left: 35%; top: 65%; width: 1px; height: 1px; animation-delay: 0.8s; animation-duration: 14s; animation-name: veo-star-drift-2; }
    .veo-cosmic-star--move:nth-child(45) { left: 72%; top: 85%; width: 2px; height: 2px; animation-delay: 1.2s; animation-duration: 12s; }
    .veo-cosmic-star--move:nth-child(66) { left: 2%; top: 32%; width: 2px; height: 2px; animation-delay: 0.3s; animation-duration: 13s; }
    .veo-cosmic-star--move:nth-child(67) { left: 40%; top: 10%; width: 1px; height: 1px; animation-delay: 1.1s; animation-duration: 15s; animation-name: veo-star-drift-2; }
    .veo-cosmic-star--move:nth-child(68) { left: 75%; top: 52%; width: 2px; height: 2px; animation-delay: 1.8s; animation-duration: 11s; }
    .veo-cosmic-star--move:nth-child(69) { left: 15%; top: 75%; width: 1px; height: 1px; animation-delay: 0.6s; animation-duration: 17s; animation-name: veo-star-drift-2; }
    .veo-cosmic-star--move:nth-child(70) { left: 58%; top: 88%; width: 2px; height: 2px; animation-delay: 1.4s; animation-duration: 12s; }
    .veo-cosmic-star--move:nth-child(71) { left: 92%; top: 22%; width: 1px; height: 1px; animation-delay: 0.2s; animation-duration: 14s; animation-name: veo-star-drift-2; }
    .veo-cosmic-star--move:nth-child(72) { left: 28%; top: 48%; width: 2px; height: 2px; animation-delay: 1.6s; animation-duration: 16s; }
    .veo-cosmic-star--move:nth-child(73) { left: 65%; top: 68%; width: 1px; height: 1px; animation-delay: 0.9s; animation-duration: 10s; animation-name: veo-star-drift-2; }
    .veo-cosmic-star--move:nth-child(74) { left: 8%; top: 15%; width: 2px; height: 2px; animation-delay: 1.2s; animation-duration: 18s; }
    .veo-cosmic-star--move:nth-child(75) { left: 85%; top: 92%; width: 1px; height: 1px; animation-delay: 0.5s; animation-duration: 14s; animation-name: veo-star-drift-2; }
    .veo-cosmic-star--move:nth-child(91) { left: 11%; top: 26%; width: 2px; height: 2px; animation-delay: 0.4s; animation-duration: 15s; }
    .veo-cosmic-star--move:nth-child(92) { left: 46%; top: 8%; width: 1px; height: 1px; animation-delay: 1.2s; animation-duration: 12s; animation-name: veo-star-drift-2; }
    .veo-cosmic-star--move:nth-child(93) { left: 78%; top: 44%; width: 2px; height: 2px; animation-delay: 1.8s; animation-duration: 14s; }
    .veo-cosmic-star--move:nth-child(94) { left: 6%; top: 68%; width: 1px; height: 1px; animation-delay: 0.7s; animation-duration: 16s; animation-name: veo-star-drift-2; }
    .veo-cosmic-star--move:nth-child(95) { left: 52%; top: 76%; width: 2px; height: 2px; animation-delay: 1.3s; animation-duration: 11s; }
    .veo-cosmic-star--move:nth-child(96) { left: 96%; top: 18%; width: 1px; height: 1px; animation-delay: 0.1s; animation-duration: 17s; animation-name: veo-star-drift-2; }
    .veo-cosmic-star--move:nth-child(97) { left: 34%; top: 56%; width: 2px; height: 2px; animation-delay: 1.5s; animation-duration: 13s; }
    .veo-cosmic-star--move:nth-child(98) { left: 68%; top: 24%; width: 1px; height: 1px; animation-delay: 0.9s; animation-duration: 10s; animation-name: veo-star-drift-2; }
    .veo-cosmic-star--move:nth-child(99) { left: 18%; top: 84%; width: 2px; height: 2px; animation-delay: 1.1s; animation-duration: 18s; }
    .veo-cosmic-star--move:nth-child(100) { left: 88%; top: 56%; width: 1px; height: 1px; animation-delay: 0.6s; animation-duration: 14s; animation-name: veo-star-drift-2; }
    /* Падающая звезда — пролетает через экран со светящимся следом */
    .veo-cosmic-star--shoot {
        width: 3px;
        height: 3px;
        top: 18%;
        opacity: 0.4;
        box-shadow: 0 0 8px rgba(255, 255, 255, 0.9), 0 0 16px rgba(255, 255, 255, 0.5);
        animation-timing-function: linear;
        animation-iteration-count: infinite;
    }
    .veo-cosmic-star--shoot::before {
        content: '';
        position: absolute;
        top: 50%;
        width: 35px;
        height: 2px;
        transform: translateY(-50%);
        background: linear-gradient(to right, transparent, rgba(255, 255, 255, 0.5));
        border-radius: 1px;
        box-shadow: 0 0 6px rgba(255, 255, 255, 0.3);
    }
    .veo-cosmic-star--shoot-ltr {
        left: -80px;
        animation-name: veo-shoot-ltr;
        animation-delay: 0s;
        animation-duration: 28s;
    }
    .veo-cosmic-star--shoot-ltr::before {
        left: 0;
        transform: translateY(-50%) translateX(-100%);
        background: linear-gradient(to right, transparent 0%, rgba(255, 255, 255, 0.2) 40%, rgba(255, 255, 255, 0.6) 100%);
    }
    .veo-cosmic-star--shoot-rtl {
        left: 100%;
        animation-name: veo-shoot-rtl;
        animation-delay: 9s;
        animation-duration: 28s;
    }
    .veo-cosmic-star--shoot-rtl::before {
        right: 0;
        left: auto;
        transform: translateY(-50%) translateX(100%);
        background: linear-gradient(to left, transparent 0%, rgba(255, 255, 255, 0.2) 40%, rgba(255, 255, 255, 0.6) 100%);
    }
    /* Падающие звёзды вверх и вниз */
    .veo-cosmic-star--shoot-up {
        left: 25%;
        top: 100%;
        animation-name: veo-shoot-up;
        animation-delay: 5s;
        animation-duration: 28s;
    }
    .veo-cosmic-star--shoot-up::before {
        left: 50%;
        top: 100%;
        width: 2px;
        height: 35px;
        transform: translateX(-50%);
        background: linear-gradient(to bottom, rgba(255, 255, 255, 0.6) 0%, rgba(255, 255, 255, 0.2) 60%, transparent 100%);
    }
    .veo-cosmic-star--shoot-down {
        left: 75%;
        top: -20px;
        animation-name: veo-shoot-down;
        animation-delay: 14s;
        animation-duration: 28s;
    }
    .veo-cosmic-star--shoot-down::before {
        left: 50%;
        top: 0;
        width: 2px;
        height: 35px;
        transform: translateX(-50%) translateY(-100%);
        background: linear-gradient(to top, rgba(255, 255, 255, 0.6) 0%, rgba(255, 255, 255, 0.2) 60%, transparent 100%);
    }
    /* Дополнительные падающие звёзды — разные позиции */
    .veo-cosmic-star--shoot-alt {
        top: 45%;
    }
    .veo-cosmic-star--shoot-alt.veo-cosmic-star--shoot-ltr {
        animation-delay: 4s;
        animation-duration: 28s;
    }
    .veo-cosmic-star--shoot-alt.veo-cosmic-star--shoot-rtl {
        animation-delay: 12s;
        animation-duration: 28s;
    }
    @keyframes veo-star-twinkle {
        0%, 100% { opacity: 0.75; transform: scale(1); }
        50% { opacity: 1; transform: scale(1.4); }
    }
    /* Дрейфующие звёзды — цикл вперёд и назад, немного подвижнее */
    @keyframes veo-star-drift {
        0% { transform: translate(0, 0); opacity: 0.8; }
        25% { opacity: 1; }
        50% { transform: translate(35px, -50px); opacity: 1; }
        75% { opacity: 1; }
        100% { transform: translate(0, 0); opacity: 0.8; }
    }
    @keyframes veo-star-drift-2 {
        0% { transform: translate(0, 0); opacity: 0.8; }
        25% { opacity: 1; }
        50% { transform: translate(-30px, 40px); opacity: 1; }
        75% { opacity: 1; }
        100% { transform: translate(0, 0); opacity: 0.8; }
    }
    /* Падающие звёзды — быстро пролетают по краю */
    @keyframes veo-shoot-ltr {
        0% { transform: translateX(0); opacity: 0; }
        0.5% { opacity: 1; }
        4% { transform: translateX(calc(100vw + 100px)); opacity: 1; }
        4.5% { opacity: 0; }
        100% { opacity: 0; }
    }
    @keyframes veo-shoot-rtl {
        0% { transform: translateX(0); opacity: 0; }
        0.5% { opacity: 1; }
        4% { transform: translateX(calc(-100vw - 100px)); opacity: 1; }
        4.5% { opacity: 0; }
        100% { opacity: 0; }
    }
    @keyframes veo-shoot-up {
        0% { transform: translateY(0); opacity: 0; }
        0.5% { opacity: 1; }
        4% { transform: translateY(calc(-100vh - 100px)); opacity: 1; }
        4.5% { opacity: 0; }
        100% { opacity: 0; }
    }
    @keyframes veo-shoot-down {
        0% { transform: translateY(0); opacity: 0; }
        0.5% { opacity: 1; }
        4% { transform: translateY(calc(100vh + 100px)); opacity: 1; }
        4.5% { opacity: 0; }
        100% { opacity: 0; }
    }

    /* Пыльца феи — только над областью сообщений, не в поле ввода */
    .veo-fairy-dust {
        position: absolute;
        top: 0;
        left: 0;
        right: 0;
        bottom: 120px;
        pointer-events: none;
        z-index: 5;
        overflow: visible;
    }
    .veo-fairy-wrap {
        position: absolute;
        width: 0;
        height: 0;
        left: 0;
        top: 0;
        pointer-events: none;
    }
    .veo-fairy-dot {
        position: absolute;
        left: 0;
        top: 0;
        width: 10px;
        height: 10px;
        margin-left: -5px;
        margin-top: -5px;
        border-radius: 50%;
        animation: veo-fairy-scatter 0.7s ease-out forwards;
        pointer-events: none;
    }
    .veo-fairy-white {
        background: rgba(255, 255, 255, 0.95);
        box-shadow: 0 0 12px rgba(255,255,255,0.8), 0 0 24px rgba(255,255,255,0.4);
    }
    .veo-fairy-gold {
        background: rgba(255, 230, 180, 0.9);
        box-shadow: 0 0 10px rgba(255, 220, 150, 0.7), 0 0 20px rgba(255, 200, 100, 0.3);
    }
    .veo-fairy-pink {
        background: rgba(255, 200, 220, 0.9);
        box-shadow: 0 0 10px rgba(255, 180, 210, 0.6), 0 0 20px rgba(255, 150, 180, 0.25);
    }
    .veo-fairy-blue {
        background: rgba(200, 230, 255, 0.9);
        box-shadow: 0 0 10px rgba(180, 220, 255, 0.6), 0 0 20px rgba(150, 200, 255, 0.25);
    }
    @keyframes veo-fairy-scatter {
        0% { transform: translate(0, 0) scale(1); opacity: 1; }
        100% { transform: translate(0, -52px) scale(0.15); opacity: 0; }
    }

    .veo-chat-title {
        font-size: 0.9rem;
        font-weight: 500;
        color: rgba(255, 255, 255, 0.45);
        text-align: center;
        margin-bottom: 0.75rem;
        letter-spacing: 0.04em;
        padding: 0 1rem;
        text-transform: none;
    }

    .veo-chat-body {
        position: relative;
        flex: 1;
        display: flex;
        flex-direction: column;
        min-height: 0;
        gap: 0;
        border-radius: var(--radius-lg);
        overflow: visible;
    }

    .veo-chat-messages {
        position: relative;
        flex: 1;
        min-height: 0;
        overflow-y: auto;
        display: flex;
        flex-direction: column;
        gap: 1rem;
        transition: min-height 0.05s ease-out;
        scrollbar-width: thin;
        scrollbar-color: rgba(255, 255, 255, 0.25) rgba(255, 255, 255, 0.04);
    }
    .veo-chat-messages::-webkit-scrollbar {
        width: 6px;
    }
    .veo-chat-messages::-webkit-scrollbar-track {
        background: rgba(255, 255, 255, 0.04);
        border-radius: 3px;
    }
    .veo-chat-messages::-webkit-scrollbar-thumb {
        background: rgba(255, 255, 255, 0.2);
        border-radius: 3px;
    }
    .veo-chat-messages::-webkit-scrollbar-thumb:hover {
        background: rgba(255, 255, 255, 0.35);
    }
    .veo-chat-messages::-webkit-scrollbar-button {
        display: none;
    }

    .veo-chat-messages:has(.veo-welcome-chat)::before {
        content: '';
        display: block;
        flex: 0.2;
        min-height: 20px;
    }
    .veo-chat-messages:has(.veo-welcome-chat)::after {
        content: '';
        display: block;
        flex: 1;
        min-height: 40px;
    }
    .veo-chat-messages:empty::after {
        content: '';
        display: block;
        flex: 1;
        min-height: 80px;
    }

    /* Приветственный блок в чате — по центру экрана */
    .veo-welcome-chat {
        flex: 0 0 auto;
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        text-align: center;
        padding: 2rem 1.5rem;
        min-height: 200px;
    }
    .veo-welcome-chat-icon {
        width: 72px;
        height: 72px;
        margin-bottom: 1.25rem;
    }
    /* Космический стиль иконки ИИ — единый для всех нейросетей (Veo, Kling, будущие) */
    .veo-ai-icon-badge,
    .veo-google-g-badge {
        display: inline-flex;
        align-items: center;
        justify-content: center;
        border-radius: 18px;
        background: linear-gradient(135deg, #0f0c29 0%, #1e1b4b 30%, #312e81 60%, #4c1d95 100%);
        box-shadow: 0 4px 24px rgba(99, 102, 241, 0.35), 0 0 40px rgba(139, 92, 246, 0.15), 0 0 0 1px rgba(255, 255, 255, 0.08) inset;
        position: relative;
        overflow: hidden;
    }
    .veo-google-g-badge {
        animation: veo-icon-glow 4s ease-in-out infinite;
    }
    .veo-google-g-badge::before {
        content: '';
        position: absolute;
        inset: 0;
        border-radius: inherit;
        background: radial-gradient(ellipse 80% 80% at 30% 20%, rgba(255,255,255,0.12), transparent 60%);
        pointer-events: none;
        animation: veo-icon-aurora 6s ease-in-out infinite;
    }
    .veo-google-g-badge::after {
        content: '';
        position: absolute;
        inset: 0;
        border-radius: inherit;
        background: linear-gradient(135deg, rgba(255,255,255,0.08) 0%, transparent 45%, rgba(255,255,255,0.04) 100%);
        pointer-events: none;
    }
    @keyframes veo-icon-glow {
        0%, 100% { box-shadow: 0 4px 24px rgba(99, 102, 241, 0.35), 0 0 40px rgba(139, 92, 246, 0.15), 0 0 0 1px rgba(255, 255, 255, 0.08) inset; }
        50% { box-shadow: 0 4px 28px rgba(99, 102, 241, 0.45), 0 0 50px rgba(139, 92, 246, 0.25), 0 0 0 1px rgba(255, 255, 255, 0.12) inset; }
    }
    @keyframes veo-icon-aurora {
        0%, 100% { opacity: 0.6; }
        50% { opacity: 1; }
    }
    .veo-google-g-badge {
        width: 72px;
        height: 72px;
    }
    .veo-google-g-badge-sm {
        width: 28px;
        height: 28px;
        border-radius: 8px;
        margin-right: 0.5rem;
    }
    .veo-google-g-icon {
        display: block;
        width: 65%;
        height: 65%;
        background: linear-gradient(135deg, #fff 0%, #e0e7ff 40%, #c4b5fd 70%, #a5b4fc 100%);
        mask-size: contain;
        mask-repeat: no-repeat;
        mask-position: center;
        -webkit-mask-size: contain;
        -webkit-mask-repeat: no-repeat;
        -webkit-mask-position: center;
        position: relative;
        z-index: 1;
        filter: drop-shadow(0 0 6px rgba(196, 181, 253, 0.6)) drop-shadow(0 0 2px rgba(255, 255, 255, 0.8));
    }
    .veo-google-g-badge-sm .veo-google-g-icon {
        width: 60%;
        height: 60%;
    }
    .veo-welcome-chat-title {
        font-size: 1.5rem;
        font-weight: 600;
        color: var(--text-primary);
        margin: 0 0 1rem;
        letter-spacing: -0.02em;
    }
    .veo-welcome-chat-desc {
        font-size: 0.95rem;
        color: var(--text-secondary);
        line-height: 1.55;
        margin: 0 0 0.75rem;
        max-width: 580px;
    }
    .veo-welcome-chat-action {
        font-size: 0.9rem;
        color: var(--text-muted);
        line-height: 1.5;
        margin: 0;
        max-width: 580px;
    }

    /* Блоки сообщений/видео внутри чата (добавляются из JS после генерации) */
    .veo-chat-messages .veo-video-block {
        flex: 0 0 auto;
    }

    .veo-video-block {
        flex: 1;
        display: flex;
        flex-direction: column;
        gap: 0.75rem;
    }

    .veo-video-wrapper {
        position: relative;
        width: 100%;
        max-width: 960px;
        margin: 0 auto;
        aspect-ratio: 16 / 9;
        border-radius: 8px;
        overflow: hidden;
        background: #111114;
    }

    .veo-video-placeholder {
        position: absolute;
        inset: 0;
        background: #111114;
    }

    .veo-video-controls {
        position: absolute;
        left: 1rem;
        top: 50%;
        transform: translateY(-50%);
        display: flex;
        flex-direction: column;
        gap: 0.5rem;
        z-index: 2;
    }

    .veo-video-ctrl {
        width: 36px;
        height: 36px;
        display: flex;
        align-items: center;
        justify-content: center;
        background: rgba(0, 0, 0, 0.4);
        border: none;
        border-radius: 50%;
        color: rgba(255, 255, 255, 0.9);
        cursor: pointer;
        transition: background 0.15s;
    }

    .veo-video-ctrl:hover {
        background: rgba(0, 0, 0, 0.6);
    }

    .veo-video-ctrl svg {
        width: 16px;
        height: 16px;
    }

    .veo-chat-bubble {
        position: absolute;
        top: 1rem;
        right: 1rem;
        max-width: 220px;
        padding: 0.65rem 0.9rem;
        border-radius: 10px;
        background: rgba(0, 0, 0, 0.7);
        color: #fff;
        font-size: 0.875rem;
        line-height: 1.4;
        display: flex;
        flex-direction: column;
        gap: 0.25rem;
        z-index: 2;
    }

    .veo-chat-bubble-time {
        font-size: 0.7rem;
        color: rgba(255, 255, 255, 0.5);
    }

    .veo-video-progress {
        position: absolute;
        bottom: 1rem;
        left: 50%;
        transform: translateX(-50%);
        z-index: 2;
    }

    .veo-video-time {
        padding: 0.25rem 0.6rem;
        border-radius: 4px;
        font-size: 0.75rem;
        background: rgba(0, 0, 0, 0.6);
        color: rgba(255, 255, 255, 0.9);
    }

    .veo-video-timestamp {
        font-size: 0.8rem;
        color: var(--text-muted);
    }

    /* Поле промпта — стильный блок с анимацией по контуру, ограниченная ширина.
       flex-shrink: 0 — не сжимается; margin-top: auto — прижат к низу.
       При росте текста/фото блок расширяется вверх, а не уходит вниз. */
    .veo-prompt-wrapper {
        margin-top: auto;
        flex-shrink: 0;
        padding-top: 1rem;
        max-width: 820px;
        margin-left: auto;
        margin-right: auto;
        width: 100%;
    }

    .veo-prompt-box {
        position: relative;
        display: flex;
        flex-direction: column;
        border-radius: var(--radius-md);
        overflow: visible;
        isolation: isolate;
        background: linear-gradient(135deg, rgba(12, 12, 22, 0.98) 0%, rgba(8, 8, 18, 0.99) 100%);
        box-shadow: 0 4px 24px rgba(0, 0, 0, 0.5), inset 0 1px 0 rgba(255, 255, 255, 0.02), 0 0 20px rgba(99, 102, 241, 0.08);
        border: 1px solid rgba(255, 255, 255, 0.06);
    }
    .veo-prompt-box::before {
        content: '';
        position: absolute;
        inset: 0;
        border-radius: inherit;
        padding: 3px;
        background: linear-gradient(90deg, #6366f1, #8b5cf6, #06b6d4, #a78bfa, #6366f1);
        background-size: 400% 100%;
        background-position: 0% 50%;
        animation: veo-prompt-border-flow 2.5s linear infinite;
        -webkit-mask-image: linear-gradient(#fff 0 0), linear-gradient(#fff 0 0);
        -webkit-mask-size: 100% 100%, 100% 100%;
        -webkit-mask-position: 0 0, 0 0;
        -webkit-mask-origin: padding-box, content-box;
        -webkit-mask-repeat: no-repeat;
        -webkit-mask-composite: xor;
        mask-image: linear-gradient(#fff 0 0), linear-gradient(#fff 0 0);
        mask-size: 100% 100%, 100% 100%;
        mask-position: 0 0, 0 0;
        mask-origin: padding-box, content-box;
        mask-repeat: no-repeat;
        mask-composite: exclude;
        filter: drop-shadow(0 0 6px rgba(99, 102, 241, 0.3));
        pointer-events: none;
        z-index: 0;
    }
    /* Без яркой анимации по контуру, когда добавлены фото — ровная обводка как у области ввода */
    .veo-prompt-box.veo-prompt-box--has-attachments::before,
    .veo-prompt-box.veo-prompt-box--has-attachments:focus-within::before {
        animation: none;
        background: linear-gradient(90deg, rgba(99, 102, 241, 0.3), rgba(139, 92, 246, 0.3), rgba(99, 102, 241, 0.3));
        background-size: 100% 100%;
        background-position: 0 0;
    }
    .veo-prompt-input-zone,
    .veo-prompt-control-bar {
        position: relative;
        z-index: 1;
    }
    .veo-prompt-box:focus-within {
        border-color: rgba(99, 102, 241, 0.25);
        box-shadow: 0 0 16px rgba(99, 102, 241, 0.15), 0 4px 24px rgba(0, 0, 0, 0.5), 0 0 30px rgba(99, 102, 241, 0.12);
    }
    .veo-prompt-box:focus-within::before {
        background: linear-gradient(90deg, #6366f1, #8b5cf6, #06b6d4, #a78bfa, #6366f1);
        background-size: 400% 100%;
        animation-duration: 2s;
        filter: drop-shadow(0 0 8px rgba(99, 102, 241, 0.4));
    }
    @keyframes veo-prompt-border-flow {
        0% { background-position: 0% 50%; }
        100% { background-position: 400% 50%; }
    }

    .veo-prompt-input-zone {
        position: relative;
        flex: 1;
        min-height: 0;
        padding: 0.85rem 1.25rem 0.75rem;
        padding-left: 1.25rem;
        background: linear-gradient(180deg, rgba(15, 15, 28, 0.9) 0%, rgba(10, 10, 22, 0.95) 100%);
        border-radius: var(--radius-md) var(--radius-md) 0 0;
    }

    .veo-prompt-control-bar {
        position: relative;
        display: flex;
        align-items: center;
        justify-content: space-between;
        gap: clamp(0.35rem, 1.5vw, 0.5rem);
        padding: 0.5rem 0.85rem 0.6rem;
        min-height: 36px;
        flex-wrap: nowrap;
        background: linear-gradient(180deg, rgba(18, 18, 32, 0.98) 0%, rgba(14, 14, 26, 0.99) 100%);
        border-top: none;
        border-radius: 0 0 var(--radius-md) var(--radius-md);
        overflow: visible;
    }
    .veo-prompt-control-bar::before {
        content: '';
        position: absolute;
        left: 0;
        right: 0;
        top: 0;
        height: 1px;
        background: var(--veo-divider-h);
    }
    .veo-prompt-control-left {
        display: flex;
        align-items: center;
        gap: 0.35rem;
        overflow: visible;
        flex-shrink: 0;
    }
    .veo-photo-upload-wrap {
        position: relative;
        overflow: visible;
    }
    .veo-photo-upload-btn {
        position: relative;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        width: 36px;
        height: 36px;
        padding: 0;
        background: rgba(255, 255, 255, 0.05);
        border: 1px solid rgba(255, 255, 255, 0.08);
        border-radius: 10px;
        color: rgba(255, 255, 255, 0.5);
        cursor: pointer;
        font-variant-numeric: tabular-nums;
        transition: background 0.2s, color 0.2s, border-color 0.2s;
        flex-shrink: 0;
    }
    .veo-photo-upload-btn:hover {
        background: rgba(255, 255, 255, 0.08);
        border-color: rgba(255, 255, 255, 0.12);
        color: rgba(255, 255, 255, 0.85);
    }
    .veo-photo-upload-icon {
        width: 16px;
        height: 16px;
        flex-shrink: 0;
    }
    .veo-photo-upload-label {
        display: none;
    }
    .veo-photo-upload-counter {
        position: absolute;
        bottom: -2px;
        right: -2px;
        min-width: 14px;
        height: 14px;
        padding: 0 3px;
        font-size: 0.6rem;
        line-height: 14px;
        text-align: center;
        background: rgba(99, 102, 241, 0.9);
        border-radius: 7px;
        color: #fff;
    }
    .veo-photo-upload-dropdown {
        position: absolute;
        bottom: 100%;
        left: 0;
        margin-bottom: 3px;
        min-width: 220px;
        padding: 0.5rem 0;
        background: linear-gradient(180deg, rgba(28, 28, 42, 0.98) 0%, rgba(20, 20, 35, 0.99) 100%);
        border: 1px solid rgba(99, 102, 241, 0.25);
        border-radius: var(--radius-md);
        box-shadow: 0 8px 24px rgba(0, 0, 0, 0.5), 0 0 12px rgba(99, 102, 241, 0.08);
        z-index: 100;
        opacity: 0;
        visibility: hidden;
        transform: translateY(3px);
        transition: opacity 0.2s, visibility 0.2s, transform 0.2s;
    }
    .veo-photo-upload-dropdown::after {
        content: '';
        position: absolute;
        top: 100%;
        left: 12px;
        border: 5px solid transparent;
        border-top-color: rgba(28, 28, 42, 0.98);
        filter: drop-shadow(0 1px 0 rgba(99, 102, 241, 0.2));
    }
    .veo-photo-upload-wrap[data-open="true"] .veo-photo-upload-dropdown {
        opacity: 1;
        visibility: visible;
        transform: translateY(0);
    }
    .veo-photo-upload-option {
        display: block;
        width: 100%;
        padding: 0.5rem 1rem;
        text-align: left;
        background: none;
        border: none;
        color: rgba(255, 255, 255, 0.95);
        font-size: 0.875rem;
        font-weight: 500;
        cursor: pointer;
        transition: background 0.15s;
    }
    .veo-photo-upload-option:hover {
        background: rgba(99, 102, 241, 0.15);
    }
    .veo-photo-upload-limit {
        position: relative;
        padding: 0.45rem 1rem;
        font-size: 0.8rem;
        color: rgba(255, 255, 255, 0.65);
        border-top: none;
    }
    .veo-photo-upload-limit::before {
        content: '';
        position: absolute;
        left: 0;
        right: 0;
        top: 0;
        height: 1px;
        background: var(--veo-divider-h);
    }
    .veo-prompt-control-right {
        display: flex;
        align-items: center;
        gap: clamp(0.3rem, 1vw, 0.4rem);
        overflow: visible;
        flex-shrink: 0;
    }

    .veo-prompt-enter-btn {
        flex-shrink: 0;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        width: 36px;
        height: 36px;
        padding: 0;
        background: rgba(255, 255, 255, 0.05);
        border: 1px solid rgba(255, 255, 255, 0.08);
        border-radius: 10px;
        color: rgba(255, 255, 255, 0.5);
        cursor: pointer;
        transition: background 0.2s, border-color 0.2s, color 0.2s, box-shadow 0.2s;
    }
    .veo-prompt-enter-btn:hover {
        background: rgba(255, 255, 255, 0.1);
        border-color: rgba(255, 255, 255, 0.15);
        color: rgba(255, 255, 255, 0.75);
    }
    .veo-prompt-enter-btn[aria-pressed="true"] {
        background: rgba(34, 197, 94, 0.2);
        border-color: rgba(34, 197, 94, 0.5);
        color: #22c55e;
        box-shadow: 0 0 0 1px rgba(34, 197, 94, 0.3), 0 0 16px rgba(34, 197, 94, 0.2);
    }
    .veo-prompt-enter-btn[aria-pressed="true"]:hover {
        background: rgba(34, 197, 94, 0.28);
        border-color: rgba(34, 197, 94, 0.5);
        box-shadow: 0 0 0 1px rgba(34, 197, 94, 0.4), 0 0 20px rgba(34, 197, 94, 0.3);
    }
    .veo-prompt-enter-icon {
        display: flex;
        align-items: center;
        justify-content: center;
    }
    .veo-prompt-enter-icon svg {
        width: 16px;
        height: 16px;
    }
    .veo-prompt-enter-label {
        display: none;
    }
    /* Выкл — замок закрыт */
    .veo-prompt-enter-btn .veo-prompt-enter-icon-unlocked {
        display: none;
    }
    .veo-prompt-enter-btn .veo-prompt-enter-icon-locked {
        display: flex;
    }
    /* Вкл — замок открыт */
    .veo-prompt-enter-btn[aria-pressed="true"] .veo-prompt-enter-icon-locked {
        display: none;
    }
    .veo-prompt-enter-btn[aria-pressed="true"] .veo-prompt-enter-icon-unlocked {
        display: flex;
    }

    .veo-prompt-input {
        width: 100%;
        min-height: 2.2rem;
        max-height: 168px;
        background: transparent;
        border: none;
        color: var(--text-primary, #fff);
        font-size: 0.95rem;
        font-family: inherit;
        resize: none;
        line-height: 1.5;
        overflow-y: auto;
        scrollbar-width: thin;
        scrollbar-color: rgba(255, 255, 255, 0.25) rgba(255, 255, 255, 0.04);
    }
    .veo-prompt-input::-webkit-scrollbar {
        width: 6px;
    }
    .veo-prompt-input::-webkit-scrollbar-track {
        background: rgba(255, 255, 255, 0.04);
        border-radius: 3px;
    }
    .veo-prompt-input::-webkit-scrollbar-thumb {
        background: rgba(255, 255, 255, 0.2);
        border-radius: 3px;
    }
    .veo-prompt-input::-webkit-scrollbar-thumb:hover {
        background: rgba(255, 255, 255, 0.35);
    }
    .veo-prompt-input::-webkit-scrollbar-button {
        display: none;
    }

    .veo-prompt-input::placeholder {
        color: rgba(255, 255, 255, 0.35);
    }

    .veo-prompt-input:focus {
        outline: none;
    }
    .veo-prompt-box:focus-within .veo-prompt-input::placeholder {
        color: rgba(255, 255, 255, 0.4);
    }

    .veo-prompt-actions {
        display: flex;
        align-items: center;
        gap: 0.5rem;
    }

    .veo-prompt-action {
        width: 36px;
        height: 36px;
        display: flex;
        align-items: center;
        justify-content: center;
        background: rgba(255, 255, 255, 0.05);
        border: 1px solid rgba(255, 255, 255, 0.08);
        border-radius: 10px;
        color: rgba(255, 255, 255, 0.5);
        cursor: pointer;
        transition: color 0.15s, background 0.15s, border-color 0.15s;
        flex-shrink: 0;
    }

    .veo-prompt-action:hover {
        color: rgba(255, 255, 255, 0.9);
        background: rgba(255, 255, 255, 0.08);
        border-color: rgba(255, 255, 255, 0.12);
    }

    .veo-prompt-action svg {
        width: 16px;
        height: 16px;
    }

    .veo-prompt-tokens {
        display: inline-flex;
        align-items: center;
        justify-content: center;
        gap: 0.2rem;
        font-size: 0.85rem;
        font-weight: 700;
        color: #fff;
        background: linear-gradient(135deg, rgba(99, 102, 241, 0.25) 0%, rgba(139, 92, 246, 0.2) 50%, rgba(6, 182, 212, 0.2) 100%);
        border: 1px solid rgba(99, 102, 241, 0.4);
        border-radius: 10px;
        padding: 0 0.85rem;
        min-width: 68px;
        height: 36px;
        box-shadow: 0 0 12px rgba(99, 102, 241, 0.25), 0 0 20px rgba(139, 92, 246, 0.1);
    }
    .veo-prompt-tokens.veo-cost-ok {
        color: #fff;
        background: rgba(34, 197, 94, 0.35);
        border-color: rgba(34, 197, 94, 0.5);
        box-shadow: 0 0 12px rgba(34, 197, 94, 0.25);
    }
    .veo-prompt-tokens.veo-cost-ok span {
        color: #fff;
    }
    .veo-prompt-tokens.veo-cost-low {
        color: #fff;
        background: rgba(239, 68, 68, 0.4);
        border-color: rgba(239, 68, 68, 0.6);
        box-shadow: 0 0 12px rgba(239, 68, 68, 0.3);
    }
    .veo-prompt-tokens.veo-cost-low span {
        color: #fff;
    }
    .veo-prompt-tokens span {
        font-weight: 600;
    }
    .veo-cost-brain {
        display: inline-block;
        animation: veo-rocket-spin 3s ease-in-out infinite;
    }

    .veo-prompt-send {
        position: relative;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        gap: 0.5rem;
        min-width: 36px;
        width: 36px;
        height: 36px;
        padding: 0;
        flex-shrink: 0;
        background: linear-gradient(135deg, rgba(99, 102, 241, 0.25) 0%, rgba(139, 92, 246, 0.2) 50%, rgba(6, 182, 212, 0.2) 100%);
        border: 1px solid rgba(99, 102, 241, 0.4);
        border-radius: 50%;
        color: #fff;
        font-weight: 700;
        font-size: 0.85rem;
        cursor: pointer;
        overflow: visible;
        transition: transform 0.35s ease, border-color 0.3s ease;
        animation: veo-btn-star-burn 3s ease-in-out infinite;
    }
    @keyframes veo-btn-star-burn {
        0%, 100% { box-shadow: 0 0 12px rgba(99, 102, 241, 0.25), 0 0 20px rgba(139, 92, 246, 0.1); }
        50% { box-shadow: 0 0 18px rgba(99, 102, 241, 0.4), 0 0 28px rgba(139, 92, 246, 0.2); }
    }
    .veo-prompt-send::before {
        content: '';
        position: absolute;
        inset: 0;
        border-radius: inherit;
        background: linear-gradient(110deg, transparent 30%, rgba(255, 255, 255, 0.25) 50%, transparent 70%);
        background-size: 200% 100%;
        background-position: 200% 0;
        opacity: 0;
        pointer-events: none;
        z-index: 0;
        transition: opacity 0.3s ease;
    }
    .veo-prompt-send:hover {
        border-color: rgba(139, 92, 246, 0.5);
        transform: scale(1.02);
        box-shadow: 0 0 18px rgba(99, 102, 241, 0.3), 0 0 32px rgba(139, 92, 246, 0.15);
        animation: veo-btn-glow 2.5s ease-in-out infinite;
    }
    .veo-prompt-send:hover::before {
        opacity: 1;
        animation: veo-btn-shimmer 2s ease-in-out infinite;
    }
    @keyframes veo-btn-shimmer {
        0% { background-position: 200% 0; }
        100% { background-position: -200% 0; }
    }
    @keyframes veo-btn-glow {
        0%, 100% { box-shadow: 0 0 18px rgba(99, 102, 241, 0.3), 0 0 32px rgba(139, 92, 246, 0.15); }
        50% { box-shadow: 0 0 24px rgba(99, 102, 241, 0.45), 0 0 40px rgba(139, 92, 246, 0.25); }
    }
    .veo-prompt-send:active {
        transform: scale(0.99);
    }
    .veo-prompt-send:disabled {
        opacity: 0.5;
        cursor: not-allowed;
        transform: none;
        animation: none;
        box-shadow: 0 0 12px rgba(99, 102, 241, 0.2);
    }
    .veo-prompt-send:disabled:hover {
        box-shadow: 0 0 12px rgba(99, 102, 241, 0.2);
        animation: none;
    }
    .veo-prompt-send:disabled:hover::before {
        opacity: 0;
        animation: none;
    }
    .veo-prompt-send-text,
    .veo-prompt-send-icon {
        position: relative;
        z-index: 1;
        display: flex;
        align-items: center;
    }
    .veo-prompt-send-text {
        display: none;
        font-weight: 700;
        line-height: 1;
    }
    .veo-prompt-send-icon {
        display: flex;
        align-items: center;
        justify-content: center;
    }
    .veo-prompt-send svg {
        width: 20px;
        height: 20px;
    }
    /* Иконка видеокамеры */
    .veo-icon-video {
        transition: transform 0.2s ease;
    }
    .veo-prompt-send:hover .veo-icon-video {
        transform: scale(1.05);
    }
    @media (min-width: 700px) {
        .veo-prompt-send {
            min-width: 120px;
            width: auto;
            height: 36px;
            padding: 0 1rem;
            border-radius: 18px;
        }
        .veo-prompt-send-text {
            display: inline-flex;
            align-items: center;
            white-space: nowrap;
            font-weight: 700;
            line-height: 1;
        }
        .veo-prompt-tokens {
            min-width: 76px;
            padding: 0 0.9rem;
            border-radius: 10px;
        }
    }

    .veo-mic-btn.veo-mic-recording {
        color: #e74c3c;
        background: rgba(231, 76, 60, 0.15);
        animation: veo-mic-pulse 1s ease-in-out infinite;
    }
    @keyframes veo-mic-pulse {
        0%, 100% { opacity: 1; }
        50% { opacity: 0.7; }
    }
    
    /* Превью загруженных изображений — миниатюры сверху области ввода */
    .veo-chat-attachments {
        display: flex;
        gap: 0.5rem;
        margin-bottom: 0;
        flex-wrap: wrap;
        padding: 0.85rem 1.25rem 0.5rem;
        background: linear-gradient(180deg, rgba(15, 15, 28, 0.9) 0%, rgba(10, 10, 22, 0.95) 100%);
        border-radius: var(--radius-md) var(--radius-md) 0 0;
        position: relative;
    }
    .veo-chat-attachments::after {
        content: '';
        position: absolute;
        left: 0;
        right: 0;
        bottom: 0;
        height: 1px;
        background: linear-gradient(90deg, transparent, rgba(99, 102, 241, 0.4), rgba(139, 92, 246, 0.4), rgba(6, 182, 212, 0.3), rgba(99, 102, 241, 0.4), transparent);
    }
    .veo-prompt-box:has(.veo-chat-attachments[style*="flex"]) .veo-prompt-input-zone {
        border-radius: 0;
    }
    
    .veo-chat-attachment-preview {
        position: relative;
        width: 48px;
        height: 48px;
        border-radius: 8px;
        overflow: hidden;
        border: 1px solid rgba(255, 255, 255, 0.1);
    }
    
    .veo-chat-attachment-preview img {
        width: 100%;
        height: 100%;
        object-fit: cover;
    }
    
    .veo-chat-attachment-remove {
        position: absolute;
        top: 2px;
        right: 2px;
        width: 18px;
        height: 18px;
        border-radius: 50%;
        background: rgba(0, 0, 0, 0.7);
        color: #fff;
        font-size: 12px;
        line-height: 1;
        display: flex;
        align-items: center;
        justify-content: center;
        cursor: pointer;
    }
    
    /* Правый сайдбар — настройки */
    .veo-right-settings {
        position: relative;
        width: 260px;
        min-width: 260px;
        background: var(--bg-primary);
        border-left: none;
        overflow: visible;
        padding: 1.25rem 1.25rem 2rem;
        display: flex;
        flex-direction: column;
        min-height: 0;
    }
    .veo-right-settings::before {
        content: '';
        position: absolute;
        top: 0;
        left: 0;
        bottom: 0;
        width: 1px;
        background: var(--veo-divider-v);
    }

    .veo-settings-chevron {
        width: 14px;
        height: 14px;
        opacity: 0.5;
        transition: transform 0.2s;
        /* По умолчанию секция раскрыта — стрелка вниз */
        transform: rotate(0deg);
    }
    /* Секция свёрнута — стрелка вверх */
    .veo-settings-section.collapsed .veo-settings-section-header .veo-settings-chevron {
        transform: rotate(180deg);
    }

    .veo-settings-reset-btn {
        display: flex;
        align-items: center;
        gap: 0.4rem;
        padding: 0.3rem 0.5rem;
        background: transparent;
        border: none;
        border-radius: 6px;
        color: var(--text-muted);
        font-size: 0.8rem;
        cursor: pointer;
        transition: color 0.15s, background 0.15s;
    }

    .veo-settings-reset-btn:hover {
        color: var(--text-secondary);
        background: rgba(255, 255, 255, 0.04);
    }

    .veo-settings-reset-btn svg {
        width: 12px;
        height: 12px;
    }
    
    .veo-settings-section {
        margin-bottom: 1rem;
    }
    .veo-settings-section[id="settingsModel"] {
        margin-top: -0.5rem;
    }
    /* Разделитель между блоками — второй блок (Настройки) с линией сверху */
    .veo-settings-section[id="settingsFormat"] {
        padding-top: 0.6rem;
        margin-top: 0.25rem;
        border-top: none;
        position: relative;
    }
    .veo-settings-section[id="settingsFormat"]::before {
        content: '';
        position: absolute;
        left: 0;
        right: 0;
        top: 0;
        height: 1px;
        background: var(--veo-divider-h);
    }
    
    .veo-settings-section-header {
        display: flex;
        align-items: center;
        justify-content: space-between;
        padding: 0.35rem 0;
        cursor: pointer;
        color: var(--text-primary);
        font-weight: 500;
        font-size: 0.875rem;
        user-select: none;
    }
    
    .veo-settings-section-header:hover {
        color: rgba(255, 255, 255, 0.9);
    }
    
    .veo-settings-section-header svg {
        width: 14px;
        height: 14px;
        opacity: 0.5;
        transition: transform 0.2s;
    }
    
    .veo-settings-section.collapsed .veo-settings-section-content {
        display: none;
    }
    
    .veo-settings-section-content {
        padding-top: 0.5rem;
    }
    
    .veo-settings-row {
        margin-bottom: 0.75rem;
    }
    
    .veo-settings-row-mode {
        margin-top: 0.75rem;
    }
    
    .veo-settings-row:last-child {
        margin-bottom: 0;
    }
    
    .veo-settings-label {
        display: flex;
        align-items: center;
        gap: 0.35rem;
        font-size: 0.8rem;
        color: var(--text-muted);
        margin-bottom: 0.35rem;
    }


    /* Кастомные дропдауны — стиль как кнопка «Создать видео» (фиолетовый градиент) */
    .veo-custom-select {
        position: relative;
        width: 100%;
    }

    .veo-custom-select-trigger {
        width: 100%;
        display: flex;
        align-items: center;
        justify-content: space-between;
        gap: 0.5rem;
        padding: 0.5rem 0.75rem;
        background: linear-gradient(135deg, rgba(99, 102, 241, 0.15) 0%, rgba(139, 92, 246, 0.1) 50%, rgba(6, 182, 212, 0.1) 100%);
        border: 1px solid rgba(99, 102, 241, 0.35);
        border-radius: 8px;
        color: var(--text-primary);
        font-size: 0.875rem;
        cursor: pointer;
        transition: border-color 0.2s, background 0.2s, box-shadow 0.2s;
        text-align: left;
        box-shadow: 0 0 10px rgba(99, 102, 241, 0.15);
    }

    .veo-custom-select-trigger:hover {
        background: linear-gradient(135deg, rgba(99, 102, 241, 0.2) 0%, rgba(139, 92, 246, 0.15) 50%, rgba(6, 182, 212, 0.12) 100%);
        border-color: rgba(139, 92, 246, 0.45);
        box-shadow: 0 0 14px rgba(99, 102, 241, 0.25);
    }

    .veo-custom-select.open .veo-custom-select-trigger {
        border-color: rgba(99, 102, 241, 0.5);
        background: linear-gradient(135deg, rgba(99, 102, 241, 0.25) 0%, rgba(139, 92, 246, 0.2) 50%, rgba(6, 182, 212, 0.15) 100%);
        box-shadow: 0 0 0 1px rgba(99, 102, 241, 0.4), 0 0 18px rgba(99, 102, 241, 0.3);
    }

    .veo-custom-select-label {
        flex: 1;
        overflow: hidden;
        text-overflow: ellipsis;
        white-space: nowrap;
    }

    .veo-custom-select-chevron {
        width: 14px;
        height: 14px;
        opacity: 0.6;
        flex-shrink: 0;
        transition: transform 0.2s;
        /* Закрыт — стрелка вверх */
        transform: rotate(180deg);
    }

    .veo-custom-select.open .veo-custom-select-chevron {
        /* Открыт — стрелка вниз */
        transform: rotate(0deg);
    }

    .veo-custom-select-dropdown {
        position: absolute;
        left: 0;
        right: 0;
        top: calc(100% + 4px);
        z-index: 100;
        background: linear-gradient(180deg, #1a1a1e 0%, #16161a 100%);
        border: 1px solid rgba(99, 102, 241, 0.25);
        border-radius: 8px;
        box-shadow: 0 8px 24px rgba(0, 0, 0, 0.4), 0 0 12px rgba(99, 102, 241, 0.1);
        max-height: 220px;
        overflow-y: auto;
        display: none;
    }

    .veo-custom-select.open .veo-custom-select-dropdown {
        display: block;
    }

    .veo-custom-select-option {
        padding: 0.5rem 0.75rem;
        font-size: 0.875rem;
        color: rgba(255, 255, 255, 0.85);
        cursor: pointer;
        transition: background 0.15s, color 0.15s;
        display: flex;
        align-items: center;
        gap: 0.5rem;
    }
    .veo-custom-select-option .veo-option-icon {
        flex-shrink: 0;
        margin-right: 0;
    }
    .veo-custom-select-option .veo-option-icon.veo-google-g-badge-sm {
        width: 22px;
        height: 22px;
    }

    .veo-custom-select-option:hover {
        background: linear-gradient(135deg, rgba(99, 102, 241, 0.12) 0%, rgba(139, 92, 246, 0.08) 100%);
        color: #fff;
    }

    .veo-custom-select-option.selected {
        background: linear-gradient(135deg, rgba(99, 102, 241, 0.25) 0%, rgba(139, 92, 246, 0.18) 100%);
        color: rgba(199, 210, 254, 1);
        border-radius: 6px;
        box-shadow: inset 0 0 8px rgba(99, 102, 241, 0.1);
    }

    .veo-option-placeholder {
        opacity: 0.7;
    }

    .veo-option-badge {
        font-size: 0.7rem;
        color: var(--text-muted);
        margin-left: 0.25rem;
    }
    
    .veo-settings-select {
        width: 100%;
        padding: 0.5rem 0.75rem;
        background: linear-gradient(135deg, rgba(99, 102, 241, 0.12) 0%, rgba(139, 92, 246, 0.08) 50%, rgba(6, 182, 212, 0.08) 100%);
        border: 1px solid rgba(99, 102, 241, 0.3);
        border-radius: 8px;
        color: var(--text-primary);
        font-size: 0.875rem;
        box-shadow: 0 0 8px rgba(99, 102, 241, 0.12);
    }
    
    .veo-settings-select:focus {
        outline: none;
        border-color: rgba(99, 102, 241, 0.5);
        box-shadow: 0 0 12px rgba(99, 102, 241, 0.25);
    }
    
    /* Модель — радио-карточки в правой панели */
    .veo-settings-model-options {
        display: flex;
        flex-direction: column;
        gap: 0.5rem;
    }
    
    .veo-settings-model-option {
        display: flex;
        align-items: center;
        gap: 0.5rem;
        padding: 0.5rem 0.75rem;
        background: linear-gradient(135deg, rgba(99, 102, 241, 0.08) 0%, rgba(139, 92, 246, 0.05) 100%);
        border: 1px solid rgba(99, 102, 241, 0.25);
        border-radius: 8px;
        cursor: pointer;
        transition: all 0.15s;
        box-shadow: 0 0 6px rgba(99, 102, 241, 0.1);
    }
    
    .veo-settings-model-option:hover {
        background: linear-gradient(135deg, rgba(99, 102, 241, 0.15) 0%, rgba(139, 92, 246, 0.1) 100%);
        border-color: rgba(99, 102, 241, 0.35);
        box-shadow: 0 0 10px rgba(99, 102, 241, 0.18);
    }
    
    .veo-settings-model-option.selected {
        border-color: rgba(99, 102, 241, 0.5);
        background: linear-gradient(135deg, rgba(99, 102, 241, 0.2) 0%, rgba(139, 92, 246, 0.15) 100%);
        box-shadow: 0 0 12px rgba(99, 102, 241, 0.25);
    }
    
    .veo-settings-model-option .model-dot {
        width: 12px;
        height: 12px;
        border-radius: 50%;
        border: 2px solid rgba(99, 102, 241, 0.4);
        flex-shrink: 0;
    }
    
    .veo-settings-model-option.selected .model-dot {
        border-color: rgba(99, 102, 241, 0.8);
        background: linear-gradient(135deg, #6366f1, #8b5cf6);
        box-shadow: 0 0 6px rgba(99, 102, 241, 0.5);
    }
    
    /* Toggle для качества + Сбросить */
    .veo-settings-toggle-row {
        display: flex;
        align-items: center;
        gap: 1rem;
        padding: 0.5rem 0;
    }
    
    .veo-settings-toggle-label {
        font-size: 0.9rem;
        color: var(--text-secondary);
    }
    
    .veo-settings-toggle {
        width: 40px;
        height: 22px;
        background: rgba(99, 102, 241, 0.2);
        border: 1px solid rgba(99, 102, 241, 0.25);
        border-radius: 11px;
        position: relative;
        cursor: pointer;
        transition: all 0.2s;
        box-shadow: 0 0 6px rgba(99, 102, 241, 0.1);
    }
    
    .veo-settings-toggle.active {
        background: linear-gradient(135deg, rgba(99, 102, 241, 0.4) 0%, rgba(139, 92, 246, 0.35) 100%);
        border-color: rgba(99, 102, 241, 0.5);
        box-shadow: 0 0 10px rgba(99, 102, 241, 0.25);
    }
    
    .veo-settings-toggle::after {
        content: '';
        position: absolute;
        width: 18px;
        height: 18px;
        border-radius: 50%;
        background: #fff;
        top: 2px;
        left: 2px;
        transition: transform 0.2s;
    }
    
    .veo-settings-toggle.active::after {
        transform: translateX(18px);
    }
    
    /* Кнопки сброса — всегда внизу панели */
    .veo-settings-footer {
        position: relative;
        margin-top: auto;
        flex-shrink: 0;
        padding-top: 1rem;
        border-top: none;
        display: flex;
        flex-direction: column;
        gap: 0.5rem;
    }
    .veo-settings-footer::before {
        content: '';
        position: absolute;
        left: 0;
        right: 0;
        top: 0;
        height: 1px;
        background: var(--veo-divider-h);
    }
    
    .veo-settings-btn {
        display: flex;
        align-items: center;
        justify-content: center;
        gap: 0.5rem;
        padding: 0.55rem 1rem;
        background: rgba(255, 255, 255, 0.03);
        border: 1px solid rgba(255, 255, 255, 0.06);
        border-radius: 8px;
        color: #fff;
        font-size: 0.875rem;
        cursor: pointer;
        transition: all 0.15s;
    }

    .veo-settings-btn svg {
        width: 14px;
        height: 14px;
        flex-shrink: 0;
    }
    
    .veo-settings-btn:hover {
        background: rgba(255, 255, 255, 0.06);
        color: #fff;
    }
    
    /* Скрыть header на desktop внутри main, т.к. header общий */
    /* Main content для desktop — full height */
    body.veo-generation-body .veo-desktop-layout + .main-content-spacer,
    body.veo-generation-body main.main-content .veo-desktop-main-inner {
        display: flex;
        flex-direction: column;
        flex: 1;
        min-height: calc(100vh - 60px);
    }
}

/* Подложка: клик вне панели закрывает её */
.veo-chats-panel-backdrop {
    position: fixed;
    inset: 0;
    z-index: 199;
    background: rgba(0, 0, 0, 0.25);
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transition: opacity 0.2s, visibility 0.2s;
}
.veo-chats-panel-backdrop[aria-hidden="false"] {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
}
/* Панель списка чатов — от самого левого края, без кнопки скрыть */
.veo-chats-panel {
    position: fixed;
    left: 0;
    top: 60px;
    bottom: 0;
    width: 280px;
    background: var(--bg-primary);
    border-right: none;
    z-index: 200;
    display: flex;
    flex-direction: column;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.2s ease, visibility 0.2s ease;
    box-shadow: 4px 0 20px rgba(0, 0, 0, 0.3);
}
.veo-chats-panel[aria-hidden="false"] {
    opacity: 1;
    visibility: visible;
}
.veo-chats-panel::after {
    content: '';
    position: absolute;
    top: 0;
    right: 0;
    bottom: 0;
    width: 1px;
    background: var(--veo-divider-v);
}
.veo-chats-panel-header {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.5rem;
    padding: 1rem 1rem;
    border-bottom: none;
    font-weight: 600;
    color: var(--text-primary);
}
.veo-chats-panel-header::after {
    content: '';
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    height: 1px;
    background: var(--veo-divider-h);
}
.veo-chats-panel-header-spacer {
    width: 36px;
    flex-shrink: 0;
}
.veo-chats-panel-back {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    padding: 0;
    background: transparent;
    border: none;
    border-radius: 8px;
    color: rgba(255, 255, 255, 0.6);
    cursor: pointer;
    transition: background 0.15s, color 0.15s;
    flex-shrink: 0;
}
.veo-chats-panel-back:hover {
    background: rgba(255, 255, 255, 0.08);
    color: rgba(255, 255, 255, 0.95);
}
.veo-chats-panel-back svg {
    width: 20px;
    height: 20px;
}
.veo-chats-panel-list {
    flex: 1;
    overflow-y: auto;
    padding: 0.5rem 0;
}
.veo-chats-panel-item {
    display: block;
    width: 100%;
    padding: 0.6rem 1rem;
    text-align: left;
    background: none;
    border: none;
    color: var(--text-secondary);
    font-size: 0.875rem;
    cursor: pointer;
    transition: background 0.15s;
}
.veo-chats-panel-item:hover {
    background: rgba(255, 255, 255, 0.05);
    color: var(--text-primary);
}
.veo-chats-panel-auth-hint {
    padding: 1rem 1rem;
    color: var(--text-muted);
    font-size: 0.85rem;
}

/* Модальное окно входа (Google, Яндекс, Telegram) */
.veo-login-overlay {
    position: fixed;
    inset: 0;
    background: #0a0a0c;
    z-index: 10000;
    display: flex;
    align-items: stretch;
    justify-content: stretch;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.25s, visibility 0.25s;
}
.veo-login-overlay[aria-hidden="false"] {
    opacity: 1;
    visibility: visible;
}
.veo-login-overlay .veo-login-page {
    display: flex;
    width: 100%;
    min-height: 100vh;
}
.veo-login-overlay .veo-login-panel {
    flex: 0 0 38%;
    min-width: 320px;
    max-width: 480px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 3rem 2.5rem;
    background: linear-gradient(180deg, #1a1512 0%, #0f0d0b 50%, #0a0908 100%);
    position: relative;
}
.veo-login-overlay .veo-login-back {
    position: absolute;
    top: 1.5rem;
    left: 2rem;
    background: none;
    border: none;
    color: rgba(255, 255, 255, 0.7);
    font-size: 1.5rem;
    cursor: pointer;
    line-height: 1;
    transition: color 0.2s;
}
.veo-login-overlay .veo-login-back:hover { color: #fff; }
.veo-login-overlay .veo-login-brand {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 2.5rem;
}
.veo-login-overlay .veo-login-logo {
    display: inline-block;
    width: 48px;
    height: 48px;
    background-image: var(--logo-url);
    background-size: contain;
    background-position: center;
    background-repeat: no-repeat;
    flex-shrink: 0;
}
.veo-login-overlay .veo-login-brand-name {
    font-family: 'Orbitron', sans-serif;
    font-size: 1.5rem;
    font-weight: 600;
    color: #fff;
}
.veo-login-overlay .veo-login-beta {
    font-size: 0.65rem;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.5);
    text-transform: uppercase;
    letter-spacing: 0.1em;
    padding: 0.15rem 0.4rem;
    background: rgba(255, 255, 255, 0.08);
    border-radius: 4px;
    margin-left: 0.25rem;
}
.veo-login-overlay .veo-login-provider-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    width: 100%;
    padding: 0.85rem 1.25rem;
    background: transparent;
    border: 1px solid rgba(255, 255, 255, 0.25);
    border-radius: 10px;
    color: #fff;
    font-size: 1rem;
    font-weight: 500;
    cursor: pointer;
    transition: border-color 0.2s, background 0.2s;
    margin-bottom: 0.75rem;
}
.veo-login-overlay .veo-login-provider-btn:hover {
    border-color: rgba(255, 255, 255, 0.45);
    background: rgba(255, 255, 255, 0.05);
}
.veo-login-overlay .veo-login-provider-icon { display: flex; align-items: center; justify-content: center; }
.veo-login-overlay .veo-login-provider-icon svg { flex-shrink: 0; }
.veo-login-overlay .veo-login-google-icon svg { width: 20px; height: 20px; }
.veo-login-overlay .veo-login-yandex-icon { color: #fc3f1d; }
.veo-login-overlay .veo-login-yandex-icon svg { width: 20px; height: 20px; }
.veo-login-overlay .veo-login-telegram-icon { color: #0088cc; }
.veo-login-overlay .veo-login-telegram-icon svg { width: 20px; height: 20px; }
.veo-login-overlay .veo-login-legal {
    margin: 1.25rem 0 0;
    font-size: 0.8rem;
    color: rgba(255, 255, 255, 0.5);
    line-height: 1.5;
}
.veo-login-overlay .veo-login-legal-link { color: rgba(255, 255, 255, 0.7); text-decoration: underline; }
.veo-login-overlay .veo-login-legal-link:hover { color: #fff; }
.veo-login-overlay .veo-login-info {
    margin-top: 1.5rem;
    padding: 1rem;
    background: rgba(255, 255, 255, 0.04);
    border-radius: 8px;
    font-size: 0.8rem;
    color: rgba(255, 255, 255, 0.55);
    line-height: 1.5;
}
.veo-login-overlay .veo-login-info p { margin: 0; }
.veo-login-overlay .veo-login-step-wait { margin-top: 1rem; }
.veo-login-overlay .veo-login-wait-title {
    margin: 0 0 0.5rem; font-size: 1.25rem; font-weight: 600;
    background: linear-gradient(135deg, #a5b4fc 0%, #c4b5fd 50%, #67e8f9 100%);
    -webkit-background-clip: text; -webkit-text-fill-color: transparent; background-clip: text;
}
.veo-login-overlay .veo-login-wait-text { margin: 0 0 1rem; font-size: 0.9rem; color: rgba(165, 180, 252, 0.9); }
.veo-login-overlay .veo-login-qr-wrap {
    margin: 1rem 0; padding: 14px; display: inline-block;
    background: linear-gradient(135deg, rgba(15, 12, 41, 0.95) 0%, rgba(30, 27, 75, 0.9) 100%);
    border: 1px solid rgba(99, 102, 241, 0.4);
    border-radius: 14px;
    box-shadow: 0 4px 24px rgba(99, 102, 241, 0.25), 0 0 40px rgba(139, 92, 246, 0.12), 0 0 0 1px rgba(255, 255, 255, 0.08) inset;
}
.veo-login-overlay .veo-login-qr { display: block; border-radius: 6px; background: #fff; }
.veo-login-overlay .veo-login-timer { margin: 0 0 1rem; font-size: 0.9rem; color: rgba(165, 180, 252, 0.9); }
.veo-login-overlay .veo-login-open-btns { display: flex; flex-direction: column; gap: 0.5rem; width: 100%; margin-bottom: 1rem; }
.veo-login-overlay .veo-login-open-btn {
    display: block; width: 100%; padding: 0.75rem 1rem; border-radius: 12px; font-size: 0.95rem; font-weight: 600;
    text-align: center; text-decoration: none; cursor: pointer; transition: opacity 0.2s, transform 0.15s, box-shadow 0.2s;
}
.veo-login-overlay .veo-login-open-btn:hover { opacity: 0.95; transform: translateY(-1px); }
.veo-login-overlay .veo-login-open-btn--primary {
    background: linear-gradient(135deg, #312e81 0%, #4c1d95 50%, #5b21b6 100%);
    color: #fff; border: 1px solid rgba(139, 92, 246, 0.4);
    box-shadow: 0 4px 24px rgba(99, 102, 241, 0.35), 0 0 40px rgba(139, 92, 246, 0.15), 0 0 0 1px rgba(255, 255, 255, 0.08) inset;
}
.veo-login-overlay .veo-login-open-btn--primary:hover {
    box-shadow: 0 6px 28px rgba(99, 102, 241, 0.45), 0 0 50px rgba(139, 92, 246, 0.2);
}
.veo-login-overlay .veo-login-open-btn--secondary {
    background: linear-gradient(135deg, rgba(30, 27, 75, 0.6) 0%, rgba(49, 46, 129, 0.3) 100%);
    color: #fff; border: 1px solid rgba(99, 102, 241, 0.4);
    box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.06) inset;
}
.veo-login-overlay .veo-login-open-btn--secondary:hover {
    border-color: rgba(139, 92, 246, 0.5);
    box-shadow: 0 0 20px rgba(99, 102, 241, 0.2);
}
.veo-login-overlay .veo-login-link { display: block; word-break: break-all; color: #e67e22; margin-bottom: 1rem; font-size: 0.9rem; }
.veo-login-overlay .veo-login-btn-secondary {
    width: 100%;
    padding: 0.6rem 1rem;
    background: rgba(255, 255, 255, 0.08);
    color: #fff;
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 8px;
    font-size: 0.9rem;
    cursor: pointer;
    margin-top: 0.5rem;
}
.veo-login-overlay .veo-login-btn-secondary:hover { background: rgba(255, 255, 255, 0.12); }
.veo-login-overlay .veo-login-gallery {
    flex: 1;
    min-width: 0;
    padding: 1.5rem;
    background: #0d0d0f;
    overflow: auto;
}
.veo-login-overlay .veo-login-gallery-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 0.75rem;
    max-width: 800px;
    margin: 0 auto;
}
.veo-login-overlay .veo-login-gallery-item { border-radius: 8px; overflow: hidden; aspect-ratio: 1; }
.veo-login-overlay .veo-login-gallery-item--tall { aspect-ratio: 1 / 1.4; }
.veo-login-overlay .veo-login-gallery-item--wide { aspect-ratio: 1.4 / 1; }
.veo-login-overlay .veo-login-gallery-item img { width: 100%; height: 100%; object-fit: cover; display: block; }
@media (max-width: 900px) {
    .veo-login-overlay .veo-login-page { flex-direction: column; }
    .veo-login-overlay .veo-login-panel { flex: none; max-width: none; padding: 2rem 1.5rem; }
    .veo-login-overlay .veo-login-gallery { min-height: 200px; }
    .veo-login-overlay .veo-login-gallery-grid { grid-template-columns: repeat(3, 1fr); }
}

/* Кастомные уведомления и ошибки */
.veo-notify-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.65);
    backdrop-filter: blur(4px);
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1.5rem;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.25s ease, visibility 0.25s ease;
}
.veo-notify-overlay[aria-hidden="false"] {
    opacity: 1;
    visibility: visible;
}
/* Космический стиль для справок (info) — как Veo 3 */
.veo-notify-overlay[data-type="info"] {
    background: rgba(15, 12, 41, 0.85);
    backdrop-filter: blur(8px);
}
.veo-notify-modal {
    background: linear-gradient(180deg, #1a1a1f 0%, #141418 100%);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 16px;
    padding: 1.75rem 2rem;
    max-width: 400px;
    width: 100%;
    box-shadow: 0 24px 48px rgba(0, 0, 0, 0.5), 0 0 0 1px rgba(255, 255, 255, 0.03);
    text-align: center;
    transform: scale(0.95);
    transition: transform 0.25s ease;
}
.veo-notify-overlay[data-type="info"] .veo-notify-modal {
    background: linear-gradient(180deg, #1e1b4b 0%, #0f0c29 50%, #141428 100%);
    border: 1px solid rgba(99, 102, 241, 0.25);
    box-shadow: 0 24px 48px rgba(0, 0, 0, 0.6), 0 4px 24px rgba(99, 102, 241, 0.2), 0 0 40px rgba(139, 92, 246, 0.08), 0 0 0 1px rgba(255, 255, 255, 0.06) inset;
}
.veo-notify-overlay[aria-hidden="false"] .veo-notify-modal {
    transform: scale(1);
}
.veo-notify-icon {
    width: 52px;
    height: 52px;
    margin: 0 auto 1rem;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}
.veo-notify-icon svg {
    width: 28px;
    height: 28px;
}
.veo-notify-overlay[data-type="error"] .veo-notify-icon {
    background: rgba(231, 76, 60, 0.2);
    color: #e74c3c;
}
.veo-notify-overlay[data-type="success"] .veo-notify-icon {
    background: rgba(46, 204, 113, 0.2);
    color: #2ecc71;
}
.veo-notify-overlay[data-type="info"] .veo-notify-icon {
    background: linear-gradient(135deg, #312e81 0%, #4c1d95 100%);
    color: rgba(255, 255, 255, 0.95);
    border: 1px solid rgba(99, 102, 241, 0.4);
    box-shadow: 0 4px 16px rgba(99, 102, 241, 0.3), 0 0 24px rgba(139, 92, 246, 0.15);
}
.veo-notify-overlay[data-type="info"] .veo-notify-icon svg {
    color: #e8e0ff;
}
.veo-notify-title {
    margin: 0 0 0.5rem;
    font-size: 1.1rem;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.95);
}
.veo-notify-message {
    margin: 0 0 1.5rem;
    font-size: 0.95rem;
    line-height: 1.5;
    color: rgba(255, 255, 255, 0.75);
    white-space: pre-line;
}
.veo-notify-overlay[data-type="info"] .veo-notify-message {
    color: rgba(255, 255, 255, 0.85);
}
.veo-notify-actions {
    display: flex;
    justify-content: center;
    gap: 0.75rem;
    flex-wrap: wrap;
}
.veo-notify-btn {
    min-width: 100px;
    padding: 0.6rem 1.25rem;
    border-radius: 10px;
    font-weight: 600;
    font-size: 0.9rem;
    cursor: pointer;
    transition: background 0.2s, transform 0.15s;
    border: none;
}
.veo-notify-btn:hover {
    transform: translateY(-1px);
}
.veo-notify-btn-primary {
    background: linear-gradient(135deg, var(--gold, #e67e22) 0%, #c96a1a 100%);
    color: #000;
    box-shadow: 0 4px 14px rgba(230, 126, 34, 0.35);
}
.veo-notify-overlay[data-type="info"] .veo-notify-btn-primary {
    background: linear-gradient(135deg, #6366f1 0%, #8b5cf6 50%, #7c3aed 100%);
    color: #fff;
    border: 1px solid rgba(139, 92, 246, 0.4);
    box-shadow: 0 4px 20px rgba(99, 102, 241, 0.4), 0 0 30px rgba(139, 92, 246, 0.2);
}
.veo-notify-btn-primary:hover {
    background: linear-gradient(135deg, #f0a040 0%, var(--gold, #e67e22) 100%);
}
.veo-notify-overlay[data-type="info"] .veo-notify-btn-primary:hover {
    background: linear-gradient(135deg, #818cf8 0%, #a78bfa 50%, #8b5cf6 100%);
    box-shadow: 0 6px 24px rgba(99, 102, 241, 0.5), 0 0 40px rgba(139, 92, 246, 0.25);
}
.veo-notify-btn-secondary {
    background: rgba(255, 255, 255, 0.08);
    color: rgba(255, 255, 255, 0.9);
    border: 1px solid rgba(255, 255, 255, 0.12);
}

/* Подтверждение отправки генерации */
.veo-confirm-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.65);
    backdrop-filter: blur(4px);
    z-index: 10000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1.5rem;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.25s ease, visibility 0.25s ease;
}
.veo-confirm-overlay[aria-hidden="false"] {
    opacity: 1;
    visibility: visible;
}
.veo-confirm-modal {
    background: linear-gradient(180deg, #1a1a1f 0%, #141418 100%);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 16px;
    padding: 1.75rem 2rem;
    max-width: 400px;
    width: 100%;
    box-shadow: 0 24px 48px rgba(0, 0, 0, 0.5), 0 0 0 1px rgba(255, 255, 255, 0.03);
    text-align: center;
    transform: scale(0.95);
    transition: transform 0.25s ease;
}
.veo-confirm-overlay[aria-hidden="false"] .veo-confirm-modal {
    transform: scale(1);
}
.veo-confirm-icon {
    width: 52px;
    height: 52px;
    margin: 0 auto 1rem;
    border-radius: 50%;
    background: rgba(230, 126, 34, 0.2);
    color: var(--gold, #e67e22);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.6rem;
    font-weight: 700;
}
.veo-confirm-title {
    margin: 0 0 0.5rem;
    font-size: 1.1rem;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.95);
}
.veo-confirm-message {
    margin: 0 0 1.25rem;
    font-size: 0.95rem;
    line-height: 1.5;
    color: rgba(255, 255, 255, 0.75);
}
.veo-confirm-checkbox {
    display: flex;
    align-items: flex-start;
    gap: 0.5rem;
    margin: 0 0 1.5rem;
    font-size: 0.85rem;
    color: rgba(255, 255, 255, 0.7);
    cursor: pointer;
    text-align: left;
}
.veo-confirm-checkbox input {
    margin-top: 0.2rem;
    flex-shrink: 0;
}
.veo-confirm-actions {
    display: flex;
    justify-content: center;
    gap: 0.75rem;
}

/* Модальное окно выбора из сгенерированных */
.veo-generated-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.65);
    backdrop-filter: blur(4px);
    z-index: 10000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1.5rem;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.25s ease, visibility 0.25s ease;
}
.veo-generated-overlay[aria-hidden="false"] {
    opacity: 1;
    visibility: visible;
}
.veo-generated-modal {
    position: relative;
    background: linear-gradient(180deg, #1a1a1f 0%, #141418 100%);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 16px;
    padding: 1.75rem 2rem;
    max-width: 480px;
    width: 100%;
    max-height: 80vh;
    overflow-y: auto;
    box-shadow: 0 24px 48px rgba(0, 0, 0, 0.5);
}
.veo-generated-close {
    position: absolute;
    top: 0.75rem;
    right: 0.75rem;
    width: 32px;
    height: 32px;
    border: none;
    background: rgba(255, 255, 255, 0.06);
    color: rgba(255, 255, 255, 0.7);
    font-size: 1.6rem;
    line-height: 1;
    cursor: pointer;
    border-radius: 8px;
    transition: background 0.2s, color 0.2s;
}
.veo-generated-close:hover {
    background: rgba(255, 255, 255, 0.1);
    color: #fff;
}
.veo-generated-title {
    margin: 0 0 1.25rem;
    font-size: 1.1rem;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.95);
}
.veo-generated-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(100px, 1fr));
    gap: 0.75rem;
    flex-wrap: wrap;
}
.veo-generated-card {
    aspect-ratio: 1;
    border-radius: 8px;
    overflow: hidden;
    border: 2px solid transparent;
    background: rgba(255, 255, 255, 0.04);
    cursor: pointer;
    padding: 0;
    transition: border-color 0.2s, transform 0.15s;
}
.veo-generated-card:hover {
    border-color: var(--gold, #e67e22);
    transform: scale(1.02);
}
.veo-generated-card img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}
.veo-generated-empty {
    margin: 0;
    font-size: 0.9rem;
    color: rgba(255, 255, 255, 0.5);
    line-height: 1.5;
}

/* Кнопка автоотправки без подтверждения — молния (мгновенная отправка) */
.veo-auto-send-btn {
    flex-shrink: 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    padding: 0;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 10px;
    color: rgba(255, 255, 255, 0.45);
    cursor: pointer;
    transition: background 0.2s, border-color 0.2s, color 0.2s;
}
.veo-auto-send-btn:hover {
    background: rgba(255, 255, 255, 0.08);
    border-color: rgba(255, 255, 255, 0.12);
    color: rgba(255, 255, 255, 0.7);
}
.veo-auto-send-btn[aria-pressed="true"] {
    background: rgba(250, 204, 21, 0.12);
    border-color: rgba(250, 204, 21, 0.35);
    color: #facc15;
}
.veo-auto-send-btn[aria-pressed="true"]:hover {
    background: rgba(250, 204, 21, 0.18);
    border-color: rgba(250, 204, 21, 0.45);
    color: #fde047;
}
.veo-auto-send-icon {
    display: flex;
    align-items: center;
    justify-content: center;
}
.veo-auto-send-icon svg {
    width: 16px;
    height: 16px;
}
.veo-auto-send-btn .veo-auto-send-icon-on {
    display: none;
}
.veo-auto-send-btn .veo-auto-send-icon-off {
    display: flex;
}
.veo-auto-send-btn[aria-pressed="true"] .veo-auto-send-icon-off {
    display: none;
}
.veo-auto-send-btn[aria-pressed="true"] .veo-auto-send-icon-on {
    display: flex;
}

/* Справки (tooltips) — космический стиль Veo 3 везде */
body.veo-generation-body .form-section-help-tooltip {
    background: linear-gradient(180deg, #1e1b4b 0%, #0f0c29 100%) !important;
    border: 1px solid rgba(99, 102, 241, 0.3);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.5), 0 4px 16px rgba(99, 102, 241, 0.15), 0 0 0 1px rgba(255, 255, 255, 0.06) inset;
    color: rgba(255, 255, 255, 0.9) !important;
    padding: 0.6rem 0.9rem;
    line-height: 1.45;
}
body.veo-generation-body .form-section-help-tooltip::after {
    border-top-color: #0f0c29;
}
.veo-right-settings .form-section-help-tooltip::after {
    top: 50%;
    left: 100%;
    transform: translateY(-50%);
    border-top-color: transparent;
    border-right-color: transparent;
    border-bottom-color: transparent;
    border-left-color: #1e1b4b;
}
/* Справки (tooltips) — слева от кнопки ? в правой панели */
.veo-right-settings .form-section-help-tooltip {
    bottom: auto;
    left: auto;
    right: calc(100% + 12px);
    top: 50%;
    transform: translateY(-50%);
    font-size: 0.75rem;
    min-width: 200px;
    max-width: 280px;
}
.veo-right-settings .form-section-help-wrapper:hover .form-section-help-tooltip,
.veo-right-settings .form-section-help:focus + .form-section-help-tooltip,
.veo-right-settings .form-section-help-wrapper:focus-within .form-section-help-tooltip {
    transform: translateY(-50%) !important;
}
@media (max-width: 768px) {
    .veo-right-settings .form-section-help-wrapper:active .form-section-help-tooltip,
    .veo-right-settings .form-section-help:active + .form-section-help-tooltip {
        transform: translateY(-50%) !important;
    }
}

/* Адаптивность хедера на средних экранах */
@media (max-width: 1100px) and (min-width: 600px) {
    body.veo-generation-body .desktop-nav .nav-link {
        padding: 0.5rem 0.5rem;
        font-size: 0.85rem;
    }
}

/* На узких экранах — mobile, на широких — desktop */
@media (max-width: 599px) {
    body.veo-generation-body .veo-desktop-layout { display: none !important; }
    body.veo-generation-body .veo-mobile-layout { display: flex !important; flex-direction: column; flex: 1; }
}
@media (min-width: 600px) {
    body.veo-generation-body .veo-desktop-layout { display: flex !important; flex-direction: row; }
    body.veo-generation-body .veo-mobile-layout { display: none !important; }
}
body.veo-generation-body .bottom-nav { display: none !important; }

/* Мобильные карточки выбора — стиль как кнопка «Создать видео» */
body.veo-generation-body .aspect-ratio-card {
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.08) 0%, rgba(139, 92, 246, 0.05) 100%);
    border: 1px solid rgba(99, 102, 241, 0.25);
}
body.veo-generation-body .aspect-ratio-card:hover {
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.12) 0%, rgba(139, 92, 246, 0.08) 100%);
    border-color: rgba(99, 102, 241, 0.35);
}
body.veo-generation-body .aspect-ratio-card.selected {
    border-color: rgba(99, 102, 241, 0.5);
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.2) 0%, rgba(139, 92, 246, 0.15) 100%);
    box-shadow: 0 0 12px rgba(99, 102, 241, 0.25);
}
body.veo-generation-body .aspect-ratio-card.selected .aspect-ratio-icon {
    color: rgba(199, 210, 254, 1);
}
body.veo-generation-body .aspect-ratio-card.selected .aspect-ratio-radio {
    border-color: rgba(99, 102, 241, 0.8);
}
body.veo-generation-body .aspect-ratio-card.selected .radio-dot {
    background: linear-gradient(135deg, #6366f1, #8b5cf6);
    box-shadow: 0 0 6px rgba(99, 102, 241, 0.5);
}

body.veo-generation-body .model-select-card {
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.08) 0%, rgba(139, 92, 246, 0.05) 100%);
    border: 1px solid rgba(99, 102, 241, 0.25);
}
body.veo-generation-body .model-select-card:hover {
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.15) 0%, rgba(139, 92, 246, 0.1) 100%);
    border-color: rgba(99, 102, 241, 0.35);
}
body.veo-generation-body .model-select-card.selected {
    border-color: rgba(99, 102, 241, 0.5);
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.2) 0%, rgba(139, 92, 246, 0.15) 100%);
    box-shadow: 0 0 12px rgba(99, 102, 241, 0.25);
}
body.veo-generation-body .model-select-card.selected .model-select-name {
    color: rgba(199, 210, 254, 1);
}
