/* Responsive Styles for Rozvelle */

@media (max-width: 991px) {
    /* Tablet Styles */
    
    /* 2. HEADER */
    .header-container {
        flex-wrap: wrap;
        position: relative;
    }

    .header-logo {
        order: 2;
        flex: 2; /* Allow it to take up more space and center */
        display: flex;
        justify-content: center;
        align-items: center;
    }

    .header-logo-img {
        height: 45px; /* Slightly smaller logo on mobile */
    }

    .mobile-menu-toggle {
        display: flex;
        order: 1;
        flex: 1;
        justify-content: flex-start;
        align-items: center;
        position: static;
        color: var(--maroon-dark);
        font-size: 24px;
        background: none;
        border: none;
        cursor: pointer;
        padding: 5px 0; /* Align perfectly with edges */
    }

    .header-actions {
        order: 3;
        flex: 1;
        justify-content: flex-end;
        gap: 15px;
    }

    /* Hide text in header actions on tablet/mobile */
    .action-item span {
        display: none;
    }

    /* Hide specific action items on mobile to save space */
    .header-actions .action-item:nth-child(1), /* Account */
    .header-actions .action-item:nth-child(3) { /* Track Order */
        display: none;
    }

    /* Make search bar take full width below logo */
    .main-header > .container > div[style*="position: relative"] {
        order: 4 !important;
        flex: 0 0 100% !important;
        max-width: 100% !important;
        margin-top: 10px;
    }

    .header-search {
        display: flex !important;
        width: 100%;
    }
    
    /* 3. NAVIGATION */
    .nav-links {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        width: 100%;
        background-color: var(--maroon-dark);
        flex-direction: column;
        padding: 0;
        gap: 0;
        z-index: 100;
        box-shadow: 0 10px 20px rgba(0,0,0,0.15);
    }
    
    .nav-links a {
        padding: 15px 20px;
        border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    }
    
    .nav-links.nav-open {
        display: flex;
        animation: slideDown 0.3s ease forwards;
    }
    
    @keyframes slideDown {
        from { opacity: 0; transform: translateY(-10px); }
        to { opacity: 1; transform: translateY(0); }
    }
    
    .nav-container {
        justify-content: center;
        padding: 0; /* Remove padding as toggle is moved to header */
    }
    
    /* 4. HERO SECTION */
    .hero {
        padding: 60px 0;
    }
    
    .hero-container {
        flex-direction: column;
        text-align: center;
        gap: 60px;
    }
    
    .hero-right {
        align-items: center;
    }
    
    .hero-divider {
        margin: 0 auto 30px auto;
    }
    
    .hero-title {
        font-size: clamp(48px, 8vw, 78px);
    }
    
    .hero-script {
        font-size: clamp(36px, 6vw, 52px);
    }
    
    /* 5. TRUST BAR */
    .features-container {
        display: grid;
        grid-template-columns: repeat(2, 1fr);
        gap: 30px;
    }
    
    /* 6. PRODUCTS GRID */
    .product-grid {
        grid-template-columns: repeat(3, 1fr);
    }
    
    /* 8. FOOTER */
    .footer-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 767px) {
    /* Mobile Large Styles */
    
    /* 1. TOP UTILITY BAR */
    .top-bar-item:not(:nth-child(3)):not(:nth-child(4)) {
        display: none;
    }
    
    .top-bar-social {
        display: none;
    }
    
    .top-bar-container {
        justify-content: center;
        gap: 30px;
    }
    
    /* 2. HEADER */
    .header-logo .logo-title {
        font-size: 22px;
        letter-spacing: 1px;
    }
    
    .header-logo .logo-badge {
        width: 40px;
        height: 40px;
        font-size: 20px;
    }
    
    .header-logo .logo-subtitle {
        font-size: 9px;
        letter-spacing: 2px;
    }
    
    /* 4. HERO SECTION */
    .hero-logo-img {
        max-width: 320px;
    }
    
    /* 6. PRODUCTS GRID */
    .product-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 15px;
    }
    
    .product-name {
        font-size: 13px;
    }
    
    .product-price {
        font-size: 14px;
    }
    
    /* 7. WHATSAPP BANNER */
    .whatsapp-banner {
        flex-direction: column;
        text-align: center;
        gap: 25px;
        padding: 30px 20px;
    }
    
    .whatsapp-left {
        flex-direction: column;
        gap: 15px;
    }
    
    .btn-whatsapp-cta {
        width: 100%;
    }
}

@media (max-width: 480px) {
    /* Small Mobile Styles */
    
    /* 1. TOP UTILITY BAR */
    .top-bar {
        font-size: 12px;
    }
    
    .top-bar-container {
        gap: 15px;
    }
    
    /* 4. HERO SECTION */
    .hero-logo-img {
        max-width: 270px;
    }
    
    /* 5. TRUST BAR */
    .features-container {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    
    .feature-item {
        justify-content: center;
        text-align: center;
        flex-direction: column;
        gap: 10px;
    }
    
    /* 8. FOOTER */
    .footer-grid {
        grid-template-columns: 1fr;
        text-align: center;
        gap: 30px;
    }
    
    .footer-social {
        justify-content: center;
    }
    
    .footer-contact li {
        justify-content: center;
        flex-direction: column;
        align-items: center;
        gap: 5px;
    }
    
    .footer-contact i {
        margin-top: 0;
        margin-bottom: 5px;
    }
    
    .footer-bottom-container {
        flex-direction: column;
        gap: 20px;
    }
    
    /* Tap Targets Accessibility */
    .btn-primary, .btn-whatsapp-cta, .btn-product-order {
        min-height: 44px;
    }
    
    .nav-links a {
        min-height: 44px;
        display: flex;
        align-items: center;
    }
}

/* Mobile App-like Enhancements */
@media (max-width: 767px) {
    /* Sticky Header with Glassmorphism */
    .main-header {
        position: sticky;
        top: 0;
        z-index: 1000;
        background: rgba(255, 255, 255, 0.9);
        backdrop-filter: blur(10px);
        -webkit-backdrop-filter: blur(10px);
        box-shadow: 0 4px 15px rgba(0,0,0,0.05);
    }
    
    /* Improve Product Cards */
    .product-actions {
        flex-direction: column;
        gap: 10px;
    }
    .btn-product-cart, .btn-product-order {
        width: 100%;
        justify-content: center;
        height: 48px; /* Better touch target */
    }
    
    /* Enhance Touch Targets for inputs */
    input[type="text"], input[type="email"], input[type="tel"], input[type="password"], input[type="number"], select, textarea {
        min-height: 48px;
    }
    
    /* Padding bottom to avoid overlap with bottom nav */
    body {
        padding-bottom: 70px;
    }

    /* Hide redundant header action items, leave hamburger menu */
    .header-actions .action-item {
        display: none !important;
    }
    
    .shop-sidebar form {
        display: flex;
        flex-direction: column;
    }
    .shop-sidebar .filter-box {
        display: flex;
        flex-direction: row;
        overflow-x: auto;
        white-space: nowrap;
        gap: 15px;
        padding-bottom: 10px;
        align-items: center;
        -webkit-overflow-scrolling: touch;
    }
    .shop-sidebar .filter-box h3 {
        margin: 0;
        margin-right: 10px;
        min-width: max-content;
    }
    .shop-sidebar .filter-box label {
        display: inline-flex;
        align-items: center;
        gap: 5px;
        margin: 0;
        min-width: max-content;
        background: #f8f9fa;
        padding: 8px 15px;
        border-radius: 20px;
        border: 1px solid #eee;
    }
    .shop-sidebar .filter-box div {
        display: flex !important;
        gap: 10px;
        min-width: max-content;
    }
}

/* Bottom Navigation Bar (Mobile Only) */
.mobile-bottom-nav {
    display: none;
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    box-shadow: 0 -2px 10px rgba(0,0,0,0.1);
    z-index: 9999;
    justify-content: space-around;
    padding: 10px 0;
    border-top: 1px solid #eee;
}

@media (max-width: 767px) {
    .mobile-bottom-nav {
        display: flex;
    }
}

.mobile-bottom-nav .nav-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    color: #666;
    text-decoration: none;
    font-size: 11px;
    gap: 4px;
    width: 25%;
}

.mobile-bottom-nav .nav-item i {
    font-size: 20px;
    transition: color 0.3s;
}

.mobile-bottom-nav .nav-item.active {
    color: var(--maroon-dark);
}

.mobile-bottom-nav .nav-item.active i {
    color: var(--maroon-dark);
}
