/*
 * شاپور — لایهٔ layout.css
 * هدر، ناوبری، کشو، هیرو
 * منبع: فاز ۲ مهاجرت از style.css مرجع (خطوط 186-597)
 * ترتیب بارگذاری لایه‌ها = ترتیب کسکید اصلی؛ هرگز ترتیب را تغییر ندهید.
 */

/* ====== Logo ====== */
.logo {
    display: flex;
    align-items: center;
    gap: 12px;
    flex-shrink: 0;
    text-decoration: none;
}

.logo-icon {
    width: 42px;
    height: 42px;
    background: var(--gradient-primary);
    border-radius: var(--radius-sm);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1.4rem;
    flex-shrink: 0;
    box-shadow: 0 4px 14px rgba(37, 99, 235, 0.3);
}

.logo-text { display: flex; flex-direction: column; line-height: 1.2; }

.logo-title {
    font-weight: 800;
    color: var(--text-primary);
    font-size: 1.3rem;
    letter-spacing: 0.5px;
}

.logo-sub {
    font-size: 0.72rem;
    color: var(--text-muted);
    margin-top: 2px;
}

/* ====== Desktop Navigation (also serves as mobile drawer source) ====== */
.main-nav {
    display: flex;
    align-items: center;
    gap: 4px;
    flex: 1;
    justify-content: center;
}

.nav-link {
    color: var(--text-secondary);
    font-size: 0.95rem;
    font-weight: 500;
    padding: 10px 16px;
    border-radius: var(--radius-sm);
    transition: color 0.25s ease, background 0.25s ease;
    position: relative;
    white-space: nowrap;
    text-decoration: none;
}

.nav-link:hover {
    color: var(--text-primary);
    background: rgba(30, 58, 95, 0.1);
}

.nav-link.active {
    color: var(--accent-green);
}

.nav-link.active::after {
    content: '';
    position: absolute;
    bottom: 4px;
    right: 16px;
    left: 16px;
    height: 2px;
    background: var(--accent-green);
    border-radius: 2px;
}

.nav-cta {
    margin-right: 12px;
    padding: 10px 22px !important;
    font-size: 0.9rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

/* ====== Header right actions (cart + menu toggle) ====== */
.header-actions {
    display: flex;
    align-items: center;
    gap: 6px;
    flex-shrink: 0;
}

/* ====== Cart icon (always visible) ====== */
.cart-link {
    position: relative;
    width: 44px;
    height: 44px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: var(--text-primary);
    border-radius: 10px;
    transition: background 0.2s ease, color 0.2s ease;
    text-decoration: none;
}
.cart-link:hover {
    background: rgba(37, 99, 235, 0.1);
    color: var(--accent-green);
}.cart-count {
    position: absolute;
    top: 4px;
    right: 4px;
    min-width: 18px;
    height: 18px;
    padding: 0 5px;
    border-radius: 9px;
    background: rgba(30, 58, 95, 0.16);
    color: var(--text-muted);
    font-size: 0.65rem;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
    line-height: 1;
    transition: background 0.25s ease, color 0.25s ease, transform 0.25s ease;
}
.cart-count.has-items {
    background: var(--accent-green);
    color: #ffffff;
    transform: scale(1.08);
    box-shadow: 0 2px 8px rgba(37, 99, 235, 0.5);
}

/* ====== Mobile menu toggle (hidden on desktop) ====== */
.menu-toggle {
    display: none;
    flex-direction: column;
    justify-content: center;
    gap: 5px;
    width: 44px;
    height: 44px;
    background: transparent;
    border: none;
    cursor: pointer;
    padding: 0;
    border-radius: 8px;
    transition: background 0.2s ease, opacity 0.25s ease, visibility 0.25s ease;
}

.menu-toggle:hover {
    background: rgba(30, 58, 95, 0.09);
}

/* When the mobile drawer is open, the hamburger button fades out
   so the user only sees the in-drawer close (X) button. */
body.menu-open .menu-toggle {
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
}.menu-toggle.active .menu-toggle-bar:nth-child(1) {
    transform: translateY(8px) rotate(45deg);
    background: var(--accent-green);
}
.menu-toggle.active .menu-toggle-bar:nth-child(2) { opacity: 0; }
.menu-toggle.active .menu-toggle-bar:nth-child(3) {
    transform: translateY(-8px) rotate(-45deg);
    background: var(--accent-green);
}

/* ====== Drawer header (mobile only) ====== */
.drawer-head {
    display: none;
    align-items: center;
    justify-content: space-between;
    padding: 0 4px 16px;
    margin-bottom: 8px;
    border-bottom: 1px solid rgba(30, 58, 95, 0.12);
}
.drawer-brand {
    display: flex;
    align-items: center;
    gap: 10px;
    color: var(--text-primary);
    font-weight: 700;
    font-size: 1rem;
}/* In-drawer close button (mobile only) */
.drawer-close {
    width: 38px;
    height: 38px;
    border-radius: 10px;
    background: rgba(30, 58, 95, 0.1);
    border: 1px solid rgba(30, 58, 95, 0.12);
    color: var(--text-secondary);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: background 0.2s ease, color 0.2s ease, transform 0.2s ease;
}
.drawer-close:hover {
    background: rgba(239, 68, 68, 0.12);
    color: var(--accent-red);
    transform: rotate(90deg);
}

/* ====== Drawer footer (mobile only) ====== */
.drawer-footer {
    display: none;
    margin-top: auto;
    padding-top: 18px;
    border-top: 1px solid rgba(30, 58, 95, 0.12);
    flex-direction: column;
    gap: 8px;
}
.drawer-contact-row {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px 14px;
    border-radius: 12px;
    background: rgba(37, 99, 235, 0.08);
    color: var(--text-primary);
    font-weight: 600;
    font-size: 0.95rem;
    text-decoration: none;
    transition: background 0.2s ease;
}.drawer-contact-wa { background: rgba(37, 211, 102, 0.1); }
.drawer-contact-wa:hover { background: rgba(37, 211, 102, 0.2); }
.drawer-contact-icon { font-size: 1.1rem; }.nav-cart-badge {
    min-width: 22px;
    height: 22px;
    padding: 0 6px;
    border-radius: 11px;
    background: rgba(30, 58, 95, 0.14);
    color: var(--text-muted);
    font-size: 0.78rem;
    font-weight: 700;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    line-height: 1;
}
.nav-cart-badge.has-items {
    background: var(--accent-green);
    color: #ffffff;
}.mobile-menu-overlay.active {
    display: block;
    opacity: 1;
}

/* ============================================
   HERO
   ============================================ */
.hero {
    min-height: calc(100vh - var(--header-height));
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    overflow: hidden;
    padding-top: 40px;
    background: var(--bg-primary);
}

.hero-content {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 60px;
    width: 100%;
}

.hero-text { flex: 1; text-align: right; }
.hero-visual { flex: 1; display: flex; justify-content: center; align-items: center; min-height: 400px; }

.hero-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: rgba(37, 99, 235, 0.1);
    border: 1px solid rgba(37, 99, 235, 0.3);
    border-radius: 50px;
    color: var(--accent-green);
    padding: 8px 20px;
    font-size: 0.9rem;
    font-weight: 600;
    margin-bottom: 24px;
}

.hero-title {
    font-size: 3.2rem;
    color: var(--text-primary);
    font-weight: 900;
    line-height: 1.2;
    max-width: 800px;
    margin-bottom: 20px;
}

.hero-highlight {
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero-desc {
    font-size: 1.1rem;
    color: var(--text-secondary);
    max-width: 600px;
    margin-bottom: 32px;
    line-height: 1.9;
}

.hero-buttons {
    display: flex;
    gap: 16px;
    margin-bottom: 40px;
    flex-wrap: wrap;
}

.hero-stats {
    display: flex;
    gap: 40px;
    flex-wrap: wrap;
}

.hero-stat { text-align: center; }
.hero-stat-num { font-size: 2rem; font-weight: 900; color: var(--text-primary); display: block; }
.hero-stat-label { font-size: 0.85rem; color: var(--text-secondary); }

.hero-lottie {
    width: 300px;
    height: 300px;
    opacity: 0.3;
}

.lottie-fallback {
    font-size: 8rem;
    text-align: center;
    animation: lottiePulse 3s ease-in-out infinite;
    filter: drop-shadow(0 0 30px rgba(37, 99, 235, 0.3));
}

@keyframes lottiePulse {
    0%, 100% { transform: scale(1); opacity: 0.8; }
    50% { transform: scale(1.1); opacity: 1; }
}

/* ============================================
   PAGE HERO (shared for inner pages)
   ============================================ */
.page-hero {
    padding: 60px 0 60px;
    background: var(--bg-secondary);
    text-align: center;
    border-bottom: 1px solid rgba(30, 58, 95, 0.09);
}

.page-badge {
    display: inline-block;
    background: rgba(37, 99, 235, 0.1);
    color: var(--accent-green);
    padding: 6px 18px;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 600;
    margin-bottom: 16px;
}

.page-title {
    font-size: 2.5rem;
    color: var(--text-primary);
    font-weight: 900;
    margin-bottom: 16px;
}

.page-desc {
    font-size: 1.1rem;
    color: var(--text-secondary);
    max-width: 700px;
    margin: 0 auto;
    line-height: 1.9;
}.section-title {
    color: var(--text-primary);
    font-size: 2.2rem;
    margin-bottom: 12px;
    position: relative;
    display: inline-block;
}

.section-title::after {
    content: '';
    position: absolute;
    bottom: -8px;
    left: 50%;
    transform: translateX(-50%);
    width: 60px;
    height: 3px;
    background: var(--gradient-primary);
    border-radius: 2px;
}

.section-subtitle {
    font-size: 1.05rem;
    color: var(--text-secondary);
    margin-top: 16px;
}

