/* Responsive Styles for AquaPro Academy */

/* Large Tablets and Small Desktops */
@media (max-width: 1024px) {
    .container {
        max-width: 960px;
    }
    
    .hero-title {
        font-size: 3rem;
    }
    
    .planes-grid {
        grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    }
    
    .dashboard-wrapper {
        gap: 20px;
    }
    
    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* Tablets */
@media (max-width: 768px) {
    /* Navigation */
    .nav-menu {
        display: none;
        position: fixed;
        top: 70px;
        left: 0;
        right: 0;
        background: white;
        flex-direction: column;
        padding: 20px;
        box-shadow: 0 5px 20px rgba(0,0,0,0.1);
        z-index: 999;
    }
    
    .nav-menu.active {
        display: flex;
    }
    
    .menu-toggle {
        display: flex;
        flex-direction: column;
        background: transparent;
        border: none;
        cursor: pointer;
        padding: 5px;
    }
    
    .menu-toggle span {
        width: 25px;
        height: 3px;
        background: var(--text-color);
        margin: 3px 0;
        transition: 0.3s;
    }
    
    /* Hero Section */
    .hero {
        height: auto;
        min-height: 100vh;
        padding: 100px 20px 50px;
    }
    
    .hero-title {
        font-size: 2rem;
    }
    
    .hero-subtitle {
        font-size: 1.1rem;
    }
    
    .hero-buttons {
        flex-direction: column;
        width: 100%;
    }
    
    .hero-buttons .btn {
        width: 100%;
    }
    
    .hero-stats {
        flex-direction: column;
        gap: 20px;
    }
    
        /* Plans */
    .planes-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    
    .plan-card.featured {
        transform: none;
    }
    
    /* Dashboard */
    .dashboard-wrapper {
        grid-template-columns: 1fr;
    }
    
    .dashboard-sidebar {
        display: none;
    }
    
    /* Mobile Dashboard Menu */
    .mobile-menu-toggle {
        display: block;
        position: fixed;
        bottom: 20px;
        right: 20px;
        width: 60px;
        height: 60px;
        background: var(--primary-color);
        color: white;
        border-radius: 50%;
        border: none;
        box-shadow: 0 5px 20px rgba(0,0,0,0.2);
        z-index: 100;
        cursor: pointer;
    }
    
    /* Checkout */
    .checkout-content {
        grid-template-columns: 1fr;
    }
    
    .checkout-summary {
        position: static;
    }
    
    .form-row {
        grid-template-columns: 1fr;
    }
    
    .user-type-selector {
        grid-template-columns: 1fr;
    }
    
    /* Login */
    .login-container {
        grid-template-columns: 1fr;
        max-width: 450px;
    }
    
    .login-image-section {
        display: none;
    }
    
    .login-form-section {
        padding: 40px 30px;
    }
    
    .social-login {
        grid-template-columns: 1fr;
    }
    
    /* Services */
    .services-grid {
        grid-template-columns: 1fr;
    }
    
    /* Footer */
    .footer-content {
        grid-template-columns: 1fr;
        text-align: center;
    }
    
    .footer-section {
        margin-bottom: 30px;
    }
    
    /* Stats */
    .stats-grid {
        grid-template-columns: 1fr;
    }
    
    /* Tables */
    table {
        font-size: 0.9rem;
    }
    
    /* Modals */
    .modal-content {
        width: 95%;
        padding: 30px 20px;
    }
}

/* Mobile Phones */
@media (max-width: 480px) {
    /* Typography */
    .section-title {
        font-size: 1.8rem;
    }
    
    .hero-title {
        font-size: 1.5rem;
    }
    
    .hero-subtitle {
        font-size: 1rem;
    }
    
    /* Spacing */
    .section {
        padding: 50px 0;
    }
    
    /* Cards */
    .plan-card {
        padding: 30px 20px;
    }
    
    .success-card,
    .failure-card,
    .pending-card {
        padding: 30px 20px;
    }
    
    /* Buttons */
    .btn {
        padding: 12px 25px;
        font-size: 1rem;
    }
    
    .action-buttons {
        flex-direction: column;
        width: 100%;
    }
    
    .action-buttons a,
    .action-buttons button {
        width: 100%;
    }
    
    /* Forms */
    .form-group input,
    .form-group select {
        font-size: 16px; /* Prevent zoom on iOS */
    }
    
    /* Price Display */
    .plan-price .amount {
        font-size: 2rem;
    }
    
    /* Navigation */
    .logo {
        font-size: 1.2rem;
    }
    
    .nav-actions {
        gap: 10px;
    }
    
    .btn-login,
    .btn-register {
        padding: 8px 15px;
        font-size: 0.9rem;
    }
    
    /* Dashboard */
    .content-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 15px;
    }
    
    /* Tabs */
    .tabs {
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
    }
    
    .tab {
        white-space: nowrap;
        padding: 12px 20px;
    }
    
    /* Legal Pages */
    .legal-content {
        padding: 25px 20px;
    }
    
    .legal-title {
        font-size: 1.8rem;
    }
    
    /* Tables - Make scrollable */
    .table-wrapper {
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
    }
    
    table {
        min-width: 500px;
    }
    
    /* Cookie Banner */
    .cookie-content {
        flex-direction: column;
        text-align: center;
    }
    
    .cookie-accept {
        width: 100%;
    }
    
    /* Payment Methods */
    .payment-methods {
        flex-direction: column;
    }
    
    .payment-methods img {
        height: 25px;
    }
    
    /* Help Links */
    .help-links {
        flex-direction: column;
        gap: 10px;
    }
    
    /* Activity List */
    .activity-item {
        flex-direction: column;
        text-align: center;
        gap: 15px;
    }
    
    /* Subscription Details */
    .subscription-details {
        grid-template-columns: 1fr;
    }
}

/* Small Mobile Phones */
@media (max-width: 360px) {
    .hero-title {
        font-size: 1.3rem;
    }
    
    .section-title {
        font-size: 1.5rem;
    }
    
    .plan-price .amount {
        font-size: 1.8rem;
    }
    
    .btn {
        padding: 10px 20px;
        font-size: 0.95rem;
    }
}

/* Landscape Orientation */
@media (orientation: landscape) and (max-height: 600px) {
    .hero {
        min-height: auto;
        padding: 80px 20px 40px;
    }
    
    .hero-title {
        font-size: 1.8rem;
    }
    
    .hero-stats {
        display: none;
    }
}

/* Print Styles */
@media print {
    /* Hide navigation and non-essential elements */
    .header,
    .footer,
    .cookie-banner,
    .btn,
    .action-buttons,
    .social-links,
    .menu-toggle {
        display: none !important;
    }
    
    /* Adjust colors for print */
    body {
        color: #000;
        background: white;
    }
    
    .section {
        page-break-inside: avoid;
    }
    
    /* Show URLs for links */
    a[href]:after {
        content: " (" attr(href) ")";
    }
    
    /* Ensure tables fit on page */
    table {
        font-size: 0.8rem;
    }
}

/* Accessibility - Reduced Motion */
@media (prefers-reduced-motion: reduce) {
    * {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
        scroll-behavior: auto !important;
    }
}

/* Dark Mode Support */
@media (prefers-color-scheme: dark) {
    :root {
        --primary-color: #4db8ff;
        --secondary-color: #0099e6;
        --dark-color: #f0f0f0;
        --text-color: #e0e0e0;
        --gray-light: #2a2a2a;
    }
    
    body {
        background: #1a1a1a;
        color: #e0e0e0;
    }
    
    .header {
        background: #2a2a2a;
    }
    
    .plan-card,
    .dashboard-content,
    .dashboard-sidebar,
    .modal-content {
        background: #2a2a2a;
        color: #e0e0e0;
    }
    
    input,
    select,
    textarea {
        background: #1a1a1a;
        color: #e0e0e0;
        border-color: #444;
    }
}

/* High Contrast Mode */
@media (prefers-contrast: high) {
    * {
        border-width: 2px !important;
    }
    
    .btn {
        border: 2px solid currentColor !important;
    }
    
    a {
        text-decoration: underline !important;
    }
}

/* Touch Device Optimizations */
@media (hover: none) and (pointer: coarse) {
    /* Increase touch targets */
    .btn,
    button,
    a,
    input,
    select {
        min-height: 44px;
        min-width: 44px;
    }
    
    /* Remove hover effects */
    .plan-card:hover,
    .service-card:hover {
        transform: none;
    }
    
    /* Add active states */
    .btn:active,
    button:active {
        transform: scale(0.95);
    }
}

/* Retina Display Optimizations */
@media (-webkit-min-device-pixel-ratio: 2),
       (min-resolution: 192dpi) {
    /* Use higher resolution images if available */
    .logo {
        image-rendering: -webkit-optimize-contrast;
    }
}
