/* Responsive CSS Overrides */

/* Mobile-first approach */
@media screen and (max-width: 640px) {
    /* Header adjustments */
    .container {
        padding-left: 1rem !important;
        padding-right: 1rem !important;
    }
    
    /* Form improvements */
    .form-group {
        margin-bottom: 1rem;
    }
    
    /* Button improvements */
    .btn-mobile-full {
        width: 100%;
        display: block;
        margin-bottom: 0.5rem;
    }
    
    /* Table improvements */
    .table-responsive {
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
    }
    
    /* Card improvements */
    .card-mobile {
        margin-bottom: 1rem;
        padding: 1rem;
    }
    
    /* Typography adjustments */
    h1 {
        font-size: 1.5rem !important;
        line-height: 1.4;
    }
    
    h2 {
        font-size: 1.25rem !important;
        line-height: 1.4;
    }
    
    /* Input field improvements */
    input[type="text"],
    input[type="number"],
    input[type="email"],
    input[type="tel"],
    textarea,
    select {
        font-size: 16px; /* Prevents zoom on iOS */
        padding: 0.75rem;
    }
    
    /* Navigation improvements */
    .nav-item {
        padding: 0.5rem 0;
        border-bottom: 1px solid #e5e5e5;
    }
    
    .nav-item:last-child {
        border-bottom: none;
    }
}

/* Tablet adjustments */
@media screen and (min-width: 641px) and (max-width: 1024px) {
    .container {
        padding-left: 2rem;
        padding-right: 2rem;
    }
    
    /* Grid improvements */
    .grid-tablet-2 {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* Desktop improvements */
@media screen and (min-width: 1025px) {
    /* Ensure proper spacing on larger screens */
    .container {
        max-width: 1200px;
        margin: 0 auto;
    }
}

/* Touch improvements */
@media (hover: none) {
    button,
    .btn,
    a.btn {
        min-height: 44px; /* Apple's recommended touch target size */
        min-width: 44px;
    }
}

/* Print improvements */
@media print {
    .no-print {
        display: none !important;
    }
    
    body {
        font-size: 12pt;
        line-height: 1.4;
    }
    
    .container {
        max-width: none;
        padding: 0;
    }
}

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

/* Dark mode support (if needed in future) */
@media (prefers-color-scheme: dark) {
    /* Add dark mode styles if needed */
}

/* High contrast mode support */
@media (prefers-contrast: high) {
    button,
    .btn {
        border: 2px solid;
    }
    
    input,
    textarea,
    select {
        border: 2px solid;
    }
}