/* Storefronts: static HTML, this file only (the Content-Security-Policy allows no inline styles and nothing from other sites). */

:root {
    --sf-text: #1f2328;
    --sf-muted: #59636e;
    --sf-background: #f6f7f9;
    --sf-surface: #ffffff;
    --sf-border: #d8dee4;
    --sf-accent: #594ae2;
    --sf-radius: 8px;
    color-scheme: light;
}

*,
*::before,
*::after {
    box-sizing: border-box;
}

html {
    -webkit-text-size-adjust: 100%;
}

body {
    margin: 0;
    background: var(--sf-background);
    color: var(--sf-text);
    font-family: system-ui, -apple-system, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    font-size: 1rem;
    line-height: 1.5;
}

a {
    color: var(--sf-accent);
}

a:focus-visible {
    outline: 2px solid var(--sf-accent);
    outline-offset: 2px;
}

.sf-page {
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

.sf-container {
    width: 100%;
    max-width: 1080px;
    margin: 0 auto;
    padding: 0 16px;
}

.sf-header {
    background: var(--sf-surface);
    border-bottom: 1px solid var(--sf-border);
}

.sf-header-inner {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 8px 16px;
    min-height: 64px;
}

.sf-brand {
    color: var(--sf-text);
    font-size: 1.25rem;
    font-weight: 600;
    text-decoration: none;
}

.sf-languages {
    display: flex;
    gap: 4px;
}

.sf-languages a {
    padding: 4px 8px;
    border-radius: var(--sf-radius);
    color: var(--sf-muted);
    font-size: 0.875rem;
    text-decoration: none;
}

.sf-languages a[aria-current="true"] {
    background: var(--sf-background);
    color: var(--sf-text);
    font-weight: 600;
}

.sf-main {
    flex: 1;
}

.sf-hero {
    padding: 48px 0 32px;
    background: var(--sf-surface);
    border-bottom: 1px solid var(--sf-border);
}

.sf-hero h1 {
    margin: 0 0 8px;
    font-size: clamp(1.75rem, 4vw, 2.5rem);
    line-height: 1.2;
}

.sf-hero p {
    margin: 0;
    color: var(--sf-muted);
    font-size: 1.125rem;
}

.sf-section {
    padding-top: 32px;
    padding-bottom: 48px;
}

.sf-section h1,
.sf-section h3 {
    margin-top: 0;
}

.sf-empty {
    margin: 0;
    padding: 24px;
    background: var(--sf-surface);
    border: 1px dashed var(--sf-border);
    border-radius: var(--sf-radius);
    color: var(--sf-muted);
}

.sf-footer {
    padding: 24px 0;
    color: var(--sf-muted);
    font-size: 0.875rem;
}

/* ---- events */
.sf-muted {
    color: var(--sf-muted);
}

.sf-badge {
    display: inline-block;
    padding: 0 8px;
    border-radius: 999px;
    background: #e8f5ec;
    color: #1a7f37;
    font-size: 0.8rem;
    font-weight: 600;
    line-height: 1.6;
    vertical-align: middle;
}

.sf-badge-off {
    background: #eef0f2;
    color: var(--sf-muted);
}

.sf-key {
    display: inline-block;
    width: 0.8rem;
    height: 0.8rem;
    margin-right: 6px;
    vertical-align: -1px;
}

.sf-event-list {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 16px;
    margin: 0;
    padding: 0;
    list-style: none;
}

.sf-event-card {
    background: var(--sf-surface);
    border: 1px solid var(--sf-border);
    border-radius: var(--sf-radius);
    overflow: hidden;
}

.sf-event-card-link {
    display: flex;
    flex-direction: column;
    height: 100%;
    color: inherit;
    text-decoration: none;
}

.sf-event-card-link:hover .sf-event-card-title {
    text-decoration: underline;
}

.sf-event-card img,
.sf-event-card-noimage {
    display: block;
    width: 100%;
    aspect-ratio: 16 / 9;
    object-fit: cover;
    background: #e9ecef;
}

.sf-event-card-body {
    display: flex;
    flex: 1;
    flex-direction: column;
    gap: 2px;
    padding: 12px 16px 16px;
}

.sf-event-card-title {
    font-size: 1.15rem;
    font-weight: 600;
}

.sf-event-card-when {
    font-size: 0.9rem;
}

.sf-event-card-where,
.sf-event-card-summary {
    color: var(--sf-muted);
    font-size: 0.9rem;
}

.sf-event-card-foot {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px;
    margin-top: auto;
    padding-top: 8px;
}

.sf-event-card-price {
    margin-left: auto;
    font-weight: 600;
}

.sf-event-image {
    display: block;
    width: 100%;
    max-height: 420px;
    object-fit: cover;
    background: #e9ecef;
}

.sf-event-header {
    padding-top: 24px;
}

.sf-event-header h1 {
    margin: 0 0 4px;
    font-size: 2rem;
    line-height: 1.2;
}

.sf-event-header p {
    margin: 0 0 4px;
}

.sf-event-when {
    font-weight: 600;
}

.sf-event-summary {
    margin-top: 8px;
    color: var(--sf-muted);
    font-size: 1.1rem;
}

.sf-event-body {
    display: grid;
    grid-template-columns: minmax(0, 3fr) minmax(0, 2fr);
    gap: 24px;
    align-items: start;
    padding-top: 24px;
    padding-bottom: 24px;
}

@media (max-width: 760px) {
    .sf-event-body {
        grid-template-columns: minmax(0, 1fr);
    }
}

.sf-event-text p {
    margin: 0 0 1em;
    overflow-wrap: anywhere;
}

.sf-tickets {
    background: var(--sf-surface);
    border: 1px solid var(--sf-border);
    border-radius: var(--sf-radius);
    padding: 16px;
}

.sf-tickets h2,
.sf-plan h2 {
    margin: 0 0 8px;
    font-size: 1.25rem;
}

.sf-tickets-status {
    margin: 0 0 12px;
    font-weight: 600;
}

.sf-ticket-type {
    padding: 12px 0;
    border-top: 1px solid var(--sf-border);
}

.sf-ticket-type h3 {
    margin: 0 0 4px;
    font-size: 1.05rem;
}

.sf-ticket-type p {
    margin: 0 0 6px;
}

.sf-tiers {
    margin: 0;
    padding: 0;
    list-style: none;
}

.sf-tiers li {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    column-gap: 12px;
    padding: 4px 0;
}

.sf-tier-name {
    overflow-wrap: anywhere;
}

.sf-tier-note {
    grid-column: 1 / -1;
    grid-row: 2;
    color: var(--sf-muted);
    font-size: 0.85rem;
}

.sf-tier-note:empty {
    display: none;
}

.sf-tier-price {
    text-align: right;
    font-weight: 600;
}

.sf-tier-off .sf-tier-name,
.sf-tier-off .sf-tier-price {
    color: var(--sf-muted);
    text-decoration: line-through;
}

.sf-tickets-rules {
    margin: 12px 0 0;
    font-size: 0.9rem;
}

.sf-plan {
    padding-top: 8px;
    padding-bottom: 32px;
}

.sf-plan-drawing {
    display: block;
    width: 100%;
    max-height: 440px;
    background: var(--sf-surface);
    border: 1px solid var(--sf-border);
    border-radius: var(--sf-radius);
}

.sf-zones {
    display: flex;
    flex-wrap: wrap;
    gap: 4px 24px;
    margin: 12px 0 0;
    padding: 0;
    list-style: none;
}

/* ---- choosing tickets (wwwroot/storefront-tickets.js) */
.sf-choose {
    padding-top: 8px;
    padding-bottom: 40px;
}

.sf-choose > h2 {
    margin: 0 0 12px;
    font-size: 1.5rem;
}

.sf-choose-grid {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 320px;
    gap: 24px;
    align-items: start;
}

@media (max-width: 900px) {
    .sf-choose-grid {
        grid-template-columns: minmax(0, 1fr);
    }
}

.sf-choose-main {
    display: flex;
    flex-direction: column;
    gap: 16px;
    min-width: 0;
}

.sf-block {
    background: var(--sf-surface);
    border: 1px solid var(--sf-border);
    border-radius: var(--sf-radius);
    padding: 16px;
}

.sf-block h3,
.sf-summary h3 {
    margin: 0 0 8px;
    font-size: 1.15rem;
}

.sf-block h4 {
    margin: 0 0 4px;
    font-size: 1rem;
}

.sf-block .sf-ticket-type:first-of-type {
    border-top: 0;
    padding-top: 0;
}

.sf-tiers li[data-tier] {
    grid-template-columns: minmax(0, 1fr) auto auto;
    align-items: center;
}

.sf-tiers li[data-tier] .sf-tier-price {
    grid-column: 2;
    grid-row: 1;
}

.sf-stepper {
    grid-column: 3;
    grid-row: 1;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    margin-left: 8px;
}

.sf-stepper output {
    min-width: 1.5rem;
    text-align: center;
    font-weight: 600;
}

.sf-stepper button,
.sf-remove {
    width: 2rem;
    height: 2rem;
    padding: 0;
    border: 1px solid var(--sf-border);
    border-radius: 50%;
    background: var(--sf-surface);
    color: var(--sf-text);
    font-size: 1.1rem;
    line-height: 1;
    cursor: pointer;
}

.sf-stepper button:disabled {
    opacity: 0.4;
    cursor: default;
}

.sf-stepper button:focus-visible,
.sf-remove:focus-visible,
.sf-button:focus-visible,
.sf-lines select:focus-visible {
    outline: 2px solid var(--sf-accent);
    outline-offset: 2px;
}

.sf-canvas {
    position: relative;
    height: 480px;
    overflow: hidden;
    background: #f8fafc;
    border: 1px solid var(--sf-border);
    border-radius: var(--sf-radius);
    outline: none;
}

.sf-canvas:focus-visible {
    box-shadow: 0 0 0 2px var(--sf-accent);
}

.sf-canvas > .sf-plan-drawing {
    height: 100%;
    max-height: none;
    border: 0;
}

.sf-picker-ready .sf-canvas > .sf-plan-drawing {
    display: none;
}

.sf-seat-legend li {
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.sf-seat-key {
    display: inline-block;
    width: 0.9rem;
    height: 0.9rem;
    border-radius: 50%;
}

.sf-seat-free {
    background: #2563eb;
}

.sf-seat-chosen {
    background: #0f172a;
    box-shadow: 0 0 0 2px #fbbf24;
}

.sf-seat-taken {
    background: #cbd5e1;
}

.sf-summary {
    position: sticky;
    top: 16px;
    background: var(--sf-surface);
    border: 1px solid var(--sf-border);
    border-radius: var(--sf-radius);
    padding: 16px;
}

.sf-summary[hidden] {
    display: none;
}

.sf-lines {
    margin: 0;
    padding: 0;
    list-style: none;
}

.sf-lines li {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 4px 8px;
    padding: 8px 0;
    border-top: 1px solid var(--sf-border);
}

.sf-line-name {
    flex: 1 1 10rem;
    display: flex;
    flex-direction: column;
    min-width: 0;
    overflow-wrap: anywhere;
}

.sf-line-name small {
    color: var(--sf-muted);
}

.sf-line-price {
    font-weight: 600;
}

.sf-lines select {
    max-width: 100%;
    padding: 4px;
    border: 1px solid var(--sf-border);
    border-radius: 4px;
    background: var(--sf-surface);
    color: var(--sf-text);
}

.sf-total {
    display: flex;
    justify-content: space-between;
    margin: 8px 0 12px;
    padding-top: 8px;
    border-top: 2px solid var(--sf-text);
    font-size: 1.15rem;
}

.sf-timer {
    margin: 0 0 8px;
    color: #9a3412;
}

.sf-message {
    margin: 0 0 8px;
    padding: 8px 12px;
    border-radius: 4px;
    background: #fef2f2;
    color: #991b1b;
}

.sf-button {
    display: block;
    width: 100%;
    margin-top: 8px;
    padding: 10px 16px;
    border: 0;
    border-radius: var(--sf-radius);
    background: var(--sf-accent);
    color: #fff;
    font: inherit;
    font-weight: 600;
    cursor: pointer;
}

.sf-button:disabled {
    opacity: 0.5;
    cursor: default;
}

.sf-button-secondary {
    border: 1px solid var(--sf-border);
    background: var(--sf-surface);
    color: var(--sf-text);
}

.sf-button[hidden] {
    display: none;
}

[hidden] {
    display: none !important;
}
