/* ==========================================================================
   Home New Arrivals ("جدیدترین‌های انیمه تی‌وی") — Design 1: 3D Pop-Out Pedestal
   ========================================================================== */

.new-pedestal-section {
    --np-rgb: 251, 191, 36;
    --np-accent: #fbbf24;
    --np-surface: #1b1c22;
    --np-surface-2: #15161c;
    --np-border: rgba(255, 255, 255, 0.08);
    --np-text: #f4f5f9;
    --np-muted: #9ca3b5;
    width: 94%;
    margin: 26px auto 34px;
    direction: rtl;
    font-family: 'IRANYekanX', 'Vazirmatn', system-ui, sans-serif;
    box-sizing: border-box;
}

/* Header */
.new-pedestal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 12px;
    margin-bottom: 6px;
}

.new-pedestal-header-right {
    display: flex;
    align-items: center;
    gap: 12px;
    min-width: 0;
}

.new-pedestal-accent-bar {
    width: 6px;
    height: 36px;
    border-radius: 999px;
    background: linear-gradient(180deg, var(--np-accent), rgba(var(--np-rgb), 0.15));
    flex-shrink: 0;
}

.new-pedestal-heading-text {
    min-width: 0;
    text-align: right;
}

.new-pedestal-title-row {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 10px;
}

.new-pedestal-section .new-pedestal-title {
    margin: 0 !important;
    color: var(--np-text) !important;
    font-family: 'IRANYekanX', 'Vazirmatn', sans-serif !important;
    font-size: 18px !important;
    font-weight: 900 !important;
    line-height: 1.4 !important;
}

.new-pedestal-chip {
    display: inline-block;
    padding: 2px 10px;
    border-radius: 8px;
    background: rgba(var(--np-rgb), 0.14);
    border: 1px solid rgba(var(--np-rgb), 0.3);
    color: var(--np-accent);
    font-family: 'IRANYekanX', 'Vazirmatn', sans-serif;
    font-size: 11.5px;
    font-weight: 800;
    line-height: 1.5;
}

.new-pedestal-section .new-pedestal-subtitle {
    margin: 2px 0 0 !important;
    color: var(--np-muted) !important;
    font-family: 'IRANYekanX', 'Vazirmatn', sans-serif !important;
    font-size: 12px !important;
    font-weight: 400 !important;
    line-height: 1.65 !important;
}

/* Header Controls */
.new-pedestal-controls {
    display: flex;
    align-items: center;
    gap: 6px;
    direction: rtl;
}

.new-pedestal-arrow-btn,
.new-pedestal-view-all {
    height: 36px;
    box-sizing: border-box;
    border-radius: 12px;
    background: var(--np-surface);
    border: 1px solid var(--np-border);
    color: var(--np-text);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    text-decoration: none !important;
    transition: background 0.2s ease, border-color 0.2s ease;
    font-family: 'IRANYekanX', 'Vazirmatn', sans-serif;
    user-select: none;
}

.new-pedestal-arrow-btn {
    width: 36px;
    padding: 0;
}

.new-pedestal-arrow-btn svg {
    width: 15px;
    height: 15px;
    display: block;
}

.new-pedestal-view-all {
    padding: 0 15px;
    gap: 7px;
    font-size: 12px;
    font-weight: 700;
    white-space: nowrap;
}

.new-pedestal-view-all .np-arrow-left {
    color: var(--np-accent);
    font-size: 13px;
    line-height: 1;
    transition: transform 0.2s ease;
}

.new-pedestal-arrow-btn:not(:disabled):hover,
.new-pedestal-view-all:hover {
    background: rgba(var(--np-rgb), 0.13);
    border-color: rgba(var(--np-rgb), 0.42);
    color: var(--np-text);
}

.new-pedestal-view-all:hover .np-arrow-left {
    transform: translateX(-3px);
}

.new-pedestal-arrow-btn:disabled {
    opacity: 0.34;
    cursor: default;
    pointer-events: none;
}

/* Embla Track — Extra top padding gives full room for 3D Pop-Out Poster + Hover Lift! */
.new-pedestal-embla.embla {
    overflow: hidden;
    padding: 36px 2px 12px;
}

.new-pedestal-container.embla__container {
    display: flex;
    align-items: flex-end;
    overflow: visible !important;
}

/* 3D Pop-Out Pedestal Card */
.new-pedestal-section .new-pedestal-card.embla__slide {
    flex: 0 0 364px;
    width: 364px;
    height: 168px;
    margin-left: 16px;
    box-sizing: border-box;
    position: relative;
    display: flex;
    align-items: flex-end;
    gap: 14px;
    padding: 14px;
    border-radius: 22px;
    background: var(--np-surface);
    border: 1px solid var(--np-border);
    text-decoration: none !important;
    overflow: visible !important;
    box-shadow: 0 14px 30px -14px rgba(0, 0, 0, 0.65);
    transition: border-color 0.24s ease, box-shadow 0.24s ease;
}

.new-pedestal-section .new-pedestal-card.embla__slide:hover {
    border-color: rgba(var(--np-rgb), 0.42);
    box-shadow: 0 18px 36px -12px rgba(0, 0, 0, 0.76), 0 0 22px -6px rgba(var(--np-rgb), 0.16);
}

/* Subtle Gold Roof Highlight Line */
.new-pedestal-roof-line {
    position: absolute;
    top: 0;
    right: 20px;
    left: 132px;
    height: 2px;
    border-radius: 999px;
    background: linear-gradient(90deg, transparent, var(--np-accent), transparent);
    opacity: 0.75;
    pointer-events: none;
}

/* Right Side: 3D Pop-Out Poster Extending Above Card Roof */
.new-pedestal-poster {
    position: relative;
    width: 116px;
    height: 172px;
    margin-top: -32px;
    border-radius: 16px;
    overflow: hidden;
    flex-shrink: 0;
    background: #0d0f16;
    box-shadow: 0 16px 32px -8px rgba(0, 0, 0, 0.78);
    transition: transform 0.34s cubic-bezier(0.22, 1, 0.36, 1), border-color 0.28s ease;
}

.new-pedestal-section .new-pedestal-card.embla__slide:hover .new-pedestal-poster {
    transform: translateY(-7px) scale(1.04);
    border-color: rgba(var(--np-rgb), 0.7);
}

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

/* Left Side: Structured Metadata + Dual Stat Boxes */
.new-pedestal-body {
    flex: 1;
    min-width: 0;
    height: 100%;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    text-align: right;
}

.new-pedestal-upper {
    min-width: 0;
}

.new-pedestal-top-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    margin-bottom: 6px;
}

.new-pedestal-type-pill {
    display: inline-block;
    padding: 2px 9px;
    border-radius: 6px;
    background: rgba(var(--np-rgb), 0.15);
    color: var(--np-accent);
    font-family: 'IRANYekanX', 'Vazirmatn', sans-serif;
    font-size: 11.5px;
    font-weight: 800;
    line-height: 1.5;
    white-space: nowrap;
}

.new-pedestal-time {
    color: var(--np-muted);
    font-family: 'IRANYekanX', 'Vazirmatn', sans-serif;
    font-size: 11.5px;
    font-weight: 500;
    white-space: nowrap;
}

.new-pedestal-section .new-pedestal-item-title {
    margin: 0 0 4px !important;
    color: var(--np-text) !important;
    font-family: 'Kalame', 'IRANYekanX', sans-serif !important;
    font-size: 18px !important;
    font-weight: 700 !important;
    line-height: 1.2 !important;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-overflow: ellipsis;
}

.new-pedestal-section .new-pedestal-item-title.is-ltr {
    direction: ltr;
    text-align: left;
}

.new-pedestal-section .new-pedestal-item-title.is-rtl {
    direction: rtl;
    text-align: right;
}

.new-pedestal-genres {
    color: var(--np-muted);
    font-family: 'IRANYekanX', 'Vazirmatn', sans-serif;
    font-size: 11.5px;
    font-weight: 400;
    line-height: 1.4;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* Dual Stat Boxes */
.new-pedestal-stats {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px;
    padding-top: 4px;
}

.new-pedestal-stat-box {
    border-radius: 12px;
    padding: 5px 9px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 4px;
    background: var(--np-surface-2);
    border: 1px solid var(--np-border);
}

.new-pedestal-stat-box.is-rate {
    background: rgba(var(--np-rgb), 0.1);
    border-color: rgba(var(--np-rgb), 0.24);
}

.new-pedestal-stat-label {
    color: var(--np-muted);
    font-family: 'IRANYekanX', 'Vazirmatn', sans-serif;
    font-size: 11px;
    font-weight: 500;
}

.new-pedestal-stat-val {
    color: var(--np-text);
    font-family: 'IRANYekanX', 'Vazirmatn', sans-serif;
    font-size: 11.5px;
    font-weight: 900;
    white-space: nowrap;
}

.new-pedestal-stat-box.is-rate .new-pedestal-stat-val {
    color: var(--np-accent);
    font-family: 'Segoe UI', system-ui, sans-serif;
    direction: ltr;
}

/* Day (Light) Theme Overrides */
.day .new-pedestal-section {
    --np-accent: #d97706;
    --np-surface: #ffffff;
    --np-surface-2: #f1f4fa;
    --np-border: rgba(15, 23, 42, 0.09);
    --np-text: #141824;
    --np-muted: #555f75;
}

@media (max-width: 760px) {
    .new-pedestal-section .new-pedestal-card.embla__slide {
        flex: 0 0 316px;
        width: 316px;
        height: 154px;
        margin-left: 12px;
    }

    .new-pedestal-poster {
        width: 102px;
        height: 154px;
    }
}

@media (prefers-reduced-motion: reduce) {
    .new-pedestal-poster,
    .new-pedestal-arrow-btn,
    .new-pedestal-view-all,
    .new-pedestal-view-all .np-arrow-left {
        transition: none;
    }
}
