/* ===== Responsive Design ===== */

/* Tablet (768px以下) */
@media screen and (max-width: 768px) {
    /* Layout */
    .container {
        padding: 0 var(--spacing-sm);
    }

    /* Header */
    .header-content {
        padding: var(--spacing-sm) 0;
    }

    .logo h1 {
        font-size: 1.3rem;
    }

    .logo small {
        font-size: 0.6rem;
    }

    .nav-list {
        position: fixed;
        top: 100%;
        left: 0;
        width: 100%;
        background: rgba(10, 10, 10, 0.98);
        backdrop-filter: blur(20px);
        flex-direction: column;
        padding: var(--spacing-xl);
        border-top: 1px solid var(--border-color);
        transform: translateY(-100%);
        opacity: 0;
        visibility: hidden;
        transition: var(--transition);
        gap: var(--spacing-lg);
    }

    .nav-list.active {
        transform: translateY(0);
        opacity: 1;
        visibility: visible;
    }

    .nav-list a {
        font-size: 1.1rem;
        padding: var(--spacing-sm) 0;
        border-bottom: 1px solid rgba(212, 175, 55, 0.2);
    }

    .hamburger {
        display: flex;
    }

    .hamburger.active span:nth-child(1) {
        transform: rotate(45deg) translate(5px, 5px);
    }

    .hamburger.active span:nth-child(2) {
        opacity: 0;
    }

    .hamburger.active span:nth-child(3) {
        transform: rotate(-45deg) translate(7px, -6px);
    }

    /* Hero */
    .hero {
        padding: calc(var(--spacing-xxl) + 80px) 0 var(--spacing-xl);
        min-height: 80vh;
    }

    .hero-content {
        grid-template-columns: 1fr;
        text-align: center;
        gap: var(--spacing-xl);
    }

    .hero-title {
        font-size: 3rem;
    }

    .hero-subtitle {
        font-size: 1rem;
    }

    .hero-buttons {
        justify-content: center;
        flex-wrap: wrap;
        gap: var(--spacing-sm);
    }

    .btn {
        padding: var(--spacing-sm) var(--spacing-lg);
        font-size: 0.8rem;
    }

    .hero-image img {
        height: 400px;
    }

    /* Features */
    .features-grid {
        grid-template-columns: 1fr;
        gap: var(--spacing-lg);
    }

    .feature-item {
        padding: var(--spacing-lg);
    }

    /* Works */
    .works-grid {
        grid-template-columns: 1fr;
        gap: var(--spacing-lg);
    }

    .work-image img {
        height: 250px;
    }

    /* Contact */
    .contact-methods {
        grid-template-columns: 1fr;
        gap: var(--spacing-lg);
    }

    .contact-method {
        padding: var(--spacing-lg);
    }

    /* Typography */
    .section-title {
        font-size: 2.5rem;
    }
}

/* Mobile (480px以下) */
@media screen and (max-width: 480px) {
    /* Layout */
    .container {
        padding: 0 var(--spacing-xs);
    }

    section {
        padding: var(--spacing-xl) 0;
    }

    /* Header */
    .header-content {
        padding: var(--spacing-sm) 0;
    }

    .logo h1 {
        font-size: 1.1rem;
    }

    .logo small {
        font-size: 0.5rem;
    }

    /* Hero */
    .hero {
        padding: calc(var(--spacing-xl) + 60px) 0 var(--spacing-lg);
        min-height: 70vh;
    }

    .hero-title {
        font-size: 2.2rem;
        line-height: 1.2;
    }

    .hero-subtitle {
        font-size: 0.9rem;
    }

    .hero-description {
        font-size: 0.9rem;
    }

    .hero-buttons {
        flex-direction: column;
        align-items: center;
        gap: var(--spacing-sm);
    }

    .btn {
        width: 100%;
        max-width: 280px;
        padding: var(--spacing-sm) var(--spacing-md);
    }

    .hero-image img {
        height: 300px;
    }

    /* Features */
    .feature-item {
        padding: var(--spacing-md);
    }

    .feature-icon {
        width: 60px;
        height: 60px;
    }

    .feature-icon svg {
        width: 30px;
        height: 30px;
    }

    .feature-item h3 {
        font-size: 1.2rem;
    }

    /* Works */
    .work-info {
        padding: var(--spacing-md);
    }

    .work-info h3 {
        font-size: 1.1rem;
    }

    .work-image img {
        height: 200px;
    }

    /* Contact */
    .contact-info h3 {
        font-size: 1.8rem;
    }

    .contact-method {
        padding: var(--spacing-md);
    }

    .phone-number {
        font-size: 1.5rem;
    }

    /* Typography */
    .section-title {
        font-size: 2rem;
        margin-bottom: var(--spacing-lg);
    }
}

/* Large screens (1200px以上) */
@media screen and (min-width: 1200px) {
    .container {
        padding: 0 var(--spacing-lg);
    }

    .hero-title {
        font-size: 5rem;
    }

    .hero-subtitle {
        font-size: 1.4rem;
    }

    .section-title {
        font-size: 4rem;
    }

    .features-grid {
        grid-template-columns: repeat(3, 1fr);
    }

    .works-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .hero-image img {
        height: 700px;
    }
}

/* Ultra-wide screens (1600px以上) */
@media screen and (min-width: 1600px) {
    .container {
        max-width: 1400px;
    }

    .hero-title {
        font-size: 6rem;
    }

    .section-title {
        font-size: 4.5rem;
    }
}

/* Accessibility */
@media (prefers-reduced-motion: reduce) {
    * {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }

    .hero::before,
    .feature-item::before,
    .work-image::after {
        display: none;
    }
}

@media (prefers-contrast: high) {
    :root {
        --primary-color: #000000;
        --secondary-color: #ffff00;
        --text-color: #ffffff;
        --text-light: #ffffff;
        --bg-dark: #000000;
        --bg-light: #000000;
        --border-color: #ffffff;
        --gold: #ffff00;
    }
}

@media (prefers-color-scheme: light) {
    :root {
        --primary-color: #f5f5f5;
        --secondary-color: #b8860b;
        --text-color: #333333;
        --text-light: #666666;
        --bg-dark: #ffffff;
        --bg-light: #f8f8f8;
        --border-color: #e0e0e0;
        --gold: #b8860b;
    }

    .hero-image img,
    .work-image img {
        filter: grayscale(0%) contrast(1);
    }
}

/* Print styles */
@media print {
    .header {
        position: static;
        background: white;
        color: black;
    }

    .nav-list,
    .hamburger {
        display: none;
    }

    .hero {
        padding-top: var(--spacing-sm);
        background: white;
        color: black;
    }

    .btn {
        display: none;
    }

    .hero-image,
    .work-image {
        display: none;
    }

    .section-title {
        color: black;
    }

    * {
        background: white !important;
        color: black !important;
    }
}

/* Touch devices */
@media (hover: none) {
    .btn:hover,
    .feature-item:hover,
    .work-item:hover,
    .contact-method:hover {
        transform: none;
    }

    .btn:active,
    .feature-item:active,
    .work-item:active {
        transform: scale(0.98);
    }

    .feature-item::before,
    .work-image::after {
        display: none;
    }
}

/* High DPI displays */
@media (-webkit-min-device-pixel-ratio: 2), (min-resolution: 192dpi) {
    .hero-image img,
    .work-image img {
        image-rendering: -webkit-optimize-contrast;
        image-rendering: crisp-edges;
    }
}

/* Landscape orientation on mobile */
@media screen and (max-width: 768px) and (orientation: landscape) {
    .hero {
        min-height: 60vh;
        padding: calc(var(--spacing-lg) + 60px) 0 var(--spacing-md);
    }

    .hero-content {
        grid-template-columns: 1fr 1fr;
        gap: var(--spacing-lg);
    }

    .hero-title {
        font-size: 2.5rem;
    }

    .hero-image img {
        height: 250px;
    }
} 