/* ============================================================
   YUSR Website - Responsive Styles
   Mobile-first breakpoints
   ============================================================ */

/* ===== TABLET (max-width: 1024px) ===== */
@media (max-width: 1024px) {
    .nav {
        display: none;
    }

    .mobile-toggle {
        display: flex;
    }

    .header-cta .btn:not(.btn-whatsapp) {
        display: none;
    }

    .hero .container {
        grid-template-columns: 1fr;
        text-align: center;
    }

    .hero-content {
        order: 1;
    }

    .hero-image {
        order: 2;
        max-width: 500px;
        margin: 0 auto;
        aspect-ratio: 4/3;
        width: 100%;
    }

    .hero-content p {
        margin-right: auto;
        margin-left: auto;
    }

    .hero-buttons {
        justify-content: center;
    }

    .hero-stats {
        justify-content: center;
    }

    .search-form {
        grid-template-columns: 1fr 1fr;
    }

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

    .footer-brand {
        grid-column: 1 / -1;
    }

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

    .sidebar {
        position: static;
    }

    .worker-profile .container {
        grid-template-columns: 1fr;
    }

    .worker-profile-image {
        max-width: 400px;
        margin: 0 auto var(--space-5);
    }

    .contact-grid {
        grid-template-columns: 1fr;
    }

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

/* ===== MOBILE (max-width: 768px) ===== */
@media (max-width: 768px) {
    :root {
        --header-height: 64px;
    }

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

    .section-header {
        margin-bottom: var(--space-5);
    }

    .header-top {
        font-size: 0.75rem;
    }

    .header-top-info {
        gap: var(--space-3);
    }

    .header-top-info span:nth-child(2) {
        display: none;
    }

    .hero {
        padding: var(--space-8) 0 var(--space-6);
    }

    .hero-stats {
        flex-wrap: wrap;
        gap: var(--space-4);
    }

    .hero-stat .number {
        font-size: 1.5rem;
    }

    .search-bar {
        margin-top: -var(--space-4);
    }

    .search-form {
        grid-template-columns: 1fr;
    }

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

    .stat-item .stat-number {
        font-size: 2rem;
    }

    .grid-2, .grid-3, .grid-4 {
        grid-template-columns: 1fr;
    }

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

    .grid-auto {
        grid-template-columns: 1fr;
    }

    .why-grid {
        grid-template-columns: 1fr;
    }

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

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

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

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

    .form-row {
        grid-template-columns: 1fr;
    }

    .worker-info-grid {
        grid-template-columns: 1fr;
    }

    .cta-buttons {
        flex-direction: column;
        align-items: stretch;
    }

    .cta-buttons .btn {
        width: 100%;
    }

    .hero-buttons {
        flex-direction: column;
        align-items: stretch;
    }

    .hero-buttons .btn {
        width: 100%;
    }

    .pagination {
        flex-wrap: wrap;
    }

    .breadcrumbs ol {
        font-size: 0.75rem;
    }

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

    .whatsapp-float {
        width: 48px;
        height: 48px;
        font-size: 1.5rem;
        bottom: 16px;
        right: 16px;
    }

    .scroll-top {
        bottom: 16px;
        left: 16px;
        width: 40px;
        height: 40px;
    }
}

/* ===== SMALL MOBILE (max-width: 480px) ===== */
@media (max-width: 480px) {
    .countries-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .grid-3 {
        grid-template-columns: 1fr;
    }

    .stats-grid {
        grid-template-columns: 1fr;
    }

    .card-body {
        padding: var(--space-4);
    }

    .section-header h2 {
        font-size: 1.375rem;
    }

    .error-page .error-code {
        font-size: 4rem;
    }

    .logo {
        font-size: 1.25rem;
    }

    .logo-icon {
        width: 32px;
        height: 32px;
        font-size: 1rem;
    }
}

/* ===== PRINT ===== */
@media print {
    .header, .footer, .whatsapp-float, .scroll-top,
    .cta-section, .mobile-nav, .mobile-nav-overlay {
        display: none !important;
    }

    body {
        color: #000;
        background: #fff;
    }

    .card, .sidebar-card {
        break-inside: avoid;
        border: 1px solid #ddd;
    }
}

/* ===== ACCESSIBILITY ===== */
@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;
    }
}

:focus-visible {
    outline: 3px solid var(--color-secondary);
    outline-offset: 2px;
}

.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

.skip-link {
    position: absolute;
    top: -40px;
    right: 0;
    background: var(--color-primary);
    color: var(--color-white);
    padding: var(--space-2) var(--space-4);
    border-radius: 0 0 0 var(--radius-sm);
    z-index: 9999;
    transition: top 0.3s;
}

.skip-link:focus {
    top: 0;
    color: var(--color-white);
}
