/* ===================================================
   DISTRIBO — CATALOG / FEATURES PAGE STYLES
   =================================================== */

/* === RTL layout fix: neutralize --reverse child direction in RTL mode === */
html[dir="rtl"] .catalog-grid--reverse > * {
    direction: rtl;
}

/* === RTL FONT override (Vazirmatn) for catalog page === */
html[dir="rtl"] .catalog-title,
html[dir="rtl"] .catalog-description,
html[dir="rtl"] .catalog-feature-list li,
html[dir="rtl"] .catalog-module-tag,
html[dir="rtl"] .catalog-hero-title,
html[dir="rtl"] .catalog-hero-description,
html[dir="rtl"] .catalog-stat-label,
html[dir="rtl"] .catalog-stat-number,
html[dir="rtl"] .mobile-divider-title,
html[dir="rtl"] .mobile-divider-desc,
html[dir="rtl"] .mobile-badge,
html[dir="rtl"] .module-nav-pill,
html[dir="rtl"] .catalog-cta-title,
html[dir="rtl"] .catalog-cta-description {
    font-family: 'Vazirmatn', sans-serif !important;
}

/* --- Catalog Hero --- */
.catalog-hero {
    padding: 160px 0 90px;
    text-align: center;
}

.catalog-hero-content {
    max-width: 780px;
    margin: 0 auto;
}

.catalog-hero-title {
    font-family: 'Space Grotesk', sans-serif;
    font-size: 4rem;
    font-weight: 700;
    line-height: 1.1;
    margin: 1rem 0 1.5rem;
    color: #f1f5f9;
}

.catalog-hero-description {
    font-size: 1.125rem;
    color: #94a3b8;
    margin-bottom: 3rem;
    line-height: 1.75;
}

.catalog-hero-stats {
    display: flex;
    justify-content: center;
    gap: 0;
    flex-wrap: wrap;
    background: rgba(30, 41, 59, 0.5);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(59, 130, 246, 0.2);
    border-radius: 20px;
    padding: 1.75rem 3rem;
    display: inline-flex;
}

.catalog-stat {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.2rem;
    padding: 0 2.5rem;
    position: relative;
}

.catalog-stat + .catalog-stat::before {
    content: '';
    position: absolute;
    left: 0;
    top: 50%;
    transform: translateY(-50%);
    width: 1px;
    height: 36px;
    background: rgba(59, 130, 246, 0.25);
}

.catalog-stat-number {
    font-family: 'Space Grotesk', sans-serif;
    font-size: 2.25rem;
    font-weight: 700;
    background: linear-gradient(135deg, #3b82f6, #60a5fa);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    line-height: 1;
}

.catalog-stat-label {
    font-size: 0.8rem;
    color: #64748b;
    text-transform: uppercase;
    letter-spacing: 0.06em;
}

/* --- Module Navigation Bar --- */
.module-nav {
    background: rgba(10, 14, 39, 0.96);
    backdrop-filter: blur(20px);
    border-bottom: 1px solid rgba(59, 130, 246, 0.12);
    padding: 0.75rem 0;
    position: sticky;
    top: 70px;
    z-index: 900;
}

.module-nav-inner {
    display: flex;
    gap: 0.375rem;
    overflow-x: auto;
    scrollbar-width: none;
    -ms-overflow-style: none;
}

.module-nav-inner::-webkit-scrollbar {
    display: none;
}

.module-nav-pill {
    display: inline-flex;
    align-items: center;
    padding: 0.375rem 1rem;
    border-radius: 100px;
    font-size: 0.8125rem;
    font-weight: 500;
    color: #64748b;
    text-decoration: none;
    white-space: nowrap;
    border: 1px solid transparent;
    transition: all 0.2s ease;
    flex-shrink: 0;
}

.module-nav-pill:hover {
    color: #e2e8f0;
    border-color: rgba(59, 130, 246, 0.25);
    background: rgba(59, 130, 246, 0.07);
}

.module-nav-pill.active {
    color: #60a5fa;
    border-color: rgba(59, 130, 246, 0.4);
    background: rgba(59, 130, 246, 0.1);
}

/* --- Catalog Sections --- */
.catalog-section {
    padding: 110px 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.04);
    position: relative;
}

.catalog-section--alt {
    background: rgba(15, 23, 42, 0.6);
}

.catalog-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 5rem;
    align-items: center;
}

.catalog-grid--reverse {
    direction: rtl;
}

.catalog-grid--reverse > * {
    direction: ltr;
}

/* --- Module Tag Pill --- */
.catalog-module-tag {
    display: inline-flex;
    align-items: center;
    padding: 0.3rem 0.9rem;
    border-radius: 100px;
    font-size: 0.7rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    margin-bottom: 1.25rem;
}

.catalog-tag--blue   { background: rgba(59,130,246,0.12); color: #60a5fa; border: 1px solid rgba(59,130,246,0.3); }
.catalog-tag--green  { background: rgba(34,197,94,0.12);  color: #4ade80; border: 1px solid rgba(34,197,94,0.3); }
.catalog-tag--teal   { background: rgba(20,184,166,0.12); color: #2dd4bf; border: 1px solid rgba(20,184,166,0.3); }
.catalog-tag--orange { background: rgba(249,115,22,0.12); color: #fb923c; border: 1px solid rgba(249,115,22,0.3); }
.catalog-tag--purple { background: rgba(139,92,246,0.12); color: #a78bfa; border: 1px solid rgba(139,92,246,0.3); }
.catalog-tag--red    { background: rgba(239,68,68,0.12);  color: #f87171; border: 1px solid rgba(239,68,68,0.3); }
.catalog-tag--amber  { background: rgba(245,158,11,0.12); color: #fbbf24; border: 1px solid rgba(245,158,11,0.3); }

/* --- Content --- */
.catalog-title {
    font-family: 'Space Grotesk', sans-serif;
    font-size: 2.25rem;
    font-weight: 700;
    line-height: 1.2;
    color: #f1f5f9;
    margin-bottom: 1rem;
}

.catalog-description {
    font-size: 1rem;
    color: #94a3b8;
    line-height: 1.8;
    margin-bottom: 2rem;
}

/* --- Feature Checklist --- */
.catalog-feature-list {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.catalog-feature-list li {
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
    font-size: 0.9375rem;
    color: #cbd5e1;
    line-height: 1.55;
}

.check-icon {
    width: 20px;
    height: 20px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    margin-top: 0.15rem;
}

.check--blue   { background: rgba(59,130,246,0.15);  color: #3b82f6; }
.check--green  { background: rgba(34,197,94,0.15);   color: #22c55e; }
.check--teal   { background: rgba(20,184,166,0.15);  color: #14b8a6; }
.check--orange { background: rgba(249,115,22,0.15);  color: #f97316; }
.check--purple { background: rgba(139,92,246,0.15);  color: #8b5cf6; }
.check--red    { background: rgba(239,68,68,0.15);   color: #ef4444; }
.check--amber  { background: rgba(245,158,11,0.15);  color: #f59e0b; }

/* --- Screen Frame (browser mockup) --- */
.catalog-visual {
    position: relative;
}

.screen-frame {
    border-radius: 12px;
    overflow: hidden;
    border: 1px solid rgba(59, 130, 246, 0.2);
    box-shadow:
        0 0 0 1px rgba(255, 255, 255, 0.04),
        0 25px 60px rgba(0, 0, 0, 0.5),
        0 0 80px rgba(59, 130, 246, 0.08);
    transition: transform 0.4s ease, box-shadow 0.4s ease;
}

.screen-frame:hover {
    transform: translateY(-6px) scale(1.01);
    box-shadow:
        0 0 0 1px rgba(255, 255, 255, 0.07),
        0 35px 80px rgba(0, 0, 0, 0.6),
        0 0 100px rgba(59, 130, 246, 0.18);
}

.screen-chrome {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.625rem 1rem;
    background: #1e293b;
    border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.chrome-dots {
    display: flex;
    gap: 5px;
    flex-shrink: 0;
}

.chrome-dots span {
    width: 10px;
    height: 10px;
    border-radius: 50%;
}

.chrome-dots span:nth-child(1) { background: #ff5f56; }
.chrome-dots span:nth-child(2) { background: #ffbd2e; }
.chrome-dots span:nth-child(3) { background: #27c93f; }

.chrome-bar {
    flex: 1;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 4px;
    padding: 0.25rem 0.75rem;
    font-size: 0.75rem;
    color: #475569;
    text-align: center;
    font-family: 'Inter', sans-serif;
}

.screen-body {
    background: #0f172a;
    line-height: 0;
}

.screen-body img {
    width: 100%;
    height: auto;
    display: block;
    object-fit: cover;
}

/* --- CTA Section --- */
.catalog-cta {
    padding: 120px 0;
    text-align: center;
}

.catalog-cta-inner {
    max-width: 640px;
    margin: 0 auto;
    background: rgba(30, 41, 59, 0.6);
    backdrop-filter: blur(16px);
    border: 1px solid rgba(59, 130, 246, 0.25);
    border-radius: 24px;
    padding: 4rem 3rem;
}

.catalog-cta-title {
    font-family: 'Space Grotesk', sans-serif;
    font-size: 2.25rem;
    font-weight: 700;
    color: #f1f5f9;
    margin-bottom: 1rem;
}

.catalog-cta-description {
    font-size: 1.0625rem;
    color: #94a3b8;
    margin-bottom: 2.5rem;
}

.catalog-cta-actions {
    display: flex;
    gap: 1rem;
    justify-content: center;
    flex-wrap: wrap;
}

.btn-outline-white {
    padding: 0.875rem 1.75rem;
    border: 1px solid rgba(255, 255, 255, 0.18);
    color: #e2e8f0;
    border-radius: 12px;
    font-size: 0.9375rem;
    font-weight: 500;
    text-decoration: none;
    transition: all 0.2s ease;
}

.btn-outline-white:hover {
    background: rgba(255, 255, 255, 0.06);
    border-color: rgba(255, 255, 255, 0.35);
    color: #fff;
}

/* --- Active nav link style --- */
.nav-link.active-page {
    color: #3b82f6;
}

/* --- Responsive --- */
@media (max-width: 1100px) {
    .catalog-grid {
        gap: 3.5rem;
    }

    .catalog-title {
        font-size: 1.875rem;
    }
}

@media (max-width: 900px) {
    .catalog-grid {
        grid-template-columns: 1fr;
        gap: 2.5rem;
    }

    .catalog-grid--reverse {
        direction: ltr;
    }

    .catalog-hero-title {
        font-size: 2.75rem;
    }

    .catalog-section {
        padding: 70px 0;
    }
}

@media (max-width: 600px) {
    .catalog-hero {
        padding: 120px 0 60px;
    }

    .catalog-hero-title {
        font-size: 2.25rem;
    }

    .catalog-hero-stats {
        gap: 1rem;
        padding: 1.25rem 1.5rem;
    }

    .catalog-stat {
        padding: 0 1.25rem;
    }

    .catalog-stat + .catalog-stat::before {
        display: none;
    }

    .catalog-cta-inner {
        padding: 2.5rem 1.5rem;
    }

    .catalog-cta-title {
        font-size: 1.75rem;
    }
}

/* ===================================================
   MOBILE APP SECTION
   =================================================== */

/* Mobile nav pill highlight */
.module-nav-pill--mobile {
    background: rgba(239, 68, 68, 0.08);
    color: #f87171;
    border-color: rgba(239, 68, 68, 0.25);
}

.module-nav-pill--mobile:hover,
.module-nav-pill--mobile.active {
    background: rgba(239, 68, 68, 0.15);
    color: #fca5a5;
    border-color: rgba(239, 68, 68, 0.4);
}

/* Mobile divider banner */
.mobile-divider {
    padding: 80px 0;
    position: relative;
}

.mobile-divider::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, rgba(59, 130, 246, 0.04), rgba(139, 92, 246, 0.06));
    pointer-events: none;
}

.mobile-divider-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 3rem;
    background: rgba(30, 41, 59, 0.6);
    backdrop-filter: blur(16px);
    border: 1px solid rgba(59, 130, 246, 0.2);
    border-radius: 24px;
    padding: 3rem 3.5rem;
    position: relative;
    overflow: hidden;
}

.mobile-divider-inner::before {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0;
    height: 3px;
    background: linear-gradient(90deg, #3b82f6, #8b5cf6, #ef4444);
}

.mobile-divider-content {
    flex: 1;
}

.mobile-divider-title {
    font-family: 'Space Grotesk', sans-serif;
    font-size: 2.5rem;
    font-weight: 700;
    color: #f1f5f9;
    line-height: 1.15;
    margin: 0.75rem 0 1rem;
}

.mobile-divider-desc {
    color: #94a3b8;
    font-size: 1rem;
    line-height: 1.75;
    max-width: 520px;
}

.mobile-divider-badges {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    flex-shrink: 0;
}

.mobile-badge {
    display: flex;
    align-items: center;
    gap: 0.625rem;
    padding: 0.5rem 1.125rem;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 10px;
    font-size: 0.875rem;
    color: #cbd5e1;
    white-space: nowrap;
}

.mobile-badge svg {
    color: #3b82f6;
    flex-shrink: 0;
}

/* Mobile section accent */
.mobile-section {
    position: relative;
}

.mobile-section::before {
    content: '';
    position: absolute;
    left: 0; top: 0; bottom: 0;
    width: 3px;
    background: linear-gradient(180deg, transparent, rgba(59, 130, 246, 0.4), transparent);
}

/* Phone visual container — centers the narrow phone */
.catalog-visual--phone {
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Mobile screenshot — image already includes phone frame */
.mobile-img-wrap {
    width: 300px;
    transition: transform 0.4s ease, filter 0.4s ease;
    filter: drop-shadow(0 30px 60px rgba(0, 0, 0, 0.5))
            drop-shadow(0 0 60px rgba(59, 130, 246, 0.12));
}

.mobile-img-wrap:hover {
    transform: translateY(-8px) scale(1.02);
    filter: drop-shadow(0 40px 80px rgba(0, 0, 0, 0.6))
            drop-shadow(0 0 80px rgba(59, 130, 246, 0.22));
}

.mobile-img-wrap img {
    width: 100%;
    height: auto;
    display: block;
}

/* Responsive */
@media (max-width: 900px) {
    .mobile-divider-inner {
        flex-direction: column;
        text-align: center;
    }

    .mobile-divider-desc {
        max-width: 100%;
    }

    .mobile-divider-badges {
        flex-direction: row;
        flex-wrap: wrap;
        justify-content: center;
    }

    .mobile-divider-title {
        font-size: 2rem;
    }
}

@media (max-width: 600px) {
    .mobile-divider-inner {
        padding: 2rem 1.5rem;
    }

    .mobile-img-wrap {
        width: 240px;
    }
}

/* ===================================================
   LIGHTBOX
   =================================================== */
.lb-backdrop {
    position: fixed;
    inset: 0;
    z-index: 9999;
    background: rgba(0, 0, 0, 0.92);
    backdrop-filter: blur(12px);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.25s ease;
}

.lb-backdrop.lb-open {
    opacity: 1;
    pointer-events: all;
}

/* Image wrapper — limits size, handles mobile */
.lb-img-wrap {
    max-width: 90vw;
    max-height: 88vh;
    display: flex;
    align-items: center;
    justify-content: center;
}

.lb-backdrop.lb-open .lb-img-wrap {
    animation: lbZoomIn 0.25s ease forwards;
}

@keyframes lbZoomIn {
    from { transform: scale(0.93); opacity: 0; }
    to   { transform: scale(1);    opacity: 1; }
}

#lbImg {
    max-width: 100%;
    max-height: 88vh;
    border-radius: 10px;
    box-shadow: 0 30px 100px rgba(0, 0, 0, 0.8);
    display: block;
    object-fit: contain;
}

/* Close button */
.lb-close {
    position: fixed;
    top: 1.25rem;
    right: 1.25rem;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.15);
    color: #fff;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s ease, transform 0.2s ease;
    z-index: 10001;
}

.lb-close:hover {
    background: rgba(255, 255, 255, 0.2);
    transform: scale(1.1);
}

/* Prev / Next arrows */
.lb-arrow {
    position: fixed;
    top: 50%;
    transform: translateY(-50%);
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.12);
    color: #fff;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s ease, transform 0.2s ease;
    z-index: 10001;
    user-select: none;
}

.lb-arrow:hover {
    background: rgba(255, 255, 255, 0.18);
    transform: translateY(-50%) scale(1.08);
}

.lb-arrow--prev { left: 1.25rem; }
.lb-arrow--next { right: 1.25rem; }

/* Counter pill */
.lb-counter {
    position: fixed;
    bottom: 1.5rem;
    left: 50%;
    transform: translateX(-50%);
    background: rgba(0, 0, 0, 0.5);
    border: 1px solid rgba(255, 255, 255, 0.12);
    color: #94a3b8;
    font-size: 0.8125rem;
    padding: 0.3rem 0.875rem;
    border-radius: 100px;
    z-index: 10001;
    pointer-events: none;
}

@media (max-width: 600px) {
    .lb-arrow--prev { left: 0.5rem; }
    .lb-arrow--next { right: 0.5rem; }

    .lb-img-wrap {
        max-width: 95vw;
    }
}
