/* === RESET & BASE === */
*, *::before, *::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

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

body {
    font-family: 'IBM Plex Mono', monospace;
    font-weight: 400;
    font-size: clamp(0.95rem, 1.2vw, 1.15rem);
    line-height: 1.75;
    letter-spacing: 0.02em;
    color: #1a1714;
    background: #f0ebe3;
    overflow-x: hidden;
}

/* === TYPOGRAPHY === */
.display-text {
    font-family: 'Share Tech Mono', monospace;
    font-size: clamp(3rem, 8vw, 7rem);
    font-weight: 400;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    line-height: 1.1;
    color: #1a1714;
}

.graffiti-text {
    font-family: 'Permanent Marker', cursive;
    font-size: clamp(1.5rem, 4vw, 3.5rem);
    transform: rotate(-2deg);
    text-shadow: 2px 2px 8px rgba(230, 57, 70, 0.4);
    color: #e63946;
}

.body-text {
    font-family: 'IBM Plex Mono', monospace;
    font-weight: 300;
    font-size: clamp(0.95rem, 1.2vw, 1.15rem);
    line-height: 1.75;
    letter-spacing: 0.02em;
    color: #1a1714;
    max-width: 540px;
}

.light-text {
    color: #f0ebe3;
}

/* === BACKGROUNDS === */
.marble-bg {
    background:
        linear-gradient(135deg, rgba(240,235,227,0.9) 25%, rgba(140,133,120,0.15) 50%, rgba(240,235,227,0.85) 75%),
        repeating-linear-gradient(45deg, transparent, transparent 8px, rgba(140,133,120,0.06) 8px, rgba(140,133,120,0.06) 9px);
    background-color: #f0ebe3;
}

.concrete-bg {
    background:
        linear-gradient(160deg, #3d3a36 0%, #2a2825 50%, #3d3a36 100%),
        repeating-linear-gradient(90deg, transparent, transparent 4px, rgba(26,23,20,0.08) 4px, rgba(26,23,20,0.08) 5px);
    background-color: #3d3a36;
}

/* === LAYOUT === */
.full-section {
    min-height: 100vh;
    width: 100%;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

/* === HOME ANCHOR === */
#home-anchor {
    position: fixed;
    top: 24px;
    left: 24px;
    z-index: 100;
    display: block;
    line-height: 0;
    transform: rotate(-12deg);
    transition: transform 0.3s ease;
    text-decoration: none;
}

#home-anchor:hover {
    transform: rotate(0deg);
}

/* === SCROLL PROGRESS === */
#scroll-progress {
    position: fixed;
    bottom: 0;
    left: 0;
    height: 3px;
    width: 100%;
    z-index: 100;
    background: linear-gradient(135deg, #e63946, #6b4c8a);
    transform: scaleX(0);
    transform-origin: left;
    will-change: transform;
}

/* === SECTION 1: THE WALL === */
#the-wall {
    display: flex;
    align-items: center;
    justify-content: center;
}

.watermark-scale {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%) rotate(-8deg);
    opacity: 0.05;
    pointer-events: none;
}

.wall-grid {
    display: grid;
    grid-template-columns: repeat(8, 1fr);
    gap: 24px;
    width: 100%;
    max-width: 1400px;
    padding: 0 48px;
}

.wall-content {
    grid-column: 1 / 4;
}

.spray-text {
    font-family: 'Share Tech Mono', monospace;
    font-size: clamp(3rem, 8vw, 7rem);
    font-weight: 400;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    line-height: 1.05;
    color: #1a1714;
    display: flex;
    flex-direction: column;
}

.spray-word {
    display: inline-block;
    opacity: 0;
    filter: blur(8px);
    clip-path: inset(0 100% 0 0);
    animation: sprayReveal 0.8s ease-out forwards;
    animation-delay: calc(var(--delay) * 0.2s + 0.3s);
}

@keyframes sprayReveal {
    0% {
        opacity: 0;
        filter: blur(8px);
        clip-path: inset(0 100% 0 0);
    }
    50% {
        opacity: 0.7;
        filter: blur(3px);
    }
    100% {
        opacity: 1;
        filter: blur(0);
        clip-path: inset(0 0% 0 0);
    }
}

.wall-subtitle {
    margin-top: 24px;
    opacity: 0;
    animation: fadeIn 0.6s ease-out 0.9s forwards;
}

@keyframes fadeIn {
    to { opacity: 1; }
}

.column-fragment {
    position: absolute;
    pointer-events: none;
}

.column-left {
    right: 80px;
    bottom: 40px;
}

.column-path {
    transition: stroke-dashoffset 1.5s ease-out;
}

.column-path.revealed {
    stroke-dashoffset: 0 !important;
}

/* Spray paint radial gradient effect on THE WALL */
#the-wall::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: radial-gradient(ellipse at 30% 40%, rgba(230,57,70,0.06) 0%, transparent 60%);
    pointer-events: none;
}

/* === SECTION 2: THE FRACTURE === */
#the-fracture {
    display: flex;
    position: relative;
}

.crack-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 10;
    pointer-events: none;
}

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

.crack-line {
    transition: stroke-dashoffset 0.6s ease-out;
}

.crack-line.cracked {
    stroke-dashoffset: 0 !important;
}

.fracture-grid {
    display: flex;
    width: 100%;
    height: 100vh;
}

.fracture-left,
.fracture-right {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 48px;
}

.fracture-content {
    max-width: 440px;
}

.fracture-content .display-text {
    font-size: clamp(2rem, 5vw, 4rem);
    margin-bottom: 24px;
}

.graffiti-heading {
    font-size: clamp(2rem, 5vw, 4rem) !important;
    margin-bottom: 24px;
}

/* Marble center divider */
.fracture-grid::before {
    content: '';
    position: absolute;
    top: 10%;
    left: 50%;
    transform: translateX(-50%);
    width: 2px;
    height: 80%;
    background: linear-gradient(to bottom, transparent, #8c8578, transparent);
    z-index: 5;
}

/* === UNDERLINE-DRAW ANIMATION === */
.underline-draw {
    background-image: linear-gradient(#e63946, #e63946);
    background-size: 0% 3px;
    background-repeat: no-repeat;
    background-position: 0 100%;
    padding-bottom: 4px;
    transition: background-size 0.6s ease-out;
    display: inline;
}

.underline-draw.active {
    background-size: 100% 3px;
}

/* === SECTION 3: THE ARCHIVE === */
#the-archive {
    width: 100%;
}

.archive-header {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    padding: 0 48px;
}

.archive-header-content {
    max-width: 500px;
    margin-right: 10%;
}

.archive-header .display-text {
    font-size: clamp(2.5rem, 6vw, 5rem);
    margin-bottom: 16px;
}

.archive-entry {
    min-height: 60vh;
    display: flex;
    align-items: center;
    padding: 80px 48px;
    position: relative;
}

.archive-entry::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: radial-gradient(ellipse at 70% 30%, rgba(230,57,70,0.04) 0%, transparent 50%);
    pointer-events: none;
}

.archive-grid {
    display: grid;
    grid-template-columns: repeat(8, 1fr);
    gap: 24px;
    width: 100%;
    max-width: 1400px;
    margin: 0 auto;
}

.archive-tag-area {
    grid-column: 1 / 3;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 16px;
}

.archive-number {
    font-size: clamp(3rem, 6vw, 5rem);
    opacity: 0.3;
    color: #c49a2a;
}

.archive-content {
    grid-column: 4 / 8;
}

.archive-title {
    font-size: clamp(1.8rem, 4vw, 3.5rem) !important;
    margin-bottom: 12px;
}

.archive-annotation {
    font-size: clamp(1.2rem, 2.5vw, 2rem) !important;
    margin-bottom: 20px;
    display: inline-block;
}

.concrete-bg .archive-content .body-text {
    color: #f0ebe3;
}

/* === SECTION 4: THE MIRROR === */
#the-mirror {
    position: relative;
    overflow: hidden;
}

.mirror-side {
    position: absolute;
    top: 0;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.mirror-left {
    z-index: 1;
    clip-path: inset(0 50% 0 0);
}

.mirror-right {
    z-index: 2;
    clip-path: inset(0 0 0 50%);
}

.mirror-content {
    max-width: 440px;
    text-align: center;
}

.mirror-content .display-text {
    font-size: clamp(1.5rem, 3vw, 2.5rem);
    margin-bottom: 16px;
}

.mirror-word {
    font-family: 'Share Tech Mono', monospace;
    font-size: clamp(4rem, 10vw, 9rem) !important;
    letter-spacing: 0.15em;
    text-transform: uppercase;
    line-height: 1;
    margin-bottom: 24px;
    color: #1a1714;
}

.mirror-word-graffiti {
    font-size: clamp(4rem, 10vw, 9rem) !important;
    letter-spacing: 0.05em;
    margin-bottom: 24px;
    display: block;
    transform: rotate(-3deg);
}

#mirror-divider {
    position: absolute;
    top: 0;
    left: 50%;
    width: 2px;
    height: 100%;
    background: linear-gradient(to bottom, #e63946, #6b4c8a);
    z-index: 10;
    pointer-events: none;
    transition: left 0.05s linear;
}

/* === RESPONSIVE === */
@media (max-width: 768px) {
    .wall-content {
        grid-column: 1 / -1;
    }

    .fracture-grid {
        flex-direction: column;
    }

    .fracture-left,
    .fracture-right {
        min-height: 50vh;
    }

    .fracture-grid::before {
        top: 50%;
        left: 10%;
        width: 80%;
        height: 2px;
        transform: translateY(-50%);
    }

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

    .archive-tag-area {
        grid-column: 1;
        flex-direction: row;
        align-items: center;
    }

    .archive-content {
        grid-column: 1;
    }

    .column-left {
        display: none;
    }

    .mirror-left {
        clip-path: inset(0 0 50% 0);
    }

    .mirror-right {
        clip-path: inset(50% 0 0 0);
    }

    #mirror-divider {
        top: 50%;
        left: 0;
        width: 100%;
        height: 2px;
    }
}
