/* Responsive Styles */

/* Tablet Styles */
@media (max-width: 1024px) {
    .container {
        padding: 0 1.5rem;
    }
    
    .hero-title .name {
        font-size: 3rem;
    }
    
    .about-content {
        grid-template-columns: 1fr;
        gap: 3rem;
    }
    
    .about-stats {
        flex-direction: row;
        justify-content: space-around;
    }
    
    .contact-content {
        grid-template-columns: 1fr;
        gap: 3rem;
    }
    
    .timeline::before {
        left: 30px;
    }
    
    .timeline-item {
        padding-left: 80px;
    }
    
    .timeline-dot {
        left: 21px;
    }
}

/* Mobile Styles */
@media (max-width: 768px) {
    .container {
        padding: 0 1rem;
    }
    
    /* Navigation */
    .nav-menu {
        position: fixed;
        left: -100%;
        top: 70px;
        flex-direction: column;
        background-color: rgba(255, 255, 255, 0.98);
        width: 100%;
        text-align: center;
        transition: 0.3s;
        box-shadow: 0 10px 27px rgba(0, 0, 0, 0.05);
        backdrop-filter: blur(10px);
        padding: 2rem 0;
    }
    
    .nav-menu.active {
        left: 0;
    }
    
    .nav-menu a {
        padding: 1rem;
        display: block;
    }
    
    .nav-toggle {
        display: flex;
    }
    
    .nav-toggle.active .bar:nth-child(2) {
        opacity: 0;
    }
    
    .nav-toggle.active .bar:nth-child(1) {
        transform: translateY(8px) rotate(45deg);
    }
    
    .nav-toggle.active .bar:nth-child(3) {
        transform: translateY(-8px) rotate(-45deg);
    }
    
    /* Hero Section */
    .hero-title .name {
        font-size: 2.5rem;
    }
    
    .hero-subtitle {
        font-size: 1.2rem;
    }
    
    .hero-buttons {
        flex-direction: column;
        align-items: center;
        gap: 1rem;
    }
    
    .hero-buttons .btn {
        width: 100%;
        max-width: 300px;
        justify-content: center;
    }
    
    /* Sections */
    section {
        padding: 3rem 0;
    }
    
    .section-title {
        font-size: 2rem;
        margin-bottom: 2rem;
    }
    
    /* About Stats */
    .about-stats {
        flex-direction: column;
        gap: 1rem;
    }
    
    /* Timeline */
    .timeline::before {
        left: 15px;
    }
    
    .timeline-item {
        padding-left: 50px;
    }
    
    .timeline-dot {
        left: 6px;
    }
    
    .timeline-content::before {
        display: none;
    }
    
    /* Skills */
    .skills-grid {
        grid-template-columns: 1fr;
        gap: 2rem;
    }
    
    /* Projects */
    .projects-grid {
        grid-template-columns: 1fr;
    }
    
    /* Education */
    .education-grid {
        grid-template-columns: 1fr;
    }
    
    /* Contact */
    .contact-items {
        gap: 1rem;
    }
    
    .contact-item {
        flex-direction: column;
        text-align: center;
        gap: 0.5rem;
    }
    
    /* Footer */
    .footer-content {
        flex-direction: column;
        gap: 1rem;
    }
    
    .footer-links {
        gap: 1rem;
    }
}

/* Small Mobile Styles */
@media (max-width: 480px) {
    html {
        font-size: 14px;
    }
    
    .container {
        padding: 0 0.75rem;
    }
    
    .hero-title .name {
        font-size: 2rem;
    }
    
    .hero-image {
        width: 150px;
        height: 150px;
    }
    
    .section-title {
        font-size: 1.8rem;
    }
    
    .timeline-item {
        padding-left: 40px;
    }
    
    .timeline-content {
        padding: 1.5rem;
    }
    
    .project-content {
        padding: 1.5rem;
    }
    
    .education-card {
        padding: 1.5rem;
    }
    
    .contact-form {
        padding: 1.5rem;
    }
    
    .back-to-top {
        bottom: 1rem;
        right: 1rem;
        width: 40px;
        height: 40px;
    }
}

/* Landscape Orientation */
@media (max-height: 500px) and (orientation: landscape) {
    .hero {
        min-height: auto;
        padding: 2rem 0;
    }
    
    .hero-image {
        width: 100px;
        height: 100px;
        margin-bottom: 1rem;
    }
    
    .hero-title .name {
        font-size: 2rem;
    }
    
    .hero-subtitle {
        font-size: 1rem;
    }
    
    .hero-description {
        font-size: 0.9rem;
        margin-bottom: 1rem;
    }
    
    .hero-buttons {
        margin-bottom: 1rem;
    }
}

/* High DPI Displays */
@media (-webkit-min-device-pixel-ratio: 2), (min-resolution: 192dpi) {
    .hero-image {
        image-rendering: -webkit-optimize-contrast;
        image-rendering: crisp-edges;
    }
}

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

/* Dark Mode Support */
@media (prefers-color-scheme: dark) {
    :root {
        --bg-color: #1a1a1a;
        --text-color: #ffffff;
        --text-secondary: #b0b0b0;
        --card-bg: #2a2a2a;
    }
    
    body {
        background-color: var(--bg-color);
        color: var(--text-color);
    }
    
    .navbar {
        background: rgba(26, 26, 26, 0.95);
    }
    
    .nav-logo,
    .nav-link {
        color: var(--text-color);
    }
    
    .hero {
        background: linear-gradient(135deg, #2a2a2a 0%, #1a1a1a 100%);
    }
    
    .section-title {
        color: var(--text-color);
    }
    
    p {
        color: var(--text-secondary);
    }
    
    .timeline-content,
    .education-card,
    .project-card {
        background: var(--card-bg);
    }
    
    .footer {
        background: #111111;
    }
}