/* ========================================================
   استایل شکیل، لوکس و خوش‌دست لیست رویدادها (Balanced Grid)
   ======================================================== */

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(-10px); }
    to { opacity: 1; transform: translateY(0); }
}

@keyframes slideUp {
    from { opacity: 0; transform: translateY(25px); }
    to { opacity: 1; transform: translateY(0); }
}

@keyframes cardAppear {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

/* کانتینر اصلی صفحه */
.premium-detail-wrapper {
    width: 100%;
    margin: 0 auto;
    padding: 20px 0 70px 0;
    background-color: var(--bg-light, #f8fafc);
    direction: rtl;
    text-align: right;
    min-height: 100vh;
}

/* مسیر راهنما (Breadcrumb) */
.detail-top-meta-deck {
    margin-bottom: 25px;
    animation: fadeIn 0.5s ease both;
}

.detail-breadcrumb-minimal {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.82rem;
    flex-wrap: wrap;
    color: #475569;
}

.detail-breadcrumb-minimal a {
    color: #475569;
    text-decoration: none;
    transition: var(--transition, all 0.3s ease);
}

.detail-breadcrumb-minimal a:hover {
    color: var(--accent-color, #d9386c);
}

.detail-breadcrumb-minimal .sep {
    color: #94a3b8;
    font-size: 0.75rem;
}

.detail-breadcrumb-minimal .cat-accent {
    color: var(--accent-color, #d9386c);
    font-weight: 700;
}

/* هدر اصلی صفحه */
.article-epic-header {
    margin-bottom: 35px;
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.epic-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background-color: rgba(217, 56, 108, 0.08);
    color: var(--accent-color, #d9386c);
    border: 1px solid rgba(217, 56, 108, 0.2);
    padding: 6px 18px;
    border-radius: 50px;
    font-size: 0.8rem;
    font-weight: 800;
    margin-bottom: 20px;
}

.epic-title {
    font-size: clamp(1.6rem, 4vw, 2.3rem);
    font-weight: 900;
    line-height: 1.4;
    color: var(--primary-color, #0d121f);
    margin: 0 auto 15px auto;
    text-align: center;
    position: relative;
    padding-bottom: 20px;
}

.epic-title::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 80px;
    height: 3px;
    background-color: var(--accent-color, #d9386c);
    border-radius: 2px;
}

.epic-sub-title {
    font-size: 1rem;
    color: #475569;
    max-width: 700px;
    line-height: 1.7;
    margin: 0 auto 20px auto;
    text-align: center;
}

/* پنل جستجو و فیلتر شیشه‌ای تیره */
.cinema-article-container {
    background-color: var(--secondary-color, #1a1f30);
    border-radius: 24px;
    border: 1px solid rgba(217, 56, 108, 0.2);
    box-shadow: 
        0 12px 30px rgba(15, 23, 42, 0.08),
        0 0 35px rgba(217, 56, 108, 0.06);
    padding: 24px 22px;
    margin-bottom: 45px;
    animation: slideUp 0.6s ease both;
}

.luxury-filter-form {
    display: flex;
    align-items: center;
    gap: 16px;
    flex-wrap: wrap;
    width: 100%;
}

.luxury-search-input-wrapper {
    flex: 1;
    min-width: 280px;
    display: flex;
    align-items: center;
    background-color: var(--primary-color, #0d121f);
    border: 1.5px solid rgba(255, 255, 255, 0.08);
    border-radius: 14px;
    overflow: hidden;
    transition: var(--transition, all 0.3s ease);
}

.luxury-search-input-wrapper:focus-within {
    border-color: var(--accent-color, #d9386c);
    box-shadow: 0 0 15px rgba(217, 56, 108, 0.25);
}

.luxury-search-input-wrapper input {
    flex: 1;
    border: none;
    background: transparent;
    padding: 14px 20px;
    color: #ffffff;
    font-size: 0.95rem;
    outline: none;
    font-family: inherit;
}

.search-main-icon {
    margin-left: 20px;
    color: var(--accent-color, #d9386c);
}

.search-action-btn {
    background-color: var(--accent-color, #d9386c);
    color: #ffffff;
    border: none;
    height: 50px;
    padding: 0 30px;
    border-radius: 14px;
    cursor: pointer;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    transition: var(--transition, all 0.3s ease);
    box-shadow: 0 4px 15px rgba(217, 56, 108, 0.3);
}

.search-action-btn:hover {
    background-color: var(--accent-hover, #be2552);
    transform: translateY(-2px);
    box-shadow: 0 8px 22px rgba(217, 56, 108, 0.45);
}

.clear-filters-link {
    color: #ef4444;
    font-weight: 700;
    font-size: 0.85rem;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    text-decoration: none;
    transition: var(--transition, all 0.3s ease);
}

.clear-filters-link:hover {
    opacity: 0.8;
}

/* ================= گرید کارت‌های متوازن (Balanced Grid) ================= */
.events-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); /* گرید کارت‌های خوش‌دست و متناسب */
    gap: 28px;
    margin-bottom: 50px;
}

/* کارت لوکس رویداد */
.event-card {
    background: linear-gradient(135deg, var(--secondary-color, #1a1f30) 0%, var(--primary-color, #0d121f) 100%);
    border-radius: 22px;
    border: 1px solid rgba(255, 255, 255, 0.08);
    overflow: hidden;
    display: flex;
    flex-direction: column;
    box-shadow: 0 10px 28px rgba(15, 23, 42, 0.12);
    position: relative;
    z-index: 1;
    transition: all 0.35s cubic-bezier(0.16, 1, 0.3, 1);
    animation: cardAppear 0.5s cubic-bezier(0.165, 0.84, 0.44, 1) both;
}

/* افکت شیمر درخشان زمان هاور */
.event-card::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(
        120deg,
        transparent 35%,
        rgba(255, 255, 255, 0.03) 45%,
        rgba(255, 255, 255, 0.08) 50%,
        rgba(255, 255, 255, 0.03) 55%,
        transparent 65%
    );
    background-size: 200% 200%;
    background-position: 200% 0;
    transition: background-position 0.8s ease;
    pointer-events: none;
    z-index: 4;
}

.event-card:hover {
    transform: translateY(-7px);
    border-color: rgba(217, 56, 108, 0.4);
    box-shadow: 
        0 18px 40px rgba(15, 23, 42, 0.22),
        0 0 25px rgba(217, 56, 108, 0.12);
}

.event-card:hover::before {
    background-position: -200% 0;
}

/* قاب تصویر بالای کارت با ابعاد استاندارد و خوش‌دست */
.card-image-box {
    position: relative;
    width: 100%;
    height: 200px; /* ارتفاع متناسب و عالی قاب عکس */
    overflow: hidden;
    background-color: var(--primary-color, #0d121f);
    margin: 0;
}

.card-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    filter: brightness(0.95);
    transition: transform 0.5s cubic-bezier(0.16, 1, 0.3, 1);
}

.event-card:hover .card-img {
    transform: scale(1.06);
}

.card-image-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, transparent 55%, rgba(13, 18, 31, 0.85) 100%);
}

/* تگ دسته‌بندی معلق روی تصویر */
.card-category-tag {
    position: absolute;
    top: 14px;
    right: 14px;
    font-size: 0.72rem;
    font-weight: 800;
    color: #ffffff;
    background-color: rgba(13, 18, 31, 0.82);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    padding: 5px 12px;
    border-radius: 50px;
    border: 1px solid rgba(217, 56, 108, 0.3);
    z-index: 3;
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.card-category-tag i {
    color: var(--accent-color, #d9386c);
}

/* بدنه متنی کارت */
.card-text-container {
    padding: 20px 22px 18px 22px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    flex-grow: 1;
}

.card-title {
    font-size: 1.1rem;
    font-weight: 850;
    line-height: 1.5;
    margin: 0 0 10px 0;
}

.card-title a {
    color: #ffffff;
    text-decoration: none;
    transition: color 0.3s ease;
}

.event-card:hover .card-title a {
    color: var(--accent-color, #d9386c);
}

.card-desc {
    color: #cbd5e1;
    font-size: 0.88rem;
    line-height: 1.7;
    margin: 0 0 16px 0;
    text-align: justify;
}

/* دکمه پایین کارت */
.card-button-row {
    margin-top: auto;
    padding-top: 14px;
    border-top: 1px solid rgba(255, 255, 255, 0.06);
}

.btn-explore {
    display: inline-flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    color: #ffffff;
    font-weight: 700;
    font-size: 0.85rem;
    text-decoration: none;
    transition: var(--transition, all 0.3s ease);
}

.explore-arrow-circle {
    width: 34px;
    height: 34px;
    border-radius: 50%;
    background-color: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.08);
    color: #ffffff;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition, all 0.3s ease);
}

.explore-arrow-circle i {
    font-size: 0.78rem;
    transition: transform 0.3s cubic-bezier(0.165, 0.84, 0.44, 1);
}

.event-card:hover .btn-explore {
    color: var(--accent-color, #d9386c);
}

.event-card:hover .explore-arrow-circle {
    background-color: var(--accent-color, #d9386c);
    border-color: var(--accent-color, #d9386c);
    color: #ffffff;
    box-shadow: 0 0 15px rgba(217, 56, 108, 0.4);
}

.event-card:hover .explore-arrow-circle i {
    transform: translateX(-4px);
}

/* صفحه‌بندی لوکس */
.luxury-pagination-wrapper {
    display: flex;
    justify-content: center;
    margin-top: 40px;
}

.luxury-pagination {
    display: flex;
    align-items: center;
    gap: 8px;
    list-style: none;
    padding: 0;
}

.luxury-pagination li a,
.luxury-pagination li span {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 42px;
    height: 42px;
    padding: 0 12px;
    background-color: var(--secondary-color, #1a1f30);
    border: 1px solid rgba(255, 255, 255, 0.08);
    color: #cbd5e1;
    border-radius: 14px;
    font-weight: 700;
    font-size: 0.9rem;
    transition: var(--transition, all 0.3s ease);
    text-decoration: none;
}

.luxury-pagination li a:hover {
    border-color: var(--accent-color, #d9386c);
    color: var(--accent-color, #d9386c);
    transform: translateY(-2px);
}

.luxury-pagination .active-step span {
    background-color: var(--accent-color, #d9386c);
    border-color: var(--accent-color, #d9386c);
    color: #ffffff;
    box-shadow: 0 4px 18px rgba(217, 56, 108, 0.4);
}

/* خالی بودن لیست */
.empty-dashboard-state {
    grid-column: 1 / -1;
    text-align: center;
    padding: 60px 20px;
    background: linear-gradient(135deg, var(--secondary-color, #1a1f30) 0%, var(--primary-color, #0d121f) 100%);
    border-radius: 24px;
    border: 1px solid rgba(255, 255, 255, 0.08);
}

.empty-dashboard-state i {
    font-size: 3rem;
    color: var(--accent-color, #d9386c);
    margin-bottom: 15px;
    opacity: 0.8;
}

/* ================= ریسپانسو موبایل و تبلت ================= */
@media (max-width: 768px) {
    .events-grid {
        grid-template-columns: 1fr; /* تک‌ستونه در موبایل */
        gap: 20px;
    }

    .card-image-box {
        height: 190px;
    }

    .card-text-container {
        padding: 18px 18px;
    }

    .card-title {
        font-size: 1.05rem;
    }
}

@media (max-width: 576px) {
    .cinema-article-container {
        padding: 18px 15px;
    }

    .luxury-filter-form {
        flex-direction: column;
        align-items: stretch;
    }

    .search-action-btn {
        width: 100%;
    }
}