/* ==========================================================================
   IranBroker Forex Symbols — Public Stylesheet
   Uses theme CSS variables: --primary-color, --secondary-color, --gutter
   ========================================================================== */

/* ─── Base layout ────────────────────────────────────────────────────────── */

.irb-forex-page {
    direction: rtl;
    padding-top: 1.5rem;
    padding-bottom: 3rem;
}

.irb-forex-page .container {
    max-width: 1240px;
    margin: 0 auto;
    padding: 0 1rem;
}

/* ─── Section Title ──────────────────────────────────────────────────────── */

.irb-section-title {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    font-size: 1.1rem;
    font-weight: 500;
    font-variation-settings: "wght" 500;
    color: #1e293b;
    margin: 0 0 1.5rem 0;
}

.irb-section-title__bar {
    display: inline-block;
    width: 4px;
    height: 22px;
    border-radius: 2px;
    background: var(--primary-color, #185adb);
    flex-shrink: 0;
}

.irb-section-title__more {
    margin-right: auto;
    display: inline-flex;
    align-items: center;
    gap: 4px;
    color: #64748b;
    font-size: 16px;
    font-weight: 400;
    font-variation-settings: "wght" 500;
    line-height: 20px;
    text-decoration: none;
    white-space: nowrap;
}

.irb-section-title__more:hover {
    color: var(--primary-color, #185adb);
}

.irb-section-title__more:hover svg path {
    fill: var(--primary-color, #185adb);
}

/* ─── Category badges ────────────────────────────────────────────────────── */

.irb-cat-badge {
    display: inline-block;
    padding: 3px 10px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
    white-space: nowrap;
}

.irb-cat-major   { background: #eff6ff; color: #1d4ed8; }
.irb-cat-minor   { background: #f0fdf4; color: #15803d; }
.irb-cat-exotic  { background: #fefce8; color: #a16207; }
.irb-cat-metals  { background: #fff7ed; color: #c2410c; }
.irb-cat-energy  { background: #fdf4ff; color: #7e22ce; }
.irb-cat-indices { background: #f0f9ff; color: #0369a1; }
.irb-cat-crypto  { background: #fff1f2; color: #be123c; }

.irb-cat-border-major   { border-top: 3px solid #1d4ed8; }
.irb-cat-border-minor   { border-top: 3px solid #15803d; }
.irb-cat-border-exotic  { border-top: 3px solid #a16207; }
.irb-cat-border-metals  { border-top: 3px solid #c2410c; }
.irb-cat-border-energy  { border-top: 3px solid #7e22ce; }
.irb-cat-border-indices { border-top: 3px solid #0369a1; }
.irb-cat-border-crypto  { border-top: 3px solid #be123c; }

/* ─── Popular Cards Strip ────────────────────────────────────────────────── */

.irb-popular-strip {
    margin: 16px 0 28px;
}

.irb-popular-strip .irb-section-title {
    margin-bottom: 12px;
}

.irb-popular-strip__slider {
    position: relative;
}

.irb-popular-cards {
    display: flex;
    gap: 8px;
    overflow-x: auto;
    padding: 2px 2px 10px;
    scrollbar-width: none;
    -webkit-overflow-scrolling: touch;
}
.irb-popular-cards::-webkit-scrollbar { display: none; }


/* ─── Archive Page ───────────────────────────────────────────────────────── */

.irb-forex-archive-section {
    margin-bottom: 2.5rem;
}

.irb-symbols-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    gap: 1rem;
}

.irb-symbol-card {
    display: flex;
    flex-direction: column;
    gap: 4px;
    padding: 1rem 1.1rem;
    background: #fff;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    text-decoration: none;
    transition: box-shadow 0.18s, transform 0.18s, border-color 0.18s;
    position: relative;
}

.irb-symbol-card:hover {
    box-shadow: 0 4px 18px rgba(0,0,0,0.09);
    transform: translateY(-2px);
    border-color: var(--primary-color, #185adb);
}

.irb-symbol-card__name {
    font-size: 1rem;
    font-weight: 700;
    color: #1e293b;
    font-family: monospace;
}

.irb-symbol-card__persian {
    font-size: 12px;
    color: #64748b;
}

.irb-symbol-card__popular {
    position: absolute;
    top: 8px;
    left: 10px;
    font-size: 12px;
}

/* ─── new-header-design overrides for forex pages ───────────────────────── */

.irb-forex-page .new-header-design {
    margin: 0 0 1.5rem 0;
}

.irb-forex-page .new-header-design__title::after {
    display: none;
}

.irb-forex-page .new-header-design__title {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 1.5rem;
    flex-wrap: wrap;
}

.irb-symbol-titleblock {
    display: flex !important;
    flex-direction: row;
    align-items: center;
    gap: 14px;
    min-width: 0;
    -webkit-line-clamp: unset !important;
    -webkit-box-orient: unset !important;
    overflow: visible !important;
}
.irb-symbol-titleblock__text {
    display: flex;
    flex-direction: column;
    gap: 8px;
    min-width: 0;
    font-size: 2rem;
}

.irb-symbol-titleblock h1 {
    font-size: 1.5rem !important;
    margin: 0;
    line-height: 1.3;
    font-weight: 600 !important;
    font-variation-settings: "wght" 600 !important;
    white-space: normal !important;
    overflow: visible !important;
    text-overflow: unset !important;
    -webkit-line-clamp: unset !important;
    -webkit-box-orient: unset !important;
    display: block !important;
    word-break: break-word;
}

.irb-title-dash {
    color: #94a3b8;
    font-weight: 300;
}

.irb-symbol-titleblock .irb-cat-badge {
    align-self: flex-start;
    font-size: 12px !important;
    font-weight: 600 !important;
}

/* ─── Price column (right-side of title block, in RTL = right) ───────────── */

.irb-price-column {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 10px;
    flex-shrink: 0;
}

/* ─── Bottom action row: broker buttons + symbol picker ──────────────────── */

.irb-symbol-actions {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}

.irb-actions-sep {
    display: block;
    width: 1px;
    height: 22px;
    background: #e2e8f0;
    flex-shrink: 0;
}

/* ─── Symbol Picker Button ───────────────────────────────────────────────── */

/* ─── Header actions (admin edit only) ───────────────────────────────────── */

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

.irb-edit-symbol-btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 0.45rem 0.9rem;
    background: transparent;
    border: 1px solid rgba(234,88,12,0.35);
    border-radius: 8px;
    font-size: 13px;
    font-weight: 500;
    color: #ea580c;
    text-decoration: none;
    transition: background 0.15s, border-color 0.15s;
    white-space: nowrap;
    flex-shrink: 0;
}

.irb-edit-symbol-btn:hover {
    background: rgba(234,88,12,0.07);
    border-color: rgba(234,88,12,0.6);
    color: #ea580c;
    text-decoration: none;
}

.irb-symbol-picker-btn {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    padding: 0.45rem 0.9rem;
    background: transparent;
    border: 1px solid rgba(24,90,219,0.35);
    border-radius: 8px;
    font-size: 13px;
    font-weight: 500;
    color: var(--primary-color, #185adb);
    cursor: pointer;
    transition: background 0.15s, border-color 0.15s, color 0.15s;
    white-space: nowrap;
    flex-shrink: 0;
}

.irb-symbol-picker-btn:hover {
    background: rgba(24,90,219,0.07);
    border-color: rgba(24,90,219,0.6);
}

/* ─── Symbol Modal ───────────────────────────────────────────────────────── */

.irb-symbol-modal {
    position: fixed;
    inset: 0;
    z-index: 99999;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1rem;
    pointer-events: none;
    opacity: 0;
    transition: opacity 0.2s;
}

.irb-symbol-modal.irb-symbol-modal--open {
    pointer-events: all;
    opacity: 1;
}

.irb-symbol-modal__backdrop {
    position: absolute;
    inset: 0;
    background: rgba(15, 23, 42, 0.55);
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
}

.irb-symbol-modal__panel {
    position: relative;
    background: #fff;
    border-radius: 18px;
    width: 100%;
    max-width: 660px;
    height: 80vh;
    display: flex;
    flex-direction: column;
    direction: rtl;
    box-shadow: 0 24px 64px rgba(0,0,0,0.18);
    transform: translateY(16px) scale(0.98);
    transition: transform 0.22s cubic-bezier(.34,1.36,.64,1);
    overflow: hidden;
}

.irb-symbol-modal--open .irb-symbol-modal__panel {
    transform: translateY(0) scale(1);
}

.irb-symbol-modal__head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1.1rem 1.25rem 0.9rem;
    border-bottom: 1px solid #f1f5f9;
    flex-shrink: 0;
}

.irb-symbol-modal__title {
    font-size: 15px;
    font-weight: 700;
    color: #1e293b;
}

.irb-symbol-modal__close {
    background: none;
    border: none;
    padding: 4px;
    cursor: pointer;
    color: #94a3b8;
    display: flex;
    align-items: center;
    border-radius: 6px;
    transition: color 0.15s, background 0.15s;
}

.irb-symbol-modal__close:hover {
    color: #334155;
    background: #f1f5f9;
}

.irb-symbol-modal__search-wrap {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 0.75rem 1.25rem;
    border-bottom: 1px solid #f1f5f9;
    flex-shrink: 0;
}

.irb-symbol-modal__search {
    flex: 1;
    border: none;
    outline: none;
    font-size: 14px;
    color: #1e293b;
    background: transparent;
    direction: rtl;
    text-align: right;
}

.irb-symbol-modal__search::placeholder { color: #94a3b8; }

/* wrapper for cats strip + arrows */
.irb-cats-wrap {
    position: relative;
    flex-shrink: 0;
    border-bottom: 1px solid #f1f5f9;
}

/* fade overlays to hint overflow */
.irb-cats-wrap::before,
.irb-cats-wrap::after {
    content: '';
    position: absolute;
    top: 0;
    bottom: 0;
    width: 36px;
    pointer-events: none;
    z-index: 1;
    transition: opacity 0.2s;
}
.irb-cats-wrap::before {
    right: 0;
    background: linear-gradient(to left, #fff 60%, transparent);
}
.irb-cats-wrap::after {
    left: 0;
    background: linear-gradient(to right, #fff 60%, transparent);
}
.irb-cats-wrap.irb-cats-at-start::before { opacity: 0; }
.irb-cats-wrap.irb-cats-at-end::after    { opacity: 0; }

.irb-symbol-modal__cats {
    display: flex;
    gap: 6px;
    padding: 0.75rem 2.25rem;
    overflow-x: auto;
    scrollbar-width: none;
    -webkit-overflow-scrolling: touch;
    border-bottom: none;
}

.irb-symbol-modal__cats::-webkit-scrollbar { display: none; }

/* cats scroll arrows */
.irb-cats-arrow {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    z-index: 2;
    width: 26px;
    height: 26px;
    background: #fff;
    border: 1px solid #e2e8f0;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    padding: 0;
    color: #64748b;
    box-shadow: 0 1px 4px rgba(0,0,0,0.08);
    transition: opacity 0.2s, color 0.15s;
}
.irb-cats-arrow:hover { color: #1e293b; }
.irb-cats-arrow--right { right: 4px; }
.irb-cats-arrow--left  { left: 4px; }
.irb-cats-arrow--hidden {
    opacity: 0;
    pointer-events: none;
}

.irb-cat-tab {
    padding: 5px 14px;
    border-radius: 20px;
    border: 1px solid #e2e8f0;
    background: #fff;
    font-size: 12px;
    color: #64748b;
    cursor: pointer;
    white-space: nowrap;
    transition: background 0.15s, color 0.15s, border-color 0.15s;
    flex-shrink: 0;
}

.irb-cat-tab:not(.irb-cat-tab--active):hover {
    border-color: var(--primary-color, #185adb);
    color: var(--primary-color, #185adb);
    background: #f0f5ff;
}

.irb-cat-tab--active {
    background: var(--primary-color, #185adb);
    border-color: var(--primary-color, #185adb);
    color: #fff;
}


.irb-symbol-modal__list {
    overflow-y: auto;
    flex: 1;
    padding: 0.5rem 0;
}

.irb-symbol-row {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 1.25rem;
    text-decoration: none;
    transition: background 0.12s;
    cursor: pointer;
}

.irb-symbol-row:hover { background: #f8fafc; }

.irb-symbol-row--active { background: #eff6ff; }

.irb-symbol-row__name {
    font-size: 14px;
    font-weight: 700;
    font-variation-settings: "wght" 700;
    color: #1e293b;
    font-family: inherit;
    min-width: 80px;
    flex-shrink: 0;
}

.irb-symbol-row__persian {
    font-size: 13px;
    color: #64748b;
    flex: 1;
}

.irb-symbol-row__cat {
    font-size: 10px !important;
    padding: 2px 8px !important;
    flex-shrink: 0;
}

.irb-symbol-row__check {
    color: var(--primary-color, #185adb);
    display: flex;
    align-items: center;
    flex-shrink: 0;
}

.irb-symbol-row__bm {
    background: none;
    border: none;
    padding: 2px;
    cursor: pointer;
    color: #cbd5e1;
    display: flex;
    align-items: center;
    flex-shrink: 0;
    transition: color 0.15s;
    order: -1;
}
.irb-symbol-row__bm:hover { color: #94a3b8; }
.irb-symbol-row__bm.irb-bm-btn--active { color: #185adb; }
.irb-symbol-row__bm.irb-bm-btn--active .irb-bm-icon { fill: #185adb; }

.irb-symbol-modal__empty {
    text-align: center;
    padding: 2rem;
    color: #94a3b8;
    font-size: 14px;
}

@media (max-width: 600px) {
    .irb-symbol-modal { align-items: flex-end; padding: 0; }
    .irb-symbol-modal__panel {
        height: 90vh;
        max-width: 100%;
        border-radius: 18px 18px 0 0;
    }
}

/* ─── Chart Section ──────────────────────────────────────────────────────── */

.irb-forex-chart-section {
    margin-bottom: 3.5rem;
}

.irb-forex-chart-wrap {
    background: #fff;
    border: 1px solid #e2e8f0;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 2px 12px rgba(0,0,0,0.05);
}

/* ─── Live Price Bar ─────────────────────────────────────────────────────── */

.irb-price-bar {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 10px;
    direction: ltr;
    flex-shrink: 0;
}

.irb-price-bar__top {
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 10px;
}

.irb-price-bar__price {
    font-size: 2.2rem;
    font-weight: 900;
    color: #1e293b;
    letter-spacing: -1px;
    line-height: 1;
}

.irb-price-bar__meta {
    display: flex;
    align-items: center;
    gap: 8px;
}

.irb-price-bar__live {
    display: inline-flex;
    align-items: center;
    gap: 4px;
}

/* ─── Daily Stats Row ────────────────────────────────────────────────────── */

.irb-price-bar__stats {
    display: flex;
    align-items: stretch;
    gap: 0;
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 10px;
    direction: rtl;
    position: relative;
    overflow: visible;
}

.irb-price-bar__stats .irb-price-stat:first-child  { border-radius: 0 10px 10px 0; }
.irb-price-bar__stats .irb-price-stat:last-child   { border-radius: 10px 0 0 10px; }

.irb-price-stat {
    display: flex;
    flex-direction: column;
    gap: 3px;
    padding: 7px 14px;
    border-left: 1px solid #e2e8f0;
}

.irb-price-stat:last-child {
    border-left: none;
}

.irb-price-stat__label {
    display: inline-flex;
    align-items: center;
    gap: 3px;
    font-size: 11px;
    color: #64748b;
    font-weight: 600;
    white-space: nowrap;
}

.irb-price-stat__val {
    font-size: 13px;
    font-weight: 700;
    color: #1e293b;
    direction: ltr;
    white-space: nowrap;
}

.irb-price-stat--high .irb-price-stat__val { color: #16a34a; }
.irb-price-stat--low  .irb-price-stat__val { color: #dc2626; }

/* ─── Tooltip ────────────────────────────────────────────────────────────── */

.irb-tip {
    position: relative;
    display: inline-flex;
    align-items: center;
    color: #cbd5e1;
    cursor: default;
    line-height: 1;
}

.irb-tip:hover { color: #94a3b8; }

.irb-tip::after {
    content: attr(data-tip);
    position: absolute;
    bottom: calc(100% + 7px);
    left: 50%;
    transform: translateX(-50%);
    background: #1e293b;
    color: #f1f5f9;
    font-size: 11px;
    font-weight: 400;
    padding: 5px 10px;
    border-radius: 7px;
    white-space: nowrap;
    pointer-events: none;
    opacity: 0;
    transition: opacity 0.15s, transform 0.15s;
    transform: translateX(-50%) translateY(3px);
    z-index: 200;
    direction: rtl;
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
}

.irb-tip::before {
    content: '';
    position: absolute;
    bottom: calc(100% + 3px);
    left: 50%;
    transform: translateX(-50%);
    border: 4px solid transparent;
    border-top-color: #1e293b;
    pointer-events: none;
    opacity: 0;
    transition: opacity 0.15s;
    z-index: 200;
}

.irb-tip:hover::after {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
}

.irb-tip:hover::before { opacity: 1; }

.irb-price-bar__dot {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: #22c55e;
    flex-shrink: 0;
    animation: irb-live-pulse 1.6s ease-in-out infinite;
}

@keyframes irb-live-pulse {
    0%, 100% { opacity: 1; box-shadow: 0 0 0 0 rgba(34,197,94,0.4); }
    50%       { opacity: 0.7; box-shadow: 0 0 0 4px rgba(34,197,94,0); }
}

.irb-price-bar__change {
    font-size: 13px;
    font-weight: 600;
    padding: 2px 9px;
    border-radius: 6px;
    font-family: inherit;
}

.irb-price-bar__change:not(.irb-price-bar__change--up):not(.irb-price-bar__change--down) { color: #64748b; background: #f1f5f9; }
.irb-price-bar__change--up   { color: #16a34a; background: #f0fdf4; }
.irb-price-bar__change--down { color: #dc2626; background: #fef2f2; }

/* ─── Live Overview Section ──────────────────────────────────────────────── */

.irb-live-overview-section {
    margin-bottom: 3.5rem;
}

.irb-live-overview__body {
    background: #fff;
    border: 1px solid #e2e8f0;
    border-radius: 16px;
    padding: 24px 28px;
    font-size: 15px;
    line-height: 2;
    color: #334155;
    direction: rtl;
    box-shadow: 0 2px 12px rgba(0,0,0,0.04);
}

.irb-live-overview__body p {
    margin: 0 0 10px;
}

.irb-live-overview__body p:last-child {
    margin-bottom: 0;
}

.irb-live-overview__body mark {
    background: #eff6ff;
    color: #1d4ed8;
    padding: 1px 7px;
    border-radius: 5px;
    font-weight: 700;
    font-style: normal;
}

.irb-ov-up   { color: #16a34a; font-weight: 600; }
.irb-ov-down { color: #dc2626; font-weight: 600; }

/* ─── Technical Analysis Section ────────────────────────────────────────── */

.irb-forex-ta-section {
    margin-bottom: 3.5rem;
}

.irb-forex-ta-wrap {
    background: #fff;
    border: 1px solid #e2e8f0;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 2px 12px rgba(0,0,0,0.05);
    padding: 1.5rem;
}

.tradingview-widget-container,
.tradingview-widget-container__widget {
    width: 100%;
}

/* ─── Posts Grid (News & Analysis) ──────────────────────────────────────── */

.irb-forex-posts-section {
    background: #f8fafc;
    border-radius: 16px;
    padding: 1.75rem 0;
    margin-bottom: 3rem;
}

.irb-posts-slider {
    position: relative;
}

/* ─── Splide-based sliders ───────────────────────────────────────────────── */

.irb-posts-splide {
    position: relative;
}

/* Allow card hover shadow to show outside the clipped track area */
.irb-posts-splide .splide__track {
    padding-bottom: 8px;
    margin-bottom: -8px;
    overflow: hidden;
}

/* Equal-height slides: stretch all slides to tallest in row */
.irb-posts-splide .splide__list {
    align-items: stretch;
}
.irb-posts-splide .splide__slide {
    height: auto;
    display: flex;
}
.irb-posts-splide .splide__slide > * {
    flex: 1;
}

/* Legacy fallback grid (kept for any non-splide context) */
.irb-posts-grid {
    display: flex;
    flex-wrap: nowrap;
    gap: 1.5rem;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    scrollbar-width: none;
    -ms-overflow-style: none;
    padding-bottom: 4px;
}

.irb-posts-grid::-webkit-scrollbar {
    display: none;
}

/* ─── Slider Arrows — matches .splide-arrow--right/left-php from theme ───── */

.irb-slider-arrow {
    position: absolute;
    top: 50%;
    z-index: 2;
    background: #fff;
    border: 1px solid #ebf0f5;
    border-radius: 36px;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: background 0.15s, border-color 0.15s;
    padding: 0;
    flex-shrink: 0;
}

.irb-slider-arrow:hover {
    background: #f8fafc;
    border-color: #cbd5e1;
}

.irb-slider-arrow--prev {
    right: 0;
    transform: translate3d(50%, -50%, 0);
}

.irb-slider-arrow--next {
    left: 0;
    transform: translate3d(-50%, -50%, 0);
}

.irb-slider-arrow--hidden {
    opacity: 0;
    pointer-events: none;
}

@media (max-width: 767px) {
    .irb-slider-arrow { display: none; }
}

/* ─── Post Card — matches .php-splide__card from theme ──────────────────── */

.irb-post-card {
    background: #fff;
    border: 1px solid #ebf0f5;
    border-radius: 12px;
    overflow: hidden;
    transition: box-shadow 0.18s;
    display: flex;
    flex-direction: column;
    flex-shrink: 0;
    width: 296px;
    scroll-snap-align: start;
}

.irb-post-card:hover {
    box-shadow: 0 4px 16px rgba(0,0,0,0.08);
}

.irb-post-card__thumb-link {
    display: block;
    text-decoration: none;
}

.irb-post-card__thumb {
    position: relative;
    width: 100%;
    aspect-ratio: 16 / 9;
    overflow: hidden;
    background: #f1f5f9;
}

.irb-post-card__thumb--no-image {
    aspect-ratio: 16 / 5;
    background: linear-gradient(135deg, #f8faff 0%, #eff6ff 100%);
}

.irb-post-card__thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.3s;
}

.irb-post-card:hover .irb-post-card__thumb img {
    transform: scale(1.04);
}

.irb-post-card__badge {
    position: absolute;
    bottom: 10px;
    right: 10px;
    padding: 3px 10px;
    border-radius: 20px;
    font-size: 11px;
    font-weight: 700;
}

.irb-badge-analysis {
    background: var(--primary-color, #185adb);
    color: #fff;
}

.irb-badge-news {
    background: var(--secondary-color, #04a448);
    color: #fff;
}

.irb-post-card__body {
    padding: 20px 20px 0;
    display: flex;
    flex-direction: column;
    gap: 8px;
    flex: 1;
}

.irb-post-card__title {
    font-size: 15px;
    font-weight: 500;
    font-variation-settings: "wght" 500;
    line-height: 1.7;
    margin: 0;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.irb-post-card__title a {
    color: #1e293b;
    text-decoration: none;
}

.irb-post-card__title a:hover {
    color: var(--primary-color, #185adb);
}

.irb-post-card__excerpt {
    font-size: 13px;
    color: #64748b;
    line-height: 1.65;
    margin: 0;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* divider — matches .php-splide__divider */
.irb-post-card__divider {
    width: 100%;
    height: 1px;
    background: #ebf0f5;
    margin-top: 16px;
    flex-shrink: 0;
}

/* footer — matches .php-splide__btns layout */
.irb-post-card__footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    padding: 12px 20px 20px;
}

.irb-post-card__meta {
    display: flex;
    flex-direction: column;
    gap: 2px;
    font-size: 12px;
    color: #94a3b8;
    min-width: 0;
}

.irb-post-card__date,
.irb-post-card__author {
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* "مشاهده" button — matches .php__btn--transparent */
.irb-post-card__btn {
    display: flex;
    padding: 8px 12px;
    justify-content: center;
    align-items: center;
    border-radius: 8px;
    border: 1px solid #e2e8f0;
    color: #334155;
    font-size: 13px;
    font-style: normal;
    font-weight: 400;
    line-height: 20px;
    text-decoration: none;
    white-space: nowrap;
    flex-shrink: 0;
    transition: border-color 0.15s, color 0.15s;
}

.irb-post-card__btn:hover {
    border-color: var(--primary-color, #185adb);
    color: var(--primary-color, #185adb);
}

/* ─── Custom Content ─────────────────────────────────────────────────────── */

.irb-forex-content-section {
    margin-bottom: 3.5rem;
}

.irb-archive-content-section {
    margin-top: 2.5rem;
}

.irb-forex-custom-content,
.irb-archive-custom-content {
    line-height: 1.9;
    color: #334155;
}

/* ─── Related Symbols ────────────────────────────────────────────────────── */

/* ─── Community CTA ──────────────────────────────────────────────────────── */

/* ─── Community CTA ──────────────────────────────────────────────────────── */

.irb-community-cta-wrap {
    margin-bottom: 2rem;
}

.irb-community-cta {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1.25rem;
    padding: 1.1rem 1.4rem;
    background: #fff;
    border: 1px solid #bfdbfe;
    border-right: 4px solid #2071f0;
    border-radius: 12px;
    box-shadow: 0 4px 20px rgba(32,113,240,.09);
    text-decoration: none;
    color: inherit;
    transition: box-shadow 0.18s, background 0.18s, transform 0.15s;
}

.irb-community-cta:hover {
    background: #f0f6ff;
    box-shadow: 0 6px 28px rgba(32,113,240,.16);
    transform: translateY(-1px);
    text-decoration: none;
    color: inherit;
}

.irb-community-cta__body {
    display: flex;
    align-items: center;
    gap: 1rem;
    min-width: 0;
}

.irb-community-cta__icon {
    flex-shrink: 0;
}

.irb-community-cta__body div {
    display: flex;
    flex-direction: column;
    gap: 4px;
    min-width: 0;
}

.irb-community-cta__body strong {
    font-size: 0.95rem;
    font-weight: 700;
    font-variation-settings: "wght" 700;
    color: #0f172a;
    white-space: normal;
    line-height: 1.4;
}

.irb-community-cta__body span {
    font-size: 0.8rem;
    color: #475569;
    line-height: 1.5;
}

.irb-community-cta__action {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    flex-shrink: 0;
    padding: 0.5rem 1rem;
    background: #2071f0;
    border-radius: 8px;
    font-size: 0.8rem;
    font-weight: 600;
    font-variation-settings: "wght" 600;
    color: #fff;
    white-space: nowrap;
    transition: background 0.15s;
}

.irb-community-cta:hover .irb-community-cta__action {
    background: #1a5fd4;
}

@media (max-width: 600px) {
    .irb-community-cta {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.85rem;
    }
    .irb-community-cta__action { width: 100%; justify-content: center; }
}

@media (max-width: 500px) {
    .irb-community-cta__body strong { font-size: 0.88rem; }
}

/* ─────────────────────────────────────────────────────────────────────────── */

.irb-forex-related-section {
    margin: 16px 0 28px;
}

.irb-forex-related-section .irb-section-title {
    margin-bottom: 12px;
}

.irb-related-symbols-scroll {
    gap: 8px;
}

.irb-related-symbol-card {
    flex-shrink: 0;
    display: flex;
    flex-direction: column;
    gap: 4px;
    padding: 0.9rem 1.1rem;
    background: #fff;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    text-decoration: none;
    min-width: 140px;
    transition: box-shadow 0.18s, transform 0.18s;
}

.irb-related-symbol-card:hover {
    box-shadow: 0 4px 14px rgba(0,0,0,0.09);
    transform: translateY(-2px);
}

.irb-related-symbol-card__name {
    font-size: 0.95rem;
    font-weight: 700;
    color: #1e293b;
    font-family: monospace;
}

.irb-related-symbol-card__persian {
    font-size: 11px;
    color: #64748b;
}

.irb-related-symbol-card__cat {
    font-size: 10px;
    color: #94a3b8;
    margin-top: 2px;
}

/* ─── Symbol Cards (related / popular) ──────────────────────────────────── */

.irb-sym-card {
    display: flex;
    flex-direction: column;
    gap: 14px;
    padding: 18px 16px;
    border-radius: 12px;
    border: 1px solid #ebf0f5;
    background: #fff;
    min-width: 168px;
    width: 180px;
    flex-shrink: 0;
    text-decoration: none;
    direction: rtl;
    transition: border-color 0.15s, box-shadow 0.15s;
    position: relative;
}

/* green live pulse dot */
.irb-sym-card::after {
    content: '';
    position: absolute;
    top: 11px;
    left: 12px;
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: #22c55e;
    animation: irb-live-pulse 1.6s ease-in-out infinite;
}

.irb-sym-card:hover {
    border-color: #bfdbfe;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.06);
    text-decoration: none;
}

.irb-sym-card__head {
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 10px;
    margin-bottom: 8px;
}

.irb-sym-card__head-text {
    display: flex;
    flex-direction: column;
    gap: 2px;
    min-width: 0;
}

.irb-sym-card__name-row {
    display: flex;
    align-items: center;
    gap: 4px;
}

.irb-sym-card__name {
    font-size: 15px;
    font-weight: 700;
    color: #1e293b;
    line-height: 1.2;
    font-style: normal;
}

.irb-sym-card__persian {
    font-size: 11px;
    color: #94a3b8;
    font-weight: 400;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.irb-sym-card__price {
    font-size: 18px;
    font-weight: 900;
    color: #94a3b8;
    direction: ltr;
    text-align: right;
    margin: 0;
    font-family: inherit;
    transition: color 0.3s;
    letter-spacing: -0.3px;
}

.irb-sym-card__price--live {
    color: #1e293b;
}

.irb-sym-card__foot {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.irb-sym-card__cat {
    font-size: 10px;
    color: #94a3b8;
}

/* ─── Responsive ─────────────────────────────────────────────────────────── */

@media (max-width: 768px) {
    .irb-forex-page .new-header-design__top-section {
        flex-wrap: nowrap;
        gap: 0.75rem;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: none;
    }
    .irb-forex-page .new-header-design__top-section::-webkit-scrollbar {
        display: none;
    }
    .irb-forex-page .new-header-design__breadcrump .breadcrumbs {
        flex-wrap: nowrap;
        white-space: nowrap;
    }

    .irb-forex-page .new-header-design__title {
        flex-direction: column;
        gap: 1rem;
    }

    .irb-price-column {
        width: 100%;
    }

    .irb-forex-symbol-selector {
        width: 100%;
        flex-direction: column;
        align-items: flex-start;
    }

    .irb-symbol-select {
        width: 100%;
        min-width: unset;
    }

    .irb-symbols-grid {
        grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
    }

    .irb-post-card {
        width: 260px;
    }

    .irb-forex-custom-content {
        padding: 1.25rem;
    }
}

@media (max-width: 600px) {
    /* Shrink main h1 so it fits on one or two lines on small screens */
    .irb-symbol-titleblock h1 {
        font-size: 1.25rem;
    }

    /* Archive page title: undo theme's line-clamp so full title shows */
    .irb-forex-archive-page .new-header-design h1,
    .irb-forex-archive-page .new-header-design__title > * {
        font-size: 1.35rem !important;
        -webkit-line-clamp: unset !important;
        -webkit-box-orient: unset !important;
        overflow: visible !important;
        display: block !important;
        white-space: normal !important;
    }

    /* Remove extra top space above breadcrumb on archive page */
    .irb-forex-archive-page .new-header-design__top-section {
        padding-top: 0 !important;
    }

}

@media (max-width: 480px) {
    .irb-symbol-titleblock h1 {
        font-size: 1.1rem;
    }

    .irb-symbols-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 600px) {
    /* Override Splide inline width on post-card slides so next card peeks */
    .irb-forex-posts-section .splide__slide {
        width: 72vw !important;
        min-width: 72vw !important;
        max-width: 72vw !important;
    }
    .irb-forex-posts-section .irb-post-card {
        width: 100%;
    }
    .irb-forex-posts-section .splide__list {
        gap: 12px;
    }
}

/* ─── Description collapse (مشابه صفحه coins) ──────────────────────────── */

/* ─── CSS-only description expand/collapse ────────────────────────────────
   Uses a hidden checkbox + adjacent-sibling selectors.
   Full content is in the HTML source at all times (SEO-safe).
   ─────────────────────────────────────────────────────────────────────── */

/* ─── Collapsible content block (JS-powered) ─────────────────────────────── */

/* Collapsed state (default) */
.irb-content-wrap {
    border-radius: 16px;
    border: 1px solid #e2e8f0;
    background: #fff;
    box-shadow: 0 2px 12px rgba(0,0,0,0.04);
    padding: 2rem 2rem 0;
    max-height: 420px;
    overflow: hidden;
    position: relative;
}

/* Expanded state */
.irb-content-wrap.is-open {
    max-height: none;
    overflow: visible;
    padding-bottom: 2rem;
}

/* Fade overlay — collapsed */
.irb-content-wrap .irb-content-collapse__fade {
    position: absolute;
    bottom: 0;
    right: 0;
    left: 0;
    display: flex;
    align-items: flex-end;
    justify-content: center;
    min-height: 140px;
    padding-bottom: 20px;
    background: linear-gradient(0deg, #fff 55%, rgba(255,255,255,0));
    pointer-events: none;
}

/* Fade overlay — expanded */
.irb-content-wrap.is-open .irb-content-collapse__fade {
    position: static;
    min-height: auto;
    background: none;
    padding: 20px 0 0;
    pointer-events: auto;
}

/* Toggle button */
.irb-content-collapse__btn {
    pointer-events: all;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: #fff;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    padding: 8px 22px;
    font-size: 14px;
    color: #374151;
    cursor: pointer;
    font-family: inherit;
    line-height: 1.5;
    transition: border-color 0.2s, background 0.2s;
    direction: rtl;
    user-select: none;
}

.irb-content-collapse__btn:hover {
    border-color: #94a3b8;
    background: #f1f5f9;
}

/* Button text: show correct string per state */
.irb-btn-text-open { display: none; }
.irb-content-wrap.is-open .irb-btn-text-closed { display: none; }
.irb-content-wrap.is-open .irb-btn-text-open   { display: inline; }

/* Arrow icon */
.irb-btn-arrow {
    flex-shrink: 0;
    transition: transform 0.3s ease;
}

.irb-content-wrap.is-open .irb-btn-arrow {
    transform: rotate(180deg);
}

/* Short content: hide the toggle entirely (set by JS) */
.irb-content-wrap.irb-content-wrap--short {
    max-height: none;
    overflow: visible;
    padding-bottom: 2rem;
}

/* ─── Archive Page ───────────────────────────────────────────────────────── */

.irb-forex-archive-page .new-header-design {
    margin-bottom: 1.75rem;
}

.irb-archive-subtitle {
    margin: 4px 0 0;
    font-size: 14px;
    color: #64748b;
    font-weight: 400;
}

/* ── Toolbar ────────────────────────────────────────────────────────── */

.irb-archive-toolbar {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 1.25rem;
    flex-wrap: wrap;
    position: sticky;
    top: 0; /* overridden by JS to track actual header bottom */
    z-index: 50;
    background: #f8fafc;
    padding: 8px 0;
    margin-top: -8px;
}

.irb-archive-cats-outer {
    flex: 1;
    min-width: 0;
    display: flex;
    align-items: center;
    gap: 4px;
    position: relative;
}

.irb-archive-cats {
    display: flex;
    gap: 6px;
    overflow-x: auto;
    scrollbar-width: none;
    padding-bottom: 4px;
    scroll-behavior: smooth;
    flex: 1;
    min-width: 0;
    -webkit-overflow-scrolling: touch;
    touch-action: pan-x;
}

.irb-archive-cats::-webkit-scrollbar { display: none; }

/* archive page arrows override the modal's position:absolute + transform */
.irb-archive-cats-outer .irb-cats-arrow {
    position: static;
    transform: none;
    top: auto;
    flex-shrink: 0;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    border: 1px solid #e2e8f0;
    background: #fff;
    color: #64748b;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: border-color 0.15s, color 0.15s, background 0.15s;
    padding: 0;
}

.irb-archive-cats-outer .irb-cats-arrow[hidden] { display: none; }

.irb-archive-cats-outer .irb-cats-arrow:hover {
    border-color: var(--primary-color, #185adb);
    color: var(--primary-color, #185adb);
    background: #f0f5ff;
}

/* dragging cursor while mouse-scrolling */
.irb-archive-cats--dragging {
    cursor: grabbing;
    scroll-behavior: auto;
    user-select: none;
}

@media (max-width: 600px) {
    .irb-cats-arrow { display: none !important; }
}

.irb-archive-cat-btn {
    padding: 4px 12px;
    border-radius: 20px;
    border: 1px solid #e2e8f0;
    background: #fff;
    font-size: 13px;
    color: #64748b;
    cursor: pointer;
    white-space: nowrap;
    flex-shrink: 0;
    transition: background 0.15s, color 0.15s, border-color 0.15s;
    font-family: inherit;
}

.irb-archive-cat-btn:hover {
    border-color: var(--primary-color, #185adb);
    color: var(--primary-color, #185adb);
    background: #f0f5ff;
}

.irb-archive-cat-btn--active {
    background: var(--primary-color, #185adb);
    border-color: var(--primary-color, #185adb);
    color: #fff;
}

.irb-archive-cat-btn--active:hover {
    background: var(--primary-color, #185adb);
    color: #fff;
}

.irb-archive-cat-btn--popular {
    display: inline-flex;
    align-items: center;
    gap: 5px;
}

.irb-archive-cat-btn--popular.irb-archive-cat-btn--active .irb-popular-icon svg path {
    fill: #fff;
}

.irb-archive-search-wrap {
    display: flex;
    align-items: center;
    gap: 8px;
    background: #fff;
    border: 1px solid #e2e8f0;
    border-radius: 10px;
    padding: 7px 14px;
    flex-shrink: 0;
    transition: border-color 0.15s;
}

.irb-archive-search-wrap:focus-within {
    border-color: var(--primary-color, #185adb);
}

.irb-archive-search {
    border: none;
    outline: none;
    font-size: 13px;
    color: #1e293b;
    background: transparent;
    width: 180px;
    direction: rtl;
    font-family: inherit;
}

.irb-archive-search::placeholder { color: #94a3b8; }

/* ── Table wrapper ──────────────────────────────────────────────────── */

.irb-archive-table-wrap {
    background: #fff;
    border: 1px solid #e2e8f0;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 2px 12px rgba(0,0,0,0.04);
}

.irb-archive-table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
    direction: rtl;
}

/* ── Headers ────────────────────────────────────────────────────────── */

.irb-th {
    padding: 13px 18px;
    font-size: 12px;
    font-weight: 600;
    color: #64748b;
    text-align: right;
    background: #f8fafc;
    border-bottom: 1px solid #e2e8f0;
    white-space: nowrap;
    user-select: none;
}

/* Corner cells — required when border-collapse: separate to clip with wrapper's border-radius */
.irb-archive-table thead tr:first-child th:first-child { border-radius: 0 15px 0 0; }
.irb-archive-table thead tr:first-child th:last-child  { border-radius: 15px 0 0 0; }
.irb-archive-table tbody tr:last-child td:first-child  { border-radius: 0 0 15px 0; }
.irb-archive-table tbody tr:last-child td:last-child   { border-radius: 0 0 0 15px; }

.irb-th--num   { text-align: center; direction: ltr; width: 180px; }
.irb-th--bm-col { width: 52px; padding: 0; }

.irb-th--sortable {
    cursor: pointer;
    transition: color 0.15s, background 0.15s;
}

.irb-th--sortable:hover {
    color: #334155;
    background: #f1f5f9;
}

.irb-th--cat-col {
    width: 220px;
    padding-right: 24px !important;
}

.irb-sort-icon {
    display: inline-flex;
    align-items: center;
    margin-right: 4px;
    color: #cbd5e1;
    vertical-align: middle;
    transition: color 0.15s;
}

.irb-th--sort-asc .irb-sort-icon,
.irb-th--sort-desc .irb-sort-icon {
    color: var(--primary-color, #185adb);
}

/* ── Rows ───────────────────────────────────────────────────────────── */

.irb-archive-row td {
    padding: 13px 18px;
    border-bottom: 1px solid #f1f5f9;
    vertical-align: middle;
    background: #fff;
}

.irb-archive-row:last-child td {
    border-bottom: none;
}

.irb-archive-row:hover td {
    background: #f8fafc;
}

/* ── Name cell ──────────────────────────────────────────────────────── */

.irb-ar__name-cell {
    white-space: nowrap;
}

.irb-ar__row-link {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    text-decoration: none;
    color: inherit;
}

/* Symbol logos */
.irb-sym-logo { flex-shrink: 0; }
.irb-sym-logo--single { border-radius: 50%; display: block; }
.irb-sym-logo--pair   { display: inline-block; }
.irb-sym-logo--pair img { object-fit: cover; }

.irb-ar__dot {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: #22c55e;
    flex-shrink: 0;
    animation: irb-live-pulse 1.6s ease-in-out infinite;
}

.irb-ar__sym {
    font-size: 14px;
    font-weight: 700;
    font-variation-settings: "wght" 700;
    color: #1e293b;
    font-family: inherit;
    letter-spacing: 0.3px;
    transition: color 0.15s;
}

.irb-ar__row-link:hover .irb-ar__sym {
    color: var(--primary-color, #185adb);
}

.irb-popular-icon {
    display: inline-block;
    vertical-align: middle;
    flex-shrink: 0;
    line-height: 1;
}

/* ── Other cells ────────────────────────────────────────────────────── */

.irb-ar__persian {
    font-size: 13px;
    color: #64748b;
    text-align: right;
}

.irb-ar__cat {
    text-align: right;
    padding-right: 24px !important;
}

/* ── Bookmark cell in archive table ─────────────────────────────────── */
.irb-ar__bm-cell {
    width: 36px;
    text-align: center;
    padding: 0 12px 0 16px !important;
}

/* ── Bookmark button ─────────────────────────────────────────────────── */
.irb-bm-btn {
    background: none;
    border: none;
    padding: 5px;
    cursor: pointer;
    color: #cbd5e1;
    display: inline-flex;
    align-items: center;
    gap: 5px;
    border-radius: 6px;
    transition: color 0.15s;
    line-height: 1;
    font-family: inherit;
    font-size: 13px;
}
.irb-bm-btn:hover {
    color: #94a3b8;
}
.irb-bm-btn--active {
    color: var(--primary-color, #185adb);
}
.irb-bm-btn--active .irb-bm-icon {
    fill: currentColor;
}
.irb-bm-btn--active .irb-bm-label {
    color: var(--primary-color, #185adb);
}

/* Bookmark button on symbol page */
.irb-symbol-meta-row {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
    margin-top: 6px;
}
.irb-bm-btn--page {
    color: #94a3b8;
    font-size: 13px;
    border: 1px solid #e2e8f0;
    padding: 4px 10px;
    border-radius: 8px;
    background: #fff;
}
.irb-bm-btn--page:hover {
    border-color: #94a3b8;
    color: #64748b;
}
.irb-bm-btn--page.irb-bm-btn--active {
    border-color: var(--primary-color, #185adb);
    background: #f0f5ff;
    color: var(--primary-color, #185adb);
}

/* Bookmarks tab in category strip */
.irb-archive-cat-btn--bookmarks.irb-archive-cat-btn--active {
    background: #f0f5ff;
    border-color: var(--primary-color, #185adb);
    color: var(--primary-color, #185adb);
}

.irb-ar__price {
    color: #94a3b8;
    white-space: nowrap;
    transition: color .25s;
    text-align: center;
}

.irb-ar__price-inner {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 5px;
}

.irb-ar__price-num {
    font-size: 15px;
    font-weight: 500;
    font-variation-settings: "wght" 500;
    direction: ltr;
    font-family: inherit;
    letter-spacing: 0.01em;
}

.irb-ar__chg {
    display: none;
    font-size: 9px;
    font-weight: 600;
    direction: ltr;
    font-family: inherit;
    font-variant-numeric: tabular-nums;
    padding: 1px 5px;
    border-radius: 5px;
    white-space: nowrap;
    flex-shrink: 0;
}

.irb-ar__chg--up   { display: inline-flex; color: #16a34a; background: #f0fdf4; }
.irb-ar__chg--down { display: inline-flex; color: #dc2626; background: #fef2f2; }

.irb-ar__price--live    { color: #1e293b; }
.irb-ar__price--no-live { color: #d1d5db; }


/* #3 Clickable rows */
.irb-archive-row[data-href] {
    cursor: pointer;
}
.irb-archive-row[data-href]:hover td {
    background: #f1f5f9;
}

@keyframes irb-flash-up {
    0%   { color: #16a34a; }
    70%  { color: #16a34a; }
    100% { color: #1e293b; }
}
@keyframes irb-flash-down {
    0%   { color: #dc2626; }
    70%  { color: #dc2626; }
    100% { color: #1e293b; }
}

.irb-ar__price--up,   .irb-sym-card__price.irb-ar__price--up   { animation: irb-flash-up   1.2s ease forwards; }
.irb-ar__price--down, .irb-sym-card__price.irb-ar__price--down { animation: irb-flash-down 1.2s ease forwards; }
.irb-sym-card__price.irb-ar__price--live { color: #1e293b; }

/* ── Empty state ────────────────────────────────────────────────────── */

.irb-archive-empty {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
    padding: 3rem;
    color: #94a3b8;
    font-size: 14px;
}

.irb-archive-empty p { margin: 0; }

/* ── Responsive ─────────────────────────────────────────────────────── */

@media (max-width: 768px) {
    .irb-archive-toolbar {
        flex-direction: column;
        align-items: stretch;
    }

    .irb-archive-search { width: 100%; }

    .irb-th--persian,
    .irb-ar__persian,
    .irb-th--cat-col,
    .irb-ar__cat { display: none; }
}

/* ─── Broker Buy / Sell Buttons ──────────────────────────────────────────── */

.irb-broker-btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 7px 18px;
    border-radius: 6px;
    font-size: 13px;
    font-weight: 600;
    font-variation-settings: "wght" 600;
    text-decoration: none;
    transition: opacity .15s, transform .1s;
    white-space: nowrap;
    line-height: 1;
}

.irb-broker-btn:hover { opacity: .88; transform: translateY(-1px); }
.irb-broker-btn:active { transform: translateY(0); }

.irb-broker-btn--buy {
    background: #16a34a;
    color: #fff;
}

.irb-broker-btn--sell {
    background: #dc2626;
    color: #fff;
}

/* ─── Forex Sessions Widget ──────────────────────────────────────────────── */

.irb-sessions-section {
    margin: 28px 0 0;
}

.irb-sessions-section .irb-section-title {
    margin-bottom: 14px;
}

/* ── Root container ── */
.irb-sess-root {
    background: #fff;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    padding: 16px 20px 20px;
    overflow: hidden;
    direction: ltr;
}

/* ── Label row (hour axis) ── */
.irb-sess-lbl-row {
    display: flex;
    align-items: flex-end;
    padding-bottom: 10px;
    border-bottom: 1px solid #f1f5f9;
    margin-bottom: 2px;
}

.irb-sess-lbl-spacer {
    width: 170px;
    flex-shrink: 0;
}

.irb-sess-lbl-track {
    flex: 1;
    position: relative;
    height: 18px;
}

.irb-sess-lbl {
    position: absolute;
    transform: translateX(-50%);
    font-size: 10px;
    color: #94a3b8;
    font-variant-numeric: tabular-nums;
    white-space: nowrap;
    user-select: none;
}

/* ── Rows wrapper (holds now-line) ── */
.irb-sess-rows {
    position: relative;
}

/* ── Individual session row ── */
.irb-sess-row {
    display: flex;
    align-items: center;
    gap: 0;
    padding: 10px 0;
    border-bottom: 1px solid #f8fafc;
}

.irb-sess-row:last-of-type {
    border-bottom: none;
    padding-bottom: 4px;
}

/* ── Info column ── */
.irb-sess-row__info {
    width: 170px;
    flex-shrink: 0;
    display: flex;
    align-items: center;
    gap: 10px;
    direction: rtl;
    padding-left: 14px;
}

.irb-sess-flag {
    font-size: 24px;
    line-height: 1;
    flex-shrink: 0;
}

.irb-sess-meta {
    flex: 1;
    min-width: 0;
}

.irb-sess-name {
    display: block;
    font-size: 13px;
    font-weight: 700;
    color: #1e293b;
}

.irb-sess-localtime {
    display: block;
    font-size: 15px;
    font-weight: 600;
    color: #334155;
    direction: ltr;
    font-variant-numeric: tabular-nums;
    letter-spacing: .03em;
    line-height: 1.2;
}

.irb-sess-cd {
    display: block;
    font-size: 10px;
    color: #94a3b8;
    direction: rtl;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    margin-top: 1px;
}

.irb-sess-cd--open    { color: #16a34a; }
.irb-sess-cd--closed  { color: #94a3b8; }
.irb-sess-cd--weekend { color: #f59e0b; }

.irb-sess-badge {
    display: inline-block;
    padding: 2px 7px;
    border-radius: 10px;
    font-size: 10px;
    font-weight: 700;
    flex-shrink: 0;
    direction: rtl;
}

.irb-sess-badge--open   { background: #dcfce7; color: #15803d; }
.irb-sess-badge--closed { background: #f1f5f9; color: #94a3b8; }

/* ── Track column ── */
.irb-sess-row__track {
    flex: 1;
    position: relative;
    height: 30px;
    background: #f1f5f9;
    border-radius: 6px;
    overflow: hidden;
}

/* ── Session bar ── */
.irb-sess-bar {
    position: absolute;
    top: 4px;
    height: calc(100% - 8px);
    border-radius: 4px;
    background: var(--irb-sess-clr);
    transition: opacity .3s;
}

.irb-sess-bar--open {
    background: var(--irb-sess-clr-open) !important;
    box-shadow: 0 0 0 1px var(--irb-sess-clr-ring);
}

.irb-sess-bar--weekend {
    background: repeating-linear-gradient(
        -45deg,
        var(--irb-sess-clr-open) 0px, var(--irb-sess-clr-open) 3px,
        rgba(255,255,255,.55) 3px, rgba(255,255,255,.55) 9px
    ) !important;
    opacity: .65;
    box-shadow: none !important;
}

/* ── Session colors ── */
.irb-sess-track--sydney  {
    --irb-sess-clr:      rgba(245,158,11,.18);
    --irb-sess-clr-open: rgba(245,158,11,.55);
    --irb-sess-clr-ring: rgba(245,158,11,.4);
}
.irb-sess-track--tokyo   {
    --irb-sess-clr:      rgba(239,68,68,.15);
    --irb-sess-clr-open: rgba(239,68,68,.5);
    --irb-sess-clr-ring: rgba(239,68,68,.35);
}
.irb-sess-track--london  {
    --irb-sess-clr:      rgba(59,130,246,.15);
    --irb-sess-clr-open: rgba(59,130,246,.5);
    --irb-sess-clr-ring: rgba(59,130,246,.35);
}
.irb-sess-track--newyork {
    --irb-sess-clr:      rgba(34,197,94,.15);
    --irb-sess-clr-open: rgba(34,197,94,.5);
    --irb-sess-clr-ring: rgba(34,197,94,.35);
}

/* open row: subtle left border accent */
.irb-sess-row--open .irb-sess-row__info {
    border-right: 3px solid var(--irb-sess-accent, #e2e8f0);
}
#irb-sess-row-sydney  { --irb-sess-accent: #f59e0b; }
#irb-sess-row-tokyo   { --irb-sess-accent: #ef4444; }
#irb-sess-row-london  { --irb-sess-accent: #3b82f6; }
#irb-sess-row-newyork { --irb-sess-accent: #22c55e; }

/* ── Now line ── */
.irb-sess-nowline {
    position: absolute;
    top: 0;
    bottom: 0;
    width: 2px;
    background: #ef4444;
    border-radius: 1px;
    pointer-events: none;
    z-index: 4;
    transform: translateX(-50%);
}

.irb-sess-now-tip {
    position: absolute;
    bottom: calc(100% + 5px);
    left: 50%;
    transform: translateX(-50%);
    background: #1e293b;
    color: #fff;
    font-size: 10px;
    font-weight: 600;
    padding: 3px 7px;
    border-radius: 5px;
    white-space: nowrap;
    direction: ltr;
    font-variant-numeric: tabular-nums;
    letter-spacing: .04em;
    pointer-events: none;
}

.irb-sess-now-tip::after {
    content: '';
    position: absolute;
    top: 100%;
    left: 50%;
    transform: translateX(-50%);
    border: 4px solid transparent;
    border-top-color: #1e293b;
}

/* ── Weekend: dim info ── */
.irb-sess--weekend .irb-sess-row__info {
    opacity: .75;
}

/* ── FAQ accordion ────────────────────────────────────────── */
.irb-forex-faq-section {
    margin-top: 40px;
    margin-bottom: 40px;
}
.irb-faq-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
}
.irb-faq-item {
    border: 1px solid #e2e8f0;
    border-radius: 10px;
    overflow: hidden;
    background: #fff;
    transition: border-color .2s, box-shadow .2s;
}
.irb-faq-item[open] {
    border-color: #2563eb;
    box-shadow: 0 2px 14px rgba(37,99,235,.09);
}
.irb-faq-q {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 14px 18px;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    list-style: none;
    user-select: none;
    gap: 12px;
    color: #1e293b;
    transition: color .2s, background .15s;
}
.irb-faq-q::-webkit-details-marker { display: none; }
.irb-faq-q::after {
    content: '';
    flex-shrink: 0;
    width: 26px;
    height: 26px;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%2364748b' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: center;
    background-color: #f1f5f9;
    border-radius: 50%;
    transition: transform .22s cubic-bezier(.4,0,.2,1), background-color .2s, background-image .2s;
}
.irb-faq-item[open] > .irb-faq-q {
    color: #2563eb;
}
.irb-faq-item[open] > .irb-faq-q::after {
    transform: rotate(180deg);
    background-color: rgba(37,99,235,.1);
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%232563eb' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
}
.irb-faq-q:hover {
    background: #f8fafc;
}
/* body wrapper — height animated by JS */
.irb-faq-body-wrap {
    overflow: hidden;
    height: 0;
    transition: height .2s ease;
}
.irb-faq-body {
    padding: 14px 18px;
    font-size: 14px;
    line-height: 1.75;
    color: #475569;
    border-top: 1px solid #e2e8f0;
}
/* read-more extras */
.irb-faq-item--more {
    display: none;
}
.irb-faq-wrap--expanded .irb-faq-item--more {
    display: block;
}
.irb-faq-readmore {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    margin: 14px auto 0;
    padding: 9px 20px;
    background: none;
    border: 1px solid #cbd5e1;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 500;
    color: #475569;
    cursor: pointer;
    transition: border-color .15s, color .15s, background .15s;
}
.irb-faq-readmore:hover {
    border-color: #94a3b8;
    color: #1e293b;
    background: #f8fafc;
}
.irb-faq-rm-arrow {
    transition: transform .2s ease;
    flex-shrink: 0;
}
.irb-faq-wrap--expanded .irb-faq-rm-arrow {
    transform: rotate(180deg);
}

/* ── Responsive ── */
@media (max-width: 640px) {
    .irb-sess-root { padding: 12px 12px 16px; }
    .irb-sess-lbl-spacer,
    .irb-sess-row__info { width: 110px; }
    .irb-sess-flag  { font-size: 18px; }
    .irb-sess-name  { font-size: 11px; }
    .irb-sess-localtime { font-size: 13px; }
    .irb-sess-cd,
    .irb-sess-badge { display: none; }
    .irb-sess-row__track { height: 26px; }
}

