:root {
    --bg: #05070d;
    --panel: #0b1020;
    --panel2: #111827;
    --card: #101827;
    --line: rgba(255,255,255,.10);
    --line2: rgba(255,255,255,.18);
    --text: #ffffff;
    --muted: rgba(255,255,255,.66);
    --muted2: rgba(255,255,255,.44);
    --red: #e50914;
    --red2: #ff3540;
    --blue: #3b82f6;
    --header: 76px;
    --radius: 22px;
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    background: var(--bg);
}

html.player-open,
body.player-open,
html.radio-open,
body.radio-open {
    overflow: hidden !important;
    height: 100% !important;
    overscroll-behavior: none !important;
}

body {
    margin: 0;
    background: var(--bg);
    color: var(--text);
    font-family: Inter, system-ui, -apple-system, "Segoe UI", Arial, sans-serif;
    -webkit-font-smoothing: antialiased;
    text-rendering: optimizeLegibility;
}

a {
    color: inherit;
    text-decoration: none;
}

button,
input,
textarea,
select {
    font: inherit;
}

button {
    -webkit-tap-highlight-color: transparent;
}

img {
    max-width: 100%;
}

.hidden {
    display: none !important;
}

/* =========================================================
   HEADER
   ========================================================= */

.app-header {
    position: fixed;
    z-index: 100;
    top: 0;
    left: 0;
    right: 0;
    height: var(--header);
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 0 18px;
    background: rgba(5, 7, 13, .92);
    border-bottom: 1px solid var(--line);
    backdrop-filter: blur(18px);
    -webkit-backdrop-filter: blur(18px);
}

.app-brand {
    display: flex;
    align-items: center;
    gap: 11px;
    min-width: 0;
}

.app-brand img,
.brand-fallback {
    width: 44px;
    height: 44px;
    border-radius: 15px;
    object-fit: contain;
    background: linear-gradient(135deg, var(--red), #7f1d1d);
    display: grid;
    place-items: center;
    font-weight: 950;
    color: #fff;
    flex: 0 0 auto;
}

.app-brand strong {
    font-size: 16px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 210px;
}

.menu-toggle {
    display: none;
    width: 44px;
    height: 44px;
    border: 1px solid var(--line);
    border-radius: 15px;
    background: rgba(255,255,255,.06);
    padding: 0;
    place-items: center;
    cursor: pointer;
    color: #fff;
}

.menu-toggle span {
    display: block;
    width: 19px;
    height: 2px;
    background: #fff;
    border-radius: 99px;
    margin: 3px auto;
}

.app-nav {
    margin-left: auto;
    display: flex;
    align-items: center;
    gap: 6px;
    min-width: 0;
    overflow-x: auto;
    scrollbar-width: none;
}

.app-nav::-webkit-scrollbar {
    display: none;
}

.app-nav a {
    flex: 0 0 auto;
    padding: 10px 13px;
    border-radius: 999px;
    color: rgba(255,255,255,.74);
    font-size: 13px;
    font-weight: 850;
    outline: none;
}

.app-nav a:hover,
.app-nav a:focus,
.app-nav a.active {
    color: #fff;
    background: rgba(255,255,255,.09);
}

.header-actions {
    display: flex;
    align-items: center;
    gap: 8px;
}

.notify-btn {
    position: relative;
    width: 44px;
    height: 44px;
    border: 1px solid var(--line);
    border-radius: 15px;
    background: rgba(255,255,255,.065);
    color: #fff;
    cursor: pointer;
}

.notify-btn:hover,
.notify-btn:focus {
    background: rgba(255,255,255,.10);
}

.notify-count {
    position: absolute;
    right: 5px;
    top: 4px;
    min-width: 18px;
    height: 18px;
    padding: 0 5px;
    border-radius: 999px;
    background: var(--red);
    display: grid;
    place-items: center;
    font-size: 11px;
    font-weight: 950;
}

/* =========================================================
   MAIN / HERO
   ========================================================= */

.app-main {
    min-height: 100vh;
    padding: calc(var(--header) + 18px) 18px 42px;
    background:
        radial-gradient(circle at 10% 0, rgba(229,9,20,.15), transparent 320px),
        radial-gradient(circle at 88% 10%, rgba(59,130,246,.13), transparent 360px),
        linear-gradient(180deg, rgba(255,255,255,.035), transparent 260px),
        var(--bg);
}

.hero {
    position: relative;
    overflow: hidden;
    border: 1px solid var(--line);
    border-radius: 30px;
    background:
        linear-gradient(135deg, rgba(255,255,255,.085), rgba(255,255,255,.028)),
        #080d18;
    box-shadow: 0 28px 90px rgba(0,0,0,.34);
    padding: 34px;
    display: grid;
    grid-template-columns: minmax(0, 1.3fr) minmax(300px, .7fr);
    gap: 24px;
    align-items: end;
}

.hero::before {
    content: "";
    position: absolute;
    inset: 0;
    background: repeating-linear-gradient(
        135deg,
        rgba(255,255,255,.026) 0,
        rgba(255,255,255,.026) 1px,
        transparent 1px,
        transparent 13px
    );
    opacity: .5;
    pointer-events: none;
}

.hero-content,
.hero-card {
    position: relative;
    z-index: 1;
}

.kicker {
    display: inline-flex;
    align-items: center;
    gap: 9px;
    color: #fff;
    text-transform: uppercase;
    letter-spacing: .13em;
    font-weight: 950;
    font-size: 11px;
}

.kicker i {
    width: 8px;
    height: 8px;
    border-radius: 999px;
    background: var(--red);
    box-shadow: 0 0 0 6px rgba(229,9,20,.13);
}

.hero h1 {
    margin: 14px 0 10px;
    font-size: clamp(36px, 6vw, 76px);
    line-height: .94;
    letter-spacing: -.065em;
}

.hero p {
    margin: 0;
    max-width: 720px;
    color: var(--muted);
    font-size: 16px;
    line-height: 1.7;
}

.hero-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 24px;
}

.hero-btn {
    min-height: 46px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0 18px;
    border-radius: 14px;
    background: rgba(255,255,255,.08);
    border: 1px solid var(--line);
    font-weight: 900;
}

.hero-btn:hover,
.hero-btn:focus {
    background: rgba(255,255,255,.12);
}

.hero-btn.primary {
    background: linear-gradient(180deg, var(--red2), var(--red));
    border-color: var(--red);
    box-shadow: 0 18px 42px rgba(229,9,20,.22);
}

.hero-card {
    padding: 18px;
    border: 1px solid var(--line);
    border-radius: 22px;
    background: rgba(0,0,0,.24);
}

.hero-card.compact {
    align-self: center;
}

.search-box {
    height: 54px;
    border: 1px solid var(--line);
    border-radius: 16px;
    background: rgba(0,0,0,.28);
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 0 14px;
}

.search-box span {
    font-size: 20px;
    color: var(--muted);
}

.search-box input {
    width: 100%;
    border: 0;
    outline: 0;
    background: transparent;
    color: #fff;
}

.search-box input::placeholder {
    color: var(--muted2);
}

.hero-stats {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
    margin-top: 14px;
}

.hero-stats div {
    padding: 13px;
    border: 1px solid var(--line);
    border-radius: 16px;
    background: rgba(255,255,255,.045);
}

.hero-stats b {
    display: block;
    font-size: 28px;
    letter-spacing: -.05em;
}

.hero-stats span {
    color: var(--muted);
    font-size: 12px;
    font-weight: 800;
}

/* =========================================================
   SECTIONS / RAILS
   ========================================================= */

.content-section {
    margin-top: 34px;
}

.section-head {
    display: flex;
    align-items: end;
    justify-content: space-between;
    gap: 14px;
    margin-bottom: 13px;
}

.section-head span {
    display: block;
    color: var(--muted2);
    text-transform: uppercase;
    letter-spacing: .12em;
    font-size: 11px;
    font-weight: 950;
}

.section-head h2 {
    margin: 6px 0 0;
    font-size: clamp(23px, 3vw, 34px);
    line-height: 1;
    letter-spacing: -.04em;
}

.section-head a {
    flex: 0 0 auto;
    padding: 9px 13px;
    border-radius: 999px;
    background: rgba(255,255,255,.06);
    border: 1px solid var(--line);
    font-size: 13px;
    font-weight: 850;
}

.section-head a:hover,
.section-head a:focus {
    background: rgba(255,255,255,.10);
}

.rail {
    display: grid;
    grid-auto-flow: column;
    grid-auto-columns: 180px;
    gap: 12px;
    overflow-x: auto;
    overflow-y: hidden;
    padding: 3px 3px 16px;
    scroll-snap-type: x proximity;
    scrollbar-width: thin;
    scrollbar-color: rgba(255,255,255,.22) transparent;
}

.rail::-webkit-scrollbar {
    height: 8px;
}

.rail::-webkit-scrollbar-thumb {
    background: rgba(255,255,255,.18);
    border-radius: 99px;
}

.rail > article {
    scroll-snap-align: start;
}

.channel-rail,
.radio-rail {
    grid-auto-columns: 180px;
}

.match-rail {
    grid-auto-columns: 340px;
}

/* =========================================================
   CARDS
   ========================================================= */

.channel-card,
.radio-card,
.match-card {
    position: relative;
    overflow: hidden;
    border: 1px solid var(--line);
    border-radius: 20px;
    background: linear-gradient(180deg, rgba(255,255,255,.07), rgba(255,255,255,.032));
    cursor: pointer;
    outline: none;
    transition:
        transform .16s ease,
        border-color .16s ease,
        box-shadow .16s ease,
        background .16s ease;
}

.channel-card:hover,
.channel-card:focus,
.radio-card:hover,
.radio-card:focus,
.match-card:hover,
.match-card:focus {
    transform: translateY(-3px);
    border-color: rgba(229,9,20,.62);
    box-shadow: 0 18px 45px rgba(0,0,0,.34);
    background: linear-gradient(180deg, rgba(255,255,255,.105), rgba(255,255,255,.04));
}

.channel-card:focus-visible,
.radio-card:focus-visible,
.match-card:focus-visible {
    outline: 3px solid rgba(229,9,20,.76);
    outline-offset: 3px;
}

.channel-card {
    height: 168px;
    padding: 13px;
}

.live-chip {
    position: absolute;
    right: 10px;
    top: 10px;
    z-index: 2;
    padding: 4px 7px;
    border-radius: 999px;
    background: var(--red);
    font-size: 10px;
    font-weight: 950;
}

.logo-box {
    height: 105px;
    border: 1px solid rgba(255,255,255,.075);
    border-radius: 15px;
    background: rgba(0,0,0,.25);
    display: grid;
    place-items: center;
}

.logo-box img {
    max-width: 84%;
    max-height: 75px;
    object-fit: contain;
}

.logo-box b {
    font-size: 32px;
}

.channel-card h3,
.radio-card h3 {
    margin: 10px 2px 0;
    font-size: 14px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.match-card {
    height: 240px;
    background: #101622;
}

.match-media {
    position: relative;
    height: 118px;
    display: grid;
    place-items: center;
    background:
        linear-gradient(135deg, rgba(229,9,20,.18), rgba(59,130,246,.08)),
        rgba(0,0,0,.22);
}

.match-media > img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.teams {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 24px;
}

.teams img {
    width: 58px;
    height: 58px;
    object-fit: contain;
}

.teams b {
    font-size: 15px;
}

.status-chip {
    position: absolute;
    left: 12px;
    top: 12px;
    padding: 6px 9px;
    border-radius: 999px;
    background: rgba(0,0,0,.55);
    border: 1px solid rgba(255,255,255,.12);
    font-size: 10px;
    font-weight: 950;
    letter-spacing: .07em;
}

.status-live .status-chip {
    background: var(--red);
    border-color: var(--red);
    animation: pulse 1.25s infinite;
}

.match-body {
    padding: 13px 14px;
}

.match-body h3 {
    margin: 0 0 6px;
    font-size: 18px;
    line-height: 1.15;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.match-body p {
    margin: 0;
    color: var(--muted);
    font-size: 13px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.match-footer {
    margin-top: 13px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
}

.match-footer span {
    font-weight: 900;
}

.match-footer button {
    height: 34px;
    border: 0;
    border-radius: 11px;
    background: var(--red);
    color: #fff;
    padding: 0 12px;
    font-weight: 950;
    cursor: pointer;
}

.radio-card {
    height: 166px;
    padding: 13px;
}

.radio-logo-box {
    width: 66px;
    height: 66px;
    border-radius: 18px;
    background: rgba(0,0,0,.25);
    border: 1px solid rgba(255,255,255,.075);
    display: grid;
    place-items: center;
}

.radio-logo-box img {
    max-width: 82%;
    max-height: 50px;
    object-fit: contain;
}

.radio-logo-box b {
    font-size: 26px;
}

.radio-card p {
    margin: 5px 0 0;
    color: var(--muted);
    font-size: 12px;
    line-height: 1.35;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.eq-mini {
    position: absolute;
    right: 13px;
    top: 18px;
    display: flex;
    align-items: end;
    gap: 3px;
    height: 18px;
}

.eq-mini i {
    width: 3px;
    border-radius: 99px;
    background: var(--red);
    animation: eq 1s ease-in-out infinite;
}

.eq-mini i:nth-child(1) {
    height: 8px;
}

.eq-mini i:nth-child(2) {
    height: 14px;
    animation-delay: .15s;
}

.eq-mini i:nth-child(3) {
    height: 10px;
    animation-delay: .3s;
}

/* =========================================================
   CATEGORY / PAGE / ADS / FOOTER
   ========================================================= */

.grid-list {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(170px, 1fr));
    gap: 14px;
    margin-top: 22px;
}

.grid-list .channel-card,
.grid-list .radio-card {
    height: 170px;
}

.match-grid {
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
}

.grid-list .match-card {
    height: 240px;
}

.content-page {
    max-width: 1000px;
    margin: 24px auto 0;
    padding: 26px;
    border: 1px solid var(--line);
    border-radius: 24px;
    background: rgba(255,255,255,.055);
    color: rgba(255,255,255,.86);
    line-height: 1.75;
}

.content-page h1,
.content-page h2,
.content-page h3 {
    color: #fff;
    line-height: 1.2;
}

.empty-state {
    margin-top: 24px;
    padding: 24px;
    border: 1px solid var(--line);
    border-radius: 22px;
    background: rgba(255,255,255,.045);
    text-align: center;
}

.empty-state p {
    color: var(--muted);
}

.ad-slot {
    margin: 18px 0;
    padding: 12px;
    border: 1px dashed rgba(255,255,255,.16);
    border-radius: 18px;
    background: rgba(255,255,255,.035);
    overflow: hidden;
}

.ad-slot > span {
    display: block;
    color: var(--muted2);
    font-size: 11px;
    text-transform: uppercase;
    font-weight: 900;
    letter-spacing: .12em;
    margin-bottom: 8px;
}

.ad-slot-inner {
    display: grid;
    place-items: center;
    min-height: 90px;
}

.site-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    flex-wrap: wrap;
    padding: 26px 20px;
    border-top: 1px solid var(--line);
    background: #05070d;
    color: var(--muted);
}

.footer-links {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}

.footer-links a {
    font-size: 13px;
    color: rgba(255,255,255,.72);
    padding: 7px 10px;
    border-radius: 999px;
    background: rgba(255,255,255,.045);
}

/* =========================================================
   NOTIFICATION
   ========================================================= */

.notify-backdrop {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,.58);
    z-index: 180;
}

.notify-backdrop.open {
    display: block;
}

.notify-popup {
    display: none;
    position: fixed;
    z-index: 181;
    right: 18px;
    top: calc(var(--header) + 14px);
    width: min(420px, calc(100vw - 28px));
    max-height: 75vh;
    overflow: auto;
    border: 1px solid var(--line2);
    border-radius: 22px;
    background: #0b1020;
    box-shadow: 0 28px 90px rgba(0,0,0,.55);
}

.notify-popup.open {
    display: block;
}

.notify-popup-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px 18px;
    border-bottom: 1px solid var(--line);
}

.notify-popup-head h2 {
    margin: 0;
    font-size: 19px;
}

.notify-popup-head button,
.radio-close,
.player-close {
    width: 42px;
    height: 42px;
    border: 0;
    border-radius: 14px;
    background: rgba(255,255,255,.08);
    color: #fff;
    font-size: 24px;
    cursor: pointer;
}

.notify-popup-body {
    padding: 18px;
    color: rgba(255,255,255,.84);
    line-height: 1.6;
}

/* =========================================================
   PLAYER
   ========================================================= */

.player-overlay {
    display: none;
    position: fixed;
    inset: 0;
    z-index: 300;
    width: 100vw;
    height: 100vh;
    height: 100svh;
    height: 100dvh;
    min-height: 100vh;
    min-height: 100svh;
    min-height: 100dvh;
    max-height: 100dvh;
    background: #000;
    padding: 14px;
    overflow: hidden;
    overscroll-behavior: none;
    touch-action: none;
}

.player-overlay.open {
    display: block;
}

.player-shell {
    width: 100%;
    height: calc(100vh - 28px);
    height: calc(100svh - 28px);
    height: calc(100dvh - 28px);
    max-height: calc(100dvh - 28px);
    min-height: 0;
    display: grid;
    grid-template-rows: auto minmax(0, 1fr) auto auto;
    gap: 10px;
    max-width: 1680px;
    margin: 0 auto;
    background: #000;
    overflow: hidden;
}

.player-topbar,
.player-commandbar {
    position: relative;
    z-index: 80;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    padding: 10px 12px;
    border: 1px solid rgba(255,255,255,.12);
    border-radius: 18px;
    background: #090d14;
    flex: 0 0 auto;
}

.player-title-box {
    display: flex;
    align-items: center;
    gap: 11px;
    min-width: 0;
}

.player-title-box img {
    width: 42px;
    height: 42px;
    object-fit: contain;
    border-radius: 12px;
    background: #111;
    flex: 0 0 auto;
}

.player-title-box span {
    display: block;
    color: var(--muted2);
    font-size: 11px;
    text-transform: uppercase;
    font-weight: 950;
    letter-spacing: .1em;
}

.player-title-box strong {
    display: block;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.player-actions,
.player-commandbar {
    flex-wrap: wrap;
}

.player-actions button,
.player-commandbar button {
    min-height: 42px;
    border: 1px solid rgba(255,255,255,.12);
    border-radius: 14px;
    background: rgba(255,255,255,.08);
    color: #fff;
    padding: 0 14px;
    font-weight: 900;
    cursor: pointer;
}

.player-actions button:hover,
.player-commandbar button:hover,
.player-actions button:focus,
.player-commandbar button:focus {
    background: rgba(255,255,255,.13);
    outline: 2px solid rgba(255,255,255,.22);
}

.player-close {
    background: var(--red) !important;
}

.player-stage {
    position: relative;
    min-height: 0;
    height: 100%;
    width: 100%;
    border-radius: 18px;
    overflow: hidden;
    background: #000;
    border: 1px solid rgba(255,255,255,.10);
    contain: layout size;
}

/* Video.js layer */
.player-stage .video-js,
.player-stage .video-js.vjs-fill,
.player-stage .video-js.vjs-fluid {
    position: absolute !important;
    inset: 0 !important;
    z-index: 10 !important;
    display: block;
    width: 100% !important;
    height: 100% !important;
    min-width: 100% !important;
    min-height: 100% !important;
    max-width: 100% !important;
    max-height: 100% !important;
    padding-top: 0 !important;
    background: #000 !important;
}

.player-stage .video-js .vjs-tech,
.player-stage video {
    width: 100% !important;
    height: 100% !important;
    object-fit: contain !important;
    background: #000 !important;
}

.player-stage .vjs-control-bar {
    z-index: 25 !important;
}

.player-stage .vjs-big-play-button {
    z-index: 26 !important;
}

/* Critical hidden state for iframe-only channels */
.player-stage .video-js.is-hidden-player,
.player-stage .is-hidden-player,
.player-stage .video-js.is-hidden-player *,
.player-stage .video-js[style*="display: none"],
.player-stage .video-js[style*="visibility: hidden"] {
    display: none !important;
    visibility: hidden !important;
    opacity: 0 !important;
    pointer-events: none !important;
    z-index: -1 !important;
}

/* Iframe layer */
.iframe-holder {
    display: none;
    position: absolute;
    inset: 0;
    z-index: 60;
    overflow: hidden;
    width: 100% !important;
    height: 100% !important;
    min-width: 100% !important;
    min-height: 100% !important;
    max-width: 100% !important;
    max-height: 100% !important;
    background: #000 !important;
}

.iframe-holder iframe {
    display: block !important;
    width: 100% !important;
    height: 100% !important;
    min-width: 100% !important;
    min-height: 100% !important;
    max-width: 100% !important;
    max-height: 100% !important;
    border: 0 !important;
    background: #000 !important;
}

.player-error {
    display: none;
    position: absolute;
    left: 50%;
    top: 50%;
    transform: translate(-50%, -50%);
    max-width: min(680px, 90%);
    padding: 18px 20px;
    border-radius: 18px;
    background: rgba(127,29,29,.94);
    color: #fff;
    text-align: center;
    font-weight: 800;
    z-index: 90;
}

.loader {
    display: none;
    position: absolute;
    left: 50%;
    top: 50%;
    width: 54px;
    height: 54px;
    margin: -27px 0 0 -27px;
    border-radius: 50%;
    border: 4px solid rgba(255,255,255,.25);
    border-top-color: #fff;
    animation: spin 1s linear infinite;
    z-index: 95;
}

.player-help {
    color: var(--muted2);
    font-size: 12px;
    font-weight: 800;
    margin-left: auto;
}

/* =========================================================
   RADIO PLAYER
   ========================================================= */

.radio-overlay {
    display: none;
    position: fixed;
    inset: 0;
    z-index: 280;
    width: 100vw;
    height: 100vh;
    height: 100dvh;
    background: #000;
    padding: 16px;
    place-items: center;
    overflow: hidden;
}

.radio-overlay.open {
    display: grid;
}

.radio-panel {
    width: min(440px, 100%);
    position: relative;
    text-align: center;
    padding: 28px;
    border: 1px solid var(--line2);
    border-radius: 28px;
    background: #0b1020;
    box-shadow: 0 28px 90px rgba(0,0,0,.5);
}

.radio-close {
    position: absolute;
    right: 14px;
    top: 14px;
}

.radio-panel img {
    width: 96px;
    height: 96px;
    object-fit: contain;
    border-radius: 24px;
    background: #05070d;
    margin: 0 auto 12px;
}

.radio-panel h3 {
    margin: 8px 0 4px;
}

.radio-panel p {
    margin: 0;
    color: var(--muted);
}

.radio-panel audio {
    width: 100%;
    margin-top: 16px;
}

.eq {
    display: flex;
    justify-content: center;
    align-items: end;
    gap: 4px;
    height: 34px;
    margin: 14px 0;
    opacity: .35;
}

.eq span {
    width: 5px;
    background: var(--red);
    border-radius: 99px;
    animation: eq 1s ease-in-out infinite;
}

.eq span:nth-child(1) {
    height: 12px;
}

.eq span:nth-child(2) {
    height: 23px;
    animation-delay: .12s;
}

.eq span:nth-child(3) {
    height: 16px;
    animation-delay: .24s;
}

.eq span:nth-child(4) {
    height: 25px;
    animation-delay: .36s;
}

/* =========================================================
   ANIMATIONS
   ========================================================= */

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

@keyframes eq {
    0%, 100% {
        transform: scaleY(.55);
    }

    50% {
        transform: scaleY(1.18);
    }
}

@keyframes pulse {
    0%, 100% {
        box-shadow: 0 0 0 0 rgba(229,9,20,.38);
    }

    50% {
        box-shadow: 0 0 0 8px rgba(229,9,20,0);
    }
}

/* =========================================================
   LARGE SCREENS
   ========================================================= */

@media (min-width: 1500px) {
    .app-main {
        padding-left: 34px;
        padding-right: 34px;
    }

    .channel-rail,
    .radio-rail {
        grid-auto-columns: 205px;
    }

    .match-rail {
        grid-auto-columns: 390px;
    }

    .channel-card {
        height: 190px;
    }

    .logo-box {
        height: 124px;
    }

    .radio-card {
        height: 180px;
    }

    .match-card {
        height: 260px;
    }

    .match-media {
        height: 130px;
    }
}

/* =========================================================
   TABLET
   ========================================================= */

@media (max-width: 980px) {
    .menu-toggle {
        display: grid;
    }

    .app-nav {
        position: fixed;
        top: var(--header);
        left: 12px;
        right: 12px;
        display: none;
        flex-direction: column;
        align-items: stretch;
        padding: 12px;
        border: 1px solid var(--line);
        border-radius: 20px;
        background: #060910;
        box-shadow: 0 24px 70px rgba(0,0,0,.5);
        overflow: visible;
    }

    .app-nav.open {
        display: flex;
    }

    .app-nav a {
        padding: 13px;
    }

    .app-main {
        padding: calc(var(--header) + 14px) 12px 32px;
    }

    .hero,
    .category-main .hero {
        grid-template-columns: 1fr;
        padding: 21px;
        border-radius: 24px;
    }

    .channel-rail,
    .radio-rail {
        grid-auto-columns: 154px;
    }

    .match-rail {
        grid-auto-columns: 285px;
    }

    .channel-card {
        height: 150px;
    }

    .logo-box {
        height: 90px;
    }

    .radio-card {
        height: 152px;
    }

    .match-card {
        height: 218px;
    }

    .match-media {
        height: 102px;
    }

    .grid-list {
        grid-template-columns: repeat(auto-fill, minmax(148px, 1fr));
    }

    .match-grid {
        grid-template-columns: repeat(auto-fill, minmax(270px, 1fr));
    }

    .player-overlay {
        padding: 8px;
    }

    .player-shell {
        height: calc(100vh - 16px);
        height: calc(100svh - 16px);
        height: calc(100dvh - 16px);
        max-height: calc(100dvh - 16px);
    }

    .player-topbar {
        align-items: flex-start;
        flex-direction: column;
    }

    .player-actions {
        width: 100%;
        display: grid;
        grid-template-columns: 1fr 1fr 46px;
    }

    .player-actions button {
        padding: 0 8px;
    }

    .player-commandbar {
        justify-content: stretch;
    }

    .player-commandbar button {
        flex: 1;
    }

    .player-help {
        width: 100%;
        text-align: center;
        margin-left: 0;
    }
}

/* =========================================================
   MOBILE
   ========================================================= */

@media (max-width: 560px) {
    :root {
        --header: 68px;
    }

    .app-header {
        padding: 0 10px;
        gap: 8px;
    }

    .app-brand img,
    .brand-fallback {
        width: 40px;
        height: 40px;
        border-radius: 13px;
    }

    .app-brand strong {
        display: none;
    }

    .menu-toggle,
    .notify-btn {
        width: 40px;
        height: 40px;
        border-radius: 13px;
    }

    .app-main {
        padding-left: 9px;
        padding-right: 9px;
    }

    .hero {
        padding: 18px;
        border-radius: 22px;
    }

    .hero h1 {
        font-size: 34px;
    }

    .hero p {
        font-size: 13px;
    }

    .hero-card {
        padding: 13px;
    }

    .hero-stats {
        grid-template-columns: 1fr 1fr 1fr;
    }

    .hero-stats b {
        font-size: 22px;
    }

    .content-section {
        margin-top: 28px;
    }

    .section-head h2 {
        font-size: 22px;
    }

    .section-head a {
        font-size: 12px;
        padding: 7px 10px;
    }

    .channel-rail,
    .radio-rail {
        grid-auto-columns: 138px;
    }

    .match-rail {
        grid-auto-columns: 260px;
    }

    .channel-card {
        height: 140px;
        padding: 10px;
        border-radius: 16px;
    }

    .logo-box {
        height: 82px;
        border-radius: 13px;
    }

    .logo-box img {
        max-height: 57px;
    }

    .channel-card h3,
    .radio-card h3 {
        font-size: 12.5px;
    }

    .radio-card {
        height: 144px;
        padding: 10px;
    }

    .radio-logo-box {
        width: 58px;
        height: 58px;
        border-radius: 15px;
    }

    .match-card {
        height: 210px;
    }

    .match-body h3 {
        font-size: 15px;
    }

    .notify-popup {
        right: 10px;
        left: 10px;
        width: auto;
        top: calc(var(--header) + 10px);
    }

    .player-overlay.open {
        position: fixed !important;
        inset: 0 !important;
        width: 100vw !important;
        height: 100vh !important;
        height: 100svh !important;
        height: 100dvh !important;
        min-height: 100svh !important;
        min-height: 100dvh !important;
        max-height: 100dvh !important;
        padding: 6px !important;
        background: #000 !important;
        overflow: hidden !important;
        overscroll-behavior: none !important;
        touch-action: none !important;
    }

    .player-shell {
        width: 100% !important;
        height: calc(100vh - 12px) !important;
        height: calc(100svh - 12px) !important;
        height: calc(100dvh - 12px) !important;
        min-height: calc(100svh - 12px) !important;
        max-height: calc(100dvh - 12px) !important;
        overflow: hidden !important;
        display: grid !important;
        grid-template-rows: auto minmax(0, 1fr) auto auto !important;
        gap: 7px !important;
        padding:
            env(safe-area-inset-top)
            env(safe-area-inset-right)
            env(safe-area-inset-bottom)
            env(safe-area-inset-left) !important;
    }

    .player-topbar,
    .player-commandbar {
        border-radius: 14px;
        padding: 8px;
        flex: 0 0 auto !important;
    }

    .player-title-box img {
        width: 34px;
        height: 34px;
    }

    .player-title-box span {
        font-size: 9px;
    }

    .player-title-box strong {
        font-size: 13px;
    }

    .player-actions button:not(.player-close),
    .player-commandbar button {
        font-size: 12px;
        padding: 0 8px;
        min-height: 38px;
    }

    .player-close {
        width: 38px;
        height: 38px;
        border-radius: 12px;
    }

    .player-stage {
        min-height: 0 !important;
        height: 100% !important;
        width: 100% !important;
        border-radius: 14px;
        overflow: hidden !important;
        background: #000 !important;
        contain: strict !important;
    }

    .player-stage .video-js,
    .player-stage .video-js.vjs-fill,
    .player-stage .video-js.vjs-fluid,
    .player-stage .video-js .vjs-tech,
    .player-stage video,
    .iframe-holder,
    .iframe-holder iframe {
        width: 100% !important;
        height: 100% !important;
        min-width: 100% !important;
        min-height: 100% !important;
        max-width: 100% !important;
        max-height: 100% !important;
        background: #000 !important;
        object-fit: contain !important;
    }

    .iframe-holder {
        position: absolute !important;
        inset: 0 !important;
        overflow: hidden !important;
    }

    .player-help {
        font-size: 10px;
    }

    .radio-overlay {
        padding: 10px;
    }

    .radio-panel {
        padding: 24px 18px;
        border-radius: 24px;
    }
}

/* =========================================================
   FINAL VIDEO.JS / IFRAME / LOADER / RADIO FIX
   MUST STAY AT THE VERY END
   ========================================================= */

/*
   Player stage must always keep proper height.
*/
.player-overlay.open .player-stage {
    min-height: 260px !important;
}

/*
   Video.js and iframe must always fill the stage.
*/
.player-overlay.open .video-js,
.player-overlay.open .video-js.vjs-fill,
.player-overlay.open .video-js.vjs-fluid,
.player-overlay.open .video-js .vjs-tech,
.player-overlay.open video,
.player-overlay.open .iframe-holder,
.player-overlay.open .iframe-holder iframe {
    width: 100% !important;
    height: 100% !important;
}

.player-overlay.open .video-js.vjs-fluid {
    padding-top: 0 !important;
}

/*
   Do NOT force user-active/user-inactive to min-height in a way
   that keeps controls visible. Only size the player itself.
*/
.player-overlay.open .video-js.vjs-has-started {
    min-height: 100% !important;
}

/* =========================================================
   VIDEO.JS HIDE FOR IFRAME-ONLY CHANNELS
   ========================================================= */

.player-overlay.open .video-js.is-hidden-player,
.player-overlay.open .video-js.is-hidden-player *,
.player-overlay.open .is-hidden-player,
.player-stage .video-js.is-hidden-player,
.player-stage .video-js.is-hidden-player *,
.player-stage .is-hidden-player,
.player-stage .video-js[style*="visibility: hidden"],
.player-stage .video-js[style*="display: none"] {
    display: none !important;
    visibility: hidden !important;
    opacity: 0 !important;
    pointer-events: none !important;
    z-index: -1 !important;
}

/* =========================================================
   IFRAME LAYER
   ========================================================= */

.iframe-holder {
    position: absolute !important;
    inset: 0 !important;
    display: none;
    z-index: 60;
    width: 100% !important;
    height: 100% !important;
    min-width: 100% !important;
    min-height: 100% !important;
    max-width: 100% !important;
    max-height: 100% !important;
    overflow: hidden !important;
    background: #000 !important;
}

.iframe-holder iframe {
    display: block !important;
    width: 100% !important;
    height: 100% !important;
    min-width: 100% !important;
    min-height: 100% !important;
    max-width: 100% !important;
    max-height: 100% !important;
    border: 0 !important;
    background: #000 !important;
}

.player-overlay.open .iframe-holder[style*="display: block"] {
    display: block !important;
    visibility: visible !important;
    opacity: 1 !important;
    pointer-events: auto !important;
    z-index: 999 !important;
}

/* =========================================================
   LOADER FIX
   ========================================================= */

/*
   Your custom loader must never appear above Video.js.
   Video.js already has its own spinner.
*/
.player-stage .video-js:not(.is-hidden-player) ~ .loader,
.player-overlay.open .player-stage .video-js:not(.is-hidden-player) ~ .loader {
    display: none !important;
}

/*
   If iframe is active, custom loader should also stay hidden after iframe loads.
*/
.player-overlay.open .iframe-holder[style*="display: block"] ~ .loader {
    display: none !important;
}

/*
   Clean Video.js spinner.
*/
.player-stage .video-js .vjs-loading-spinner {
    width: 52px !important;
    height: 52px !important;
    margin-left: -26px !important;
    margin-top: -26px !important;
    border-width: 4px !important;
}

/*
   Hide big play button after stream starts.
*/
.player-stage .video-js.vjs-has-started .vjs-big-play-button {
    display: none !important;
}

/* =========================================================
   VIDEO.JS CONTROL BAR AUTO-HIDE
   ========================================================= */

/*
   Hide control bar when Video.js becomes inactive.
*/
.player-stage .video-js.vjs-user-inactive .vjs-control-bar {
    opacity: 0 !important;
    visibility: hidden !important;
    pointer-events: none !important;
    transform: translateY(100%) !important;
    transition:
        opacity .22s ease,
        visibility .22s ease,
        transform .22s ease !important;
}

/*
   Show control bar when active, focused, hovered, paused, or not started.
*/
.player-stage .video-js.vjs-user-active .vjs-control-bar,
.player-stage .video-js:hover .vjs-control-bar,
.player-stage .video-js:focus-within .vjs-control-bar,
.player-stage .video-js.vjs-paused .vjs-control-bar,
.player-stage .video-js:not(.vjs-has-started) .vjs-control-bar {
    opacity: 1 !important;
    visibility: visible !important;
    pointer-events: auto !important;
    transform: translateY(0) !important;
}

/*
   Keep player top bar/buttons visible.
   These are your own Previous / Next / Close buttons, not Video.js controls.
*/
.player-topbar,
.player-actions,
.player-actions button {
    z-index: 1000 !important;
}

/*
   Prevent Video.js from covering your top bar.
*/
.player-stage .video-js {
    z-index: 10 !important;
}

/* =========================================================
   RADIO PREVIOUS / NEXT BUTTONS
   ========================================================= */

.radio-actions {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    margin: 12px 0 14px;
}

.radio-actions button {
    min-height: 40px;
    padding: 0 14px;
    border: 1px solid rgba(255,255,255,.14);
    border-radius: 14px;
    background: rgba(255,255,255,.08);
    color: #fff;
    font-weight: 900;
    cursor: pointer;
}

.radio-actions button:hover,
.radio-actions button:focus {
    background: rgba(255,255,255,.14);
    outline: 2px solid rgba(255,255,255,.22);
}

/*
   Allow horizontal swipe for radio navigation,
   but still allow normal touch interaction inside audio controls.
*/
.radio-overlay {
    touch-action: pan-y;
}

.radio-panel {
    touch-action: manipulation;
}

/* =========================================================
   MOBILE PLAYER FIXES
   ========================================================= */

@media (max-width: 560px) {
    .player-overlay.open .player-stage {
        min-height: 240px !important;
    }

    .player-overlay.open .video-js,
    .player-overlay.open .video-js.vjs-fill,
    .player-overlay.open .video-js.vjs-fluid,
    .player-overlay.open .video-js .vjs-tech,
    .player-overlay.open video,
    .player-overlay.open .iframe-holder,
    .player-overlay.open .iframe-holder iframe {
        position: absolute !important;
        inset: 0 !important;
        width: 100% !important;
        height: 100% !important;
        min-height: 100% !important;
        max-height: 100% !important;
    }

    .player-stage .video-js.vjs-user-inactive .vjs-control-bar {
        opacity: 0 !important;
        visibility: hidden !important;
        pointer-events: none !important;
        transform: translateY(100%) !important;
    }

    .player-stage .video-js.vjs-user-active .vjs-control-bar,
    .player-stage .video-js:hover .vjs-control-bar,
    .player-stage .video-js:focus-within .vjs-control-bar,
    .player-stage .video-js.vjs-paused .vjs-control-bar {
        opacity: 1 !important;
        visibility: visible !important;
        pointer-events: auto !important;
        transform: translateY(0) !important;
    }

    .radio-actions {
        gap: 8px;
        margin: 10px 0 12px;
    }

    .radio-actions button {
        min-height: 38px;
        padding: 0 12px;
        font-size: 13px;
        border-radius: 12px;
    }
}