/**
 * Deepswag Dance Studio - Responsive Styles
 * Mobile-first responsive design
 */

/* ==================== LARGE DESKTOP (1400px+) ==================== */
@media (min-width: 1400px) {
    .container {
        max-width: 1320px;
    }
}

/* ==================== DESKTOP (1200px - 1399px) ==================== */
@media (max-width: 1399px) {
    .container {
        max-width: 1140px;
    }
}

/* ==================== LAPTOP (992px - 1199px) ==================== */
@media (max-width: 1199px) {
    .container {
        max-width: 960px;
    }
    
    .hero-title {
        font-size: 4rem;
    }
    
    .grid-4 {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* ==================== TABLET (768px - 991px) ==================== */
@media (max-width: 991px) {
    .container {
        max-width: 720px;
    }
    
    /* Navigation */
    .nav-menu {
        position: fixed;
        top: 80px;
        left: -100%;
        width: 100%;
        height: calc(100vh - 80px);
        background: rgba(10, 10, 10, 0.98);
        backdrop-filter: blur(10px);
        flex-direction: column;
        justify-content: flex-start;
        padding: 50px 20px;
        gap: 30px;
        transition: left 0.3s ease;
        overflow-y: auto;
    }
    
    .nav-menu.active {
        left: 0;
    }
    
    .menu-toggle {
        display: flex;
    }
    
    .menu-toggle.active span:nth-child(1) {
        transform: rotate(45deg) translate(8px, 8px);
    }
    
    .menu-toggle.active span:nth-child(2) {
        opacity: 0;
    }
    
    .menu-toggle.active span:nth-child(3) {
        transform: rotate(-45deg) translate(8px, -8px);
    }
    
    /* Hero */
    .hero-title {
        font-size: 3rem;
    }
    
    .hero-subtitle {
        font-size: 1.5rem;
    }
    
    .hero-buttons {
        flex-direction: column;
        align-items: center;
    }
    
    .hero-buttons .btn {
        width: 100%;
        max-width: 300px;
    }
    
    /* Grids */
    .grid-3,
    .grid-4 {
        grid-template-columns: repeat(2, 1fr);
    }
    
    /* Stats */
    .stat-number {
        font-size: 2.5rem;
    }
    
    /* Section Padding */
    .section {
        padding: 60px 0;
    }
    
    /* Footer */
    .footer-content {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* ==================== MOBILE LANDSCAPE (576px - 767px) ==================== */
@media (max-width: 767px) {
    .container {
        max-width: 540px;
    }
    
    /* Typography */
    h1 {
        font-size: 2.5rem;
    }
    
    h2 {
        font-size: 2rem;
    }
    
    h3 {
        font-size: 1.5rem;
    }
    
    p {
        font-size: 1rem;
    }
    
    /* Hero */
    .hero {
        height: auto;
        min-height: 100vh;
        padding: 100px 0 50px;
    }
    
    .hero-title {
        font-size: 2.5rem;
    }
    
    .hero-subtitle {
        font-size: 1.2rem;
    }
    
    .hero-description {
        font-size: 1rem;
    }
    
    /* Buttons */
    .btn {
        padding: 12px 30px;
        font-size: 0.9rem;
    }
    
    /* Grids */
    .grid-2,
    .grid-3,
    .grid-4 {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    
    /* Class Cards */
    .class-image {
        height: 250px;
    }
    
    /* Stats */
    .stat-card {
        padding: 30px 20px;
    }
    
    .stat-number {
        font-size: 2rem;
    }
    
    .stat-icon {
        font-size: 2.5rem;
    }
    
    /* Testimonials */
    .testimonial-card {
        padding: 30px 20px;
    }
    
    .testimonial-text {
        font-size: 1rem;
    }
    
    .testimonial-author img {
        width: 50px;
        height: 50px;
    }
    
    /* CTA */
    .cta-buttons {
        flex-direction: column;
        align-items: center;
    }
    
    .cta-buttons .btn {
        width: 100%;
        max-width: 300px;
    }
    
    /* Footer */
    .footer-content {
        grid-template-columns: 1fr;
        gap: 30px;
    }
    
    .social-links {
        justify-content: center;
    }
    
    /* Scroll to Top */
    .scroll-top {
        width: 45px;
        height: 45px;
        bottom: 20px;
        right: 20px;
    }
}

/* ==================== MOBILE PORTRAIT (320px - 575px) ==================== */
@media (max-width: 575px) {
    .container {
        padding: 0 15px;
    }
    
    /* Navigation */
    .navbar {
        padding: 15px 0;
    }
    
    .logo {
        font-size: 1.5rem;
    }
    
    .nav-menu {
        top: 70px;
        height: calc(100vh - 70px);
        padding: 30px 15px;
        gap: 20px;
    }
    
    /* Hero */
    .hero-title {
        font-size: 2rem;
        line-height: 1.2;
    }
    
    .hero-subtitle {
        font-size: 1rem;
    }
    
    .hero-description {
        font-size: 0.95rem;
    }
    
    /* Section Title */
    .section-title h2 {
        font-size: 1.8rem;
    }
    
    .section-subtitle {
        font-size: 1rem;
    }
    
    /* Cards */
    .card {
        padding: 20px;
    }
    
    .card-icon {
        font-size: 2.5rem;
    }
    
    .card-title {
        font-size: 1.3rem;
    }
    
    /* Class Cards */
    .class-image {
        height: 200px;
    }
    
    .class-content {
        padding: 20px;
    }
    
    .class-meta {
        flex-direction: column;
        gap: 10px;
    }
    
    /* Stats */
    .stat-card {
        padding: 25px 15px;
    }
    
    .stat-number {
        font-size: 1.8rem;
    }
    
    .stat-icon {
        font-size: 2rem;
    }
    
    .stat-label {
        font-size: 0.9rem;
    }
    
    /* Testimonials */
    .testimonials-slider {
        min-height: 350px;
    }
    
    .testimonial-card {
        padding: 25px 15px;
    }
    
    .testimonial-rating {
        font-size: 1rem;
    }
    
    .testimonial-text {
        font-size: 0.95rem;
    }
    
    .testimonial-author {
        flex-direction: column;
        text-align: center;
        gap: 10px;
    }
    
    .testimonial-controls button {
        width: 40px;
        height: 40px;
        font-size: 1rem;
    }
    
    /* CTA */
    .cta-content h2 {
        font-size: 1.8rem;
    }
    
    .cta-content p {
        font-size: 1rem;
    }
    
    /* Footer */
    .footer {
        padding: 40px 0 15px;
    }
    
    .footer-section h3 {
        font-size: 1.2rem;
    }
    
    .footer-section p,
    .footer-section li {
        font-size: 0.9rem;
    }
    
    .footer-bottom {
        font-size: 0.85rem;
        padding-top: 20px;
    }
    
    /* Notification */
    .notification {
        right: -350px;
        padding: 15px 20px;
        font-size: 0.9rem;
    }
    
    .notification.show {
        right: 15px;
    }
}

/* ==================== EXTRA SMALL MOBILE (< 375px) ==================== */
@media (max-width: 374px) {
    .hero-title {
        font-size: 1.8rem;
    }
    
    .section-title h2 {
        font-size: 1.5rem;
    }
    
    .btn {
        padding: 10px 25px;
        font-size: 0.85rem;
    }
    
    .stat-number {
        font-size: 1.5rem;
    }
    
    .class-image {
        height: 180px;
    }
}

/* ==================== LANDSCAPE ORIENTATION ==================== */
@media (max-height: 500px) and (orientation: landscape) {
    .hero {
        height: auto;
        min-height: 100vh;
    }
    
    .hero-content {
        padding: 50px 20px;
    }
    
    .nav-menu {
        height: calc(100vh - 60px);
        padding: 20px;
    }
}

/* ==================== PRINT STYLES ==================== */
@media print {
    .navbar,
    .menu-toggle,
    .scroll-top,
    .cta-section,
    .footer,
    .testimonial-controls {
        display: none !important;
    }
    
    .hero {
        height: auto;
        page-break-after: always;
    }
    
    .section {
        page-break-inside: avoid;
    }
    
    * {
        background: white !important;
        color: black !important;
        box-shadow: none !important;
        text-shadow: none !important;
    }
}

/* ==================== ACCESSIBILITY ==================== */

/* Focus Styles */
@media (prefers-reduced-motion: no-preference) {
    *:focus {
        outline: 2px solid var(--primary-color);
        outline-offset: 3px;
    }
}

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

/* High Contrast Mode */
@media (prefers-contrast: high) {
    :root {
        --primary-color: #FF0080;
        --secondary-color: #A000FF;
        --text-white: #FFFFFF;
        --bg-dark: #000000;
    }
    
    .card,
    .class-card,
    .testimonial-card {
        border-width: 3px;
    }
}

/* Dark Mode (if system preference) */
@media (prefers-color-scheme: dark) {
    /* Already dark by default */
}

/* ==================== TOUCH DEVICE OPTIMIZATIONS ==================== */
@media (hover: none) and (pointer: coarse) {
    /* Larger touch targets */
    .btn,
    button,
    a {
        min-height: 44px;
        min-width: 44px;
    }
    
    /* Remove hover effects on touch devices */
    .card:hover,
    .class-card:hover,
    .btn:hover {
        transform: none;
    }
    
    /* Tap highlight color */
    * {
        -webkit-tap-highlight-color: rgba(255, 0, 110, 0.3);
    }
}

/* ==================== RETINA DISPLAYS ==================== */
@media (-webkit-min-device-pixel-ratio: 2), (min-resolution: 192dpi) {
    /* High-resolution image handling */
    .hero-bg,
    .class-image img {
        image-rendering: -webkit-optimize-contrast;
    }
}
