:root {
    --bg-color: #050505;
    --surface-color: #111111;
    --surface-hover: #1a1a1a;
    --text-primary: #f5f5f5;
    --text-secondary: #a0a0a0;
    --accent-color: #2997ff;
    /* Apple-like blue accent */
    --accent-gradient: linear-gradient(135deg, #2997ff 0%, #9d4eff 100%);

    --font-heading: 'Inter', sans-serif;
    --font-futura: 'Jost', sans-serif;
    /* Futura alternative */
    --font-body: 'Noto Sans JP', sans-serif;

    --spacing-xs: 0.5rem;
    --spacing-sm: 1rem;
    --spacing-md: 2rem;
    --spacing-lg: 4rem;
    --spacing-xl: 8rem;

    --container-width: 1200px;
    --header-height: 80px;

    --transition-fast: 0.2s cubic-bezier(0.16, 1, 0.3, 1);
    --transition-smooth: 0.6s cubic-bezier(0.16, 1, 0.3, 1);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    background-color: var(--bg-color);
    color: var(--text-primary);
    font-family: var(--font-body);
    line-height: 1.6;
    overflow-x: hidden;
}

/* Global Paragraph Style - matching About Us vibe */
p,
dd,
li {
    font-family: 'Noto Sans JP', sans-serif;
    font-weight: 300;
    line-height: 2.2;
    letter-spacing: 0.1em;
}

/* Typography */
h1,
h2,
h3 {
    font-family: var(--font-heading);
    font-weight: 800;
    letter-spacing: -0.02em;
}

.text-gradient {
    background: var(--accent-gradient);
    background-clip: text;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

/* Layout */
.container {
    box-sizing: border-box;
    width: 90%;
    max-width: var(--container-width);
    margin: 0 auto;
    padding: 0 var(--spacing-sm);
}

/* Header */
.header {
    position: fixed;
    top: 0;
    width: 100%;
    height: var(--header-height);
    background: rgba(5, 5, 5, 0.8);
    backdrop-filter: blur(12px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    z-index: 100;
    transition: transform 0.3s ease;
}

.header-container {
    height: 100%;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo img {
    height: 40px;
    /* Adjust based on logo aspect ratio */
    width: auto;
    display: block;
}

.nav-list {
    display: flex;
    list-style: none;
    gap: var(--spacing-md);
}

.nav-list a {
    color: var(--text-secondary);
    text-decoration: none;
    font-size: 0.9rem;
    font-family: var(--font-futura);
    font-weight: 200;
    /* Extra Light for readability */
    letter-spacing: 0.05em;
    text-transform: uppercase;
    transition: color var(--transition-fast);
}

/* Mobile Menu Button */
.mobile-menu-btn {
    display: none;
    flex-direction: column;
    justify-content: space-between;
    width: 30px;
    height: 20px;
    background: transparent;
    border: none;
    z-index: 1001;
}

.mobile-menu-btn span {
    width: 100%;
    height: 2px;
    background-color: var(--text-primary);
    transition: all 0.3s ease;
    border-radius: 2px;
}

/* Rotate into X */
.mobile-menu-btn.active span:nth-child(1) {
    transform: translateY(9px) rotate(45deg);
}

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

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

.nav-list a:hover {
    color: var(--text-primary);
}

/* Hero Section */
.hero {
    height: 100vh;
    display: flex;
    align-items: center;
    position: relative;
    padding-top: var(--header-height);
}

.hero-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    /* Fixed background image */
    background: url('assets/bg01.png') no-repeat center center/cover;
    overflow: hidden;
}

.hero-bg::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: transparent;
}

.hero-content {
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    align-items: flex-start;
    height: 100%;
    position: relative;
    z-index: 2;
    padding-top: 5vh;
}

.hero-logo-overlay {
    position: absolute;
    top: 50%;
    right: 5%;
    transform: translateY(-50%);
    width: 400px;
    /* Adjust size as needed */
    max-width: 40%;
    opacity: 0.8;
    z-index: 1;
    pointer-events: none;
    mix-blend-mode: overlay;
    /* Cool blending effect */
}

.hero-title {
    font-size: clamp(3rem, 9vw, 8rem);
    line-height: 0.75;
    /* Extremely tight line height */
    text-align: left;
    margin-bottom: var(--spacing-md);
    letter-spacing: -0.08em;
    /* Extremely tight letter spacing */
    z-index: 2;
    text-shadow: 0 4px 12px rgba(0, 0, 0, 0.5);
    /* Soft drop shadow */
}

.hero-title .block {
    display: block;
}

.hero-subtitle {
    font-family: 'Noto Serif JP', serif;
    /* Keep Serif for Hero Subtitle specific contrast */
    font-size: 2rem;
    color: #ffffff;
    margin-bottom: var(--spacing-lg);
    max-width: 600px;
    letter-spacing: 0.4em;
    margin-left: 5px;
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 12px 32px;
    border-radius: 9999px;
    text-decoration: none;
    font-weight: 600;
    font-size: 0.95rem;
    transition: all var(--transition-fast);
}

.btn-primary {
    background: var(--text-primary);
    color: var(--bg-color);
}

.btn-primary:hover {
    background: #ffffff;
    box-shadow: 0 0 20px rgba(255, 255, 255, 0.3);
    transform: scale(1.02);
}

.btn-secondary {
    background: transparent;
    color: var(--text-primary);
    border: 1px solid rgba(255, 255, 255, 0.2);
    margin-left: var(--spacing-sm);
}

.btn-secondary:hover {
    border-color: var(--text-primary);
    background: rgba(255, 255, 255, 0.05);
}

/* Sections */
.section {
    padding: var(--spacing-xl) 0;
}

.section-title {
    font-family: var(--font-futura);
    font-weight: 100;
    /* Ultra Thin */
    font-size: 2.5rem;
    margin-bottom: var(--spacing-lg);
    border-left: 4px solid var(--accent-color);
    padding-left: var(--spacing-sm);
    letter-spacing: 0.1em;
    /* Futura looks good with spacing */
    text-transform: uppercase;
}

/* IN EDIT & IN CG Shared Styles or Custom */

/* IN EDIT */
.in-edit {
    position: relative;
    background: url('assets/in_edit_bg.png') no-repeat center center/cover;
    background-attachment: fixed;
    /* Parallax effect */
    padding: var(--spacing-xl) 0;
    overflow: hidden;
}

.in-edit-container {
    position: relative;
    z-index: 2;
    text-align: center;
}

.in-edit .section-title {
    border-left: none;
    padding-left: 0;
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.5);
}

.in-edit-subtitle {
    font-family: 'Noto Serif JP', serif;
    /* Match Hero Subtitle */
    font-weight: 400;
    /* Ensure normal weight */
    font-size: 2.5rem;
    margin-bottom: var(--spacing-lg);
    letter-spacing: 0.4em;
    /* Match Hero spacing */
    color: #ffffff;
    position: relative;
    z-index: 1;
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.5);
    margin-right: -0.4em;
    /* Optical centering for wide spacing */
}

.in-edit-text {
    max-width: 800px;
    margin: 0 auto;
    background: rgba(0, 0, 0, 0.4);
    backdrop-filter: blur(5px);
    padding: var(--spacing-lg);
    border-radius: 16px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    position: relative;
    z-index: 1;
}

.edit-category {
    font-size: 1.25rem;
    /* Increased size */
    letter-spacing: 0.1em;
    color: var(--accent-color);
    margin-bottom: var(--spacing-sm);
    text-transform: uppercase;
    font-weight: 500;
}

.edit-description {
    font-size: 1.1rem;
    line-height: 2;
    color: var(--text-secondary);
}

.highlight {
    color: var(--text-primary);
    font-weight: 700;
}

/* IN CG */
.in-cg {
    position: relative;
    background: url('assets/bg3.jpg') no-repeat center center/cover;
    background-attachment: fixed;
    /* Parallax effect for "full width video feel" */
    padding: var(--spacing-xl) 0;
    overflow: hidden;
}

.bg-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.6);
    /* Darken for text readability */
    z-index: 1;
}

.in-cg-container {
    position: relative;
    z-index: 2;
    text-align: center;
    /* Center align for impact */
}

.in-cg .section-title {
    border-left: none;
    /* Center style */
    padding-left: 0;
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.5);
}

.in-cg-subtitle {
    font-family: 'Noto Serif JP', serif;
    /* Match Hero Subtitle */
    font-weight: normal;
    /* Serif weight */
    font-size: 2.5rem;
    margin-bottom: var(--spacing-lg);
    letter-spacing: 0.4em;
    /* Match Hero spacing */
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.5);
    margin-right: -0.4em;
    /* Optical centering */
    color: #ffffff;
}

.in-cg-text {
    max-width: 800px;
    margin: 0 auto;
    background: rgba(0, 0, 0, 0.4);
    backdrop-filter: blur(5px);
    padding: var(--spacing-lg);
    border-radius: 16px;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.cg-lead {
    font-size: 1.2rem;
    margin-bottom: var(--spacing-md);
    color: var(--accent-color);
}

.cg-list {
    font-size: 1.1rem;
    line-height: 2;
}

.highlight {
    color: var(--text-primary);
    font-weight: 700;
}

/* Studio */
.studio {
    position: relative;
    background: url('assets/IN01.png') no-repeat center center/cover;
    background-attachment: fixed;
    padding: var(--spacing-xl) 0;
    overflow: hidden;
}

.studio-container {
    position: relative;
    z-index: 2;
}

.studio-content {
    background: transparent;
    /* Removed card bg */
    padding: 0;
    border-radius: 0;
    border: none;
    position: relative;
}

.studio-subtitle {
    font-family: var(--font-futura);
    font-weight: 200;
    font-size: 1.5rem;
    color: var(--accent-color);
    margin-bottom: var(--spacing-md);
    letter-spacing: 0.1em;
    text-transform: uppercase;
}

.studio-specs p {
    margin-bottom: 0.5rem;
    font-size: 1.1rem;
    color: var(--text-primary);
}

.studio-capacity {
    margin-top: var(--spacing-md);
    padding-top: var(--spacing-sm);
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    font-weight: 500;
}

/* Studio Gallery */
.studio-gallery {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: var(--spacing-md);
    margin-top: var(--spacing-lg);
}

.gallery-item {
    border-radius: 12px;
    overflow: hidden;
    height: 250px;
    position: relative;
    border: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
}

.gallery-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s cubic-bezier(0.16, 1, 0.3, 1);
}

.gallery-item:hover img {
    transform: scale(1.05);
}

@media (max-width: 768px) {
    .studio-gallery {
        grid-template-columns: 1fr;
        height: auto;
    }

    .gallery-item {
        height: 200px;
    }
}

/* Access */
.access-content {
    display: grid;
    grid-template-columns: 1fr 1.5fr;
    gap: var(--spacing-md);
    align-items: center;
}

.access-info h3 {
    font-size: 1.5rem;
    margin-bottom: var(--spacing-sm);
}

.access-info p {
    color: var(--text-secondary);
    line-height: 1.8;
}

.access-note {
    margin-top: var(--spacing-sm);
    font-size: 0.9rem;
    color: var(--accent-color);
}

/* About Us */
.about-container {
    padding-bottom: var(--spacing-lg);
}

.about-text-block h3 {
    font-family: var(--font-futura);
    font-weight: 200;
    font-size: 1.5rem;
    color: var(--accent-color);
    margin-bottom: var(--spacing-md);
    letter-spacing: 0.2em;
    text-transform: uppercase;
}

.about-text-block p {
    font-family: 'Noto Sans JP', sans-serif;
    font-weight: 300;
    font-size: 1rem;
    line-height: 2.5;
    /* Wide line height for modern feel */
    letter-spacing: 0.15em;
    /* Wide letter spacing */
    color: var(--text-primary);
}

.company-dl {
    display: grid;
    grid-template-columns: 140px 1fr;
    gap: 1.5rem;
    margin-top: var(--spacing-md);
}

.company-dl dt {
    color: var(--accent-color);
    font-weight: 600;
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    padding-bottom: 0.5rem;
}

.company-dl dd {
    margin: 0;
    color: var(--text-primary);
    line-height: 1.6;
    padding-bottom: 0.5rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

@media (max-width: 768px) {
    .company-dl {
        grid-template-columns: 1fr;
        gap: 0.5rem;
    }

    .company-dl dt {
        border: none;
        padding-bottom: 0;
        margin-top: 1rem;
    }

    .company-dl dd {
        padding-bottom: 0.5rem;
    }
}


/* Access Grid */
.access-details-grid {
    display: grid;
    grid-template-columns: 1fr 1.5fr;
    gap: var(--spacing-md);
    align-items: center;
}

.access-station {
    font-size: 1.1rem;
    color: var(--text-primary);
    margin-bottom: 0.5rem;
    padding-left: 1rem;
    border-left: 2px solid var(--accent-color);
}

.access-notes {
    margin-top: var(--spacing-md);
    color: var(--text-secondary);
    font-size: 0.9rem;
}

.access-notes p {
    margin-bottom: 0.3rem;
}

.bw-map {
    width: 100%;
    height: 400px;
    border-radius: 16px;
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.bw-map iframe {
    display: block;
    width: 100%;
    height: 100%;
}

@media (max-width: 900px) {
    .access-details-grid {
        grid-template-columns: 1fr;
    }
}

/* Contact */
.contact-form {
    max-width: 600px;
    display: flex;
    flex-direction: column;
    gap: var(--spacing-md);
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.form-group label {
    font-size: 0.9rem;
    color: var(--text-secondary);
}

.form-group input,
.form-group textarea {
    background: var(--surface-color);
    border: 1px solid rgba(255, 255, 255, 0.05);
    padding: 16px;
    border-radius: 8px;
    color: var(--text-primary);
    font-family: inherit;
    font-size: 1rem;
    transition: border-color 0.2s;
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--accent-color);
}

.btn-submit {
    align-self: flex-start;
}

/* Footer */
.footer {
    padding: var(--spacing-lg) 0;
    text-align: center;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
    margin-top: var(--spacing-xl);
}

.footer-logo {
    font-weight: 800;
    font-size: 1.5rem;
    margin-bottom: var(--spacing-sm);
    letter-spacing: -0.02em;
}

.footer p {
    color: var(--text-secondary);
    font-size: 0.8rem;
}

/* Animations */
.fade-in-up {
    opacity: 0;
    transform: translateY(30px);
    animation: fadeInUp 1s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

.scroll-fade-up {
    opacity: 0;
    transform: translateY(30px);
}

.scroll-fade-up.in-view {
    animation: fadeInUp 1s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

.delay-1 {
    animation-delay: 0.2s;
}

.delay-2 {
    animation-delay: 0.4s;
}

.delay-3 {
    animation-delay: 0.6s;
}

@keyframes fadeInUp {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Specific delays for slow animation */
.scroll-fade-slow.in-view.slow-delay-2 {
    animation-delay: 1.0s;
}

.scroll-fade-slow.in-view.slow-delay-3 {
    animation-delay: 2.0s;
}

/* Slow Fade In for Studio Gallery */
.scroll-fade-slow {
    opacity: 0;
    transform: translateY(20px);
    /* Subtle lift */
    will-change: opacity, transform;
}

.scroll-fade-slow.in-view {
    animation: fadeInSlow 8s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

@keyframes fadeInSlow {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Text Reveal Animation */
.reveal-text {
    opacity: 0;
    display: block;
    animation: revealBlur 1.2s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

@keyframes revealBlur {
    0% {
        opacity: 0;
        transform: translateY(40px) scale(0.95);
        filter: blur(20px);
    }

    100% {
        opacity: 1;
        transform: translateY(0) scale(1);
        filter: blur(0);
    }
}

.reveal-text:nth-child(1) {
    animation-delay: 0.1s;
}

.reveal-text:nth-child(2) {
    animation-delay: 0.3s;
}

.reveal-text:nth-child(3) {
    animation-delay: 0.5s;
}

.reveal-text:nth-child(4) {
    animation-delay: 0.7s;
}

/* Mobile */
@media (max-width: 768px) {
    .mobile-menu-btn {
        display: flex;
    }

    .hero-logo-overlay {
        display: none;
        /* Hide logo overlay on mobile to prevent overlap */
    }

    .nav {
        position: fixed;
        top: 0;
        right: 0;
        width: 100%;
        height: 100vh;
        background: rgba(5, 5, 5, 0.98);
        backdrop-filter: blur(10px);
        display: flex;
        align-items: center;
        justify-content: center;
        transform: translateX(100%);
        transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1);
        z-index: 1000;
    }

    .nav.active {
        transform: translateX(0);
        display: flex;
        /* Ensure display is flex */
    }

    .nav-list {
        flex-direction: column;
        align-items: center;
        gap: var(--spacing-sm);
        /* Reduced from var(--spacing-lg) */
    }

    .nav-list a {
        font-size: 1.2rem;
        /* Reduced from 2rem for better usability */
        font-weight: 200;
    }

    .masonry-grid {
        grid-template-columns: 1fr;
    }

    .hero-title {
        font-size: 3.5rem;
        /* Increased from 2.5rem for better visibility */
    }

    /* Fix parallax backgrounds on mobile */
    .in-edit,
    .in-cg,
    .studio {
        background-attachment: scroll;
        /* Disable parallax on mobile */
        background-size: cover;
        background-position: center;
    }
}