/* Responsive Styles */

/* Large Desktop */
@media (min-width: 1200px) {
    .container {
        max-width: 1140px;
    }
    
    .product-grid {
        grid-template-columns: repeat(4, 1fr);
    }
}

/* Desktop */
@media (min-width: 992px) and (max-width: 1199px) {
    .container {
        max-width: 960px;
    }
    
    .product-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

/* Tablet */
@media (min-width: 768px) and (max-width: 991px) {
    .container {
        max-width: 720px;
    }
    
    .product-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .hero-slider h1 {
        font-size: 2rem;
    }
    
    .sidebar {
        margin-bottom: 30px;
    }
}

/* Mobile Landscape */
@media (min-width: 576px) and (max-width: 767px) {
    .container {
        max-width: 540px;
    }
    
    .product-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .hero-slider {
        height: 50vh;
    }
    
    .hero-slider h1 {
        font-size: 1.5rem;
    }
    
    .navbar-brand img {
        max-height: 35px;
    }
}

/* Mobile Portrait */
@media (max-width: 575px) {
    .features-section h2 {
        font-size: 1.5rem;
    }
    .container {
        padding-left: 15px;
        padding-right: 15px;
    }
    
    .product-grid {
        grid-template-columns: 1fr;
    }
    
    .hero-slider {
        height: 40vh;
    }
    
    .hero-slider h1 {
        font-size: 1.25rem;
    }
    
    .hero-slider p {
        font-size: 0.875rem;
    }
    
    .btn {
        font-size: 0.875rem;
        padding: 0.375rem 0.75rem;
    }
    
    .card-title {
        font-size: 1rem;
    }
    
    .product-card .card-img-top {
        height: 180px;
    }
    
    .footer {
        text-align: center;
    }
    
    .footer .social-links {
        margin-top: 15px;
    }
    
    .gallery-thumbs {
        display: none;
    }
}

/* Small Mobile */
@media (max-width: 375px) {
    .hero-slider h1 {
        font-size: 1rem;
    }
    
    .btn-lg {
        font-size: 0.875rem;
        padding: 0.5rem 1rem;
    }
}

/* Print Styles */
@media print {
    .navbar,
    .footer,
    .sidebar,
    .btn,
    .share-buttons {
        display: none !important;
    }
    
    body {
        margin: 0;
        padding: 0;
    }
    
    .container {
        width: 100%;
        max-width: none;
    }
}

/* Touch Device Optimizations */
@media (hover: none) and (pointer: coarse) {
    .btn,
    .nav-link,
    .product-card {
        cursor: pointer;
        -webkit-tap-highlight-color: transparent;
    }
    
    input,
    select,
    textarea {
        font-size: 16px !important; /* Prevent zoom on focus in iOS */
    }
}

/* High DPI Screens */
@media (-webkit-min-device-pixel-ratio: 2), (min-resolution: 192dpi) {
    .hero-slide {
        background-size: cover;
    }
}

/* Dark Mode Support */
@media (prefers-color-scheme: dark) {
    body {
        background-color: #121212;
        color: #ffffff;
    }
    
    .card,
    .modal-content {
        background-color: #1e1e1e;
        border-color: #333;
    }
    
    .form-control {
        background-color: #2d2d2d;
        border-color: #444;
        color: #fff;
    }
    
    .table {
        color: #fff;
    }
    
    .table-striped tbody tr:nth-of-type(odd) {
        background-color: rgba(255,255,255,0.05);
    }
}