/* UAE eVisa Website - Responsive Styles */

/* ===== MOBILE FIRST APPROACH ===== */

/* Extra Large Devices (1400px and up) */
@media (min-width: 1400px) {
    .container-fluid {
        padding-left: 2rem;
        padding-right: 2rem;
    }
    
    .hero-title {
        font-size: 4rem;
    }
    
    .section-title h2 {
        font-size: 3rem;
    }
    
    .features-grid {
        grid-template-columns: repeat(4, 1fr);
    }
    
    .stats-grid {
        grid-template-columns: repeat(4, 1fr);
    }
}

/* Large Devices (1200px and up) */
@media (min-width: 1200px) {
    .hero-section {
        padding: 8rem 0;
    }
    
    .features-grid {
        grid-template-columns: repeat(3, 1fr);
    }
    
    .stats-grid {
        grid-template-columns: repeat(4, 1fr);
    }
    
    .footer-main {
        padding: 5rem 0 3rem;
    }
}

/* Medium Devices (992px and up) */
@media (min-width: 992px) {
    .navbar-nav .nav-link {
        padding: 0.5rem 0.75rem !important;
    }
    
    .hero-cta {
        flex-direction: row;
    }
    
    .features-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .stats-grid {
        grid-template-columns: repeat(4, 1fr);
    }
    
    .trust-badges {
        justify-content: flex-start;
    }
    
    .footer-bottom-links {
        justify-content: flex-end;
    }
}

/* Small Devices (768px and up) */
@media (min-width: 768px) {
    .top-bar {
        display: block;
    }
    
    .hero-title {
        font-size: 3rem;
    }
    
    .hero-subtitle {
        font-size: 1.2rem;
    }
    
    .section-title h2 {
        font-size: 2.5rem;
    }
    
    .features-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .chat-window {
        width: 350px;
    }
}

/* ===== MOBILE DEVICES (767px and below) ===== */
@media (max-width: 767.98px) {
    /* Reduce overall spacing for mobile */
    :root {
        --section-padding: 2rem 0;
        --container-padding: 0.75rem;
    }
    
    /* Typography adjustments */
    h1 { font-size: 1.75rem; }
    h2 { font-size: 1.5rem; }
    h3 { font-size: 1.3rem; }
    h4 { font-size: 1.2rem; }
    h5 { font-size: 1.1rem; }
    h6 { font-size: 1rem; }
    
    /* Hide top bar on mobile */
    .top-bar {
        display: none;
    }
    
    /* Mobile header adjustments */
    .navbar {
        padding: 0.75rem 0;
    }
    
    .navbar-brand {
        font-size: 1.1rem;
    }
    
    .logo-img {
        height: 32px;
    }
    
    .logo-text strong {
        font-size: 1.2rem;
    }
    
    .logo-text small {
        font-size: 0.7rem;
    }
    
    /* Mobile navigation */
    .navbar-collapse {
        margin-top: 1rem;
        padding-top: 1rem;
        border-top: 1px solid var(--gray-200);
    }
    
    .navbar-nav {
        margin-bottom: 1rem;
    }
    
    .navbar-nav .nav-link {
        padding: 0.75rem 0 !important;
        margin: 0;
        border-bottom: 1px solid var(--gray-100);
    }
    
    .dropdown-menu {
        position: static !important;
        transform: none !important;
        box-shadow: none;
        border: none;
        background: var(--gray-50);
        margin: 0;
        padding: 0;
    }
    
    .dropdown-item {
        padding: 0.5rem 1rem;
        font-size: 0.9rem;
    }
    
    .navbar-cta {
        flex-direction: column;
        gap: 0.75rem;
        width: 100%;
    }
    
    .navbar-cta .btn {
        width: 100%;
        justify-content: center;
    }
    
    /* Mobile breadcrumb */
    .breadcrumb-nav {
        padding: 0.5rem 0;
    }
    
    .breadcrumb {
        font-size: 0.85rem;
        flex-wrap: wrap;
    }
    
    /* Mobile hero section */
    .hero-section {
        padding: 3rem 0;
        background-attachment: scroll;
    }
    
    .hero-title {
        font-size: 2rem;
        margin-bottom: 1rem;
    }
    
    .hero-subtitle {
        font-size: 1rem;
        margin-bottom: 1.5rem;
    }
    
    .hero-cta {
        flex-direction: column;
        gap: 0.75rem;
    }
    
    .hero-cta .btn {
        width: 100%;
        max-width: 280px;
    }
    
    /* Mobile sections */
    .section {
        padding: 2rem 0;
    }
    
    .section-title {
        margin-bottom: 2rem;
        text-align: center;
    }
    
    .section-title h2 {
        font-size: 1.75rem;
        margin-bottom: 0.75rem;
    }
    
    .section-subtitle {
        font-size: 1rem;
    }
    
    /* Mobile cards */
    .card {
        margin-bottom: 1.5rem;
    }
    
    .card-body {
        padding: 1.5rem;
    }
    
    .card-header {
        padding: 1rem;
    }
    
    /* Mobile features */
    .features-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
        margin-top: 2rem;
    }
    
    .feature-card {
        padding: 1.5rem;
    }
    
    .feature-icon {
        width: 60px;
        height: 60px;
        font-size: 1.5rem;
        margin-bottom: 1rem;
    }
    
    .feature-title {
        font-size: 1.1rem;
    }
    
    /* Mobile stats */
    .stats-section {
        padding: 2rem 0;
    }
    
    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 1rem;
    }
    
    .stat-number {
        font-size: 2rem;
    }
    
    .stat-label {
        font-size: 0.9rem;
    }
    
    /* Mobile buttons */
    .btn {
        padding: 0.75rem 1.25rem;
        font-size: 0.9rem;
    }
    
    .btn-lg {
        padding: 1rem 1.5rem;
        font-size: 1rem;
    }
    
    .btn-sm {
        padding: 0.5rem 0.75rem;
        font-size: 0.8rem;
    }
    
    /* Mobile footer */
    .footer-main {
        padding: 2rem 0 1rem;
    }
    
    .footer-widget {
        margin-bottom: 2rem;
        text-align: center;
    }
    
    .footer-stats {
        justify-content: center;
        gap: 1rem;
    }
    
    .footer-links {
        text-align: center;
    }
    
    .contact-info {
        text-align: left;
    }
    
    .trust-badges {
        justify-content: center;
        gap: 1rem;
    }
    
    .trust-item {
        font-size: 0.85rem;
    }
    
    .payment-methods {
        justify-content: center;
        flex-direction: column;
        gap: 0.5rem;
        text-align: center;
    }
    
    .footer-bottom-links {
        justify-content: center;
        gap: 1rem;
        margin-top: 1rem;
    }
    
    .copyright {
        text-align: center;
    }
    
    /* Mobile utilities */
    .back-to-top {
        bottom: 1rem;
        right: 1rem;
        width: 45px;
        height: 45px;
        font-size: 1rem;
    }
    
    .live-chat-widget {
        bottom: 1rem;
        left: 1rem;
    }
    
    .chat-toggle {
        width: 50px;
        height: 50px;
        font-size: 1.2rem;
    }
    
    .chat-window {
        width: calc(100vw - 2rem);
        max-width: 320px;
        bottom: 70px;
    }
    
    .chat-body {
        height: 250px;
    }
    
    /* Mobile spacing utilities */
    .mb-mobile-2 { margin-bottom: 1rem !important; }
    .mb-mobile-3 { margin-bottom: 1.5rem !important; }
    .mb-mobile-4 { margin-bottom: 2rem !important; }
    
    .pb-mobile-2 { padding-bottom: 1rem !important; }
    .pb-mobile-3 { padding-bottom: 1.5rem !important; }
    .pb-mobile-4 { padding-bottom: 2rem !important; }
    
    .px-mobile-1 { padding-left: 0.5rem !important; padding-right: 0.5rem !important; }
    .px-mobile-2 { padding-left: 1rem !important; padding-right: 1rem !important; }
    
    /* Mobile text utilities */
    .text-center-mobile { text-align: center !important; }
    .text-left-mobile { text-align: left !important; }
    
    /* Mobile display utilities */
    .d-none-mobile { display: none !important; }
    .d-block-mobile { display: block !important; }
    .d-flex-mobile { display: flex !important; }
    
    .flex-column-mobile { flex-direction: column !important; }
    .flex-wrap-mobile { flex-wrap: wrap !important; }
    
    .justify-content-center-mobile { justify-content: center !important; }
    .align-items-center-mobile { align-items: center !important; }
    
    /* Mobile grid utilities */
    .col-mobile-12 { flex: 0 0 100% !important; max-width: 100% !important; }
    .col-mobile-6 { flex: 0 0 50% !important; max-width: 50% !important; }
    
    /* Mobile form adjustments */
    .form-control {
        font-size: 16px; /* Prevents zoom on iOS */
        padding: 0.75rem;
    }
    
    .form-select {
        font-size: 16px;
        padding: 0.75rem;
    }
    
    .input-group .btn {
        padding: 0.75rem 1rem;
    }
}

/* ===== EXTRA SMALL DEVICES (575px and below) ===== */
@media (max-width: 575.98px) {
    :root {
        --container-padding: 0.5rem;
    }
    
    .hero-title {
        font-size: 1.75rem;
    }
    
    .hero-subtitle {
        font-size: 0.95rem;
    }
    
    .section-title h2 {
        font-size: 1.5rem;
    }
    
    .stats-grid {
        grid-template-columns: 1fr;
        gap: 1rem;
    }
    
    .feature-card {
        padding: 1rem;
    }
    
    .card-body {
        padding: 1rem;
    }
    
    .trust-badges {
        flex-direction: column;
        align-items: center;
        gap: 0.75rem;
    }
    
    .social-links {
        justify-content: center;
    }
    
    .footer-bottom-links {
        flex-direction: column;
        gap: 0.5rem;
    }
    
    .chat-window {
        width: calc(100vw - 1rem);
        left: -0.5rem;
    }
}

/* ===== LANDSCAPE MOBILE DEVICES ===== */
@media (max-height: 500px) and (orientation: landscape) {
    .hero-section {
        padding: 2rem 0;
        background-attachment: scroll;
    }
    
    .hero-title {
        font-size: 1.75rem;
        margin-bottom: 0.75rem;
    }
    
    .hero-subtitle {
        font-size: 0.95rem;
        margin-bottom: 1rem;
    }
    
    .section {
        padding: 1.5rem 0;
    }
    
    .navbar {
        padding: 0.5rem 0;
    }
    
    .back-to-top {
        bottom: 0.5rem;
        right: 0.5rem;
        width: 40px;
        height: 40px;
    }
    
    .live-chat-widget {
        bottom: 0.5rem;
        left: 0.5rem;
    }
    
    .chat-toggle {
        width: 45px;
        height: 45px;
    }
}

/* ===== PRINT STYLES ===== */
@media print {
    .top-bar,
    .navbar,
    .breadcrumb-nav,
    .back-to-top,
    .live-chat-widget,
    .main-footer {
        display: none !important;
    }
    
    .main-content {
        margin: 0 !important;
        padding: 0 !important;
    }
    
    .hero-section {
        background: none !important;
        color: var(--dark-color) !important;
        padding: 1rem 0 !important;
    }
    
    .card {
        box-shadow: none !important;
        border: 1px solid var(--gray-300) !important;
    }
    
    .btn {
        border: 1px solid var(--gray-400) !important;
        background: none !important;
        color: var(--dark-color) !important;
    }
    
    a {
        color: var(--dark-color) !important;
        text-decoration: underline !important;
    }
    
    .text-white {
        color: var(--dark-color) !important;
    }
}

/* ===== ACCESSIBILITY IMPROVEMENTS ===== */
@media (prefers-reduced-motion: reduce) {
    * {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
    
    .hero-section {
        background-attachment: scroll !important;
    }
}

/* High contrast mode */
@media (prefers-contrast: high) {
    .card {
        border: 2px solid var(--dark-color) !important;
    }
    
    .btn {
        border: 2px solid currentColor !important;
    }
    
    .dropdown-menu {
        border: 2px solid var(--dark-color) !important;
    }
}

/* Dark mode support */
@media (prefers-color-scheme: dark) {
    /* This can be expanded if dark mode is needed */
    .form-control {
        background-color: var(--gray-800);
        border-color: var(--gray-600);
        color: var(--uae-white);
    }
    
    .form-control:focus {
        background-color: var(--gray-700);
        border-color: var(--primary-color);
        color: var(--uae-white);
    }
}

