/* ============================================
   MOBILE CSS — Zari Zeen S Collection
   Responsive breakpoints & mobile-specific styles
   ============================================ */

/* ─── Tablet (≤ 1024px) ─── */
@media (max-width: 1024px) {
    .products-grid-4 {
        grid-template-columns: repeat(3, 1fr);
    }

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

    .category-tile-large {
        grid-column: 1 / -1;
        grid-row: auto;
        min-height: 280px;
    }

    .footer-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: var(--space-8);
    }

    .instagram-grid {
        grid-template-columns: repeat(4, 1fr);
    }

    .contact-grid {
        grid-template-columns: 1fr;
    }

    .newsletter-inner {
        flex-direction: column;
        text-align: center;
    }

    .newsletter-form {
        max-width: 100%;
        width: 100%;
    }
}

/* ─── Mobile Landscape / Small Tablet (≤ 768px) ─── */
@media (max-width: 768px) {
    :root {
        --header-height: var(--header-height-mobile);
    }

    .products-grid-4 {
        grid-template-columns: repeat(2, 1fr);
        gap: var(--space-3);
    }

    .category-tiles {
        grid-template-columns: 1fr;
    }

    .category-tile-large {
        min-height: 200px;
    }

    .category-tile {
        min-height: 180px;
    }

    .footer-grid {
        grid-template-columns: 1fr 1fr;
    }

    .instagram-grid {
        grid-template-columns: repeat(3, 1fr);
    }

    .section-title {
        font-size: var(--text-2xl);
    }

    .section-subtitle {
        font-size: var(--text-sm);
    }

    .section-padding {
        padding: var(--space-10) 0;
    }

    /* Slider */
    .slide {
        min-height: 400px;
    }

    .slide-content {
        min-height: 400px;
    }

    .slide-title {
        font-size: var(--text-3xl);
    }

    .slide-subtitle {
        font-size: var(--text-sm);
    }

    .slider-arrow {
        width: 36px;
        height: 36px;
    }

    .slider-prev { left: var(--space-3); }
    .slider-next { right: var(--space-3); }

    /* Newsletter */
    .newsletter-input-group {
        flex-direction: column;
    }

    .newsletter-input-group input {
        text-align: center;
    }

    /* Footer Bottom */
    .footer-bottom {
        flex-direction: column;
        gap: var(--space-3);
        text-align: center;
    }

    /* Page Content */
    .page-template-content {
        padding: var(--space-10) var(--space-4);
    }

    .page-template-content h1 {
        font-size: var(--text-2xl);
    }
}

/* ─── Mobile (≤ 992px) — Hamburger activation ─── */
@media (max-width: 992px) {
    /* Show hamburger, hide desktop nav */
    .mobile-menu-toggle {
        display: flex;
        order: 1;
    }

    .desktop-nav {
        display: none;
    }

    .desktop-only {
        display: none !important;
    }

    /* Header layout: Hamburger Left | Logo Center | Icons Right */
    .header-layout {
        display: grid;
        grid-template-columns: auto 1fr auto;
        align-items: center;
        gap: 0;
    }

    .header-logo {
        order: 2;
        text-align: center;
        justify-self: center;
    }

    .site-logo {
        height: 42px;
    }

    .header-icons {
        order: 3;
        gap: var(--space-1);
    }

    /* Smaller header icons on mobile */
    .header-icon {
        width: 36px;
        height: 36px;
    }

    .header-icon .material-icons-outlined {
        font-size: 20px;
    }

    /* Hide search icon in header (use bottom nav) */
    .header-icons .search-toggle {
        display: none;
    }

    /* Show mobile bottom nav */
    .mobile-bottom-nav {
        display: flex !important;
    }

    /* Add bottom padding to prevent content hiding behind bottom nav */
    .site-content {
        padding-bottom: var(--mobile-bottom-nav-height);
    }

    /* WhatsApp button above bottom nav */
    .whatsapp-float {
        bottom: calc(var(--mobile-bottom-nav-height) + 16px);
    }
}

/* ─── Mobile Small (≤ 480px) ─── */
@media (max-width: 480px) {
    .container {
        padding: 0 var(--space-4);
    }

    .slide {
        min-height: 350px;
    }

    .slide-content {
        min-height: 350px;
    }

    .slide-title {
        font-size: var(--text-2xl);
    }

    .slide-label {
        font-size: 9px;
        letter-spacing: 2px;
        padding: 3px var(--space-3);
    }

    .slider-arrow {
        display: none;
    }

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

    .footer-grid {
        grid-template-columns: 1fr;
    }

    .footer-brand {
        text-align: center;
    }

    .footer-social {
        justify-content: center;
    }

    .footer-logo {
        margin-left: auto;
        margin-right: auto;
    }

    .product-card-info {
        padding: var(--space-2) 0;
    }

    .product-title {
        font-size: var(--text-xs);
    }

    .product-price {
        font-size: var(--text-xs);
    }

    .tile-content {
        padding: var(--space-5);
        min-height: 180px;
    }

    .tile-title {
        font-size: var(--text-xl);
    }

    .tile-icon {
        font-size: 28px;
        margin-bottom: var(--space-2);
    }

    /* Contact page */
    .contact-info-card {
        flex-direction: column;
        text-align: center;
        align-items: center;
    }
}

/* ─── Mobile Bottom Navigation ─── */
.mobile-bottom-nav {
    display: none;
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    height: var(--mobile-bottom-nav-height);
    background: var(--zz-white);
    border-top: 1px solid var(--zz-gray-200);
    z-index: var(--z-mobile-nav);
    align-items: center;
    justify-content: space-around;
    padding: 0 var(--space-2);
    box-shadow: 0 -2px 10px rgba(0,0,0,0.05);
}

.bottom-nav-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 2px;
    padding: var(--space-1) var(--space-2);
    color: var(--zz-gray-500);
    text-decoration: none;
    transition: color var(--transition-base);
    position: relative;
    flex: 1;
    min-width: 0;
}

.bottom-nav-item.active,
.bottom-nav-item:hover {
    color: var(--zz-black);
}

.bottom-nav-item .material-icons-outlined {
    font-size: 22px;
}

.bottom-nav-label {
    font-size: 10px;
    font-weight: 500;
    letter-spacing: 0.3px;
    white-space: nowrap;
}

.bottom-nav-home {
    position: relative;
}

.bottom-nav-home .material-icons-outlined {
    font-size: 24px;
}

.bottom-nav-badge {
    position: absolute;
    top: 0;
    right: 50%;
    transform: translateX(14px);
    background: var(--zz-gold);
    color: var(--zz-white);
    font-size: 9px;
    font-weight: 700;
    width: 15px;
    height: 15px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    line-height: 1;
}

/* ─── Mobile Account Panel ─── */
.mobile-account-panel {
    padding: var(--space-6);
}

.mobile-account-header {
    display: flex;
    align-items: center;
    gap: var(--space-4);
    padding-bottom: var(--space-6);
    border-bottom: 1px solid var(--zz-gray-200);
    margin-bottom: var(--space-6);
}

.mobile-account-avatar {
    width: 56px;
    height: 56px;
    border-radius: var(--radius-full);
    background: linear-gradient(135deg, var(--zz-gold), var(--zz-gold-dark));
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--zz-white);
}

.mobile-account-avatar .material-icons-outlined {
    font-size: 28px;
}

.mobile-account-name {
    font-size: var(--text-lg);
    font-weight: 600;
}

.mobile-account-email {
    font-size: var(--text-sm);
    color: var(--zz-gray-500);
}

.mobile-account-menu {
    list-style: none;
    padding: 0;
}

.mobile-account-menu li {
    border-bottom: 1px solid var(--zz-gray-100);
}

.mobile-account-menu a {
    display: flex;
    align-items: center;
    gap: var(--space-3);
    padding: var(--space-4) 0;
    font-size: var(--text-sm);
    font-weight: 500;
    color: var(--zz-black);
    transition: color var(--transition-base);
}

.mobile-account-menu a:hover {
    color: var(--zz-gold);
}

.mobile-account-menu .material-icons-outlined {
    font-size: 20px;
    color: var(--zz-gray-500);
}

/* ─── Touch Optimizations ─── */
@media (hover: none) and (pointer: coarse) {
    /* Show product actions always on touch devices */
    .product-card-actions {
        opacity: 1;
        transform: translateY(0);
    }

    /* Larger touch targets */
    .action-btn {
        width: 40px;
        height: 40px;
    }

    .header-icon {
        min-width: 44px;
        min-height: 44px;
    }

    .bottom-nav-item {
        min-height: 44px;
    }
}

/* ─── Landscape Mobile Fix ─── */
@media (max-height: 500px) and (orientation: landscape) {
    .slide {
        min-height: 300px;
    }

    .slide-content {
        min-height: 300px;
    }

    .mobile-bottom-nav {
        height: 48px;
    }

    .bottom-nav-label {
        display: none;
    }
}

/* ─── Print Styles ─── */
@media print {
    .site-header,
    .mobile-bottom-nav,
    .whatsapp-float,
    .newsletter-section,
    .instagram-section,
    .slider-arrow,
    .slider-dots {
        display: none !important;
    }

    .site-content {
        padding-bottom: 0 !important;
    }

    body {
        font-size: 12pt;
        color: #000;
    }
}
