/**
 * Responsive Design System
 * Mobile-first approach with premium breakpoints
 */

/* ═══════════════════════════════════════════════════════════════ */
/* MOBILE BASE (< 480px) */
/* ═══════════════════════════════════════════════════════════════ */

@media (max-width: 479px) {
    :root {
        --space-3xl: 2.5rem;
        --space-4xl: 3.5rem;
    }

    h1 {
        font-size: 1.8rem;
    }

    h2 {
        font-size: 1.4rem;
    }

    h3 {
        font-size: 1.1rem;
    }

    .container {
        padding: 0 var(--space-md);
    }

    section {
        padding: var(--space-2xl) 0;
    }

    .navbar {
        padding: var(--space-sm) 0;
    }

    .navbar-nav {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background: rgba(26, 26, 46, 0.98);
        flex-direction: column;
        gap: 0;
        padding: var(--space-lg) 0;
        border-bottom: 1px solid rgba(255, 255, 255, 0.1);
        z-index: 999;
    }

    .navbar-nav.active {
        display: flex;
    }

    .nav-link {
        padding: var(--space-md) var(--space-lg);
    }

    .mobile-menu-btn {
        display: flex;
    }

    .product-grid {
        grid-template-columns: 1fr;
        gap: var(--space-xl);
    }

    .hero-split {
        grid-template-columns: 1fr;
        gap: var(--space-xl);
    }

    .steps {
        flex-direction: column;
        gap: var(--space-2xl);
    }

    .steps::before {
        display: none;
    }

    .btn {
        padding: 0.75rem 1.5rem;
        font-size: 0.9rem;
        width: 100%;
    }

    .product-actions {
        flex-direction: column;
    }

    .product-actions .btn {
        width: 100%;
    }

    form {
        width: 100%;
    }

    .modal-content {
        margin: var(--space-lg);
        max-width: 100%;
    }

    .stat-card {
        padding: var(--space-lg);
    }

    .stat-number {
        font-size: 1.8rem;
    }

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

    .footer-bottom {
        flex-direction: column;
        text-align: center;
    }
}

/* ═══════════════════════════════════════════════════════════════ */
/* SMALL PHONES (480px - 767px) */
/* ═══════════════════════════════════════════════════════════════ */

@media (min-width: 480px) and (max-width: 767px) {
    :root {
        --space-3xl: 3rem;
        --space-4xl: 4rem;
    }

    h1 {
        font-size: 2rem;
    }

    h2 {
        font-size: 1.6rem;
    }

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

    .hero-split {
        grid-template-columns: 1fr;
    }

    .container {
        padding: 0 var(--space-lg);
    }

    .steps {
        flex-direction: column;
    }

    .steps::before {
        display: none;
    }

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

/* ═══════════════════════════════════════════════════════════════ */
/* TABLETS (768px - 1023px) */
/* ═══════════════════════════════════════════════════════════════ */

@media (min-width: 768px) and (max-width: 1023px) {
    .product-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: var(--space-2xl);
    }

    .hero-split {
        grid-template-columns: 1fr 0.9fr;
        gap: var(--space-2xl);
    }

    .container {
        padding: 0 var(--space-xl);
    }

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

/* ═══════════════════════════════════════════════════════════════ */
/* SMALL DESKTOP (1024px - 1199px) */
/* ═══════════════════════════════════════════════════════════════ */

@media (min-width: 1024px) and (max-width: 1199px) {
    .product-grid {
        grid-template-columns: repeat(3, 1fr);
        gap: var(--space-2xl);
    }

    .container {
        max-width: 1024px;
    }
}

/* ═══════════════════════════════════════════════════════════════ */
/* DESKTOP (1200px - 1439px) */
/* ═══════════════════════════════════════════════════════════════ */

@media (min-width: 1200px) and (max-width: 1439px) {
    .product-grid {
        grid-template-columns: repeat(3, 1fr);
    }

    .container {
        max-width: 1140px;
    }
}

/* ═══════════════════════════════════════════════════════════════ */
/* LARGE DESKTOP (1440px+) */
/* ═══════════════════════════════════════════════════════════════ */

@media (min-width: 1440px) {
    .container {
        max-width: 1320px;
    }

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

    section {
        padding: var(--space-4xl) 0;
    }
}

/* ═══════════════════════════════════════════════════════════════ */
/* LANDSCAPE ORIENTATION */
/* ═══════════════════════════════════════════════════════════════ */

@media (orientation: landscape) and (max-height: 600px) {
    .hero {
        min-height: 80vh;
    }

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

    h1 {
        font-size: 1.5rem;
    }
}

/* ═══════════════════════════════════════════════════════════════ */
/* PRINT STYLES */
/* ═══════════════════════════════════════════════════════════════ */

@media print {
    body {
        font-size: 12pt;
        color: #000;
        background: #fff;
    }

    .navbar,
    footer,
    .btn,
    .modal {
        display: none;
    }

    section {
        page-break-inside: avoid;
    }

    a {
        text-decoration: underline;
    }
}

/* ═══════════════════════════════════════════════════════════════ */
/* HIGH DPI / RETINA DISPLAYS */
/* ═══════════════════════════════════════════════════════════════ */

@media (-webkit-min-device-pixel-ratio: 2), (min-resolution: 192dpi) {
    body {
        -webkit-font-smoothing: antialiased;
        -moz-osx-font-smoothing: grayscale;
    }
}

/* ═══════════════════════════════════════════════════════════════ */
/* DARK MODE SUPPORT (FUTURE) */
/* ═══════════════════════════════════════════════════════════════ */

@media (prefers-color-scheme: dark) {
    /* Can be extended for dark mode */
}

/* ═══════════════════════════════════════════════════════════════ */
/* REDUCED MOTION */
/* ═══════════════════════════════════════════════════════════════ */

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

/* ═══════════════════════════════════════════════════════════════ */
/* TOUCH DEVICE OPTIMIZATIONS */
/* ═══════════════════════════════════════════════════════════════ */

@media (hover: none) and (pointer: coarse) {
    .btn {
        min-height: 48px;
        padding: 0.875rem 1.5rem;
    }

    .product-card {
        transform: none;
    }

    .product-card:active {
        transform: scale(0.98);
    }

    a {
        min-height: 44px;
        display: inline-flex;
        align-items: center;
    }
}

/* ═══════════════════════════════════════════════════════════════ */
/* RESPONSIVE TABLES */
/* ═══════════════════════════════════════════════════════════════ */

@media (max-width: 767px) {
    .table {
        font-size: 0.85rem;
    }

    .table th,
    .table td {
        padding: var(--space-md) var(--space-sm);
    }

    .table thead {
        display: none;
    }

    .table tbody,
    .table tr,
    .table td {
        display: block;
        width: 100%;
    }

    .table tr {
        margin-bottom: var(--space-xl);
        border: 1px solid var(--border-color);
        border-radius: var(--radius-lg);
        overflow: hidden;
    }

    .table td {
        position: relative;
        padding-left: 50%;
        text-align: right;
    }

    .table td::before {
        content: attr(data-label);
        position: absolute;
        left: var(--space-md);
        font-weight: 600;
        color: var(--text-primary);
    }
}

/* ═══════════════════════════════════════════════════════════════ */
/* RESPONSIVE GRID FIXES */
/* ═══════════════════════════════════════════════════════════════ */

@media (max-width: 1023px) {
    .hero-split {
        gap: var(--space-xl);
    }
}

/* ═══════════════════════════════════════════════════════════════ */
/* BREADCRUMB RESPONSIVE */
/* ═══════════════════════════════════════════════════════════════ */

@media (max-width: 767px) {
    .breadcrumb {
        font-size: 0.8rem;
        gap: var(--space-sm);
    }
}

