/* =====================================================
   Responsive - متجاوب مع جميع الشاشات
   ===================================================== */

/* ===== Mobile (max 768px) ===== */
@media (max-width: 768px) {
    /* Touch-friendly tap targets */
    button, .btn, .btn-add-cart, .btn-primary, .btn-submit,
    .filter-tag, .theme-toggle, .cart-link {
        min-height: 44px;
    }

    /* Header */
    .nav-link { display: none; }
    .header-inner { padding: 0 16px; }
    .logo-img { height: 36px; }
    .header.scrolled .logo-img { height: 30px; }

    /* Container */
    .container { padding: 0 16px; }

    /* Footer store location */
    .store-location-inner {
        grid-template-columns: 1fr;
        gap: 24px;
    }
    .location-map { height: 200px; }
    .store-location { padding: 36px 16px; }

    /* Checkout */
    .checkout-grid { grid-template-columns: 1fr; }
    .summary-card { position: static; order: -1; }

    /* Stepper */
    .step-label { display: none; }

    /* Features bar */
    .features-bar { padding: 14px 10px; }
    .feature-item { padding: 6px 14px; }
    .feature-item h4 { font-size: 11px; }
    .feature-item .icon { font-size: 18px; }
    .feature-item p { display: none; }

    /* Back to top + Floating cart */
    .back-to-top { bottom: 20px; right: 16px; width: 38px; height: 38px; font-size: 15px; }
    .floating-cart { bottom: 20px; left: 16px; width: 50px; height: 50px; font-size: 20px; }

    /* Cards */
    .card { padding: 18px; }

    /* Section title */
    .section-title { font-size: 18px; }
}

/* ===== Small Phones (max 400px) ===== */
@media (max-width: 400px) {
    .header-inner { padding: 0 12px; }
    .logo-img { height: 30px; }
    .card { padding: 14px; border-radius: var(--radius); }
    .container { padding: 0 12px; }
    .section-title { font-size: 16px; }
}

/* ===== Tablet (769px - 1024px) ===== */
@media (min-width: 769px) and (max-width: 1024px) {
    .container { padding: 0 24px; }
    .products-grid { grid-template-columns: repeat(3, 1fr); }
}

/* ===== Large Desktop (1200px+) ===== */
@media (min-width: 1200px) {
    .products-grid { grid-template-columns: repeat(4, 1fr); }
}

/* ===== Reduce Motion ===== */
@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
    .hero::before, .hero::after, .particle { display: none; }
}

/* ===== iOS Safari ===== */
@supports (-webkit-touch-callout: none) {
    body { min-height: -webkit-fill-available; }
}

/* ===== Dark mode - theme color ===== */
@media (prefers-color-scheme: dark) {
    :root { color-scheme: light dark; }
}

/* ===== Landscape phones ===== */
@media (max-height: 500px) and (orientation: landscape) {
    .hero { padding: 30px 20px 25px; }
    .hero h1 { font-size: 22px; }
    .features-bar { display: none; }
}
