/* ==========================================================================
   monopole.bar — A speakeasy for magnetic monopoles
   Art Deco, dark-mode, opulent, mysterious
   ========================================================================== */

:root {
    --c-black-velvet: #0a0a12;
    --c-lounge-dark: #1a1a28;
    --c-bar-counter: #2a2a3a;
    --c-whiskey: #4a3a2a;
    --c-aged-brass: #8a7a5a;
    --c-gilded: #c9a84c;
    --c-champagne: #e8dcc8;

    --font-display: 'Poiret One', 'Cormorant Garamond', serif;
    --font-body: 'Raleway', 'Helvetica Neue', sans-serif;
    --font-menu: 'Josefin Sans', 'Raleway', sans-serif;

    --content-max: 640px;
    --content-narrow: 520px;

    --frame-pad: clamp(28px, 5vw, 56px);
    --bar-height: 64px;
}

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

html {
    scroll-behavior: smooth;
}

body {
    background-color: var(--c-black-velvet);
    color: var(--c-champagne);
    font-family: var(--font-body);
    font-weight: 400;
    font-size: 1rem;
    line-height: 1.75;
    overflow-x: hidden;
    padding-bottom: var(--bar-height);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

p {
    margin: 0 0 1.1em;
    color: var(--c-champagne);
}

p:last-child {
    margin-bottom: 0;
}

em {
    font-style: italic;
    color: var(--c-gilded);
}

a {
    color: var(--c-gilded);
    text-decoration: none;
}

/* ==========================================================================
   Outer page frame — a thin gilded border around the entire viewport
   ========================================================================== */

.page-frame {
    position: fixed;
    inset: 14px 14px calc(var(--bar-height) + 14px) 14px;
    border: 1px solid rgba(201, 168, 76, 0.22);
    pointer-events: none;
    z-index: 5;
}

.page-frame::before,
.page-frame::after {
    content: "";
    position: absolute;
    width: 22px;
    height: 22px;
    border: 1px solid var(--c-gilded);
}

.page-frame::before {
    top: -3px;
    left: -3px;
    border-right: none;
    border-bottom: none;
}

.page-frame::after {
    top: -3px;
    right: -3px;
    border-left: none;
    border-bottom: none;
}

/* ==========================================================================
   Rooms (full-viewport sections)
   ========================================================================== */

.rooms {
    position: relative;
    z-index: 1;
}

.room {
    position: relative;
    min-height: 100vh;
    padding: clamp(80px, 12vh, 140px) clamp(20px, 5vw, 60px);
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.room--hero {
    background: var(--c-black-velvet);
}

.room--charter {
    background: var(--c-lounge-dark);
}

.room--menu {
    background: var(--c-black-velvet);
}

.room--lounge {
    background: var(--c-lounge-dark);
}

.room--ledger {
    background: var(--c-black-velvet);
}

.room--invitation {
    background: linear-gradient(180deg, var(--c-lounge-dark) 0%, var(--c-black-velvet) 100%);
}

/* ==========================================================================
   Hero — sunburst, marquee, frame, scroll cue
   ========================================================================== */

.hero-sunburst {
    position: absolute;
    inset: -10%;
    background: repeating-conic-gradient(
        from 0deg at 50% 50%,
        var(--c-black-velvet) 0deg,
        var(--c-black-velvet) 8deg,
        var(--c-lounge-dark) 8deg,
        var(--c-lounge-dark) 10deg
    );
    opacity: 0.85;
    z-index: 0;
    animation: sunburst-drift 90s linear infinite;
    will-change: transform;
}

@keyframes sunburst-drift {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

.hero-vignette {
    position: absolute;
    inset: 0;
    background:
        radial-gradient(ellipse at 50% 40%, transparent 0%, transparent 35%, rgba(10, 10, 18, 0.92) 80%),
        linear-gradient(180deg, rgba(10, 10, 18, 0.6) 0%, transparent 30%, transparent 70%, rgba(10, 10, 18, 0.95) 100%);
    z-index: 1;
}

.hero-inner {
    position: relative;
    z-index: 2;
    width: 100%;
    max-width: 760px;
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 36px;
}

.hero-marque {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 14px;
    width: 100%;
    max-width: 560px;
    color: var(--c-aged-brass);
    font-family: var(--font-menu);
    font-weight: 300;
    font-size: 0.78rem;
    letter-spacing: 0.32em;
    text-transform: uppercase;
}

.hero-marque__rule {
    flex: 1;
    height: 1px;
    background: linear-gradient(90deg, transparent, var(--c-gilded) 40%, var(--c-gilded) 60%, transparent);
    opacity: 0.55;
}

.hero-frame {
    position: relative;
    padding: clamp(36px, 6vw, 64px) clamp(28px, 5vw, 56px);
    background: rgba(10, 10, 18, 0.55);
    backdrop-filter: blur(2px);
    -webkit-backdrop-filter: blur(2px);
    width: min(100%, 620px);
}

.hero-emblem {
    width: 100px;
    height: 100px;
    margin: 0 auto 22px;
    opacity: 0;
    animation: hero-fade 1.4s ease 0.2s forwards;
}

.hero-emblem svg {
    width: 100%;
    height: 100%;
    display: block;
    animation: emblem-spin 60s linear infinite;
}

@keyframes emblem-spin {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

.hero-title {
    font-family: var(--font-display);
    font-weight: 400;
    font-size: clamp(2.5rem, 9vw, 5.5rem);
    line-height: 1;
    letter-spacing: 0.04em;
    color: var(--c-gilded);
    text-shadow:
        0 0 24px rgba(201, 168, 76, 0.18),
        0 0 1px rgba(201, 168, 76, 0.6);
    opacity: 0;
    animation: hero-fade 1.6s ease 0.5s forwards;
}

.hero-title__monopole,
.hero-title__bar,
.hero-title__dot {
    display: inline-block;
}

.hero-title__dot {
    color: var(--c-champagne);
    transform: translateY(-0.05em);
    margin: 0 0.08em;
}

.hero-tag {
    margin-top: 22px;
    font-family: var(--font-body);
    font-size: clamp(0.95rem, 1.5vw, 1.05rem);
    color: var(--c-champagne);
    line-height: 1.7;
    font-style: italic;
    opacity: 0;
    animation: hero-fade 1.6s ease 0.9s forwards;
}

.hero-meta {
    margin-top: 22px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-wrap: wrap;
    gap: 10px;
    color: var(--c-aged-brass);
    font-family: var(--font-menu);
    font-weight: 300;
    font-size: 0.75rem;
    letter-spacing: 0.28em;
    text-transform: uppercase;
    opacity: 0;
    animation: hero-fade 1.6s ease 1.2s forwards;
}

.dot-sep {
    color: var(--c-gilded);
}

.hero-scrollcue {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
    color: var(--c-aged-brass);
    font-family: var(--font-menu);
    font-weight: 300;
    font-size: 0.7rem;
    letter-spacing: 0.4em;
    text-transform: uppercase;
    opacity: 0;
    animation: hero-fade 1.6s ease 1.5s forwards, scrollcue-pulse 3s ease-in-out 2.6s infinite;
}

.hero-scrollcue__line {
    width: 1px;
    height: 56px;
    background: linear-gradient(180deg, var(--c-gilded), transparent);
}

@keyframes scrollcue-pulse {
    0%, 100% { transform: translateY(0); opacity: 0.7; }
    50% { transform: translateY(6px); opacity: 1; }
}

@keyframes hero-fade {
    from { opacity: 0; transform: translateY(8px); }
    to { opacity: 1; transform: translateY(0); }
}

/* ==========================================================================
   Gilded frame — corner brackets via pseudo-elements
   ========================================================================== */

.gilded-frame {
    position: relative;
}

.gilded-frame::before,
.gilded-frame::after,
.gilded-frame > .corner-tl,
.gilded-frame > .corner-br {
    /* fallbacks; we use ::before and ::after for two corners and box-shadow trick is avoided */
}

/* L-shaped corner brackets, 16px per arm, on all four corners */
.gilded-frame {
    --gf-arm: 18px;
    --gf-thick: 1.5px;
    --gf-color: var(--c-gilded);
    --gf-inset: 10px;
}

.gilded-frame::before {
    content: "";
    position: absolute;
    top: var(--gf-inset);
    left: var(--gf-inset);
    width: var(--gf-arm);
    height: var(--gf-arm);
    border-top: var(--gf-thick) solid var(--gf-color);
    border-left: var(--gf-thick) solid var(--gf-color);
    pointer-events: none;
}

.gilded-frame::after {
    content: "";
    position: absolute;
    top: var(--gf-inset);
    right: var(--gf-inset);
    width: var(--gf-arm);
    height: var(--gf-arm);
    border-top: var(--gf-thick) solid var(--gf-color);
    border-right: var(--gf-thick) solid var(--gf-color);
    pointer-events: none;
}

/* For bottom corners we wrap content with two extra ::before/::after on a sentinel.
   Using a stacked technique: the .gilded-frame's children inherit pseudo positions.
   We introduce a child selector ".gilded-frame > *:last-child" approach via a dedicated
   ::before/::after pair using "filter" not possible — so we add an inline ::before
   on the ".gilded-frame" via outline rays plus two synthetic divs... Instead, use
   background-image to draw bottom corners: */
.gilded-frame {
    background-image:
        /* bottom-left corner: horizontal arm */
        linear-gradient(90deg, var(--c-gilded) 0, var(--c-gilded) 100%),
        /* bottom-left corner: vertical arm */
        linear-gradient(180deg, var(--c-gilded) 0, var(--c-gilded) 100%),
        /* bottom-right corner: horizontal arm */
        linear-gradient(90deg, var(--c-gilded) 0, var(--c-gilded) 100%),
        /* bottom-right corner: vertical arm */
        linear-gradient(180deg, var(--c-gilded) 0, var(--c-gilded) 100%);
    background-repeat: no-repeat;
    background-size:
        var(--gf-arm) var(--gf-thick),
        var(--gf-thick) var(--gf-arm),
        var(--gf-arm) var(--gf-thick),
        var(--gf-thick) var(--gf-arm);
    background-position:
        var(--gf-inset) calc(100% - var(--gf-inset)),
        var(--gf-inset) calc(100% - var(--gf-inset) - var(--gf-arm) + var(--gf-thick)),
        calc(100% - var(--gf-inset)) calc(100% - var(--gf-inset)),
        calc(100% - var(--gf-inset)) calc(100% - var(--gf-inset) - var(--gf-arm) + var(--gf-thick));
}

/* ==========================================================================
   Content blocks
   ========================================================================== */

.content-block {
    position: relative;
    width: 100%;
    max-width: var(--content-max);
    padding: clamp(40px, 6vw, 64px) clamp(28px, 5vw, 56px);
    background: rgba(10, 10, 18, 0.45);
}

.content-block--narrow {
    max-width: var(--content-narrow);
    text-align: center;
}

.kicker {
    font-family: var(--font-menu);
    font-weight: 300;
    font-size: 0.78rem;
    letter-spacing: 0.4em;
    text-transform: uppercase;
    color: var(--c-gilded);
    margin-bottom: 18px;
    display: inline-flex;
    align-items: center;
    gap: 12px;
}

.kicker::before {
    content: "";
    display: inline-block;
    width: 28px;
    height: 1px;
    background: var(--c-gilded);
}

.section-title {
    font-family: var(--font-display);
    font-weight: 400;
    font-size: clamp(2rem, 4.6vw, 3.2rem);
    line-height: 1.05;
    letter-spacing: 0.02em;
    color: var(--c-champagne);
    margin-bottom: 28px;
}

.section-title--final {
    color: var(--c-gilded);
}

.lede {
    font-family: var(--font-body);
    font-weight: 400;
    font-size: 1.08rem;
    line-height: 1.75;
    color: var(--c-champagne);
    margin-bottom: 1.4em;
    font-style: italic;
}

/* ==========================================================================
   Chevron dividers — clip-path zigzag
   ========================================================================== */

.chevron-divider {
    position: relative;
    width: 100%;
    height: 40px;
    background-color: var(--c-gilded);
    clip-path: polygon(
        0% 0%,
        4% 100%, 8% 0%,
        12% 100%, 16% 0%,
        20% 100%, 24% 0%,
        28% 100%, 32% 0%,
        36% 100%, 40% 0%,
        44% 100%, 48% 0%,
        52% 100%, 56% 0%,
        60% 100%, 64% 0%,
        68% 100%, 72% 0%,
        76% 100%, 80% 0%,
        84% 100%, 88% 0%,
        92% 100%, 96% 0%,
        100% 100%,
        100% 0%
    );
    /* a thin gold zigzag — keep it subtle by reducing height when overshadowed */
}

/* The clip-path above creates a downward-pointing zigzag of gold against the
   page's black backdrop. We want both: top-pointing teeth on the upper edge.
   Use a layered approach: this .chevron-divider sits on dark; the polygon
   produces alternating triangles that the eye reads as a chevron strip. */

.chevron-divider--alt {
    background-color: var(--c-whiskey);
}

/* A wrapper line above the chevron — a thin gold rule */
.chevron-divider::before,
.chevron-divider::after {
    content: "";
    position: absolute;
    left: 0;
    right: 0;
    height: 1px;
    background: rgba(201, 168, 76, 0.35);
}

.chevron-divider::before { top: 0; }
.chevron-divider::after  { bottom: 0; }

/* ==========================================================================
   Subtle background patterns inside rooms
   ========================================================================== */

.room-bg-pattern {
    position: absolute;
    inset: 0;
    background-image:
        repeating-linear-gradient(
            45deg,
            transparent 0,
            transparent 38px,
            rgba(201, 168, 76, 0.04) 38px,
            rgba(201, 168, 76, 0.04) 39px
        ),
        repeating-linear-gradient(
            -45deg,
            transparent 0,
            transparent 38px,
            rgba(201, 168, 76, 0.04) 38px,
            rgba(201, 168, 76, 0.04) 39px
        );
    pointer-events: none;
    z-index: 0;
}

.room-bg-pattern--vertical {
    background-image:
        repeating-linear-gradient(
            90deg,
            transparent 0,
            transparent 60px,
            rgba(201, 168, 76, 0.05) 60px,
            rgba(201, 168, 76, 0.05) 61px
        );
}

.room > .content-block {
    z-index: 2;
}

/* ==========================================================================
   The Menu — cocktail list
   ========================================================================== */

.cocktail-list {
    list-style: none;
    margin: 0 0 26px;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 26px;
}

.cocktail {
    border-bottom: 1px dashed rgba(201, 168, 76, 0.22);
    padding-bottom: 22px;
}

.cocktail:last-child {
    border-bottom: none;
    padding-bottom: 0;
}

.cocktail__head {
    display: grid;
    grid-template-columns: 36px 1fr auto;
    align-items: baseline;
    gap: 14px;
    margin-bottom: 8px;
}

.cocktail__number {
    font-family: var(--font-display);
    font-size: 1.1rem;
    color: var(--c-gilded);
    font-style: italic;
}

.cocktail__name {
    font-family: var(--font-display);
    font-weight: 400;
    font-size: clamp(1.25rem, 2.4vw, 1.55rem);
    color: var(--c-champagne);
    letter-spacing: 0.02em;
    line-height: 1.2;
}

.cocktail__price {
    font-family: var(--font-menu);
    font-weight: 300;
    font-size: 0.95rem;
    letter-spacing: 0.18em;
    color: var(--c-gilded);
}

.cocktail__desc {
    font-size: 0.96rem;
    color: var(--c-champagne);
    margin-left: 50px;
    margin-bottom: 0;
    line-height: 1.65;
    opacity: 0.92;
}

.menu-foot {
    margin-top: 22px;
    font-family: var(--font-menu);
    font-weight: 300;
    font-size: 0.78rem;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    color: var(--c-aged-brass);
    text-align: center;
}

/* ==========================================================================
   The Lounge — rules + quote
   ========================================================================== */

.rules-list {
    list-style: none;
    margin: 0 0 36px;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 18px;
}

.rules-list li {
    display: grid;
    grid-template-columns: 44px 1fr;
    gap: 14px;
    align-items: baseline;
    color: var(--c-champagne);
    font-size: 0.98rem;
    line-height: 1.7;
}

.rules-list__num {
    font-family: var(--font-display);
    color: var(--c-gilded);
    font-size: 1.15rem;
    letter-spacing: 0.04em;
}

.quote-block {
    margin-top: 28px;
    padding: 28px clamp(20px, 4vw, 36px);
    border-top: 1px solid rgba(201, 168, 76, 0.3);
    border-bottom: 1px solid rgba(201, 168, 76, 0.3);
    text-align: center;
}

.quote-block__text {
    font-family: var(--font-display);
    font-size: clamp(1.15rem, 2.2vw, 1.45rem);
    color: var(--c-gilded);
    line-height: 1.4;
    letter-spacing: 0.02em;
    margin-bottom: 14px;
    font-style: normal;
}

.quote-block__attr {
    font-family: var(--font-menu);
    font-weight: 300;
    font-size: 0.78rem;
    letter-spacing: 0.28em;
    text-transform: uppercase;
    color: var(--c-aged-brass);
    margin: 0;
}

/* ==========================================================================
   The Ledger — gilded table
   ========================================================================== */

.ledger-table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 8px;
    font-size: 0.96rem;
}

.ledger-table thead th {
    font-family: var(--font-menu);
    font-weight: 400;
    font-size: 0.74rem;
    letter-spacing: 0.32em;
    text-transform: uppercase;
    color: var(--c-gilded);
    text-align: left;
    padding: 10px 10px;
    border-bottom: 1px solid var(--c-gilded);
}

.ledger-table tbody td {
    padding: 14px 10px;
    border-bottom: 1px dashed rgba(138, 122, 90, 0.4);
    color: var(--c-champagne);
    vertical-align: top;
}

.ledger-table tbody tr:last-child td {
    border-bottom: 1px solid var(--c-gilded);
}

.ledger-table__col-year {
    width: 22%;
    font-family: var(--font-display);
    color: var(--c-gilded);
}

.ledger-table tbody td:first-child {
    font-family: var(--font-display);
    color: var(--c-gilded);
    font-size: 1.05rem;
}

.ledger-table__col-result,
.ledger-table tbody td:last-child {
    text-align: right;
    color: var(--c-aged-brass);
    font-style: italic;
    width: 32%;
}

.ledger-foot {
    margin-top: 22px;
    font-size: 0.92rem;
    color: var(--c-aged-brass);
    font-style: italic;
    text-align: center;
}

/* ==========================================================================
   The Invitation — closing
   ========================================================================== */

.closing-emblem {
    width: 200px;
    margin: 30px auto 18px;
    opacity: 0.9;
}

.closing-emblem svg {
    width: 100%;
    height: auto;
    display: block;
}

.signoff {
    font-family: var(--font-display);
    font-size: 1.2rem;
    color: var(--c-gilded);
    letter-spacing: 0.18em;
    margin-top: 4px;
}

/* ==========================================================================
   Cocktail-menu fixed bottom navigation
   ========================================================================== */

.menu-bar {
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    height: var(--bar-height);
    background: rgba(10, 10, 18, 0.95);
    border-top: 1px solid var(--c-gilded);
    z-index: 100;
    backdrop-filter: blur(6px);
    -webkit-backdrop-filter: blur(6px);
    padding: 8px 0;
}

.menu-bar__inner {
    height: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 clamp(16px, 4vw, 36px);
    display: flex;
    align-items: center;
    gap: clamp(14px, 3vw, 36px);
}

.menu-bar__title {
    font-family: var(--font-display);
    font-size: 1.1rem;
    color: var(--c-gilded);
    letter-spacing: 0.18em;
    white-space: nowrap;
    padding-right: clamp(10px, 2vw, 24px);
    border-right: 1px solid rgba(201, 168, 76, 0.35);
    flex-shrink: 0;
}

.menu-bar__list {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    align-items: center;
    gap: clamp(10px, 2.5vw, 26px);
    overflow-x: auto;
    scrollbar-width: none;
    -ms-overflow-style: none;
    flex: 1;
}

.menu-bar__list::-webkit-scrollbar {
    display: none;
}

.menu-bar__link {
    display: inline-flex;
    align-items: baseline;
    gap: 8px;
    color: var(--c-aged-brass);
    font-family: var(--font-menu);
    font-weight: 300;
    font-size: 0.85rem;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    transition: color 320ms ease;
    white-space: nowrap;
    position: relative;
    padding: 4px 0;
}

.menu-bar__num {
    font-family: var(--font-display);
    font-style: italic;
    color: var(--c-gilded);
    font-size: 0.95rem;
    letter-spacing: 0;
    opacity: 0.8;
    transition: opacity 320ms ease;
}

.menu-bar__name {
    transition: color 320ms ease;
}

.menu-bar__link::after {
    content: "";
    position: absolute;
    left: 0;
    right: 0;
    bottom: -4px;
    height: 1px;
    background: var(--c-gilded);
    transform: scaleX(0);
    transform-origin: center;
    transition: transform 360ms ease;
}

.menu-bar__link:hover {
    color: var(--c-champagne);
}

.menu-bar__link:hover .menu-bar__num {
    opacity: 1;
}

.menu-bar__link:hover::after {
    transform: scaleX(1);
}

.menu-bar__link.is-active {
    color: var(--c-champagne);
}

.menu-bar__link.is-active::after {
    transform: scaleX(1);
}

/* ==========================================================================
   Reveal-on-scroll
   ========================================================================== */

.content-block {
    opacity: 0;
    transform: translateY(28px);
    transition: opacity 900ms ease, transform 900ms ease;
}

.content-block.is-revealed {
    opacity: 1;
    transform: translateY(0);
}

/* The hero-frame inside hero room is treated as visible immediately */
.room--hero .hero-frame {
    opacity: 1;
    transform: none;
    transition: none;
}

/* ==========================================================================
   Responsive
   ========================================================================== */

@media (max-width: 720px) {
    :root {
        --bar-height: 56px;
    }

    .room {
        padding: clamp(70px, 10vh, 100px) 18px;
        min-height: 95vh;
    }

    .menu-bar__title {
        font-size: 0.95rem;
        padding-right: 12px;
    }

    .cocktail__desc {
        margin-left: 0;
    }

    .cocktail__head {
        grid-template-columns: 28px 1fr auto;
        gap: 10px;
    }

    .ledger-table thead th {
        font-size: 0.65rem;
        letter-spacing: 0.2em;
        padding: 8px 6px;
    }

    .ledger-table tbody td {
        padding: 12px 6px;
        font-size: 0.92rem;
    }
}

@media (max-width: 480px) {
    .menu-bar__title {
        display: none;
    }

    .hero-marque {
        font-size: 0.66rem;
        letter-spacing: 0.22em;
    }

    .hero-meta {
        font-size: 0.66rem;
        letter-spacing: 0.18em;
    }
}

@media (prefers-reduced-motion: reduce) {
    .hero-sunburst,
    .hero-emblem svg {
        animation: none;
    }

    .hero-emblem,
    .hero-title,
    .hero-tag,
    .hero-meta,
    .hero-scrollcue {
        opacity: 1;
        animation: none;
    }

    .content-block {
        opacity: 1;
        transform: none;
        transition: none;
    }

    html {
        scroll-behavior: auto;
    }
}
