.filmparty-home {
    min-height: 100vh;
    padding-bottom: 90px;
}

/* Base topbar shell: shell-layout.css — home only overrides scroll/hero states below */

.topbar-right,
.topbar-left {
    display: flex;
    align-items: center;
    gap: 14px;
}

.desktop-menu-btn,
.search-open-btn {
    width: 42px;
    height: 42px;
    border: none;
    border-radius: 16px;
    cursor: pointer;
    color: white;
    background: rgba(255,255,255,0.08);
    border: 1px solid rgba(255,255,255,0.1);
}

.brand-small {
    direction: ltr;
    font-size: 22px;
    font-weight: 900;
    letter-spacing: 1px;
}

.brand-small span {
    color: #ff4d67;
    text-shadow: 0 0 14px rgba(255,77,103,.6);
}

.brand-small b {
    color: #57a1ff;
    text-shadow: 0 0 14px rgba(87,161,255,.6);
}

.hero-banner-stage {
    position: relative;
    height: 520px;
    overflow: hidden;
    border-radius: 0 0 36px 36px;
    background: #050b14;
}

.hero-banner-track {
    position: relative;
    width: 100%;
    height: 100%;
}

.hero-banner-slide {
    position: absolute;
    inset: 0;
    opacity: 0;
    transform: scale(1.02);
    transition: opacity .7s ease, transform 1.2s ease;
}

.hero-banner-slide.active {
    opacity: 1;
    transform: scale(1);
}

.hero-banner-slide img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.hero-vignette {
    position: absolute;
    inset: 0;
    background:
        linear-gradient(to bottom, rgba(7,17,31,.65), transparent 28%, var(--bg-main) 100%),
        linear-gradient(to left, rgba(7,17,31,.1), rgba(7,17,31,.85));
}

.hero-content {
    position: absolute;
    right: max(24px, calc((100vw - 1180px) / 2));
    bottom: 72px;
    width: min(90%, 560px);
    opacity: 1;
    transition: opacity .28s ease;
}

.hero-content.hero-content--pending {
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
}

.hero-banner-slide:not(.is-banner-ready) .hero-content {
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
}

.hero-pill {
    display: none;
}

.hero-content h1 {
    margin: 0 0 12px;
    font-size: clamp(32px, 5vw, 58px);
    line-height: 1.25;
    text-shadow: 0 10px 30px rgba(0,0,0,.7);
}

.hero-content p {
    color: var(--text-soft);
    line-height: 2;
    margin: 0 0 22px;
    max-width: 460px;
}

.hero-action-btn {
    display: inline-flex;
    min-height: 48px;
    align-items: center;
    justify-content: center;
    padding: 0 22px;
    border-radius: 17px;
    background: linear-gradient(135deg, rgba(47,123,255,.9), rgba(87,161,255,.85));
    color: white;
    font-weight: 900;
    box-shadow: 0 14px 35px rgba(47,123,255,.3);
}

.hero-dots {
    position: absolute;
    bottom: 26px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 8px;
    z-index: 3;
}

.hero-dots button {
    width: 8px;
    height: 8px;
    border: none;
    border-radius: 999px;
    background: rgba(255,255,255,.35);
    cursor: pointer;
    transition: .25s;
}

.hero-dots button.active {
    width: 28px;
    background: #57a1ff;
    box-shadow: 0 0 16px rgba(87,161,255,.8);
}

.home-content {
    width: min(100%, 1220px);
    margin: 0 auto;
    padding: 34px 18px;
}

.cinema-section {
    margin-bottom: 46px;
}

.section-heading {
    display: flex;
    align-items: end;
    justify-content: space-between;
    gap: 20px;
    margin-bottom: 18px;
}

.section-kicker {
    color: #79b4ff;
    font-size: 12px;
    font-weight: 900;
    letter-spacing: 1.5px;
}

.section-heading h2 {
    margin: 6px 0 0;
    font-size: 25px;
}

.section-heading p {
    margin: 0;
    color: var(--text-soft);
    line-height: 1.8;
    font-size: 14px;
}

.recent-carousel-shell {
    position: relative;
}

.poster-carousel {
    display: flex;
    align-items: flex-start;
    gap: 16px;
    overflow-x: auto;
    padding: 10px 4px 18px;
    scroll-snap-type: x mandatory;
    scrollbar-width: none;
    --fp-poster-card-width: 168px;
}

.poster-carousel::-webkit-scrollbar {
    display: none;
}

/* پرطرفدارترین‌های هفته: عرض ثابت — جلوگیری از بزرگ‌شدن کارت به‌خاطر min-width:auto و img 340px */
.poster-carousel .movie-card-pro {
    flex: 0 0 var(--fp-poster-card-width);
    width: var(--fp-poster-card-width);
    min-width: 0;
    max-width: var(--fp-poster-card-width);
    scroll-snap-align: center;
}

.poster-carousel .movie-poster-wrap {
    width: 100%;
}

.poster-carousel .movie-poster-link {
    display: block;
    width: 100%;
    height: 100%;
}

.poster-carousel .movie-poster-wrap img {
    display: block;
    width: 100%;
    height: 100%;
    max-width: 100%;
    object-fit: cover;
    object-position: center center;
}

.movie-card-pro {
    flex: 0 0 168px;
    scroll-snap-align: center;
    transition: transform .28s ease, opacity .28s ease;
}

.recent-carousel .movie-card-pro:nth-child(3) {
    transform: scale(1.12);
}

.movie-card-link {
    display: block;
}

.movie-poster-wrap {
    position: relative;
    aspect-ratio: 2 / 3;
    border-radius: 22px;
    overflow: hidden;
    background: var(--glass-fill);
    border: 1px solid var(--glass-border-neutral);
    box-shadow:
        0 18px 42px rgba(0, 0, 0, 0.28),
        inset 0 0 0 1px var(--glass-rim);
}

.movie-poster-wrap img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform .35s ease, filter .35s ease;
}

.movie-card-pro:hover img {
    transform: scale(1.06);
    filter: brightness(.78);
}

.movie-card-shine {
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, rgba(255,255,255,.18), transparent 40%);
    opacity: 0;
    transition: .3s;
}

.movie-card-pro:hover .movie-card-shine {
    opacity: 1;
}

.wishlist-heart {
    position: absolute;
    top: 10px;
    left: 10px;
    width: 34px;
    height: 34px;
    border: none;
    border-radius: 14px;
    cursor: pointer;
    color: rgba(255,255,255,.75);
    background: rgba(0,0,0,.36);
    backdrop-filter: blur(14px);
    border: 1px solid rgba(255,255,255,.16);
    opacity: 0;
    transform: translateY(-6px);
    transition: .25s ease;
}

.movie-card-pro:hover .wishlist-heart {
    opacity: 1;
    transform: translateY(0);
}

.wishlist-heart.active {
    color: #ff4d67;
    box-shadow: 0 0 20px rgba(255,77,103,.35);
}

.movie-card-meta {
    padding: 11px 4px 0;
}

.movie-card-meta h3 {
    margin: 0 0 7px;
    font-size: 14px;
    line-height: 1.6;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.movie-card-info {
    display: flex;
    gap: 7px;
    flex-wrap: wrap;
    color: var(--text-soft);
    font-size: 11px;
}

.movie-card-info span {
    padding: 4px 7px;
    border-radius: 999px;
    background: var(--glass-fill);
    border: 1px solid var(--glass-border-cool);
}

.movie-card-info .movie-card-imdb-chip {
    padding: 2px 6px;
    font-size: 10px;
    font-weight: 600;
    letter-spacing: 0.02em;
    color: rgba(236, 228, 205, 0.88);
    background:
        radial-gradient(circle at 22% 8%, rgba(255, 255, 255, 0.16), transparent 46%),
        linear-gradient(155deg, rgba(250, 204, 21, 0.09), rgba(120, 90, 30, 0.05));
    border: 1px solid rgba(255, 255, 255, 0.11);
    backdrop-filter: blur(14px) saturate(1.15);
    -webkit-backdrop-filter: blur(14px) saturate(1.15);
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.14),
        inset 0 -0.5px 0 rgba(0, 0, 0, 0.06),
        0 2px 5px rgba(0, 0, 0, 0.08);
}

.carousel-nav {
    position: absolute;
    top: 40%;
    transform: translateY(-50%);
    z-index: 5;
    width: 42px;
    height: 58px;
    border: none;
    border-radius: 18px;
    color: white;
    cursor: pointer;
    background: var(--glass-fill-strong);
    border: 1px solid var(--glass-border-neutral);
    backdrop-filter: blur(20px);
    font-size: 34px;
    box-shadow: var(--glass-accent-rim);
}

.carousel-nav.prev {
    right: -8px;
}

.carousel-nav.next {
    left: -8px;
}

.empty-glass-box {
    padding: 28px;
    border-radius: 24px;
    background: var(--glass-fill);
    border: 1px solid var(--glass-border-neutral);
    color: var(--text-soft);
    text-align: center;
}

.mobile-bottom-nav {
    position: fixed;
    bottom: 12px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 60;
    width: min(94%, 480px);
    height: 66px;
    display: none;
    align-items: stretch;
    justify-content: space-between;
    padding: 0 10px;
    border-radius: 26px;
    background: var(--glass-fill);
    border: 1px solid var(--glass-border-neutral);
    backdrop-filter: blur(20px) saturate(1.06);
    -webkit-backdrop-filter: blur(20px) saturate(1.06);
    box-shadow:
        0 10px 28px rgba(0, 0, 0, 0.16),
        inset 0 1px 0 var(--glass-highlight),
        var(--glass-accent-rim);
}

@media (max-width: 768px) {
    .desktop-menu-btn {
        display: none;
    }

    .topbar-glass {
        border-radius: 20px;
    }

    .hero-banner-stage {
        height: 420px;
        border-radius: 0 0 28px 28px;
    }

    .hero-content {
        right: 22px;
        bottom: 64px;
    }

    .section-heading {
        display: block;
    }

    .section-heading p {
        margin-top: 8px;
    }

    .movie-card-pro {
        flex-basis: 136px;
    }

    .poster-carousel {
        --fp-poster-card-width: 136px;
    }

    .recent-carousel .movie-card-pro:nth-child(3) {
        transform: none;
    }

    .carousel-nav {
        display: none;
    }

    .mobile-bottom-nav {
        display: flex;
    }
}
.recent-carousel {
    padding-top: 34px;
    padding-bottom: 34px;
    align-items: center;
}

.recent-carousel .movie-card-pro {
    flex-basis: 150px;
    opacity: .82;
    transform-origin: center center;
}

.recent-carousel .movie-card-pro:nth-child(3) {
    flex-basis: 188px;
    transform: scale(1.08);
    opacity: 1;
    z-index: 3;
}

.recent-carousel .movie-card-pro:nth-child(2),
.recent-carousel .movie-card-pro:nth-child(4) {
    flex-basis: 142px;
    transform: scale(.94);
    opacity: .9;
}

.recent-carousel .movie-poster-wrap {
    overflow: hidden;
}

@media (max-width: 768px) {
    .recent-carousel {
        padding-top: 24px;
        padding-bottom: 28px;
    }

    .recent-carousel .movie-card-pro {
        flex-basis: 118px;
    }

    .recent-carousel .movie-card-pro:nth-child(3) {
        flex-basis: 148px;
        transform: scale(1.04);
    }

    .recent-carousel .movie-card-pro:nth-child(2),
    .recent-carousel .movie-card-pro:nth-child(4) {
        flex-basis: 112px;
        transform: scale(.93);
    }
}
.movie-poster-link {
    display: block;
    width: 100%;
    height: 100%;
}

.movie-card-actions {
    position: absolute;
    top: 10px;
    left: 10px;
    display: grid;
    gap: 7px;
    z-index: 4;
}

.wishlist-heart,
.public-eye-btn {
    width: 36px;
    height: 36px;
    border: none;
    border-radius: 14px;
    cursor: pointer;
    color: rgba(255,255,255,.78);
    background: rgba(0,0,0,.42);
    backdrop-filter: blur(14px);
    border: 1px solid rgba(255,255,255,.17);
    opacity: 0;
    transform: translateY(-6px);
    transition: .25s ease;
}

.movie-card-pro:hover .wishlist-heart,
.movie-card-pro:hover .public-eye-btn {
    opacity: 1;
    transform: translateY(0);
}

.wishlist-heart.active {
    opacity: 1;
    color: #ff4d67;
    box-shadow: 0 0 20px rgba(255,77,103,.35);
}

.public-eye-btn.active {
    opacity: 1;
    color: #9cc7ff;
    box-shadow: 0 0 20px rgba(87,161,255,.35);
}

.wishlist-heart:disabled,
.public-eye-btn:disabled {
    opacity: .55;
    cursor: wait;
}

.filmparty-toast {
    position: fixed;
    right: 50%;
    bottom: 26px;
    transform: translateX(50%) translateY(20px);
    z-index: 999;
    min-width: 220px;
    max-width: min(92vw, 420px);
    padding: 13px 18px;
    border-radius: 18px;
    background: rgba(255,255,255,.1);
    border: 1px solid rgba(255,255,255,.16);
    backdrop-filter: blur(24px);
    color: white;
    text-align: center;
    box-shadow: 0 18px 60px rgba(0,0,0,.35);
    opacity: 0;
    pointer-events: none;
    transition: .25s ease;
}

.filmparty-toast.show {
    opacity: 1;
    transform: translateX(50%) translateY(0);
}

@media (max-width: 768px) {
    .wishlist-heart,
    .public-eye-btn {
        opacity: 1;
        transform: none;
    }
}
.movie-card-actions {
    position: absolute;
    top: 10px;
    left: 10px;
    display: grid;
    gap: 7px;
    z-index: 4;
}

.wishlist-heart {
    width: 38px;
    height: 38px;
    border: none;
    border-radius: 15px;
    cursor: pointer;
    color: rgba(255,255,255,.9);
    background: rgba(0,0,0,.42);
    backdrop-filter: blur(14px);
    border: 1px solid rgba(255,255,255,.18);
    opacity: 0;
    transform: translateY(-6px);
    transition: .25s ease;
    font-size: 24px;
    line-height: 1;
}

.movie-card-pro:hover .wishlist-heart {
    opacity: 1;
    transform: translateY(0);
}

.wishlist-heart.active {
    opacity: 1;
    color: #ff4d67;
    background: rgba(var(--fp-brand-rgb),.16);
    border-color: rgba(255,77,103,.36);
    box-shadow: 0 0 20px rgba(255,77,103,.35);
}

.wishlist-heart:disabled {
    opacity: .55;
    cursor: wait;
}

@media (max-width: 768px) {
    .wishlist-heart {
        opacity: 1;
        transform: none;
    }
}
.wishlist-heart {
    display: grid;
    place-items: center;
    font-size: 0 !important;
}

.wishlist-heart .fp-icon {
    width: 22px;
    height: 22px;
    flex-basis: 22px;
}

.wishlist-heart.active {
    color: #ff4d67;
}
.fp-home-stage {
    --hero-bg: none;
    position: relative;
    min-height: 720px;
    display: grid;
    align-items: end;
    overflow: hidden;
    border-radius: 0 0 46px 46px;
    margin: -1px auto 34px;
    isolation: isolate;
    background: var(--bg-main);
}

.fp-home-stage::before {
    content: "";
    position: absolute;
    inset: 0;
    z-index: -5;
    background-image: var(--hero-bg);
    background-size: cover;
    background-position: center 18%;
    filter: saturate(1.05);
    transform: scale(1.04);
    transition: background-image .45s ease, transform .8s ease;
}

.fp-hero-layer {
    position: absolute;
    inset: 0;
    z-index: -4;
    background:
        radial-gradient(circle at 50% 38%, rgba(47,123,255,.20), transparent 26%),
        linear-gradient(90deg, rgba(7,17,31,.98) 0%, rgba(7,17,31,.76) 38%, rgba(7,17,31,.34) 100%),
        linear-gradient(180deg, rgba(7,17,31,.22) 0%, rgba(7,17,31,.82) 72%, var(--bg-main) 100%);
}

.fp-hero-noise {
    position: absolute;
    inset: 0;
    z-index: -3;
    pointer-events: none;
    background:
        radial-gradient(circle at 18% 16%, rgba(var(--fp-brand-rgb),.16), transparent 28%),
        radial-gradient(circle at 82% 12%, rgba(47,123,255,.18), transparent 26%);
}

.fp-home-hero-content {
    position: absolute;
    top: 150px;
    right: max(22px, calc((100vw - 1180px) / 2));
    z-index: 5;
    width: min(92vw, 580px);
}

.fp-hero-kicker {
    display: inline-flex;
    align-items: center;
    min-height: 30px;
    padding: 0 11px;
    border-radius: 999px;
    color: #cfe5ff;
    background: rgba(47,123,255,.15);
    border: 1px solid rgba(87,161,255,.28);
    font-size: 11px;
    font-weight: 950;
    letter-spacing: 1.5px;
    margin-bottom: 14px;
}

.fp-home-hero-content h1 {
    margin: 0 0 14px;
    color: white;
    font-size: clamp(38px, 6vw, 76px);
    line-height: 1.12;
    font-weight: 950;
    letter-spacing: -1.5px;
    text-shadow: 0 18px 60px rgba(0,0,0,.5);
}

.fp-home-hero-content p {
    max-width: 540px;
    margin: 0;
    color: rgba(235,244,255,.78);
    line-height: 2;
    font-size: 15px;
}

.fp-hero-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin: 18px 0;
}

.fp-hero-meta span {
    min-height: 34px;
    display: inline-flex;
    align-items: center;
    padding: 0 11px;
    border-radius: 999px;
    color: white;
    background: rgba(255,255,255,.08);
    border: 1px solid rgba(255,255,255,.13);
    backdrop-filter: blur(18px);
    font-size: 12px;
    font-weight: 900;
}

.fp-hero-link {
    min-height: 48px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0 19px;
    border-radius: 17px;
    color: white;
    font-weight: 950;
    background: linear-gradient(135deg, #1f6fff, #3d95ff);
    box-shadow: 0 18px 44px rgba(47,123,255,.28);
}

.fp-recent-center-wrap {
    position: relative;
    z-index: 10;
    width: min(100%, 1180px);
    height: 372px;
    margin: 0 auto 34px;
    display: grid;
    align-items: end;
    justify-items: center;
}

.fp-recent-title {
    position: absolute;
    top: 0;
    right: 22px;
    display: grid;
    gap: 4px;
    z-index: 12;
}

.fp-recent-title span {
    color: #79b4ff;
    font-size: 10px;
    font-weight: 950;
    letter-spacing: 1.4px;
}

.fp-recent-title strong {
    color: white;
    font-size: 20px;
}

.fp-recent-track {
    position: relative;
    width: 100%;
    height: 330px;
    margin: 0 auto;
    perspective: 1200px;
}

.fp-recent-card {
    position: absolute;
    left: 50%;
    bottom: 0;
    width: 176px;
    aspect-ratio: 2 / 3;
    border-radius: 26px;
    overflow: hidden;
    opacity: 0;
    transform: translateX(-50%) scale(.62);
    transition:
        transform .68s cubic-bezier(.2,.78,.2,1),
        opacity .45s ease,
        filter .45s ease,
        box-shadow .45s ease;
    background: rgba(255,255,255,.08);
    border: 1px solid rgba(255,255,255,.14);
    box-shadow: 0 20px 60px rgba(0,0,0,.35);
    filter: saturate(.72) brightness(.72);
    will-change: transform, opacity;
}

.fp-recent-card.is-visible {
    opacity: 1;
}

.fp-recent-card.pos-0 {
    z-index: 9;
    width: 230px;
    transform: translateX(-50%) translateY(-20px) scale(1);
    filter: saturate(1.08) brightness(1.04);
    box-shadow:
        0 34px 100px rgba(0,0,0,.52),
        0 0 0 1px rgba(87,161,255,.28),
        0 0 50px rgba(47,123,255,.24);
}

.fp-recent-card.pos-m1 {
    z-index: 7;
    transform: translateX(calc(-50% - 205px)) translateY(18px) scale(.82) rotateY(-8deg);
}

.fp-recent-card.pos-p1 {
    z-index: 7;
    transform: translateX(calc(-50% + 205px)) translateY(18px) scale(.82) rotateY(8deg);
}

.fp-recent-card.pos-m2 {
    z-index: 5;
    transform: translateX(calc(-50% - 370px)) translateY(42px) scale(.68) rotateY(-13deg);
}

.fp-recent-card.pos-p2 {
    z-index: 5;
    transform: translateX(calc(-50% + 370px)) translateY(42px) scale(.68) rotateY(13deg);
}

.fp-recent-card img {
    width: 100%;
    height: 100%;
    display: block;
    object-fit: cover;
    object-position: center center;
}

.fp-recent-card::after {
    content: "";
    position: absolute;
    inset: 0;
    background:
        linear-gradient(180deg, transparent 48%, rgba(0,0,0,.84) 100%),
        radial-gradient(circle at 50% 8%, rgba(255,255,255,.18), transparent 28%);
    pointer-events: none;
}

.fp-recent-card-info {
    position: absolute;
    right: 0;
    left: 0;
    bottom: 0;
    z-index: 3;
    padding: 14px;
    opacity: 0;
    transform: translateY(10px);
    transition: .35s ease;
}

.fp-recent-card.pos-0 .fp-recent-card-info {
    opacity: 1;
    transform: translateY(0);
}

.fp-recent-card-info strong {
    display: block;
    color: white;
    line-height: 1.55;
    font-size: 14px;
    font-weight: 950;
    text-shadow: 0 6px 22px rgba(0,0,0,.75);
}

.fp-recent-card-info span {
    display: block;
    margin-top: 4px;
    color: rgba(255,255,255,.68);
    font-size: 11px;
}

.fp-carousel-nav {
    position: absolute;
    top: 52%;
    z-index: 18;
    width: 46px;
    height: 46px;
    border: none;
    border-radius: 17px;
    cursor: pointer;
    color: white;
    background: var(--glass-fill-strong);
    border: 1px solid var(--glass-border-neutral);
    backdrop-filter: blur(22px);
    box-shadow:
        0 16px 48px rgba(0, 0, 0, 0.28),
        var(--glass-accent-rim);
}

.fp-carousel-nav.prev {
    right: 18px;
}

.fp-carousel-nav.next {
    left: 18px;
}

.fp-carousel-nav i {
    position: relative;
    width: 16px;
    height: 16px;
    display: inline-block;
}

.fp-carousel-nav i::before {
    content: "";
    position: absolute;
    inset: 0;
    border-top: 3px solid currentColor;
    border-right: 3px solid currentColor;
    border-radius: 2px;
}

.fp-carousel-nav.prev i::before {
    transform: rotate(45deg);
}

.fp-carousel-nav.next i::before {
    transform: rotate(-135deg);
}

.fp-carousel-nav:hover {
    background: rgba(47,123,255,.18);
    border-color: rgba(87,161,255,.34);
}

@media (max-width: 920px) {
    .fp-home-stage {
        min-height: 690px;
    }

    .fp-home-hero-content {
        top: 118px;
        right: 18px;
        left: 18px;
        width: auto;
    }

    .fp-home-hero-content h1 {
        font-size: clamp(32px, 10vw, 54px);
    }

    .fp-recent-center-wrap {
        height: 336px;
        margin-bottom: 24px;
    }

    .fp-recent-track {
        height: 292px;
    }

    .fp-recent-card {
        width: 140px;
        border-radius: 22px;
    }

    .fp-recent-card.pos-0 {
        width: 176px;
        transform: translateX(-50%) translateY(-16px) scale(1);
    }

    .fp-recent-card.pos-m1 {
        transform: translateX(calc(-50% - 145px)) translateY(26px) scale(.78) rotateY(-8deg);
    }

    .fp-recent-card.pos-p1 {
        transform: translateX(calc(-50% + 145px)) translateY(26px) scale(.78) rotateY(8deg);
    }

    .fp-recent-card.pos-m2,
    .fp-recent-card.pos-p2 {
        opacity: 0;
        pointer-events: none !important;
    }

    .fp-carousel-nav {
        top: auto;
        bottom: 118px;
        width: 42px;
        height: 42px;
    }

    .fp-carousel-nav.prev {
        right: 12px;
    }

    .fp-carousel-nav.next {
        left: 12px;
    }
}

@media (max-width: 520px) {
    .fp-home-stage {
        min-height: 650px;
        border-radius: 0 0 34px 34px;
    }

    .fp-home-stage::before {
        background-position: center top;
    }

    .fp-home-hero-content {
        top: 96px;
    }

    .fp-home-hero-content p {
        display: -webkit-box;
        -webkit-line-clamp: 2;
        -webkit-box-orient: vertical;
        overflow: hidden;
    }

    .fp-hero-meta {
        margin: 14px 0;
    }

    .fp-recent-title {
        right: 16px;
    }

    .fp-recent-center-wrap {
        height: 300px;
        margin-bottom: 18px;
    }

    .fp-recent-track {
        height: 262px;
    }

    .fp-recent-card {
        width: 118px;
        border-radius: 20px;
    }

    .fp-recent-card.pos-0 {
        width: 150px;
        transform: translateX(-50%) translateY(-12px) scale(1);
    }

    .fp-recent-card.pos-m1 {
        transform: translateX(calc(-50% - 112px)) translateY(25px) scale(.74) rotateY(-8deg);
    }

    .fp-recent-card.pos-p1 {
        transform: translateX(calc(-50% + 112px)) translateY(25px) scale(.74) rotateY(8deg);
    }

    .fp-recent-card-info {
        display: none;
    }
}
.home-recent-upgraded-section {
    width: min(100%, 1180px);
    margin: 34px auto;
    padding: 0 16px;
}

.home-recent-upgraded-wrap {
    position: relative;
    width: 100%;
    height: 350px;
    display: grid;
    place-items: center;
    overflow: hidden;
}

.recent-upgraded-track {
    position: relative;
    width: 100%;
    height: 330px;
    perspective: 1200px;
}

.recent-upgraded-card {
    position: absolute;
    left: 50%;
    bottom: 0;
    width: 170px;
    aspect-ratio: 2 / 3;
    border-radius: 26px;
    overflow: hidden;
    opacity: 0;
    transform: translateX(-50%) scale(.62);
    transition:
        transform .65s cubic-bezier(.2,.78,.2,1),
        opacity .35s ease,
        filter .35s ease,
        box-shadow .35s ease;
    background: rgba(255,255,255,.08);
    border: 1px solid rgba(255,255,255,.14);
    box-shadow: 0 20px 60px rgba(0,0,0,.34);
    filter: saturate(.72) brightness(.72);
}

.recent-upgraded-card.is-visible {
    opacity: 1;
}

.recent-upgraded-card.pos-0 {
    z-index: 9;
    width: 224px;
    transform: translateX(-50%) translateY(-18px) scale(1);
    filter: saturate(1.08) brightness(1.04);
    box-shadow:
        0 34px 100px rgba(0,0,0,.52),
        0 0 0 1px rgba(87,161,255,.28),
        0 0 48px rgba(47,123,255,.22);
}

.recent-upgraded-card.pos-m1 {
    z-index: 7;
    transform: translateX(calc(-50% - 205px)) translateY(20px) scale(.82) rotateY(-8deg);
}

.recent-upgraded-card.pos-p1 {
    z-index: 7;
    transform: translateX(calc(-50% + 205px)) translateY(20px) scale(.82) rotateY(8deg);
}

.recent-upgraded-card.pos-m2 {
    z-index: 5;
    transform: translateX(calc(-50% - 365px)) translateY(44px) scale(.68) rotateY(-13deg);
}

.recent-upgraded-card.pos-p2 {
    z-index: 5;
    transform: translateX(calc(-50% + 365px)) translateY(44px) scale(.68) rotateY(13deg);
}

.recent-upgraded-card img {
    width: 100%;
    height: 100%;
    display: block;
    object-fit: cover;
    object-position: center center;
}

.recent-upgraded-card::after {
    content: "";
    position: absolute;
    inset: 0;
    background:
        linear-gradient(180deg, transparent 48%, rgba(0,0,0,.84) 100%),
        radial-gradient(circle at 50% 8%, rgba(255,255,255,.18), transparent 28%);
    pointer-events: none;
}

.recent-upgraded-info {
    position: absolute;
    right: 0;
    left: 0;
    bottom: 0;
    z-index: 3;
    padding: 14px;
    opacity: 0;
    transform: translateY(10px);
    transition: .35s ease;
}

.recent-upgraded-card.pos-0 .recent-upgraded-info {
    opacity: 1;
    transform: translateY(0);
}

.recent-upgraded-info strong {
    display: block;
    color: white;
    line-height: 1.55;
    font-size: 14px;
    font-weight: 950;
    text-shadow: 0 6px 22px rgba(0,0,0,.75);
}

.recent-upgraded-info span {
    display: block;
    margin-top: 4px;
    color: rgba(255,255,255,.68);
    font-size: 11px;
}

.recent-upgraded-nav {
    position: absolute;
    top: 50%;
    z-index: 18;
    width: 44px;
    height: 44px;
    border: none;
    border-radius: 17px;
    cursor: pointer;
    color: white;
    background: rgba(255,255,255,.09);
    border: 1px solid rgba(255,255,255,.14);
    backdrop-filter: blur(22px);
    box-shadow: 0 16px 48px rgba(0,0,0,.28);
}

.recent-upgraded-nav.prev {
    right: 8px;
}

.recent-upgraded-nav.next {
    left: 8px;
}

.recent-upgraded-nav i {
    position: relative;
    width: 16px;
    height: 16px;
    display: inline-block;
}

.recent-upgraded-nav i::before {
    content: "";
    position: absolute;
    inset: 0;
    border-top: 3px solid currentColor;
    border-right: 3px solid currentColor;
    border-radius: 2px;
}

.recent-upgraded-nav.prev i::before {
    transform: rotate(45deg);
}

.recent-upgraded-nav.next i::before {
    transform: rotate(-135deg);
}

@media (max-width: 920px) {
    .home-recent-upgraded-wrap {
        height: 312px;
    }

    .recent-upgraded-track {
        height: 292px;
    }

    .recent-upgraded-card {
        width: 140px;
        border-radius: 22px;
    }

    .recent-upgraded-card.pos-0 {
        width: 176px;
        transform: translateX(-50%) translateY(-14px) scale(1);
    }

    .recent-upgraded-card.pos-m1 {
        transform: translateX(calc(-50% - 145px)) translateY(25px) scale(.78) rotateY(-8deg);
    }

    .recent-upgraded-card.pos-p1 {
        transform: translateX(calc(-50% + 145px)) translateY(25px) scale(.78) rotateY(8deg);
    }

    .recent-upgraded-card.pos-m2,
    .recent-upgraded-card.pos-p2 {
        opacity: 0;
        pointer-events: none !important;
    }
}

@media (max-width: 520px) {
    .home-recent-upgraded-section {
        margin: 24px auto;
        padding: 0 8px;
    }

    .home-recent-upgraded-wrap {
        height: 276px;
    }

    .recent-upgraded-track {
        height: 258px;
    }

    .recent-upgraded-card {
        width: 116px;
        border-radius: 20px;
    }

    .recent-upgraded-card.pos-0 {
        width: 150px;
        transform: translateX(-50%) translateY(-10px) scale(1);
    }

    .recent-upgraded-card.pos-m1 {
        transform: translateX(calc(-50% - 112px)) translateY(25px) scale(.74) rotateY(-8deg);
    }

    .recent-upgraded-card.pos-p1 {
        transform: translateX(calc(-50% + 112px)) translateY(25px) scale(.74) rotateY(8deg);
    }

    .recent-upgraded-info {
        display: none;
    }

    .recent-upgraded-nav {
        width: 38px;
        height: 38px;
    }
}
.fp-home-stage,
.fp-recent-center-wrap,
.fp-recent-track,
.fp-recent-card {
    all: unset;
}
.topbar-glass {
    overflow: visible !important;
}

.topbar-left,
.topbar-right {
    overflow: visible !important;
}
@media (min-width: 921px) {
    .home-recent-upgraded-section,
    .home-recent-upgraded-wrap,
    .recent-upgraded-track {
        overflow: visible !important;
    }

    .home-recent-upgraded-wrap {
        height: 390px !important;
        padding-top: 24px;
    }

    .recent-upgraded-track {
        height: 360px !important;
    }

    .recent-upgraded-card img {
        object-position: center top !important;
    }

    .recent-upgraded-card.pos-0 {
        transform: translateX(-50%) translateY(0) scale(1) !important;
    }
}
.wishlist-heart {
    width: 42px !important;
    height: 42px !important;
    min-width: 42px !important;
    min-height: 42px !important;
}
.movie-card,
.film-card,
.poster-card,
.home-movie-card {
    position: relative;
}

.wishlist-heart {
    top: 10px !important;
    left: 10px !important;
    right: auto !important;
    z-index: 20 !important;
}

/* =========================================================
   FilmParty Home Recent Final Clean Patch
   هدف: حذف فاصله اضافه، label روی بنر، لود پایدار تصاویر
   ========================================================= */

.hero-banner-stage {
    margin-bottom: 0 !important;
}

.hero-banner-slide img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
    background: #050b14;
    transform: translateZ(0);
    backface-visibility: hidden;
}

.hero-recent-label {
    position: absolute;
    right: max(18px, calc((100vw - 1180px) / 2));
    bottom: 18px;
    z-index: 5;
    min-height: 34px;
    display: inline-flex;
    align-items: center;
    padding: 0 14px;
    border-radius: 999px;
    color: #fff;
    font-size: 13px;
    font-weight: 950;
    letter-spacing: -.2px;
    background: rgba(7,17,31,.42);
    border: 1px solid rgba(255,255,255,.16);
    backdrop-filter: blur(18px);
    box-shadow: 0 12px 34px rgba(0,0,0,.30);
}

.home-content {
    padding-top: 6px !important;
}

.home-recent-upgraded-section {
    width: min(100%, 1180px) !important;
    margin: 0 auto 24px !important;
    padding: 0 16px !important;
}

.home-recent-upgraded-section .home-section-head {
    display: none !important;
}

.home-recent-upgraded-wrap {
    height: 350px !important;
    padding-top: 0 !important;
    margin-top: 0 !important;
    overflow: visible !important;
}

.recent-upgraded-track {
    height: 330px !important;
    overflow: visible !important;
}

.recent-upgraded-card {
    contain: layout paint;
    will-change: transform, opacity;
    background:
        linear-gradient(135deg, rgba(255,255,255,.08), rgba(255,255,255,.035)),
        #091321;
}

.recent-upgraded-card img {
    display: block;
    width: 100%;
    height: 100%;
    aspect-ratio: 2 / 3;
    object-fit: cover;
    object-position: center top;
    background: #091321;
    transform: translateZ(0);
    backface-visibility: hidden;
}

.recent-upgraded-card.pos-0 {
    transform: translateX(-50%) translateY(-4px) scale(1) !important;
}

/* روی موبایل فاصله بنر و لیست حداقلی بماند */
@media (max-width: 768px) {
    .hero-recent-label {
        right: 16px;
        bottom: 16px;
        min-height: 31px;
        padding: 0 12px;
        font-size: 12px;
    }

    .home-content {
        padding-top: 4px !important;
    }

    .home-recent-upgraded-section {
        margin-top: 0 !important;
        margin-bottom: 18px !important;
        padding: 0 8px !important;
    }

    .home-recent-upgraded-wrap {
        height: 286px !important;
    }

    .recent-upgraded-track {
        height: 266px !important;
    }
}

/* اگر کاربر motion کمتر می‌خواهد، انیمیشن سنگین کمتر شود */
@media (prefers-reduced-motion: reduce) {
    .recent-upgraded-card,
    .hero-banner-slide {
        transition: opacity .2s ease !important;
    }
}

/* FilmParty safe recent hero sync patch */
.js-home-recent-linked-hero .hero-banner-slide:not(.active) {
    display: none !important;
}

.js-home-recent-linked-hero.is-recent-syncing .hero-banner-slide.active img {
    opacity: .62;
    filter: blur(1.2px) saturate(.9);
}

.js-home-recent-linked-hero .hero-banner-slide.active img {
    transition: opacity .22s ease, filter .22s ease;
}

/* چیپ پایین بنر حذف شود */
.hero-recent-label {
    display: none !important;
}

/* چون بنر حالا با کاروسل اخیر هماهنگ است، dots بنر قدیمی لازم نیست */
#heroDotsRecentLinked {
    display: none !important;
}

/* =========================================================
   FilmParty Stable Hero Banner Fit
   بنر اصلی بدون کراپ شدید + بک‌گراند همگام با همان بنر
   ========================================================= */

html,
body {
    background-color: var(--bg-main) !important;
}

.hero-banner-stage {
    position: relative !important;
    height: clamp(520px, 37.5vw, 680px) !important;
    min-height: 520px !important;
    max-height: 680px !important;
    overflow: hidden !important;
    isolation: isolate !important;
    background: var(--bg-main) !important;
}

.hero-banner-stage::before {
    content: "";
    position: absolute;
    inset: -34px;
    z-index: 0;
    background-image: var(--fp-hero-image);
    background-size: cover;
    background-position: center center;
    background-repeat: no-repeat;
    filter: blur(24px) saturate(1.18) brightness(.62);
    transform: scale(1.08);
    opacity: .95;
    pointer-events: none;
}

.hero-banner-stage::after {
    content: "";
    position: absolute;
    inset: 0;
    z-index: 1;
    pointer-events: none;
    background:
        radial-gradient(circle at 20% 88%, var(--brand-fuchsia-glow) 0%, transparent 44%),
        radial-gradient(circle at 82% 10%, var(--brand-gold-dark-glow) 0%, transparent 36%),
        radial-gradient(circle at 50% 40%, rgba(47, 123, 255, 0.11) 0%, transparent 34%),
        linear-gradient(180deg, rgba(12, 10, 14, 0.12) 0%, var(--bg-plum-soft) 64%, var(--bg-main) 100%);
}

.hero-banner-track {
    position: relative !important;
    z-index: 2 !important;
    width: 100% !important;
    height: 100% !important;
}

.hero-banner-slide {
    background: transparent !important;
}

.hero-banner-slide img {
    position: absolute !important;
    inset: 0 !important;
    width: 100% !important;
    height: 100% !important;
    object-fit: contain !important;
    object-position: center center !important;
    background: transparent !important;
    transform: translateZ(0);
    backface-visibility: hidden;
}

.hero-vignette {
    z-index: 3 !important;
    background:
        linear-gradient(to bottom, rgba(10, 11, 16, 0.58), rgba(10, 11, 16, 0.1) 34%, var(--bg-main) 100%),
        linear-gradient(to left, rgba(47, 123, 255, 0.05), rgba(10, 11, 16, 0.74)) !important;
}

.hero-content {
    z-index: 5 !important;
}

/* آیفون و موبایل: بنر کامل دیده شود، فضای اضافه با بلور پر شود */
@media (max-width: 768px) {
    .hero-banner-stage {
        height: clamp(430px, 108vw, 540px) !important;
        min-height: 430px !important;
        max-height: 540px !important;
        border-radius: 0 0 28px 28px !important;
    }

    .hero-banner-stage::before {
        inset: -42px;
        filter: blur(28px) saturate(1.2) brightness(.58);
    }

    .hero-content {
        right: 18px !important;
        left: 18px !important;
        bottom: 58px !important;
        width: auto !important;
    }

    .hero-content h1 {
        font-size: clamp(28px, 8vw, 42px) !important;
    }

    .hero-content p {
        max-width: 100% !important;
        display: -webkit-box;
        -webkit-line-clamp: 2;
        -webkit-box-orient: vertical;
        overflow: hidden;
    }
}

/* آیفون‌های کوچک‌تر */
@media (max-width: 430px) {
    .hero-banner-stage {
        height: 455px !important;
        min-height: 455px !important;
    }
}

/* حذف چیپ اخیراً اضافه‌شده اگر هنوز جایی مانده */
.hero-recent-label {
    display: none !important;
}

/* =========================================================
   FilmParty Hero Clean Fit - Remove Blur Margins
   حذف حاشیه‌های تار بنر + بالا آوردن لیست اخیراً اضافه‌شده
   ========================================================= */

.hero-banner-stage::before,
.hero-banner-stage::after {
    display: none !important;
    content: none !important;
    background: none !important;
    filter: none !important;
}

.hero-banner-stage {
    height: clamp(430px, 34vw, 560px) !important;
    min-height: 430px !important;
    max-height: 560px !important;
    margin-bottom: 0 !important;
    background: var(--bg-main) !important;
    overflow: hidden !important;
}

.hero-banner-track,
.hero-banner-slide {
    height: 100% !important;
    background: var(--bg-main) !important;
}

.hero-banner-slide img {
    position: absolute !important;
    inset: 0 !important;
    width: 100% !important;
    height: 100% !important;
    object-fit: cover !important;
    object-position: center center !important;
    background: var(--bg-main) !important;
    opacity: 1 !important;
    filter: none !important;
}

.hero-banner-stage.is-recent-syncing .hero-banner-slide.active img {
    opacity: .82 !important;
    filter: none !important;
}

.hero-vignette {
    background:
        linear-gradient(to bottom, rgba(7,17,31,.46), rgba(7,17,31,.08) 38%, var(--bg-main) 100%),
        linear-gradient(to left, rgba(7,17,31,.08), rgba(7,17,31,.78)) !important;
}

.home-content {
    padding-top: 0 !important;
    margin-top: -10px !important;
}

.home-recent-upgraded-section {
    margin-top: -8px !important;
    margin-bottom: 22px !important;
}

.home-recent-upgraded-wrap {
    margin-top: 0 !important;
    padding-top: 0 !important;
}

/* موبایل: بنر کوتاه‌تر شود تا لیست‌ها بالا بیایند و فضای خالی حس نشود */
@media (max-width: 768px) {
    .hero-banner-stage {
        height: clamp(360px, 92vw, 450px) !important;
        min-height: 360px !important;
        max-height: 450px !important;
        border-radius: 0 0 26px 26px !important;
    }

    .hero-banner-slide img {
        object-position: center center !important;
    }

    .hero-content {
        bottom: 44px !important;
    }

    .home-content {
        margin-top: -8px !important;
        padding-top: 0 !important;
    }

    .home-recent-upgraded-section {
        margin-top: -6px !important;
        margin-bottom: 16px !important;
    }
}

/* آیفون‌های کوچک */
@media (max-width: 430px) {
    .hero-banner-stage {
        height: 385px !important;
        min-height: 385px !important;
    }

    .hero-content {
        bottom: 38px !important;
    }
}

/* =========================================================
   FilmParty Mobile Hero No-Crop Final
   روی موبایل بنر کامل نمایش داده شود و از طول/بالا/پایین کراپ نخورد
   ========================================================= */

@media (max-width: 768px) {
    .hero-banner-stage {
        height: auto !important;
        min-height: 0 !important;
        max-height: none !important;
        aspect-ratio: 16 / 9 !important;
        border-radius: 0 0 24px 24px !important;
        background: var(--bg-main) !important;
        overflow: hidden !important;
    }

    .hero-banner-track,
    .hero-banner-slide {
        position: relative !important;
        width: 100% !important;
        height: 100% !important;
        min-height: 0 !important;
    }

    .hero-banner-slide {
        inset: auto !important;
    }

    .hero-banner-slide:not(.active) {
        display: none !important;
    }

    .hero-banner-slide img {
        position: relative !important;
        inset: auto !important;
        width: 100% !important;
        height: 100% !important;
        object-fit: contain !important;
        object-position: center center !important;
        background: var(--bg-main) !important;
        display: block !important;
    }

    .hero-vignette {
        position: absolute !important;
        inset: 0 !important;
        background:
            linear-gradient(to bottom, rgba(7,17,31,.30), rgba(7,17,31,.02) 45%, rgba(7,17,31,.80) 100%),
            linear-gradient(to left, rgba(7,17,31,.02), rgba(7,17,31,.58)) !important;
    }

    .hero-content {
        right: 14px !important;
        left: 14px !important;
        bottom: 18px !important;
        width: auto !important;
    }

    .hero-pill {
        display: none !important;
    }

    .hero-content h1 {
        margin-bottom: 6px !important;
        font-size: clamp(21px, 6vw, 30px) !important;
        line-height: 1.35 !important;
    }

    .hero-content p {
        display: none !important;
    }

    .hero-action-btn {
        min-height: 36px !important;
        padding: 0 13px !important;
        border-radius: 13px !important;
        font-size: 12px !important;
    }

    .home-content {
        margin-top: -2px !important;
        padding-top: 0 !important;
    }

    .home-recent-upgraded-section {
        margin-top: 0 !important;
    }
}

/* گوشی‌های خیلی باریک */
@media (max-width: 430px) {
    .hero-banner-stage {
        aspect-ratio: 16 / 9 !important;
    }

    .hero-content {
        bottom: 14px !important;
    }

    .hero-content h1 {
        font-size: clamp(19px, 5.7vw, 26px) !important;
    }
}

/* =========================================================
   FilmParty Mobile Hero Balanced Final
   حذف حاشیه مشکی دوطرف + برگشت عرض کامل + ارتفاع مناسب موبایل
   ========================================================= */

@media (max-width: 768px) {
    .hero-banner-stage {
        height: clamp(390px, 82vw, 470px) !important;
        min-height: 390px !important;
        max-height: 470px !important;
        aspect-ratio: auto !important;
        border-radius: 0 0 26px 26px !important;
        background: var(--bg-main) !important;
        overflow: hidden !important;
    }

    .hero-banner-track,
    .hero-banner-slide {
        position: absolute !important;
        inset: 0 !important;
        width: 100% !important;
        height: 100% !important;
    }

    .hero-banner-slide:not(.active) {
        display: none !important;
    }

    .hero-banner-slide img {
        position: absolute !important;
        inset: 0 !important;
        width: 100% !important;
        height: 100% !important;
        object-fit: cover !important;
        object-position: center center !important;
        display: block !important;
        background: var(--bg-main) !important;
    }

    .hero-vignette {
        position: absolute !important;
        inset: 0 !important;
        background:
            linear-gradient(to bottom, rgba(7,17,31,.42), rgba(7,17,31,.04) 42%, rgba(7,17,31,.88) 100%),
            linear-gradient(to left, rgba(7,17,31,.04), rgba(7,17,31,.68)) !important;
    }

    .hero-content {
        right: 16px !important;
        left: 16px !important;
        bottom: 34px !important;
        width: auto !important;
    }

    .hero-pill {
        display: none !important;
    }

    .hero-content h1 {
        margin-bottom: 8px !important;
        font-size: clamp(23px, 6.7vw, 34px) !important;
        line-height: 1.35 !important;
    }

    .hero-content p {
        max-width: 96% !important;
        margin-bottom: 12px !important;
        font-size: 12px !important;
        line-height: 1.8 !important;
        display: -webkit-box !important;
        -webkit-line-clamp: 2 !important;
        -webkit-box-orient: vertical !important;
        overflow: hidden !important;
    }

    .hero-action-btn {
        min-height: 39px !important;
        padding: 0 14px !important;
        border-radius: 13px !important;
        font-size: 12px !important;
    }

    .home-content {
        margin-top: -4px !important;
        padding-top: 0 !important;
    }

    .home-recent-upgraded-section {
        margin-top: -2px !important;
    }
}

@media (max-width: 430px) {
    .hero-banner-stage {
        height: 410px !important;
        min-height: 410px !important;
        max-height: 410px !important;
    }

    .hero-content {
        bottom: 30px !important;
    }

    .hero-content h1 {
        font-size: clamp(22px, 6.2vw, 30px) !important;
    }
}

/* =========================================
   Mobile hero ratio fix - 5:4
   ========================================= */
@media (max-width: 768px) {
    .hero-banner-stage {
        height: auto !important;
        min-height: 0 !important;
        max-height: none !important;
        aspect-ratio: 5 / 4 !important; /* اگر خواستی 4:3 شود فقط این را به 4 / 3 تغییر بده */
        overflow: hidden !important;
        background: var(--bg-main) !important;
    }

    .hero-banner-track,
    .hero-banner-slide {
        position: absolute !important;
        inset: 0 !important;
        width: 100% !important;
        height: 100% !important;
    }

    .hero-banner-slide img {
        width: 100% !important;
        height: 100% !important;
        object-fit: cover !important;
        object-position: center top !important;
        display: block !important;
    }

    .hero-content {
        right: 16px !important;
        left: 16px !important;
        bottom: 26px !important;
        width: auto !important;
    }

    .hero-content h1 {
        font-size: clamp(22px, 6vw, 32px) !important;
        line-height: 1.35 !important;
    }

    .hero-content p {
        font-size: 12px !important;
        line-height: 1.8 !important;
        margin-bottom: 12px !important;
    }
}

@media (max-width: 430px) {
    .hero-banner-stage {
        aspect-ratio: 5 / 4 !important;
    }
}

/* === FilmParty desktop hero and scroll topbar safe patch START === */

/* فقط دسکتاپ: بنر کمتر از بالا/پایین کات بخورد */
@media (min-width: 769px) {
    .hero-banner-stage {
        height: clamp(600px, 40vw, 720px) !important;
        min-height: 600px !important;
        max-height: 720px !important;
        overflow: hidden !important;
        background: var(--bg-main) !important;
    }

    .hero-banner-track,
    .hero-banner-slide {
        height: 100% !important;
    }

    .hero-banner-slide img {
        width: 100% !important;
        height: 100% !important;
        object-fit: cover !important;
        object-position: center 32% !important;
        transform: none !important;
        filter: none !important;
    }

    .hero-content {
        bottom: 84px !important;
    }

    .hero-vignette {
        background:
            linear-gradient(to bottom, rgba(7,17,31,.56), rgba(7,17,31,.08) 34%, var(--bg-main) 100%),
            linear-gradient(to left, rgba(7,17,31,.08), rgba(7,17,31,.82)) !important;
    }
}

/* موبایل دست‌نخورده بماند */
@media (max-width: 768px) {
    .hero-banner-slide img {
        transform: none !important;
    }
}

/* حالت عادی: خود نوار بالا شیشه‌ای نباشد تا روی بنر را نپوشاند */
.topbar-glass {
    background: transparent !important;
    border-color: transparent !important;
    box-shadow: none !important;
    backdrop-filter: none !important;
    -webkit-backdrop-filter: none !important;
    transition:
        background .28s ease,
        border-color .28s ease,
        box-shadow .28s ease,
        backdrop-filter .28s ease,
        -webkit-backdrop-filter .28s ease !important;
}

/* در حالت عادی فقط دکمه‌ها شیشه‌ای خیلی شفاف باشند — لوگو بدون کادر */
.topbar-glass:not(.is-scrolled) .desktop-menu-btn,
.topbar-glass:not(.is-scrolled) .search-open-btn,
.topbar-glass:not(.is-scrolled) .topbar-left .catalog-top-link,
.topbar-glass:not(.is-scrolled) .topbar-left .fp-topbar-wallet-stable,
.topbar-glass:not(.is-scrolled) .topbar-left .fp-mobile-subscription-top-cta,
.topbar-glass:not(.is-scrolled) .notification-bell-shell.inside-topbar .notification-bell-btn {
    background: var(--glass-fill-ghost) !important;
    border: 1px solid var(--glass-border-cool) !important;
    backdrop-filter: blur(7px) !important;
    -webkit-backdrop-filter: blur(7px) !important;
    box-shadow: none !important;
}

.topbar-glass .desktop-menu-btn,
.topbar-glass .search-open-btn {
    min-width: 42px !important;
    height: 42px !important;
    border-radius: 15px !important;
}

.topbar-glass .brand-small.fp-logo-no-chip {
    min-height: 0 !important;
    display: inline-flex !important;
    align-items: center !important;
    gap: 0 !important;
    padding: 0 !important;
    border-radius: 0 !important;
    background: transparent !important;
    border: none !important;
    box-shadow: none !important;
    backdrop-filter: none !important;
    -webkit-backdrop-filter: none !important;
}

.topbar-glass .brand-small:not(.fp-logo-no-chip) {
    min-height: 42px !important;
    display: inline-flex !important;
    align-items: center !important;
    gap: 2px !important;
    padding: 0 14px !important;
    border-radius: 16px !important;
}

/* بعد از اسکرول: بک‌گراند شیشه‌ای خود نوار ظاهر شود */
.topbar-glass.is-scrolled {
    background: var(--glass-topbar-scrolled) !important;
    border-color: rgba(255, 255, 255, 0.1) !important;
    box-shadow: 0 18px 55px rgba(0, 0, 0, 0.32) !important;
    backdrop-filter: blur(24px) !important;
    -webkit-backdrop-filter: blur(24px) !important;
}

/* وقتی خود نوار شیشه‌ای شد، دکمه‌ها ساده‌تر شوند تا دوبار شیشه‌ای نشوند */
.topbar-glass.is-scrolled .desktop-menu-btn,
.topbar-glass.is-scrolled .search-open-btn {
    background: transparent !important;
    border-color: transparent !important;
    box-shadow: none !important;
    backdrop-filter: none !important;
    -webkit-backdrop-filter: none !important;
}

/* === FilmParty desktop hero and scroll topbar safe patch END === */


/* FILMPARTY_STEP116_3_DESKTOP_HOME_BANNER_NO_HARD_CROP_START
   Desktop-only home banner crop fix.
   Mobile is intentionally untouched because current mobile banner is approved.
   The original 520px fixed desktop height caused hard vertical crop on wide screens.
*/
@media (min-width: 769px) {
    .filmparty-home .hero-banner-stage {
        height: clamp(600px, 40vw, 720px) !important;
        min-height: 600px !important;
        max-height: 720px !important;
        overflow: hidden !important;
    }

    .filmparty-home .hero-banner-track,
    .filmparty-home .hero-banner-slide {
        height: 100% !important;
        min-height: 100% !important;
    }

    .filmparty-home .hero-banner-slide img {
        width: 100% !important;
        height: 100% !important;
        object-fit: cover !important;
        object-position: center 32% !important;
        display: block !important;
    }

    .filmparty-home .hero-content {
        bottom: clamp(72px, 7vw, 104px) !important;
    }

    .filmparty-home .hero-dots {
        bottom: 30px !important;
    }
}

@media (min-width: 1600px) {
    .filmparty-home .hero-banner-slide img {
        object-position: center 30% !important;
    }
}
/* FILMPARTY_STEP116_3_DESKTOP_HOME_BANNER_NO_HARD_CROP_END */

/* FILMPARTY_HOME_CONTINUE_WATCHING_START */
.home-continue-section {
    width: min(100%, 1180px);
    margin: 26px auto 30px;
    padding: 0 16px;
}

.home-continue-section.cinema-section {
    margin-bottom: 30px;
}

.home-continue-heading {
    margin-bottom: 14px;
}

.fp-continue-track {
    display: flex;
    gap: 12px;
    overflow-x: auto;
    padding: 6px 2px 14px;
    scroll-snap-type: x proximity;
    scrollbar-width: none;
    -webkit-overflow-scrolling: touch;
}

.fp-continue-track::-webkit-scrollbar {
    display: none;
}

.fp-continue-card {
    flex: 0 0 228px;
    scroll-snap-align: start;
    display: grid;
    grid-template-columns: 72px 1fr;
    gap: 10px;
    align-items: stretch;
    min-height: 96px;
    padding: 9px;
    border-radius: 18px;
    background:
        linear-gradient(135deg, rgba(255,255,255,.085), rgba(255,255,255,.035));
    border: 1px solid rgba(255,255,255,.11);
    box-shadow: 0 10px 28px rgba(0,0,0,.18);
    backdrop-filter: blur(14px);
    transition: transform .18s ease, border-color .18s ease, background .18s ease;
    text-decoration: none;
    color: inherit;
}

.fp-continue-card:hover,
.fp-continue-card:focus-visible {
    transform: translateY(-1px);
    background: rgba(47,123,255,.12);
    border-color: rgba(87,161,255,.28);
    outline: none;
}

.fp-continue-card__poster-wrap {
    position: relative;
    width: 72px;
    height: 96px;
    border-radius: 13px;
    overflow: hidden;
    background: rgba(255,255,255,.08);
    flex-shrink: 0;
}

.fp-continue-card__poster-wrap img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.fp-continue-card__progress {
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    height: 3px;
    background: rgba(255,255,255,.22);
    pointer-events: none;
}

.fp-continue-card__progress > i {
    display: block;
    height: 100%;
    min-width: 0;
    background: #ff4d67;
    box-shadow: 0 0 8px rgba(255,77,103,.45);
}

.fp-continue-card__info {
    min-width: 0;
    display: grid;
    align-content: center;
    gap: 3px;
}

.fp-continue-card__info strong {
    display: block;
    color: #fff;
    font-size: 13px;
    line-height: 1.45;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.fp-continue-card__info small {
    display: block;
    direction: ltr;
    text-align: right;
    color: rgba(226,232,240,.72);
    font-size: 11px;
    line-height: 1.35;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.fp-continue-card__meta {
    display: flex;
    flex-wrap: wrap;
    gap: 5px;
    margin-top: 4px;
}

.fp-continue-card__meta span {
    padding: 3px 6px;
    border-radius: 999px;
    font-size: 10px;
    line-height: 1.2;
    color: rgba(226,232,240,.78);
    background: rgba(0,0,0,.22);
    border: 1px solid rgba(255,255,255,.06);
    white-space: nowrap;
}

@media (max-width: 768px) {
    .home-continue-section {
        margin: 20px auto 22px;
        padding: 0 8px;
    }

    .home-continue-section.cinema-section {
        margin-bottom: 22px;
    }

    .home-continue-heading h2 {
        font-size: 21px;
    }

    .fp-continue-card {
        flex-basis: 210px;
        min-height: 90px;
        padding: 8px;
        border-radius: 16px;
    }

    .fp-continue-card__poster-wrap {
        width: 64px;
        height: 86px;
        border-radius: 12px;
    }

    .fp-continue-track {
        gap: 10px;
        padding-bottom: 12px;
    }
}
/* FILMPARTY_HOME_CONTINUE_WATCHING_END */

/* FILMPARTY_HERO_BOTTOM_DISSOLVE_START
   دسکتاپ: mask روی slide | موبایل/عمودی: layout یکپارچه + محو فقط روی slide::after
*/
@media (min-width: 769px) {
    /* دسکتاپ: تمام‌عرض + نسبت بلندتر از 16:6 → کراپ کمتر از بالا/پایین (موبایل جداست) */
    .filmparty-home .hero-banner-stage {
        width: 100% !important;
        max-width: none !important;
        height: auto !important;
        min-height: 0 !important;
        max-height: none !important;
        aspect-ratio: 16 / 7 !important;
        margin: 0 !important;
        border-radius: 0 0 36px 36px !important;
        overflow: hidden !important;
        background: var(--bg-main) !important;
    }

    .filmparty-home .hero-banner-track,
    .filmparty-home .hero-banner-slide {
        position: absolute !important;
        inset: 0 !important;
        width: 100% !important;
        height: 100% !important;
    }

    .filmparty-home .hero-banner-slide img {
        position: absolute !important;
        inset: 0 !important;
        width: 100% !important;
        height: 100% !important;
        object-fit: cover !important;
        object-position: center center !important;
        transform: none !important;
        filter: none !important;
        background: var(--bg-main) !important;
    }

    .filmparty-home .hero-banner-slide {
        -webkit-mask-image: linear-gradient(
            to bottom,
            #000 0%,
            #000 68%,
            rgba(0, 0, 0, 0.94) 76%,
            rgba(0, 0, 0, 0.82) 82%,
            rgba(0, 0, 0, 0.66) 88%,
            rgba(0, 0, 0, 0.46) 93%,
            rgba(0, 0, 0, 0.24) 97%,
            transparent 100%
        ) !important;
        mask-image: linear-gradient(
            to bottom,
            #000 0%,
            #000 68%,
            rgba(0, 0, 0, 0.94) 76%,
            rgba(0, 0, 0, 0.82) 82%,
            rgba(0, 0, 0, 0.66) 88%,
            rgba(0, 0, 0, 0.46) 93%,
            rgba(0, 0, 0, 0.24) 97%,
            transparent 100%
        ) !important;
        -webkit-mask-size: 100% 100% !important;
        mask-size: 100% 100% !important;
        -webkit-mask-repeat: no-repeat !important;
        mask-repeat: no-repeat !important;
    }

    .filmparty-home .hero-vignette {
        background:
            linear-gradient(to bottom, rgba(7, 17, 31, 0.3) 0%, transparent 20%),
            linear-gradient(to left, rgba(7, 17, 31, 0.02), rgba(7, 17, 31, 0.52)) !important;
    }
}

.filmparty-home .hero-banner-slide img {
    -webkit-mask-image: none !important;
    mask-image: none !important;
}

@media (max-width: 768px) {
    .filmparty-home .hero-banner-stage {
        position: relative !important;
        isolation: isolate !important;
        height: auto !important;
        min-height: 0 !important;
        max-height: none !important;
        aspect-ratio: 5 / 4 !important;
        border-radius: 0 0 24px 24px !important;
        background: var(--bg-main) !important;
        overflow: hidden !important;
    }

    .filmparty-home .hero-banner-stage::before,
    .filmparty-home .hero-banner-stage::after {
        display: none !important;
        content: none !important;
        background: none !important;
    }

    .filmparty-home .hero-banner-track,
    .filmparty-home .hero-banner-slide {
        position: absolute !important;
        inset: 0 !important;
        width: 100% !important;
        height: 100% !important;
        -webkit-mask-image: none !important;
        mask-image: none !important;
    }

    .filmparty-home .hero-banner-slide:not(.active) {
        display: none !important;
    }

    .filmparty-home .hero-banner-slide img {
        position: absolute !important;
        inset: 0 !important;
        width: 100% !important;
        height: 100% !important;
        object-fit: cover !important;
        object-position: center 30% !important;
        display: block !important;
        background: var(--bg-main) !important;
    }

    .filmparty-home .hero-banner-slide::after {
        content: "" !important;
        display: block !important;
        position: absolute !important;
        left: 0 !important;
        right: 0 !important;
        bottom: 0 !important;
        height: 58% !important;
        z-index: 2 !important;
        pointer-events: none !important;
        background: linear-gradient(
            to bottom,
            rgba(7, 17, 31, 0) 0%,
            rgba(7, 17, 31, 0.025) 14%,
            rgba(7, 17, 31, 0.08) 26%,
            rgba(7, 17, 31, 0.16) 38%,
            rgba(7, 17, 31, 0.27) 50%,
            rgba(7, 17, 31, 0.4) 62%,
            rgba(7, 17, 31, 0.55) 74%,
            rgba(7, 17, 31, 0.72) 86%,
            rgba(7, 17, 31, 0.88) 95%,
            var(--bg-main) 100%
        ) !important;
    }

    .filmparty-home .hero-vignette {
        z-index: 3 !important;
        background: linear-gradient(to left, rgba(7, 17, 31, 0), rgba(7, 17, 31, 0.26)) !important;
    }

    .filmparty-home .hero-content {
        z-index: 5 !important;
    }
}

@media (max-width: 768px) and (orientation: portrait) {
    .filmparty-home .hero-banner-stage {
        aspect-ratio: 16 / 13 !important;
    }

    .filmparty-home .hero-banner-slide img {
        object-position: center 28% !important;
    }

    .filmparty-home .hero-banner-slide::after {
        height: 64% !important;
    }
}

@media (max-width: 430px) and (orientation: portrait) {
    .filmparty-home .hero-banner-stage {
        aspect-ratio: 16 / 14 !important;
    }
}
/* FILMPARTY_HERO_BOTTOM_DISSOLVE_END */

/* ===== Popular ("پرطرفدارترین‌های هفته") desktop paging arrows ===== */
.fp-pop-wrap {
    position: relative;
}

.fp-pop-nav {
    position: absolute;
    top: calc(50% - 9px);
    transform: translateY(-50%);
    z-index: 18;
    width: 44px;
    height: 44px;
    border-radius: 16px;
    border: 1px solid rgba(255, 255, 255, 0.14);
    background: rgba(18, 22, 31, 0.74);
    color: #fff;
    cursor: pointer;
    -webkit-backdrop-filter: blur(22px);
    backdrop-filter: blur(22px);
    box-shadow: 0 16px 48px rgba(0, 0, 0, 0.34);
    display: none;
    align-items: center;
    justify-content: center;
    transition: opacity 0.2s ease, background 0.2s ease, border-color 0.2s ease, transform 0.14s ease;
}

.fp-pop-nav.prev { right: 2px; }
.fp-pop-nav.next { left: 2px; }

.fp-pop-nav:hover {
    background: rgba(255, 98, 139, 0.24);
    border-color: rgba(255, 98, 139, 0.42);
}

.fp-pop-nav:active { transform: translateY(-50%) scale(0.94); }

.fp-pop-nav i {
    position: relative;
    width: 14px;
    height: 14px;
    display: inline-block;
}

.fp-pop-nav i::before {
    content: "";
    position: absolute;
    inset: 0;
    border-top: 3px solid currentColor;
    border-right: 3px solid currentColor;
    border-radius: 2px;
}

.fp-pop-nav.prev i::before { transform: rotate(45deg); }
.fp-pop-nav.next i::before { transform: rotate(-135deg); }

.fp-pop-nav.is-disabled {
    opacity: 0;
    pointer-events: none;
}

/* Desktop only — mobile keeps native swipe */
@media (min-width: 921px) {
    .fp-pop-nav { display: inline-flex; }
}
