/* Public site (static SSR pages using PublicLayout). Built on the admin theme tokens in admin.css, so
   brand colours set under Settings > Appearance carry over, light and dark. Flat colour only: no
   gradients anywhere. Background artwork comes from patterns.css; content and toggles from
   Settings > Public site. */

.public-shell {
    --public-bg: #ffffff;
    --public-bg-alt: #f3f6fb;
    --public-surface: #ffffff;
    --public-text: #141b2d;
    --public-muted: #59657d;
    --public-border: #e2e7f0;
    --public-max: 1360px;
    --public-ease: cubic-bezier(.2, .7, .2, 1);
    /* Surfaces that carry white text. The button colour stays deep in dark mode, where
       --admin-brand turns light and white text on it would fail contrast. */
    --public-solid: var(--admin-btn-bg);

    position: relative;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    background: var(--public-bg);
    color: var(--public-text);
    overflow-x: clip;
}

[data-bs-theme="dark"] .public-shell {
    --public-bg: #0d1424;
    --public-bg-alt: #111a2d;
    --public-surface: #152038;
    --public-text: #e8ecf3;
    --public-muted: #9ba7bd;
    --public-border: #24314a;
}

.public-container {
    width: 100%;
    max-width: var(--public-max);
    margin: 0 auto;
    padding: 0 16px;
}

@media (min-width: 768px) {
    .public-container { padding: 0 32px; }
}

.public-skip {
    position: absolute;
    left: 16px;
    top: 8px;
    z-index: 1100;
    padding: .5rem 1rem;
    background: var(--admin-brand);
    color: #fff;
    border-radius: var(--admin-radius-sm);
}

/* Announcement bar */

.public-announcement {
    background: var(--admin-navy);
    color: #fff;
    font-size: .9rem;
    font-weight: 600;
}

.public-announcement .public-container {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: .6rem;
    min-height: 2.5rem;
    text-align: center;
}

.public-announcement a { color: #fff; text-decoration: underline; text-underline-offset: 3px; }
.public-announcement .fa-bullhorn { color: var(--admin-accent); }

/* Header */

.public-header {
    position: sticky;
    top: 0;
    z-index: 1000;
    background: var(--public-bg);
    border-bottom: 1px solid var(--public-border);
    transition: box-shadow .25s ease;
}

.public-header-row {
    display: flex;
    align-items: center;
    gap: 1.25rem;
    min-height: 4.5rem;
}

.public-brand {
    display: inline-flex;
    align-items: center;
    gap: .6rem;
    font-weight: 800;
    font-size: 1.25rem;
    letter-spacing: -.01em;
    color: var(--public-text);
    text-decoration: none;
    white-space: nowrap;
}

.public-brand:hover { color: var(--admin-brand); }
.public-brand-logo { width: auto; height: 36px; transition: transform .3s var(--public-ease); }
.public-brand:hover .public-brand-logo { transform: rotate(-8deg) scale(1.06); }

.public-search {
    flex: 1 1 auto;
    max-width: 460px;
    align-items: center;
    gap: .6rem;
    padding: 0 1rem;
    height: 2.75rem;
    border: 1px solid var(--public-border);
    border-radius: 999px;
    background: var(--public-bg-alt);
    color: var(--public-muted);
    transition: border-color .2s ease, box-shadow .2s ease;
}

.public-search:focus-within { border-color: var(--admin-brand); box-shadow: 0 0 0 4px var(--admin-brand-soft); }

.public-search input {
    flex: 1;
    min-width: 0;
    border: 0;
    background: transparent;
    color: var(--public-text);
    outline: none;
}

.public-nav {
    margin-left: auto;
    display: flex;
    align-items: center;
    gap: .5rem;
}

.public-nav-link {
    position: relative;
    display: inline-flex;
    align-items: center;
    padding: .45rem .7rem;
    color: var(--public-text);
    font-weight: 600;
    text-decoration: none;
    white-space: nowrap;
}

/* Underline that grows from the left on hover. */
.public-nav-link::after {
    content: "";
    position: absolute;
    left: .7rem;
    right: .7rem;
    bottom: .2rem;
    height: 2px;
    background: var(--admin-brand);
    transform: scaleX(0);
    transform-origin: left;
    transition: transform .25s var(--public-ease);
}

.public-nav-link:hover { color: var(--admin-brand); }
.public-nav-link:hover::after { transform: scaleX(1); }

.public-btn { border-radius: 999px; padding: .45rem 1.1rem; font-weight: 700; }

.public-shell .btn { transition: transform .2s var(--public-ease), background-color .2s ease, box-shadow .2s ease; }
.public-shell .btn-primary:hover { transform: translateY(-1px); box-shadow: 0 6px 16px -6px var(--admin-brand); }
.public-shell .btn-primary:active { transform: translateY(0); }

/* Hero */

.public-main { flex: 1 0 auto; }

.public-hero {
    position: relative;
    padding: 4.5rem 0 5rem;
    background: var(--public-bg-alt);
    overflow: hidden;
    isolation: isolate;
}

.public-hero > .pattern { z-index: -1; }

/* Flat decorative shapes that drift slowly behind the content. */
.public-hero-shape {
    position: absolute;
    z-index: -1;
    pointer-events: none;
}

.shape-circle {
    width: 22rem;
    height: 22rem;
    right: -6rem;
    top: -7rem;
    border-radius: 50%;
    background: var(--admin-brand);
    opacity: .1;
}

.shape-ring {
    width: 9rem;
    height: 9rem;
    left: 46%;
    bottom: -3rem;
    border-radius: 50%;
    border: 14px solid var(--admin-accent);
    opacity: .22;
}

.shape-square {
    width: 4.5rem;
    height: 4.5rem;
    left: 4%;
    top: 12%;
    border-radius: 1rem;
    background: var(--admin-accent);
    opacity: .16;
    transform: rotate(18deg);
}

.public-hero-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 3rem;
    align-items: center;
}

@media (min-width: 992px) {
    .public-hero-grid { grid-template-columns: 1.15fr 1fr; gap: 4rem; }
}

.public-eyebrow {
    display: inline-flex;
    align-items: center;
    gap: .5rem;
    margin-bottom: 1.25rem;
    padding: .35rem .9rem;
    border-radius: 999px;
    background: var(--public-surface);
    border: 1px solid var(--public-border);
    font-weight: 700;
    font-size: .85rem;
    color: var(--public-text);
}

.public-eyebrow-dot {
    width: .55rem;
    height: .55rem;
    border-radius: 50%;
    background: var(--admin-accent);
}

.public-hero h1 {
    font-size: clamp(2.3rem, 5.2vw, 4.1rem);
    font-weight: 800;
    line-height: 1.06;
    letter-spacing: -.03em;
    margin-bottom: 1.25rem;
    max-width: 16ch;
}

.public-hero-tagline {
    font-size: clamp(1.05rem, 1.4vw, 1.25rem);
    color: var(--public-muted);
    max-width: 52ch;
    margin-bottom: 2.25rem;
}

.public-hero-search {
    display: flex;
    align-items: center;
    gap: .6rem;
    max-width: 600px;
    padding: .4rem .4rem .4rem 1.2rem;
    border: 1px solid var(--public-border);
    border-radius: 999px;
    background: var(--public-surface);
    box-shadow: 0 18px 40px -22px rgba(13, 30, 60, .35);
    color: var(--public-muted);
    transition: border-color .2s ease, box-shadow .2s ease;
}

.public-hero-search:focus-within { border-color: var(--admin-brand); box-shadow: 0 0 0 4px var(--admin-brand-soft); }

.public-hero-search input {
    flex: 1;
    min-width: 0;
    border: 0;
    background: transparent;
    color: var(--public-text);
    font-size: 1.05rem;
    outline: none;
}

.public-hero-search .btn { border-radius: 999px; padding: .65rem 1.4rem; font-weight: 700; white-space: nowrap; }
.public-hero-search-inline { margin-bottom: 2rem; box-shadow: none; }

.public-hero-media {
    border-radius: 1.5rem;
    overflow: hidden;
    aspect-ratio: 4 / 3;
    background: var(--public-surface);
    box-shadow: 0 30px 60px -30px rgba(13, 30, 60, .45);
}

.public-hero-media img,
.public-hero-media video,
.public-hero-media iframe { width: 100%; height: 100%; object-fit: cover; border: 0; display: block; }

/* Illustrated ticket stack (when no hero image is set). */

.ticket-stack {
    position: relative;
    height: 25rem;
    max-width: 30rem;
    margin: 1.5rem auto 0;
}

.ticket {
    position: absolute;
    left: 50%;
    top: 50%;
    width: min(26rem, 92%);
    display: flex;
    border-radius: 1.1rem;
    color: #fff;
    box-shadow: 0 24px 40px -24px rgba(10, 20, 40, .55);
}

/* Punched notches between the main part and the stub, cut in the hero's own background colour. */
.ticket::before,
.ticket::after {
    content: "";
    position: absolute;
    right: 6.2rem;
    width: 1.4rem;
    height: 1.4rem;
    border-radius: 50%;
    background: var(--public-bg-alt);
    transform: translateX(50%);
}

.ticket::before { top: -.7rem; }
.ticket::after { bottom: -.7rem; }

.ticket-main {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: .25rem;
    padding: 1.4rem 1.5rem;
    font-size: .9rem;
}

.ticket-main strong { font-size: 1.3rem; font-weight: 800; line-height: 1.2; }
.ticket-main span { opacity: .9; }

.ticket-tag {
    align-self: flex-start;
    margin-bottom: .35rem;
    padding: .15rem .6rem;
    border-radius: 999px;
    background: rgba(255, 255, 255, .2);
    font-size: .72rem;
    font-weight: 800;
    letter-spacing: .08em;
    text-transform: uppercase;
    opacity: 1 !important;
}

.ticket-price { margin-top: .5rem; font-size: 1.15rem; font-weight: 800; opacity: 1 !important; }

.ticket-stub {
    width: 6.2rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: .6rem;
    border-left: 2px dashed rgba(255, 255, 255, .55);
}

/* A QR-ish block made from a solid-shape mask, so it stays flat. */
.ticket-qr {
    width: 3.4rem;
    height: 3.4rem;
    border-radius: .35rem;
    background: #fff;
    -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 21 21'%3E%3Cpath d='M0 0h7v7H0zM14 0h7v7h-7zM0 14h7v7H0zM2 2v3h3V2zM16 2v3h3V2zM2 16v3h3v-3zM9 0h2v2H9zM9 4h3v3H9zM8 9h4v2H8zM14 9h2v3h-2zM18 9h3v2h-3zM9 13h2v4H9zM13 14h3v2h-3zM17 14h4v3h-4zM12 18h4v3h-4zM18 19h3v2h-3z'/%3E%3C/svg%3E") center / contain no-repeat;
    mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 21 21'%3E%3Cpath d='M0 0h7v7H0zM14 0h7v7h-7zM0 14h7v7H0zM2 2v3h3V2zM16 2v3h3V2zM2 16v3h3v-3zM9 0h2v2H9zM9 4h3v3H9zM8 9h4v2H8zM14 9h2v3h-2zM18 9h3v2h-3zM9 13h2v4H9zM13 14h3v2h-3zM17 14h4v3h-4zM12 18h4v3h-4zM18 19h3v2h-3z'/%3E%3C/svg%3E") center / contain no-repeat;
}

.ticket-admit { font-size: .6rem; font-weight: 800; letter-spacing: .12em; writing-mode: vertical-rl; transform: rotate(180deg); display: none; }

.ticket-back {
    background: var(--admin-accent);
    transform: translate(-50%, -50%) translate(2.2rem, -6.2rem) rotate(8deg);
}

.ticket-mid {
    background: var(--admin-navy);
    transform: translate(-50%, -50%) translate(-1.8rem, -2.4rem) rotate(-6deg);
}

.ticket-front {
    background: var(--public-solid);
    transform: translate(-50%, -50%) translate(0, 3rem) rotate(-1deg);
}

/* Ticker */

.public-ticker {
    position: relative;
    overflow: hidden;
    background: var(--public-solid);
    color: #fff;
    padding: .9rem 0;
}

.public-ticker-track { display: flex; width: max-content; }

.public-ticker ul {
    display: flex;
    gap: 0;
    margin: 0;
    padding: 0;
    list-style: none;
}

.public-ticker li { display: flex; align-items: center; }

.public-ticker li::after {
    content: "";
    width: .5rem;
    height: .5rem;
    margin: 0 1.75rem;
    background: var(--admin-accent);
    transform: rotate(45deg);
}

.public-ticker a {
    color: #fff;
    font-weight: 800;
    font-size: 1.05rem;
    letter-spacing: .02em;
    text-decoration: none;
    white-space: nowrap;
}

.public-ticker a:hover { text-decoration: underline; text-underline-offset: 4px; }

/* Sections */

.public-section { position: relative; padding: 4.5rem 0; }
.public-section-alt { background: var(--public-bg-alt); }

.public-section h2,
.public-page-title {
    font-size: clamp(1.6rem, 3vw, 2.35rem);
    font-weight: 800;
    letter-spacing: -.02em;
    margin-bottom: 1.75rem;
}

.public-section-head {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 1rem;
}

.public-link-arrow { font-weight: 700; white-space: nowrap; text-decoration: none; }
.public-link-arrow i { margin-left: .35rem; transition: transform .25s var(--public-ease); }
.public-link-arrow:hover i { transform: translateX(4px); }

.public-empty {
    text-align: center;
    padding: 3.5rem 1rem;
    border: 2px dashed var(--public-border);
    border-radius: 1.25rem;
    color: var(--public-muted);
    background: var(--public-surface);
}

.public-empty-icon {
    display: inline-grid;
    place-items: center;
    width: 4rem;
    height: 4rem;
    margin-bottom: 1rem;
    border-radius: 1.1rem;
    background: var(--admin-brand-soft);
    color: var(--admin-brand);
    font-size: 1.6rem;
}

.public-empty p { margin: 0; }
.public-empty .public-empty-title { color: var(--public-text); font-weight: 800; font-size: 1.15rem; margin-bottom: .25rem; }

.public-features {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 1.5rem;
}

.public-feature {
    position: relative;
    padding: 2rem;
    border-radius: 1.25rem;
    background: var(--public-surface);
    border: 1px solid var(--public-border);
    transition: transform .3s var(--public-ease), border-color .3s ease, box-shadow .3s ease;
}

/* A flat accent bar that slides in along the top edge on hover. */
.public-feature::before {
    content: "";
    position: absolute;
    left: 2rem;
    right: 2rem;
    top: -1px;
    height: 4px;
    border-radius: 0 0 4px 4px;
    background: var(--admin-accent);
    transform: scaleX(0);
    transition: transform .35s var(--public-ease);
}

.public-feature:hover {
    transform: translateY(-6px);
    border-color: var(--admin-brand);
    box-shadow: 0 24px 40px -28px rgba(13, 30, 60, .4);
}

.public-feature:hover::before { transform: scaleX(1); }

.public-feature h3 { font-size: 1.15rem; font-weight: 800; margin: 1.25rem 0 .5rem; }
.public-feature p { color: var(--public-muted); margin: 0; }

.public-feature-icon {
    display: inline-grid;
    place-items: center;
    width: 3.25rem;
    height: 3.25rem;
    border-radius: 1rem;
    background: var(--admin-brand-soft);
    color: var(--admin-brand);
    font-size: 1.3rem;
    transition: background-color .3s ease, color .3s ease, transform .3s var(--public-ease);
}

.public-feature:hover .public-feature-icon {
    background: var(--admin-brand);
    color: #fff;
    transform: rotate(-6deg);
}

/* Organizer call to action: solid brand panel with the pattern in white and ticket notches. */
.public-cta {
    position: relative;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 1.5rem;
    padding: 2.25rem 1.75rem;
    border-radius: 1.5rem;
    background: var(--public-solid);
    color: #fff;
    overflow: hidden;
    isolation: isolate;
}

.public-cta > .pattern { z-index: -1; }
.public-cta .pattern-a { background-color: #fff; }
.public-cta .pattern-b { background-color: var(--admin-navy); }

.public-cta::before,
.public-cta::after {
    content: "";
    position: absolute;
    top: 50%;
    width: 2.5rem;
    height: 2.5rem;
    border-radius: 50%;
    background: var(--public-bg);
    transform: translateY(-50%);
}

.public-cta::before { left: -1.25rem; }
.public-cta::after { right: -1.25rem; }

.public-cta-copy { max-width: 62ch; }
.public-cta h2 { color: #fff; margin-bottom: .6rem; }
.public-cta p { margin: 0; font-size: 1.05rem; opacity: .95; }

.public-cta-btn {
    background: #fff;
    color: var(--admin-navy);
    border: 0;
    border-radius: 999px;
    padding: .8rem 1.6rem;
    font-weight: 800;
}

.public-cta-btn:hover { background: var(--admin-accent); color: var(--admin-accent-fg, #fff); transform: translateY(-2px); }

@media (min-width: 768px) {
    .public-cta { padding: 3rem 3.5rem; }
}

/* Footer */

.public-footer {
    position: relative;
    padding: 3rem 0 2.5rem;
    background: var(--public-bg-alt);
    border-top: 1px solid var(--public-border);
    overflow: hidden;
    isolation: isolate;
}

.public-footer > .pattern { z-index: -1; opacity: .7; }

.public-footer-row {
    display: flex;
    flex-wrap: wrap;
    gap: 1.5rem 3rem;
    justify-content: space-between;
}

.public-footer-note { color: var(--public-muted); margin: .6rem 0 0; max-width: 42ch; }

.public-footer-links { display: flex; flex-wrap: wrap; gap: .5rem 1.75rem; }
.public-footer-links a { color: var(--public-text); text-decoration: none; font-weight: 700; }
.public-footer-links a:hover { color: var(--admin-brand); }

.public-footer-copy { width: 100%; color: var(--public-muted); font-size: .875rem; margin: 0; }

/* Motion. Only when the admin left animations on, and never for visitors who ask their device for
   reduced motion. */

@media (prefers-reduced-motion: no-preference) {
    .public-motion .ticket-front { animation: ticket-float-front 7s ease-in-out infinite; }
    .public-motion .ticket-mid { animation: ticket-float-mid 8s ease-in-out infinite; }
    .public-motion .ticket-back { animation: ticket-float-back 9s ease-in-out infinite; }
    .public-motion .shape-circle { animation: drift 18s ease-in-out infinite; }
    .public-motion .shape-ring { animation: drift 14s ease-in-out infinite reverse; }
    .public-motion .shape-square { animation: spin-slow 30s linear infinite; }
    .public-motion .public-eyebrow-dot { animation: pulse-dot 2.2s ease-in-out infinite; }
    .public-motion .public-ticker-track { animation: ticker 38s linear infinite; }
    .public-motion .public-ticker:hover .public-ticker-track { animation-play-state: paused; }
    .public-motion .pattern-b { animation: pattern-drift 40s linear infinite; }

    /* Scroll reveal: hidden only once public.js has marked the page, so no-JS still shows everything. */
    .js-reveal .public-motion .reveal {
        opacity: 0;
        transform: translateY(22px);
        transition: opacity .7s var(--public-ease), transform .7s var(--public-ease);
        transition-delay: calc(var(--d, 0) * 90ms);
    }

    .js-reveal .public-motion .reveal.is-visible { opacity: 1; transform: none; }
}

/* Tickets: the same translate as their resting state, plus a gentle bob. */
@keyframes ticket-float-front {
    0%, 100% { transform: translate(-50%, -50%) translate(0, 3rem) rotate(-1deg); }
    50% { transform: translate(-50%, -50%) translate(0, 2.4rem) rotate(0deg); }
}

@keyframes ticket-float-mid {
    0%, 100% { transform: translate(-50%, -50%) translate(-1.8rem, -2.4rem) rotate(-6deg); }
    50% { transform: translate(-50%, -50%) translate(-2.2rem, -2.9rem) rotate(-8deg); }
}

@keyframes ticket-float-back {
    0%, 100% { transform: translate(-50%, -50%) translate(2.2rem, -6.2rem) rotate(8deg); }
    50% { transform: translate(-50%, -50%) translate(2.6rem, -6.6rem) rotate(10deg); }
}

@keyframes drift {
    0%, 100% { transform: translate(0, 0); }
    50% { transform: translate(-1.5rem, 1rem); }
}

@keyframes spin-slow { to { transform: rotate(378deg); } }

@keyframes pulse-dot {
    0%, 100% { transform: scale(1); opacity: 1; }
    50% { transform: scale(1.5); opacity: .6; }
}

@keyframes ticker { to { transform: translateX(-50%); } }

@keyframes pattern-drift {
    to { -webkit-mask-position: 160px 80px; mask-position: 160px 80px; }
}

/* Phone widths. */
@media (max-width: 575.98px) {
    .public-header-row { gap: .5rem; min-height: 4rem; }
    .public-header .public-brand span { display: none; }
    .public-nav { gap: .25rem; }
    .public-hero { padding: 2.75rem 0 3.5rem; }
    .public-hero-search { padding-left: .9rem; }
    .public-hero-search .btn { padding-inline: .9rem; }
    .ticket-stack { height: 19rem; scale: .74; margin-top: -1.5rem; margin-bottom: -2rem; }
    .ticket-main strong { font-size: 1.1rem; }
    .ticket-stub { width: 5rem; }
    .ticket::before, .ticket::after { right: 5rem; }
    .public-section { padding: 3.25rem 0; }
}

@media (min-width: 576px) {
    .ticket-admit { display: block; }
}

/* ---------------------------------------------------------------------------
   Events: cards, listing, event page. Flat fills; motion only via .public-motion.
--------------------------------------------------------------------------- */

.public-section-tight { padding-top: 2.75rem; }

.events-head { display: flex; align-items: baseline; justify-content: space-between; gap: 1rem; flex-wrap: wrap; }
.events-head .public-page-title { margin-bottom: 1rem; }

.category-chips { display: flex; flex-wrap: wrap; gap: .5rem; margin-bottom: 2rem; }

.category-chip {
    display: inline-flex;
    align-items: center;
    gap: .45rem;
    padding: .45rem .95rem;
    border: 1px solid var(--public-border);
    border-radius: 999px;
    background: var(--public-surface);
    color: var(--public-text);
    font-weight: 600;
    font-size: .9rem;
    text-decoration: none;
    transition: background-color .2s ease, color .2s ease, border-color .2s ease, transform .2s var(--public-ease);
}

.category-chip i { color: var(--admin-brand); transition: color .2s ease; }
.category-chip:hover { border-color: var(--admin-brand); transform: translateY(-1px); color: var(--public-text); }
.category-chip.active { background: var(--public-solid); border-color: var(--public-solid); color: #fff; }
.category-chip.active i { color: #fff; }

.event-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
    gap: 1.5rem;
}

.event-card {
    display: flex;
    flex-direction: column;
    border-radius: 1.25rem;
    overflow: hidden;
    background: var(--public-surface);
    border: 1px solid var(--public-border);
    color: var(--public-text);
    text-decoration: none;
    transition: transform .3s var(--public-ease), box-shadow .3s ease, border-color .3s ease;
}

.event-card:hover {
    transform: translateY(-6px);
    border-color: var(--admin-brand);
    box-shadow: 0 26px 44px -30px rgba(13, 30, 60, .45);
    color: var(--public-text);
}

.event-card:focus-visible { outline: 3px solid var(--admin-brand); outline-offset: 3px; }

.event-card-media {
    position: relative;
    aspect-ratio: 16 / 9;
    background: var(--public-bg-alt);
    overflow: hidden;
}

.event-card-media img { width: 100%; height: 100%; object-fit: cover; transition: transform .6s var(--public-ease); }
.event-card:hover .event-card-media img { transform: scale(1.05); }

.event-card-placeholder {
    position: relative;
    width: 100%;
    height: 100%;
    display: grid;
    place-items: center;
    background: var(--public-bg-alt);
    color: var(--admin-brand);
    font-size: 2.4rem;
}

.event-card-date {
    position: absolute;
    left: .85rem;
    top: .85rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    min-width: 3.2rem;
    padding: .35rem .5rem;
    border-radius: .8rem;
    background: var(--public-surface);
    color: var(--public-text);
    line-height: 1.05;
    box-shadow: 0 8px 18px -10px rgba(10, 20, 40, .45);
}

.event-card-date span { font-size: .68rem; font-weight: 800; letter-spacing: .08em; color: var(--public-muted); }
.event-card-date strong { font-size: 1.35rem; font-weight: 800; }

.event-card-flag {
    position: absolute;
    right: .85rem;
    top: .85rem;
    padding: .25rem .7rem;
    border-radius: 999px;
    background: #141b2d;
    color: #fff;
    font-size: .75rem;
    font-weight: 800;
}

.event-card-body { display: flex; flex-direction: column; gap: .3rem; padding: 1.1rem 1.2rem 1.25rem; flex: 1; }
.event-card-category { font-size: .72rem; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; color: var(--admin-brand); }
.event-card-body h3 { font-size: 1.1rem; font-weight: 800; line-height: 1.3; margin: 0 0 .25rem; }
.event-card-meta { margin: 0; color: var(--public-muted); font-size: .9rem; display: flex; gap: .5rem; align-items: baseline; }
.event-card-meta i { width: 1rem; text-align: center; color: var(--public-muted); }

.event-card-foot {
    margin-top: auto;
    padding-top: .75rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: .5rem;
    border-top: 1px dashed var(--public-border);
}

.event-card-price { font-weight: 800; color: var(--public-text); }
.event-card-by { font-size: .8rem; color: var(--public-muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 55%; }

.events-pager { display: flex; justify-content: center; align-items: center; gap: 1rem; margin-top: 2.5rem; }

/* Event page */

.event-hero {
    position: relative;
    padding: 3rem 0;
    background: var(--public-bg-alt);
    overflow: hidden;
    isolation: isolate;
}

.event-hero > .pattern { z-index: -1; }

.event-hero-grid { display: grid; gap: 2.5rem; align-items: center; }

@media (min-width: 992px) {
    .event-hero-grid { grid-template-columns: 1.1fr 1fr; gap: 3.5rem; }
}

.event-hero-media {
    aspect-ratio: 16 / 9;
    border-radius: 1.5rem;
    overflow: hidden;
    background: var(--public-surface);
    box-shadow: 0 30px 60px -32px rgba(13, 30, 60, .5);
}

.event-hero-media img { width: 100%; height: 100%; object-fit: cover; }

.event-hero-category {
    display: inline-block;
    margin-bottom: .9rem;
    padding: .3rem .85rem;
    border-radius: 999px;
    background: var(--public-solid);
    color: #fff;
    font-weight: 800;
    font-size: .78rem;
    letter-spacing: .06em;
    text-transform: uppercase;
    text-decoration: none;
}

.event-hero-category:hover { background: var(--admin-accent); color: var(--admin-accent-fg, #fff); }

.event-hero h1 {
    font-size: clamp(2rem, 4.4vw, 3.4rem);
    font-weight: 800;
    letter-spacing: -.03em;
    line-height: 1.08;
    margin-bottom: .9rem;
}

.event-hero-summary { font-size: 1.15rem; color: var(--public-muted); margin-bottom: 1.5rem; }

.event-facts { list-style: none; padding: 0; margin: 0; display: grid; gap: 1rem; }
.event-facts li { display: flex; gap: .9rem; align-items: flex-start; line-height: 1.45; color: var(--public-muted); }
.event-facts strong { color: var(--public-text); }

.event-fact-icon {
    flex: 0 0 2.6rem;
    height: 2.6rem;
    display: grid;
    place-items: center;
    border-radius: .85rem;
    background: var(--public-surface);
    border: 1px solid var(--public-border);
    color: var(--admin-brand);
}

.event-banner-note { background: var(--public-bg-alt); border-bottom: 1px solid var(--public-border); padding: .9rem 0; font-weight: 700; }
.event-banner-cancelled { background: #ffe7e3; color: #7d1219; border-color: #ffc4bb; }
[data-bs-theme="dark"] .event-banner-cancelled { background: #340d0b; color: #ffb4a8; border-color: #7d1f1a; }

.event-body-grid { display: grid; gap: 2.5rem; }

@media (min-width: 992px) {
    .event-body-grid { grid-template-columns: 1.4fr 1fr; align-items: start; }
    .event-tickets { position: sticky; top: 6rem; }
}

.event-about h2, .event-tickets h2 { font-size: 1.5rem; font-weight: 800; margin-bottom: 1rem; }
.event-about h3 { font-size: 1.1rem; font-weight: 800; margin: 2rem 0 .5rem; }
.event-about p { white-space: pre-line; font-size: 1.05rem; line-height: 1.7; color: var(--public-text); }

.event-tickets {
    padding: 1.5rem;
    border-radius: 1.25rem;
    background: var(--public-surface);
    border: 1px solid var(--public-border);
}

.ticket-list { list-style: none; padding: 0; margin: 0 0 1rem; display: grid; gap: .75rem; }

.ticket-row {
    position: relative;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1rem;
    padding: 1rem 1.1rem;
    border-radius: 1rem;
    border: 1px solid var(--public-border);
    background: var(--public-bg);
    transition: border-color .2s ease, transform .2s var(--public-ease);
}

/* A flat stub edge on the left, like a ticket. */
.ticket-row::before {
    content: "";
    position: absolute;
    left: 0;
    top: 1rem;
    bottom: 1rem;
    width: 4px;
    border-radius: 0 4px 4px 0;
    background: var(--admin-accent);
}

.ticket-row:hover { border-color: var(--admin-brand); transform: translateX(3px); }
.ticket-row.is-unavailable { opacity: .6; }
.ticket-row.is-unavailable::before { background: var(--public-border); }
.ticket-row-main { display: flex; flex-direction: column; gap: .15rem; }
.ticket-row-main .text-600 { font-size: .85rem; }
.ticket-row-state { font-size: .78rem; font-weight: 700; color: var(--admin-brand); }
.ticket-row.is-unavailable .ticket-row-state { color: var(--public-muted); }
.ticket-row-price { font-weight: 800; font-size: 1.1rem; white-space: nowrap; }

.ticket-row-buy { display: flex; flex-direction: column; align-items: flex-end; gap: .4rem; }

.ticket-qty {
    min-width: 4.25rem;
    padding: .35rem 1.9rem .35rem .75rem;
    border-radius: .65rem;
    border: 1px solid var(--public-border);
    background-color: var(--public-surface);
    color: var(--public-text);
    font-weight: 700;
    cursor: pointer;
    transition: border-color .2s ease, box-shadow .2s ease;
}

.ticket-qty:focus { outline: none; border-color: var(--admin-brand); box-shadow: 0 0 0 4px var(--admin-brand-soft); }

/* Checkout */

.checkout-grid { display: grid; gap: 1.5rem; align-items: start; }

@media (min-width: 992px) {
    .checkout-grid { grid-template-columns: minmax(0, 1.35fr) minmax(0, 1fr); gap: 2rem; }
    .checkout-summary { position: sticky; top: 6rem; }
}

.checkout-card {
    padding: 1.75rem;
    border-radius: 1.25rem;
    background: var(--public-surface);
    border: 1px solid var(--public-border);
}

.checkout-card h2 { font-size: 1.35rem; font-weight: 800; margin-bottom: .35rem; }
.checkout-card > p.text-600 { margin-bottom: 1.5rem; }

.checkout-field { display: flex; flex-direction: column; gap: .35rem; margin-bottom: 1.1rem; }
.checkout-field label { font-weight: 700; font-size: .92rem; }
.checkout-field small { color: var(--public-muted); font-size: .8rem; }

.checkout-field input, .checkout-field textarea {
    padding: .8rem 1rem;
    border-radius: .8rem;
    border: 1px solid var(--public-border);
    background: var(--public-bg);
    color: var(--public-text);
    font-size: 1rem;
    transition: border-color .2s ease, box-shadow .2s ease;
}

.checkout-field input:focus, .checkout-field textarea:focus { outline: none; border-color: var(--admin-brand); box-shadow: 0 0 0 4px var(--admin-brand-soft); }

.checkout-error {
    padding: .85rem 1rem;
    margin-bottom: 1.25rem;
    border-radius: .8rem;
    border: 1px solid #f1b0b7;
    background: #fdf0f1;
    color: #8a1c2b;
    font-weight: 600;
}

[data-bs-theme="dark"] .checkout-error { background: #3a1820; border-color: #6b2a36; color: #ffc9d0; }

.checkout-secure { margin: .85rem 0 0; text-align: center; font-size: .82rem; color: var(--public-muted); }

.checkout-event { display: flex; gap: 1rem; align-items: center; padding-bottom: 1.25rem; margin-bottom: 1.25rem; border-bottom: 1px dashed var(--public-border); }
.checkout-event img { width: 5.5rem; height: 5.5rem; object-fit: cover; border-radius: .9rem; flex-shrink: 0; }
.checkout-event div { display: flex; flex-direction: column; gap: .15rem; min-width: 0; }
.checkout-event strong { font-size: 1.1rem; font-weight: 800; line-height: 1.3; }
.checkout-event span { color: var(--public-muted); font-size: .88rem; }

.checkout-lines { list-style: none; padding: 0; margin: 0 0 1rem; display: grid; gap: .6rem; }
.checkout-lines li { display: flex; justify-content: space-between; gap: 1rem; }
.checkout-lines li span:last-child { font-weight: 700; white-space: nowrap; }

.checkout-total {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    padding-top: 1rem;
    border-top: 1px solid var(--public-border);
    font-weight: 700;
}

.checkout-total strong { font-size: 1.6rem; font-weight: 800; letter-spacing: -.02em; }
.checkout-change { display: inline-block; margin-top: 1rem; font-weight: 700; font-size: .9rem; }

/* Order page and e-tickets */

.order-wrap { max-width: 1200px; }

.order-body { display: grid; gap: 1.5rem; align-items: start; }
.order-body .ticket-grid { margin-bottom: 0; }
.order-body:not(.has-tickets) .order-summary { max-width: 560px; }

@media (min-width: 992px) {
    .order-body.has-tickets { grid-template-columns: minmax(0, 1fr) 340px; gap: 2rem; }
    .order-summary { position: sticky; top: 6rem; }
}

.order-state {
    display: flex;
    gap: 1.25rem;
    align-items: flex-start;
    padding: 1.75rem;
    margin-bottom: 2rem;
    border-radius: 1.25rem;
    background: var(--public-surface);
    border: 1px solid var(--public-border);
}

.order-state h1 { font-size: clamp(1.4rem, 2.6vw, 2rem); font-weight: 800; letter-spacing: -.02em; margin-bottom: .4rem; }
.order-state p { color: var(--public-muted); margin-bottom: 1rem; }
.order-state p:last-child { margin-bottom: 0; }

.order-state-icon {
    display: grid;
    place-items: center;
    flex-shrink: 0;
    width: 3.25rem;
    height: 3.25rem;
    border-radius: 1rem;
    background: var(--admin-brand-soft);
    color: var(--admin-brand);
    font-size: 1.35rem;
}

.order-state-paid { border-color: var(--admin-accent); }
.order-state-paid .order-state-icon { background: var(--admin-accent); color: var(--admin-accent-fg, #fff); animation: order-pop .5s var(--public-ease) both; }
.order-state-failed .order-state-icon { background: #fdf0f1; color: #b4233a; }

@keyframes order-pop { from { transform: scale(.4); opacity: 0; } to { transform: none; opacity: 1; } }

.order-summary { padding: 1.5rem 1.75rem; border-radius: 1.25rem; background: var(--public-surface); border: 1px solid var(--public-border); }
.order-summary h2 { font-size: 1.1rem !important; font-weight: 800; margin-bottom: 1rem !important; }
[data-bs-theme="dark"] .order-state-failed .order-state-icon { background: #3a1820; color: #ffc9d0; }

.event-fact-logo { background: #fff; padding: .25rem; overflow: hidden; }
.event-fact-logo img { width: 100%; height: 100%; object-fit: contain; }

/* Promo and unlock codes on the event page and at checkout */
.promo-note { display: flex; align-items: center; gap: .6rem; padding: .75rem 1rem; margin-bottom: 1rem; border-radius: .85rem; font-size: .92rem; }
.promo-note.is-ok { background: var(--admin-brand-soft); color: var(--public-text); border: 1px solid var(--admin-brand); }
.promo-note.is-ok i { color: var(--admin-brand); }
.promo-note.is-bad { background: #fdf0f1; color: #8a1c2b; border: 1px solid #f1b0b7; }
[data-bs-theme="dark"] .promo-note.is-bad { background: #3a1820; color: #ffc9d0; border-color: #6b2a36; }
.promo-note a { font-weight: 700; white-space: nowrap; }
.ticket-row-was { display: block; font-size: .8rem; font-weight: 600; color: var(--public-muted); text-align: right; }
.ticket-unlocked { margin-left: .4rem; padding: .1rem .5rem; border-radius: 999px; background: var(--admin-accent); color: var(--admin-accent-fg, #fff); font-size: .7rem; font-weight: 800; vertical-align: middle; }
.promo-entry { margin-top: 1rem; }
.promo-entry summary { cursor: pointer; font-weight: 700; font-size: .9rem; color: var(--admin-brand); }
.promo-form { display: flex; gap: .5rem; margin-top: .6rem; }
.promo-form input { flex: 1; min-width: 0; padding: .55rem .8rem; border: 1px solid var(--public-border); border-radius: .7rem; background: var(--public-bg);
    color: var(--public-text); text-transform: uppercase; font-weight: 700; letter-spacing: .04em; }
.promo-form input:focus { outline: none; border-color: var(--admin-brand); box-shadow: 0 0 0 4px var(--admin-brand-soft); }
.checkout-saving { color: var(--admin-brand); font-weight: 700; }

/* Buyer refund request (order page) */
.refund-ask { margin-top: 1.5rem; border-top: 1px solid var(--public-border); padding-top: 1rem; }
.refund-ask summary { cursor: pointer; font-weight: 600; font-size: .9rem; color: var(--public-muted); list-style: none; }
.refund-ask summary::-webkit-details-marker { display: none; }
.refund-ask summary::after { content: "+"; float: right; font-weight: 700; transition: transform .2s var(--public-ease); }
.refund-ask[open] summary::after { transform: rotate(45deg); }
.refund-ask[open] form, .refund-ask[open] .refund-ask-policy { animation: refund-ask-in .25s ease both; }
.refund-ask-policy { font-size: .85rem; margin: .75rem 0; color: var(--public-muted); }
.refund-ask textarea { width: 100%; resize: vertical; }
.refund-ask-state { display: flex; gap: .6rem; align-items: flex-start; margin-top: 1.5rem; padding: .85rem 1rem; border-radius: .9rem;
    background: var(--public-bg-alt); font-size: .875rem; }
.refund-ask-state i { margin-top: .2rem; color: var(--admin-brand); }
@keyframes refund-ask-in { from { opacity: 0; transform: translateY(-4px); } to { opacity: 1; transform: none; } }
@media (prefers-reduced-motion: reduce) { .refund-ask[open] form, .refund-ask[open] .refund-ask-policy { animation: none; } }

/* Passing tickets on */
.eticket-sent { opacity: .75; }
.eticket-sent .eticket-used { min-height: 9rem; }
.send-legend { font-size: .9rem; font-weight: 600; margin-bottom: .4rem; }
.send-pick { display: flex; align-items: center; gap: .6rem; padding: .55rem .8rem; border: 1px solid var(--public-border);
    border-radius: .8rem; margin-bottom: .4rem; cursor: pointer; font-weight: 500; }
.send-pick:has(input:checked) { border-color: var(--admin-brand); box-shadow: 0 0 0 3px var(--admin-brand-soft); }
.send-pick input { accent-color: var(--admin-brand); }
.eticket-action { font-weight: 700; font-size: .8rem; }

/* Waitlist (event page) */
.waitlist-pick { display: grid; grid-template-columns: 2fr 1fr; gap: .75rem; }
.waitlist-ask { margin-top: 1rem; }

/* Organizer page */
.orgpage-hero { display: grid; grid-template-columns: auto 1fr auto; gap: 1.5rem; align-items: center; padding: 2rem 0 1.25rem; }
.orgpage-hero-logo { width: 96px; height: 96px; border-radius: 1.5rem; background: #fff; border: 1px solid var(--public-border);
    display: grid; place-items: center; overflow: hidden; font-weight: 800; font-size: 2rem; color: var(--admin-brand); }
.orgpage-hero-logo img { width: 100%; height: 100%; object-fit: contain; padding: .5rem; }
.orgpage-hero-kicker { text-transform: uppercase; letter-spacing: .12em; font-size: .72rem; font-weight: 700; color: var(--public-muted); margin: 0 0 .25rem; }
.orgpage-hero h1 { font-size: clamp(1.8rem, 4vw, 2.6rem); font-weight: 800; margin: 0 0 .35rem; }
.orgpage-hero-meta { color: var(--public-muted); margin: 0; }
.orgpage-hero-action { display: grid; gap: .4rem; justify-items: end; text-align: right; }
.orgpage-hero-action small { color: var(--public-muted); max-width: 16rem; }
.orgpage-hero-bio { max-width: 52rem; font-size: 1.05rem; line-height: 1.65; margin: 0 0 2rem; white-space: pre-line; }
.event-org-link { color: inherit; text-decoration: none; }
.event-org-link:hover strong { text-decoration: underline; }
@media (max-width: 767.98px) {
    .orgpage-hero { grid-template-columns: auto 1fr; }
    .orgpage-hero-action { grid-column: 1 / -1; justify-items: start; text-align: left; }
    .orgpage-hero-logo { width: 72px; height: 72px; font-size: 1.5rem; }
}

/* Waiting room */
.queue-card { max-width: 560px; margin: 2rem auto; text-align: center; padding: 2.5rem 2rem; border: 1px solid var(--public-border);
    border-radius: 1.5rem; background: var(--public-surface); }
.queue-kicker { text-transform: uppercase; letter-spacing: .12em; font-size: .72rem; font-weight: 700; color: var(--public-muted); margin: 0 0 .5rem; }
.queue-card h1 { font-size: clamp(1.5rem, 3.5vw, 2rem); font-weight: 800; margin: 0 0 1.5rem; }
.queue-position strong { display: block; font-size: clamp(3rem, 10vw, 4.5rem); font-weight: 800; line-height: 1; color: var(--admin-brand); }
.queue-position span { color: var(--public-muted); }
.queue-bar { height: 6px; border-radius: 3px; background: var(--public-bg-alt); overflow: hidden; margin: 1.5rem 0; }
.queue-bar span { display: block; height: 100%; width: 30%; border-radius: 3px; background: var(--admin-brand);
    animation: queue-slide 1.6s var(--public-ease) infinite; }
@keyframes queue-slide { from { transform: translateX(-100%); } to { transform: translateX(340%); } }
@media (prefers-reduced-motion: reduce) { .queue-bar span { animation: none; width: 100%; opacity: .4; } }

/* Seat picker */
.seats-title { font-size: clamp(1.6rem, 3.5vw, 2.2rem); font-weight: 800; margin: 0 0 .35rem; }
.seat-legend { display: flex; gap: 1.25rem; list-style: none; padding: 0; margin: 1rem 0; font-size: .85rem; color: var(--public-muted); }
.seat-legend li { display: flex; align-items: center; gap: .4rem; }
.seat-dot { width: 1rem; height: 1rem; border-radius: .3rem; border: 1px solid var(--public-border); background: var(--public-surface); }
.seat-dot.is-picked { background: var(--admin-brand); border-color: var(--admin-brand); }
.seat-dot.is-taken { background: var(--public-bg-alt); border-style: dashed; }
.seat-stage { margin: 0 auto 1.5rem; max-width: 520px; text-align: center; padding: .5rem; border-radius: 0 0 2rem 2rem;
    background: var(--public-bg-alt); color: var(--public-muted); font-weight: 700; letter-spacing: .2em; text-transform: uppercase; font-size: .75rem; }
.seat-section { border: 1px solid var(--public-border); border-radius: 1.25rem; padding: 1rem 1rem 1.25rem; margin: 0 0 1.25rem; }
.seat-section legend { float: none; width: auto; padding: 0 .5rem; font-size: 1rem; display: flex; gap: .6rem; align-items: baseline; flex-wrap: wrap; }
.seat-section legend span { color: var(--public-muted); font-size: .85rem; }
.seat-scroll { overflow-x: auto; padding-bottom: .25rem; }
.seat-row { display: flex; align-items: center; gap: .3rem; margin: 0 auto .3rem; width: max-content; }
.seat-row-label { width: 1.6rem; text-align: center; font-weight: 700; font-size: .75rem; color: var(--public-muted); }
.seat { position: relative; cursor: pointer; }
.seat input { position: absolute; opacity: 0; inset: 0; margin: 0; cursor: pointer; }
.seat span { display: grid; place-items: center; width: 2rem; height: 2rem; border-radius: .5rem .5rem .3rem .3rem; font-size: .7rem; font-weight: 600;
    border: 1px solid var(--public-border); background: var(--public-surface); color: var(--public-text);
    transition: background-color .15s var(--public-ease), transform .15s var(--public-ease); }
.seat:hover span { transform: translateY(-2px); border-color: var(--admin-brand); }
.seat input:focus-visible + span { outline: 3px solid var(--admin-brand-soft); outline-offset: 1px; }
.seat input:checked + span { background: var(--admin-brand); border-color: var(--admin-brand); color: #fff; }
.seat.is-taken { cursor: not-allowed; }
.seat.is-taken span { background: var(--public-bg-alt); border-style: dashed; color: transparent; transform: none; }
.seat-continue { position: sticky; bottom: 0; display: flex; flex-wrap: wrap; align-items: center; gap: 1rem; padding: 1rem 0;
    background: var(--public-bg); border-top: 1px solid var(--public-border); }
.ticket-seats { white-space: nowrap; }
.eticket-seat { display: block; font-weight: 700; color: var(--admin-brand); }
@media (prefers-reduced-motion: reduce) { .seat span { transition: none; } .seat:hover span { transform: none; } }
.checkout-seats { font-size: .82rem; color: var(--public-muted); }

/* Wallet buttons (black, as both wallets ask) */
.wallet-btn { display: inline-flex; align-items: center; gap: .5rem; padding: .6rem 1rem; border-radius: .8rem; background: #000; color: #fff;
    font-weight: 600; font-size: .9rem; text-decoration: none; margin-left: .5rem; transition: transform .15s var(--public-ease); }
.wallet-btn:hover { color: #fff; transform: translateY(-1px); }
.wallet-btn-sm { display: flex; justify-content: center; margin: .25rem 1rem .75rem; padding: .5rem .8rem; font-size: .82rem; }
@media (prefers-reduced-motion: reduce) { .wallet-btn { transition: none; } .wallet-btn:hover { transform: none; } }
