/* Reset & Base */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

/* Reduced Motion for Accessibility */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
        scroll-behavior: auto !important;
    }
}

/* Focus Visible for Keyboard Navigation */
*:focus-visible {
    outline: 2px solid var(--primary-blue);
    outline-offset: 2px;
    border-radius: 4px;
}

/* Skip to Content Link for Accessibility */
.skip-link {
    position: absolute;
    top: -100px;
    left: 0;
    background: var(--primary-blue);
    color: white;
    padding: 8px 16px;
    text-decoration: none;
    z-index: 10000;
    opacity: 0;
    visibility: hidden;
    clip: rect(0, 0, 0, 0);
}

.skip-link:focus {
    top: 0;
    opacity: 1;
    visibility: visible;
    clip: auto;
}

:root {
    --primary-blue: #1E90FF;
    --dark-bg: #0a0a0a;
    --darker-bg: #000000;
    --card-bg: #1a1a1a;
    --text-primary: #ffffff;
    --text-secondary: #b3b3b3;
    --gradient-overlay: linear-gradient(180deg, rgba(0,0,0,0.4) 0%, rgba(0,0,0,0.2) 50%, rgba(0,0,0,0.5) 100%);
}

html {
    width: 100%;
    overflow-x: hidden;
    max-width: 100vw;
    margin: 0;
    padding: 0;
    border: none;
    border-top: none;
    outline: none;
    box-shadow: none;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', 'Helvetica', 'Arial', sans-serif;
    background-color: var(--dark-bg);
    color: var(--text-primary);
    line-height: 1.6;
    position: relative;
    width: 100%;
    overflow-x: hidden;
    max-width: 100vw;
    margin: 0;
    padding: 0;
    border: none;
    border-top: none;
    outline: none;
    box-shadow: none;
}

.container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 40px;
    width: 100%;
    box-sizing: border-box;
}

/* Header */
.header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    background: linear-gradient(180deg, rgba(0,0,0,0.95) 0%, rgba(0,0,0,0.85) 2%, rgba(0,0,0,0) 100%);
    padding: 15px 0;
    transition: background 0.3s ease;
    border: none;
    border-top: none;
    outline: none;
    box-shadow: none;
    margin: 0;
    height: auto;
}

.header.scrolled {
    background: rgba(0,0,0,0.95);
    backdrop-filter: blur(10px);
    border: none;
    outline: none;
    box-shadow: none;
    margin: 0;
}

.header-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 40px;
    position: relative;
}

.header-cta-btn {
    position: absolute;
    left: 50%;
    transform: translateX(-50%) !important;
    opacity: 1;
    visibility: visible;
    transition: opacity 0.3s ease, visibility 0.3s ease;
    white-space: nowrap;
    padding: 7.5px 20px !important;
    font-size: 8.5px !important;
    z-index: 100;
    width: auto !important;
    height: auto !important;
    min-width: auto !important;
    max-width: none !important;
}

.header-cta-btn.hidden {
    opacity: 0;
    visibility: hidden;
}

/* Кнопка внизу экрана после дождика */
.bottom-cta-btn {
    position: fixed;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
    white-space: nowrap;
    padding: 7.5px 20px;
    font-size: 8.5px;
    z-index: 1000;
    width: auto;
    max-width: calc(100vw - 40px);
    box-sizing: border-box;
}

.bottom-cta-btn.visible {
    opacity: 1;
    visibility: visible;
    animation: pulseCTA 3s ease-in-out infinite;
}

.bottom-cta-btn:hover {
    transform: translateX(-50%) scale(1.05);
    animation-play-state: paused;
}

.header-cta-btn.visible {
    opacity: 1;
    visibility: visible;
}

.header-cta-btn:hover {
    transform: translateX(-50%) scale(1.05);
    animation-play-state: paused;
}

@keyframes pulseCTA {
    0%, 100% {
        transform: translateX(-50%) scale(1);
        box-shadow: 0 8px 24px rgba(30, 144, 255, 0.4);
    }
    50% {
        transform: translateX(-50%) scale(1.08);
        box-shadow: 0 12px 32px rgba(30, 144, 255, 0.6);
    }
}

.logo {
    display: flex;
    align-items: center;
}

.logo img {
    height: 30px;
    width: auto;
    max-width: 100%;
}

.lang-selector {
    display: flex;
    align-items: center;
}

.lang-select {
    padding: 10px 36px 10px 14px;
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: 8px;
    color: var(--text-primary);
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
    appearance: none;
    -webkit-appearance: none;
    -moz-appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='14' viewBox='0 0 14 14' fill='none'%3E%3Cpath d='M3.5 5.25L7 8.75L10.5 5.25' stroke='%23ffffff' stroke-width='1.5' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 12px center;
    background-size: 14px;
    min-width: 70px;
    z-index: 100;
    position: relative;
}

.lang-select:hover {
    background-color: rgba(255, 255, 255, 0.12);
    border-color: rgba(255, 255, 255, 0.25);
}

.lang-select:focus {
    outline: none;
    border-color: rgba(30, 144, 255, 0.6);
    background-color: rgba(255, 255, 255, 0.12);
    box-shadow: 0 0 0 2px rgba(30, 144, 255, 0.15);
}

.lang-select option {
    background: #1a1a1a;
    color: var(--text-primary);
    padding: 12px 14px;
    font-size: 14px;
    font-weight: 500;
}

.lang-select option:hover {
    background: rgba(30, 144, 255, 0.2);
}

.lang-select option:checked {
    background: rgba(30, 144, 255, 0.3);
}

.lang-btn {
    padding: 8px 16px;
    background: transparent;
    border: none;
    color: var(--text-secondary);
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    border-radius: 6px;
    transition: all 0.3s ease;
}

.lang-btn:hover {
    color: var(--text-primary);
    background: rgba(255,255,255,0.05);
}

.lang-btn.active {
    background: var(--primary-blue);
    color: white;
}

/* Hero Section */
.hero {
    position: relative;
    height: 110vh;
    min-height: 800px;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    margin-top: 0;
    padding-top: 0;
    z-index: 1;
}

.hero-bg {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 1;
}

.hero-bg img,
.hero-bg picture {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: var(--gradient-overlay);
    z-index: 2;
}

/* Floating Rectangles */
.floating-rectangles {
    position: absolute;
    width: 100%;
    height: 100%;
    top: 0;
    left: 0;
    z-index: 3;
    pointer-events: none;
}

.floating-rect {
    position: absolute;
    width: 200px;
    height: 120px;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
    animation: shakeLight 3s ease-in-out infinite;
    opacity: 1 !important;
    background: #2f4356;
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    will-change: transform;
    contain: layout style paint;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 15px;
}

.floating-rect-text {
    color: var(--text-primary);
    font-size: 16px;
    font-weight: 700;
    text-align: center;
    line-height: 1.3;
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.8);
    word-wrap: break-word;
}

.floating-rect::after {
    display: none;
}

/* На hero - ближе к центру */
.floating-rectangles .floating-rect:nth-child(1) {
    top: 20%;
    left: 20%;
}

.floating-rectangles .floating-rect:nth-child(2) {
    top: 35%;
    left: 8%;
}

.floating-rectangles .floating-rect:nth-child(3) {
    top: 50%;
    left: 15%;
}

/* После прокрутки - фиксированные позиции по краям */
.floating-rectangles.fixed {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    z-index: 999;
}

/* Десктопные стили для fixed состояния - только для больших экранов */
@media (min-width: 481px) {
    .floating-rectangles.fixed .floating-rect:nth-child(1) {
        top: 20%;
        left: 10px;
        transform: translateX(0);
    }

    .floating-rectangles.fixed .floating-rect:nth-child(2) {
        top: 50%;
        left: 10px;
        transform: translateX(0);
    }

    .floating-rectangles.fixed .floating-rect:nth-child(3) {
        top: 35%;
        right: 10px;
        left: auto;
        transform: translateX(0);
    }

    /* Для фиксированных прямоугольников - легкая тряска */
    .floating-rectangles.fixed .floating-rect:nth-child(1) {
        animation: shakeLightLeft 3s ease-in-out infinite;
    }

    .floating-rectangles.fixed .floating-rect:nth-child(2) {
        animation: shakeLightLeft 3s ease-in-out infinite 0.5s;
    }

    .floating-rectangles.fixed .floating-rect:nth-child(3) {
        animation: shakeLightRight 3s ease-in-out infinite;
    }
}

@keyframes shake {
    0%, 100% { transform: rotate(0deg); }
    25% { transform: rotate(-15deg); }
    75% { transform: rotate(15deg); }
}

@keyframes shakeLeft {
    0%, 100% { transform: translateX(0) rotate(0deg); }
    25% { transform: translateX(0) rotate(-15deg); }
    75% { transform: translateX(0) rotate(15deg); }
}

@keyframes shakeRight {
    0%, 100% { transform: translateX(0) rotate(0deg); }
    25% { transform: translateX(0) rotate(-15deg); }
    75% { transform: translateX(0) rotate(15deg); }
}

/* Легкое качание для брендов ТВ */
@keyframes shakeLight {
    0%, 100% { transform: rotate(0deg); }
    25% { transform: rotate(-3deg); }
    75% { transform: rotate(3deg); }
}

/* Легкое качание для фиксированных элементов (с translateX) */
@keyframes shakeLightLeft {
    0%, 100% { transform: rotate(0deg); }
    25% { transform: rotate(-3deg); }
    75% { transform: rotate(3deg); }
}

@keyframes shakeLightRight {
    0%, 100% { transform: rotate(0deg); }
    25% { transform: rotate(-3deg); }
    75% { transform: rotate(3deg); }
}

/* Легкое качание для элементов с translate(-50%, 0) */
@keyframes shakeLightCenter {
    0%, 100% { transform: translate(-50%, 0) rotate(0deg); }
    25% { transform: translate(-50%, 0) rotate(-3deg); }
    75% { transform: translate(-50%, 0) rotate(3deg); }
}

.hero-cta-btn {
    transition: opacity 0.3s ease, transform 0.3s ease;
}

.hero-cta-btn.hidden {
    opacity: 0;
    pointer-events: none;
}

.hero-content {
    position: relative;
    z-index: 10;
    text-align: center;
    padding-top: 80px;
}

.hero-title {
    font-size: 64px;
    font-weight: 800;
    margin-bottom: 40px;
    text-shadow: 0 4px 20px rgba(0,0,0,0.8);
    line-height: 1.2;
}

.btn-primary {
    padding: 18px 48px;
    background: var(--primary-blue);
    color: white;
    border: none;
    border-radius: 12px;
    font-size: 20px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 8px 24px rgba(30, 144, 255, 0.4);
    display: inline-block;
    text-decoration: none;
    text-align: center;
}

.btn-primary:hover {
    background: #1873CC;
    transform: translateY(-2px);
    box-shadow: 0 12px 32px rgba(30, 144, 255, 0.6);
}

/* Section Styles */
.section {
    padding: 100px 0;
    width: 100%;
    max-width: 100vw;
    box-sizing: border-box;
    overflow-x: hidden;
}

.section-title {
    font-size: 48px;
    font-weight: 800;
    margin-bottom: 60px;
    text-align: center;
}

.highlight {
    color: var(--primary-blue);
}

/* Exclusive Content Section */
.exclusive-section {
    background: linear-gradient(180deg, var(--dark-bg) 0%, var(--darker-bg) 100%);
}

.slider-container {
    position: relative;
}

.slider {
    overflow: hidden;
    padding: 20px 0;
}

.slider-track {
    display: flex;
    gap: 24px;
    transition: transform 0.5s ease;
    width: fit-content;
    will-change: transform;
    contain: layout style;
}

/* Отключаем transition для эскалатора */
.slider-track.escalator-setup {
    transition: none !important;
}

.content-card {
    flex: 0 0 auto;
    width: 400px;
    height: 600px;
    border-radius: 16px;
    overflow: hidden;
    cursor: pointer;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    box-shadow: 0 8px 24px rgba(0,0,0,0.5);
    position: relative;
    z-index: 1;
    contain: layout style paint;
}

.content-card:hover {
    transform: scale(1.05);
    box-shadow: 0 12px 40px rgba(30, 144, 255, 0.3);
    z-index: 10;
}

.content-card img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    image-rendering: -webkit-optimize-contrast;
    image-rendering: crisp-edges;
}

.slider-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(255,255,255,0.1);
    backdrop-filter: blur(10px);
    border: none;
    width: 60px;
    height: 60px;
    border-radius: 50%;
    cursor: pointer;
    color: white;
    transition: all 0.3s ease;
    z-index: 10;
}

.slider-btn:hover {
    background: rgba(255,255,255,0.2);
    transform: translateY(-50%) scale(1.1);
}

.slider-btn-prev {
    left: -30px;
}

.slider-btn-next {
    right: -30px;
}

/* Эффект эскалатора - непрерывная прокрутка для всех версий */
.exclusive-section .slider-btn,
.premieres-section .slider-btn {
    display: none !important;
}

.exclusive-section .slider-track {
    transition: none !important;
    animation: scrollInfiniteRight 30s linear infinite;
    will-change: transform;
}

.premieres-section .slider-track {
    transition: none !important;
    animation: scrollInfiniteLeft 30s linear infinite;
    will-change: transform;
}

/* Убираем transition для всех версий, чтобы анимация работала плавно */
.exclusive-section .slider-track.escalator-setup,
.premieres-section .slider-track.escalator-setup {
    transition: none !important;
    animation-play-state: running !important;
}

@keyframes scrollInfiniteRight {
    0% {
        transform: translateX(0);
    }
    100% {
        transform: translateX(-50%);
    }
}

@keyframes scrollInfiniteLeft {
    0% {
        transform: translateX(-50%);
    }
    100% {
        transform: translateX(0);
    }
}

/* Premieres Section */
.premieres-section {
    background: linear-gradient(180deg, var(--darker-bg) 0%, var(--dark-bg) 100%);
}

.section-cta {
    text-align: center;
}

/* Platform Section */
.platform-section {
    background: linear-gradient(180deg, var(--dark-bg) 0%, var(--darker-bg) 100%);
    padding: 60px 0 30px;
}

.platform-content {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 40px;
}

.platform-text {
    flex: 1;
}

.platform-text .section-title {
    text-align: left;
    margin-bottom: 30px;
}

.platform-description {
    font-size: 18px;
    line-height: 1.8;
    color: var(--text-secondary);
    margin-bottom: 40px;
}

/* TV Brand Logos in Platform Section */
.platform-brands {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 20px;
    flex-wrap: nowrap;
    margin-top: 40px;
}

.platform-brand-item {
    background: rgba(255, 255, 255, 0.05);
    border-radius: 12px;
    padding: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: transform 0.3s ease, background 0.3s ease;
    width: 117px;
    min-width: 100px;
    max-width: 117px;
    height: 67px;
    flex-shrink: 1;
    animation: shakeLight 3s ease-in-out infinite;
    overflow: hidden;
    will-change: transform;
    contain: layout style paint;
}

.platform-brand-item:nth-child(1) {
    animation-delay: 0s;
}

.platform-brand-item:nth-child(2) {
    animation-delay: 0.5s;
}

.platform-brand-item:nth-child(3) {
    animation-delay: 1s;
}

.platform-brand-item:nth-child(4) {
    animation-delay: 1.5s;
}

.platform-brand-item:hover {
    background: rgba(255, 255, 255, 0.1);
    transform: translateY(-5px);
    animation-play-state: paused;
}

.platform-brand-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 1;
}

.platform-image {
    flex: 1;
    display: flex;
    justify-content: center;
    align-items: center;
}

.platform-image img {
    width: 100%;
    height: auto;
    max-width: 100%;
    transform: scale(1.1);
}

/* Kids Section */
.kids-section {
    background: linear-gradient(180deg, var(--dark-bg) 0%, var(--darker-bg) 100%);
    padding: 30px 0 60px;
}

.kids-section .parental-control-content {
    margin-top: 40px;
    padding-top: 40px;
}

.kids-content {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 40px;
}

.kids-image {
    flex: 1;
    display: flex;
    justify-content: center;
    align-items: center;
}

.kids-image img {
    width: 100%;
    height: auto;
    max-width: 100%;
    transform: scale(1.1);
    border-radius: 30px;
}

.kids-text {
    flex: 1;
}

.kids-text .section-title {
    text-align: left;
    margin-bottom: 30px;
}

.kids-description {
    font-size: 18px;
    line-height: 1.8;
    color: var(--text-secondary);
}

/* Library Section */
.library-section {
    background: var(--darker-bg);
    padding: 120px 0;
}

.library-grid {
    display: grid;
    grid-template-columns: repeat(8, 1fr);
    gap: 24px;
    align-items: start;
    margin-bottom: 60px;
}

.library-cta {
    text-align: center;
    margin-top: 60px;
    padding-top: 40px;
}

.library-cta-btn {
    display: inline-block;
}

.library-card {
    background: linear-gradient(135deg, #2a2a2a 0%, #1a1a1a 100%);
    border-radius: 16px;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    width: 100%;
    aspect-ratio: 16/9;
    height: auto;
    overflow: hidden;
    contain: layout style paint;
}

.library-card img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

/* Шахматный порядок - паттерн 4-3-4-3 */
/* Ряд 1: карточки 1,2,3,4 */
.library-card:nth-child(7n+1) { grid-column: 1 / 3; }
.library-card:nth-child(7n+2) { grid-column: 3 / 5; }
.library-card:nth-child(7n+3) { grid-column: 5 / 7; }
.library-card:nth-child(7n+4) { grid-column: 7 / 9; }

/* Ряд 2: карточки 5,6,7 (смещены на 1 колонку) */
.library-card:nth-child(7n+5) { grid-column: 2 / 4; }
.library-card:nth-child(7n+6) { grid-column: 4 / 6; }
.library-card:nth-child(7n+7) { grid-column: 6 / 8; }

/* Ряд 3 starts автоматически с карточки 8 (7n+1 where n=1) */

.library-card:hover {
    transform: scale(1.05);
    box-shadow: 0 12px 32px rgba(30, 144, 255, 0.3);
    z-index: 10;
}

/* Footer */
.footer {
    background: var(--darker-bg);
    padding: 80px 0 40px;
    border-top: 1px solid #2a2a2a;
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 40px;
    margin-bottom: 60px;
}

.footer-title {
    font-size: 16px;
    font-weight: 700;
    margin-bottom: 20px;
}

.footer-links {
    list-style: none;
}

.footer-links li {
    margin-bottom: 12px;
}

.footer-links a {
    color: var(--text-secondary);
    text-decoration: none;
    font-size: 14px;
    transition: color 0.3s ease;
}

.footer-links a:hover {
    color: var(--primary-blue);
}

.app-links {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.app-btn {
    display: flex;
    flex-direction: column;
    padding: 8px 16px;
    background: var(--card-bg);
    border-radius: 8px;
    text-decoration: none;
    color: var(--text-primary);
    transition: all 0.3s ease;
}

.app-btn:hover {
    background: var(--primary-blue);
    transform: translateY(-2px);
}

.app-btn span {
    font-size: 11px;
    color: var(--text-secondary);
}

.app-btn strong {
    font-size: 14px;
}

.smart-tv {
    padding: 8px 16px;
    background: var(--card-bg);
    border-radius: 8px;
}

.smart-tv span {
    font-size: 11px;
    color: var(--text-secondary);
    display: block;
}

.smart-tv strong {
    font-size: 14px;
    display: block;
}

.social-links {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
}

.social-icon {
    width: 40px;
    height: 40px;
    background: var(--card-bg);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-primary);
    transition: all 0.3s ease;
}

.social-icon:hover {
    background: var(--primary-blue);
    transform: translateY(-2px);
}

.footer-bottom {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: 40px;
    border-top: 1px solid #2a2a2a;
    color: var(--text-secondary);
    font-size: 14px;
}

.footer-lang {
    display: flex;
    gap: 20px;
}

.footer-lang a {
    color: var(--text-secondary);
    text-decoration: none;
    transition: color 0.3s ease;
}

.footer-lang a:hover {
    color: var(--primary-blue);
}

.footer-lang a.active {
    color: var(--primary-blue);
    font-weight: 700;
}

/* Responsive */
@media (max-width: 1200px) {
    .container {
        padding: 0 24px;
    }

    .hero-title {
        font-size: 48px;
    }

.section-title {
        font-size: 36px;
    }

    .content-card {
        width: 320px;
        height: 480px;
    }

    .library-grid {
        grid-template-columns: repeat(4, 1fr);
    }
    
    .footer-content {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (max-width: 768px) {
    .hero-title {
        font-size: 32px;
    }

    .section-title {
        font-size: 28px;
    }

    .section {
        padding: 60px 0;
    }
    
    /* Уменьшение кнопок на мобильных */
    .btn-primary {
        padding: 12px 32px;
        font-size: 16px;
    }
    
    .header-cta-btn {
        padding: 6px 16px;
        font-size: 10px;
    }

    .platform-content,
    .kids-content {
        flex-direction: column;
        gap: 40px;
    }

    .platform-text,
    .kids-text {
        flex: 1 1 auto;
        max-width: 100%;
    }

    .platform-text .section-title,
    .kids-text .section-title {
    text-align: center;
    }

    .platform-image img,
    .kids-image img {
        transform: scale(1);
    }

    .content-card {
        width: 280px;
        height: 420px;
    }

    .library-section {
        padding: 80px 0;
    }

    .library-grid {
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
        margin-bottom: 50px;
    }
    
    .library-cta {
        margin-top: 50px;
        padding-top: 35px;
    }
    
    /* Tablet - упрощенный шахматный порядок */
    .library-card { grid-column: span 1; }
    
    /* Ряд 1: 1,2 */
    .library-card:nth-child(5n+1) { grid-column: 1 / 2; }
    .library-card:nth-child(5n+2) { grid-column: 2 / 3; }
    
    /* Ряд 2: 3 (смещен) */
    .library-card:nth-child(5n+3) { grid-column: 2 / 3; }
    
    /* Ряд 3: 4,5 */
    .library-card:nth-child(5n+4) { grid-column: 1 / 2; }
    .library-card:nth-child(5n+5) { grid-column: 2 / 3; }
    
    .footer-content {
        grid-template-columns: repeat(2, 1fr);
    }

    .slider-btn {
        width: 44px;
        height: 44px;
    }

    .slider-btn-prev {
        left: 0;
    }
    
    .slider-btn-next {
        right: 0;
    }
}

@media (max-width: 480px) {
    .hero-title {
        font-size: 24px;
    }

    .section-title {
        font-size: 24px;
    }

    .content-card {
        width: 240px;
        height: 360px;
    }
    
    /* Уменьшение кнопок на маленьких экранах */
    .btn-primary {
        padding: 10px 24px;
        font-size: 14px;
    }
    
    .header-cta-btn {
        padding: 5px 12px;
        font-size: 9px;
    }
    
    .lang-select {
        padding: 8px 14px;
        font-size: 13px;
        min-width: 60px;
        margin-left: auto;
        margin-right: 10px;
        background: rgba(255, 255, 255, 0.08);
        border: 1px solid rgba(255, 255, 255, 0.15);
        border-radius: 8px;
        background-image: none;
        text-align: center;
    }
    
    .lang-select:focus {
        background: rgba(255, 255, 255, 0.12);
        border-color: rgba(30, 144, 255, 0.6);
        box-shadow: 0 0 0 2px rgba(30, 144, 255, 0.15);
    }
    
    /* TV-каналы спорта в нижней части, заголовок и текст выше - только для мобильных */
    .sport-section {
        display: flex !important;
        flex-direction: column !important;
        justify-content: flex-start !important;
        min-height: auto !important;
        height: auto !important;
        overflow: visible !important;
        padding: 60px 0 !important;
        position: relative !important;
        background-image: image-set(url('/images/sport/sport-bg.webp') type('image/webp'), url('/images/sport/sport-bg.png') type('image/png')) !important;
        background-position: left 0% top 130% !important;
        background-repeat: no-repeat !important;
        background-size: auto !important;
    }
    
    .sport-section .container {
        margin-bottom: 0 !important;
        padding-top: 30px !important;
        justify-content: flex-start !important;
    }
    
    .sport-section .section-title {
        margin-bottom: 15px !important;
    }
    
    .sport-description {
        margin-bottom: 15px !important;
        
    }
    
    /* Обертка для всех каналов */
    .sport-floating-top {
        position: relative !important;
        width: 100% !important;
        /* увеличиваем высоту, чтобы разместить 3 ряда без наложений */
        height: 85vh !important;
        margin-top: 20px !important;
        z-index: 3 !important; /* выше фоновой картинки */
        pointer-events: auto !important; /* разрешаем взаимодействия */
    }
    
    /* Ряд 1: футбол (слева 5%, top 55%) и живи (справа 5%, top 55%) */
    .sport-section .sport-floating-top .sport-float-card.sport-float-1 {
        position: absolute !important;
        left: 5% !important;
        right: auto !important;
        top: 20% !important;
        bottom: auto !important;
        width: 42% !important;
        max-width: 140px !important;
        z-index: 5 !important;
        margin: 0 !important;
        padding: 0 !important;
        transform: scale(1.2) translateY(-50%) rotate(0deg);
        animation: shakeLightLeftMobile 3s ease-in-out infinite !important;
        animation-delay: 0.4s !important;
        animation-fill-mode: both !important;
    }
    
    .sport-section .sport-floating-top .sport-card-3,
    .sport-section .sport-floating-top .sport-card.sport-card-3 {
        position: absolute !important;
        right: 5% !important;
        top: 20% !important;
        width: 42% !important;
        max-width: 140px !important;
        z-index: 5 !important;
        transform: scale(1.2) translateY(-50%) rotate(0deg);
        animation: shakeLightRightMobile 3s ease-in-out infinite !important;
        animation-delay: 1.2s !important;
    }
    
    /* Ряд 2: Зор (слева 12%, top 40%) и матч! (справа 12%, top 40%) */
    .sport-section .sport-floating-top .sport-float-card.sport-float-3 {
        position: absolute !important;
        left: 12% !important;
        right: auto !important;
        top: 40% !important;
        bottom: auto !important;
        width: 45% !important;
        max-width: 140px !important;
        height: auto !important;
        z-index: 5 !important;
        margin: 0 !important;
        padding: 0 !important;
        transform: translateY(-50%) rotate(0deg);
        animation: shakeLightRightMobileNoScale 3s ease-in-out infinite !important;
        animation-delay: 0.6s !important;
        animation-fill-mode: both !important;
    }
    
    .sport-section .sport-floating-top .sport-float-card.sport-float-2 {
        position: absolute !important;
        right: 12% !important;
        left: auto !important;
        top: 40% !important;
        bottom: auto !important;
        width: 45% !important;
        max-width: 140px !important;
        height: auto !important;
        z-index: 5 !important;
        margin: 0 !important;
        padding: 0 !important;
        transform: translateY(-50%) rotate(0deg);
        animation: shakeLightCenterMobile 3s ease-in-out infinite !important;
        animation-delay: 0.2s !important;
        animation-fill-mode: both !important;
    }
    
    /* Ряд 3: Трейс (слева 5%, top 75%) и Спорт (справа 5%, top 75%) */
    .sport-section .sport-floating-top .sport-cards {
        position: absolute !important;
        left: 0 !important;
        right: 0 !important;
        top: 45% !important;
        display: flex !important;
        flex-direction: row !important;
        justify-content: space-between !important;
        padding: 0 5% !important;
        width: 100% !important;
        box-sizing: border-box !important;
        z-index: 4 !important;
        pointer-events: auto !important;
    }
    
    .sport-section .sport-floating-top .sport-card-2 {
        position: absolute !important;
        width: 42% !important;
        max-width: 140px !important;
        left: 5% !important;
        top: 60% !important;
        z-index: 5 !important;
        transform: scale(1.2) translateY(-50%) rotate(0deg);
        animation: shakeLightLeftMobile 3s ease-in-out infinite !important;
        animation-delay: 1.4s !important;
    }
    
    .sport-section .sport-floating-top .sport-card-1 {
        position: absolute !important;
        width: 42% !important;
        max-width: 140px !important;
        right: 5% !important;
        top: 60% !important;
        z-index: 5 !important;
        transform: scale(1.2) translateY(-50%) rotate(0deg);
        animation: shakeLightLeftMobile 3s ease-in-out infinite !important;
        animation-delay: 1s !important;
    }
    
    /* Анимации для мобильной версии с учетом translateY(-50%) и scale */
    @keyframes shakeLightLeftMobile {
        0%, 100% { transform: scale(1.2) translateY(-50%) rotate(0deg); }
        25% { transform: scale(1.2) translateY(-50%) rotate(-3deg); }
        75% { transform: scale(1.2) translateY(-50%) rotate(3deg); }
    }
    
    @keyframes shakeLightRightMobile {
        0%, 100% { transform: scale(1.2) translateY(-50%) rotate(0deg); }
        25% { transform: scale(1.2) translateY(-50%) rotate(3deg); }
        75% { transform: scale(1.2) translateY(-50%) rotate(-3deg); }
    }
    
    @keyframes shakeLightRightMobileNoScale {
        0%, 100% { transform: translateY(-50%) rotate(0deg); }
        25% { transform: translateY(-50%) rotate(3deg); }
        75% { transform: translateY(-50%) rotate(-3deg); }
    }
    
    @keyframes shakeLightCenterMobile {
        0%, 100% { transform: translateY(-50%) rotate(0deg); }
        25% { transform: translateY(-50%) rotate(-3deg); }
        75% { transform: translateY(-50%) rotate(3deg); }
    }
    
    /* Ensure images inside cards scale responsively */
    .sport-section .sport-floating-top img {
        width: 100% !important;
        height: auto !important;
        display: block !important;
    }
    
    /* Паттерн дождика для мобильных - паттерн 4-3-4-3 как на десктопе */
    .library-section {
        overflow-x: hidden;
    }
    
    .library-grid {
        grid-template-columns: repeat(8, 1fr) !important;
        gap: 24px !important;
        margin: 0 auto;
        padding: 0 15px;
        max-width: 100%;
    }
    
    /* Паттерн 4-3-4-3 как на десктопе */
    /* Ряд 1: карточки 1,2,3,4 */
    .library-card:nth-child(7n+1) { 
        grid-column: 1 / 3 !important; 
    }
    .library-card:nth-child(7n+2) { 
        grid-column: 3 / 5 !important; 
    }
    .library-card:nth-child(7n+3) { 
        grid-column: 5 / 7 !important; 
    }
    .library-card:nth-child(7n+4) { 
        grid-column: 7 / 9 !important; 
    }
    
    /* Ряд 2: карточки 5,6,7 (смещены на 1 колонку) */
    .library-card:nth-child(7n+5) { 
        grid-column: 2 / 4 !important; 
    }
    .library-card:nth-child(7n+6) { 
        grid-column: 4 / 6 !important; 
    }
    .library-card:nth-child(7n+7) { 
        grid-column: 6 / 8 !important; 
    }
    
    /* Уменьшение логотипа на мобильных */
    .logo img {
        height: 24px;
        max-width: 100px;
    }
    
    /* Сдвиг выпадающего списка языков левее */
    .header-content {
        gap: 10px;
        padding: 0 10px;
        align-items: center;
    }
    
    .lang-selector {
        order: 3;
        margin-left: auto;
        display: flex;
        align-items: center;
    }
    
    .logo {
        display: flex;
        align-items: center;
    }
    
    /* Уменьшение кнопок брендов в 0.9 раз и уменьшение расстояния */
    .platform-brands {
        gap: 10px !important;
        
        justify-content: center !important;
        padding: 0 10px !important;
        max-width: 100% !important;
        box-sizing: border-box !important;
    }
    
    .platform-brand-item {
        width: 90px !important;
        min-width: 80px !important;
        max-width: 90px !important;
        height: 50px !important;
        flex-shrink: 0 !important;
        overflow: hidden !important;
    }
    
    .platform-brand-item img {
        width: 100% !important;
        height: 100% !important;
        object-fit: contain !important;
        padding: 0px !important;
        box-sizing: border-box !important;
    }
    
    /* Прямоугольники на hero ниже кнопки на мобильных */
    .floating-rectangles .floating-rect:nth-child(1) {
        top: 70% !important;
        left: 0% !important;
        transform: scale(0.8) !important;
    }
    
    .floating-rectangles .floating-rect:nth-child(2) {
        top: 70% !important;
        left: 32% !important;
        transform: scale(0.8) !important;
    }
    
    .floating-rectangles .floating-rect:nth-child(3) {
        top: 70% !important;
        left: 63% !important;
        transform: scale(0.8) !important;
    }
    
    /* Для fixed состояния на мобильной версии - сохраняем scale и добавляем анимацию */
    .floating-rectangles.fixed .floating-rect:nth-child(1) {
        top: 20% !important;
        left: 10px !important;
        right: auto !important;
        transform: scale(0.4) translateX(0);
        animation: shakeLightLeftMobileHero 3s ease-in-out infinite !important;
    }
    
    .floating-rectangles.fixed .floating-rect:nth-child(2) {
        top: 50% !important;
        left: 10px !important;
        right: auto !important;
        transform: scale(0.4) translateX(0);
        animation: shakeLightLeftMobileHero 3s ease-in-out infinite 0.5s !important;
    }
    
    .floating-rectangles.fixed .floating-rect:nth-child(3) {
        top: 35% !important;
        right: 10px !important;
        left: auto !important;
        transform: scale(0.4) translateX(0);
        animation: shakeLightRightMobileHero 3s ease-in-out infinite !important;
    }
    
    /* Анимации для прямоугольников на hero в мобильной версии с учетом scale */
    @keyframes shakeLightLeftMobileHero {
        0%, 100% { transform: scale(0.4) translateX(0) rotate(0deg); }
        25% { transform: scale(0.4) translateX(0) rotate(-3deg); }
        75% { transform: scale(0.4) translateX(0) rotate(3deg); }
    }
    
    @keyframes shakeLightRightMobileHero {
        0%, 100% { transform: scale(0.4) translateX(0) rotate(0deg); }
        25% { transform: scale(0.4) translateX(0) rotate(3deg); }
        75% { transform: scale(0.4) translateX(0) rotate(-3deg); }
    }
    
    .library-section {
        padding: 60px 0;
    }

    .library-grid {
        grid-template-columns: 1fr;
        gap: 16px;
        margin-bottom: 40px;
    }

    /* Mobile - без шахматного порядка */
    .library-card {
        grid-column: 1 / 2 !important;
    }

    .library-card:hover {
        transform: scale(1.02);
    }
    
    .library-cta {
        margin-top: 40px;
        padding-top: 30px;
    }

    .footer-content {
        grid-template-columns: 1fr;
    }

    .footer-bottom {
        flex-direction: column;
        gap: 20px;
        text-align: center;
    }
    
    /* Floating rectangles mobile */
    .floating-rect {
        width: 150px;
        height: 90px;
    }
    
    .floating-rect::after {
        font-size: 12px;
        padding: 10px 8px 8px;
    }
    
    
    /* Parental Control mobile */
    .parental-control-content {
        flex-direction: column;
        text-align: center;
    }
    
    /* Sport cards mobile - уменьшение в 0.7 раз */
    .sport-cards {
        position: absolute !important;
        height: 100% !important;
        pointer-events: auto !important;
        z-index: 4 !important;
    }
    
    .sport-card {
        width: 140px !important;
        height: 84px !important;
    }
    
    .sport-float-card {
        width: 140px !important;
        height: 84px !important;
    }
    
    /* Premium logos mobile */
    .premium-sports-logos {
        grid-template-columns: repeat(3, 1fr);
        gap: 20px;
    }
}

/* Parental Control Content (now inside kids section) */
.parental-control-content {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 60px;
    flex-wrap: wrap;
}

.parental-control-icon {
    flex: 0 0 auto;
}

.parental-control-icon img {
    max-width: 300px;
    height: auto;
    filter: drop-shadow(0 10px 30px rgba(30, 144, 255, 0.5));
}

.parental-control-text {
    flex: 1;
    min-width: 300px;
}

.parental-control-description {
    font-size: 18px;
    color: var(--text-secondary);
    margin-top: 20px;
}

/* Sport Section */
.sport-section {
    padding: 100px 0;
    background: linear-gradient(180deg, var(--dark-bg) 0%, var(--darker-bg) 100%);
    background-image: url('/images/sport/sport-bg.webp');
    background-position: top right;
    background-repeat: no-repeat;
    background-size: auto;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 80vh;
}

/* Floating Sport Cards Above Title */
.sport-floating-top {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    width: 100%;
    height: 100%;
    z-index: 2; /* base */
    pointer-events: auto; /* allow interactions */
}

/* Ensure floating-top children are above background */
.sport-floating-top > * {
    z-index: 4;
}

.sport-float-card {
    position: absolute;
    width: 200px;
    height: 120px;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
}

/* Увеличение размеров TV-каналов для десктопной версии в 1.5 раза */
@media (min-width: 481px) {
    .sport-float-card {
        width: 300px;
        height: 180px;
    }
    
    .sport-card {
        width: 300px;
        height: 180px;
    }
    
    /* Специфичные каналы - также увеличиваем в 1.5 раза */
    .sport-card-1,
    .sport-card-2,
    .sport-card-3 {
        width: 300px !important;
        height: 180px !important;
    }
}

.sport-float-card img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* Матч! Планета - 10% от верха по центру - только для десктопа */
@media (min-width: 481px) {
    .sport-float-card.sport-float-2 {
        left: 50% !important;
        right: auto !important;
        top: 10% !important;
        bottom: auto !important;
        transform: translateX(-50%);
        animation: shakeLightCenter 3s ease-in-out infinite;
        animation-delay: 0.2s;
    }
}

/* Futbol - 15% от левого края, 25% от верха - только для десктопа */
@media (min-width: 481px) {
    .sport-float-card.sport-float-1 {
        left: 15% !important;
        right: auto !important;
        top: 20% !important;
        bottom: auto !important;
        animation: shakeLightLeft 3s ease-in-out infinite;
        animation-delay: 0.4s;
    }
}

/* Zo'r TV - 15% от правого края, 25% от верха - только для десктопа */
@media (min-width: 481px) {
    .sport-float-card.sport-float-3 {
        right: 15% !important;
        left: auto !important;
        top: 20% !important;
        bottom: auto !important;
        animation: shakeLightRight 3s ease-in-out infinite;
        animation-delay: 0.6s;
    }
}

.sport-section .container {
    position: relative;
    z-index: 3;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

.sport-section .section-title {
    margin-bottom: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 15px;
    flex-wrap: wrap;
}

.sport-logo {
    height: 50px;
    width: auto;
    display: inline-block;
    vertical-align: middle;
}

.sport-description {
    font-size: 20px;
    color:var(--text-secondary);
    text-align: center;
    margin-bottom: 60px;
}

.sport-cards {
    position: absolute;
    width: 100%;
    height: 100%;
    top: 0;
    left: 0;
    z-index: 3;
    pointer-events: auto;
}

.sport-card {
    position: absolute;
    width: 200px;
    height: 120px;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
}

.sport-card img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* Sport - 15% от левого края, 25% от низа - только для десктопа */
@media (min-width: 481px) {
    .sport-card-1 {
        left: 15% !important;
        bottom: 20% !important;
        top: auto !important;
        right: auto !important;
        animation: shakeLightLeft 3s ease-in-out infinite;
        animation-delay: 1s;
    }
}

/* Живи - 15% от правого края, 25% от низа */
.sport-card-3 {
    right: 15% !important;
    bottom: 20% !important;
    top: auto !important;
    left: auto !important;
    animation: shakeLightRight 3s ease-in-out infinite;
    animation-delay: 1.2s;
}

/* Trace Sport Stars - 10% от низа по центру - только для десктопа */
@media (min-width: 481px) {
    .sport-card-2 {
        left: 50% !important;
        bottom: 10% !important;
        top: auto !important;
        right: auto !important;
        transform: translate(-50%, 0);
        animation: shakeLightCenter 3s ease-in-out infinite !important;
        animation-delay: 1.4s !important;
    }
}

/* Smart TV Modal */
.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 10000;
    align-items: center;
    justify-content: center;
}

.modal.active {
    display: flex;
}

.modal-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(5px);
}

.modal-content {
    position: relative;
    background: linear-gradient(135deg, #1a1a1a 0%, #2a2a2a 100%);
    border-radius: 20px;
    padding: 40px;
    max-width: 500px;
    width: 90%;
    z-index: 10001;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.modal-close {
    position: absolute;
    top: 15px;
    right: 15px;
    background: transparent;
    border: none;
    color: var(--text-primary);
    font-size: 32px;
    cursor: pointer;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: all 0.3s ease;
    line-height: 1;
}

.modal-close:hover {
    background: rgba(255, 255, 255, 0.1);
    transform: rotate(90deg);
}

.modal-title {
    font-size: 24px;
    font-weight: 700;
    margin-bottom: 30px;
    text-align: center;
    color: var(--text-primary);
}

.modal-buttons {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.modal-tv-btn {
    padding: 20px 30px;
    background: var(--card-bg);
    border: 2px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    color: var(--text-primary);
    font-size: 18px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    text-align: center;
}

.modal-tv-btn:hover {
    background: var(--primary-blue);
    border-color: var(--primary-blue);
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(30, 144, 255, 0.3);
}

.modal-tv-btn strong {
    display: block;
}

.modal-instructions {
    max-width: 600px;
}

.instructions-content {
    margin-bottom: 30px;
}

.instruction-step {
    margin-bottom: 20px;
    padding: 15px 20px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 10px;
    border-left: 3px solid var(--primary-blue);
}

.instruction-step-number {
    display: inline-block;
    width: 30px;
    height: 30px;
    background: var(--primary-blue);
    color: white;
    border-radius: 50%;
    text-align: center;
    line-height: 30px;
    font-weight: 700;
    margin-right: 15px;
    font-size: 16px;
}

.instruction-step-text {
    display: inline-block;
    color: var(--text-primary);
    font-size: 16px;
    line-height: 1.6;
    vertical-align: middle;
}

.modal-back-btn {
    width: 100%;
    padding: 15px 30px;
    background: var(--card-bg);
    border: 2px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    color: var(--text-primary);
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    margin-top: 20px;
}

.modal-back-btn:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: rgba(255, 255, 255, 0.2);
    transform: translateY(-2px);
}

@media (max-width: 480px) {
    .modal-content {
        padding: 30px 20px;
        max-width: 90%;
    }
    
    .modal-title {
        font-size: 20px;
        margin-bottom: 25px;
    }
    
    .modal-tv-btn {
        padding: 16px 24px;
        font-size: 16px;
    }
    
    .instruction-step {
        padding: 12px 15px;
    }
    
    .instruction-step-number {
        width: 25px;
        height: 25px;
        line-height: 25px;
        font-size: 14px;
        margin-right: 10px;
    }
    
    .instruction-step-text {
        font-size: 14px;
    }
}

