/**
 * Old Pump Soaps - Responsive Styles
 * Mobile-first responsive design
 */

/* =======================
   Mobile (default)
   ======================= */

/* Ensure text is readable on small screens */
body {
    font-size: 16px;
    line-height: 1.6;
}

/* =======================
   Tablet (768px and up)
   ======================= */

@media (min-width: 768px) {
    /* Product grid adjusts to 2 columns */
    .wc-block-grid__products {
        grid-template-columns: repeat(2, 1fr) !important;
    }
}

/* =======================
   Desktop (1024px and up)
   ======================= */

@media (min-width: 1024px) {
    /* Product grid adjusts to 3 columns */
    .wc-block-grid__products {
        grid-template-columns: repeat(3, 1fr) !important;
    }
    
    /* Header improvements */
    .wp-block-site-title {
        font-size: 2rem;
    }
}

/* =======================
   Large Desktop (1200px and up)
   ======================= */

@media (min-width: 1200px) {
    /* Product grid adjusts to 4 columns */
    .wc-block-grid__products {
        grid-template-columns: repeat(4, 1fr) !important;
    }
}

/* =======================
   Mobile-specific Styles
   ======================= */

@media (max-width: 767px) {
    /* Stack columns on mobile */
    .wp-block-columns {
        flex-direction: column;
    }
    
    .wp-block-column {
        flex-basis: 100% !important;
    }
    
    /* Adjust spacing for mobile */
    .wp-block-group.alignfull {
        padding-left: 1rem !important;
        padding-right: 1rem !important;
    }
    
    /* Mobile navigation */
    .wp-block-navigation__responsive-container.is-menu-open {
        padding: 2rem;
    }
    
    /* Hero section adjustments */
    h1 {
        font-size: 2rem !important;
    }
    
    h2 {
        font-size: 1.5rem !important;
    }
    
    /* Product cards */
    .wc-block-grid__product {
        padding: 1rem;
    }
    
    /* Footer stacks */
    .wp-block-group.has-navy-blue-background-color .wp-block-group.alignwide {
        flex-direction: column;
        gap: 2rem;
    }
    
    /* Newsletter form */
    .newsletter-form {
        flex-direction: column;
    }
    
    .newsletter-form input,
    .newsletter-form button {
        width: 100%;
    }
}

/* =======================
   Touch Device Optimizations
   ======================= */

@media (hover: none) and (pointer: coarse) {
    /* Increase tap target sizes */
    .wp-block-button__link,
    .wc-block-components-button {
        min-height: 44px;
        min-width: 44px;
        padding: 0.75rem 1.5rem;
    }
    
    /* Remove hover effects on touch devices */
    .wp-block-group.has-white-background-color:hover {
        transform: none;
    }
    
    .wp-block-button__link:hover {
        transform: none;
    }
}

/* =======================
   Print Styles
   ======================= */

@media print {
    /* Hide navigation and non-essential elements */
    header,
    footer,
    .wp-block-navigation,
    .wc-block-mini-cart,
    .wp-block-button {
        display: none;
    }
    
    /* Ensure readability */
    body {
        font-size: 12pt;
        line-height: 1.5;
        color: #000;
        background: #fff;
    }
    
    /* Expand content width for printing */
    .wp-block-group {
        max-width: none;
    }
}

/* =======================
   Reduced Motion Preference
   ======================= */

@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}
