:root
{
    --font-main: "Cairo", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    --bg-base: #10131f;
    --bg-elevated: #171b2c;
    --bg-panel: #1d2237;
    --bg-soft: #252b45;
    --text-main: #f5f7ff;
    --text-soft: #d9ddf0;
    --text-muted: #a6adc8;
    --text-faint: #7f88a8;
    --primary: #7c6cff;
    --secondary: #ff7db2;
    --accent: #ffb84d;
    --accent-soft: #67d8ff;
    --success: #39c98a;
    --border-soft: rgba(255, 255, 255, 0.08);
    --border-strong: rgba(255, 255, 255, 0.16);
    --shadow-sm: 0 8px 18px rgba(0, 0, 0, 0.18);
    --shadow-md: 0 12px 28px rgba(0, 0, 0, 0.22);
    --shadow-lg: 0 18px 40px rgba(0, 0, 0, 0.28);
    --radius-sm: 14px;
    --radius-md: 18px;
    --radius-lg: 22px;
    --radius-xl: 28px;
    --radius-pill: 999px;
    --header-height: 72px;
    --bottom-nav-height: 78px;
    --transition-fast: 160ms ease;
    --transition-base: 240ms ease;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }

body
{
    margin: 0;
    min-height: 100vh;
    font-family: var(--font-main);
    background: var(--bg-base);
    color: var(--text-main);
    overflow-x: hidden;
}

a { color: inherit; text-decoration: none; }
img { display: block; max-width: 100%; }
button { font-family: inherit; }

.container
{
    width: min(100% - 32px, 1200px);
    margin-inline: auto;
}

.app-shell
{
    padding-bottom: calc(var(--bottom-nav-height) + 30px + env(safe-area-inset-bottom));
}

.site-header
{
    position: sticky;
    top: 0;
    z-index: 100;
    height: calc(var(--header-height) + env(safe-area-inset-top));
    padding-top: env(safe-area-inset-top);
    background: rgba(16, 19, 31, 0.84);
    backdrop-filter: blur(14px);
    border-bottom: 1px solid var(--border-soft);
}

.site-header__inner
{
    min-height: var(--header-height);
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
}

.brand
{
    display: inline-flex;
    align-items: center;
    gap: 12px;
    min-width: 0;
}

.brand__logo
{
    width: 46px;
    height: 46px;
    border-radius: 16px;
    flex: 0 0 auto;
    background: linear-gradient(135deg, var(--secondary), var(--primary));
    border: 1px solid var(--border-soft);
    box-shadow: var(--shadow-md);
    position: relative;
}

.brand__text { min-width: 0; }

.brand__title
{
    margin: 0;
    font-size: 1.25rem;
    font-weight: 900;
    line-height: 1.1;
	unicode-bidi: plaintext;
}

.brand__subtitle
{
    display: block;
    margin-top: 2px;
    color: var(--text-muted);
    font-size: 0.76rem;
	unicode-bidi: plaintext;
}

.header-actions
{
    display: flex;
    align-items: center;
    gap: 8px;
}

.icon-btn
{
    width: 42px;
    height: 42px;
	font-size: 1.1rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: var(--radius-sm);
    border: 1px solid var(--border-soft);
    background: rgba(255, 255, 255, 0.04);
    color: var(--text-soft);
    box-shadow: var(--shadow-sm);
    cursor: pointer;
    transition: transform var(--transition-fast), background var(--transition-fast), border-color var(--transition-fast), color var(--transition-fast);
}

.icon-btn:hover,
.icon-btn:focus-visible
{
    transform: translateY(-2px);
    background: rgba(255, 255, 255, 0.08);
    border-color: var(--border-strong);
    color: var(--text-main);
    outline: none;
}

.section { padding: 18px 0; }

.section__head
{
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    margin-bottom: 16px;
}

.section__title-wrap { min-width: 0; }

.section__title
{
    margin: 0;
    font-size: clamp(1.15rem, 2vw, 1.45rem);
    font-weight: 900;
	unicode-bidi: plaintext;
}

.section__kicker
{
    display: block;
    margin-bottom: 6px;
    color: var(--secondary);
    font-size: 1rem;
    font-weight: 900;
}

.section__link
{
    color: var(--text-soft);
    font-size: 0.9rem;
    font-weight: 800;
    white-space: nowrap;
}

.hero
{
    padding-top: 22px;
    padding-bottom: 8px;
}

.hero__shell
{
    position: relative;
    overflow: hidden;
    min-height: 320px;
    border-radius: var(--radius-xl);
    border: 1px solid var(--border-soft);
    background: linear-gradient(135deg, rgba(29, 34, 55, 0.96), rgba(16, 19, 31, 0.98));
    box-shadow: var(--shadow-lg);
    isolation: isolate;
}

.hero__shell::before,
.hero__shell::after
{
    content: "";
    position: absolute;
    pointer-events: none;
}

.hero__shell::before
{
    inset: 0;
    background-image: radial-gradient(circle at 12px 12px, rgba(255, 255, 255, 0.12) 1.6px, transparent 2px), radial-gradient(circle at 50px 28px, rgba(255, 255, 255, 0.08) 1.2px, transparent 1.8px);
    background-size: 120px 120px;
    opacity: 0.16;
}

.hero__shell::after
{
    width: 280px;
    height: 280px;
    left: -40px;
    bottom: -130px;
    border-radius: 50%;
    background: rgba(124, 108, 255, 0.16);
    filter: blur(45px);
}

.hero__grid
{
    position: relative;
    z-index: 1;
    display: grid;
    grid-template-columns: 1fr;
    gap: 24px;
    padding: 24px;
    align-items: center;
    min-height: 320px;
}

.hero__content { max-width: 620px; }

.eyebrow
{
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 14px;
    padding: 8px 14px;
    border-radius: var(--radius-pill);
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid var(--border-soft);
    color: var(--text-soft);
    font-size: 0.9rem;
    font-weight: 800;
    box-shadow: var(--shadow-sm);
}

.eyebrow__dot
{
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--accent), var(--secondary));
}

.hero__title
{
    margin: 0;
    font-size: clamp(1.8rem, 5vw, 2rem);
    line-height: 1.12;
    font-weight: 900;
	unicode-bidi: plaintext;
}

.hero__desc
{
    margin: 14px 0 0;
    line-height: 1.9;
    max-width: 54ch;
    font-size: 1rem;
}

.hero__actions
{
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-top: 24px;
}

.btn
{
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    min-height: 48px;
    padding: 0 20px;
    border-radius: var(--radius-sm);
    border: 1px solid transparent;
    font-size: 0.9rem;
    font-weight: 900;
    cursor: pointer;
    transition: transform var(--transition-fast), box-shadow var(--transition-fast), background var(--transition-fast), border-color var(--transition-fast);
}

.btn:hover,
.btn:focus-visible
{
    transform: translateY(-2px);
    outline: none;
}

.btn-primary
{
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    color: #fff;
    box-shadow: 0 10px 24px rgba(124, 108, 255, 0.20);
}

.btn-secondary
{
    background: rgba(255, 255, 255, 0.06);
    color: var(--text-main);
    border-color: var(--border-soft);
}

.btn-danger {
    background: linear-gradient(135deg, #e85d75, #d64545);
    color: #fff;
    box-shadow: 0 10px 24px rgba(232,93,117,0.18);
}

.hero__visual
{
    position: relative;
    display: grid;
    place-items: center;
    min-height: 240px;
}

.hero-art
{
    width: min(100%, 420px);
    aspect-ratio: 1 / 1;
    position: relative;
}

.hero-art__card,
.hero-art__orb,
.hero-art__chip
{
    position: absolute;
    border-radius: 24px;
    border: 1px solid var(--border-soft);
    box-shadow: var(--shadow-md);
}

.hero-art__card--main
{
    inset: 12%;
    transform: rotate(-6deg);
    background: linear-gradient(145deg, rgba(124, 108, 255, 0.42), rgba(255, 125, 178, 0.34), rgba(103, 216, 255, 0.24));
}

.hero-art__card--sub
{
    width: 42%;
    height: 42%;
    left: 3%;
    bottom: 9%;
    transform: rotate(8deg);
    background: linear-gradient(145deg, rgba(255, 184, 77, 0.28), rgba(255, 255, 255, 0.10));
}

.hero-art__orb
{
    border-radius: 50%;
    background: rgba(255, 125, 178, 0.20);
}

.hero-art__orb:not(.hero-art__orb--two)
{
    width: 58px;
    height: 58px;
    top: 14%;
    right: 10%;
}

.hero-art__orb--two
{
    width: 34px;
    height: 34px;
    right: 28%;
    bottom: 8%;
    background: rgba(103, 216, 255, 0.24);
}

.hero-art__chip
{
    padding: 10px 14px;
    border-radius: var(--radius-pill);
    background: rgba(255, 255, 255, 0.10);
    font-size: 0.76rem;
    font-weight: 900;
    color: var(--text-main);
}

.hero-art__chip--a { top: 18%; left: 5%; }
.hero-art__chip--b { right: 4%; bottom: 22%; }

.featured-grid
{
    display: grid;
    gap: 14px;
    grid-template-columns: 1fr;
}

.cards-grid
{
    display: grid;
    gap: 14px;
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.media-card {
    position: relative;
    display: block;
    min-height: 188px;
    overflow: hidden;
    border-radius: var(--radius-lg);
    background: var(--bg-panel);
    border: 1px solid var(--border-soft);
    box-shadow: var(--shadow-md);
    isolation: isolate;
    transition:
        transform var(--transition-base),
        box-shadow var(--transition-base),
        border-color var(--transition-base);
}

.media-card:hover,
.media-card:focus-visible
{
    transform: translateY(-4px);
    border-color: var(--border-strong);
    box-shadow: var(--shadow-lg);
    outline: none;
}

.media-card__bg
{
    position: absolute;
    inset: 0;
    background: linear-gradient(155deg, rgba(255, 255, 255, 0.16), transparent 30%), linear-gradient(135deg, rgba(124, 108, 255, 0.28), rgba(255, 125, 178, 0.22), rgba(103, 216, 255, 0.18));
	background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
}

.media-card__bg--two
{
    background: linear-gradient(135deg, rgba(255, 184, 77, 0.24), rgba(255, 125, 178, 0.22), rgba(124, 108, 255, 0.18));
}

.media-card__bg--three
{
    background: linear-gradient(135deg, rgba(103, 216, 255, 0.22), rgba(124, 108, 255, 0.20), rgba(255, 125, 178, 0.18));
}

.media-card__bg--four
{
    background: linear-gradient(135deg, rgba(255, 125, 178, 0.18), rgba(255, 184, 77, 0.18), rgba(255, 255, 255, 0.18));
}

.media-card::after
{
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(to top, rgba(20, 24, 38, 0.84) 10%, rgba(20, 24, 38, 0.20) 44%, transparent 72%);
    pointer-events: none;
}

.media-card__body
{
    position: absolute;
    bottom: 0;
    width: 100%;
    padding: 10px;
    z-index: 2;
}

.media-card__title
{
    margin: 0;
    font-size: 1rem;
    font-weight: 900;
    line-height: 1.45;
    color: #fff;
    display: -webkit-box;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
    overflow: hidden;
	unicode-bidi: plaintext;
}

.media-card__meta
{
    margin-top: 6px;
    color: rgba(255, 255, 255, 0.88);
    font-size: 0.77rem;
    line-height: 1.5;
}

.media-card__metas {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

/* ------- */

.media-card__titles
{
    margin: 0;
    font-size: 0.96rem;
    line-height: 1.5;
    font-weight: 900;
    color: var(--text-main);
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
	unicode-bidi: plaintext;
}

.history-meta
{
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 10px;
    color: var(--text-muted);
    font-size: 0.78rem;
    line-height: 1.4;
	unicode-bidi: plaintext;
}

.history-meta__relative
{
    color: var(--text-soft);
    font-weight: 800;
}

.history-meta__dot
{
    width: 4px;
    height: 4px;
    border-radius: 50%;
    background: rgba(255,255,255,0.24);
}

/* ------- */

.history-time {
    font-size: 0.85rem;
    font-weight: 800;
    color: var(--text-soft);
}

.history-date {
    font-size: 0.75rem;
    color: var(--text-muted);
}

.category-card
{
    position: relative;
    aspect-ratio: 1 / 1;
    overflow: hidden;
    border-radius: var(--radius-lg);
    background: var(--bg-panel);
}

.category-card .media-card__bg
{
    position: absolute;
    inset: 0;
    background-size: contain;
    background-position: center;
    background-repeat: no-repeat;
}

.badge
{
    position: absolute;
    top: 12px;
    right: 12px;
    z-index: 3;
    min-height: 30px;
    padding: 0 12px;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    border-radius: var(--radius-pill);
    border: 1px solid rgba(255, 255, 255, 0.18);
    box-shadow: var(--shadow-sm);
    color: #fff;
    font-size: 0.74rem;
    font-weight: 900;
    backdrop-filter: blur(10px);
}

.badge--new { background: linear-gradient(135deg, var(--secondary), var(--primary)); }
.badge--viewed { background: rgba(30, 34, 48, 0.72); }
.badge--popular { background: linear-gradient(135deg, var(--accent), #ff9d2e); }

.badge-favorite
{
    position: absolute;
    top: 8px;
    left: 4px;
    z-index: 3;
    min-height: 30px;
    padding: 0 12px;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    color: var(--secondary);
    font-size: 0.74rem;
    font-weight: 900;
}

.ticker
{
    position: relative;
    overflow: hidden;
    display: grid;
    grid-template-columns: auto 1fr auto;
    align-items: center;
    gap: 14px;
    padding: 16px;
    border-radius: var(--radius-md);
    border: 1px solid var(--border-soft);
    background: linear-gradient(135deg, rgba(255, 125, 178, 0.10), rgba(103, 216, 255, 0.10), rgba(255, 255, 255, 0.04));
    box-shadow: var(--shadow-md);
}

.ticker__icon
{
    width: 42px;
    height: 42px;
    display: grid;
    place-items: center;
    border-radius: 16px;
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid var(--border-soft);
    font-size: 1.1rem;
}

.ticker__viewport
{
    overflow: hidden;
    white-space: nowrap;
    color: var(--text-soft);
    font-size: 0.9rem;
    font-weight: 800;
}

.ticker__track
{
    display: inline-block;
    padding-inline-start: 100%;
    animation: marquee-rtl 18s linear infinite;
}

@keyframes marquee-rtl
{
    from { transform: translateX(-100%); }
    to { transform: translateX(0); }
}

.category-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
}

.category-header__text {
    min-width: 0;
    flex: 1 1 auto;
    display: flex;
    align-items: center;
}

.category-header__title {
    margin: 0;
    line-height: 1.3;
    font-size: clamp(1.2rem, 2vw, 1.6rem);
    font-weight: 900;
    color: var(--text-main);
	unicode-bidi: plaintext;
}

.favorite-btn {
    flex: 0 0 auto;
    min-width: 132px;
    height: 40px;
    min-height: 40px;
    padding: 0 12px;
    justify-content: center;
    align-self: center;
}

.favorite-btn.is-active {
    border-color: rgba(255,255,255,0.22);
    background: linear-gradient(135deg, rgba(255,125,178,0.16), rgba(124,108,255,0.14));
}

.favorite-btn.is-active .material-icons {
    color: #ff7db2;
}

.favorite-btn:disabled
{
    opacity: 0.7;
    cursor: wait;
}

.favorite-btn.is-loading
{
    pointer-events: none;
}

html[dir="ltr"] .category-header
{
    flex-direction: row-reverse;
}

html[dir="ltr"] .category-header {
    flex-direction: row;
}

@media (max-width: 767px) {
    .category-header {
        align-items: center;
    }

    .favorite-btn {
        width: 40px;
        min-width: 40px;
        padding: 0;
    }

    .favorite-btn .btn-icon-text__label {
        display: none;
    }

    .favorite-btn .btn-icon-text__icon {
        font-size: 22px;
        margin: 0;
    }
}

.category-items
{
	position: relative;
    margin-top: 8px;
    padding-top: 24px;
}

.category-items::before
{
    content: "";
    position: absolute;
    top: 0;
    right: 0;
    left: 0;
    height: 1px;
    background: linear-gradient(to left, transparent, rgba(255,255,255,0.16), transparent);
}

.category-header-title
{
    margin: 0;
    font-size: 1.15rem;
    font-weight: 900;
	unicode-bidi: plaintext;
}

/* html[dir="ltr"] .category-header
{
    flex-direction: row-reverse;
} */

/* .category-header .btn-icon-text
{
    display: inline-flex !important;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 8px 14px !important;
    min-height: 40px;
    width: auto;
    line-height: 1;
    white-space: nowrap;
}

.category-header .btn-icon-text__icon
{
    font-size: 20px;
    line-height: 1;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.category-header
{
    display: inline-block;
    line-height: 1.2;
}

html[dir="rtl"] .category-header .btn-icon-text
{
    flex-direction: row-reverse;
} */

.quiz-panel
{
    position: relative;
    overflow: hidden;
    display: grid;
    gap: 16px;
    padding: 22px;
    border-radius: var(--radius-xl);
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.08), rgba(255, 255, 255, 0.04));
    border: 1px solid var(--border-soft);
    box-shadow: var(--shadow-lg);
}

.quiz-panel__content { position: relative; z-index: 1; }

.quiz-panel__kicker
{
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 10px;
    padding: 8px 12px;
    border-radius: var(--radius-pill);
    background: rgba(255, 255, 255, 0.08);
    color: var(--text-soft);
    font-size: 0.76rem;
    font-weight: 900;
    border: 1px solid var(--border-soft);
}

.quiz-panel__title
{
    margin: 0;
    font-size: clamp(1.25rem, 2vw, 1.65rem);
    font-weight: 900;
    line-height: 1.3;
    color: var(--text-main);
	unicode-bidi: plaintext;
}

.quiz-panel__desc
{
    margin: 10px 0 0;
    color: var(--text-soft);
    line-height: 1.85;
    font-size: 0.92rem;
}

.footer-links
{
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 18px;
	justify-content: center;
}

.footer-link
{
    display: inline-flex;
    align-items: center;
    min-height: 42px;
    padding: 0 15px;
    border-radius: var(--radius-sm);
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid var(--border-soft);
    color: var(--text-soft);
    font-size: 0.88rem;
    font-weight: 800;
    box-shadow: var(--shadow-sm);
	cursor: pointer;
}

.footer-note
{
    color: var(--text-faint);
    font-size: 0.78rem;
    line-height: 1.9;
    padding-bottom: 18px;
}

.bottom-nav
{
    position: fixed;
    z-index: 120;
    right: 16px;
    left: 16px;
    bottom: calc(14px + env(safe-area-inset-bottom));
    height: var(--bottom-nav-height);
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    align-items: stretch;
    padding: 8px;
    border-radius: var(--radius-xl);
    background: rgba(23, 29, 43, 0.92);
    border: 1px solid var(--border-soft);
    box-shadow: var(--shadow-lg);
    backdrop-filter: blur(14px);
}

.bottom-nav__item
{
    display: grid;
    place-items: center;
    align-content: center;
    gap: 4px;
    border-radius: var(--radius-md);
    color: var(--text-muted);
    font-size: 0.68rem;
    font-weight: 900;
    position: relative;
    transition: transform var(--transition-fast), background var(--transition-fast), color var(--transition-fast);
}

.bottom-nav__item:hover,
.bottom-nav__item:focus-visible
{
    transform: translateY(-2px);
    background: rgba(255, 255, 255, 0.06);
    color: var(--text-main);
    outline: none;
}

.bottom-nav__item::before
{
    content: "";
    position: absolute;
    inset: auto 16px 6px 16px;
    height: 3px;
    border-radius: 999px;
    background: transparent;
    opacity: 0;
    transition: opacity var(--transition-fast), background var(--transition-fast);
}

.bottom-nav__item.is-active::before
{
    background: linear-gradient(135deg, var(--accent), var(--secondary));
    opacity: 1;
}

.bottom-nav__item.is-active
{
    background: linear-gradient(135deg, rgba(124, 108, 255, 0.18), rgba(255, 125, 178, 0.12));
    color: var(--text-main);
}

.bottom-nav__icon
{
    width: 26px;
    height: 26px;
    display: grid;
    place-items: center;
    font-size: 1.1rem;
}

.bottom-nav__item--center
{
    position: relative;
}

.bottom-nav__item--center .bottom-nav__icon
{
	width: 42px;
	height: 42px;
	border-radius: 16px;
	background: linear-gradient(135deg, var(--primary), var(--secondary));
	box-shadow: var(--glow-primary);
}

.bottom-nav__item--center span:last-child { margin-top: -2px; }

.desktop-only { display: none; }
.desktop-only-2 { display: none; }

@media (min-width: 640px)
{
    .container { width: min(100% - 40px, 1200px); }
    .featured-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
    .cards-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}

@media (min-width: 900px)
{
    .hero__grid
	{
        grid-template-columns: minmax(0, 1.15fr) minmax(320px, 0.85fr);
        padding: 34px;
        min-height: 390px;
    }

    .hero__visual { min-height: 300px; }
    .section { padding: 22px 0; }
    .cards-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); }
    .desktop-only { display: inline-flex; }
    .desktop-only-2 { display: block; }
}

@media (min-width: 1100px)
{
    .cards-grid { grid-template-columns: repeat(5, minmax(0, 1fr)); }
    .hero__shell { min-height: 410px; }
    .hero__grid { padding: 38px; }
}

@media (min-width: 1024px)
{
    .app-shell { padding-bottom: 28px; }
    .bottom-nav { display: none; }
}

@media (max-width: 420px)
{
    .brand__subtitle { display: none; }
    .hero__grid { padding: 20px; }
    .hero__actions { flex-direction: column; }
    .btn { width: 100%; }
    .ticker { grid-template-columns: auto 1fr; }
    .ticker .btn-secondary { display: none; }
}

.menu-backdrop
{
    position: fixed;
    inset: 0;
    z-index: 130;
    background: rgba(18, 18, 28, 0.32);
    backdrop-filter: blur(6px);
}

.portal-menu
{
    position: fixed;
    top: 0;
    left: 0;
    z-index: 140;
    width: min(340px, calc(100vw - 28px));
    height: 100dvh;
    padding: calc(18px + env(safe-area-inset-top)) 18px calc(18px + env(safe-area-inset-bottom));
    transform: translateX(-105%);
    transition: transform var(--transition-base);
    display: flex;
    flex-direction: column;
    gap: 18px;
    overflow: auto;
}

.portal-menu.is-open
{
    transform: translateX(0);
}

.portal-menu__head
{
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 12px;
    padding-bottom: 14px;
    border-bottom: 1px solid var(--border-soft);
}

.portal-menu__title
{
    display: block;
    font-size: 1rem;
    font-weight: 900;
    color: var(--text-main);
	unicode-bidi: plaintext;
}

.portal-menu__subtitle
{
    display: block;
    margin-top: 4px;
    font-size: 0.76rem;
    color: var(--text-muted);
	unicode-bidi: plaintext;
}

.portal-menu__nav
{
    display: grid;
    gap: 10px;
}

.portal-menu__link
{
    display: flex;
    align-items: center;
    min-height: 48px;
    padding: 0 14px;
    border-radius: var(--radius-sm);
    font-size: 0.9rem;
    font-weight: 800;
    transition: transform var(--transition-fast), background var(--transition-fast), border-color var(--transition-fast), color var(--transition-fast);
}

.portal-menu__link:hover,
.portal-menu__link:focus-visible
{
    transform: translateY(-2px);
    outline: none;
}

.portal-menu__link--button
{
    width: 100%;
    text-align: right;
    font-family: inherit;
    cursor: pointer;
}

.modal-backdrop
{
    position: fixed;
    inset: 0;
    z-index: 150;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 16px;
    background: rgba(18, 18, 28, 0.36);
    backdrop-filter: blur(8px);
}

.modal-backdrop.is-open
{
    display: flex;
}

.portal-modal
{
    width: min(100%, 560px);
    max-height: min(82vh, 760px);
    overflow: auto;
    border-radius: var(--radius-xl);
    box-shadow: var(--shadow-lg);
}

.portal-modal__head
{
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 18px 18px 12px;
    border-bottom: 1px solid var(--border-soft);
}

.portal-modal__title
{
    margin: 0;
    font-size: 1.05rem;
    font-weight: 900;
    color: var(--text-main);
	unicode-bidi: plaintext;
}

.portal-modal__body
{
    padding: 18px;
    color: var(--text-soft);
    line-height: 1.9;
    font-size: 0.92rem;
}

.portal-modal__body p
{
    margin: 0 0 12px;
}

.language-list
{
    display: grid;
    gap: 10px;
}

.language-option
{
    display: flex;
    align-items: center;
    justify-content: space-between;
    min-height: 48px;
    padding: 0 14px;
    border-radius: var(--radius-sm);
    font-size: 0.9rem;
    font-weight: 800;
    cursor: pointer;
    transition: transform var(--transition-fast), background var(--transition-fast), border-color var(--transition-fast), color var(--transition-fast);
}

.language-option:hover,
.language-option:focus-visible
{
    transform: translateY(-2px);
    outline: none;
}

@media (min-width: 1024px)
{
    .portal-menu
	{
        width: 360px;
    }
}

@media (max-width: 420px)
{
	.portal-modal
	{
        border-radius: 24px;
    }
}

.hero-section
{
    padding: 18px 0;
}

.hero
{
    position: relative;
    height: clamp(220px, 32vh, 300px);
    display: flex;
    align-items: center;
    overflow: hidden;
}

.hero__media
{
    position: absolute;
    inset: 0;
    z-index: 1;
}

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

.hero__overlay
{
    position: absolute;
    inset: 0;
    z-index: 2;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.78) 10%, rgba(0, 0, 0, 0.35) 45%, transparent 75%);
}

.hero__content
{
    position: relative;
    z-index: 3;
    height: clamp(220px, 32vh, 300px);
    display: flex;
    flex-direction: column;
    justify-content: center;
    max-width: 560px;
    padding: 24px;
    color: #fff;
}

.bottom-nav__item .material-icons
{
    font-size: 26px;
    line-height: 1;
}

.bottom-nav__item--primary .material-icons
{
    font-size: 30px;
}

.bottom-nav__item--primary
{
    transform: translateY(-6px);
}

.bottom-nav__item.active .material-icons
{
    transform: scale(1.15);
}

@media (max-width: 767px)
{
    .hero-section
	{
        padding: 0;
    }
	
    .hero-section .container
	{
        width: 100%;
        max-width: none;
        padding: 0;
    }
	
    .hero
	{
        border-radius: 0;
        height: clamp(220px, 32vh, 300px);
    }
	
    .hero__content
	{
        height: clamp(220px, 32vh, 300px);
        padding: 20px 16px;
    }
}

.site-header
{
    position: sticky;
    top: 0;
    z-index: 100;
    overflow: visible;
}

.occasion-decor
{
    position: absolute;
    top: calc(100% - 2px);
    left: 50%;
    transform: translateX(-50%);
    width: min(100% - 32px, 1200px);
    pointer-events: none;
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    z-index: 20;
}

.occasion-decor__item
{
    position: relative;
    display: block;
    width: 34px;
    height: 34px;
    flex: 0 0 auto;
}

.occasion-decor__item::before
{
    content: "";
    position: absolute;
    top: -22px;
    left: 50%;
    width: 1px;
    height: 22px;
    transform: translateX(-50%);
    background: rgba(216, 178, 110, 0.45);
}

.occasion-decor__item::after
{
    content: "";
    position: absolute;
    inset: 0;
    display: block;
}

.occasion-decor__item--star::after
{
    content: "✦";
    display: grid;
    place-items: center;
    color: #d8b26e;
    font-size: 20px;
    text-shadow: 0 0 10px rgba(216, 178, 110, 0.28);
}

.occasion-decor__item--crescent::after
{
    width: 28px;
    height: 28px;
    margin: 3px auto 0;
    border-radius: 50%;
    box-shadow: -8px 0 0 0 #d8b26e;
    opacity: 0.95;
    filter: drop-shadow(0 0 8px rgba(216, 178, 110, 0.22));
}

.occasion-decor__item--lantern::after
{
    width: 20px;
    height: 26px;
    margin: 4px auto 0;
    border-radius: 8px;
    background: linear-gradient(180deg, #f4d58a 0%, #d8b26e 55%, #b98c3d 100%);
    box-shadow: 0 0 12px rgba(216, 178, 110, 0.26), inset 0 0 0 1px rgba(255,255,255,0.18);
    clip-path: polygon(25% 0%, 75% 0%, 88% 18%, 88% 82%, 75% 100%, 25% 100%, 12% 82%, 12% 18%);
}

.occasion-decor__item--lantern
{
    animation: lanternSwing 3.6s ease-in-out infinite;
    transform-origin: top center;
}

.occasion-decor__item--lantern:nth-child(2)
{
    animation-delay: -.8s;
}

.occasion-decor__item--lantern:nth-child(4)
{
    animation-delay: -.3s;
}

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

@media (max-width: 767px)
{
    .occasion-decor
	{
        width: calc(100% - 20px);
    }
	
    .occasion-decor__item
	{
        width: 24px;
        height: 24px;
    }
	
    .occasion-decor__item::before
	{
        height: 16px;
        top: -16px;
    }
	
    .occasion-decor__item--star::after
	{
        font-size: 16px;
    }
	
    .occasion-decor__item--crescent::after
	{
        width: 20px;
        height: 20px;
        box-shadow: -6px 0 0 0 #d8b26e;
    }
	
    .occasion-decor__item--lantern::after
	{
        width: 14px;
        height: 18px;
    }
}

.item-fallback
{
	padding: 28px 16px;
	display: grid;
	gap: 10px;
	place-items: center;
	text-align: center;
	color: var(--text-soft);
}

.item-fallback__icon
{
	font-size: 34px;
	color: var(--text-muted);
}

.item-fallback__text
{
	margin: 0;
	line-height: 1.7;
}

.video-stage
{
	padding-top: 14px;
}

.video-stage__container {
    width: min( - 48px, 1320px);
    margin-inline: auto;
}

.video-stage__player-wrap
{
	width: 100%;
    aspect-ratio: 16 / 9;
    min-height: 260px;
    max-height: 82vh;
    background: #000;
    overflow: hidden;
    box-shadow: var(--shadow-lg);
}

.video-stage__player
{
	width: 100%;
	height: 100%;
	display: block;
	object-fit: contain;
	background: #000;
}

@media (max-width: 767px)
{
    .video-stage {
        padding-top: 0;
    }

    .video-stage__container {
        width: 100%;
        max-width: none;
        padding: 0;
    }

    .video-stage__player-wrap {
        border-radius: 0;
        border-inline: 0;
        min-height: 220px;
    }
}

.btn-icon-text {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    line-height: 1;
    white-space: nowrap;
}

.btn-icon-text__icon {
    font-size: 20px;
    line-height: 1;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.btn-icon-text__label {
    display: inline-block;
    line-height: 1;
}

.video-details
{
	padding-top: 20px;
	padding-bottom: 30px;
}

.video-details__stack
{
	display: grid;
	gap: 18px;
}

.video-details__header,
.media-item-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
}


.video-details__title-wrap,
.media-item-header__text {
    min-width: 0;
    flex: 1 1 auto;
    display: flex;
    align-items: center;
	unicode-bidi: plaintext;
}

.video-details__fav,
.media-item-fav {
    flex: 0 0 auto;
    min-width: 0;
    height: 40px;
    min-height: 40px;
    padding: 0 12px;
    justify-content: center;
    align-self: center;
}

.video-details__fav.is-active,
.media-item-fav.is-active {
    border-color: rgba(255,255,255,0.22);
    background: linear-gradient(135deg, rgba(255,125,178,0.16), rgba(124,108,255,0.14));
}

.video-details__fav.is-active .material-icons,
.media-item-fav.is-active .material-icons {
    color: #ff7db2;
}

@media (max-width: 767px)
{
    .video-details__header,
    .media-item-header
	{
        flex-direction: row;
        align-items: flex-start;
    }
	
    html[dir="ltr"] .video-details__header,
    html[dir="ltr"] .media-item-header {
        flex-direction: row;
    }
	
    .video-details__header,
    .media-item-header {
        flex-direction: row;
        align-items: center;
    }

    html[dir="ltr"] .video-details__header,
    html[dir="ltr"] .media-item-header {
        flex-direction: row;
    }

    .video-details__fav,
    .media-item-fav {
        width: 40px;
        min-width: 40px;
        padding: 0;
    }

    .video-details__fav .btn-icon-text__label,
    .media-item-fav .btn-icon-text__label {
        display: none;
    }

    .video-details__fav .btn-icon-text__icon,
    .media-item-fav .btn-icon-text__icon {
        font-size: 22px;
        margin: 0;
    }
}

.video-details__title,
.media-item-title {
    margin: 0;
	font-size: clamp(1.35rem, 2vw, 1.9rem);
	line-height: 1.35;
	font-weight: 900;
	color: var(--text-main);
	unicode-bidi: plaintext;
}

.video-details__meta
{
	display: flex;
	flex-wrap: wrap;
	gap: 8px;
	margin-top: 10px;
}

.video-details__meta-chip
{
	min-height: 32px;
	padding: 0 12px;
	display: inline-flex;
	align-items: center;
	border-radius: 999px;
	background: rgba(255,255,255,0.06);
	border: 1px solid var(--border-soft);
	color: var(--text-muted);
	font-size: 0.78rem;
	font-weight: 800;
}

.video-details__fav.is-active
{
	border-color: var(--border-strong);
	background: rgba(255,255,255,0.10);
}

.video-details__desc-card
{
	padding: 16px 18px;
	background: var(--bg-panel);
	border: 1px solid var(--border-soft);
	border-radius: var(--radius-xl);
	box-shadow: var(--shadow-sm);
}

.video-details__section-title
{
	margin: 0 0 8px;
	font-size: 0.98rem;
	font-weight: 900;
	color: var(--text-main);
	unicode-bidi: plaintext;
}

.video-details__desc-body
{
	color: var(--text-soft);
	line-height: 1.9;
	font-size: 0.94rem;
}

.video-shelf {
    display: grid;
    gap: 14px;
}

.video-shelf__head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}

.video-shelf__title {
    margin: 0;
    font-size: 1rem;
    font-weight: 900;
    color: var(--text-main);
	unicode-bidi: plaintext;
}

.video-shelf__grid {
    display: grid;
    gap: 14px;
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.video-shelf__item {
    display: block;
    overflow: hidden;
    border-radius: var(--radius-lg);
    background: var(--bg-panel);
    border: 1px solid var(--border-soft);
    box-shadow: var(--shadow-sm);
    transition:
        transform var(--transition-fast),
        border-color var(--transition-fast),
        box-shadow var(--transition-fast);
}

.video-shelf__item:hover,
.video-shelf__item:focus-visible {
    transform: translateY(-2px);
    border-color: var(--border-strong);
    box-shadow: var(--shadow-md);
    outline: none;
}

.video-shelf__thumb {
    aspect-ratio: 16 / 9;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    background-color: rgba(255,255,255,0.06);
}

.video-shelf__body {
    padding: 10px 12px 12px;
}

.video-shelf__item-title {
    margin: 0;
    font-size: 0.9rem;
    line-height: 1.5;
    font-weight: 800;
    color: var(--text-main);
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
	unicode-bidi: plaintext;
}

@media (min-width: 768px) {
    .video-shelf__grid {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }
}

@media (min-width: 1100px) {
    .video-shelf__grid {
        grid-template-columns: repeat(4, minmax(0, 1fr));
    }
}

.media-item-page {
    padding-top: 22px;
    padding-bottom: 30px;
}

.media-item-stack {
    display: grid;
    gap: 20px;
}

.media-item-main {
    background: var(--bg-panel);
    border: 1px solid var(--border-soft);
    border-radius: var(--radius-xl);
    box-shadow: var(--shadow-md);
    padding: 18px;
}

.media-item-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    margin-bottom: 18px;
}

.media-item-header__text {
    min-width: 0;
    flex: 1 1 auto;
    display: flex;
    align-items: center;
}

.media-item-title {
    margin: 0;
    font-size: clamp(1.35rem, 2vw, 1.9rem);
    line-height: 1.3;
    font-weight: 900;
    color: var(--text-main);
	unicode-bidi: plaintext;
}

.media-item-fav {
    flex: 0 0 auto;
    min-width: 0;
    height: 40px;
    min-height: 40px;
    padding: 0 12px;
    justify-content: center;
    align-self: center;
}

.media-item-fav.is-active {
    border-color: rgba(255,255,255,0.22);
    background: linear-gradient(135deg, rgba(255,125,178,0.16), rgba(124,108,255,0.14));
}

.media-item-fav.is-active .material-icons {
    color: #ff7db2;
}

.media-panel {
    border-radius: calc(var(--radius-xl) - 6px);
    overflow: hidden;
    background: rgba(255,255,255,0.04);
    border: 1px solid var(--border-soft);
    min-height: 320px;
}

.item-frame {
    display: grid;
    place-items: center;
    min-height: 420px;
    padding: 18px;
    background:
        radial-gradient(circle at top left, rgba(255,255,255,0.05), transparent 24%),
        rgba(0,0,0,0.18);
}

.item-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    justify-content: center;
    padding: 0 18px 18px;
	margin-top: 18px;
}

.item-actions-btn
{
	width: 100%;
}

@media (max-width: 767px)
{
    .item-actions
	{
        padding: 0 12px 12px;
    }
	
    .item-actions .btn
	{
        width: 100%;
    }
}

.item-image {
    display: block;
    max-width: 100%;
    max-height: 72vh;
    width: auto;
    height: auto;
    object-fit: contain;
    border-radius: calc(var(--radius-lg) - 2px);
    box-shadow: var(--shadow-sm);
}

.audio-panel,
.apk-panel {
    display: grid;
    gap: 16px;
    padding: 18px;
}

.audio-panel__cover-wrap,
.apk-panel__media {
    overflow: hidden;
    border-radius: var(--radius-lg);
    background: rgba(255,255,255,0.05);
    border: 1px solid var(--border-soft);
}

.audio-panel__cover,
.apk-panel__image {
    display: block;
    width: 100%;
    max-height: 420px;
    object-fit: contain;
}

.audio-panel__player-wrap {
    border-radius: var(--radius-lg);
    background: rgba(255,255,255,0.05);
    border: 1px solid var(--border-soft);
    padding: 14px;
}

.audio-panel__player {
    width: 100%;
}

.apk-panel__content
{
    display: grid;
    gap: 14px;
}

.apk-panel__info {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.apk-panel__chip {
    min-height: 32px;
    padding: 0 12px;
    display: inline-flex;
    align-items: center;
    border-radius: 999px;
    background: rgba(255,255,255,0.06);
    border: 1px solid var(--border-soft);
    color: var(--text-muted);
    font-size: 0.78rem;
    font-weight: 800;
}

.text-reader {
    padding: 22px;
    color: var(--text-main);
    line-height: 2;
    font-size: 1rem;
    white-space: pre-wrap;
    word-break: break-word;
}

.game-shell {
    position: relative;
    width: 100%;
    aspect-ratio: 16 / 9;
    background: #000;
}

.game-shell__frame {
    width: 100%;
    height: 100%;
    border: 0;
    display: block;
}

.media-item-desc {
    margin-top: 18px;
    padding-top: 18px;
    border-top: 1px solid var(--border-soft);
}

.media-item-desc__title {
    margin: 0 0 10px;
    font-size: 1rem;
    font-weight: 900;
    color: var(--text-main);
	unicode-bidi: plaintext;
}

.media-item-desc__body {
    color: var(--text-soft);
    line-height: 1.95;
    font-size: 0.95rem;
}

.media-next {
    position: relative;
    margin-top: 8px;
    padding-top: 24px;
}

.media-next::before {
    content: "";
    position: absolute;
    top: 0;
    right: 0;
    left: 0;
    height: 1px;
    background: linear-gradient(
        to left,
        transparent,
        rgba(255,255,255,0.16),
        transparent
    );
}

.media-next__head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 14px;
}

.media-next__title {
    margin: 0;
    font-size: 1rem;
    font-weight: 900;
    color: var(--text-main);
	unicode-bidi: plaintext;
}

.media-next__grid {
    display: grid;
    gap: 14px;
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.media-next__item {
    display: block;
    overflow: hidden;
    border-radius: var(--radius-lg);
    background: var(--bg-panel);
    border: 1px solid var(--border-soft);
    box-shadow: var(--shadow-sm);
    transition:
        transform var(--transition-fast),
        border-color var(--transition-fast),
        box-shadow var(--transition-fast);
}

.media-next__item:hover,
.media-next__item:focus-visible {
    transform: translateY(-2px);
    border-color: var(--border-strong);
    box-shadow: var(--shadow-md);
    outline: none;
}

.media-next__thumb {
    aspect-ratio: 16 / 9;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    background-color: rgba(255,255,255,0.06);
}

.media-next__body {
    padding: 10px 12px 12px;
}

.media-next__item-title {
    margin: 0;
    font-size: 0.9rem;
    line-height: 1.5;
    font-weight: 800;
    color: var(--text-main);
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
	unicode-bidi: plaintext;
}

.video-shelf,
.media-item-side__card
{
    position: relative;
    margin-top: 8px;
    padding-top: 22px;
}

.video-shelf::before,
.media-item-side__card::before
{
    content: "";
    position: absolute;
    top: 0;
    right: 0;
    left: 0;
    height: 1px;
    background: linear-gradient(
        to left,
        transparent,
        rgba(255,255,255,0.16),
        transparent
    );
}

@media (min-width: 768px) {
    .media-next__grid {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }
}

@media (min-width: 1100px) {
    .media-next__grid {
        grid-template-columns: repeat(4, minmax(0, 1fr));
    }
}

@media (max-width: 767px) {
    .media-item-main {
        padding: 14px;
    }

    .media-item-header {
        flex-direction: row;
        align-items: center;
    }

    html[dir="ltr"] .media-item-header {
        flex-direction: row;
    }
	
	.apk-panel__info
	{
		justify-content: center;
	}

    .media-item-fav {
        width: 40px;
        min-width: 40px;
        padding: 0;
    }

    .media-item-fav .btn-icon-text__label {
        display: none;
    }

    .media-item-fav .btn-icon-text__icon {
        font-size: 22px;
        margin: 0;
    }

    .item-frame {
        min-height: 280px;
        padding: 12px;
    }

    .text-reader {
        padding: 16px;
    }
}

.page-loader {
    position: fixed;
    inset: 0;
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(16, 19, 31, 0.88);
    backdrop-filter: blur(6px);
    opacity: 1;
    visibility: visible;
    transition:
        opacity 220ms ease,
        visibility 220ms ease;
}

.page-loader.is-hidden {
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
}

.is-hidden {
	display: none;
}

.page-loader__box {
    display: grid;
    gap: 12px;
    justify-items: center;
    padding: 20px 24px;
    border-radius: 20px;
    background: var(--bg-panel);
    border: 1px solid var(--border-soft);
    box-shadow: 0 12px 28px rgba(0, 0, 0, 0.22);
}

.page-loader__spinner {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    border: 3px solid rgba(255, 255, 255, 0.12);
    border-top-color: var(--primary);
    animation: pageLoaderSpin 0.8s linear infinite;
}

.page-loader__text {
    color: var(--text-main);
    font-size: 0.92rem;
    font-weight: 800;
    line-height: 1.2;
}

@keyframes pageLoaderSpin {
    to {
        transform: rotate(360deg);
    }
}


.page-shell {
    padding: 22px 0 30px;
}

.panel {
    background: var(--bg-panel);
    border: 1px solid var(--border-soft);
    border-radius: var(--radius-xl);
    box-shadow: var(--shadow-md);
}

.center-panel {
    margin-inline: auto;
    padding: 22px;
    text-align: center;
}

.page-title {
    margin: 0;
    font-size: clamp(1.5rem, 2vw, 2.15rem);
    line-height: 1.3;
    font-weight: 900;
    color: var(--text-main);
}

.page-subtitle {
    margin: 12px auto 0;
    max-width: 58ch;
    color: var(--text-soft);
    line-height: 1.95;
    font-size: 1.2rem;
}

.page-desc {
    margin: 12px auto 0;
    max-width: 58ch;
    color: var(--text-soft);
    line-height: 1.95;
    font-size: 0.96rem;
}

.actions {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    justify-content: center;
    margin-top: 22px;
}

.hero-icon {
    width: 76px;
    height: 76px;
    margin: 0 auto 16px;
    border-radius: 24px;
    display: grid;
    place-items: center;
    font-size: 2rem;
    background: linear-gradient(135deg, rgba(124,108,255,0.18), rgba(255,125,178,0.14));
    border: 1px solid var(--border-soft);
    box-shadow: var(--shadow-sm);
}

.list-grid {
    display: grid;
    gap: 14px;
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.media-card__thumb {
    aspect-ratio: 16 / 9;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    background-color: rgba(255,255,255,0.06);
}

.section-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 14px;
}

.section-title {
    margin: 0;
    font-size: 1.08rem;
    font-weight: 900;
    color: var(--text-main);
}

.info-table {
    display: grid;
    gap: 10px;
}

.info-row {
    display: grid;
    grid-template-columns: 160px 1fr;
    gap: 14px;
    padding: 12px 14px;
    border-radius: var(--radius-md);
    background: rgba(255,255,255,0.04);
    border: 1px solid var(--border-soft);
}

.info-row__key {
    color: var(--text-muted);
    font-weight: 800;
}

.info-row__value {
    color: var(--text-main);
    font-weight: 900;
    min-width: 0;
    word-break: break-word;
}

.empty-state {
    padding: 26px 18px;
    text-align: center;
    color: var(--text-soft);
    border: 1px dashed var(--border-soft);
    border-radius: var(--radius-lg);
    background: rgba(255,255,255,0.03);
}

.portal-modal__actions {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    justify-content: flex-end;
    padding: 0 18px 18px;
}

@media (min-width: 768px) {
    .list-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
@media (min-width: 1100px) {
    .list-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); }
}
@media (max-width: 767px) {
    .center-panel { padding: 18px 16px; }
    .list-grid { grid-template-columns: 1fr; }
    .info-row { grid-template-columns: 1fr; gap: 8px; }
    .portal-modal__actions { justify-content: stretch; }
    .portal-modal__actions .btn { width: 100%; }
}

.fav-toggle-btn {
    position: absolute;
    top: 10px;
    left: 10px; /* RTL: left, LTR: right if needed */

    width: 38px;
    height: 38px;

    display: grid;
    place-items: center;

    border-radius: 50%;
    border: 1px solid rgba(255,255,255,0.12);

    background: rgba(16,19,31,0.6);
    backdrop-filter: blur(6px);

    color: #fff;
    cursor: pointer;

    z-index: 2;

    transition: all 160ms ease;
}

.fav-toggle-btn:hover {
    transform: scale(1.08);
}

.fav-toggle-btn .material-icons {
    font-size: 20px;
}

/* Active (favorite) */
.fav-toggle-btn.is-active {
    background: rgba(255,125,178,0.15);
    border-color: rgba(255,125,178,0.35);
}

.fav-toggle-btn.is-active .material-icons {
    color: #ff7db2;
}

/* LTR support */
html[dir="ltr"] .fav-toggle-btn {
    right: 10px;
    left: auto;
}

/* parent must already be position: relative */
.media-card {
    position: relative;
}

/* remove button */
.fav-remove-btn {
    position: absolute;
    top: 10px;
    left: 10px; /* RTL default */

    width: 36px;
    height: 36px;

    display: grid;
    place-items: center;

    border-radius: 50%;
    border: 1px solid rgba(255,255,255,0.12);

    background: rgba(16,19,31,0.65);
    backdrop-filter: blur(6px);

    color: rgba(255,255,255,0.85);

    cursor: pointer;
    z-index: 2;

    transition:
        transform 160ms ease,
        background 160ms ease,
        border-color 160ms ease,
        color 160ms ease;
}

/* icon size */
.fav-remove-btn .material-icons {
    font-size: 18px;
}

/* hover */
.fav-remove-btn:hover {
    transform: scale(1.08);
    background: rgba(239,107,107,0.15);
    border-color: rgba(239,107,107,0.4);
    color: #ef6b6b;
}

/* active click */
.fav-remove-btn:active {
    transform: scale(0.95);
}

/* LTR support */
html[dir="ltr"] .fav-remove-btn {
    right: 10px;
    left: auto;
}

.fav-remove-btn::after {
    content: "إزالة";
    position: absolute;
    bottom: -26px;
    left: 50%;
    transform: translateX(-50%);
    font-size: 0.7rem;
    background: rgba(0,0,0,0.7);
    padding: 3px 8px;
    border-radius: 6px;
    opacity: 0;
    pointer-events: none;
    transition: opacity 120ms ease;
}

.fav-remove-btn:hover::after {
    opacity: 1;
}

.download-container {
	margin: 0;
	min-height: 100vh;
	display: grid;
	place-items: center;
	font-family: Cairo, system-ui, sans-serif;
	background: #10131f;
	color: #f5f7ff;
}
.download-box {
	width: min(100% - 32px, 520px);
	padding: 24px;
	text-align: center;
	border-radius: 24px;
	background: #1d2237;
	border: 1px solid rgba(255,255,255,0.08);
	box-shadow: 0 12px 28px rgba(0,0,0,0.22);
}

.download-spinner {
	width: 48px;
	height: 48px;
	margin: 0 auto 16px;
	border-radius: 50%;
	border: 3px solid rgba(255,255,255,0.15);
	border-top-color: #7c6cff;
	animation: spin .8s linear infinite;
}

.download-title {
	margin: 0;
	font-size: 1.25rem;
	font-weight: 900;
}

.download-desc {
	margin: 10px 0 0;
	color: #d9ddf0;
	line-height: 1.9;
	font-size: .95rem;
}

@keyframes spin {
	to { transform: rotate(360deg); }
}

.download-iframe {
	display: none;
}