/*
 * Responsive Styles
 * Make the portfolio look great on all devices
 */

/* === Medium Devices (Tablets) === */
@media (max-width: 992px) {
    /* Typography adjustments */
    h1 {
        font-size: 2.5rem;
    }

    h2 {
        font-size: 2rem;
    }

    /* Hero Section */
    .hero h1 {
        font-size: 3rem;
    }

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

    /* Featured Projects */
    .featured-project, .featured-project.reversed {
        flex-direction: column;
    }

    .project-image {
        min-height: 250px;
    }

    /* About Page */
    .about-content {
        flex-direction: column;
    }

    .about-image {
        max-width: 100%;
        margin-bottom: var(--spacing-xl);
    }

    /* Projects Page */
    .showcase-content {
        flex-direction: column;
    }

    .showcase-details {
        grid-template-columns: 1fr 1fr;
    }

    /* Contact Page */
    .contact-layout {
        flex-direction: column;
    }
}

/* === Small Devices (Mobile) === */
@media (max-width: 768px) {
    /* Typography adjustments */
    h1 {
        font-size: 2.25rem;
    }

    h2 {
        font-size: 1.75rem;
    }

    h3 {
        font-size: 1.25rem;
    }

    p {
        font-size: 0.9375rem;
    }

    /* Header & Navigation */
    header .container {
        position: relative;
    }

    .mobile-toggle {
        display: block;
        background: none;
        border: none;
        cursor: pointer;
        width: 30px;
        height: 24px;
        position: relative;
        z-index: 1001;
    }

    .mobile-toggle span {
        display: block;
        width: 100%;
        height: 2px;
        background-color: var(--dark);
        position: absolute;
        left: 0;
        transition: all var(--transition-fast);
    }

    .mobile-toggle span:nth-child(1) {
        top: 0;
    }

    .mobile-toggle span:nth-child(2) {
        top: 50%;
        transform: translateY(-50%);
    }

    .mobile-toggle span:nth-child(3) {
        bottom: 0;
    }

    .mobile-toggle.active span:nth-child(1) {
        transform: translateY(11px) rotate(45deg);
    }

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

    .mobile-toggle.active span:nth-child(3) {
        transform: translateY(-11px) rotate(-45deg);
    }

    .nav-links {
        position: fixed;
        top: 0;
        right: -100%;
        width: 80%;
        max-width: 300px;
        height: 100vh;
        background-color: var(--white);
        box-shadow: var(--shadow-lg);
        flex-direction: column;
        justify-content: center;
        align-items: center;
        transition: right var(--transition-medium);
        z-index: 1000;
    }

    .nav-links.active {
        right: 0;
    }

    .nav-links li {
        margin: var(--spacing-md) 0;
        margin-left: 0;
    }

    /* Add no-scroll body style */
    body.no-scroll {
        overflow: hidden;
    }

    /* Hero Section */
    .hero {
        padding: var(--spacing-xl) 0;
        min-height: auto;
    }

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

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

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

    .hero-buttons {
        flex-direction: column;
        gap: var(--spacing-sm);
        width: 100%;
    }

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

    /* Skills Section */
    .skills-grid {
        grid-template-columns: 1fr;
    }

    /* Projects Section */
    .project-content {
        padding: var(--spacing-md);
    }

    .project-tech {
        margin-bottom: var(--spacing-md);
    }

    .project-links {
        flex-direction: column;
        width: 100%;
    }

    .project-links .btn {
        width: 100%;
    }
}

/* === Extra Small Devices === */
@media (max-width: 480px) {
    .container {
        padding: 0 var(--spacing-sm);
    }

    /* Typography */
    h1 {
        font-size: 2rem;
    }

    h2 {
        font-size: 1.5rem;
    }

    h3 {
        font-size: 1.125rem;
    }

    /* Hero Section */
    .hero h1 {
        font-size: 2rem;
    }

    .hero h2 {
        font-size: 1.25rem;
    }

    /* Footer */
    .social-links {
        flex-wrap: wrap;
        justify-content: center;
    }
}

/* === Dark mode support === */
@media (prefers-color-scheme: dark) {
    :root {
        --dark: #f3f4f6;
        --medium-dark: #d1d5db;
        --medium: #9ca3af;
        --light-medium: #6b7280;
        --light: #1f2937;
        --white: #111827;
    }

    header {
        background-color: rgba(17, 24, 39, 0.98);
    }

    .skill-card, .featured-project {
        background-color: #1a1a1a;
    }

    .tech-tag {
        background-color: #2c2c2c;
    }

    .mobile-toggle span {
        background-color: var(--dark);
    }

    .nav-links {
        background-color: var(--white);
    }
}

@media (max-width: 768px) {
    .about-title {
        text-align: center;
        margin-left: 0;
    }

    .about-image {
        max-width: 60%;
        margin: 0 auto var(--spacing-lg) auto;
    }

    .about-content {
        flex-direction: column;
        text-align: center;
    }

    .about-text {
        text-align: left;
    }
}

@media (max-width: 480px) {
    .about-title {
        font-size: 2rem;
    }

    .about-image {
        max-width: 80%;
    }
}