/* ============================================
   Responsive Design - Mobile First
   ============================================ */

/* ============================================
   Mobile Devices (320px - 767px)
   ============================================ */
@media screen and (max-width: 767px) {
    :root {
        --font-size-5xl: 2rem;
        --font-size-4xl: 1.75rem;
        --font-size-3xl: 1.5rem;
        --font-size-2xl: 1.25rem;
        --spacing-3xl: 3rem;
        --spacing-2xl: 2.5rem;
        --spacing-xl: 1.5rem;
    }

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

    /* Navigation */
    .menu-toggle {
        display: flex;
    }

    .nav-menu {
        position: fixed;
        top: 70px;
        left: 0;
        right: 0;
        background-color: var(--bg-primary);
        flex-direction: column;
        padding: var(--spacing-lg);
        box-shadow: var(--shadow-lg);
        transform: translateX(-100%);
        transition: transform var(--transition-base);
        z-index: 999;
    }

    .nav-menu.active {
        transform: translateX(0);
    }

    .nav-menu li {
        width: 100%;
    }

    .nav-link {
        display: block;
        padding: var(--spacing-sm);
        border-bottom: 1px solid var(--border-color);
    }

    /* Hero Section */
    .hero {
        min-height: 90vh;
        padding: calc(var(--spacing-2xl) + 60px) 0 var(--spacing-2xl);
    }

    .hero-title {
        font-size: var(--font-size-3xl);
        line-height: 1.3;
    }

    .hero-subtitle {
        font-size: var(--font-size-base);
    }

    .hero-cta {
        flex-direction: column;
        width: 100%;
    }

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

    /* Sections */
    section {
        padding: var(--spacing-2xl) 0;
    }

    .section-title {
        font-size: var(--font-size-3xl);
    }

    .section-subtitle {
        font-size: var(--font-size-base);
    }

    /* Servicios */
    .servicios-grid {
        grid-template-columns: 1fr;
        gap: var(--spacing-lg);
    }

    .servicio-card {
        padding: var(--spacing-lg);
    }

    /* Sobre Mí */
    .sobre-mi-content {
        grid-template-columns: 1fr;
        gap: var(--spacing-xl);
    }

    .sobre-mi-values {
        grid-template-columns: 1fr;
        gap: var(--spacing-md);
    }

    .visual-card {
        padding: var(--spacing-xl);
    }

    .visual-card i {
        font-size: 3rem;
    }

    .stats {
        flex-direction: column;
        gap: var(--spacing-md);
    }

    /* Contacto */
    .contacto-content {
        max-width: 100%;
    }

    .contacto-items {
        grid-template-columns: 1fr;
        gap: var(--spacing-md);
    }
    
    .contacto-item {
        padding: var(--spacing-md);
    }

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

    .footer-section {
        text-align: center;
    }

    .footer-section ul {
        align-items: center;
    }
}

/* ============================================
   Tablet Devices (768px - 1023px)
   ============================================ */
@media screen and (min-width: 768px) and (max-width: 1023px) {
    .container {
        padding: 0 var(--spacing-md);
    }

    /* Navigation */
    .nav-menu {
        gap: var(--spacing-md);
    }

    /* Hero */
    .hero-title {
        font-size: var(--font-size-4xl);
    }

    .hero-subtitle {
        font-size: var(--font-size-lg);
    }

    /* Servicios */
    .servicios-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    /* Sobre Mí */
    .sobre-mi-content {
        gap: var(--spacing-2xl);
    }

    .sobre-mi-values {
        grid-template-columns: repeat(3, 1fr);
    }

    /* Contacto */
    .contacto-content {
        gap: var(--spacing-2xl);
    }
}

/* ============================================
   Desktop Small (1024px - 1439px)
   ============================================ */
@media screen and (min-width: 1024px) and (max-width: 1439px) {
    .container {
        max-width: 1100px;
    }

    .servicios-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

/* ============================================
   Desktop Large (1440px+)
   ============================================ */
@media screen and (min-width: 1440px) {
    .container {
        max-width: 1400px;
    }

    .hero-title {
        font-size: 3.5rem;
    }

    .section-title {
        font-size: 3rem;
    }
}

/* ============================================
   Landscape Mobile Devices
   ============================================ */
@media screen and (max-width: 767px) and (orientation: landscape) {
    .hero {
        min-height: auto;
        padding: calc(var(--spacing-2xl) + 60px) 0 var(--spacing-2xl);
    }

    .hero-title {
        font-size: var(--font-size-2xl);
    }

    .hero-subtitle {
        font-size: var(--font-size-sm);
    }
}

/* ============================================
   Print Styles
   ============================================ */
@media print {
    .header,
    .menu-toggle,
    .scroll-indicator,
    .hero-cta,
    .contacto-form,
    .footer {
        display: none;
    }

    .hero {
        min-height: auto;
        padding: var(--spacing-lg) 0;
    }

    section {
        page-break-inside: avoid;
        padding: var(--spacing-md) 0;
    }

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

/* ============================================
   High DPI Displays
   ============================================ */
@media screen and (-webkit-min-device-pixel-ratio: 2),
       screen and (min-resolution: 192dpi) {
    .hero-background::before {
        background-size: 50% 50%;
    }
}

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

    html {
        scroll-behavior: auto;
    }

    .scroll-indicator {
        animation: none;
    }
}

/* ============================================
   Dark Mode Support (Optional)
   ============================================ */
@media (prefers-color-scheme: dark) {
    /* This can be enabled if dark mode is desired */
    /* Currently keeping light mode as default */
}

