/* ===================================
   RESPONSIVE STYLES - Premium Theme
   Dacker - Site Vitrine
   =================================== */

/* Large Desktop - 1440px */
@media (max-width: 1440px) {
    :root {
        --container-max: 1200px;
    }
}

/* Desktop - 1200px */
@media (max-width: 1200px) {
    :root {
        --container-max: 1024px;
    }

    .hero-content {
        max-width: 700px;
    }

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

    /* Navigation - Passage en menu mobile */
    .nav-list {
        position: fixed;
        top: 0;
        left: 0;
        right: 0;
        bottom: 0;
        width: 100%;
        height: 100vh;
        background: var(--color-bg-primary);
        flex-direction: column;
        align-items: center;
        justify-content: center;
        gap: var(--spacing-lg);
        opacity: 0;
        visibility: hidden;
        transition: opacity var(--transition-base), visibility var(--transition-base);
        z-index: 1000;
    }

    .nav-list.active {
        opacity: 1;
        visibility: visible;
    }

    .nav-link {
        font-size: 1.75rem;
        font-weight: 600;
        padding: var(--spacing-sm) var(--spacing-lg);
        color: var(--color-text-primary);
    }

    .nav-link:hover,
    .nav-link.active {
        color: var(--color-accent-primary);
    }

    .nav-link::after {
        display: none;
    }

    .nav-toggle {
        display: flex;
        z-index: 1001;
        position: relative;
    }

    .nav-toggle.active span:nth-child(1) {
        transform: rotate(45deg) translate(6px, 6px);
    }

    .nav-toggle.active span:nth-child(2) {
        opacity: 0;
        transform: scaleX(0);
    }

    .nav-toggle.active span:nth-child(3) {
        transform: rotate(-45deg) translate(6px, -6px);
    }

    .nav .btn--primary {
        display: none;
    }

    .theme-toggle {
        z-index: 1001;
        position: relative;
    }

    .lang-switcher {
        display: none;
    }

    /* Show lang switcher inside mobile menu */
    .nav-list.active ~ .lang-switcher-mobile {
        display: flex;
    }
}

/* Tablet - 1024px */
@media (max-width: 1024px) {
    :root {
        --spacing-4xl: 6rem;
        --spacing-3xl: 4rem;
    }

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

    .contact-grid {
        gap: var(--spacing-xl);
    }

    .about-content {
        gap: var(--spacing-xl);
    }

    .portfolio-grid {
        grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    }
}

/* Tablet Portrait - 768px */
@media (max-width: 768px) {
    :root {
        --container-padding: 1.5rem;
        --spacing-4xl: 5rem;
        --spacing-3xl: 3.5rem;
    }

    /* Hero */
    .hero {
        min-height: auto;
        padding: 140px 0 100px;
    }

    .hero::before,
    .hero::after {
        width: 300px;
        height: 300px;
    }

    .hero h1 {
        font-size: 2.75rem;
    }

    .hero p {
        font-size: 1.125rem;
    }

    .hero-buttons {
        flex-direction: column;
    }

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

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

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

    .about-image {
        order: -1;
    }

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

    .footer-brand {
        display: flex;
        flex-direction: column;
        align-items: center;
    }

    .footer-brand p {
        max-width: 400px;
    }

    .footer-social {
        justify-content: center;
    }

    .footer-bottom {
        flex-direction: column;
        gap: var(--spacing-sm);
        text-align: center;
    }

    /* Stats */
    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .stat-item h3 {
        font-size: 2.5rem;
    }

    /* Portfolio */
    .portfolio-grid {
        grid-template-columns: 1fr;
    }

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

    /* Sections */
    .section {
        padding: var(--spacing-3xl) 0;
    }

    .section-header {
        margin-bottom: var(--spacing-2xl);
    }

    .page-hero {
        padding: 160px 0 80px;
    }

    /* Cards */
    .services-grid {
        grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    }
}

/* Mobile - 480px */
@media (max-width: 480px) {
    :root {
        --container-padding: 1rem;
        --spacing-4xl: 4rem;
        --spacing-3xl: 3rem;
        --spacing-2xl: 2.5rem;
    }

    .header .container {
        height: 70px;
    }

    .logo-text {
        font-size: 1.25rem;
    }

    /* Typography */
    h1 {
        font-size: 2rem;
    }

    h2 {
        font-size: 1.75rem;
    }

    h3 {
        font-size: 1.25rem;
    }

    /* Hero */
    .hero {
        padding: 120px 0 80px;
    }

    .hero h1 {
        font-size: 2rem;
        line-height: 1.15;
    }

    .hero p {
        font-size: 1rem;
    }

    .hero-badge {
        font-size: 0.8125rem;
        padding: 0.375rem 0.875rem;
    }

    /* Cards */
    .card {
        padding: var(--spacing-lg);
    }

    .card-icon {
        width: 48px;
        height: 48px;
    }

    .card-icon svg {
        width: 20px;
        height: 20px;
    }

    .services-grid {
        grid-template-columns: 1fr;
        gap: var(--spacing-md);
    }

    /* Stats */
    .stats-grid {
        grid-template-columns: 1fr;
        gap: var(--spacing-md);
    }

    .stat-item {
        padding: var(--spacing-md);
    }

    .stat-item h3 {
        font-size: 2.25rem;
    }

    /* Team */
    .team-grid {
        grid-template-columns: 1fr;
    }

    .team-card {
        padding: var(--spacing-lg);
    }

    .team-card-image {
        width: 120px;
        height: 120px;
    }

    /* Portfolio filters */
    .portfolio-filters {
        gap: var(--spacing-xs);
    }

    .filter-btn {
        padding: 0.5rem 1rem;
        font-size: 0.8125rem;
    }

    /* Contact */
    .contact-form {
        padding: var(--spacing-lg);
    }

    .contact-item {
        padding: var(--spacing-sm);
    }

    .contact-item-icon {
        width: 40px;
        height: 40px;
    }

    /* Buttons */
    .btn {
        width: 100%;
        justify-content: center;
        padding: 0.875rem 1.5rem;
    }

    .btn--large {
        padding: 1rem 1.75rem;
        font-size: 0.9375rem;
    }

    /* CTA */
    .cta-section {
        padding: var(--spacing-3xl) 0;
    }

    .cta-section h2 {
        font-size: 1.75rem;
    }

    /* Values */
    .values-grid {
        grid-template-columns: 1fr;
    }

    .value-card {
        padding: var(--spacing-lg);
    }

    .value-icon {
        width: 64px;
        height: 64px;
        font-size: 1.5rem;
    }

    /* Page Hero */
    .page-hero {
        padding: 140px 0 60px;
    }

    .page-hero p {
        font-size: 1rem;
    }
}

/* Small Mobile - 360px */
@media (max-width: 360px) {
    :root {
        --container-padding: 0.875rem;
    }

    h1 {
        font-size: 1.75rem;
    }

    .hero h1 {
        font-size: 1.75rem;
    }

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

    .nav-link {
        font-size: 1.25rem;
    }
}

/* Hover states - disable on touch devices */
@media (hover: none) {
    .card:hover {
        transform: none;
        box-shadow: none;
    }

    .portfolio-card:hover {
        transform: none;
        box-shadow: none;
    }

    .portfolio-card:hover .portfolio-card-image img {
        transform: none;
    }

    .stat-item:hover {
        transform: none;
    }

    .team-card:hover {
        transform: none;
    }

    .btn:hover {
        transform: none;
    }

    .nav-link::after {
        display: none;
    }
}

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

    html {
        scroll-behavior: auto;
    }

    .reveal {
        opacity: 1;
        transform: none;
    }

    .hero::before,
    .hero::after {
        animation: none;
    }

    .hero-badge::before {
        animation: none;
    }
}

/* High contrast mode */
@media (prefers-contrast: high) {
    :root {
        --color-border: rgba(255, 255, 255, 0.2);
        --color-border-hover: rgba(255, 255, 255, 0.4);
        --color-text-secondary: #b0b8c4;
        --color-text-tertiary: #8892a0;
    }

    .card,
    .stat-item,
    .team-card,
    .portfolio-card,
    .contact-form,
    .contact-item {
        border-width: 2px;
    }
}

/* Print styles */
@media print {
    .header,
    .footer,
    .nav-toggle,
    .btn,
    .cta-section,
    .hero::before,
    .hero::after {
        display: none !important;
    }

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

    .hero {
        background: none;
        color: #000;
        min-height: auto;
        padding: 2rem 0;
    }

    .hero h1,
    .hero p,
    .hero-highlight {
        color: #000;
        -webkit-text-fill-color: #000;
        background: none;
    }

    h1, h2, h3, h4, h5, h6 {
        color: #000;
        -webkit-text-fill-color: #000;
        background: none;
    }

    .text-gradient,
    .logo-text {
        color: #000;
        -webkit-text-fill-color: #000;
        background: none;
    }

    .stat-item h3 {
        color: #000;
        -webkit-text-fill-color: #000;
        background: none;
    }

    p {
        color: #333;
    }

    a {
        color: #000;
        text-decoration: underline;
    }

    .card,
    .stat-item,
    .team-card,
    .portfolio-card {
        border: 1px solid #ccc;
        background: #fff;
        box-shadow: none;
    }

    .section {
        padding: 1.5rem 0;
        background: none;
    }

    .section::before {
        display: none;
    }
}
