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

html {
    scroll-behavior: smooth;
    overflow-x: hidden;
    /* palette: #e8e2db available for hover states */
}

body {
    background-color: #2d2a30;
    color: #e0d9d1;
    font-family: 'Inter', sans-serif;
    font-weight: 300;
    line-height: 1.7;
    overflow-x: hidden;
}

/* ===== WATERCOLOR SPLASHES ===== */
.watercolor-splash {
    position: absolute;
    pointer-events: none;
    z-index: 1;
    opacity: 0;
    transition: opacity 1.5s ease;
}

.watercolor-splash.visible {
    opacity: 1;
}

.splash-hero-1 {
    width: 400px;
    height: 350px;
    top: 10%;
    left: -5%;
    border-radius: 40% 60% 55% 45% / 50% 40% 60% 50%;
    background: radial-gradient(ellipse at 40% 50%, #9b87a3 0%, transparent 70%);
    filter: blur(50px);
    opacity: 0.2;
}

.splash-hero-2 {
    width: 300px;
    height: 280px;
    bottom: 15%;
    right: -3%;
    border-radius: 55% 45% 50% 50% / 40% 60% 40% 60%;
    background: radial-gradient(ellipse at 60% 40%, #6b5e6e 0%, transparent 70%);
    filter: blur(45px);
    opacity: 0.18;
}

.splash-passage-1 {
    width: 500px;
    height: 400px;
    top: 5%;
    right: -10%;
    border-radius: 45% 55% 60% 40% / 55% 45% 55% 45%;
    background: radial-gradient(ellipse at 50% 50%, #b5836e 0%, transparent 65%);
    filter: blur(60px);
    opacity: 0.15;
}

.splash-passage-2 {
    width: 350px;
    height: 300px;
    top: 55%;
    left: -8%;
    border-radius: 50% 50% 45% 55% / 60% 40% 55% 45%;
    background: radial-gradient(ellipse at 45% 55%, #9b87a3 0%, transparent 70%);
    filter: blur(55px);
    opacity: 0.15;
}

.splash-envelope {
    width: 450px;
    height: 350px;
    top: -10%;
    left: 50%;
    transform: translateX(-50%);
    border-radius: 40% 60% 50% 50% / 50% 50% 50% 50%;
    background: radial-gradient(ellipse at 50% 50%, #6b5e6e 0%, transparent 60%);
    filter: blur(50px);
    opacity: 0.2;
}

/* ===== HERO: THE WALL ===== */
.hero {
    position: relative;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    overflow: hidden;
}

.hero-texture {
    position: absolute;
    inset: 0;
    background:
        repeating-conic-gradient(#4a4347 0% 25%, transparent 0% 50%) 0 0 / 3px 3px,
        linear-gradient(180deg, #2d2a30 0%, #4a4347 100%);
    opacity: 0.3;
    z-index: 0;
}

.hero-title {
    font-family: 'Playfair Display', serif;
    font-weight: 900;
    font-size: clamp(4rem, 12vw, 10rem);
    letter-spacing: -0.03em;
    line-height: 0.9;
    text-transform: uppercase;
    color: #e0d9d1;
    position: relative;
    z-index: 2;
    text-align: center;
}

/* Stencil spray effect on title */
.hero-title[data-stencil] {
    background: linear-gradient(
        180deg,
        #e0d9d1 0%,
        #c4a882 40%,
        #b5836e 70%,
        #e0d9d1 100%
    );
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    text-shadow: none;
}

.hero-subtitle {
    font-family: 'Space Mono', monospace;
    font-weight: 400;
    font-size: clamp(0.75rem, 1.5vw, 1rem);
    letter-spacing: 0.35em;
    text-transform: uppercase;
    color: #8a7f85;
    margin-top: 1.5rem;
    position: relative;
    z-index: 2;
}

.stencil-drip {
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 2px;
    height: 0;
    background: linear-gradient(180deg, #b5836e, transparent);
    z-index: 2;
    transition: height 2s ease;
}

.stencil-drip.active {
    height: 80px;
}

/* ===== STENCIL STRIP ===== */
.stencil-strip {
    background: #b5836e;
    padding: 1rem 0;
    overflow: hidden;
    position: relative;
    z-index: 5;
    transform: rotate(-1deg) scaleX(1.05);
}

.strip-text {
    display: flex;
    gap: 2rem;
    white-space: nowrap;
    font-family: 'Playfair Display', serif;
    font-weight: 900;
    font-size: clamp(0.9rem, 2vw, 1.3rem);
    letter-spacing: 0.15em;
    color: #2d2a30;
    text-transform: uppercase;
    animation: marquee 20s linear infinite;
}

.strip-dot {
    opacity: 0.5;
}

@keyframes marquee {
    0% { transform: translateX(0); }
    100% { transform: translateX(-50%); }
}

/* ===== THE PASSAGE ===== */
.passage {
    position: relative;
    padding: 15vh 0;
    min-height: 200vh;
}

.passage-block {
    max-width: 550px;
    padding: 3rem 2rem;
    margin-bottom: 20vh;
    opacity: 0;
    transform: translateY(60px);
    transition: opacity 0.8s ease, transform 0.8s ease;
}

.passage-block.revealed {
    opacity: 1;
    transform: translateY(0) rotate(var(--block-rotate, 0deg));
}

.block-1 {
    margin-left: 10%;
    --block-rotate: -1.5deg;
}

.block-2 {
    margin-left: auto;
    margin-right: 10%;
    --block-rotate: 1deg;
}

.block-3 {
    margin-left: 15%;
    --block-rotate: -0.5deg;
}

.block-4 {
    margin-left: auto;
    margin-right: 8%;
    --block-rotate: 1.5deg;
}

.passage-block h2 {
    font-family: 'Playfair Display', serif;
    font-weight: 900;
    font-size: clamp(1.8rem, 4vw, 3rem);
    letter-spacing: -0.02em;
    line-height: 1;
    text-transform: uppercase;
    color: #c4a882;
    margin-bottom: 1.2rem;
}

.passage-block p {
    font-family: 'Inter', sans-serif;
    font-weight: 300;
    font-size: clamp(0.95rem, 1.3vw, 1.1rem);
    color: #b8b0a6;
    line-height: 1.8;
}

/* ===== THE ENVELOPE ===== */
.envelope {
    position: relative;
    min-height: 80vh;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 10vh 2rem;
}

.envelope-container {
    position: relative;
    width: 340px;
    height: 240px;
    opacity: 0;
    transform: translateY(40px);
    transition: opacity 1s ease, transform 1s ease;
}

.envelope-container.revealed {
    opacity: 1;
    transform: translateY(0);
}

.envelope-body {
    width: 100%;
    height: 100%;
    background: #4a4347;
    border: 1px solid #6b5e6e;
    border-radius: 4px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    position: relative;
    overflow: hidden;
}

.envelope-flap {
    position: absolute;
    top: -1px;
    left: 0;
    right: 0;
    height: 80px;
    background: #4a4347;
    border: 1px solid #6b5e6e;
    border-bottom: none;
    clip-path: polygon(0 100%, 50% 0, 100% 100%);
    z-index: 3;
    transform-origin: top center;
    transition: transform 0.8s ease;
}

.envelope-container.revealed .envelope-flap {
    transform: rotateX(180deg);
}

.envelope-seal {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: radial-gradient(circle at 40% 40%, #b5836e, #8a5a48);
    position: absolute;
    top: 15px;
    z-index: 2;
}

.envelope-text {
    font-family: 'Space Mono', monospace;
    font-size: 0.8rem;
    letter-spacing: 0.05em;
    color: #8a7f85;
    text-align: center;
    line-height: 1.8;
    margin-top: 30px;
}

/* ===== FOOTER WALL ===== */
.footer-wall {
    padding: 8vh 2rem 4vh;
    display: flex;
    justify-content: center;
}

.footer-tag {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
}

.tag-mono {
    font-family: 'Space Mono', monospace;
    font-weight: 700;
    font-size: 0.75rem;
    letter-spacing: 0.3em;
    text-transform: uppercase;
    color: #6b5e6e;
}

.tag-year {
    font-family: 'Inter', sans-serif;
    font-weight: 300;
    font-size: 0.7rem;
    color: #4a4347;
}

/* Hover highlight using full palette */
.passage-block h2:hover {
    color: #e8e2db;
}

/* ===== RESPONSIVE ===== */
@media (max-width: 768px) {
    .passage-block {
        max-width: 90%;
        margin-left: 5% !important;
        margin-right: 5% !important;
    }

    .envelope-container {
        width: 280px;
        height: 200px;
    }
}
