/* ===============================================
   COMPLETE RESPONSIVE STYLES - FIXED VERSION
   All Breakpoints & Pages Included
   =============================================== */

/* ============================================
   LARGE DESKTOP (1440px and above)
   ============================================ */
@media (min-width: 1440px) {
    .container {
        max-width: 1400px;
    }
    
    .hero-title {
        font-size: 64px;
    }
    
    .section-title {
        font-size: 42px;
    }
}

/* ============================================
   DESKTOP (1200px - 1439px)
   ============================================ */
@media (max-width: 1439px) {
    .container {
        max-width: 1140px;
    }
}

/* ============================================
   LAPTOP / SMALL DESKTOP (1024px - 1199px)
   ============================================ */
@media (max-width: 1199px) {
    .container {
        max-width: 960px;
        padding: 0 20px;
    }

    .hero-title {
        font-size: 48px;
    }

    .section-title {
        font-size: 32px;
    }

    .products-grid {
        grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
        gap: var(--spacing-md);
    }

    .shop-layout {
        grid-template-columns: 260px 1fr;
    }
    
    .product-details-wrapper {
        gap: var(--spacing-lg);
    }
    
    .cart-layout {
        grid-template-columns: 1fr 350px;
    }
    
    .checkout-layout {
        grid-template-columns: 1fr 380px;
    }
}

/* ============================================
   TABLET LANDSCAPE (992px - 1023px)
   ============================================ */
@media (max-width: 1023px) {
    .container {
        max-width: 720px;
    }

    /* Header Adjustments */
    .top-bar-content {
        font-size: 13px;
    }

    .search-bar {
        max-width: 400px;
    }

    .nav-menu {
        gap: 5px;
    }

    .nav-menu a {
        padding: 8px 15px;
        font-size: 14px;
    }

    /* Hero Section */
    .hero-banner {
        padding: 80px 0;
    }

    .hero-title {
        font-size: 42px;
    }

    .hero-subtitle {
        font-size: 18px;
    }

    /* Products */
    .products-grid {
        grid-template-columns: repeat(3, 1fr);
        gap: var(--spacing);
    }

    .product-image {
        height: 250px;
    }

    /* Shop Page */
    .shop-layout {
        grid-template-columns: 240px 1fr;
    }

    /* Product Details */
    .product-details-wrapper {
        grid-template-columns: 1fr;
    }

    .product-gallery {
        position: static;
    }

    .main-image img {
        height: 400px;
    }

    /* Cart & Checkout */
    .cart-layout,
    .checkout-layout {
        grid-template-columns: 1fr;
    }

    .cart-summary,
    .order-summary {
        position: static;
    }

    /* About Page */
    .story-stats {
        grid-template-columns: repeat(2, 1fr);
    }

    /* Footer */
    .footer-content {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* ============================================
   TABLET PORTRAIT (768px - 991px)
   ============================================ */
@media (max-width: 991px) {
    .container {
        max-width: 100%;
        padding: 0 20px;
    }

    /* Typography */
    .hero-title {
        font-size: 36px;
    }

    .section-title {
        font-size: 28px;
    }

    .page-title {
        font-size: 28px;
    }

    /* Header */
    .top-bar {
        padding: 10px 0;
    }

    .top-bar-content {
        flex-direction: column;
        gap: 10px;
        text-align: center;
    }

    .contact-info {
        /*flex-direction: column;*/
        gap: 5px;
    }

    .user-actions {
        justify-content: center;
    }

    .nav-content {
        flex-wrap: wrap;
    }

    .logo a {
        font-size: 22px;
    }

    .logo i {
        font-size: 26px;
    }

    .search-bar {
        order: 3;
        width: 100%;
        max-width: 100%;
        margin-top: var(--spacing-sm);
    }

    .mobile-menu-toggle {
        display: block;
    }

    .nav-menu {
        display: none;
        flex-direction: column;
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background: var(--bg-white);
        box-shadow: var(--shadow-lg);
        border-top: 1px solid var(--border-color);
        padding: var(--spacing);
        margin-top: 0;
        border-top: none;
        z-index: 999;
    }

    .nav-menu.active {
        display: flex;
    }

    .nav-menu li {
        width: 100%;
    }

    .nav-menu a {
        width: 100%;
        padding: 12px 15px;
        justify-content: flex-start;
    }

    .dropdown-menu {
        position: static;
        box-shadow: none;
        padding-left: var(--spacing-md);
        margin-top: var(--spacing-sm);
        background: var(--bg-light);
    }

    /* Hero */
    .hero-banner {
        padding: 60px 0;
    }

    /* Grids */
    .features-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: var(--spacing-md);
    }

    .categories-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: var(--spacing);
    }

    .products-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: var(--spacing);
    }

    .product-image {
        height: 220px;
    }

    .product-name {
        font-size: 15px;
    }

    .price-current {
        font-size: 20px;
    }

    .testimonials-grid {
        grid-template-columns: 1fr;
    }

    /* Newsletter */
    .newsletter-content {
        flex-direction: column;
        text-align: center;
    }

    .newsletter-form {
        width: 100%;
        max-width: 500px;
        margin: 0 auto;
    }

    /* Shop Page */
    .shop-layout {
        grid-template-columns: 1fr;
    }

    .shop-sidebar {
        position: static;
        margin-bottom: var(--spacing-md);
    }

    .shop-toolbar {
        flex-direction: column;
        gap: var(--spacing);
        align-items: flex-start;
    }

    .shop-controls {
        width: 100%;
        justify-content: space-between;
    }

    /* Product Details */
    .product-title {
        font-size: 26px;
    }

    .product-rating-review {
        flex-direction: column;
        align-items: flex-start;
    }

    .product-actions {
        flex-direction: column;
    }

    .product-actions .btn {
        width: 100%;
    }

    .reviews-summary {
        grid-template-columns: 1fr;
    }

    /* Cart */
    .cart-item {
        grid-template-columns: 100px 1fr 120px 80px 40px;
        gap: var(--spacing-sm);
        padding: var(--spacing);
    }

    .cart-item-image img {
        height: 100px;
    }

    .cart-item-details h4 {
        font-size: 14px;
    }

    .item-total {
        font-size: 16px;
    }

    .cart-actions {
        flex-direction: column;
        gap: var(--spacing-sm);
    }

    .cart-actions .btn {
        width: 100%;
    }

    /* Checkout */
    .checkout-steps {
        flex-wrap: wrap;
        gap: var(--spacing);
    }

    .step {
        flex-direction: column;
        text-align: center;
    }

    .checkout-actions {
        flex-direction: column;
        gap: var(--spacing-sm);
    }

    .checkout-actions .btn {
        width: 100%;
    }

    /* Wishlist */
    .wishlist-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .wishlist-actions {
        flex-direction: column;
    }

    .wishlist-actions .btn {
        width: 100%;
    }

    /* About Page */
    .about-hero-content h1 {
        font-size: 36px;
    }

    .story-content {
        grid-template-columns: 1fr;
    }

    .story-text h2 {
        font-size: 28px;
    }

    .values-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .team-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    /* Contact Page */
    .contact-info-cards {
        grid-template-columns: 1fr;
    }

    /* Footer */
    .footer-content {
        grid-template-columns: 1fr;
        gap: var(--spacing-lg);
    }

    .footer-bottom {
        flex-direction: column;
        text-align: center;
    }
}

/* ============================================
   MOBILE LANDSCAPE (576px - 767px)
   ============================================ */
@media (max-width: 767px) {
    /* Typography */
    .hero-title {
        font-size: 28px;
    }

    .hero-subtitle {
        font-size: 16px;
    }

    .section-title {
        font-size: 24px;
    }

    .page-title {
        font-size: 24px;
    }

    /* Header */
    .logo a {
        font-size: 20px;
    }

    .nav-icon {
        font-size: 22px;
    }

    .nav-icons {
        gap: var(--spacing);
    }

    /* Hero */
    .hero-banner {
        padding: 50px 0;
    }

    .hero-tag {
        font-size: 12px;
        padding: 8px 20px;
    }

    /* Buttons */
    .btn {
        padding: 10px 20px;
        font-size: 14px;
    }

    .btn-lg {
        padding: 12px 30px;
        font-size: 16px;
    }

    .btn-sm {
        padding: 6px 15px;
        font-size: 13px;
    }

    /* Grids */
    .features-grid {
        grid-template-columns: 1fr;
    }

    .categories-grid,
    .products-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: var(--spacing-sm);
    }

    .product-card {
        font-size: 13px;
    }

    .product-image {
        height: 180px;
    }

    .product-name {
        font-size: 14px;
        height: 42px;
    }

    .price-current {
        font-size: 18px;
    }

    .btn-icon {
        width: 38px;
        height: 38px;
        font-size: 16px;
    }

    /* Product Details */
    .main-image img {
        height: 300px;
    }

    .thumbnail-images {
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
    }

    .thumbnail-images img {
        width: 80px;
        height: 80px;
    }

    .product-title {
        font-size: 22px;
    }

    .product-price-main {
        flex-direction: column;
        align-items: flex-start;
    }

    .color-btn {
        width: 35px;
        height: 35px;
    }

    .size-btn {
        padding: 8px 15px;
        font-size: 14px;
    }

    .tab-buttons {
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
    }

    .tab-btn {
        white-space: nowrap;
        padding: 10px 20px;
        font-size: 14px;
    }

    /* Cart */
    .cart-item {
        grid-template-columns: 80px 1fr;
        gap: var(--spacing-sm);
    }

    .cart-item-image img {
        height: 80px;
    }

    .cart-item-quantity {
        grid-column: 1 / -1;
        justify-content: center;
        margin-top: var(--spacing-sm);
    }

    .cart-item-total {
        grid-column: 1 / -1;
        text-align: center;
        margin-top: var(--spacing-sm);
    }

    .cart-item-remove {
        /*position: absolute;*/
        top: var(--spacing-sm);
        right: var(--spacing-sm);
    }

    /* Checkout */
    .checkout-steps {
        flex-direction: column;
    }

    .form-row {
        grid-template-columns: 1fr;
    }

    .shipping-options,
    .payment-options {
        gap: var(--spacing-sm);
    }

    .option-content {
        flex-direction: column;
        align-items: flex-start;
    }

    /* Wishlist */
    .wishlist-grid {
        grid-template-columns: 1fr;
    }

    .wishlist-image {
        height: 220px;
    }

    /* About */
    .about-hero-content h1 {
        font-size: 28px;
    }

    .story-text h2 {
        font-size: 24px;
    }

    .story-stats {
        grid-template-columns: repeat(2, 1fr);
        gap: var(--spacing-sm);
    }

    .stat h3 {
        font-size: 28px;
    }

    .values-grid,
    .team-grid {
        grid-template-columns: 1fr;
    }

    .cta-content h2 {
        font-size: 28px;
    }

    /* Contact */
    .contact-form-wrapper h2 {
        font-size: 24px;
    }

    /* Error Page */
    .error-code {
        font-size: 80px;
    }

    .error-message {
        font-size: 24px;
    }

    .error-actions {
        flex-direction: column;
    }

    .error-actions .btn {
        width: 100%;
    }

    /* Modal */
    .modal-content {
        padding: var(--spacing-md);
        width: 95%;
    }

    .modal h2 {
        font-size: 22px;
    }

    /* Newsletter */
    .newsletter-text h2 {
        font-size: 24px;
    }

    .newsletter-form {
        flex-direction: column;
    }

    /* Back to Top */
    .back-to-top {
        width: 45px;
        height: 45px;
        bottom: 20px;
        right: 20px;
        font-size: 18px;
    }

    /* Pagination */
    .pagination-btn {
        width: 35px;
        height: 35px;
        font-size: 14px;
    }
}

/* ============================================
   MOBILE PORTRAIT (480px - 575px)
   ============================================ */
@media (max-width: 575px) {
    .container {
        padding: 0 15px;
    }

    /* Typography */
    .hero-title {
        font-size: 24px;
    }

    .section-title {
        font-size: 22px;
    }

    /* Header */
    .top-bar {
        font-size: 12px;
        padding: 8px 0;
    }

    .logo a {
        font-size: 18px;
    }

    .logo i {
        font-size: 22px;
    }

    .nav-icon {
        font-size: 20px;
    }

    /* Products */
    .products-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 10px;
    }

    .product-image {
        height: 150px;
    }

    .product-card {
        border-radius: var(--radius-sm);
    }

    .product-info {
        padding: var(--spacing-sm);
    }

    .product-name {
        font-size: 13px;
        height: 38px;
    }

    .price-current {
        font-size: 16px;
    }

    .discount-percent {
        font-size: 10px;
        padding: 2px 6px;
    }

    /* Product Details */
    .main-image img {
        height: 250px;
    }

    .product-title {
        font-size: 20px;
    }

    .product-info-main {
        padding: var(--spacing);
    }

    /* Cart */
    .cart-item {
        padding: var(--spacing-sm);
        border-radius: var(--radius-sm);
    }

    /* Forms */
    .form-group input,
    .form-group textarea,
    .form-group select {
        padding: 10px 12px;
        font-size: 14px;
    }

    /* Buttons */
    .btn {
        padding: 10px 20px;
        font-size: 14px;
    }

    /* Newsletter */
    .newsletter-text h2 {
        font-size: 20px;
    }

    /* Footer */
    .footer-content {
        gap: var(--spacing-md);
    }

    .payment-methods {
        font-size: 24px;
    }
}

/* ============================================
   SMALL MOBILE (max-width: 479px)
   ============================================ */
@media (max-width: 479px) {
    /* Typography */
    .hero-title {
        font-size: 22px;
    }

    .hero-subtitle {
        font-size: 14px;
    }

    .section-title {
        font-size: 20px;
    }

    .page-title {
        font-size: 20px;
    }

    /* Header */
    .search-bar input {
        padding: 10px 15px;
        font-size: 13px;
    }

    .search-bar button {
        padding: 10px 20px;
    }

    /* Products */
    .products-grid {
        grid-template-columns: 1fr;
    }

    .product-image {
        height: 200px;
    }

    /* Product Details */
    .product-overlay {
        flex-direction: column;
    }

    .btn-icon {
        width: 35px;
        height: 35px;
    }

    /* About */
    .story-stats {
        grid-template-columns: 1fr;
    }

    /* Error Page */
    .error-code {
        font-size: 60px;
    }

    .error-message {
        font-size: 20px;
    }

    .error-description {
        font-size: 14px;
    }
}

/* ============================================
   LANDSCAPE MODE FIXES
   ============================================ */
@media (max-height: 500px) and (orientation: landscape) {
    .hero-banner {
        padding: 40px 0;
    }

    .modal-content {
        max-height: 95vh;
    }

    .product-gallery {
        position: static;
    }

    .main-image img {
        height: 300px;
    }
}

/* ============================================
   PRINT STYLES
   ============================================ */
@media print {
    .site-header,
    .site-footer,
    .back-to-top,
    .modal,
    .notification,
    .mobile-menu-toggle,
    .product-overlay,
    .btn,
    .search-bar,
    .nav-icons,
    .user-actions,
    .newsletter-section {
        display: none !important;
    }

    body {
        background: white;
        color: black;
    }

    .container {
        max-width: 100%;
    }
}

/* ============================================
   ACCESSIBILITY IMPROVEMENTS
   ============================================ */
@media (prefers-reduced-motion: reduce) {
    * {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}

/* High Contrast Mode */
@media (prefers-contrast: high) {
    :root {
        --border-color: #000;
        --shadow: 0 2px 4px rgba(0, 0, 0, 0.5);
    }
}

/* ============================================
   TOUCH DEVICE OPTIMIZATIONS
   ============================================ */
@media (hover: none) and (pointer: coarse) {
    .btn,
    .nav-menu a,
    .product-card,
    .wishlist-item {
        min-height: 44px;
        min-width: 44px;
    }

    .btn-icon {
        min-width: 44px;
        min-height: 44px;
    }

    .product-overlay {
        opacity: 1;
        background: rgba(0, 0, 0, 0.3);
    }
}

/* ============================================
   CUSTOM SCROLLBAR (WEBKIT)
   ============================================ */
@media (min-width: 768px) {
    ::-webkit-scrollbar {
        width: 10px;
        height: 10px;
    }

    ::-webkit-scrollbar-track {
        background: var(--bg-light);
    }

    ::-webkit-scrollbar-thumb {
        background: var(--text-light);
        border-radius: 5px;
    }

    ::-webkit-scrollbar-thumb:hover {
        background: var(--primary-color);
    }
}

/* Mobile responsive adjustments for slide text in hero slider */
@media (max-width: 767px) {
    .slide-text {
        padding: 8px 12px !important; /* Slightly reduced padding */
        gap: 6px !important; /* Reduced gap if using flex */
        margin: 0 auto !important; /* Center align with no extra margin */
        max-width: 100%; /* Slight width limit for better fit */
    }

    .slide-title {
        /*font-size: 1rem;*/ /* Adjust font size for smaller screens */
        line-height: 1.2;
    }

    .slide-subtitle {
        /*font-size: 1rem;*/
        margin-bottom: 6px;
    }
}

