/* lugubrious.dev - Retro-futuristic melancholy */

:root {
    --cream: #faf3e6;
    --parchment: #f4e8d0;
    --saffron: #d4a24e;
    --terracotta: #c4703a;
    --teal: #5a8f8b;
    --plum: #6b3244;
    --espresso: #2b1d14;
    --leather: #9c7b5e;
}

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

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Lora', serif;
    background-color: var(--cream);
    color: var(--espresso);
    overflow-x: hidden;
}

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

.section__inner {
    max-width: 900px;
    width: 90%;
    margin: 0 auto;
    padding: 4rem 2rem;
}

.section__heading {
    font-family: 'Commissioner', sans-serif;
    font-weight: 700;
    font-size: clamp(2.8rem, 7vw, 6rem);
    letter-spacing: -0.01em;
    line-height: 1.08;
    text-transform: uppercase;
    color: var(--espresso);
    margin-bottom: 1.5rem;
}

.section__text {
    font-family: 'Lora', serif;
    font-size: clamp(1.1rem, 2.5vw, 1.4rem);
    line-height: 1.7;
    color: var(--espresso);
    max-width: 600px;
}

/* HERO */
.section--hero {
    background: linear-gradient(to bottom, var(--saffron), var(--parchment));
    flex-direction: column;
}

.hero__cityscape {
    position: absolute;
    inset: 0;
    z-index: 1;
}

.hero__svg {
    width: 100%;
    height: 100%;
}

.hero__content {
    position: relative;
    z-index: 2;
    text-align: center;
    padding: 2rem;
}

.hero__title {
    font-family: 'Commissioner', sans-serif;
    font-weight: 700;
    font-size: clamp(4rem, 12vw, 10rem);
    letter-spacing: -0.01em;
    line-height: 1;
    text-transform: uppercase;
    color: var(--cream);
    text-shadow: 0 4px 20px rgba(43, 29, 20, 0.3);
    margin-bottom: 1rem;
}

.hero__subtitle {
    font-family: 'Lora', serif;
    font-style: italic;
    font-size: clamp(1rem, 2.5vw, 1.5rem);
    color: var(--cream);
    max-width: 500px;
    margin: 0 auto;
    text-shadow: 0 2px 8px rgba(43, 29, 20, 0.2);
}

.hero__scroll-hint {
    position: absolute;
    bottom: 2rem;
    left: 50%;
    transform: translateX(-50%);
    z-index: 2;
    color: var(--cream);
    animation: bounce 2s infinite;
}

@keyframes bounce {
    0%, 100% { transform: translateX(-50%) translateY(0); }
    50% { transform: translateX(-50%) translateY(10px); }
}

/* DEFINITION */
.section--definition {
    background-color: var(--cream);
}

.section--definition .section__inner {
    display: flex;
    align-items: center;
    gap: 4rem;
    flex-wrap: wrap;
    justify-content: center;
}

.definition__card {
    flex: 1;
    min-width: 280px;
    background: var(--parchment);
    border-radius: 20px;
    padding: 3rem;
    border: 2px solid var(--leather);
}

.definition__pos {
    font-family: 'Commissioner', sans-serif;
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.15em;
    color: var(--teal);
    display: block;
    margin-bottom: 0.5rem;
}

.definition__word {
    font-family: 'Commissioner', sans-serif;
    font-weight: 700;
    font-size: clamp(2rem, 5vw, 3.5rem);
    color: var(--espresso);
    margin-bottom: 0.25rem;
}

.definition__phonetic {
    font-family: 'Lora', serif;
    font-style: italic;
    color: var(--leather);
    margin-bottom: 1.5rem;
}

.definition__meaning {
    font-family: 'Lora', serif;
    font-size: 1.15rem;
    line-height: 1.7;
    color: var(--espresso);
    margin-bottom: 1rem;
}

.definition__origin {
    font-family: 'Lora', serif;
    font-size: 0.9rem;
    color: var(--leather);
    font-style: italic;
}

.definition__illustration {
    flex: 0 0 200px;
}

.illustration--weeping-robot {
    width: 200px;
    height: 200px;
}

.tear {
    animation: tearDrop 2.5s infinite;
}

.tear--right {
    animation-delay: 1s;
}

@keyframes tearDrop {
    0% { opacity: 0; transform: translateY(0); }
    50% { opacity: 1; }
    100% { opacity: 0; transform: translateY(10px); }
}

/* IRONY */
.section--irony {
    background: var(--espresso);
}

.section--irony .section__heading {
    color: var(--saffron);
}

.section--irony .section__text {
    color: var(--parchment);
    margin-bottom: 3rem;
}

.irony__panels {
    display: flex;
    gap: 3rem;
    flex-wrap: wrap;
    justify-content: center;
}

.irony__panel {
    text-align: center;
    padding: 2rem;
    border-radius: 16px;
    min-width: 180px;
}

.irony__panel--expect {
    background: rgba(250, 243, 230, 0.05);
    border: 1px solid var(--leather);
}

.irony__panel--get {
    background: rgba(212, 162, 78, 0.1);
    border: 1px solid var(--saffron);
}

.panel__icon svg {
    width: 80px;
    height: 80px;
    margin-bottom: 1rem;
}

.panel__label {
    font-family: 'Commissioner', sans-serif;
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--parchment);
}

/* GALLERY */
.section--gallery {
    background: var(--parchment);
}

.gallery__grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 2.5rem;
    margin-top: 2rem;
}

.gallery__item {
    text-align: center;
    padding: 2rem;
    background: var(--cream);
    border-radius: 20px;
    border: 2px solid transparent;
    transition: border-color 0.3s, transform 0.3s;
}

.gallery__item:hover {
    border-color: var(--saffron);
    transform: translateY(-4px);
}

.gallery__illustration {
    width: 160px;
    height: 160px;
    margin-bottom: 1rem;
}

.gallery__caption {
    font-family: 'Commissioner', sans-serif;
    font-size: 0.9rem;
    font-weight: 700;
    color: var(--espresso);
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

/* FOOTER */
.section--footer {
    min-height: auto;
    padding: 4rem 0;
    background: var(--espresso);
    text-align: center;
}

.footer__text {
    font-family: 'Lora', serif;
    font-style: italic;
    color: var(--parchment);
    font-size: 1.1rem;
    margin-bottom: 1.5rem;
}

.footer__ornament {
    display: flex;
    justify-content: center;
}

.ornament__svg {
    width: 200px;
    height: 30px;
    opacity: 0.6;
}

/* SCROLL ANIMATIONS */
.section__inner,
.definition__card,
.definition__illustration,
.irony__panel,
.gallery__item {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.8s ease, transform 0.8s ease;
}

.section__inner.visible,
.definition__card.visible,
.definition__illustration.visible,
.irony__panel.visible,
.gallery__item.visible {
    opacity: 1;
    transform: translateY(0);
}

/* Stagger gallery items */
.gallery__item:nth-child(2) { transition-delay: 0.15s; }
.gallery__item:nth-child(3) { transition-delay: 0.3s; }

.irony__panel:nth-child(2) { transition-delay: 0.2s; }
