/* ==========================================================================
   assets/desktop.css — Тарҳи профессионалӣ барои компютер ва ноутбук (>= 1024px).
   Версияи телефонӣ ДАСТ НАМЕХӮРАД: ҳамаи қоидаҳои тарҳ танҳо дар дохили
   @media (min-width:1024px) ҳастанд. Берун аз он — танҳо пинҳон кардани
   унсурҳое, ки махсуси компютер мебошанд (.fz-desk-only).
   ========================================================================== */

/* Ҷустуҷӯи app-bar ва унсурҳои компютерӣ дар телефон пинҳонанд */
.app-bar-search, .fz-desk-only { display: none; }

@media (min-width: 1024px) {
    :root {
        --sidebar-w: 268px;
        --content-w: 1120px;
        --d-ink: #0b1610;            /* матни асосӣ */
        --d-ink-2: #4b5b52;          /* матни дуюмдараҷа */
        --d-ink-3: #8a978f;
        --d-line: #e3e9e5;           /* хатҳо */
        --d-bg: #f1f4f2;             /* заминаи саҳифа */
        --d-card: #ffffff;
        --d-night: #07120b;          /* sidebar / торик */
        --d-night-2: #0e2116;
        --d-pitch: #14532d;
        --d-green: #16a34a;
        --d-lime: #4ade80;           /* аксенти дурахшон */
        --d-gold: #fbbf24;
        --d-red: #ef4444;
        --d-r: 18px;
        --d-r-sm: 12px;
        --d-sh-1: 0 1px 2px rgba(11, 22, 16, .04), 0 1px 1px rgba(11, 22, 16, .03);
        --d-sh-2: 0 10px 30px -12px rgba(11, 40, 22, .22), 0 2px 6px rgba(11, 22, 16, .05);
        --d-sh-3: 0 24px 60px -20px rgba(7, 30, 15, .45);
        --d-font: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
        /* Тағйирёбандаҳои кӯҳна — барои ҳамоҳангии саҳифаҳо */
        --primary: #15803d; --secondary: #166534; --primary-light: #22c55e;
        --text: var(--d-ink); --text-light: var(--d-ink-2); --border: var(--d-line);
        --bg: var(--d-bg); --highlight: #ecf7ef; --radius: var(--d-r);
        --shadow: var(--d-sh-1); --shadow-lg: var(--d-sh-2);
        /* Рангҳои мавзӯъ (равшан). Мавзӯи торик онҳоро дар assets/theme.css иваз мекунад */
        --d-soft: #eef2ef; --d-hover: #f6faf7; --d-line-2: #d3ddd6; --d-input: #fbfcfb;
        --d-glass: rgba(241, 244, 242, .82); --d-solid: var(--d-night); --d-solid-hover: var(--d-pitch);
        --d-scroll: #c4cfc8;
        --sb-bg: #ffffff; --sb-head: rgba(255, 255, 255, .92); --sb-edge: 1px 0 0 var(--d-line), 8px 0 30px -18px rgba(11, 40, 22, .18);
        --sb-fg: #3d4b43; --sb-fg-strong: var(--d-ink); --sb-icon: #16a34a; --sb-label: #9aa69f;
        --sb-hover: #f2f6f3; --sb-card: #f4f7f5; --sb-card-line: var(--d-line); --sb-line: var(--d-line);
        --sb-active-bg: linear-gradient(90deg, #e3f5e8, #f1faf3); --sb-active-fg: #14532d; --sb-accent: #16a34a;
        --hero-bg:
            radial-gradient(500px 200px at 85% -30%, rgba(187, 247, 208, .45), transparent 70%),
            radial-gradient(400px 220px at 10% 140%, rgba(74, 222, 128, .35), transparent 70%),
            linear-gradient(120deg, #166534, #15803d 55%, #16a34a);
        --comp-bg: linear-gradient(90deg, #166534, #15803d);
        --ft-bg: #ffffff; --ft-fg: var(--d-ink-2); --ft-strong: var(--d-ink); --ft-line: var(--d-line);
    }

    * { font-family: var(--d-font); }
    html { scroll-padding-top: 96px; }
    body {
        padding-bottom: 0 !important;
        font-size: 14.5px;
        letter-spacing: -.005em;
        color: var(--d-ink);
        background:
            radial-gradient(1200px 420px at 70% -120px, rgba(34, 197, 94, .10), transparent 70%),
            var(--d-bg) !important;
        -webkit-font-smoothing: antialiased;
    }
    body { padding-left: var(--sidebar-w); }
    ::selection { background: rgba(74, 222, 128, .35); }

    /* Scrollbar-и зебо */
    html { scrollbar-width: thin; scrollbar-color: var(--d-scroll) transparent; }
    ::-webkit-scrollbar { width: 10px; height: 10px; }
    ::-webkit-scrollbar-thumb { background: var(--d-scroll); border-radius: 10px; border: 3px solid var(--d-bg); }
    ::-webkit-scrollbar-track { background: transparent; }

    /* ======================================================================
       SIDEBAR — менюи торики доимӣ
       ====================================================================== */
    .nav-drawer {
        left: 0 !important;
        width: var(--sidebar-w) !important;
        max-width: none !important;
        z-index: 600 !important;
        transition: none !important;
        background: var(--sb-bg) !important;
        box-shadow: var(--sb-edge) !important;
        color: var(--sb-fg);
        scrollbar-width: thin; scrollbar-color: var(--sb-line) transparent;
        padding-bottom: 24px;
    }
    .nav-drawer::-webkit-scrollbar { width: 6px; }
    .nav-drawer::-webkit-scrollbar-thumb { background: var(--sb-line); border: none; }
    .nav-drawer .close-drawer { display: none !important; }
    .nav-overlay { display: none !important; }
    #drawerOpenBtn { display: none !important; }
    .bottom-nav { display: none !important; }

    .nav-drawer-header {
        background: transparent !important;
        padding: 22px 18px 14px !important;
        position: sticky; top: 0; z-index: 2;
        backdrop-filter: blur(10px);
        background: var(--sb-head) !important;
    }
    .nav-drawer-logo { font-size: 1.12rem !important; letter-spacing: -.02em; margin-bottom: 18px !important; color: var(--sb-fg-strong); }
    .nav-drawer-logo img {
        width: 40px !important; height: 40px !important; border-radius: 12px !important;
        box-shadow: 0 0 0 1px var(--sb-line), 0 8px 20px -6px rgba(74, 222, 128, .45);
    }
    .nav-drawer-user {
        background: var(--sb-card) !important; color: var(--sb-fg-strong) !important;
        border: 1px solid var(--sb-card-line);
        border-radius: 14px !important; padding: 10px 12px !important;
        transition: background .2s, border-color .2s;
    }
    .nav-drawer-user:hover { background: var(--sb-hover) !important; border-color: rgba(74, 222, 128, .35); }
    .nav-drawer-avatar { background: linear-gradient(135deg, var(--d-lime), var(--d-green)) !important; color: var(--d-night); }
    .nav-drawer-usersub { opacity: .6 !important; }

    .nav-section-label {
        color: var(--sb-label) !important;
        font-size: .66rem !important; letter-spacing: .14em !important;
        padding: 18px 26px 8px !important;
    }
    .nav-drawer-item {
        margin: 1px 12px !important; padding: 9px 14px !important; border-radius: 11px !important;
        color: var(--sb-fg) !important; font-size: .9rem !important; font-weight: 500 !important;
        position: relative; transition: background .18s, color .18s, transform .18s !important;
        gap: 13px !important;
    }
    .nav-drawer-item i { color: var(--sb-icon); font-size: .95rem !important; transition: color .18s, transform .18s; }
    .nav-drawer-item:hover { background: var(--sb-hover) !important; color: var(--sb-fg-strong) !important; }
    .nav-drawer-item:hover i { transform: scale(1.12); }
    .nav-drawer-item.active {
        background: var(--sb-active-bg) !important;
        color: var(--sb-active-fg) !important; font-weight: 650 !important;
    }
    .nav-drawer-item.active::before {
        content: ""; position: absolute; left: -12px; top: 8px; bottom: 8px; width: 4px;
        border-radius: 0 4px 4px 0; background: var(--sb-accent); box-shadow: 0 0 14px var(--sb-accent);
    }
    .nav-drawer-item.active i { color: var(--sb-accent) !important; }
    .nav-drawer-item.danger { color: var(--d-red) !important; }
    .nav-drawer-hr { background: var(--sb-line) !important; margin: 12px 24px !important; }
    .nav-drawer form button.nav-drawer-item { width: calc(100% - 24px) !important; }

    /* ======================================================================
       APP BAR — панели болоии шишагин
       ====================================================================== */
    .app-bar {
        background: var(--d-glass) !important;
        backdrop-filter: saturate(180%) blur(16px);
        -webkit-backdrop-filter: saturate(180%) blur(16px);
        color: var(--d-ink) !important;
        box-shadow: 0 1px 0 rgba(11, 22, 16, .06) !important;
        padding: 14px 36px !important; gap: 24px;
        min-height: 72px;
    }
    .app-bar .app-logo { display: none; }
    .app-bar-left { flex: 0 0 auto; }
    .app-bar-search {
        display: flex; align-items: center; gap: 10px; flex: 1; max-width: 560px;
        background: var(--d-card); border: 1px solid var(--d-line); border-radius: 14px;
        padding: 0 6px 0 16px; height: 46px; box-shadow: var(--d-sh-1);
        transition: border-color .2s, box-shadow .2s;
    }
    .app-bar-search:focus-within { border-color: rgba(22, 163, 74, .55); box-shadow: 0 0 0 4px rgba(34, 197, 94, .14); }
    .app-bar-search i { color: var(--d-ink-3); }
    .app-bar-search input {
        flex: 1; background: transparent; border: none; outline: none; color: var(--d-ink);
        font-size: .93rem; min-width: 0;
    }
    .app-bar-search input::placeholder { color: var(--d-ink-3); }
    .app-bar-search button {
        background: var(--d-solid); border: none; color: #fff; border-radius: 10px; padding: 0 16px; height: 34px;
        font-weight: 650; font-size: .82rem; cursor: pointer; transition: background .2s, transform .15s;
    }
    .app-bar-search button:hover { background: var(--d-solid-hover); }
    .app-bar-search kbd {
        font-family: var(--d-font); font-size: .7rem; color: var(--d-ink-3); border: 1px solid var(--d-line);
        border-radius: 6px; padding: 2px 6px; background: var(--d-bg);
    }
    .app-bar-right { gap: 10px !important; margin-left: auto; }
    .app-bar-right > a[href*="search.php"] { display: none !important; }
    .app-bar-btn {
        background: var(--d-card) !important; color: var(--d-ink) !important; border: 1px solid var(--d-line) !important;
        width: 44px !important; height: 44px !important; border-radius: 13px !important; box-shadow: var(--d-sh-1);
        transition: transform .15s, box-shadow .2s, border-color .2s !important;
    }
    .app-bar-btn:hover { transform: translateY(-1px); box-shadow: var(--d-sh-2); border-color: var(--d-line-2) !important; }
    .app-bar-badge { box-shadow: 0 0 0 2px var(--d-card) !important; top: -4px !important; right: -4px !important; }

    .fz-desk-only { display: revert; }
    .fz-today {
        display: flex; flex-direction: column; line-height: 1.15;
    }
    .fz-today b { font-size: 1.05rem; font-weight: 750; letter-spacing: -.02em; }
    .fz-today span { font-size: .76rem; color: var(--d-ink-3); font-weight: 500; }
    .fz-live-pill {
        display: inline-flex !important; align-items: center; gap: 8px; height: 44px; padding: 0 16px;
        border-radius: 13px; background: var(--d-solid); color: #fff; text-decoration: none;
        font-weight: 700; font-size: .82rem; letter-spacing: .04em;
        box-shadow: 0 10px 24px -10px rgba(239, 68, 68, .6);
        transition: transform .15s;
    }
    .fz-live-pill:hover { transform: translateY(-1px); }
    .fz-live-pill .dot { width: 8px; height: 8px; border-radius: 50%; background: var(--d-red); box-shadow: 0 0 0 0 rgba(239, 68, 68, .7); animation: fzPing 1.6s infinite; }
    @keyframes fzPing { 0% { box-shadow: 0 0 0 0 rgba(239, 68, 68, .65); } 70% { box-shadow: 0 0 0 9px rgba(239, 68, 68, 0); } 100% { box-shadow: 0 0 0 0 rgba(239, 68, 68, 0); } }
    .fz-user-btn {
        display: inline-flex !important; align-items: center; gap: 10px; height: 44px; padding: 0 16px 0 6px;
        border-radius: 13px; background: var(--d-card); border: 1px solid var(--d-line); text-decoration: none;
        color: var(--d-ink); font-weight: 650; font-size: .86rem; box-shadow: var(--d-sh-1);
        transition: transform .15s, box-shadow .2s;
    }
    .fz-user-btn:hover { transform: translateY(-1px); box-shadow: var(--d-sh-2); }
    .fz-user-btn .av {
        width: 32px; height: 32px; border-radius: 10px; overflow: hidden; display: flex; align-items: center; justify-content: center;
        background: linear-gradient(135deg, var(--d-lime), var(--d-green)); color: var(--d-night); font-weight: 800;
    }
    .fz-user-btn .av img { width: 100%; height: 100%; object-fit: cover; }
    .fz-user-btn.guest { background: var(--d-green); color: #fff; border-color: transparent; padding: 0 18px; box-shadow: 0 10px 24px -10px rgba(22, 163, 74, .8); }

    /* ======================================================================
       МУНДАРИҶА — умумӣ
       ====================================================================== */
    .fz-main { max-width: var(--content-w); margin: 0 auto; padding: 28px 36px 56px; min-height: calc(100vh - 72px); }
    .fz-main .container { max-width: none; margin: 0; padding: 0; }

    /* Сарлавҳаи саҳифа → «hero»-и торики стадион */
    .fz-main > .header, body.tv-page .header {
        position: relative !important; top: auto !important; overflow: hidden;
        border-radius: 22px; margin: 0 0 26px; padding: 26px 0 !important;
        background: var(--hero-bg) !important;
        box-shadow: var(--d-sh-3) !important;
        isolation: isolate;
    }
    .fz-main > .header::after, body.tv-page .header::after {
        /* хатҳои майдон */
        content: ""; position: absolute; inset: 0; z-index: -1; pointer-events: none; opacity: .14;
        background:
            radial-gradient(circle at 78% 50%, transparent 58px, rgba(255, 255, 255, .9) 59px, rgba(255, 255, 255, .9) 61px, transparent 62px),
            linear-gradient(90deg, transparent calc(78% - 1px), rgba(255, 255, 255, .9) calc(78% - 1px), rgba(255, 255, 255, .9) calc(78% + 1px), transparent calc(78% + 1px));
    }
    .header-container { padding: 0 28px !important; }
    .header-title { font-size: 1.45rem !important; font-weight: 800 !important; letter-spacing: -.03em; gap: 14px !important; }
    .header-title i {
        width: 44px; height: 44px; border-radius: 13px; display: inline-flex; align-items: center; justify-content: center;
        background: rgba(255, 255, 255, .14); border: 1px solid rgba(255, 255, 255, .2); font-size: 1.05rem; color: #fff;
    }
    .header-btn {
        width: 42px !important; height: 42px !important; border-radius: 12px !important;
        background: rgba(255, 255, 255, .1) !important; border: 1px solid rgba(255, 255, 255, .16) !important;
        transition: background .2s, transform .15s;
    }
    .header-btn:hover { background: rgba(255, 255, 255, .2) !important; transform: translateY(-1px); }
    body.tv-page .header { max-width: 980px; margin: 24px auto 0; }

    .card {
        background: var(--d-card); border: 1px solid var(--d-line); border-radius: var(--d-r) !important;
        padding: 24px; box-shadow: var(--d-sh-1);
    }
    a.card, .news-card, .video-card, .yt-card, .league-row, .match-item, .contact-row, .h2h-match-item, .event-row, .league-item img {
        transition: transform .2s cubic-bezier(.2, .8, .2, 1), box-shadow .2s, background .2s, border-color .2s;
    }
    a.card:hover { transform: translateY(-3px); box-shadow: var(--d-sh-2); border-color: var(--d-line-2); }

    .btn { border-radius: 12px; font-weight: 650; transition: transform .15s, box-shadow .2s, background .2s; }
    .btn:hover { transform: translateY(-1px); }
    .btn-primary { background: linear-gradient(135deg, #16a34a, #15803d) !important; box-shadow: 0 10px 22px -10px rgba(22, 163, 74, .8) !important; }
    .btn-outline { background: var(--d-card) !important; color: var(--d-ink) !important; }
    .btn-outline:hover { border-color: var(--d-line-2); }
    .form-input, .form-textarea, .form-select { border-radius: 12px; border-color: var(--d-line); background: var(--d-input); color: var(--d-ink); }
    .form-input:focus, .form-textarea:focus, .form-select:focus { background: var(--d-card); border-color: #22c55e !important; box-shadow: 0 0 0 4px rgba(34, 197, 94, .14) !important; outline: none; }
    .alert { border-radius: 12px; }
    .badge { letter-spacing: .02em; }
    .empty-state { padding: 60px 20px; }
    .list-item { padding: 16px 18px; }

    /* ======================================================================
       САҲИФАИ АСОСӢ (index.php)
       ====================================================================== */
    body.page-home .fz-main {
        display: grid; grid-template-columns: minmax(0, 1fr) 360px; column-gap: 28px; align-items: start;
        max-width: 1320px;
    }
    body.page-home .fz-main > * { grid-column: 1; min-width: 0; }
    body.page-home .fz-main > .search-section,
    body.page-home .fz-main > .live-matches-banner { display: none; }
    body.page-home .fz-rail {
        display: flex; flex-direction: column; gap: 20px;
        grid-column: 2; grid-row: 1 / span 30;
        position: sticky; top: 96px; max-height: calc(100vh - 116px); overflow-y: auto;
        scrollbar-width: none; padding-bottom: 6px;
    }
    body.page-home .fz-rail::-webkit-scrollbar { display: none; }
    body.page-home .fz-rail > * { flex-shrink: 0; }

    /* Hero — баннер */
    body .fz-main > .banner-slider {
        margin: 0 0 28px; height: auto; aspect-ratio: 16 / 7; border-radius: 24px;
        box-shadow: var(--d-sh-3); background: var(--d-night);
    }
    body .banner-slider .swiper-slide { border-radius: 24px; background: var(--d-night); }
    body .banner-slider .swiper-slide img { transition: transform 6s ease; }
    body .banner-slider .swiper-slide-active img { transform: scale(1.04); }
    body .banner-slider::after {
        content: ""; position: absolute; inset: auto 0 0 0; height: 30%; z-index: 2; pointer-events: none;
        background: linear-gradient(0deg, rgba(7, 18, 11, .55), transparent);
    }
    body .banner-slider .swiper-pagination { bottom: 16px !important; z-index: 5; }
    body .banner-slider .swiper-pagination-bullet { width: 8px; height: 8px; transition: width .3s; border-radius: 8px; }
    body .banner-slider .swiper-pagination-bullet-active { width: 28px; background: var(--d-lime); }
    body .banner-slider .swiper-button-next, body .banner-slider .swiper-button-prev {
        width: 46px; height: 46px; background: rgba(255, 255, 255, .14); backdrop-filter: blur(8px);
        border: 1px solid rgba(255, 255, 255, .22); opacity: 0; transition: opacity .25s, background .2s;
    }
    body .banner-slider:hover .swiper-button-next, body .banner-slider:hover .swiper-button-prev { opacity: 1; }
    body .banner-slider .swiper-button-next:hover, body .banner-slider .swiper-button-prev:hover { background: rgba(255, 255, 255, .28); }

    /* Бахшҳо */
    body .fz-main > .section {
        margin: 0 0 28px; padding: 26px 28px; border-radius: 22px;
        background: var(--d-card); border: 1px solid var(--d-line); box-shadow: var(--d-sh-1);
    }
    body .section-header { margin-bottom: 20px; }
    body .section-title {
        font-size: 1.3rem; font-weight: 800; letter-spacing: -.03em; display: flex; align-items: center; gap: 12px;
    }
    body .section-title::before {
        content: ""; width: 6px; height: 22px; border-radius: 6px;
        background: linear-gradient(180deg, var(--d-lime), var(--d-green));
    }
    body .section-link {
        display: inline-flex; align-items: center; gap: 6px; padding: 8px 14px; border-radius: 10px;
        background: var(--d-bg); color: var(--d-ink) !important; font-size: .82rem; transition: background .2s, color .2s;
    }
    body .section-link::after { content: "→"; transition: transform .2s; }
    body .section-link:hover { background: var(--d-solid); color: #fff !important; }
    body .section-link:hover::after { transform: translateX(3px); }

    /* Лигаҳо — плиткаҳо */
    body .leagues-scroll {
        display: grid; grid-template-columns: repeat(5, 1fr); gap: 14px; overflow: visible; padding: 0;
    }
    body .league-item { width: auto; }
    body .league-item a {
        display: flex; flex-direction: column; align-items: center; gap: 10px; padding: 18px 10px 14px;
        border-radius: 16px; background: linear-gradient(180deg, var(--d-hover), var(--d-card)); border: 1px solid var(--d-line);
        transition: transform .2s, box-shadow .2s, border-color .2s;
    }
    body .league-item img { width: 56px; height: 56px; padding: 0; margin: 0; background: transparent; box-shadow: none; border-radius: 0; filter: drop-shadow(0 6px 10px rgba(0, 0, 0, .12)); }
    body .league-item span { font-size: .78rem; font-weight: 650; color: var(--d-ink-2); text-align: center; line-height: 1.25; }
    body .league-item a:hover { transform: translateY(-4px); box-shadow: var(--d-sh-2); border-color: rgba(34, 197, 94, .45); }
    body .league-item a:hover img { transform: scale(1.08); box-shadow: none; }
    body .league-item a:hover span { color: var(--d-ink); }

    /* Видеоҳо */
    body .videos-grid { grid-template-columns: repeat(4, 1fr); gap: 18px; }
    body .video-card { border-radius: 16px; box-shadow: none; background: transparent; overflow: visible; }
    body .video-thumbnail-container { height: auto !important; aspect-ratio: 16 / 9; border-radius: 16px; overflow: hidden; box-shadow: var(--d-sh-2); }
    body .thumbnail-image { height: 100% !important; transition: transform .5s cubic-bezier(.2, .8, .2, 1); }
    body .play-overlay { background: linear-gradient(0deg, rgba(7, 18, 11, .55), transparent 60%); transition: background .3s; }
    body .play-icon {
        width: 50px; height: 50px; font-size: 1rem; background: rgba(255, 255, 255, .18); backdrop-filter: blur(6px);
        border: 1px solid rgba(255, 255, 255, .4); transition: transform .25s, background .25s;
    }
    body .video-card:hover .thumbnail-image { transform: scale(1.07); }
    body .video-card:hover .play-icon { transform: scale(1.12); background: var(--d-green); border-color: var(--d-green); }
    body .video-info { padding: 12px 2px 0; }
    body .video-title { font-size: .92rem; line-height: 1.4; font-weight: 700; }
    body .video-card:hover .video-title { color: var(--d-pitch); }

    /* Хабарҳои асосӣ — корт бо акси калон */
    body .section:has(> .news-card) { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; }
    body .section:has(> .news-card) > .section-header,
    body .section:has(> .news-card) > .load-more,
    body .section:has(> .news-card) > p { grid-column: 1 / -1; }
    body .section > .news-card,
    body .section > .news-card:last-of-type {
        flex-direction: column; margin: 0; padding: 0; border: none; border-radius: 16px;
    }
    body .section > .news-card .news-image {
        width: 100%; height: auto; aspect-ratio: 16 / 10; margin: 0 0 14px; border-radius: 16px;
        box-shadow: var(--d-sh-2); transition: transform .5s cubic-bezier(.2, .8, .2, 1), filter .3s;
    }
    body .section > .news-card .news-title { font-size: 1.02rem; line-height: 1.4; letter-spacing: -.01em; -webkit-line-clamp: 3; }
    body .section > .news-card .news-meta span:first-child { color: var(--d-green); font-weight: 700; }
    body .news-card:hover .news-title { color: var(--d-pitch); }
    body .section > .news-card:hover .news-image { transform: translateY(-3px); filter: saturate(1.15); }
    body .section > .news-card:first-of-type { grid-column: span 1; }

    body .load-more { margin-top: 22px; }
    body .load-more-btn {
        background: var(--d-solid) !important; border-radius: 12px !important; padding: 12px 26px !important;
        transition: transform .15s, background .2s; font-size: .85rem;
    }
    body .load-more-btn:hover { background: var(--d-solid-hover) !important; transform: translateY(-1px); }

    /* ---------- Панели рости саҳифаи асосӣ (ajax_home_rail.php) ---------- */
    .rail-card {
        background: var(--d-card); border: 1px solid var(--d-line); border-radius: 22px; overflow: hidden;
        box-shadow: var(--d-sh-1);
    }
    .rail-card.dark { background: radial-gradient(320px 180px at 100% 0, rgba(239, 68, 68, .09), transparent 70%), var(--d-card); border-color: rgba(239, 68, 68, .22); }
    html[data-theme="dark"] .rail-card.dark {
        background:
            radial-gradient(320px 180px at 100% 0, rgba(239, 68, 68, .22), transparent 70%),
            radial-gradient(300px 200px at 0 100%, rgba(74, 222, 128, .16), transparent 70%),
            linear-gradient(160deg, var(--d-night-2), var(--d-night));
        border-color: rgba(255, 255, 255, .06); color: #fff; box-shadow: var(--d-sh-3);
    }
    .rail-head { display: flex; align-items: center; justify-content: space-between; padding: 18px 20px 12px; }
    .rail-title { font-weight: 800; font-size: 1.02rem; letter-spacing: -.02em; display: flex; align-items: center; gap: 10px; }
    .rail-title .live-dot2 { width: 9px; height: 9px; border-radius: 50%; background: var(--d-red); animation: fzPing 1.6s infinite; }
    .rail-more { font-size: .78rem; font-weight: 650; text-decoration: none; color: var(--d-ink-2); padding: 6px 10px; border-radius: 9px; background: var(--d-bg); }
    html[data-theme="dark"] .rail-card.dark .rail-more { color: rgba(255, 255, 255, .8); background: rgba(255, 255, 255, .08); }
    .rail-more:hover { filter: brightness(1.1); }
    .rail-count { font-size: .72rem; font-weight: 800; background: var(--d-red); color: #fff; border-radius: 20px; padding: 2px 9px; }

    .rail-list { padding: 0 10px 12px; }
    .rail-league { display: flex; align-items: center; gap: 8px; padding: 10px 10px 6px; font-size: .7rem; font-weight: 750; letter-spacing: .06em; text-transform: uppercase; color: var(--d-ink-3); }
    html[data-theme="dark"] .rail-card.dark .rail-league { color: rgba(255, 255, 255, .45); }
    .rail-league img { width: 16px; height: 16px; object-fit: contain; }
    .rail-match {
        display: grid; grid-template-columns: 1fr auto; gap: 4px 10px; align-items: center;
        padding: 10px 12px; border-radius: 13px; text-decoration: none; color: inherit; transition: background .18s;
    }
    .rail-match:hover { background: var(--d-bg); }
    html[data-theme="dark"] .rail-card.dark .rail-match:hover { background: rgba(255, 255, 255, .06); }
    .rail-team { display: flex; align-items: center; gap: 9px; font-size: .86rem; font-weight: 600; min-width: 0; }
    .rail-team img { width: 20px; height: 20px; object-fit: contain; flex-shrink: 0; }
    .rail-team span { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
    .rail-score { font-weight: 800; font-size: .92rem; text-align: right; font-variant-numeric: tabular-nums; min-width: 22px; }
    .rail-side { grid-column: 2; grid-row: 1 / span 2; display: flex; flex-direction: column; align-items: flex-end; justify-content: center; gap: 3px; }
    .rail-teams { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
    .rail-badge { font-size: .7rem; font-weight: 800; padding: 3px 8px; border-radius: 8px; white-space: nowrap; }
    .rail-badge.live { background: rgba(239, 68, 68, .16); color: #f87171; }
    .rail-badge.time { background: var(--d-bg); color: var(--d-ink); }
    .rail-badge.ft { background: var(--d-soft); color: var(--d-ink-3); }
    .rail-scores { display: flex; flex-direction: column; gap: 6px; align-items: flex-end; }
    .rail-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
    .rail-empty { padding: 6px 22px 22px; font-size: .85rem; color: var(--d-ink-3); }
    html[data-theme="dark"] .rail-card.dark .rail-empty { color: rgba(255, 255, 255, .6); }
    .rail-skel { height: 64px; margin: 6px 12px; border-radius: 13px; background: linear-gradient(90deg, var(--d-soft) 0%, var(--d-hover) 50%, var(--d-soft) 100%); background-size: 200% 100%; animation: fzShimmer 1.3s infinite; }
    html[data-theme="dark"] .rail-card.dark .rail-skel { background: linear-gradient(90deg, rgba(255,255,255,.05) 0%, rgba(255,255,255,.1) 50%, rgba(255,255,255,.05) 100%); background-size: 200% 100%; }
    @keyframes fzShimmer { from { background-position: 200% 0; } to { background-position: -200% 0; } }

    .rail-quick { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; padding: 0 16px 16px; }
    .rail-quick a {
        display: flex; flex-direction: column; gap: 10px; padding: 14px; border-radius: 15px; text-decoration: none;
        color: var(--d-ink); font-weight: 700; font-size: .84rem; background: var(--d-bg); border: 1px solid transparent;
        transition: transform .18s, border-color .18s, background .18s;
    }
    .rail-quick a:hover { transform: translateY(-2px); background: var(--d-card); border-color: var(--d-line); box-shadow: var(--d-sh-2); }
    .rail-quick a i { width: 36px; height: 36px; border-radius: 11px; display: flex; align-items: center; justify-content: center; font-size: .95rem; color: #fff; }
    .rail-quick a small { display: block; font-weight: 500; color: var(--d-ink-3); font-size: .72rem; margin-top: -6px; }

    /* ======================================================================
       ФУТЕР (танҳо компютер)
       ====================================================================== */
    .fz-footer {
        display: block; padding: 48px 36px 28px;
        background: var(--ft-bg); color: var(--ft-fg); border-top: 1px solid var(--ft-line);
        position: relative; overflow: hidden;
    }
    .fz-footer::before { content: ""; position: absolute; inset: 0 0 auto 0; height: 1px; background: linear-gradient(90deg, transparent, rgba(74, 222, 128, .5), transparent); }
    .fz-footer-inner { max-width: 1240px; margin: 0 auto; display: grid; grid-template-columns: 1.4fr 1fr 1fr 1fr; gap: 40px; }
    .fz-footer-brand { display: flex; align-items: center; gap: 12px; color: #fff; font-weight: 800; font-size: 1.15rem; letter-spacing: -.02em; margin-bottom: 14px; text-decoration: none; color: var(--ft-strong); }
    .fz-footer-brand img { width: 42px; height: 42px; border-radius: 12px; }
    .fz-footer p { font-size: .86rem; line-height: 1.7; max-width: 340px; }
    .fz-footer h4 { color: var(--ft-strong); font-size: .74rem; letter-spacing: .14em; text-transform: uppercase; margin-bottom: 16px; font-weight: 750; }
    .fz-footer ul { list-style: none; display: flex; flex-direction: column; gap: 10px; }
    .fz-footer ul a { color: var(--ft-fg); text-decoration: none; font-size: .88rem; transition: color .18s, padding .18s; }
    .fz-footer ul a:hover { color: var(--sb-accent); padding-left: 4px; }
    .fz-footer-bottom {
        max-width: 1240px; margin: 36px auto 0; padding-top: 22px; border-top: 1px solid var(--ft-line);
        display: flex; justify-content: space-between; font-size: .8rem; color: var(--d-ink-3);
    }

    /* ======================================================================
       ХАБАРҲО (news.php) / ВИДЕОҲО (videos.php)
       ====================================================================== */
    body .search-box { background: var(--d-card); border: 1px solid var(--d-line); border-radius: 18px; padding: 10px; box-shadow: var(--d-sh-1); margin-bottom: 22px !important; }
    body .search-box input { border: none !important; background: transparent; font-size: .95rem; color: var(--d-ink); }
    body .search-box button, body .filter-btn { border-radius: 12px !important; }
    body .search-box button { background: var(--d-solid) !important; }
    body .card .search-box { border: none; box-shadow: none; padding: 0; margin-bottom: 0 !important; background: transparent; }

    body #newsFeed { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; }
    body #newsFeed > .card {
        margin-bottom: 0; padding: 0 !important; overflow: hidden; display: flex; flex-direction: column;
        transition: transform .25s cubic-bezier(.2, .8, .2, 1), box-shadow .25s, border-color .25s;
    }
    body #newsFeed > .card:hover { transform: translateY(-4px); box-shadow: var(--d-sh-2); border-color: var(--d-line-2); }
    body #newsFeed > .empty-state { grid-column: 1 / -1; }
    body #newsFeed .list-item { flex-direction: column; align-items: stretch; padding: 0 !important; gap: 0; border: none; height: 100%; }
    body #newsFeed .list-thumb {
        width: 100% !important; height: auto !important; aspect-ratio: 16 / 10; border-radius: 0 !important;
        transition: transform .6s cubic-bezier(.2, .8, .2, 1);
    }
    body #newsFeed > .card:hover .list-thumb { transform: scale(1.05); }
    body #newsFeed .list-info { padding: 16px 18px 18px; position: relative; background: var(--d-card); }
    body #newsFeed .list-title { white-space: normal; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; font-size: 1rem; line-height: 1.42; letter-spacing: -.01em; }
    body #newsFeed > .card:hover .list-title { color: var(--d-pitch); }
    body #newsFeed .list-meta { font-size: .76rem; }

    body #videoFeed { display: grid; grid-template-columns: repeat(3, 1fr); gap: 26px 22px; }
    body #videoFeed > .yt-card { margin-bottom: 0; }
    body #videoFeed > .empty-state { grid-column: 1 / -1; }
    body .yt-card:hover { transform: translateY(-3px); }
    body .yt-card:hover .yt-title { color: var(--d-pitch); }

    /* Bottom-sheet-и филтр → тирезаи марказӣ */
    body .filter-sheet {
        left: 50% !important; right: auto !important; width: 560px; max-width: 90vw;
        border-radius: 22px !important; transform: translateX(-50%);
        bottom: auto !important; top: -120%; transition: top .3s cubic-bezier(.4, 0, .2, 1) !important;
        box-shadow: var(--d-sh-3) !important;
    }
    body .filter-sheet.active { top: 50%; transform: translate(-50%, -50%); }

    /* ======================================================================
       БОЗИҲО / ЗИНДА (matches.php, live.php, лигаҳо)
       ====================================================================== */
    body .date-tabs, body .date-picker-form { max-width: none; margin-left: 0; margin-right: 0; }
    body .date-tabs { background: var(--d-card); border: 1px solid var(--d-line); border-radius: 16px; padding: 6px; gap: 6px !important; box-shadow: var(--d-sh-1); }
    body .date-tab { border: none !important; border-radius: 11px !important; padding: 11px !important; font-weight: 650 !important; background: transparent !important; transition: background .2s, color .2s; }
    body .date-tab:hover { background: var(--d-bg) !important; }
    body .date-tab.active { background: var(--d-solid) !important; color: #fff !important; box-shadow: 0 10px 20px -10px rgba(7, 18, 11, .7); }
    body .date-display-wrap { border-radius: 14px !important; padding: 13px 18px !important; box-shadow: var(--d-sh-1); }

    body .comp-group, body .competition-section {
        margin-bottom: 22px; border-radius: 20px; overflow: hidden; background: var(--d-card);
        border: 1px solid var(--d-line); box-shadow: var(--d-sh-1);
    }
    body .comp-header, body .competition-header {
        background: var(--comp-bg) !important;
        padding: 14px 22px !important; font-size: .95rem !important; font-weight: 750 !important;
        letter-spacing: -.01em; border-radius: 0 !important; gap: 12px !important;
    }
    body .comp-header img, body .competition-header img { background: #fff; border-radius: 8px; padding: 3px; }
    body .comp-header i, body .competition-header i { color: #fff; opacity: .9; }
    body .container > div > .competition-header:only-child,
    body .container > div > .competition-header:first-child:not(:only-child) { border-radius: 16px !important; margin-bottom: 14px; }
    body .comp-matches, body .competition-matches { border-radius: 0 !important; }

    body .match-item { padding: 16px 26px; border-color: var(--d-line) !important; }
    body .match-item:hover { background: var(--d-hover) !important; }
    body .match-team-name, body .team-name { font-size: .95rem; font-weight: 600; }
    body .match-team-logo, body .match-item .team-logo { width: 30px; height: 30px; }
    body .match-center, body .match-score {
        min-width: 74px; padding: 6px 12px; border-radius: 10px; background: var(--d-bg);
        font-variant-numeric: tabular-nums; font-size: 1.02rem; font-weight: 800; color: var(--d-ink);
    }
    body .match-center.vs { background: transparent; }
    body .match-item-live { background: linear-gradient(90deg, rgba(239, 68, 68, .07), transparent 60%) !important; border-left: 3px solid var(--d-red) !important; }
    body .live-score, body .match-item.live .match-score { background: rgba(239, 68, 68, .1) !important; color: #dc2626 !important; }
    body .extra-leagues-btn { border-radius: 16px; padding: 16px; background: var(--d-card); transition: background .2s; }
    body .extra-leagues-btn:hover { background: var(--highlight); }
    body .current-time { border-radius: 16px; }
    body .no-matches { border-radius: 20px; border: 1px dashed var(--d-line-2); background: var(--d-card); }

    /* ================= Лигаҳо ================= */
    body .leagues-search { top: 88px; }
    body .league-row:hover { background: var(--highlight); }

    /* ================= Саҳифаи бозӣ (match.php) ================= */
    body .match-info-card { padding: 32px; border-radius: 24px; }
    body .match-teams .team-logo { width: 84px; height: 84px; }
    body .match-score { font-size: 2.6rem; }
    body .pitch-wrap { max-width: 760px; }

    /* ================= Бозигар / Даста ================= */
    body .stat-box-grid { grid-template-columns: repeat(6, 1fr); }

    /* ================= Ҷадвалҳо ================= */
    body table { border-collapse: separate; border-spacing: 0; }
    body table th { font-size: .74rem; letter-spacing: .06em; text-transform: uppercase; }
    body table tbody tr { transition: background .15s; }
    body table tbody tr:hover { background: var(--d-hover); }

    /* ================= Воридшавӣ / Сабти ном ================= */
    body .login-container { max-width: 480px; margin: 40px auto; }

    /* ================= Шиносоӣ / Махфият ================= */
    body .feature-grid { grid-template-columns: repeat(5, 1fr) !important; }

    /* ================= Каналҳои ТВ ================= */
    body.tv-page .container { max-width: 1040px; margin: 0 auto; padding: 24px 36px 48px; }

    /* Анимацияи пайдоиш */
    .fz-main > .section, .fz-main > .banner-slider, .fz-rail, .fz-main > .header {
        animation: fzRise .6s cubic-bezier(.2, .8, .2, 1) both;
    }
    .fz-main > :nth-child(4) { animation-delay: .05s; }
    .fz-main > :nth-child(5) { animation-delay: .1s; }
    .fz-main > :nth-child(6) { animation-delay: .15s; }
    .fz-main > :nth-child(7) { animation-delay: .2s; }
    @keyframes fzRise { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: none; } }
    @media (prefers-reduced-motion: reduce) {
        *, *::before, *::after { animation: none !important; transition: none !important; }
    }
}

/* Ноутбукҳои хурд: панели рост танг */
@media (min-width: 1024px) and (max-width: 1279px) {
    :root { --sidebar-w: 236px; }
    body.page-home .fz-main { grid-template-columns: minmax(0, 1fr) 300px; column-gap: 20px; padding: 24px 24px 48px; }
    body .videos-grid { grid-template-columns: repeat(2, 1fr); }
    body .leagues-scroll { grid-template-columns: repeat(3, 1fr); }
    body .section:has(> .news-card) { grid-template-columns: repeat(2, 1fr); }
    body #newsFeed { grid-template-columns: repeat(2, 1fr); }
    body #videoFeed { grid-template-columns: repeat(2, 1fr); }
    .fz-today { display: none !important; }
    .fz-footer-inner { grid-template-columns: 1fr 1fr; }
}

/* Экранҳои калон */
@media (min-width: 1600px) {
    :root { --sidebar-w: 284px; --content-w: 1240px; }
    body.page-home .fz-main { max-width: 1440px; grid-template-columns: minmax(0, 1fr) 380px; }
    body #videoFeed { grid-template-columns: repeat(4, 1fr); }
}
