/* ===================================
   haskell.day - Functional Toybox
   Candy-bright, bento-box layout
   =================================== */

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

:root {
    --pink: #FF6B9D;
    --teal: #06D6A0;
    --yellow: #FFD166;
    --lavender: #C084FC;
    --cream: #FFF5F0;
    --plum: #2D1B3D;
    --grape: #6B5B7B;
    --coral: #FF8A5C;

    --pink-tint: rgba(255, 107, 157, 0.08);
    --teal-tint: rgba(6, 214, 160, 0.08);
    --yellow-tint: rgba(255, 209, 102, 0.08);
    --lavender-tint: rgba(192, 132, 252, 0.08);
    --coral-tint: rgba(255, 138, 92, 0.08);

    --bounce: cubic-bezier(0.34, 1.56, 0.64, 1);
    --font-display: 'Nunito', sans-serif;
    --font-body: 'Quicksand', sans-serif;
    --font-code: 'Comfortaa', cursive;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-body);
    font-weight: 400;
    font-size: clamp(1rem, 1.8vw, 1.15rem);
    line-height: 1.7;
    letter-spacing: 0.01em;
    color: var(--plum);
    background-color: var(--cream);
    overflow-x: hidden;
}

h1, h2, h3, h4 {
    font-family: var(--font-display);
    font-weight: 800;
    letter-spacing: -0.01em;
    line-height: 1.15;
    color: var(--plum);
}

h2 {
    font-size: clamp(1.6rem, 3.5vw, 2.8rem);
    margin-bottom: 0.6em;
}

h3 {
    font-size: clamp(1.2rem, 2.5vw, 1.8rem);
    margin-bottom: 0.5em;
}

p {
    margin-bottom: 0.8em;
}

a {
    text-decoration: none;
    color: inherit;
}

/* --- Hero Section --- */
.hero {
    position: relative;
    width: 100%;
    height: 100vh;
    min-height: 600px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #FF6B9D 0%, #C084FC 100%);
    overflow: hidden;
}

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

.hero-lambdas .floating-lambda {
    position: absolute;
    font-family: var(--font-code);
    color: rgba(255, 255, 255, 0.15);
    pointer-events: none;
    will-change: transform;
}

.hero-content {
    position: relative;
    z-index: 2;
    text-align: center;
    padding: 0 24px;
}

.hero-title {
    font-family: var(--font-display);
    font-weight: 800;
    font-size: clamp(3rem, 8vw, 7rem);
    color: #fff;
    text-shadow: 0 4px 16px rgba(45, 27, 61, 0.2);
    opacity: 0;
    transform: translateY(40px);
    animation: hero-bounce-in 600ms var(--bounce) 200ms forwards;
}

.hero-tagline {
    font-family: var(--font-body);
    font-weight: 500;
    font-size: clamp(1.1rem, 2.5vw, 1.6rem);
    color: #fff;
    text-shadow: 0 2px 8px rgba(45, 27, 61, 0.15);
    opacity: 0;
    animation: fade-in 400ms ease-out 1100ms forwards;
    margin-top: 16px;
}

@keyframes hero-bounce-in {
    0% {
        opacity: 0;
        transform: translateY(40px);
    }
    100% {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fade-in {
    0% {
        opacity: 0;
    }
    100% {
        opacity: 1;
    }
}

/* Scroll Indicator */
.scroll-indicator {
    position: absolute;
    bottom: 40px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 2;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    cursor: pointer;
    opacity: 0;
    animation: fade-in 400ms ease-out 1800ms forwards;
}

.chevron {
    display: block;
    width: 20px;
    height: 20px;
    border-right: 3px solid rgba(255, 255, 255, 0.6);
    border-bottom: 3px solid rgba(255, 255, 255, 0.6);
    transform: rotate(45deg);
    animation: chevron-pulse 1.5s ease-in-out infinite;
}

.chevron:nth-child(2) {
    animation-delay: 0.15s;
}

.chevron:nth-child(3) {
    animation-delay: 0.3s;
}

@keyframes chevron-pulse {
    0%, 100% {
        transform: rotate(45deg) translateY(0);
        opacity: 0.6;
    }
    50% {
        transform: rotate(45deg) translateY(8px);
        opacity: 0.3;
    }
}

/* --- Floating Lambda Animation --- */
@keyframes float-lambda {
    0%, 100% { transform: translateY(0) rotate(0deg); }
    25% { transform: translateY(-18px) rotate(5deg); }
    50% { transform: translateY(-8px) rotate(-3deg); }
    75% { transform: translateY(-22px) rotate(7deg); }
}

@keyframes float-lambda-alt {
    0%, 100% { transform: translateY(0) rotate(0deg); }
    25% { transform: translateY(-14px) rotate(-4deg); }
    50% { transform: translateY(-24px) rotate(6deg); }
    75% { transform: translateY(-10px) rotate(-2deg); }
}

@keyframes float-lambda-slow {
    0%, 100% { transform: translateY(0) rotate(0deg); }
    33% { transform: translateY(-20px) rotate(8deg); }
    66% { transform: translateY(-12px) rotate(-5deg); }
}

/* --- Bento Grid --- */
.bento-grid {
    display: grid;
    grid-template-columns: repeat(6, 1fr);
    gap: 16px;
    padding: 16px;
    max-width: 1400px;
    margin: 0 auto;
}

/* --- Bento Cells --- */
.bento-cell {
    border-radius: 24px;
    overflow: hidden;
    position: relative;
    opacity: 0;
    transform: scale(0.85) translateY(24px);
    transition: opacity 500ms ease-out, transform 600ms var(--bounce);
}

.bento-cell.visible {
    opacity: 1;
    transform: scale(1) translateY(0);
}

.bento-cell:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 24px rgba(45, 27, 61, 0.12);
    transition: transform 300ms var(--bounce), box-shadow 300ms ease;
}

.bento-cell.visible:hover {
    transform: scale(1) translateY(-4px);
}

.cell-inner {
    padding: 32px;
    height: 100%;
    display: flex;
    flex-direction: column;
}

/* Cell Lambda decorations */
.cell-lambda {
    position: absolute;
    font-family: var(--font-code);
    pointer-events: none;
    z-index: 0;
}

.cl-1 {
    top: 12%;
    right: 8%;
    font-size: 48px;
    color: rgba(255, 255, 255, 0.2);
    animation: float-lambda 10s ease-in-out infinite;
}

.cl-2 {
    bottom: 15%;
    left: 5%;
    font-size: 32px;
    color: rgba(255, 255, 255, 0.12);
    animation: float-lambda-alt 13s ease-in-out infinite;
}

.cl-3 {
    top: 8%;
    left: 10%;
    font-size: 40px;
    color: rgba(255, 255, 255, 0.18);
    animation: float-lambda-slow 11s ease-in-out infinite;
}

.cl-4 {
    bottom: 10%;
    right: 6%;
    font-size: 36px;
    color: rgba(45, 27, 61, 0.1);
    animation: float-lambda 14s ease-in-out infinite;
}

.cl-5 {
    top: 6%;
    right: 12%;
    font-size: 52px;
    color: rgba(255, 255, 255, 0.15);
    animation: float-lambda-alt 9s ease-in-out infinite;
}

.cl-6 {
    bottom: 20%;
    left: 8%;
    font-size: 28px;
    color: rgba(255, 255, 255, 0.1);
    animation: float-lambda 16s ease-in-out infinite;
}

.cl-7 {
    top: 10%;
    right: 3%;
    font-size: 60px;
    color: rgba(45, 27, 61, 0.06);
    animation: float-lambda-slow 12s ease-in-out infinite;
}

.cl-8 {
    bottom: 5%;
    left: 2%;
    font-size: 44px;
    color: rgba(45, 27, 61, 0.05);
    animation: float-lambda-alt 15s ease-in-out infinite;
}

.cl-9 {
    top: 15%;
    left: 5%;
    font-size: 38px;
    color: rgba(255, 255, 255, 0.15);
    animation: float-lambda 11s ease-in-out infinite;
}

.cl-10 {
    bottom: 8%;
    right: 10%;
    font-size: 56px;
    color: rgba(255, 255, 255, 0.1);
    animation: float-lambda-slow 14s ease-in-out infinite;
}

.cl-11 {
    top: 12%;
    right: 4%;
    font-size: 46px;
    color: rgba(255, 255, 255, 0.18);
    animation: float-lambda-alt 10s ease-in-out infinite;
}

/* --- Feature Cells --- */
.feature-type-safety {
    grid-column: span 3;
    min-height: 380px;
    background-color: var(--pink);
    color: #fff;
    box-shadow: 0 2px 8px rgba(45, 27, 61, 0.06);
}

.feature-type-safety h2,
.feature-type-safety p {
    color: #fff;
}

.feature-pure-functions {
    grid-column: span 2;
    min-height: 380px;
    background-color: var(--teal);
    color: #fff;
    box-shadow: 0 2px 8px rgba(45, 27, 61, 0.06);
}

.feature-pure-functions h2,
.feature-pure-functions p {
    color: #fff;
}

.accent-snippet-1 {
    grid-column: span 1;
    min-height: 380px;
    background-color: var(--plum);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 8px rgba(45, 27, 61, 0.06);
}

.accent-snippet-1 .cell-inner {
    justify-content: center;
    align-items: center;
}

.feature-lazy-eval {
    grid-column: span 2;
    min-height: 360px;
    background-color: var(--yellow);
    color: var(--plum);
    box-shadow: 0 2px 8px rgba(45, 27, 61, 0.06);
}

.feature-pattern-match {
    grid-column: span 4;
    min-height: 360px;
    background-color: var(--lavender);
    color: #fff;
    box-shadow: 0 2px 8px rgba(45, 27, 61, 0.06);
}

.feature-pattern-match h2,
.feature-pattern-match p {
    color: #fff;
}

/* --- Dot Separator Cell --- */
.dot-separator-cell {
    grid-column: span 6;
    background: transparent;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 24px 0;
    box-shadow: none;
}

.dot-separator-cell:hover {
    box-shadow: none;
    transform: none;
}

.dot-separator-cell.visible:hover {
    transform: scale(1) translateY(0);
}

.bouncing-dots {
    display: flex;
    gap: 16px;
    align-items: center;
}

.dot {
    width: 14px;
    height: 14px;
    border-radius: 50%;
    display: inline-block;
}

.dot-pink {
    background-color: var(--pink);
    animation: dot-bounce 1.2s ease-in-out infinite;
}

.dot-teal {
    background-color: var(--teal);
    animation: dot-bounce 1.2s ease-in-out infinite 0.1s;
}

.dot-yellow {
    background-color: var(--yellow);
    animation: dot-bounce 1.2s ease-in-out infinite 0.2s;
}

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

/* --- Narrative Cell --- */
.narrative-cell {
    grid-column: span 6;
    min-height: 400px;
    background-color: #fff;
    border: 2px solid rgba(45, 27, 61, 0.06);
    box-shadow: 0 2px 8px rgba(45, 27, 61, 0.06);
}

.narrative-inner {
    display: flex;
    gap: 40px;
    align-items: center;
}

.narrative-illustration {
    flex: 0 0 40%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.narrative-scene {
    position: relative;
    width: 240px;
    height: 240px;
}

.big-lambda {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-family: var(--font-code);
    font-size: 120px;
    color: var(--lavender);
    opacity: 0.3;
    animation: float-lambda-slow 10s ease-in-out infinite;
}

.scene-box {
    position: absolute;
    border-radius: 12px;
}

.scene-box-1 {
    width: 60px;
    height: 60px;
    background: var(--pink);
    top: 20px;
    left: 20px;
    animation: float-lambda 8s ease-in-out infinite;
}

.scene-box-2 {
    width: 45px;
    height: 45px;
    background: var(--teal);
    bottom: 40px;
    left: 60px;
    animation: float-lambda-alt 11s ease-in-out infinite;
}

.scene-box-3 {
    width: 50px;
    height: 50px;
    background: var(--yellow);
    top: 40px;
    right: 20px;
    animation: float-lambda-slow 9s ease-in-out infinite;
}

.scene-arrow {
    position: absolute;
    bottom: 20px;
    right: 40px;
    width: 40px;
    height: 4px;
    background: var(--coral);
    border-radius: 2px;
}

.scene-arrow::after {
    content: '';
    position: absolute;
    right: -6px;
    top: -5px;
    width: 14px;
    height: 14px;
    border-right: 4px solid var(--coral);
    border-top: 4px solid var(--coral);
    transform: rotate(45deg);
    border-radius: 2px;
}

.scene-sparkle {
    position: absolute;
    font-size: 20px;
    opacity: 0.6;
}

.sparkle-1 {
    top: 10px;
    right: 10px;
    animation: float-lambda 7s ease-in-out infinite;
}

.sparkle-2 {
    bottom: 10px;
    left: 10px;
    animation: float-lambda-alt 9s ease-in-out infinite;
}

.sparkle-3 {
    top: 50%;
    right: 0;
    animation: float-lambda-slow 11s ease-in-out infinite;
}

.narrative-text {
    flex: 1;
}

.narrative-text h2 {
    color: var(--pink);
}

.narrative-text em {
    color: var(--lavender);
    font-style: italic;
}

/* --- Accent Cells --- */
.accent-funfact {
    grid-column: span 2;
    background: linear-gradient(135deg, rgba(192, 132, 252, 0.12), rgba(255, 107, 157, 0.08));
    border: 2px solid rgba(192, 132, 252, 0.15);
    box-shadow: 0 2px 8px rgba(45, 27, 61, 0.06);
}

.fun-fact {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 12px;
}

.fun-fact-icon {
    font-size: 36px;
}

.fun-fact p {
    font-size: 0.95rem;
    color: var(--grape);
    line-height: 1.6;
}

.accent-snippet-2 {
    grid-column: span 3;
    background-color: var(--plum);
    box-shadow: 0 4px 16px rgba(45, 27, 61, 0.2);
}

.accent-snippet-3 {
    grid-column: span 1;
    background-color: var(--plum);
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 8px rgba(45, 27, 61, 0.06);
}

.accent-snippet-3 .cell-inner {
    justify-content: center;
    align-items: center;
}

/* Code Blocks */
.code-block {
    background: var(--plum);
    border-radius: 16px;
    padding: 0;
    overflow: hidden;
}

.code-block-header {
    display: flex;
    gap: 8px;
    padding: 12px 16px;
    background: rgba(255, 255, 255, 0.06);
}

.code-dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
}

.cd-1 { background: var(--pink); }
.cd-2 { background: var(--yellow); }
.cd-3 { background: var(--teal); }

.code-block pre {
    padding: 16px 20px 20px;
    margin: 0;
    overflow-x: auto;
}

.code-block code {
    font-family: monospace;
    font-size: 0.9rem;
    line-height: 1.6;
    color: #fff;
}

.code-snippet {
    text-align: center;
}

.code-snippet code {
    font-family: var(--font-code);
    font-size: clamp(0.85rem, 1.5vw, 1.1rem);
    color: #fff;
    display: block;
    margin-bottom: 8px;
}

.mini-snippet code {
    font-size: clamp(0.75rem, 1.2vw, 0.95rem);
}

.code-result {
    margin-top: 4px;
}

/* Syntax colors */
.kw { color: var(--pink); }
.fn { color: var(--teal); }
.type { color: var(--yellow); }
.num { color: var(--coral); }
.comment { color: var(--grape); opacity: 0.7; }

/* --- Community Cell --- */
.community-cell {
    grid-column: span 3;
    background: linear-gradient(135deg, rgba(255, 107, 157, 0.1), rgba(192, 132, 252, 0.08));
    border: 2px solid rgba(255, 107, 157, 0.12);
    box-shadow: 0 2px 8px rgba(45, 27, 61, 0.06);
}

.community-cell h2 {
    color: var(--pink);
}

.pill-buttons {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 16px;
}

.pill-btn {
    display: inline-block;
    padding: 10px 22px;
    border-radius: 9999px;
    font-family: var(--font-display);
    font-weight: 700;
    font-size: 0.9rem;
    color: #fff;
    transition: transform 300ms var(--bounce), box-shadow 300ms ease;
    cursor: pointer;
}

.pill-btn:hover {
    transform: scale(1.06);
    box-shadow: 0 4px 12px rgba(45, 27, 61, 0.15);
}

.pill-pink { background-color: var(--pink); }
.pill-teal { background-color: var(--teal); }
.pill-yellow { background-color: var(--yellow); color: var(--plum); }
.pill-lavender { background-color: var(--lavender); }
.pill-coral { background-color: var(--coral); }

/* --- Monad Cell --- */
.accent-monad {
    grid-column: span 3;
    background: linear-gradient(135deg, rgba(255, 138, 92, 0.1), rgba(255, 209, 102, 0.08));
    border: 2px solid rgba(255, 138, 92, 0.12);
    box-shadow: 0 2px 8px rgba(45, 27, 61, 0.06);
}

.monad-visual {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 20px;
    flex-wrap: wrap;
}

.monad-box {
    padding: 12px 20px;
    border-radius: 16px;
    font-family: var(--font-display);
    font-weight: 700;
    font-size: 1.1rem;
    color: #fff;
}

.mb-1 { background: var(--lavender); }
.mb-2 { background: var(--teal); }
.mb-3 { background: var(--pink); }

.monad-arrow {
    font-size: 1.5rem;
    color: var(--grape);
}

/* --- Quote Cell --- */
.accent-quote {
    grid-column: span 3;
    background: linear-gradient(135deg, rgba(255, 209, 102, 0.15), rgba(255, 138, 92, 0.08));
    border: 2px solid rgba(255, 209, 102, 0.15);
    display: flex;
    align-items: center;
    box-shadow: 0 2px 8px rgba(45, 27, 61, 0.06);
}

.accent-quote .cell-inner {
    justify-content: center;
}

.accent-quote blockquote p {
    font-family: var(--font-display);
    font-weight: 800;
    font-size: clamp(1.3rem, 2.5vw, 2rem);
    color: var(--plum);
    line-height: 1.3;
}

.accent-quote cite {
    display: block;
    margin-top: 12px;
    font-size: 0.9rem;
    color: var(--grape);
    font-style: normal;
}

/* --- Getting Started Cell --- */
.getting-started-cell {
    grid-column: span 6;
    background: linear-gradient(135deg, rgba(6, 214, 160, 0.08), rgba(192, 132, 252, 0.06));
    border: 2px solid rgba(6, 214, 160, 0.12);
    box-shadow: 0 2px 8px rgba(45, 27, 61, 0.06);
}

.getting-started-cell h2 {
    color: var(--teal);
}

.steps-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
    margin-top: 16px;
}

.step {
    background: #fff;
    border-radius: 20px;
    padding: 28px;
    box-shadow: 0 2px 8px rgba(45, 27, 61, 0.06);
    transition: transform 300ms var(--bounce), box-shadow 300ms ease;
}

.step:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 24px rgba(45, 27, 61, 0.1);
}

.step-number {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: var(--font-display);
    font-weight: 800;
    font-size: 1.2rem;
    color: #fff;
    margin-bottom: 16px;
}

.step:nth-child(1) .step-number { background: var(--pink); }
.step:nth-child(2) .step-number { background: var(--teal); }
.step:nth-child(3) .step-number { background: var(--lavender); }

.step h3 {
    font-size: 1.2rem;
    color: var(--plum);
}

.step p {
    font-size: 0.95rem;
    color: var(--grape);
    margin-bottom: 0;
}

/* --- Illustrations --- */

/* Type Safety Illustration */
.illustration-type-safety {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 16px;
    margin-bottom: 20px;
}

.peg-board {
    display: flex;
    gap: 20px;
}

.hole {
    width: 48px;
    height: 48px;
    border: 4px solid rgba(255, 255, 255, 0.5);
    display: flex;
    align-items: center;
    justify-content: center;
}

.hole-circle {
    border-radius: 50%;
}

.hole-square {
    border-radius: 8px;
}

.hole-triangle {
    width: 0;
    height: 0;
    border: none;
    border-left: 26px solid transparent;
    border-right: 26px solid transparent;
    border-bottom: 48px solid rgba(255, 255, 255, 0.3);
}

.pegs {
    display: flex;
    gap: 20px;
}

.peg {
    animation: float-lambda 4s ease-in-out infinite;
}

.peg-circle {
    width: 36px;
    height: 36px;
    background: var(--yellow);
    border-radius: 50%;
    box-shadow: 0 4px 8px rgba(45, 27, 61, 0.15);
}

.peg-square {
    width: 36px;
    height: 36px;
    background: var(--teal);
    border-radius: 6px;
    box-shadow: 0 4px 8px rgba(45, 27, 61, 0.15);
    animation-delay: 0.5s;
}

.peg-triangle {
    width: 0;
    height: 0;
    border-left: 20px solid transparent;
    border-right: 20px solid transparent;
    border-bottom: 36px solid var(--lavender);
    filter: drop-shadow(0 4px 8px rgba(45, 27, 61, 0.15));
    animation-delay: 1s;
}

/* Pure Functions Illustration */
.illustration-pure-functions {
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 20px;
}

.pure-box {
    display: flex;
    align-items: center;
    gap: 12px;
}

.box-face {
    width: 80px;
    height: 80px;
    background: rgba(255, 255, 255, 0.25);
    border-radius: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 36px;
    box-shadow: 0 4px 12px rgba(45, 27, 61, 0.1);
}

.arrow {
    width: 40px;
    height: 4px;
    background: rgba(255, 255, 255, 0.6);
    border-radius: 2px;
    position: relative;
}

.arrow-in::before {
    content: '';
    position: absolute;
    right: -1px;
    top: -5px;
    width: 14px;
    height: 14px;
    border-right: 3px solid rgba(255, 255, 255, 0.6);
    border-top: 3px solid rgba(255, 255, 255, 0.6);
    transform: rotate(45deg);
}

.arrow-out::after {
    content: '';
    position: absolute;
    right: -1px;
    top: -5px;
    width: 14px;
    height: 14px;
    border-right: 3px solid rgba(255, 255, 255, 0.6);
    border-top: 3px solid rgba(255, 255, 255, 0.6);
    transform: rotate(45deg);
}

/* Lazy Evaluation Illustration */
.illustration-lazy {
    margin-bottom: 20px;
}

.hammock-scene {
    display: flex;
    align-items: flex-end;
    justify-content: center;
    gap: 0;
    position: relative;
    height: 100px;
}

.post {
    width: 8px;
    height: 80px;
    background: var(--plum);
    border-radius: 4px;
    opacity: 0.4;
}

.hammock {
    width: 100px;
    height: 50px;
    border-bottom: 4px solid var(--plum);
    border-left: 4px solid var(--plum);
    border-right: 4px solid var(--plum);
    border-radius: 0 0 50% 50%;
    opacity: 0.4;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 -4px;
    align-self: center;
}

.hammock-character {
    font-size: 28px;
    margin-top: 10px;
}

.task-bubbles {
    display: flex;
    justify-content: center;
    gap: 10px;
    margin-top: 12px;
}

.task-bubble {
    background: rgba(45, 27, 61, 0.1);
    border-radius: 9999px;
    padding: 4px 14px;
    font-family: var(--font-display);
    font-weight: 700;
    font-size: 0.75rem;
    color: var(--plum);
    opacity: 0.6;
}

.tb-1 { animation: float-lambda 6s ease-in-out infinite; }
.tb-2 { animation: float-lambda-alt 8s ease-in-out infinite 0.5s; }
.tb-3 { animation: float-lambda-slow 7s ease-in-out infinite 1s; }

/* Pattern Matching Illustration */
.illustration-pattern {
    margin-bottom: 20px;
}

.flowchart {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
}

.flow-start {
    width: 24px;
    height: 24px;
    background: #fff;
    border-radius: 50%;
    opacity: 0.8;
}

.flow-branches {
    display: flex;
    gap: 16px;
}

.flow-branch {
    width: 60px;
    height: 8px;
    border-radius: 4px;
}

.branch-pink { background: var(--pink); opacity: 0.8; }
.branch-teal { background: var(--teal); opacity: 0.8; }
.branch-yellow { background: var(--yellow); opacity: 0.8; }

.flow-end {
    font-size: 28px;
    color: var(--yellow);
}

/* --- Footer --- */
.site-footer {
    padding: 48px 24px;
    text-align: center;
    background: var(--cream);
}

.footer-content {
    max-width: 600px;
    margin: 0 auto;
}

.footer-lambda {
    font-family: var(--font-code);
    font-size: 48px;
    color: var(--lavender);
    opacity: 0.4;
    display: block;
    margin-bottom: 16px;
}

.footer-content p {
    font-family: var(--font-body);
    font-weight: 500;
    color: var(--grape);
    font-size: 0.95rem;
}

.footer-dots {
    display: flex;
    justify-content: center;
    gap: 10px;
    margin-top: 20px;
}

.footer-dots .dot {
    width: 10px;
    height: 10px;
    animation: none;
}

/* --- Responsive --- */
@media (max-width: 1024px) {
    .bento-grid {
        grid-template-columns: repeat(4, 1fr);
    }

    .feature-type-safety {
        grid-column: span 2;
    }

    .feature-pure-functions {
        grid-column: span 2;
    }

    .accent-snippet-1 {
        grid-column: span 4;
        min-height: auto;
    }

    .feature-lazy-eval {
        grid-column: span 2;
    }

    .feature-pattern-match {
        grid-column: span 2;
    }

    .dot-separator-cell {
        grid-column: span 4;
    }

    .narrative-cell {
        grid-column: span 4;
    }

    .accent-funfact {
        grid-column: span 2;
    }

    .accent-snippet-2 {
        grid-column: span 2;
    }

    .accent-snippet-3 {
        grid-column: span 4;
        min-height: auto;
    }

    .community-cell {
        grid-column: span 4;
    }

    .accent-monad {
        grid-column: span 2;
    }

    .accent-quote {
        grid-column: span 2;
    }

    .getting-started-cell {
        grid-column: span 4;
    }

    .narrative-inner {
        flex-direction: column;
    }

    .narrative-illustration {
        flex: none;
    }

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

@media (max-width: 640px) {
    .bento-grid {
        grid-template-columns: 1fr;
        padding: 12px;
        gap: 12px;
    }

    .feature-type-safety,
    .feature-pure-functions,
    .accent-snippet-1,
    .feature-lazy-eval,
    .feature-pattern-match,
    .dot-separator-cell,
    .narrative-cell,
    .accent-funfact,
    .accent-snippet-2,
    .accent-snippet-3,
    .community-cell,
    .accent-monad,
    .accent-quote,
    .getting-started-cell {
        grid-column: span 1;
        min-height: auto;
    }

    .hero-title {
        font-size: clamp(2.5rem, 12vw, 4rem);
    }

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

    .monad-visual {
        justify-content: center;
    }
}
