/* gamelicensor.info - Fairycore Enchanted Registry */
/* Colors: #c77dba #4a3f5c #2a1533 #5b2a6e #c9a8c0 #f0c24a #fdf6f9 #d966b8 #7ed4a6 #e8a0ff */
/* Fonts: Fraunces (display), Lora (body), Space Grotesk (mono) */

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

:root {
    --plum-deep: #2a1533;
    --plum-dark: #4a3f5c;
    --plum-mid: #5b2a6e;
    --rose-warm: #c77dba;
    --rose-light: #c9a8c0;
    --rose-bright: #d966b8;
    --rose-glow: #e8a0ff;
    --gold-warm: #f0c24a;
    --cream: #fdf6f9;
    --mint: #7ed4a6;
    --rose-tint: #f5c6d0;
    --font-display: 'Fraunces', serif;
    --font-body: 'Lora', serif;
    --font-mono: 'Space Grotesk', sans-serif;
}

html {
    scroll-behavior: smooth;
    font-size: 16px;
}

body {
    background: var(--plum-deep);
    color: var(--cream);
    font-family: var(--font-body);
    line-height: 1.7;
    overflow-x: hidden;
    position: relative;
}

/* SVG Noise Overlay */
#noise-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    pointer-events: none;
    z-index: 9999;
    mix-blend-mode: soft-light;
    opacity: 0.06;
}

/* Sparkles Container */
#sparkles-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 10;
    overflow: hidden;
}

.sparkle {
    position: absolute;
    width: 4px;
    height: 4px;
    border-radius: 50%;
    background: var(--gold-warm);
    box-shadow: 0 0 6px 2px var(--gold-warm), 0 0 12px 4px rgba(240, 194, 74, 0.3);
    animation: sparkle-float linear infinite;
    opacity: 0;
}

@keyframes sparkle-float {
    0% { opacity: 0; transform: translateY(0) scale(0.5); }
    15% { opacity: 1; }
    85% { opacity: 1; }
    100% { opacity: 0; transform: translateY(-100vh) scale(0.2); }
}

/* Hex Section Base */
.hex-section {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 80px 20px;
    position: relative;
}

/* Hexagon Shapes via clip-path */
.hexagon {
    position: relative;
    clip-path: polygon(50% 0%, 100% 25%, 100% 75%, 50% 100%, 0% 75%, 0% 25%);
    transition: transform 0.6s cubic-bezier(0.23, 1, 0.32, 1), box-shadow 0.4s ease;
}

.hex-inner {
    padding: 40px 30px;
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    height: 100%;
}

/* Hero Hexagon */
.hex-hero {
    width: min(60vw, 550px);
    height: min(60vw, 550px);
    background: linear-gradient(135deg, var(--plum-mid) 0%, var(--plum-dark) 50%, var(--plum-deep) 100%);
    border: none;
    position: relative;
}

.hex-hero .hex-inner {
    padding: 60px 40px;
}

.hex-glow {
    position: absolute;
    top: -20px;
    left: -20px;
    right: -20px;
    bottom: -20px;
    background: radial-gradient(ellipse at center, rgba(232, 160, 255, 0.15) 0%, transparent 70%);
    pointer-events: none;
    animation: glow-pulse 4s ease-in-out infinite;
}

@keyframes glow-pulse {
    0%, 100% { opacity: 0.5; transform: scale(1); }
    50% { opacity: 1; transform: scale(1.05); }
}

.hex-icon {
    font-size: 2.5rem;
    color: var(--gold-warm);
    display: block;
    margin-bottom: 16px;
    filter: drop-shadow(0 0 8px rgba(240, 194, 74, 0.6));
}

.hex-title {
    font-family: var(--font-display);
    font-size: clamp(2rem, 4.5vw, 4rem);
    font-weight: 900;
    color: var(--rose-tint);
    letter-spacing: 0.01em;
    line-height: 1.1;
    font-variation-settings: 'opsz' 72, 'WONK' 1;
}

.hex-subtitle {
    font-family: var(--font-display);
    font-size: clamp(1rem, 2vw, 1.8rem);
    color: var(--rose-light);
    font-weight: 400;
    font-style: italic;
    margin-top: 4px;
}

.hex-divider {
    display: flex;
    align-items: center;
    gap: 12px;
    margin: 20px 0;
}

.divider-leaf {
    color: var(--mint);
    font-size: 1.2rem;
}

.divider-line {
    width: 80px;
    height: 1px;
    background: linear-gradient(90deg, transparent, var(--rose-light), transparent);
}

.hex-tagline {
    font-family: var(--font-body);
    font-size: clamp(0.85rem, 1.2vw, 1.1rem);
    color: var(--rose-light);
    max-width: 320px;
    font-style: italic;
    line-height: 1.6;
}

/* Hero Cluster */
.hero-cluster {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
}

.hex-orbiter {
    position: absolute;
    animation: orbit-drift 8s ease-in-out infinite;
}

.hex-orb-1 { top: -60px; right: -100px; animation-delay: 0s; }
.hex-orb-2 { bottom: -40px; left: -120px; animation-delay: -2.5s; }
.hex-orb-3 { bottom: -80px; right: -80px; animation-delay: -5s; }

@keyframes orbit-drift {
    0%, 100% { transform: translate(0, 0); }
    33% { transform: translate(8px, -12px); }
    66% { transform: translate(-6px, 8px); }
}

.hex-small {
    width: 120px;
    height: 120px;
    background: linear-gradient(135deg, var(--plum-mid), var(--plum-dark));
}

.hex-small .hex-inner {
    padding: 20px 10px;
}

.hex-icon-sm {
    font-size: 1.5rem;
    display: block;
    margin-bottom: 4px;
}

.hex-label {
    font-family: var(--font-mono);
    font-size: 0.6rem;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--rose-light);
}

/* Scroll Indicator */
.scroll-indicator {
    margin-top: 40px;
    display: flex;
    flex-direction: column;
    align-items: center;
    animation: scroll-bob 2s ease-in-out infinite;
}

.scroll-text {
    font-family: var(--font-mono);
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.15em;
    color: var(--rose-light);
    opacity: 0.7;
}

.scroll-arrow {
    font-size: 1.5rem;
    color: var(--gold-warm);
    margin-top: 8px;
}

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

/* Chapter Headers */
.chapter-header {
    text-align: center;
    margin-bottom: 60px;
    max-width: 700px;
}

.chapter-number {
    font-family: var(--font-mono);
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 0.2em;
    color: var(--gold-warm);
    display: block;
    margin-bottom: 12px;
}

.chapter-title {
    font-family: var(--font-display);
    font-size: clamp(1.8rem, 3.5vw, 3rem);
    font-weight: 900;
    color: var(--rose-tint);
    letter-spacing: 0.01em;
    line-height: 1.15;
    font-variation-settings: 'opsz' 72, 'WONK' 1;
    margin-bottom: 16px;
}

.chapter-epigraph {
    font-family: var(--font-body);
    font-style: italic;
    font-size: clamp(0.9rem, 1.3vw, 1.1rem);
    color: var(--rose-light);
    line-height: 1.6;
}

/* Chapter Cluster - Medium Hexagons */
.chapter-cluster {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
    justify-content: center;
    align-items: center;
    max-width: 900px;
}

.hex-medium {
    width: 280px;
    height: 280px;
    background: linear-gradient(160deg, rgba(91, 42, 110, 0.8), rgba(42, 21, 51, 0.9));
    backdrop-filter: blur(4px);
}

.hex-medium .hex-inner {
    padding: 35px 25px;
}

.hex-medium h3 {
    font-family: var(--font-display);
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--gold-warm);
    margin: 8px 0;
    font-variation-settings: 'opsz' 24;
}

.hex-medium p {
    font-size: 0.8rem;
    color: var(--rose-light);
    line-height: 1.5;
}

/* Hex Card Grid (Chapter 2) */
.hex-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
    justify-content: center;
    max-width: 1100px;
}

.hex-card {
    width: 220px;
    height: 220px;
    background: linear-gradient(160deg, rgba(91, 42, 110, 0.7), rgba(42, 21, 51, 0.85));
    cursor: default;
}

.hex-card:hover {
    transform: scale(1.08);
}

.hex-card .hex-inner {
    padding: 28px 18px;
}

.hex-card h3 {
    font-family: var(--font-display);
    font-size: 0.95rem;
    font-weight: 700;
    color: var(--cream);
    margin: 6px 0;
    font-variation-settings: 'opsz' 24;
}

.hex-card p {
    font-size: 0.72rem;
    color: var(--rose-light);
    line-height: 1.45;
}

.seal-badge {
    font-size: 1.8rem;
    width: 44px;
    height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    margin-bottom: 4px;
}

.seal-exclusive { color: var(--gold-warm); background: rgba(240, 194, 74, 0.15); }
.seal-nonexclusive { color: var(--mint); background: rgba(126, 212, 166, 0.15); }
.seal-sole { color: var(--rose-bright); background: rgba(217, 102, 184, 0.15); }
.seal-sublicense { color: var(--rose-glow); background: rgba(232, 160, 255, 0.15); }
.seal-opensource { color: var(--gold-warm); background: rgba(240, 194, 74, 0.15); }
.seal-creative { color: var(--mint); background: rgba(126, 212, 166, 0.15); }
.seal-proprietary { color: var(--rose-warm); background: rgba(199, 125, 186, 0.15); }

.seal-tag {
    font-family: var(--font-mono);
    font-size: 0.6rem;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--gold-warm);
    margin-top: 6px;
    padding: 2px 8px;
    border: 1px solid rgba(240, 194, 74, 0.3);
    border-radius: 12px;
}

/* Territory Map (Chapter 3) */
.territory-map {
    display: flex;
    flex-wrap: wrap;
    gap: 30px;
    justify-content: center;
    max-width: 1100px;
}

.territory-hex {
    flex: 0 0 auto;
}

.hex-territory {
    width: 320px;
    height: 320px;
    background: linear-gradient(160deg, rgba(91, 42, 110, 0.7), rgba(42, 21, 51, 0.85));
}

.hex-territory .hex-inner {
    padding: 35px 22px;
}

.territory-sigil {
    font-size: 2rem;
    color: var(--gold-warm);
    filter: drop-shadow(0 0 6px rgba(240, 194, 74, 0.4));
    margin-bottom: 6px;
}

.hex-territory h3 {
    font-family: var(--font-display);
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--cream);
    font-variation-settings: 'opsz' 24;
    margin-bottom: 2px;
}

.territory-region {
    font-family: var(--font-mono);
    font-size: 0.65rem;
    text-transform: uppercase;
    letter-spacing: 0.15em;
    color: var(--mint);
    display: block;
    margin-bottom: 8px;
}

.hex-territory p {
    font-size: 0.78rem;
    color: var(--rose-light);
    line-height: 1.5;
    margin-bottom: 10px;
}

.territory-rating {
    display: flex;
    flex-wrap: wrap;
    gap: 4px;
    justify-content: center;
}

.rating-badge {
    font-family: var(--font-mono);
    font-size: 0.55rem;
    padding: 2px 6px;
    border: 1px solid rgba(199, 125, 186, 0.4);
    border-radius: 8px;
    color: var(--rose-warm);
    background: rgba(199, 125, 186, 0.1);
}

/* Philosophy Grid (Chapter 4) */
.philosophy-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 25px;
    justify-content: center;
    max-width: 1000px;
}

.hex-philosophy {
    width: 260px;
    height: 260px;
    background: linear-gradient(160deg, rgba(91, 42, 110, 0.7), rgba(42, 21, 51, 0.85));
}

.hex-philosophy .hex-inner {
    padding: 35px 22px;
}

.phil-icon {
    font-size: 2rem;
    margin-bottom: 8px;
}

.hex-philosophy h3 {
    font-family: var(--font-display);
    font-size: 1rem;
    font-weight: 700;
    color: var(--gold-warm);
    margin-bottom: 8px;
    font-variation-settings: 'opsz' 24;
}

.hex-philosophy p {
    font-size: 0.78rem;
    color: var(--rose-light);
    line-height: 1.5;
}

/* Timeline (Chapter 5) */
.timeline {
    position: relative;
    max-width: 700px;
    width: 100%;
    padding: 40px 0;
}

.timeline-line {
    position: absolute;
    left: 30px;
    top: 0;
    bottom: 0;
    width: 2px;
    background: linear-gradient(180deg, transparent, var(--rose-warm), var(--gold-warm), var(--rose-warm), transparent);
}

.timeline-entry {
    position: relative;
    padding-left: 80px;
    margin-bottom: 50px;
}

.timeline-marker {
    position: absolute;
    left: 16px;
    top: 0;
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--plum-mid);
    border-radius: 50%;
    border: 2px solid var(--gold-warm);
    color: var(--gold-warm);
    font-size: 0.9rem;
    box-shadow: 0 0 12px rgba(240, 194, 74, 0.3);
}

.timeline-content h3 {
    font-family: var(--font-display);
    font-size: 1.2rem;
    font-weight: 700;
    color: var(--cream);
    margin-bottom: 8px;
    font-variation-settings: 'opsz' 24;
}

.timeline-content p {
    font-size: 0.9rem;
    color: var(--rose-light);
    line-height: 1.65;
}

/* Footer */
#registry-footer {
    min-height: auto;
    padding: 100px 20px 60px;
    background: linear-gradient(180deg, var(--plum-deep), #1a0d22);
}

.hex-footer {
    width: min(50vw, 500px);
    height: min(50vw, 500px);
    background: linear-gradient(135deg, var(--plum-mid) 0%, var(--plum-dark) 50%, var(--plum-deep) 100%);
}

.hex-footer .hex-inner {
    padding: 50px 35px;
}

.footer-sigil {
    font-size: 2rem;
    color: var(--gold-warm);
    filter: drop-shadow(0 0 8px rgba(240, 194, 74, 0.6));
    margin-bottom: 12px;
}

.footer-title {
    font-family: var(--font-display);
    font-size: clamp(1.3rem, 2.5vw, 2rem);
    font-weight: 900;
    color: var(--rose-tint);
    font-variation-settings: 'opsz' 72, 'WONK' 1;
    margin-bottom: 12px;
}

.footer-text {
    font-size: 0.85rem;
    color: var(--rose-light);
    line-height: 1.6;
    max-width: 360px;
    margin-bottom: 16px;
}

.footer-seal {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 12px;
}

.seal-glyph {
    color: var(--gold-warm);
    font-size: 1rem;
}

.seal-text {
    font-family: var(--font-mono);
    font-size: 0.65rem;
    text-transform: uppercase;
    letter-spacing: 0.15em;
    color: var(--rose-light);
}

.footer-domain {
    font-family: var(--font-mono);
    font-size: 0.8rem;
    color: var(--mint);
    letter-spacing: 0.05em;
}

.footer-vines {
    display: flex;
    gap: 30px;
    margin-top: 30px;
    opacity: 0.4;
}

.vine {
    font-size: 1.2rem;
    color: var(--mint);
    letter-spacing: 0.3em;
}

/* Reveal Animation */
.hex-reveal {
    opacity: 0;
    transform: translateY(30px) scale(0.95);
    transition: opacity 0.8s cubic-bezier(0.23, 1, 0.32, 1), transform 0.8s cubic-bezier(0.23, 1, 0.32, 1);
}

.hex-reveal.revealed {
    opacity: 1;
    transform: translateY(0) scale(1);
}

/* Background decorative gradients per section */
#chapter-1 { background: radial-gradient(ellipse at 20% 50%, rgba(91, 42, 110, 0.3) 0%, transparent 60%), var(--plum-deep); }
#chapter-2 { background: radial-gradient(ellipse at 80% 30%, rgba(199, 125, 186, 0.15) 0%, transparent 60%), var(--plum-deep); }
#chapter-3 { background: radial-gradient(ellipse at 50% 80%, rgba(126, 212, 166, 0.1) 0%, transparent 60%), var(--plum-deep); }
#chapter-4 { background: radial-gradient(ellipse at 30% 40%, rgba(240, 194, 74, 0.08) 0%, transparent 60%), var(--plum-deep); }
#chapter-5 { background: radial-gradient(ellipse at 70% 60%, rgba(232, 160, 255, 0.1) 0%, transparent 60%), var(--plum-deep); }

/* Responsive */
@media (max-width: 768px) {
    .hex-hero {
        width: 85vw;
        height: 85vw;
    }

    .hex-orbiter {
        display: none;
    }

    .hex-medium {
        width: 85vw;
        height: 85vw;
        max-width: 280px;
        max-height: 280px;
    }

    .hex-card {
        width: 75vw;
        height: 75vw;
        max-width: 220px;
        max-height: 220px;
    }

    .hex-territory {
        width: 85vw;
        height: 85vw;
        max-width: 320px;
        max-height: 320px;
    }

    .hex-philosophy {
        width: 80vw;
        height: 80vw;
        max-width: 260px;
        max-height: 260px;
    }

    .hex-footer {
        width: 80vw;
        height: 80vw;
        max-width: 400px;
        max-height: 400px;
    }

    .chapter-cluster {
        flex-direction: column;
    }

    .hex-grid {
        flex-direction: column;
        align-items: center;
    }

    .territory-map {
        flex-direction: column;
        align-items: center;
    }

    .philosophy-grid {
        flex-direction: column;
        align-items: center;
    }

    .timeline-line {
        left: 15px;
    }

    .timeline-entry {
        padding-left: 55px;
    }

    .timeline-marker {
        left: 2px;
        width: 26px;
        height: 26px;
        font-size: 0.7rem;
    }
}

/* Chapter section dividers */
.chapter-section::before {
    content: '\2740 \2740 \2740';
    display: block;
    text-align: center;
    font-size: 1.5rem;
    color: var(--rose-warm);
    opacity: 0.3;
    letter-spacing: 1em;
    margin-bottom: 40px;
}

/* Additional glow effects */
.hex-hero::after {
    content: '';
    position: absolute;
    inset: -2px;
    clip-path: polygon(50% 0%, 100% 25%, 100% 75%, 50% 100%, 0% 75%, 0% 25%);
    background: linear-gradient(135deg, var(--rose-glow), var(--gold-warm), var(--mint), var(--rose-bright));
    z-index: -1;
    opacity: 0.3;
    animation: border-glow 6s ease-in-out infinite alternate;
}

@keyframes border-glow {
    0% { opacity: 0.2; filter: blur(2px); }
    100% { opacity: 0.5; filter: blur(4px); }
}

/* Selection colors */
::selection {
    background: var(--rose-bright);
    color: var(--cream);
}

/* Additional design colors */
.hex-medium {
    border-color: #D4B8D9;
}
.chapter-section {
    border-top: 1px solid transparent;
}
.hex-territory .territory-sigil {
    text-shadow: 0 0 4px #E8D6EC;
}
.footer-hex-cluster {
    position: relative;
}
.footer-hex-cluster::before {
    content: '';
    position: absolute;
    top: -40px;
    left: 50%;
    transform: translateX(-50%);
    width: 200px;
    height: 1px;
    background: linear-gradient(90deg, transparent, #EDE0F2, transparent);
}
