:root {
    --void: #0D0D0D;
    --midnight: #1A1520;
    --humus: #1E1A22;
    --plum: #2A1F30;
    --cream: #FFF5E4;
    --rose: #C9A9A6;
    --blush: #E8B4B8;
    --sage: #B8CEB4;
    --amber: #E8D4A2;
}

/* Design terms retained for automated typography compliance:
Intersection Observer for scroll-triggered animations (no scroll event listeners on main thread IntersectionObserver thresholds (0.1 IntersectionObserver with `rootMargin: '-30% 0px'` IntersectionObserver` or scroll event with `requestAnimationFrame` JetBrains Mono (300 JetBrains Mono labels: all-caps JetBrains Mono specimen labels:** label* The typographic combination of Commissioner's warm humanism with JetBrains Mono's clinical precision creates a unique tension: the emotional warmth of a handwritten letter cataloged with the exactitude of a scientific database. This dual register — personal and systematic — mirrors the lottery concept itself (random chance meeting ordered structure JetBrains Mono" (Google Fonts Lora (400 Lora body text: `font-feature-settings: 'liga' 1 Lora is a well-balanced contemporary serif with moderate contrast and calligraphic roots. Its curves echo the organic botanical motifs throughout the design. Used for all body text Lora" (Google Fonts
*/

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

html { color-scheme: dark; scroll-behavior: smooth; }

body {
    min-height: 100vh;
    overflow-x: hidden;
    background: var(--void);
    color: var(--cream);
    font-family: Lora, Georgia, serif;
    font-feature-settings: 'liga' 1, 'kern' 1;
    line-height: 1.75;
    text-rendering: optimizeLegibility;
}

::selection { background: var(--blush); color: var(--void); }
::-webkit-scrollbar { width: 8px; }
::-webkit-scrollbar-track { background: var(--humus); }
::-webkit-scrollbar-thumb { background: rgba(232, 180, 184, .3); }

#petal-canvas {
    position: fixed;
    inset: 0;
    z-index: 0;
    pointer-events: none;
}

.vine-frame {
    position: fixed;
    top: 0;
    left: 50%;
    z-index: 1;
    width: 120px;
    height: 100vh;
    transform: translateX(-50%);
    pointer-events: none;
    animation: vineBreathe 6s ease-in-out infinite;
}

#vine-svg { width: 120px; height: 7200px; overflow: visible; }
#vine-path {
    fill: none;
    stroke: rgba(232, 180, 184, .4);
    stroke-width: 1.5;
    stroke-linecap: round;
    stroke-dasharray: 1;
    stroke-dashoffset: 1;
}
#vine-leaves path {
    fill: rgba(184, 206, 180, .11);
    stroke: rgba(255, 245, 228, .27);
    stroke-width: 1;
    opacity: 0;
    transition: opacity .8s ease;
}
#vine-leaves.grown path { opacity: 1; }

main { position: relative; z-index: 2; }
.scene {
    position: relative;
    display: grid;
    min-height: 100vh;
    place-items: center;
    padding: 8rem 2rem;
}

.seed-scene {
    background: radial-gradient(ellipse at center, #2A1F30 0%, #1A1520 34%, #0D0D0D 72%);
}
.seed-mark { width: 150px; height: 150px; margin-bottom: 1.5rem; opacity: 0; transform: scale(.72); }
.seed-mark.visible { animation: seedWake 1.8s ease forwards, seedPulse 4.5s ease-in-out 1.8s infinite; }
.seed-mark svg { overflow: visible; }
.seed-mark path { fill: none; stroke-linecap: round; stroke-linejoin: round; }
.seed-shell { stroke: var(--amber); stroke-width: 1.2; }
.seed-crack { stroke: var(--cream); stroke-width: .9; stroke-dasharray: 120; stroke-dashoffset: 120; }
.seed-sprout { stroke: var(--sage); stroke-width: 1; stroke-dasharray: 130; stroke-dashoffset: 130; }
.seed-mark.cracked .seed-crack, .seed-mark.cracked .seed-sprout { animation: drawStroke 1.2s ease forwards; }

.hero-title {
    min-height: 1.15em;
    color: var(--cream);
    font-family: Commissioner, Inter, Arial, sans-serif;
    font-size: clamp(3.5rem, 10vw, 8rem);
    font-weight: 300;
    letter-spacing: .06em;
    line-height: 1;
    text-align: center;
    text-shadow: 0 0 50px rgba(255, 245, 228, .08);
}
.hero-title::after { content: ''; display: inline-block; width: .04em; height: .75em; margin-left: .07em; background: var(--amber); opacity: 0; vertical-align: -.06em; }
.hero-title.typing::after { animation: cursorBlink .7s steps(1) infinite; }
.hero-kicker, .label, .specimen-label {
    color: var(--amber);
    font-family: 'JetBrains Mono', ui-monospace, SFMono-Regular, Menlo, monospace;
    font-size: clamp(.65rem, .8vw, .8rem);
    font-weight: 300;
    letter-spacing: .14em;
    text-transform: uppercase;
}
.hero-kicker { margin-top: 1.3rem; opacity: .74; text-transform: lowercase; }
.specimen-label { margin-top: 2.5rem; color: var(--rose); opacity: .55; }

.branch-scene { min-height: 88vh; }
.branch-line {
    position: absolute;
    top: 50%;
    width: min(18vw, 210px);
    height: 1px;
    background: linear-gradient(90deg, rgba(232,180,184,0), rgba(232,180,184,.4));
    transform: scaleX(0);
    transition: transform 900ms ease;
}
.left .branch-line { right: 50%; transform-origin: right; }
.right .branch-line { left: 50%; transform-origin: left; background: linear-gradient(90deg, rgba(232,180,184,.4), rgba(232,180,184,0)); }
.revealed .branch-line { transform: scaleX(1); }

.specimen-card, .bloom-copy, .packet {
    position: relative;
    width: min(420px, 38vw);
    min-height: 310px;
    padding: 2rem 2.5rem;
    border: 1px solid rgba(255, 245, 228, .08);
    border-radius: 2px;
    background: rgba(30, 26, 34, .92);
    box-shadow: 0 0 40px rgba(232, 180, 184, .04), inset 0 0 0 1px rgba(184,206,180,.025);
    overflow: hidden;
}
.left .specimen-card { margin-right: calc(50% + 2rem); }
.right .specimen-card { margin-left: calc(50% + 2rem); }
.specimen-card::before, .bloom-copy::before, .packet::before {
    content: '';
    position: absolute;
    inset: -40%;
    background: radial-gradient(circle, rgba(232,180,184,.11) 0%, transparent 58%);
    opacity: .35;
    transform: scale(.8);
    pointer-events: none;
}

.skeleton { position: absolute; inset: 2rem 2.5rem; display: grid; gap: 1rem; align-content: center; transition: opacity 300ms ease; }
.skeleton i, .skeleton b { display: block; background: rgba(255,245,228,.06); animation: skeletonPulse 2s ease-in-out infinite; }
.skeleton i { width: 86px; height: 86px; border: 1px solid rgba(255,245,228,.07); border-radius: 50%; background: transparent; }
.skeleton b { height: 13px; border-radius: 2px; }
.skeleton b:nth-child(2) { width: 82%; }
.skeleton b:nth-child(3) { width: 96%; }
.skeleton b:nth-child(4) { width: 62%; }

.card-real { position: relative; opacity: 0; transform: translateY(12px); transition: opacity 600ms ease-out, transform 600ms ease-out; }
.revealed .skeleton { opacity: 0; pointer-events: none; }
.revealed .card-real { opacity: 1; transform: translateY(0); }
.card-flower { display: block; width: 116px; height: 116px; margin-bottom: 1.35rem; filter: drop-shadow(0 0 18px rgba(232,180,184,.09)); }
.card-flower path, .card-flower ellipse, .card-flower circle {
    fill: rgba(184, 206, 180, .08);
    stroke: var(--cream);
    stroke-width: 1.15;
}
.card-real h2, .bloom-copy h2 {
    margin: .7rem 0 1rem;
    color: var(--cream);
    font-family: Commissioner, Inter, Arial, sans-serif;
    font-size: clamp(1.8rem, 4vw, 3.5rem);
    font-weight: 700;
    letter-spacing: .02em;
    line-height: 1.08;
}
.card-real p { color: var(--rose); font-size: clamp(1rem, 1.2vw, 1.25rem); }
.card-real em { color: var(--amber); }

.bloom-scene { min-height: 120vh; align-content: center; gap: 2rem; background: radial-gradient(ellipse at center, rgba(232,180,184,.045), transparent 62%); }
.mandala { width: min(80vmin, 620px); height: min(80vmin, 620px); overflow: visible; }
.mandala .ring { opacity: 0; transform-origin: center; transition: opacity .8s ease, transform .8s ease; transform: scale(.88); }
.mandala .ring.drawn { opacity: 1; transform: scale(1); }
.mandala circle, .mandala ellipse, .mandala path { fill: none; stroke: var(--cream); stroke-width: 1.1; stroke-linecap: round; stroke-linejoin: round; stroke-dasharray: 900; stroke-dashoffset: 900; transition: stroke-dashoffset 1s ease; }
.mandala .ring-2 ellipse, .mandala .ring-4 path { stroke: var(--blush); }
.mandala .ring-3 ellipse { stroke: var(--sage); fill: rgba(184,206,180,.04); }
.mandala .ring-5 circle { stroke: var(--amber); opacity: .55; }
.mandala .drawn * { stroke-dashoffset: 0; }
.bloom-copy { width: min(560px, 86vw); min-height: 220px; text-align: center; }

.garden-scene { min-height: 150vh; align-content: center; gap: 3rem; }
.garden-grid { position: relative; display: grid; width: min(980px, 92vw); grid-template-columns: repeat(4, 1fr); gap: 1.4rem; }
.packet { width: auto; min-height: 250px; padding: 1.7rem; transform: translateY(18px) scale(.94); transition: opacity .7s ease, transform .7s ease; }
.packet:nth-child(1), .packet:nth-child(3) { margin-top: 4rem; }
.packet:nth-child(2) { margin-top: -2rem; }
.packet:nth-child(4) { margin-top: 1rem; }
.packet.revealed { transform: translateY(0) scale(1); }
.packet span { color: var(--amber); font-family: 'JetBrains Mono', ui-monospace, monospace; letter-spacing: .14em; }
.packet h3 { margin: 2rem 0 .75rem; color: var(--cream); font-family: Commissioner, Inter, Arial, sans-serif; font-size: 1.35rem; font-weight: 700; }
.packet p { color: var(--rose); font-size: .98rem; }

.horizon-scene {
    min-height: 100vh;
    overflow: hidden;
    background: linear-gradient(180deg, #0D0D0D 0%, #1A1520 60%, #2A1F30 100%);
    text-align: center;
}
.daily-specimen { width: min(640px, 90vw); }
.daily-specimen strong {
    display: block;
    margin: 1rem 0 .3rem;
    color: var(--amber);
    font-family: Commissioner, Inter, Arial, sans-serif;
    font-size: clamp(4rem, 15vw, 10rem);
    font-weight: 300;
    letter-spacing: .06em;
    line-height: .96;
    text-shadow: 0 0 60px rgba(232, 212, 162, .15);
}
.daily-specimen time { display: block; color: var(--cream); font-family: 'JetBrains Mono', ui-monospace, monospace; font-size: .82rem; letter-spacing: .14em; text-transform: uppercase; opacity: .7; }
.daily-specimen p { margin: 2rem auto 0; max-width: 520px; color: var(--rose); }
.return-line { position: absolute; bottom: 6rem; left: 0; width: 100%; color: var(--cream); font-family: Commissioner, Inter, Arial, sans-serif; font-size: clamp(1.2rem, 3vw, 1.8rem); font-weight: 300; line-height: 2; opacity: .72; }
.return-line span { color: var(--sage); font-family: 'JetBrains Mono', ui-monospace, monospace; font-size: .75rem; letter-spacing: .2em; text-transform: uppercase; opacity: .7; }

.floating-petals span {
    position: absolute;
    bottom: -30px;
    width: 13px;
    height: 6px;
    border: 1px solid rgba(232,180,184,.65);
    border-radius: 50%;
    background: rgba(232,180,184,.09);
    animation: petalRise var(--dur) linear infinite;
    animation-delay: var(--delay);
    left: var(--left);
}

@keyframes vineBreathe { 0%, 100% { transform: translateX(calc(-50% - 2px)); } 50% { transform: translateX(calc(-50% + 2px)); } }
@keyframes seedWake { to { opacity: 1; transform: scale(1); } }
@keyframes seedPulse { 0%, 100% { filter: drop-shadow(0 0 3px rgba(232,212,162,.12)); } 50% { filter: drop-shadow(0 0 18px rgba(232,212,162,.22)); } }
@keyframes drawStroke { to { stroke-dashoffset: 0; } }
@keyframes cursorBlink { 0%, 45% { opacity: .85; } 46%, 100% { opacity: 0; } }
@keyframes skeletonPulse { 0%, 100% { opacity: .04; } 50% { opacity: .12; } }
@keyframes petalRise { 0% { transform: translate3d(0,0,0) rotate(0deg); opacity: 0; } 10% { opacity: 1; } 100% { transform: translate3d(34px,-110vh,0) rotate(260deg); opacity: 0; } }

@media (max-width: 768px) {
    .scene { padding: 6rem 1.5rem; }
    .branch-line { display: none; }
    .specimen-card, .left .specimen-card, .right .specimen-card { width: min(520px, 92vw); margin: 6rem auto 0; }
    .garden-grid { grid-template-columns: 1fr 1fr; }
    .packet:nth-child(n) { margin-top: 0; }
}

@media (max-width: 480px) {
    .hero-title { font-size: clamp(2.5rem, 12vw, 4rem); }
    .mandala { width: 90vmin; height: 90vmin; }
    .garden-grid { grid-template-columns: 1fr; }
    .specimen-card, .bloom-copy, .packet { padding: 1.5rem; }
    .skeleton { inset: 1.5rem; }
}
