/* ========================================
   PRECISION MED LNC - Responsive Styles
   Mobile-First Responsive Design
   ======================================== */

/* ========================================
   TABLET - max-width: 1024px
   ======================================== */
@media (max-width: 1024px) {
    .container {
        padding: 0 var(--spacing-md);
    }

    .hero h1 {
        font-size: 2.5rem;
    }

    .hero-subtitle {
        font-size: 1.1rem;
    }

    .services-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .contact-container {
        grid-template-columns: 1fr;
        gap: var(--spacing-md);
    }
}

/* ========================================
   MOBILE - max-width: 768px
   ======================================== */
@media (max-width: 768px) {
    /* Typography Adjustments */
    html {
        font-size: 15px;
    }

    h1 { font-size: 2rem; }
    h2 { font-size: 1.75rem; }
    h3 { font-size: 1.5rem; }
    h4 { font-size: 1.25rem; }

    /* Spacing Adjustments */
    .section {
        padding: var(--spacing-md) 0;
    }

    .container {
        padding: 0 var(--spacing-sm);
    }

    /* Navigation Mobile */
    .nav-container {
        padding: 1rem var(--spacing-sm);
    }

    .nav-menu {
        position: fixed;
        left: -100%;
        top: 70px;
        flex-direction: column;
        background-color: var(--white);
        width: 100%;
        text-align: center;
        transition: left var(--transition-normal);
        box-shadow: var(--shadow-lg);
        padding: var(--spacing-md) 0;
        gap: 0;
    }

    .nav-menu.active {
        left: 0;
    }

    .nav-menu li {
        margin: 0;
        padding: var(--spacing-sm) 0;
        border-bottom: 1px solid var(--light-gray);
    }

    .nav-menu li:last-child {
        border-bottom: none;
    }

    .nav-menu li a {
        display: block;
        padding: var(--spacing-sm);
    }

    .nav-toggle {
        display: flex;
    }

    .nav-toggle.active span:nth-child(1) {
        transform: rotate(45deg) translate(5px, 5px);
    }

    .nav-toggle.active span:nth-child(2) {
        opacity: 0;
    }

    .nav-toggle.active span:nth-child(3) {
        transform: rotate(-45deg) translate(7px, -6px);
    }

    /* Hero Section Mobile */
    .hero {
        padding: 5rem var(--spacing-sm) 3rem;
        margin-top: 70px;
    }

    .hero h1 {
        font-size: 1.75rem;
    }

    .hero-subtitle {
        font-size: 1rem;
    }

    .hero-cta {
        flex-direction: column;
        align-items: stretch;
    }

    .hero-cta .btn {
        width: 100%;
    }

    /* Specialty Banner Mobile */
    .specialty-banner h3 {
        font-size: 1.25rem;
    }

    .specialty-tags {
        gap: 0.5rem;
    }

    .specialty-tag {
        padding: 0.4rem 1rem;
        font-size: 0.9rem;
    }

    /* Services Grid Mobile */
    .services-grid {
        grid-template-columns: 1fr;
        gap: var(--spacing-md);
    }

    .service-card {
        padding: var(--spacing-sm);
    }

    /* Features Grid Mobile */
    .features-grid {
        grid-template-columns: 1fr;
        gap: var(--spacing-md);
    }

    .feature-item {
        padding: var(--spacing-sm);
    }

    /* Process Steps Mobile */
    .process-steps {
        grid-template-columns: 1fr;
        gap: var(--spacing-md);
    }

    .step-number {
        width: 50px;
        height: 50px;
        font-size: 1.25rem;
    }

    /* Testimonials Mobile */
    .testimonial-grid {
        grid-template-columns: 1fr;
        gap: var(--spacing-md);
    }

    .testimonial-card {
        padding: var(--spacing-sm);
    }

    /* Contact Section Mobile */
    .contact-container {
        grid-template-columns: 1fr;
    }

    .contact-form {
        padding: var(--spacing-sm);
    }

    /* Footer Mobile */
    .footer-content {
        grid-template-columns: 1fr;
        gap: var(--spacing-md);
        text-align: center;
    }

    .footer-section ul {
        margin-left: 0;
    }

    /* Buttons Mobile */
    .btn {
        padding: 0.75rem 1.5rem;
        font-size: 0.9rem;
    }

    /* Section Headings Mobile */
    .section-heading h2 {
        font-size: 1.75rem;
    }

    .section-heading p {
        font-size: 1rem;
    }
}

/* ========================================
   SMALL MOBILE - max-width: 480px
   ======================================== */
@media (max-width: 480px) {
    html {
        font-size: 14px;
    }

    .hero h1 {
        font-size: 1.5rem;
    }

    .hero-subtitle {
        font-size: 0.95rem;
    }

    .nav-logo {
        font-size: 1.25rem;
    }

    .service-icon {
        font-size: 2rem;
    }

    .feature-icon {
        font-size: 2.5rem;
    }

    .section-heading h2 {
        font-size: 1.5rem;
    }

    .specialty-banner h3 {
        font-size: 1.1rem;
    }

    .specialty-tags {
        flex-direction: column;
        align-items: center;
    }

    .specialty-tag {
        width: 90%;
    }

    .contact-details li {
        flex-direction: column;
        align-items: center;
        text-align: center;
    }

    .form-group input,
    .form-group textarea,
    .form-group select {
        font-size: 16px; /* Prevents zoom on iOS */
    }
}

/* ========================================
   LANDSCAPE MOBILE - max-height: 500px
   ======================================== */
@media (max-height: 500px) and (orientation: landscape) {
    .hero {
        padding: 3rem var(--spacing-sm) 2rem;
    }

    .hero h1 {
        font-size: 1.5rem;
        margin-bottom: var(--spacing-sm);
    }

    .hero-subtitle {
        font-size: 0.95rem;
        margin-bottom: var(--spacing-md);
    }

    .section {
        padding: var(--spacing-md) 0;
    }
}

/* ========================================
   PRINT STYLES
   ======================================== */
@media print {
    .navbar,
    .nav-toggle,
    .hero-cta,
    .contact-form,
    .footer {
        display: none;
    }

    body {
        font-size: 12pt;
        line-height: 1.5;
        color: #000;
        background: #fff;
    }

    .section {
        page-break-inside: avoid;
    }

    a {
        color: #000;
        text-decoration: underline;
    }

    h1, h2, h3, h4, h5, h6 {
        page-break-after: avoid;
        page-break-inside: avoid;
    }
}

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

/* High Contrast Mode */
@media (prefers-contrast: high) {
    :root {
        --primary-navy: #000066;
        --primary-blue: #0000cc;
        --accent-teal: #006666;
        --dark-gray: #000000;
    }

    .btn {
        border-width: 3px;
    }

    .service-card,
    .testimonial-card,
    .contact-form {
        border: 2px solid var(--dark-gray);
    }
}

/* Dark Mode Support (Future Enhancement) */
@media (prefers-color-scheme: dark) {
    /*
    Uncomment and customize when dark mode is ready:

    :root {
        --white: #1a202c;
        --off-white: #2d3748;
        --dark-gray: #e2e8f0;
        --charcoal: #f7fafc;
    }
    */
}
