/**
 * Responsive Styles - Mobile & Tablet
 * Breakpoints: Mobile (<768px), Tablet (768-1199px), Desktop (1200px+)
 */

/* ============================================
   TABLET (768px - 1199px)
   ============================================ */
@media (max-width: 1199px) {
    .container {
        max-width: 960px;
    }
    
    .hero-title {
        font-size: 3rem;
    }
    
    .services-grid {
        grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    }
    
    .about-grid {
        grid-template-columns: 1fr;
        gap: var(--spacing-md);
    }
}

/* ============================================
   MOBILE (< 768px)
   ============================================ */
@media (max-width: 767px) {
    /* Typography */
    h1 { font-size: 2.25rem; }
    h2 { font-size: 2rem; }
    h3 { font-size: 1.5rem; }
    h4 { font-size: 1.25rem; }
    
    p { font-size: 1rem; }
    
    /* Container */
    .container {
        padding: 0 1rem;
    }
    
    .section-padding {
        padding: 3rem 0;
    }
    
    /* Header */
    .nav {
        position: fixed;
        top: 0;
        left: -100%;
        width: 100%;
        height: 100vh;
        background: white;
        flex-direction: column;
        justify-content: center;
        gap: 2rem;
        transition: left 0.3s ease;
        z-index: 999;
    }
    
    .nav.active {
        left: 0;
    }
    
    .mobile-menu-toggle {
        display: flex;
        z-index: 1000;
    }
    
    .mobile-menu-toggle.active span:nth-child(1) {
        transform: rotate(45deg) translateY(8px);
    }
    
    .mobile-menu-toggle.active span:nth-child(2) {
        opacity: 0;
    }
    
    .mobile-menu-toggle.active span:nth-child(3) {
        transform: rotate(-45deg) translateY(-8px);
    }
    
    /* Hero */
    .hero-section {
        min-height: 70vh;
    }
    
    .hero-title {
        font-size: 2rem;
    }
    
    .hero-subtitle {
        font-size: 1rem;
    }
    
    .hero-buttons {
        flex-direction: column;
        width: 100%;
    }
    
    .hero-buttons .btn {
        width: 100%;
    }
    
    /* Stats */
    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 1rem;
    }
    
    .stat-number {
        font-size: 2.5rem;
    }
    
    .stat-label {
        font-size: 0.875rem;
    }
    
    /* About */
    .about-grid {
        grid-template-columns: 1fr;
    }
    
    .about-badge {
        top: 1rem;
        right: 1rem;
        padding: 1rem;
    }
    
    .badge-year {
        font-size: 1.5rem;
    }
    
    /* Services */
    .services-grid {
        grid-template-columns: 1fr;
    }
    
    .service-card {
        padding: var(--spacing-md);
    }
    
    /* Projects */
    .project-filters {
        flex-direction: column;
    }
    
    .filter-btn {
        width: 100%;
    }
    
    .projects-grid {
        grid-template-columns: 1fr;
    }
    
    /* Contact */
    .contact-grid {
        grid-template-columns: 1fr;
    }
    
    .contact-map {
        height: 300px;
    }
    
    /* Footer */
    .footer-grid {
        grid-template-columns: 1fr;
        gap: var(--spacing-md);
    }
    
    /* Floating buttons */
    .whatsapp-float,
    .back-to-top {
        bottom: 1rem;
    }
    
    .whatsapp-float {
        right: 1rem;
    }
    
    .back-to-top {
        left: 1rem;
    }
    
    .whatsapp-float svg {
        width: 50px;
        height: 50px;
    }
    
    .back-to-top {
        width: 45px;
        height: 45px;
    }
}

/* ============================================
   EXTRA SMALL MOBILE (< 480px)
   ============================================ */
@media (max-width: 479px) {
    .hero-title {
        font-size: 1.75rem;
    }
    
    .stats-grid {
        grid-template-columns: 1fr;
    }
    
    .stat-item {
        padding: 1rem;
    }
    
    .btn {
        padding: 0.875rem 1.5rem;
        font-size: 0.9375rem;
    }
}

/* ============================================
   PRINT STYLES
   ============================================ */
@media print {
    .header,
    .whatsapp-float,
    .back-to-top,
    .mobile-menu-toggle {
        display: none !important;
    }
    
    body {
        font-size: 12pt;
        color: black;
    }
    
    a {
        text-decoration: underline;
    }
}

/* ============================================
   LANDSCAPE ORIENTATION (Mobile)
   ============================================ */
@media (max-width: 767px) and (orientation: landscape) {
    .hero-section {
        min-height: auto;
        padding: 4rem 0;
    }
}

/* ============================================
   TOUCH DEVICE OPTIMIZATIONS
   ============================================ */
@media (hover: none) and (pointer: coarse) {
    /* Increase tap targets */
    .btn,
    .nav-link,
    .filter-btn {
        min-height: 44px;
        min-width: 44px;
    }
    
    /* Remove hover effects on touch devices */
    .service-card:hover,
    .project-item:hover {
        transform: none;
    }
    
    .project-overlay {
        opacity: 1;
        background: linear-gradient(to top, rgba(0,0,0,0.8), transparent);
    }
}
