/* =====================================================
   gamelicensor.info — Bureau of Game Licensing
   Art-deco institutional grandeur meets arcade culture
   ===================================================== */

:root {
    --bureau-midnight: #0b1026;
    --midnight-deep: #161b3a;
    --parchment-warm: #f5e6c8;
    --licensing-gold: #c9a84c;
    --gold-light: #dbb960;
    --brass-antique: #8b7234;
    --ivory-script: #e8e0d0;
    --registry-ink: #1a1a2e;
    --approval-emerald: #2d6a4f;
    --revocation-red: #8b2500;

    --brass-grad: linear-gradient(135deg, #c9a84c 0%, #8b7234 40%, #dbb960 60%, #c9a84c 100%);
    --midnight-grad: radial-gradient(ellipse at 50% 30%, #161b3a 0%, #0b1026 70%);

    --font-display: 'Playfair Display', 'Lora', serif;
    --font-body: 'Libre Baskerville', 'Lora', Georgia, serif;
    --font-stamp: 'Bebas Neue', 'Inter', sans-serif;
    --font-mono: 'IBM Plex Mono', 'Space Mono', monospace;
}

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

html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-body);
    background: var(--bureau-midnight);
    color: var(--ivory-script);
    line-height: 1.85;
    -webkit-font-smoothing: antialiased;
    overflow-x: hidden;
}

/* ============== INTRO OVERLAY ============== */
.intro {
    position: fixed;
    inset: 0;
    background: var(--bureau-midnight);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    z-index: 9999;
    transition: opacity 800ms ease-in-out;
}

.intro.fade-out {
    opacity: 0;
    pointer-events: none;
}

.intro-line {
    position: absolute;
    height: 1px;
    background: var(--licensing-gold);
    width: 0;
    box-shadow: 0 0 12px rgba(201, 168, 76, 0.5);
}

.intro-line-top {
    top: calc(50% - 60px);
    left: 50%;
    transform: translateX(-50%);
    transition: width 800ms ease-out;
}

.intro-line-bottom {
    top: calc(50% + 60px);
    right: 50%;
    transform: translateX(50%);
    transition: width 800ms ease-out 1100ms;
}

.intro.start .intro-line-top,
.intro.start .intro-line-bottom {
    width: 100vw;
    left: 0;
    right: 0;
    transform: none;
}

.intro-title {
    font-family: var(--font-display);
    font-weight: 700;
    color: var(--licensing-gold);
    letter-spacing: 0.2em;
    font-size: clamp(1.2rem, 3vw, 2.4rem);
    text-transform: uppercase;
    text-align: center;
    line-height: 1.4;
    text-shadow: 0 0 24px rgba(201, 168, 76, 0.3);
}

.intro-letter {
    display: inline-block;
    opacity: 0;
    transform: translateY(8px);
    transition: opacity 400ms ease-out, transform 400ms ease-out;
}

.intro-space {
    display: inline-block;
    width: 0.5em;
}

.intro-letter.show {
    opacity: 1;
    transform: translateY(0);
}

.intro-skip {
    position: absolute;
    bottom: 40px;
    right: 40px;
    background: transparent;
    border: 1px solid var(--brass-antique);
    color: var(--licensing-gold);
    font-family: var(--font-stamp);
    font-size: 0.8rem;
    letter-spacing: 0.2em;
    text-transform: uppercase;
    padding: 10px 20px;
    cursor: pointer;
    opacity: 0;
    transition: opacity 600ms ease-out 1000ms, background 200ms, color 200ms;
}

.intro.start .intro-skip {
    opacity: 1;
}

.intro-skip:hover {
    background: var(--licensing-gold);
    color: var(--bureau-midnight);
}

/* ============== NAV SEAL ============== */
.nav-seal {
    position: fixed;
    top: 28px;
    right: 28px;
    z-index: 1000;
    width: 48px;
    height: 48px;
}

.nav-seal-button {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: var(--bureau-midnight);
    border: 1px solid var(--licensing-gold);
    cursor: pointer;
    padding: 4px;
    transition: transform 400ms ease-out, box-shadow 300ms;
    box-shadow: 0 0 0 2px rgba(11, 16, 38, 0.4), 0 4px 16px rgba(0, 0, 0, 0.6);
    position: relative;
    z-index: 2;
}

.nav-seal-button:hover {
    transform: rotate(15deg);
    box-shadow: 0 0 0 2px rgba(201, 168, 76, 0.3), 0 4px 20px rgba(201, 168, 76, 0.4);
}

.nav-seal-svg {
    width: 100%;
    height: 100%;
}

.nav-radial {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%) scale(0);
    width: 320px;
    height: 320px;
    border-radius: 50%;
    pointer-events: none;
    transition: transform 400ms cubic-bezier(0.34, 1.56, 0.64, 1);
}

.nav-seal.open .nav-radial {
    transform: translate(-50%, -50%) scale(1);
    pointer-events: auto;
}

.nav-seal.open::before {
    content: '';
    position: fixed;
    inset: 0;
    background: rgba(11, 16, 38, 0.6);
    backdrop-filter: blur(4px);
    z-index: -1;
    animation: backdropFade 400ms ease-out;
}

@keyframes backdropFade {
    from { opacity: 0; }
    to { opacity: 1; }
}

.nav-link {
    position: absolute;
    top: 50%;
    left: 50%;
    color: var(--licensing-gold);
    font-family: var(--font-stamp);
    font-size: 0.9rem;
    letter-spacing: 0.2em;
    text-transform: uppercase;
    text-decoration: none;
    padding: 10px 14px;
    background: var(--bureau-midnight);
    border: 1px solid var(--brass-antique);
    border-radius: 4px;
    opacity: 0;
    transform: translate(-50%, -50%);
    transition: opacity 300ms ease-out, background 200ms, color 200ms;
    white-space: nowrap;
}

.nav-seal.open .nav-link {
    opacity: 1;
}

.nav-link:hover {
    background: var(--licensing-gold);
    color: var(--bureau-midnight);
}

/* ============== PANELS BASE ============== */
.main {
    position: relative;
}

.panel {
    min-height: 100vh;
    padding: 8vh 6vw;
    position: relative;
    display: flex;
    flex-direction: column;
    justify-content: center;
    overflow: hidden;
}

.panel-header {
    text-align: center;
    margin-bottom: 4vh;
    max-width: 900px;
    margin-left: auto;
    margin-right: auto;
}

.panel-numeral {
    display: block;
    font-family: var(--font-display);
    font-size: 1.4rem;
    color: var(--brass-antique);
    letter-spacing: 0.4em;
    margin-bottom: 1rem;
}

.panel-numeral.dark { color: var(--brass-antique); }
.panel-numeral.light { color: var(--licensing-gold); }

.panel-title {
    font-family: var(--font-display);
    font-weight: 700;
    font-size: clamp(2.5rem, 6vw, 4.5rem);
    letter-spacing: 0.15em;
    text-transform: uppercase;
    color: var(--licensing-gold);
    line-height: 1.1;
}

.panel-title.dark {
    color: var(--registry-ink);
}

.panel-rule {
    width: 80px;
    height: 1px;
    background: var(--licensing-gold);
    margin: 2rem auto 0;
    position: relative;
}

.panel-rule::before, .panel-rule::after {
    content: '';
    position: absolute;
    top: 50%;
    width: 8px;
    height: 8px;
    background: var(--brass-grad);
    transform: translateY(-50%) rotate(45deg);
}

.panel-rule::before { left: -20px; }
.panel-rule::after { right: -20px; }

.panel-rule.dark { background: var(--brass-antique); }
.panel-rule.dark::before, .panel-rule.dark::after { background: var(--brass-grad); }

.panel-lede {
    max-width: 720px;
    margin: 0 auto 5vh;
    text-align: center;
    font-style: italic;
    font-size: clamp(1rem, 1.3vw, 1.2rem);
    color: var(--ivory-script);
    opacity: 0.85;
}

/* Reveal animation */
.reveal {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 700ms ease-out, transform 700ms ease-out;
}

.reveal.in-view {
    opacity: 1;
    transform: translateY(0);
}

/* ============== FAN ORNAMENTS ============== */
.fan-ornament {
    position: absolute;
    width: 120px;
    height: 60px;
    background: conic-gradient(
        from 180deg at 50% 100%,
        var(--licensing-gold) 0deg, var(--licensing-gold) 18deg,
        transparent 18deg, transparent 36deg,
        var(--licensing-gold) 36deg, var(--licensing-gold) 54deg,
        transparent 54deg, transparent 72deg,
        var(--licensing-gold) 72deg, var(--licensing-gold) 90deg,
        transparent 90deg, transparent 108deg,
        var(--licensing-gold) 108deg, var(--licensing-gold) 126deg,
        transparent 126deg, transparent 144deg,
        var(--licensing-gold) 144deg, var(--licensing-gold) 162deg,
        transparent 162deg, transparent 180deg
    );
    clip-path: polygon(0 100%, 100% 100%, 50% 0);
    opacity: 0.5;
}

.fan-corner {
    width: 80px;
    height: 40px;
    transform: scale(0.6);
}

.fan-tl { top: 30px; left: 30px; transform: rotate(135deg) scale(0.6); }
.fan-tr { top: 30px; right: 30px; transform: rotate(-135deg) scale(0.6); }
.fan-bl { bottom: 30px; left: 30px; transform: rotate(45deg) scale(0.6); }
.fan-br { bottom: 30px; right: 30px; transform: rotate(-45deg) scale(0.6); }

/* ============== 1. THE GRAND LOBBY ============== */
.lobby {
    background: var(--midnight-grad);
    text-align: center;
    align-items: center;
}

.lobby-ceiling {
    position: absolute;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 120%;
    height: 200px;
    background: radial-gradient(ellipse at 50% 0%, rgba(201, 168, 76, 0.15) 0%, transparent 70%);
    pointer-events: none;
}

.lobby-content {
    max-width: 900px;
    margin: 0 auto;
    position: relative;
    z-index: 2;
}

.eyebrow {
    font-family: var(--font-stamp);
    font-size: 0.85rem;
    letter-spacing: 0.4em;
    text-transform: uppercase;
    color: var(--brass-antique);
    margin-bottom: 1.2rem;
}

.lobby-title {
    font-family: var(--font-display);
    font-weight: 700;
    font-size: clamp(3rem, 7vw, 6rem);
    letter-spacing: 0.25em;
    text-transform: uppercase;
    color: var(--licensing-gold);
    line-height: 1.05;
    text-shadow: 0 2px 24px rgba(201, 168, 76, 0.3);
    margin-bottom: 4vh;
}

.lobby-archway {
    margin: 0 auto 4vh;
    width: clamp(280px, 50vw, 420px);
    height: clamp(360px, 60vw, 540px);
    position: relative;
    perspective: 1200px;
}

.archway-frame {
    position: absolute;
    inset: 0;
    border: 3px solid transparent;
    border-image: var(--brass-grad) 1;
    border-bottom: none;
    border-radius: 50% 50% 0 0 / 35% 35% 0 0;
    background:
        linear-gradient(180deg, rgba(201, 168, 76, 0.04) 0%, transparent 50%),
        radial-gradient(ellipse at 50% 100%, rgba(11, 16, 38, 0.8) 0%, transparent 60%);
    box-shadow:
        inset 0 0 60px rgba(201, 168, 76, 0.15),
        0 0 80px rgba(201, 168, 76, 0.1);
}

.archway-frame::before {
    content: '';
    position: absolute;
    inset: 8px 8px 0 8px;
    border: 1px solid var(--brass-antique);
    border-bottom: none;
    border-radius: 50% 50% 0 0 / 35% 35% 0 0;
    opacity: 0.6;
}

.archway-frame::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 80%;
    height: 2px;
    background: var(--brass-grad);
}

.archway-inner {
    position: absolute;
    inset: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.floating-certificate {
    width: 70%;
    height: 75%;
    position: relative;
    transform-style: preserve-3d;
    animation: floatRotate 12s ease-in-out infinite;
}

@keyframes floatRotate {
    0%, 100% { transform: rotateY(-10deg) rotateX(2deg) translateY(0); }
    50% { transform: rotateY(10deg) rotateX(-2deg) translateY(-8px); }
}

.cert-face {
    position: absolute;
    inset: 0;
    background: var(--parchment-warm);
    border: 2px solid var(--licensing-gold);
    box-shadow:
        0 0 0 1px var(--brass-antique),
        0 0 0 6px var(--parchment-warm),
        0 0 0 7px var(--licensing-gold),
        0 16px 40px rgba(0, 0, 0, 0.6),
        0 0 60px rgba(201, 168, 76, 0.3);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 24px;
    color: var(--registry-ink);
}

.cert-corner {
    position: absolute;
    width: 18px;
    height: 18px;
    background: var(--brass-grad);
    transform: rotate(45deg);
}

.cert-corner.cert-tl { top: -3px; left: -3px; }
.cert-corner.cert-tr { top: -3px; right: -3px; }
.cert-corner.cert-bl { bottom: -3px; left: -3px; }
.cert-corner.cert-br { bottom: -3px; right: -3px; }

.cert-eyebrow {
    font-family: var(--font-stamp);
    font-size: 0.8rem;
    letter-spacing: 0.3em;
    text-transform: uppercase;
    color: var(--brass-antique);
    margin-bottom: 0.5rem;
}

.cert-title {
    font-family: var(--font-display);
    font-weight: 900;
    font-size: clamp(1.8rem, 4vw, 2.8rem);
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--registry-ink);
    margin-bottom: 1rem;
}

.cert-number {
    font-family: var(--font-mono);
    font-size: 0.85rem;
    letter-spacing: 0.08em;
    color: var(--brass-antique);
}

.lobby-subtitle {
    max-width: 640px;
    margin: 0 auto 3vh;
    font-size: clamp(1rem, 1.3vw, 1.2rem);
    color: var(--ivory-script);
    line-height: 1.85;
}

.brass-rule {
    width: 200px;
    height: 2px;
    margin: 2rem auto 0;
    background: var(--brass-grad);
    position: relative;
}

.brass-rule::before, .brass-rule::after {
    content: '';
    position: absolute;
    top: 50%;
    width: 10px;
    height: 10px;
    background: var(--brass-grad);
    transform: translateY(-50%) rotate(45deg);
    box-shadow: 0 0 0 1px var(--brass-antique);
}

.brass-rule::before { left: -16px; }
.brass-rule::after { right: -16px; }

.scroll-indicator {
    position: absolute;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%);
    text-align: center;
    color: var(--brass-antique);
    font-family: var(--font-stamp);
    font-size: 0.75rem;
    letter-spacing: 0.3em;
    text-transform: uppercase;
    z-index: 2;
}

.scroll-line {
    width: 1px;
    height: 40px;
    margin: 12px auto 0;
    background: linear-gradient(180deg, var(--licensing-gold) 0%, transparent 100%);
    animation: scrollPulse 2s ease-in-out infinite;
}

@keyframes scrollPulse {
    0%, 100% { opacity: 0.3; transform: scaleY(1); }
    50% { opacity: 1; transform: scaleY(1.3); }
}

/* ============== 2. THE REGISTRY HALL ============== */
.registry {
    background: var(--bureau-midnight);
    background-image:
        linear-gradient(180deg, #0d122a 0%, var(--bureau-midnight) 100%);
}

.registry-grid {
    max-width: 1100px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 1fr 2px 1.618fr;
    gap: 4vw;
    align-items: start;
    width: 100%;
}

.registry-timeline {
    display: flex;
    flex-direction: column;
    gap: 1.2rem;
}

.brass-rail {
    width: 2px;
    height: 100%;
    min-height: 400px;
    background: linear-gradient(180deg,
        transparent 0%,
        var(--brass-antique) 10%,
        var(--licensing-gold) 50%,
        var(--brass-antique) 90%,
        transparent 100%);
}

.plaque {
    background: var(--brass-antique);
    background-image: linear-gradient(135deg, #9d8240 0%, #7a6230 50%, #9d8240 100%);
    padding: 18px 22px;
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.3),
        inset 0 -1px 0 rgba(0, 0, 0, 0.4),
        inset 2px 2px 4px rgba(0, 0, 0, 0.2),
        0 4px 12px rgba(0, 0, 0, 0.4);
    color: var(--bureau-midnight);
    font-family: var(--font-stamp);
    text-transform: uppercase;
    letter-spacing: 0.15em;
    transition: filter 300ms ease-out, box-shadow 300ms ease-out, transform 300ms ease-out;
    position: relative;
    display: grid;
    grid-template-columns: auto 1fr auto;
    align-items: center;
    gap: 16px;
    text-shadow: 0 1px 0 rgba(255, 255, 255, 0.2);
}

.plaque:hover {
    filter: brightness(1.15);
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.4),
        inset 0 -1px 0 rgba(0, 0, 0, 0.5),
        inset 2px 2px 4px rgba(0, 0, 0, 0.2),
        0 0 0 1px var(--licensing-gold),
        0 8px 20px rgba(0, 0, 0, 0.6);
    transform: translateY(-2px);
}

.plaque-year {
    font-family: var(--font-display);
    font-weight: 700;
    font-size: 1.4rem;
    letter-spacing: 0.05em;
    color: var(--bureau-midnight);
}

.plaque-text {
    font-size: 0.85rem;
    color: var(--bureau-midnight);
}

.plaque-code {
    font-family: var(--font-mono);
    font-size: 0.7rem;
    letter-spacing: 0.05em;
    color: var(--registry-ink);
    opacity: 0.7;
}

.registry-text p {
    margin-bottom: 1.4rem;
    font-size: clamp(1rem, 1.15vw, 1.1rem);
    color: var(--ivory-script);
}

.dropcap::first-letter {
    font-family: var(--font-display);
    font-weight: 900;
    font-size: 4.2rem;
    float: left;
    line-height: 0.85;
    margin: 6px 12px 0 0;
    color: var(--licensing-gold);
}

/* ============== 3. THE EXAMINATION CHAMBER ============== */
.examination {
    background: var(--bureau-midnight);
    background-image:
        linear-gradient(180deg, var(--bureau-midnight) 0%, #0d122a 50%, var(--bureau-midnight) 100%);
}

.plate-scatter {
    max-width: 1200px;
    margin: 0 auto;
    width: 100%;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 28px 20px;
    padding: 20px 0;
}

.plate {
    position: relative;
    background: linear-gradient(135deg, #1a2046 0%, #161b3a 100%);
    border: 2px solid var(--licensing-gold);
    padding: 30px 22px 22px;
    display: flex;
    flex-direction: column;
    gap: 8px;
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.08),
        inset 0 0 0 1px rgba(201, 168, 76, 0.2),
        0 8px 24px rgba(0, 0, 0, 0.5);
    transition: transform 400ms cubic-bezier(0.25, 0.46, 0.45, 0.94), box-shadow 400ms;
    cursor: default;
}

.plate:nth-child(odd) { transform: rotate(-1.5deg); }
.plate:nth-child(even) { transform: rotate(1.5deg); }

.plate:hover {
    transform: rotateY(3deg) translateY(-6px) !important;
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.1),
        inset 0 0 0 1px rgba(201, 168, 76, 0.4),
        0 16px 40px rgba(0, 0, 0, 0.7),
        0 0 30px rgba(201, 168, 76, 0.15);
}

.plate-tab {
    position: absolute;
    top: -12px;
    right: 16px;
    background: var(--brass-grad);
    color: var(--bureau-midnight);
    padding: 4px 12px;
    font-family: var(--font-mono);
    font-size: 0.7rem;
    letter-spacing: 0.1em;
    font-weight: 500;
    clip-path: polygon(0 0, 100% 0, 90% 100%, 10% 100%);
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.4);
}

.plate-icon {
    width: 32px;
    height: 32px;
    border: 1.5px solid var(--licensing-gold);
    border-radius: 50%;
    position: relative;
    margin-bottom: 4px;
}

.plate-icon::before {
    content: '';
    position: absolute;
    inset: 6px;
    border: 1px solid var(--brass-antique);
    border-radius: 50%;
}

.plate-icon::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 8px;
    height: 8px;
    background: var(--licensing-gold);
    border-radius: 50%;
}

.plate-name {
    font-family: var(--font-display);
    font-weight: 700;
    font-size: 1.25rem;
    letter-spacing: 0.05em;
    color: var(--licensing-gold);
    line-height: 1.2;
}

.plate-meta {
    font-family: var(--font-stamp);
    font-size: 0.75rem;
    letter-spacing: 0.2em;
    text-transform: uppercase;
    color: var(--brass-antique);
}

/* ============== 4. THE SEAL WORKSHOP ============== */
.workshop {
    background: var(--parchment-warm);
    color: var(--registry-ink);
    text-align: center;
    align-items: center;
}

.parchment-noise {
    position: absolute;
    inset: 0;
    pointer-events: none;
    background-image:
        radial-gradient(circle at 20% 30%, rgba(139, 114, 52, 0.08) 0%, transparent 30%),
        radial-gradient(circle at 80% 70%, rgba(139, 114, 52, 0.06) 0%, transparent 30%),
        radial-gradient(circle at 50% 50%, rgba(245, 230, 200, 0) 0%, rgba(139, 114, 52, 0.04) 70%);
}

.parchment-noise::before {
    content: '';
    position: absolute;
    inset: 0;
    background-image:
        repeating-linear-gradient(45deg,
            transparent 0px, transparent 2px,
            rgba(139, 114, 52, 0.015) 2px, rgba(139, 114, 52, 0.015) 4px);
    mix-blend-mode: multiply;
}

.workshop-header { position: relative; z-index: 2; }
.workshop-content {
    position: relative;
    z-index: 2;
    max-width: 700px;
    margin: 0 auto;
}

.workshop-lede {
    font-family: var(--font-body);
    font-style: italic;
    font-size: clamp(1rem, 1.2vw, 1.15rem);
    color: var(--registry-ink);
    margin-bottom: 4vh;
    max-width: 540px;
    margin-left: auto;
    margin-right: auto;
}

.seal-stage {
    position: relative;
    width: 280px;
    height: 280px;
    margin: 0 auto 2rem;
    cursor: pointer;
}

.grand-seal {
    width: 100%;
    height: 100%;
    transition: transform 600ms ease-out, filter 400ms;
    filter: drop-shadow(0 6px 16px rgba(139, 114, 52, 0.3));
}

.seal-stage:hover .grand-seal {
    filter: drop-shadow(0 10px 26px rgba(139, 114, 52, 0.5));
}

.seal-stage:hover .seal-outer {
    transform-origin: 130px 130px;
    transform: rotate(15deg);
    transition: transform 600ms ease-out;
}

.seal-outer {
    transition: transform 600ms ease-out;
    transform-origin: 130px 130px;
}

.grand-seal.stamping {
    animation: stampDrop 600ms cubic-bezier(0.34, 1.56, 0.64, 1);
}

@keyframes stampDrop {
    0% { transform: translateY(-20px) scale(1); }
    50% { transform: translateY(0) scale(1.15); }
    100% { transform: translateY(0) scale(1); }
}

.wax-particles {
    position: absolute;
    inset: 0;
    pointer-events: none;
}

.wax-particle {
    position: absolute;
    width: 8px;
    height: 8px;
    background: var(--revocation-red);
    border-radius: 50%;
    top: 50%;
    left: 50%;
    pointer-events: none;
    opacity: 0;
}

.wax-particle.burst {
    animation: waxBurst 700ms ease-out forwards;
}

@keyframes waxBurst {
    0% {
        opacity: 0.9;
        transform: translate(-50%, -50%) scale(1);
    }
    100% {
        opacity: 0;
        transform: translate(calc(-50% + var(--dx)), calc(-50% + var(--dy))) scale(0.3);
    }
}

.workshop-license-no {
    font-family: var(--font-mono);
    font-size: 0.95rem;
    letter-spacing: 0.1em;
    color: var(--brass-antique);
    margin-bottom: 0.5rem;
}

.workshop-status {
    font-family: var(--font-stamp);
    font-size: 1.1rem;
    letter-spacing: 0.3em;
    text-transform: uppercase;
    color: var(--brass-antique);
    transition: color 300ms;
}

.workshop-status.approved {
    color: var(--approval-emerald);
}

.workshop-status.denied {
    color: var(--revocation-red);
}

/* ============== 5. THE ARCHIVE CORRIDOR ============== */
.archive {
    background: var(--bureau-midnight);
    background-image:
        linear-gradient(180deg, #0d122a 0%, var(--bureau-midnight) 50%, #0d122a 100%);
}

.archive-corridor {
    max-width: 1300px;
    margin: 0 auto;
    width: 100%;
    position: relative;
    display: flex;
    align-items: center;
    gap: 16px;
}

.archive-nav {
    background: transparent;
    border: 1px solid var(--brass-antique);
    color: var(--licensing-gold);
    width: 44px;
    height: 44px;
    border-radius: 50%;
    cursor: pointer;
    font-size: 1.1rem;
    flex-shrink: 0;
    transition: all 300ms;
    z-index: 2;
}

.archive-nav:hover {
    background: var(--licensing-gold);
    color: var(--bureau-midnight);
    border-color: var(--licensing-gold);
}

.archive-scroller {
    display: flex;
    gap: 22px;
    overflow-x: auto;
    scroll-behavior: smooth;
    padding: 30px 8px;
    flex: 1;
    scrollbar-width: thin;
    scrollbar-color: var(--brass-antique) transparent;
}

.archive-scroller::-webkit-scrollbar { height: 8px; }
.archive-scroller::-webkit-scrollbar-track { background: transparent; }
.archive-scroller::-webkit-scrollbar-thumb { background: var(--brass-antique); border-radius: 4px; }

.record {
    flex: 0 0 220px;
    aspect-ratio: 2 / 3;
    background: var(--parchment-warm);
    color: var(--registry-ink);
    padding: 30px 18px 18px;
    position: relative;
    box-shadow:
        0 8px 24px rgba(0, 0, 0, 0.5),
        inset 0 0 0 1px var(--brass-antique);
    display: flex;
    flex-direction: column;
}

.record::before {
    content: '';
    position: absolute;
    inset: 6px;
    border: 1px solid var(--brass-antique);
    pointer-events: none;
    opacity: 0.4;
}

.record-tab {
    position: absolute;
    top: -14px;
    left: 16px;
    background: var(--brass-antique);
    color: var(--bureau-midnight);
    padding: 4px 12px;
    font-family: var(--font-mono);
    font-size: 0.7rem;
    letter-spacing: 0.08em;
    border-radius: 2px 2px 0 0;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.3);
}

.record-title {
    font-family: var(--font-display);
    font-weight: 700;
    font-size: 1.05rem;
    letter-spacing: 0.05em;
    color: var(--registry-ink);
    margin-bottom: 0.75rem;
    line-height: 1.2;
}

.record-stamp {
    font-family: var(--font-stamp);
    font-size: 0.85rem;
    letter-spacing: 0.25em;
    text-transform: uppercase;
    padding: 4px 8px;
    border: 2px solid;
    display: inline-block;
    align-self: flex-start;
    transform: rotate(-3deg);
    margin-bottom: 1rem;
}

.record-stamp.approved {
    color: var(--approval-emerald);
    border-color: var(--approval-emerald);
}

.record-stamp.denied {
    color: var(--revocation-red);
    border-color: var(--revocation-red);
}

.record-stamp.pending {
    color: var(--brass-antique);
    border-color: var(--brass-antique);
}

.record-lines {
    flex: 1;
    background-image: repeating-linear-gradient(
        180deg,
        transparent 0,
        transparent 12px,
        rgba(139, 114, 52, 0.3) 12px,
        rgba(139, 114, 52, 0.3) 13px
    );
    margin-bottom: 1rem;
}

.record-no {
    font-family: var(--font-mono);
    font-size: 0.75rem;
    letter-spacing: 0.08em;
    color: var(--brass-antique);
    text-align: right;
}

/* ============== 6. THE COMPLIANCE OBSERVATORY ============== */
.observatory {
    padding: 0;
    min-height: 100vh;
    overflow: hidden;
    background: var(--bureau-midnight);
}

.observatory-upper {
    position: absolute;
    inset: 0;
    background: var(--bureau-midnight);
    clip-path: polygon(0 0, 100% 0, 100% 50%, 0 calc(50% + 7vh));
}

.observatory-lower {
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, #c9a84c 0%, #b89a44 50%, #c9a84c 100%);
    clip-path: polygon(0 calc(50% + 7vh), 100% 50%, 100% 100%, 0 100%);
}

.observatory-content {
    position: relative;
    z-index: 2;
    max-width: 900px;
    margin: 0 auto;
    padding: 8vh 6vw;
    text-align: center;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.observatory-statement {
    font-family: var(--font-display);
    font-weight: 700;
    font-size: clamp(1.8rem, 4.5vw, 3.6rem);
    letter-spacing: -0.02em;
    line-height: 1.25;
    color: var(--licensing-gold);
    margin: 2rem 0;
}

.observatory-statement em {
    font-style: italic;
    color: var(--ivory-script);
    font-weight: 400;
}

.observatory-attribution {
    font-family: var(--font-stamp);
    font-size: 0.95rem;
    letter-spacing: 0.3em;
    text-transform: uppercase;
    color: var(--registry-ink);
    margin-top: 2rem;
}

/* ============== 7. THE FINAL STAMP ============== */
.final {
    background: var(--midnight-grad);
    text-align: center;
    align-items: center;
}

.final-content {
    max-width: 500px;
    margin: 0 auto;
}

.final-seal {
    width: clamp(180px, 30vw, 260px);
    height: clamp(180px, 30vw, 260px);
    margin: 0 auto 3rem;
    filter: drop-shadow(0 6px 30px rgba(201, 168, 76, 0.3));
    animation: sealBreath 6s ease-in-out infinite;
}

@keyframes sealBreath {
    0%, 100% { transform: scale(1); filter: drop-shadow(0 6px 30px rgba(201, 168, 76, 0.3)); }
    50% { transform: scale(1.02); filter: drop-shadow(0 8px 40px rgba(201, 168, 76, 0.5)); }
}

.final-tagline {
    font-family: var(--font-stamp);
    font-size: 1rem;
    letter-spacing: 0.3em;
    text-transform: uppercase;
    color: var(--licensing-gold);
    margin-bottom: 1rem;
}

.final-underline {
    width: 120px;
    height: 2px;
    margin: 0 auto 3rem;
    background: var(--brass-grad);
    animation: underlinePulse 3s ease-in-out infinite;
}

@keyframes underlinePulse {
    0%, 100% { opacity: 0.6; transform: scaleX(1); }
    50% { opacity: 1; transform: scaleX(1.2); }
}

.final-imprint {
    font-family: var(--font-mono);
    font-size: 0.75rem;
    letter-spacing: 0.15em;
    color: var(--brass-antique);
}

/* ============== RESPONSIVE ============== */
@media (max-width: 768px) {
    .panel { padding: 6vh 5vw; }
    .registry-grid {
        grid-template-columns: 1fr;
        gap: 3vh;
    }
    .brass-rail { display: none; }
    .lobby-title { font-size: clamp(2.2rem, 9vw, 4rem); }
    .nav-seal { top: 16px; right: 16px; }
    .archway-frame { border-radius: 50% 50% 0 0 / 25% 25% 0 0; }
    .observatory-statement { font-size: clamp(1.4rem, 5vw, 2.4rem); }
    .nav-radial { width: 240px; height: 240px; }
}

@media (max-width: 480px) {
    .plate-scatter {
        grid-template-columns: 1fr;
    }
    .record { flex: 0 0 180px; }
}
