/* Responsive Design */

/* Large Screens */
@media (max-width: 1200px) {
    .container {
        max-width: 1000px;
    }
    
    .hero-content h1 {
        font-size: 2.5rem;
    }
    
    .services-grid {
        grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    }
}

/* Medium Screens */
@media (max-width: 992px) {
    .nav-menu {
        position: fixed;
        top: 80px;
        left: -100%;
        width: 100%;
        height: calc(100vh - 80px);
        background-color: var(--white-color);
        flex-direction: column;
        justify-content: flex-start;
        align-items: center;
        padding-top: 2rem;
        transition: left 0.3s ease;
        box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    }
    
    .nav-menu.active {
        left: 0;
    }
    
    .nav-toggle {
        display: flex;
    }
    
    .nav-toggle.active .bar:nth-child(2) {
        opacity: 0;
    }
    
    .nav-toggle.active .bar:nth-child(1) {
        transform: translateY(8px) rotate(45deg);
    }
    
    .nav-toggle.active .bar:nth-child(3) {
        transform: translateY(-8px) rotate(-45deg);
    }
    
    .hero-content {
        grid-template-columns: 1fr;
        text-align: center;
        gap: 2rem;
    }
    
    .hero-content h1 {
        font-size: 2rem;
    }
    
    .hero-buttons {
        justify-content: center;
        flex-wrap: wrap;
    }
    
    .about-content {
        grid-template-columns: 1fr;
        gap: 2rem;
    }
    
    .about-stats {
        grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    }
    
    .contact-content {
        grid-template-columns: 1fr;
        gap: 2rem;
    }
    
    .footer-content {
        grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    }
    
    .services-grid {
        grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    }
    
    .reviews-grid {
        grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    }
    
    .blog-grid {
        grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    }
}

/* Small Screens */
@media (max-width: 768px) {
    .container {
        padding: 0 1rem;
    }
    
    .navbar {
        padding: 0.75rem 0;
    }
    
    .nav-container {
        padding: 0 1rem;
    }
    
    .hero {
        padding: 6rem 0 3rem;
    }
    
    .hero-content h1 {
        font-size: 1.75rem;
    }
    
    .hero-content p {
        font-size: 1rem;
    }
    
    .services,
    .about,
    .reviews,
    .newsletter,
    .contact {
        padding: 3rem 0;
    }
    
    .services-grid,
    .reviews-grid,
    .blog-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }
    
    .service-card,
    .review-card {
        padding: 1.5rem;
    }
    
    .about-stats {
        grid-template-columns: 1fr;
    }
    
    .contact-form {
        padding: 1.5rem;
    }
    
    .newsletter-form {
        flex-direction: column;
        gap: 1rem;
    }
    
    .cookie-buttons {
        flex-direction: column;
        align-items: center;
    }
    
    .cookie-buttons .btn-primary,
    .cookie-buttons .btn-secondary,
    .cookie-buttons .btn-outline {
        width: 100%;
        max-width: 300px;
    }
    
    .modal-content {
        padding: 1.5rem;
        margin: 1rem;
    }
    
    .modal-buttons {
        flex-direction: column;
        gap: 0.5rem;
    }
    
    .blog-header {
        padding: 4rem 0 2rem;
    }
    
    .blog-article {
        padding: 4rem 0 2rem;
    }
    
    .article-meta {
        flex-direction: column;
        gap: 0.5rem;
    }
    
    .article-navigation {
        flex-direction: column;
        gap: 1rem;
        text-align: center;
    }
    
    .thank-you-actions {
        flex-direction: column;
        align-items: center;
    }
    
    .legal-page {
        padding: 4rem 0 2rem;
    }
    
    .footer-content {
        grid-template-columns: 1fr;
        text-align: center;
    }
    
    .social-links {
        justify-content: center;
    }
    
    h1 {
        font-size: 2rem;
    }
    
    h2 {
        font-size: 1.5rem;
    }
    
    h3 {
        font-size: 1.25rem;
    }
    
    .cookie-table {
        font-size: 0.9rem;
    }
    
    .cookie-table th,
    .cookie-table td {
        padding: 0.5rem;
    }
}

/* Extra Small Screens */
@media (max-width: 480px) {
    .hero-content h1 {
        font-size: 1.5rem;
    }
    
    .hero-content p {
        font-size: 0.9rem;
    }
    
    .service-card,
    .review-card {
        padding: 1rem;
    }
    
    .contact-form {
        padding: 1rem;
    }
    
    .modal-content {
        padding: 1rem;
    }
    
    .cookie-content {
        padding: 0 1rem;
    }
    
    .btn-primary,
    .btn-secondary,
    .btn-outline {
        padding: 0.5rem 1rem;
        font-size: 0.9rem;
    }
    
    .article-text .lead {
        font-size: 1.1rem;
    }
    
    .share-buttons {
        justify-content: center;
    }
    
    .thank-you-icon {
        font-size: 3rem;
    }
    
    .thank-you-info {
        padding: 1.5rem;
    }
    
    h1 {
        font-size: 1.75rem;
    }
    
    h2 {
        font-size: 1.25rem;
    }
    
    h3 {
        font-size: 1.1rem;
    }
    
    .cookie-table {
        font-size: 0.8rem;
    }
    
    .cookie-table th,
    .cookie-table td {
        padding: 0.25rem;
    }
}

/* Print Styles */
@media print {
    .header,
    .footer,
    .cookie-banner,
    .cookie-modal,
    .nav-toggle,
    .hero-buttons,
    .newsletter,
    .contact-form,
    .article-navigation,
    .share-buttons,
    .thank-you-actions {
        display: none;
    }
    
    .hero {
        margin-top: 0;
        padding: 2rem 0;
        background: none;
        color: var(--dark-color);
    }
    
    .hero-content h1 {
        color: var(--dark-color);
    }
    
    .hero-content p {
        color: var(--gray-color);
    }
    
    .blog-article,
    .legal-page,
    .thank-you {
        margin-top: 0;
        padding: 1rem 0;
    }
    
    .services,
    .about,
    .reviews,
    .contact {
        padding: 1rem 0;
    }
    
    .service-card,
    .review-card {
        break-inside: avoid;
        box-shadow: none;
        border: 1px solid var(--border-color);
    }
    
    .article-text {
        font-size: 12pt;
        line-height: 1.5;
    }
    
    .article-text h2,
    .article-text h3 {
        page-break-after: avoid;
    }
    
    .article-text p {
        orphans: 3;
        widows: 3;
    }
    
    .cookie-table {
        page-break-inside: avoid;
    }
    
    .thank-you-info {
        break-inside: avoid;
    }
}

/* High DPI Screens */
@media (-webkit-min-device-pixel-ratio: 2), (min-resolution: 192dpi) {
    .service-icon img,
    .nav-logo img,
    .hero-image img,
    .about-image img,
    .blog-image img,
    .article-image img {
        image-rendering: -webkit-optimize-contrast;
        image-rendering: crisp-edges;
    }
}

/* 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;
    }
    
    .hero::before {
        animation: none;
    }
    
    .fade-in,
    .slide-in {
        animation: none;
    }
}

/* Dark Mode Support */
@media (prefers-color-scheme: dark) {
    .cookie-banner,
    .modal-content,
    .contact-form,
    .thank-you-info {
        background-color: var(--dark-color);
        color: var(--white-color);
    }
    
    .cookie-banner {
        border-top-color: var(--gray-color);
    }
    
    .cookie-content p {
        color: rgba(255, 255, 255, 0.8);
    }
    
    .contact-form input,
    .contact-form textarea {
        background-color: var(--gray-color);
        border-color: var(--gray-color);
        color: var(--white-color);
    }
    
    .contact-form input::placeholder,
    .contact-form textarea::placeholder {
        color: rgba(255, 255, 255, 0.6);
    }
}

/* Landscape Orientation */
@media (max-width: 768px) and (orientation: landscape) {
    .hero {
        padding: 4rem 0 2rem;
    }
    
    .hero-content h1 {
        font-size: 1.5rem;
    }
    
    .nav-menu {
        height: calc(100vh - 60px);
    }
    
    .cookie-banner {
        padding: 0.5rem;
    }
    
    .cookie-content p {
        font-size: 0.9rem;
    }
    
    .cookie-buttons {
        flex-direction: row;
        gap: 0.5rem;
    }
    
    .modal-content {
        max-height: 70vh;
    }
}

/* Focus Styles for Accessibility */
@media (any-hover: hover) {
    .nav-link:focus,
    .btn-primary:focus,
    .btn-secondary:focus,
    .btn-outline:focus,
    .contact-form input:focus,
    .contact-form textarea:focus,
    .newsletter-form input:focus {
        outline: 2px solid var(--primary-color);
        outline-offset: 2px;
    }
}

/* Touch Device Optimizations */
@media (any-hover: none) {
    .service-card:hover,
    .review-card:hover,
    .blog-card:hover {
        transform: none;
        box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
    }
    
    .btn-primary:hover,
    .btn-secondary:hover,
    .btn-outline:hover {
        transform: none;
    }
    
    .social-links a:hover,
    .share-btn:hover {
        transform: none;
    }
    
    .blog-read-more:hover {
        color: var(--primary-color);
    }
}
