/* =================================================================
   studio CLOTO - Responsive Design
   ================================================================= */

/* ===== Desktop Large (1200px+) ===== */
@media (min-width: 1200px) {
    .container {
        max-width: 1400px;
    }
    
    .hero__title {
        font-size: 4.5rem;
    }
    
    .section-title {
        font-size: 4rem;
    }
}

/* ===== Laptop (1024px - 1199px) ===== */
@media (max-width: 1199px) and (min-width: 1024px) {
    .hero__container,
    .about__slide,
    .contact__content {
        grid-template-columns: 1fr;
        gap: var(--spacing-lg);
        text-align: center;
    }
    
    .vision-slide__content {
        grid-template-columns: 1fr;
        gap: 3rem;
    }
}

/* ===== Tablet (768px - 1023px) ===== */
@media (max-width: 1023px) and (min-width: 768px) {
    .section-title,
    .projects .section-title,
    .team .section-title,
    .contact .section-title {
        font-size: 3rem;
    }
    
    .section-container {
        padding: 0 var(--spacing-md);
    }
    
    .services__grid {
        grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
        max-height: 55vh;
    }
    
    .contact__content {
        grid-template-columns: 1fr;
        gap: var(--spacing-lg);
        text-align: center;
    }
    
    .tech-grid {
        grid-template-columns: repeat(auto-fit, minmax(100px, 1fr));
    }
    
    .project-overview .section-title {
        font-size: 3rem;
    }
    
    .project-intro h3 {
        font-size: 2.5rem;
    }
    
    .project-detail__content h3 {
        font-size: 2rem;
    }
    
    .project-capabilities {
        grid-template-columns: 1fr;
    }

    .project-overview .section-title {
        font-size: 3rem;
    }
    .project-intro h3 {
        font-size: 2.5rem;
    }
    .project-detail__content h3 {
        font-size: 2rem;
    }
    .project-capabilities {
        grid-template-columns: 1fr;
    }
}

/* ===== Mobile Large (481px - 767px) ===== */
@media (max-width: 767px) {
    :root {
        --section-padding: var(--spacing-lg);
        --hero-pin-height: 200vh;
        --vision-pin-height: 300vh;
        --about-pin-height: 380vh;
    }
    
    /* ===== Navigation Mobile ===== */
    .nav__menu {
        position: fixed;
        top: 70px;
        left: 0;
        right: 0;
        background: rgba(0, 0, 0, 0.98);
        flex-direction: column;
        padding: 2rem;
        transform: translateX(-100%);
        transition: transform 0.3s ease;
        display: flex;
        gap: 1.5rem;
    }

    .nav__menu.active {
        transform: translateX(0);
    }
    
    .nav__toggle {
        display: flex;
    }

    .nav__toggle.active span:nth-child(1) {
        transform: rotate(45deg) translate(5px, 5px);
    }

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

    .nav__toggle.active span:nth-child(3) {
        transform: rotate(-45deg) translate(7px, -6px);
    }
    
    /* ===== Section Heights Mobile ===== */
    section.projects,
    section.team,
    section.contact {
        height: 100vh;
    }
    
    .hero-pin {
        height: var(--hero-pin-height);
    }
    
    .vision-pin {
        height: var(--vision-pin-height);
    }
    
    .about-pin {
        height: var(--about-pin-height);
    }
    
    /* ===== Typography Mobile ===== */
    .section-title,
    .projects .section-title,
    .team .section-title,
    .contact .section-title {
        font-size: 2.5rem;
    }
    
    .section-subtitle,
    .projects .section-subtitle,
    .team .section-subtitle,
    .contact .section-subtitle {
        font-size: 1rem;
    }
    
    .hero__title {
        font-size: 2.5rem;
    }
    
    .hero__subtitle {
        font-size: 1.2rem;
    }
    
    /* ===== Hero Mobile ===== */
    .hero__container {
        grid-template-columns: 1fr;
        gap: var(--spacing-md);
        text-align: center;
    }
    
    .hero__cta {
        flex-direction: column;
        align-items: center;
        gap: var(--spacing-sm);
    }
    
    .hero__kanji-logo {
        height: 300px;
    }
    
    /* ===== Vision Mobile ===== */
    .vision-horizontal {
        padding: 150px 10px 50px;
    }
    
    .vision__header {
        padding: var(--spacing-lg) 0 var(--spacing-md);
    }
    
    .vision-slide__content {
        grid-template-columns: 1fr;
        gap: 2rem;
        text-align: center;
        padding: 0 2rem;
    }
    
    .vision-slide__text h3 {
        font-size: 2.5rem;
    }
    
    .vision-slide__text h4 {
        font-size: 1.5rem;
    }
    
    .vision-slide__text p {
        font-size: 1rem;
        line-height: 1.8;
    }
    
    .vision__geometric {
        width: 200px;
        height: 200px;
    }
    
    .vision__header .section-title {
        font-size: 2.5rem;
    }
    
    /* ===== About Mobile ===== */
    .about__header {
        padding: 100px 0 40px;
    }
    
    .about__header .section-title {
        font-size: 2.5rem;
    }
    
    .about__header .section-subtitle {
        font-size: 1rem;
    }
    
    .about-vertical {
        padding-left: 2%;
        padding-right: 2%;
        height: var(--about-pin-height);
        animation: aboutVerticalScrollMobile linear both;
        animation-timeline: --about-pin;
        animation-range: contain 0% contain 100%;
    }
    
    @keyframes aboutVerticalScrollMobile {
        from { transform: translateY(0); }
        to { transform: translateY(-280vh); }
    }
    
    .about-slide__content {
        grid-template-columns: 1fr;
        gap: 2rem;
        text-align: center;
    }
    
    .about-slide__text h3 {
        font-size: 2.5rem;
    }
    
    .about-slide__text h4 {
        font-size: 1.5rem;
    }
    
    .about-slide__text p {
        font-size: 1rem;
    }
    
    .about__geometric {
        width: 200px;
        height: 200px;
    }
    
    /* ===== Services Mobile ===== */
    .projects-header {
        padding-top: 100px;
    }
    
    .projects-header .section-title {
        font-size: 2.5rem;
    }
    
    .projects-header .section-subtitle {
        font-size: 1rem;
    }
    
    .project-container:first-of-type {
        margin-top: 180px;
    }
    
    .project-section {
        padding: 0 var(--spacing-md);
    }
    
    .project-overview .section-title {
        font-size: 2.5rem;
    }
    
    .project-intro h3 {
        font-size: 2rem;
    }
    
    .project-detail__content h3 {
        font-size: 1.8rem;
    }
    
    .project-tagline {
        font-size: 1.1rem;
    }
    
    .project-features {
        justify-content: center;
    }
    
    .feature-tag {
        font-size: 0.8rem;
        padding: 0.4rem 0.8rem;
    }
    
    .project-detail__description p {
        font-size: 1rem;
    }
    
    .services__grid {
        grid-template-columns: 1fr;
        gap: var(--spacing-sm);
        max-height: 50vh;
    }
    
    /* ===== Components Mobile ===== */
    .section-container {
        padding: 120px var(--spacing-sm) 0;
    }
    
    .team__stats {
        grid-template-columns: 1fr;
        gap: var(--spacing-md);
    }
    
    .contact .section-container {
        text-align: center;
    }
    
    .footer__content {
        grid-template-columns: 1fr;
        text-align: center;
    }
    
    /* ===== Progress Bars Mobile ===== */
    .vision-progress {
        width: 90%;
        bottom: 20px;
    }
    
    .vision-progress__container {
        padding: 15px;
    }
    
    .vision-progress__bar {
        height: 4px;
        margin-bottom: 12px;
    }
    
    .vision-progress__marker {
        font-size: 0.8rem;
    }
    
    .vision-progress__marker::before {
        width: 6px;
        height: 6px;
        top: -16px;
    }
    
    .about-progress {
        right: 20px;
        width: 60px;
    }
    
    .about-progress__container {
        padding: 15px;
    }
    
    .about-progress__marker {
        font-size: 0.7rem;
    }
    
    .about-progress__marker::before {
        width: 6px;
        height: 6px;
        left: -20px;
    }
}

/* ===== Mobile Small (320px - 480px) ===== */
@media (max-width: 480px) {
    /* ===== Typography Small Mobile ===== */
    .hero__title {
        font-size: 2rem;
    }
    
    .section-title,
    .projects .section-title,
    .team .section-title,
    .contact .section-title {
        font-size: 2rem;
    }
    
    .section-subtitle,
    .projects .section-subtitle,
    .team .section-subtitle,
    .contact .section-subtitle {
        font-size: 0.9rem;
    }
    
    /* ===== Layout Small Mobile ===== */
    .services__grid {
        max-height: 45vh;
    }
    
    .hero__kanji-logo {
        height: 250px;
    }
    
    .projects-header {
        padding-top: 80px;
    }
    
    .project-container:first-of-type {
        margin-top: 160px;
    }
    
    /* ===== About Small Mobile ===== */
    .about__header {
        padding: 80px 0 30px;
    }
    
    .about__header .section-title {
        font-size: 2rem;
    }
    
    .about__header .section-subtitle {
        font-size: 0.9rem;
    }
    
    .about-slide__text h3 {
        font-size: 2rem;
    }
    
    .about__geometric {
        width: 150px;
        height: 150px;
    }
    
    .about-progress {
        right: 10px;
        width: 50px;
    }
    
    /* ===== Services Small Mobile ===== */
    .project-intro h3 {
        font-size: 1.8rem;
    }
    
    .project-detail__content h3 {
        font-size: 1.5rem;
    }
    
    .tech-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* ===== Mobile Extra Small (below 320px) ===== */
@media (max-width: 319px) {
    .container {
        padding: 0 var(--spacing-xs);
    }
    
    .hero__title {
        font-size: 1.8rem;
    }
    
    .section-title {
        font-size: 1.8rem;
    }
    
    .hero__kanji-logo {
        height: 200px;
    }
    
    .nav__menu {
        padding: 1rem;
    }
    
    .btn {
        padding: var(--spacing-xs) var(--spacing-sm);
        font-size: 0.8rem;
    }
}

/* ===== Landscape Orientation Mobile ===== */
@media (max-height: 500px) and (orientation: landscape) {
    .hero-pin,
    .vision-pin,
    .about-pin {
        height: auto;
        min-height: 100vh;
    }
    
    .section.projects,
    .section.team,
    .section.contact {
        height: auto;
        min-height: 100vh;
        padding: var(--spacing-lg) 0;
    }
    
    .hero__kanji-logo {
        height: 200px;
    }
    
    .services__grid {
        max-height: none;
    }
}

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

/* ===== Dark Mode Support (if needed) ===== */
@media (prefers-color-scheme: light) {
    :root {
        --color-black: #ffffff;
        --color-white: #000000;
        --color-gray: #666666;
    }
}

/* ===== Reduced Motion Support ===== */
@media (prefers-reduced-motion: reduce) {
    * {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
    
    .hero__kanji-logo {
        animation: none;
    }
    
    .scroll-indicator {
        animation: none;
    }
}

/* ===== Contrast Enhancement ===== */
@media (prefers-contrast: high) {
    :root {
        --color-accent: #ffcc00;
    }
    
    .btn--primary {
        border: 2px solid var(--color-black);
    }
    
    .btn--outline {
        border: 2px solid var(--color-white);
    }
}

/* ===== Print Optimization ===== */
@media print {
    .nav,
    .hero__scroll-indicator,
    .contact__form,
    .vision-progress,
    .about-progress {
        display: none !important;
    }
    
    body {
        background: white !important;
        color: black !important;
    }
    
    .section-title {
        color: black !important;
    }
    
    .hero__title {
        color: black !important;
    }
    
    * {
        background: transparent !important;
        box-shadow: none !important;
        text-shadow: none !important;
    }
} 