/* ============================================================
   БАЗОВІ НАЛАШТУВАННЯ ТА ОКСАМИТОВО-ЗОЛОТА ПАЛІТРА
   ============================================================ */
:root {
    --velvet-dark: #020817;
    --velvet-mid: #05173b;
    --velvet-royal: #0a3485;
    --gold-bright: #fcf6ba;
    --gold-main: #d4af37;
    --gold-deep: #8c6218;
}

html {
    background-color: var(--velvet-dark);
    scroll-padding-top: 5.5rem;
}

body {
    background-color: var(--velvet-dark);
    color: #eef4ff;
    overflow-x: clip;
    width: 100%;
}

/* Оксамитова текстура поверхні (глибокий королівський синій) */
.velvet-surface {
    background:
        radial-gradient(ellipse 85% 70% at 15% 15%, rgba(15, 76, 189, 0.42), transparent 62%),
        radial-gradient(ellipse 75% 65% at 88% 82%, rgba(9, 46, 122, 0.55), transparent 65%),
        linear-gradient(135deg, #020817 0%, #05163a 48%, #02091c 100%);
    position: relative;
}

.velvet-surface::before {
    content: '';
    position: absolute;
    inset: 0;
    pointer-events: none;
    opacity: 0.22;
    background-image: radial-gradient(rgba(255, 255, 255, 0.06) 1px, transparent 0);
    background-size: 24px 24px;
    z-index: 0;
}

.velvet-surface > * {
    position: relative;
    z-index: 2;
}

/* Діагональні геометричні стрічки синього оксамиту із золотою облямівкою */
.hero-geometry {
    position: absolute;
    inset: 0;
    overflow: hidden;
    pointer-events: none;
    z-index: 0;
}

.geo-ribbon {
    position: absolute;
    border-top: 2px solid transparent;
    border-bottom: 2px solid transparent;
    background-origin: border-box;
    box-shadow: 0 24px 70px rgba(0, 0, 0, 0.65);
}

.geo-ribbon-1 {
    top: -12%;
    left: -15%;
    width: 135%;
    height: 220px;
    transform: rotate(24deg);
    background:
        linear-gradient(110deg, #06286e 0%, #031233 55%, #010614 100%) padding-box,
        linear-gradient(90deg, #8c6218 0%, #fcf6ba 30%, #d4af37 58%, #fcf6ba 82%, #8c6218 100%) border-box;
    opacity: 0.72;
}

.geo-ribbon-2 {
    bottom: -6%;
    left: -20%;
    width: 145%;
    height: 240px;
    transform: rotate(-19deg);
    background:
        linear-gradient(95deg, #020a1f 0%, #083080 52%, #03102d 100%) padding-box,
        linear-gradient(90deg, #7a5210 0%, #e8c76b 25%, #fcf6ba 50%, #b8862d 78%, #fcf6ba 100%) border-box;
    opacity: 0.68;
}

.geo-ribbon-3 {
    top: 38%;
    right: -25%;
    width: 95%;
    height: 150px;
    transform: rotate(31deg);
    background:
        linear-gradient(120deg, #0a3b99 0%, #04153b 65%, #010510 100%) padding-box,
        linear-gradient(90deg, #b8862d 0%, #fcf6ba 48%, #8c6218 100%) border-box;
    opacity: 0.48;
}

/* Золотий розділювач між секціями */
.gold-divider {
    height: 2px;
    background: linear-gradient(90deg, transparent 0%, #8c6218 18%, #fcf6ba 50%, #8c6218 82%, transparent 100%);
    opacity: 0.7;
}

/* Золотий градієнт для тексту */
.text-gold-gradient {
    background: linear-gradient(135deg, #d4af37 0%, #fcf6ba 45%, #c9972e 75%, #f5df96 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* Анімований металевий перелив на головних золотих заголовках */
.text-gold-shimmer {
    background: linear-gradient(
        110deg,
        #b8862d 0%,
        #e8c76b 22%,
        #fff8d6 45%,
        #d4af37 65%,
        #fcf6ba 85%,
        #b8862d 100%
    );
    background-size: 240% auto;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    animation: goldTextFlow 6.5s linear infinite;
}

@keyframes goldTextFlow {
    0% { background-position: 0% center; }
    100% { background-position: 240% center; }
}

/* ============================================================
   ВАУ-ЕФЕКТ КНОПОК ІЗ ЗОЛОТИМ ВІДБЛИСКОМ ТА СВІТІННЯМ ЗА КУРСОРОМ
   ============================================================ */
.btn-gold-wow {
    position: relative;
    overflow: hidden;
    background: linear-gradient(135deg, #a67822 0%, #e5c167 38%, #fcf6ba 52%, #c9962b 76%, #946816 100%);
    background-size: 200% auto;
    color: #030b1e;
    font-weight: 700;
    border: 1px solid rgba(252, 246, 186, 0.85);
    box-shadow:
        0 10px 28px rgba(212, 175, 55, 0.28),
        inset 0 1px 1px rgba(255, 255, 255, 0.65);
    transition: transform 0.3s cubic-bezier(0.22, 1, 0.36, 1), box-shadow 0.35s ease, background-position 0.5s ease;
}

.btn-gold-wow::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -130%;
    width: 65%;
    height: 210%;
    background: linear-gradient(
        115deg,
        transparent 0%,
        rgba(255, 255, 255, 0.15) 35%,
        rgba(255, 255, 255, 0.85) 50%,
        rgba(255, 246, 190, 0.25) 65%,
        transparent 100%
    );
    transform: skewX(-24deg);
    transition: left 0.72s cubic-bezier(0.22, 1, 0.36, 1);
    pointer-events: none;
    z-index: 2;
}

.btn-gold-wow:hover {
    transform: translateY(-2px);
    background-position: right center;
    box-shadow:
        0 14px 36px rgba(212, 175, 55, 0.5),
        0 0 22px rgba(252, 246, 186, 0.45),
        inset 0 1px 2px rgba(255, 255, 255, 0.9);
}

.btn-gold-wow:hover::before {
    left: 165%;
}

.btn-gold-wow:active {
    transform: translateY(0) scale(0.98);
}

.btn-gold-wow:disabled {
    opacity: 0.75;
    cursor: not-allowed;
    transform: none;
}

/* Вторинна оксамитова кнопка із золотим відблиском */
.btn-velvet-wow {
    position: relative;
    overflow: hidden;
    background: linear-gradient(145deg, rgba(8, 33, 84, 0.92), rgba(3, 14, 38, 0.96));
    color: #fcf6ba;
    font-weight: 600;
    border: 1px solid rgba(212, 175, 55, 0.65);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.45), inset 0 1px 0 rgba(252, 246, 186, 0.18);
    transition: transform 0.3s cubic-bezier(0.22, 1, 0.36, 1), border-color 0.3s ease, box-shadow 0.35s ease;
}

.btn-velvet-wow::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -130%;
    width: 60%;
    height: 210%;
    background: linear-gradient(
        115deg,
        transparent 0%,
        rgba(212, 175, 55, 0.12) 32%,
        rgba(252, 246, 186, 0.65) 50%,
        rgba(212, 175, 55, 0.15) 68%,
        transparent 100%
    );
    transform: skewX(-24deg);
    transition: left 0.75s cubic-bezier(0.22, 1, 0.36, 1);
    pointer-events: none;
    z-index: 2;
}

.btn-velvet-wow:hover {
    transform: translateY(-2px);
    border-color: #fcf6ba;
    box-shadow: 0 12px 30px rgba(212, 175, 55, 0.28), 0 0 18px rgba(212, 175, 55, 0.25);
}

.btn-velvet-wow:hover::before {
    left: 165%;
}

/* Динамічна золота пляма світла за курсором всередині кнопки */
.wow-btn-spotlight {
    position: absolute;
    inset: 0;
    pointer-events: none;
    opacity: 0;
    transition: opacity 0.25s ease;
    background: radial-gradient(
        120px circle at var(--mx, 50%) var(--my, 50%),
        rgba(255, 250, 215, 0.45),
        transparent 70%
    );
    z-index: 1;
}

.btn-gold-wow:hover .wow-btn-spotlight,
.btn-velvet-wow:hover .wow-btn-spotlight {
    opacity: 1;
}

/* ============================================================
   ОКСАМИТОВІ КАРТКИ З 3D-СВІТІННЯМ ТА ПРЕМІАЛЬНОЮ РАМКОЮ
   ============================================================ */
.velvet-card {
    position: relative;
    overflow: hidden;
    background: linear-gradient(155deg, rgba(9, 34, 86, 0.78) 0%, rgba(4, 15, 42, 0.92) 55%, rgba(2, 9, 24, 0.96) 100%);
    border: 1px solid rgba(212, 175, 55, 0.32);
    box-shadow: 0 18px 45px rgba(0, 0, 0, 0.48), inset 0 1px 0 rgba(252, 246, 186, 0.14);
    backdrop-filter: blur(12px);
    transform-style: preserve-3d;
    will-change: transform;
    transition: border-color 0.35s ease, box-shadow 0.35s ease, transform 0.25s ease-out;
}

.velvet-card::after {
    content: '';
    position: absolute;
    inset: 0;
    pointer-events: none;
    opacity: 0;
    transition: opacity 0.35s ease;
    background: radial-gradient(
        380px circle at var(--cx, 50%) var(--cy, 50%),
        rgba(252, 246, 186, 0.15),
        rgba(212, 175, 55, 0.05) 42%,
        transparent 72%
    );
    z-index: 1;
}

.velvet-card:hover {
    border-color: rgba(252, 246, 186, 0.65);
    box-shadow: 0 24px 55px rgba(0, 0, 0, 0.62), 0 0 24px rgba(212, 175, 55, 0.16);
}

.velvet-card:hover::after {
    opacity: 1;
}

.velvet-card > * {
    position: relative;
    z-index: 2;
}

/* ============================================================
   АНІМАЦІЯ ТЕРЕЗІВ ПРАВОСУДДЯ:
   РІВНОВАГА ЗА ЗАМОВЧУВАННЯМ + ПЛАВНА ПЕРЕВАГА ПРИ НАТИСКАННІ
   ============================================================ */
@keyframes beamEquilibrium {
    0%, 100% { transform: rotate(-2.2deg); }
    50% { transform: rotate(2.2deg); }
}

@keyframes panEquilibrium {
    0%, 100% { transform: rotate(2.2deg); }
    50% { transform: rotate(-2.2deg); }
}

#scaleTiltGroup {
    transform-box: view-box;
    transform-origin: 300px 104px;
    transform: rotate(0deg);
    transition: transform 1.15s cubic-bezier(0.34, 1.45, 0.64, 1);
}

#scaleBeamGroup {
    transform-box: view-box;
    transform-origin: 300px 104px;
    animation: beamEquilibrium 5.2s ease-in-out infinite;
}

#leftPanTilt {
    transform-box: view-box;
    transform-origin: 148px 104px;
    transform: rotate(0deg);
    transition: transform 1.15s cubic-bezier(0.34, 1.45, 0.64, 1);
}

#leftPanGroup {
    transform-box: view-box;
    transform-origin: 148px 104px;
    animation: panEquilibrium 5.2s ease-in-out infinite;
}

#rightPanTilt {
    transform-box: view-box;
    transform-origin: 452px 104px;
    transform: rotate(0deg);
    transition: transform 1.15s cubic-bezier(0.34, 1.45, 0.64, 1);
}

#rightPanGroup {
    transform-box: view-box;
    transform-origin: 452px 104px;
    animation: panEquilibrium 5.2s ease-in-out infinite;
}

/* Стан переваги захисту після натискання кнопки */
.scales-boosted #scaleTiltGroup {
    transform: rotate(14.5deg);
}
.scales-boosted #leftPanTilt,
.scales-boosted #rightPanTilt {
    transform: rotate(-14.5deg);
}

@keyframes auraPulse {
    0%, 100% { opacity: 0.25; transform: scale(0.94); }
    50% { opacity: 0.55; transform: scale(1.03); }
}
.protection-aura {
    transform-box: fill-box;
    transform-origin: center;
    animation: auraPulse 3.6s ease-in-out infinite;
    transition: opacity 0.6s ease;
}
.scales-boosted .protection-aura {
    animation: none;
    opacity: 0.92;
    transform: scale(1.08);
}

@keyframes sparkleTwinkle {
    0%, 100% { opacity: 0.25; transform: scale(0.75); }
    50% { opacity: 1; transform: scale(1.3); }
}
.gold-sparkle {
    transform-box: fill-box;
    transform-origin: center;
    animation: sparkleTwinkle 2.6s ease-in-out infinite;
}
.gold-sparkle-delay-1 { animation-delay: 0.85s; }
.gold-sparkle-delay-2 { animation-delay: 1.7s; }

/* Активна вкладка прайсу */
.price-tab-active {
    background: linear-gradient(135deg, #b8862d 0%, #e5c167 50%, #9e701e 100%) !important;
    color: #030c21 !important;
    border-color: #fcf6ba !important;
    font-weight: 700;
    box-shadow: 0 0 20px rgba(212, 175, 55, 0.38);
}

/* Смужка прогресу прокручування зверху екрана */
#scrollProgress {
    position: fixed;
    top: 0;
    left: 0;
    height: 3px;
    width: 0%;
    z-index: 100;
    background: linear-gradient(90deg, #8c6218 0%, #d4af37 40%, #fcf6ba 75%, #ffffff 100%);
    box-shadow: 0 0 14px rgba(252, 246, 186, 0.85), 0 0 4px rgba(212, 175, 55, 0.9);
    transition: width 0.08s linear;
}

/* Плавна поява блоків при скролі */
.js-ready .reveal-up {
    opacity: 0;
    transform: translateY(24px);
    transition: opacity 0.75s cubic-bezier(0.22, 1, 0.36, 1), transform 0.75s cubic-bezier(0.22, 1, 0.36, 1);
}

.js-ready .reveal-up.is-visible {
    opacity: 1;
    transform: translateY(0);
}

/* Пульсуюче кільце для плаваючої кнопки 24/7 */
@keyframes urgentPulse {
    0% { box-shadow: 0 0 0 0 rgba(212, 175, 55, 0.55); }
    70% { box-shadow: 0 0 0 14px rgba(212, 175, 55, 0); }
    100% { box-shadow: 0 0 0 0 rgba(212, 175, 55, 0); }
}
.urgent-pulse {
    animation: urgentPulse 2.4s infinite;
}

@keyframes fadeInModal {
    from { opacity: 0; transform: translateY(12px) scale(0.97); }
    to { opacity: 1; transform: translateY(0) scale(1); }
}
.modal-animate {
    animation: fadeInModal 0.28s cubic-bezier(0.22, 1, 0.36, 1);
}

/* Спінер завантаження у кнопці відправки */
@keyframes spinSlow {
    to { transform: rotate(360deg); }
}
.btn-spinner {
    width: 16px;
    height: 16px;
    border: 2px solid rgba(3, 12, 33, 0.3);
    border-top-color: #030c21;
    border-radius: 50%;
    animation: spinSlow 0.7s linear infinite;
    display: inline-block;
    vertical-align: middle;
}

/* Повага до системних налаштувань зменшеного руху */
@media (prefers-reduced-motion: reduce) {
    .js-ready .reveal-up,
    .reveal-up { opacity: 1 !important; transform: none !important; transition: none !important; }
    .text-gold-shimmer,
    .urgent-pulse,
    .protection-aura,
    .gold-sparkle { animation: none !important; }
}

/* Делікатне золоте світіння для фірмового логотипу */
.logo-emblem-glow {
    filter: drop-shadow(0 4px 14px rgba(212, 175, 55, 0.35)) drop-shadow(0 0 6px rgba(58, 144, 200, 0.3));
    transition: transform 0.35s cubic-bezier(0.22, 1, 0.36, 1), filter 0.35s ease;
}
.group:hover .logo-emblem-glow {
    transform: scale(1.06);
    filter: drop-shadow(0 6px 20px rgba(252, 246, 186, 0.55)) drop-shadow(0 0 10px rgba(78, 167, 220, 0.45));
}
