/* ========================================
   RESPONSIVE DESIGN
======================================== */

/* Tablet Landscape - 1024px */
@media screen and (max-width: 1024px) {
    .container {
        padding: 0 2rem;
    }
    
    .hero-content {
        gap: 3rem;
    }
    
    .hero-title {
        font-size: clamp(2.5rem, 5vw, 3.5rem);
    }
    
    .skills-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .certifications-grid {
        grid-template-columns: repeat(3, 1fr);
    }
    
    .floating-card {
        padding: 0.75rem 1.25rem;
        font-size: 0.875rem;
    }
    
    .card-1,
    .card-3 {
        left: -5%;
    }
    
    .card-2 {
        right: -5%;
    }
}

/* Tablet Portrait - 768px */
@media screen and (max-width: 768px) {
    section {
        padding: var(--spacing-2xl) 1.5rem;
    }
    
    /* Navigation */
    .nav-menu {
        position: fixed;
        top: 80px;
        left: -100%;
        width: 100%;
        height: calc(100vh - 80px);
        background: var(--bg-primary);
        flex-direction: column;
        padding: 2rem;
        gap: 0.5rem;
        transition: left var(--transition-base);
        box-shadow: var(--shadow-xl);
        overflow-y: auto;
    }
    
    .nav-menu.active {
        left: 0;
    }
    
    .nav-link {
        padding: 1rem 1.5rem;
        width: 100%;
        font-size: 1.125rem;
    }
    
    .nav-link i {
        font-size: 1.25rem;
    }
    
    .hamburger {
        display: flex;
    }
    
    /* Hero Section */
    .hero {
        padding: 6rem 1.5rem 3rem;
        min-height: auto;
    }
    
    .hero-content {
        grid-template-columns: 1fr;
        gap: 3rem;
    }
    
    .hero-text {
        order: 2;
        text-align: center;
    }
    
    .hero-image {
        order: 1;
    }
    
    .greeting {
        justify-content: center;
    }
    
    .hero-description {
        max-width: 100%;
    }
    
    .hero-buttons {
        justify-content: center;
    }
    
    .social-links {
        justify-content: center;
    }
    
    .floating-card {
        display: none;
    }
    
    .scroll-indicator {
        display: none;
    }
    
    /* About Section */
    .about-content {
        grid-template-columns: 1fr;
        gap: 3rem;
    }
    
    .stats-grid {
        grid-template-columns: 1fr;
    }
    
    .info-grid {
        grid-template-columns: 1fr;
    }
    
    /* Skills */
    .skills-grid {
        grid-template-columns: 1fr;
    }
    
    /* Education */
    .education-grid {
        grid-template-columns: 1fr;
    }
    
    /* Certifications */
    .certifications-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    /* Contact */
    .contact-content {
        grid-template-columns: 1fr;
        gap: 3rem;
    }
    
    .contact-form-wrapper {
        padding: 2rem;
    }
    
    /* Footer */
    .footer-content {
        grid-template-columns: 1fr;
        gap: 2rem;
    }
}

/* Mobile Large - 480px */
@media screen and (max-width: 480px) {
    :root {
        font-size: 14px;
    }
    
    section {
        padding: var(--spacing-xl) 1rem;
    }
    
    .section-header {
        margin-bottom: var(--spacing-xl);
    }
    
    .section-title {
        font-size: 2rem;
    }
    
    /* Navigation */
    .nav-container {
        padding: 1rem 1.5rem;
    }
    
    .nav-logo {
        font-size: 1.125rem;
    }
    
    .logo-gradient {
        font-size: 1.25rem;
    }
    
    /* Hero */
    .hero {
        padding: 5rem 1rem 2rem;
    }
    
    .hero-title {
        font-size: 2.5rem;
    }
    
    .hero-subtitle {
        font-size: 1.25rem;
    }
    
    .hero-description {
        font-size: 1rem;
    }
    
    .hero-buttons {
        flex-direction: column;
        width: 100%;
    }
    
    .btn {
        width: 100%;
        justify-content: center;
    }
    
    /* Timeline */
    .timeline {
        padding-left: 1.5rem;
    }
    
    .timeline-item {
        padding-left: 2rem;
    }
    
    .timeline-content {
        padding: 1.5rem;
    }
    
    .timeline-title {
        font-size: 1.375rem;
    }
    
    .timeline-company {
        font-size: 1rem;
    }
    
    /* Stats */
    .stat-number {
        font-size: 2rem;
    }
    
    /* Certifications */
    .certifications-grid {
        grid-template-columns: 1fr;
    }
    
    .cert-card {
        padding: 1.5rem;
    }
    
    /* Contact */
    .contact-subtitle {
        font-size: 1.5rem;
    }
    
    .contact-form-wrapper {
        padding: 1.5rem;
    }
    
    .form-group input,
    .form-group textarea {
        padding: 0.75rem 1rem;
    }
    
    /* Scroll to Top */
    .scroll-to-top {
        bottom: 1.5rem;
        right: 1.5rem;
        width: 45px;
        height: 45px;
    }
    
    /* Method Tags */
    .methodology-tags {
        gap: 0.75rem;
    }
    
    .method-tag {
        padding: 0.625rem 1.25rem;
        font-size: 0.875rem;
    }
}

/* Mobile Small - 360px */
@media screen and (max-width: 360px) {
    :root {
        font-size: 13px;
    }
    
    .nav-container {
        padding: 0.875rem 1rem;
    }
    
    .hero-title {
        font-size: 2rem;
    }
    
    .section-title {
        font-size: 1.75rem;
    }
    
    .about-subtitle {
        font-size: 1.375rem;
    }
    
    .timeline-content {
        padding: 1.25rem;
    }
    
    .skill-category {
        padding: 1.5rem;
    }
    
    .education-card {
        padding: 2rem;
    }
    
    .cert-card {
        padding: 1.25rem;
    }
}

/* Landscape Orientation */
@media screen and (max-height: 600px) and (orientation: landscape) {
    .hero {
        min-height: auto;
        padding: 5rem 2rem 2rem;
    }
    
    .nav-menu {
        height: calc(100vh - 70px);
        top: 70px;
    }
}

/* High Resolution Displays */
@media screen and (min-width: 1920px) {
    .container {
        max-width: 1600px;
    }
    
    .hero-content,
    .nav-container {
        max-width: 1600px;
    }
    
    .section-title {
        font-size: 4rem;
    }
    
    .hero-title {
        font-size: 5rem;
    }
}

/* Reduced Motion */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
        scroll-behavior: auto !important;
    }
    
    .shape {
        animation: none;
    }
    
    .floating-card {
        animation: none;
    }
    
    .image-container {
        animation: none;
    }
}

/* Print Styles */
@media print {
    .navbar,
    .scroll-to-top,
    .theme-toggle,
    .hamburger,
    .hero-buttons,
    .social-links,
    .contact-form-wrapper,
    .bg-animation {
        display: none !important;
    }
    
    body {
        background: white;
        color: black;
    }
    
    section {
        page-break-inside: avoid;
        padding: 1rem 0;
    }
    
    .hero {
        min-height: auto;
        page-break-after: always;
    }
}

/* Dark Mode Specific Responsive Adjustments */
@media screen and (max-width: 768px) {
    [data-theme="dark"] .nav-menu {
        background: var(--bg-primary);
        border-right: 1px solid var(--border-color);
    }
}

/* Touch Device Optimizations */
@media (hover: none) and (pointer: coarse) {
    .btn,
    .nav-link,
    .social-link,
    .contact-card,
    .cert-card,
    .skill-category,
    .education-card,
    .timeline-content {
        transition-duration: 0.1s;
    }
    
    /* Increase touch targets */
    .nav-link,
    .social-link,
    .theme-toggle,
    .hamburger {
        min-height: 44px;
        min-width: 44px;
    }
}