/* ============================================
   masugomi.com - Watercolor Split-Screen Styles
   ============================================ */

/* --- Color Palette ---
   #F8F9FA - Clinical White (Media BG)
   #FFF8F0 - Warm Paper (Reality BG)
   #2D2D2D - Corporate Dark (Media Text)
   #5A3D3D - Authentic Brown (Reality Text)
   #E8B4B8 - Pastel Rose (Watercolor)
   #B8D4C0 - Pastel Sage (Watercolor)
   #C4B8D8 - Pastel Lavender (Watercolor)
   #8B7B6B - Muted Text
   --- */

:root {
    --color-clinical-white: #F8F9FA;
    --color-warm-paper: #FFF8F0;
    --color-corporate-dark: #2D2D2D;
    --color-authentic-brown: #5A3D3D;
    --color-pastel-rose: #E8B4B8;
    --color-pastel-sage: #B8D4C0;
    --color-pastel-lavender: #C4B8D8;
    --color-muted-text: #8B7B6B;
}

/* --- Reset & Base --- */
*, *::before, *::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    overflow-x: hidden;
}

body {
    font-family: 'Josefin Sans', sans-serif;
    font-weight: 400;
    line-height: 1.8;
    color: #2D2D2D;
    background: #F8F9FA;
    overflow-x: hidden;
}

/* --- SVG Definitions (hidden) --- */
.svg-defs {
    position: absolute;
    width: 0;
    height: 0;
    overflow: hidden;
}

/* ============================================
   SPLIT-SCREEN LAYOUT SYSTEM
   ============================================ */

.split-section {
    position: relative;
    display: flex;
    min-height: 100vh;
    width: 100%;
    overflow: hidden;
}

.split-left {
    position: relative;
    width: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 2;
}

.split-right {
    position: relative;
    width: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 2;
}

/* --- Media Side (Left) --- */
.media-side {
    background: #F8F9FA;
}

/* --- Reality Side (Right) --- */
.reality-side {
    background: #FFF8F0;
}

/* ============================================
   CENTER DIVIDE
   ============================================ */

.center-divide {
    position: absolute;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 60px;
    height: 100%;
    z-index: 10;
    pointer-events: none;
}

.divide-svg {
    width: 100%;
    height: 100%;
}

/* Hero divide special - animated on load */
#center-divide {
    opacity: 0;
}

#center-divide.visible {
    opacity: 1;
}

#divide-path {
    stroke-dasharray: 2800;
    stroke-dashoffset: 2800;
    transition: stroke-dashoffset 800ms ease-out;
}

#divide-path.drawn {
    stroke-dashoffset: 0;
}

/* ============================================
   HERO SECTION
   ============================================ */

.hero-section {
    height: 100vh;
    min-height: 100vh;
}

.hero-text-left {
    text-align: right;
    padding-right: 5vw;
    width: 100%;
}

.hero-text-right {
    text-align: left;
    padding-left: 5vw;
    width: 100%;
    position: relative;
    z-index: 3;
}

/* --- Hero Titles --- */
.hero-title-media {
    font-family: 'Josefin Sans', sans-serif;
    font-weight: 700;
    font-size: clamp(3rem, 7vw, 6rem);
    color: #2D2D2D;
    letter-spacing: 0.08em;
    line-height: 1.1;
    opacity: 0;
    transform: translateX(-40px);
    transition: opacity 400ms ease-out, transform 400ms ease-out;
}

.hero-title-media.visible {
    opacity: 1;
    transform: translateX(0);
}

.hero-title-reality {
    font-family: 'Caveat', cursive;
    font-weight: 700;
    font-size: clamp(3rem, 7vw, 6rem);
    color: #5A3D3D;
    line-height: 1.1;
    opacity: 0;
    transition: opacity 300ms ease-out;
}

.hero-title-reality.visible {
    opacity: 1;
    animation: jitter-in 300ms ease-out forwards;
}

@keyframes jitter-in {
    0% { transform: translate(1px, -1px); }
    25% { transform: translate(-1px, 1px); }
    50% { transform: translate(1px, 0px); }
    75% { transform: translate(-1px, -1px); }
    100% { transform: translate(0, 0); }
}

/* --- Hero Subtitles --- */
.hero-subtitle-media {
    font-family: 'Josefin Sans', sans-serif;
    font-weight: 400;
    font-size: clamp(0.9rem, 1.2vw, 1.1rem);
    color: #8B7B6B;
    letter-spacing: 0.15em;
    text-transform: lowercase;
    margin-top: 1rem;
    opacity: 0;
    transition: opacity 500ms ease-out 800ms;
}

.hero-subtitle-media.visible {
    opacity: 1;
}

.hero-subtitle-reality {
    font-family: 'Caveat', cursive;
    font-weight: 400;
    font-size: clamp(1rem, 1.4vw, 1.3rem);
    color: #8B7B6B;
    margin-top: 0.8rem;
    opacity: 0;
    transition: opacity 500ms ease-out 800ms;
}

.hero-subtitle-reality.visible {
    opacity: 1;
}

/* --- Watercolor Wash SVGs --- */
.watercolor-wash {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
    pointer-events: none;
}

.wash-hero {
    opacity: 0;
    transition: opacity 600ms ease-out;
}

.wash-hero.visible {
    opacity: 1;
}

/* ============================================
   COMPARISON SECTIONS
   ============================================ */

.comparison-section {
    min-height: 100vh;
    padding: 6rem 0;
}

.comparison-content {
    padding: 3rem 4vw;
    max-width: 520px;
    position: relative;
    z-index: 3;
}

/* --- Media Side Content --- */
.media-content {
    margin-left: auto;
    margin-right: 3vw;
}

.media-label {
    font-family: 'Josefin Sans', sans-serif;
    font-weight: 700;
    font-size: 0.7rem;
    letter-spacing: 0.25em;
    text-transform: uppercase;
    color: #8B7B6B;
    display: block;
    margin-bottom: 1.5rem;
}

.media-title {
    font-family: 'Josefin Sans', sans-serif;
    font-weight: 700;
    font-size: clamp(1.4rem, 2.5vw, 2rem);
    color: #2D2D2D;
    line-height: 1.3;
    margin-bottom: 1.5rem;
}

.media-text {
    font-family: 'Josefin Sans', sans-serif;
    font-weight: 400;
    font-size: clamp(0.9rem, 1.05vw, 1rem);
    color: #2D2D2D;
    line-height: 1.8;
    margin-bottom: 1.5rem;
}

.media-source {
    font-family: 'Josefin Sans', sans-serif;
    font-weight: 400;
    font-size: 0.8rem;
    color: #8B7B6B;
    font-style: italic;
}

/* --- Reality Side Content --- */
.reality-content {
    margin-right: auto;
    margin-left: 3vw;
}

.reality-label {
    font-family: 'Caveat', cursive;
    font-weight: 700;
    font-size: 0.95rem;
    letter-spacing: 0.08em;
    color: #8B7B6B;
    display: block;
    margin-bottom: 1.5rem;
}

.reality-title {
    font-family: 'Caveat', cursive;
    font-weight: 700;
    font-size: clamp(1.5rem, 2.8vw, 2.2rem);
    color: #5A3D3D;
    line-height: 1.3;
    margin-bottom: 1.5rem;
    transform: rotate(-0.5deg);
}

.reality-text {
    font-family: 'Josefin Sans', sans-serif;
    font-weight: 400;
    font-size: clamp(0.9rem, 1.05vw, 1rem);
    color: #5A3D3D;
    line-height: 1.8;
    margin-bottom: 1.5rem;
    transform: rotate(-0.5deg);
}

.reality-source {
    font-family: 'Caveat', cursive;
    font-weight: 400;
    font-size: 0.95rem;
    color: #8B7B6B;
    font-style: italic;
}

/* --- Underline-Draw Animation --- */
.underline-draw {
    position: relative;
    display: inline;
}

.underline-draw::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 100%;
    height: 3px;
    background: rgba(232, 180, 184, 0.6);
    transform: scaleX(0);
    transform-origin: left;
    transition: transform 400ms ease-out;
}

.underline-draw.drawn::after {
    transform: scaleX(1);
}

/* --- Dashed Connectors --- */
.dashed-connector {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 0;
    height: 0;
    border-top: 2px dashed rgba(139, 123, 107, 0.3);
    z-index: 11;
    transition: width 200ms ease-out;
}

.dashed-connector.drawn {
    width: 80px;
}

/* --- Glitch Rectangles --- */
.glitch-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 4;
    pointer-events: none;
}

.glitch-rect {
    position: absolute;
    display: block;
    background: #5A3D3D;
}

/* --- Watercolor Bleed Transitions --- */
.watercolor-bleed {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
    pointer-events: none;
    clip-path: inset(0 0 0 50%);
    transition: clip-path 600ms ease-in-out;
}

.watercolor-bleed.bleeding {
    clip-path: inset(0 0 0 30%);
}

.bleed-svg {
    width: 100%;
    height: 100%;
}

/* --- Section Watercolor Washes --- */
.wash-section {
    opacity: 0;
    transition: opacity 500ms ease-out;
}

.wash-section.visible {
    opacity: 1;
}

/* --- Content Animation States --- */
.media-content {
    opacity: 0;
    transform: translateX(-30px);
    transition: opacity 300ms ease-out, transform 300ms ease-out;
}

.media-content.visible {
    opacity: 1;
    transform: translateX(0);
}

.reality-content {
    opacity: 0;
    transition: opacity 400ms ease-out 200ms;
}

.reality-content.visible {
    opacity: 1;
}

/* ============================================
   FOOTER SECTION
   ============================================ */

.footer-section {
    position: relative;
    height: 80vh;
    min-height: 80vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #FFF8F0;
    overflow: hidden;
}

.wash-footer {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
    pointer-events: none;
}

.footer-content {
    position: relative;
    z-index: 2;
    text-align: center;
}

.footer-japanese {
    font-family: 'Noto Sans JP', sans-serif;
    font-weight: 500;
    font-size: clamp(2rem, 5vw, 4rem);
    color: #5A3D3D;
    margin-bottom: 1rem;
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 600ms ease-out, transform 600ms ease-out;
}

.footer-japanese.visible {
    opacity: 1;
    transform: translateY(0);
}

.footer-tagline {
    font-family: 'Caveat', cursive;
    font-weight: 400;
    font-size: 1.2rem;
    color: #8B7B6B;
    letter-spacing: 0.1em;
    opacity: 0;
    transition: opacity 600ms ease-out 300ms;
}

.footer-tagline.visible {
    opacity: 1;
}

/* ============================================
   SECTION LABELS (shared)
   ============================================ */

.section-label {
    display: block;
    margin-bottom: 1.5rem;
}

/* ============================================
   RESPONSIVE ADJUSTMENTS
   ============================================ */

@media (max-width: 900px) {
    .split-section {
        flex-direction: column;
        min-height: auto;
    }

    .hero-section {
        height: auto;
        min-height: 100vh;
    }

    .split-left,
    .split-right {
        width: 100%;
        min-height: 50vh;
    }

    .hero-text-left {
        text-align: center;
        padding-right: 0;
        padding: 3rem 2rem;
    }

    .hero-text-right {
        text-align: center;
        padding-left: 0;
        padding: 3rem 2rem;
    }

    .center-divide {
        display: none;
    }

    .comparison-content {
        padding: 2.5rem 6vw;
        max-width: 100%;
    }

    .media-content {
        margin-left: 0;
        margin-right: 0;
    }

    .reality-content {
        margin-left: 0;
        margin-right: 0;
    }

    .dashed-connector {
        top: auto;
        left: 50%;
        transform: translateX(-50%);
        width: 60px;
        height: 0;
        border-top: 2px dashed rgba(139, 123, 107, 0.3);
        position: relative;
    }

    .comparison-section {
        padding: 3rem 0;
    }

    .watercolor-bleed {
        clip-path: none;
    }

    .footer-section {
        height: auto;
        min-height: 60vh;
        padding: 4rem 2rem;
    }
}

@media (max-width: 600px) {
    .hero-title-media,
    .hero-title-reality {
        font-size: clamp(2.5rem, 12vw, 4rem);
    }

    .comparison-content {
        padding: 2rem 5vw;
    }
}
