@import url('https://fonts.googleapis.com/css2?family=Heebo:wght@400;500;600;700;800;900&display=swap');

/* ═══════════════════════════════════════════════════════
   Tiki-Taka Tickets — Search Interface v2
   Grid results + filters + pagination
   ═══════════════════════════════════════════════════════ */

/* Container */
.tcl-modern-container {
    font-family: 'Heebo', var(--e-global-typography-primary-font-family, system-ui, -apple-system, sans-serif);
    max-width: 1280px; /* Increased from 1100px */
    margin: 40px auto;
    direction: rtl;
    color: var(--e-global-color-text, #111827);
    container-type: inline-size;
    padding: 0 16px;
}

/* ─── Search Panel ─── */
.tcl-search-panel {
    margin-bottom: 30px;
}

/* Title above search */
.tcl-search-title {
    text-align: center;
    font-size: 2.6rem;
    font-weight: 900;
    color: var(--e-global-color-text, #0f172a);
    margin: 0 0 20px;
    letter-spacing: 0.5px;
}

/* Search Row: everything in one line on desktop */
.tcl-search-row {
    display: flex;
    align-items: stretch;
    gap: 0;
    max-width: 900px;
    margin: 0 auto;
    background: #ffffff;
    border-radius: 16px;
    box-shadow: 0 4px 24px -2px rgba(0, 0, 0, 0.10);
    border: 3px solid #e2e8f0;
    overflow: hidden;
    transition: border-color 0.3s ease, box-shadow 0.3s ease;
}

.tcl-search-row:focus-within {
    border-color: #1e3a8a; /* Dark Blue */
    box-shadow: 0 8px 30px -4px rgba(30, 58, 138, 0.15);
}

/* Text Input Area */
.tcl-search-box {
    position: relative;
    display: flex;
    align-items: center;
    flex: 1;
    min-width: 0;
    padding: 0 16px;
    gap: 10px;
}

#tcl-search-input {
    flex-grow: 1;
    min-width: 0;
    border: none;
    outline: none;
    font-size: 1.25rem;
    font-weight: 900; /* Black font weight */
    padding: 20px 10px;
    background: transparent;
    color: var(--e-global-color-text, #0f172a);
    box-shadow: none;
    font-family: inherit;
    height: 64px;
    box-sizing: border-box;
}

#tcl-search-input::placeholder {
    color: #94a3b8;
    font-weight: 600;
}

/* Date picker: merged into the search row as its own segment — between
   the clear (X) button and the CTA — instead of a separate floating box.
   Flat sides, no independent border/shadow; it shares the row's. */
.tcl-search-dates {
    display: flex;
    align-items: stretch;
    flex: 0 0 auto;
}

.tcl-search-dates .tcl-dp {
    width: auto;
    max-width: none;
    height: auto;
}

.tcl-search-dates .tcl-dp-trigger {
    height: 100%;
    border: none;
    border-radius: 0;
    box-shadow: none;
    background: #ffffff !important;
    padding: 0 18px;
    white-space: nowrap;
}

/* CTA Button: Dark Blue, text only */
.tcl-btn-search-cta {
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #1e3a8a 0%, #172554 100%); /* Dark Blue gradient */
    color: #ffffff;
    border: none;
    border-radius: 0;
    padding: 0 32px;
    height: auto;
    cursor: pointer;
    transition: all 0.2s ease;
    flex-shrink: 0;
    font-size: 1.15rem;
    font-weight: 800;
    font-family: inherit;
    white-space: nowrap;
}

.tcl-btn-search-cta:hover {
    background: linear-gradient(135deg, #172554 0%, #0f172a 100%);
    filter: brightness(1.1);
    box-shadow: 0 6px 16px -2px rgba(30, 58, 138, 0.4);
}

.tcl-btn-search-cta:active {
    transform: scale(0.98);
}

/* Inset focus rings — the row's overflow:hidden clips a normal outline */
.tcl-btn-search-cta:focus-visible,
.tcl-btn-clear-inline:focus-visible {
    outline: 3px solid currentColor;
    outline-offset: -3px;
}

/* Clear Button (inline X): red on red */
.tcl-btn-clear-inline {
    display: flex;
    align-items: center;
    justify-content: center;
    background: #fee2e2;
    color: #dc2626;
    border: none;
    width: 52px;
    align-self: stretch;
    flex-shrink: 0;
    cursor: pointer;
    transition: all 0.2s ease;
}

.tcl-btn-clear-inline:hover {
    background: #ef4444;
    color: #ffffff;
}

/* ─── Results Area ─── */
.tcl-results-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 20px;
    padding: 0 4px;
}

#tcl-results-count {
    font-size: 1.05rem;
    font-weight: 600;
    color: var(--e-global-color-secondary, #4b5563);
}

/* ─── Results List (Rows) ─── */
.tcl-results-grid {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

/* ─── Result Card (Row Layout) ─── */
.tcl-result-card {
    background: rgba(255, 255, 255, 0.85);
    backdrop-filter: blur(8px);
    border: 1px solid rgba(229, 231, 235, 0.8);
    border-radius: 16px;
    overflow: hidden;
    display: flex;
    flex-direction: row; /* Row layout */
    align-items: center;
    cursor: pointer;
    transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1), box-shadow 0.3s ease, border-color 0.3s ease;
    box-shadow: 0 2px 8px -2px rgba(0, 0, 0, 0.04);
}

.tcl-result-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 20px -6px rgba(0, 0, 0, 0.08), 0 4px 8px -2px rgba(0, 0, 0, 0.04);
    border-color: #1e3a8a; /* Dark Blue */
}

.tcl-result-card-img {
    width: 140px;
    height: 110px;
    object-fit: cover;
    background: #f1f5f9;
    display: block;
    flex-shrink: 0;
}

@container (max-width: 600px) {
    .tcl-result-card {
        flex-direction: column;
        align-items: stretch;
    }
    .tcl-result-card-img {
        width: 100%;
        height: 160px;
    }
}

.tcl-result-card-body {
    padding: 20px;
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.tcl-result-card-title {
    font-size: 1.15rem;
    font-weight: 800;
    margin: 0;
    color: #1e3a8a; /* Dark Blue */
    line-height: 1.3;
}

.tcl-result-card-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin: 0;
}

.tcl-meta-tag {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    background: #f1f5f9;
    padding: 4px 10px;
    border-radius: 8px;
    white-space: nowrap;
    font-weight: 500;
    font-size: 0.85rem;
    color: var(--e-global-color-text, #475569);
    border: 1px solid #e2e8f0;
}

.tcl-icon {
    color: var(--e-global-color-secondary, #94a3b8);
    flex-shrink: 0;
}

/* ─── Pagination ─── */
.tcl-pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 6px;
    margin-top: 35px;
    flex-wrap: wrap;
}

.tcl-page-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 42px;
    height: 42px;
    padding: 0 12px;
    border: 1px solid #e5e7eb;
    border-radius: 10px;
    background: #fff;
    color: var(--e-global-color-text, #374151);
    font-size: 0.95rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    font-family: inherit;
}

.tcl-page-btn:hover:not(.active):not(:disabled) {
    background: #f8fafc;
    border-color: #1e3a8a;
    color: #1e3a8a;
    transform: translateY(-1px);
}

.tcl-page-btn.active {
    background: #1e3a8a; /* Dark Blue */
    border-color: #1e3a8a;
    color: #fff;
    box-shadow: 0 4px 10px -2px rgba(30, 58, 138, 0.3);
    cursor: default;
}

.tcl-page-btn:disabled {
    opacity: 0.4;
    cursor: not-allowed;
}

.tcl-page-ellipsis {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 32px;
    height: 42px;
    color: #9ca3af;
    font-weight: 600;
    user-select: none;
}

/* ─── Match Details View ─── */
#tcl-match-details {
    animation: tclFadeIn 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.tcl-match-header {
    margin-bottom: 30px;
    text-align: center;
}

#tcl-match-title {
    font-size: 2.2rem;
    font-weight: 900;
    margin: 20px 0 15px;
    color: #1e3a8a; /* Dark Blue */
    line-height: 1.2;
}

#tcl-match-meta {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 12px;
    margin-bottom: 30px;
}

.tcl-btn-text {
    background: none;
    border: none;
    color: #1e3a8a;
    font-size: 1.05rem;
    font-weight: 700;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 16px;
    border-radius: 50px;
    transition: all 0.2s ease;
    background: rgba(30, 58, 138, 0.05);
    font-family: inherit;
}

.tcl-btn-text:hover {
    background: rgba(30, 58, 138, 0.1);
    transform: translateX(4px); /* arrow points right in RTL */
}

/* ─── Ticket Cards (Inventory) ─── */
#tcl-inventory-results {
    display: grid;
    gap: 20px;
}

.tcl-ticket-card {
    background: rgba(255, 255, 255, 0.8);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(229, 231, 235, 0.8);
    border-radius: 16px;
    padding: 24px;
    display: flex;
    flex-direction: column;
    gap: 20px;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.05), 0 2px 4px -1px rgba(0, 0, 0, 0.03);
    transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1), box-shadow 0.3s ease;
}

@container (min-width: 500px) {
    .tcl-ticket-card:has(.tcl-ticket-img-wrap),
    .tcl-ticket-card.has-image {
        flex-direction: row;
        align-items: center;
    }
}

.tcl-ticket-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
    border-color: rgba(209, 213, 219, 0.8);
}

.tcl-ticket-img-wrap {
    width: 80px;
    height: 80px;
    flex-shrink: 0;
    border-radius: 12px;
    overflow: hidden;
    background: #f1f5f9;
    box-shadow: inset 0 2px 4px rgba(0,0,0,0.05);
}

.tcl-ticket-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.tcl-ticket-content-wrap {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 15px;
    min-width: 0; /* Prevents overflow pushing */
}

@container (min-width: 500px) {
    .tcl-ticket-content-wrap {
        flex-direction: row;
        justify-content: space-between;
        align-items: center;
        flex-wrap: wrap; /* allow wrapping if things get too squished */
    }
}

.tcl-ticket-info h4 {
    margin: 0 0 8px 0;
    font-size: 1.3rem;
    color: #1e3a8a; /* Dark Blue */
    font-weight: 800;
}

.tcl-ticket-price {
    font-size: 1.5rem;
    font-weight: 800;
    color: var(--e-global-color-accent, #059669);
}

.tcl-ticket-action {
    display: flex;
    align-items: center;
    gap: 15px;
}

.tcl-ticket-qty {
    width: 70px;
    padding: 10px;
    border: 1px solid #d1d5db;
    border-radius: 10px;
    text-align: center;
    font-size: 1.05rem;
    background: #fff;
    cursor: pointer;
}

.tcl-btn-primary {
    background: #1e3a8a !important; /* Dark Blue */
    color: #ffffff !important;
    border: none !important;
    padding: 12px 24px;
    border-radius: 10px !important;
    font-size: 1.05rem;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.2s ease;
    box-shadow: 0 4px 6px -1px rgba(30, 58, 138, 0.2);
    font-family: inherit;
    white-space: normal !important; /* let it wrap if needed instead of spilling */
    line-height: 1.2;
}

.tcl-btn-primary:hover {
    filter: brightness(1.1);
    transform: translateY(-2px);
    box-shadow: 0 6px 10px -1px rgba(30, 58, 138, 0.3);
}

/* ─── Empty State ─── */
.tcl-empty-state {
    padding: 50px 20px;
    text-align: center;
    color: var(--e-global-color-secondary, #6b7280);
    font-size: 1.1rem;
    grid-column: 1 / -1;
}

/* ─── Skeleton Loaders ─── */
.tcl-skeleton-container {
    display: grid;
    gap: 20px;
}

.tcl-skeleton-card {
    height: 100px;
    background: #f3f4f6;
    border-radius: 16px;
    position: relative;
    overflow: hidden;
}

.tcl-skeleton-result-card {
    height: 110px;
    background: #f3f4f6;
    border-radius: 16px;
    position: relative;
    overflow: hidden;
    margin-bottom: 16px;
}

.tcl-skeleton-card::after,
.tcl-skeleton-result-card::after {
    content: "";
    position: absolute;
    top: 0;
    right: 0;
    bottom: 0;
    left: 0;
    transform: translateX(-100%);
    background-image: linear-gradient(
        90deg,
        rgba(255, 255, 255, 0) 0,
        rgba(255, 255, 255, 0.4) 20%,
        rgba(255, 255, 255, 0.6) 60%,
        rgba(255, 255, 255, 0)
    );
    animation: tclShimmer 1.5s infinite;
}

/* ─── Spinner ─── */
.tcl-spinner {
    width: 24px;
    height: 24px;
    border: 3px solid #e2e8f0;
    border-top-color: #1e3a8a;
    border-radius: 50%;
    animation: tclSpin 0.8s linear infinite;
}

/* ─── Animations ─── */
@keyframes tclShimmer {
    100% {
        transform: translateX(100%);
    }
}

@keyframes tclSpin {
    to {
        transform: rotate(360deg);
    }
}

@keyframes tclFadeIn {
    from {
        opacity: 0;
        transform: translateY(15px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* ─── Mobile: Input, Clear, CTA on one line ─── */
@media (max-width: 768px) {
    .tcl-search-title {
        font-size: 1.9rem;
        margin-bottom: 14px;
    }

    .tcl-search-row {
        display: flex;
        flex-direction: row;
        flex-wrap: wrap;
        border-radius: 0;
        background: transparent;
        border: none;
        box-shadow: none;
        gap: 0;
    }

    .tcl-search-row:focus-within {
        border-color: transparent;
        box-shadow: none;
    }

    .tcl-search-box {
        background: #fff;
        border: 2px solid #e5e7eb;
        border-left: none;
        border-radius: 0 12px 12px 0; /* RTL right */
        padding: 0 10px;
        order: 1;
        flex: 1;
        min-width: 0;
        height: 52px;
        box-shadow: 0 2px 8px -2px rgba(0,0,0,0.05);
    }

    .tcl-search-box:focus-within {
        border-color: #1e3a8a;
    }

    #tcl-search-input {
        font-size: 1.1rem;
        height: 100%;
        padding: 0;
        width: 100%;
    }

    #tcl-search-input::placeholder {
        font-size: 0.88rem;
    }

    .tcl-btn-clear-inline {
        position: static;
        order: 2;
        width: 44px;
        height: 52px;
        border-radius: 0;
        background: #fee2e2;
        color: #dc2626;
        border-top: 2px solid #e5e7eb;
        border-bottom: 2px solid #e5e7eb;
        border-left: none;
        border-right: none;
    }

    .tcl-btn-search-cta {
        order: 3;
        width: 76px;
        height: 52px;
        padding: 0 4px;
        font-size: 0.9rem;
        line-height: 1.15;
        white-space: normal;
        text-align: center;
        border-radius: 12px 0 0 12px;
        justify-content: center;
        box-shadow: 0 2px 8px -2px rgba(234, 88, 12, 0.4);
    }

    .tcl-search-dates {
        order: 4;
        width: 100%;
        border-top: none;
        margin-top: 10px;
    }

    .tcl-search-dates .tcl-dp {
        width: 100%;
        max-width: 100%;
    }

    .tcl-search-dates .tcl-dp-trigger {
        height: 52px;
        justify-content: flex-start;
        border-radius: 12px;
        width: 100%;
        border: 2px solid #e5e7eb;
    }
}

/* ═══════════════════════════════════════
   Seat map (stadium plan): responsive layout, compact tickets, inline SVG
   ═══════════════════════════════════════ */
.tcl-inventory-layout {
    display: flex;
    flex-direction: column;   /* mobile: map on top, tickets below */
    gap: 20px;
    align-items: stretch;
}

@media (max-width: 899px) {
    .tcl-seatmap-col {
        order: -1;
        position: sticky;
        top: 0;
        z-index: 10;
        background: rgba(255, 255, 255, 0.95);
        backdrop-filter: blur(8px);
        padding: 10px 0;
        border-bottom: 1px solid #e5e7eb;
        margin-bottom: 10px;
        box-shadow: 0 4px 12px -6px rgba(0,0,0,0.1);
    }
}

.tcl-tickets-col {
    display: flex;
    flex-direction: column;
    gap: 12px;
    min-width: 0;
}

.tcl-seatmap-col {
    min-width: 0;
}

/* SVG blends into the page — no card, no border, no shadow, no background. */
.tcl-seatmap {
    width: 100%;
    background: transparent;
    border: 0;
    box-shadow: none;
    padding: 0;
}

.tcl-seatmap svg {
    width: 100%;
    max-width: 100%;
    max-height: 75vh;
    height: auto;              /* keep the SVG's own aspect ratio — never stretch */
    display: block;
    margin: 0 auto;
    background: transparent;
}

/* Neutralize theme CSS (letter/word-spacing, RTL direction, transforms) that would
   otherwise cascade into the inlined SVG and distort the stadium's text labels. */
.tcl-seatmap svg text,
.tcl-seatmap svg tspan {
    letter-spacing: normal;
    word-spacing: normal;
    direction: ltr;
    unicode-bidi: isolate;
    text-transform: none;
}

/* Section(s) of a ticket category: hovered (preview) or clicked (pinned). */
.tcl-seatmap svg .tcl-seat-hl,
.tcl-seatmap svg .tcl-seat-sel {
    fill: #16a34a !important;
    stroke: #065f46;
    stroke-width: 2;
    opacity: 1 !important;
    transition: fill 0.15s ease;
}

/* ── Compact ticket cards shown beside the map ── */
.tcl-tickets-col .tcl-ticket-card,
.tcl-tickets-col .tcl-ticket-card.has-image {
    flex-direction: row;
    align-items: flex-start;
    padding: 20px 18px;
    gap: 16px;
    border-radius: 14px;
    /* Ticket-category colour stripe down the leading edge (as on the retail site). */
    border-inline-start: 5px solid var(--tcl-cat-color, transparent);
    /* no overflow:hidden — it was clipping the price/name/button */
}
@media (max-width: 600px) {
    .tcl-tickets-col .tcl-ticket-card,
    .tcl-tickets-col .tcl-ticket-card.has-image {
        flex-direction: column;
        align-items: stretch;
    }
}
.tcl-tickets-col .tcl-ticket-card:hover {
    transform: translateY(-2px);
}
.tcl-ticket-card.tcl-has-seatmap {
    cursor: pointer;
}
.tcl-ticket-card.tcl-selected {
    border-color: #16a34a;
    box-shadow: 0 0 0 2px rgba(22, 163, 74, 0.55);
}
/* Ticket mockup: a centered, rounded square thumbnail — no edge-flush, no clipping. */
.tcl-tickets-col .tcl-ticket-img-wrap {
    position: static;
    width: 80px;
    height: 80px;
    flex-shrink: 0;
    align-self: flex-start;
    margin-top: 4px;
    border-radius: 14px;
    overflow: hidden;
    background: transparent;
    box-shadow: none;
}
@media (max-width: 600px) {
    .tcl-tickets-col .tcl-ticket-img-wrap {
        width: 100%;
        height: 160px;
        margin-top: 0;
        margin-bottom: 10px;
    }
}
.tcl-tickets-col .tcl-ticket-content-wrap {
    flex-direction: column;
    align-items: stretch;
    gap: 14px;
    min-width: 0;   /* allow shrinking instead of overflowing (and being clipped) */
}
.tcl-tickets-col .tcl-ticket-info {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 12px;
}
.tcl-tickets-col .tcl-ticket-info h4 {
    margin: 0;
    font-size: 1rem;
    line-height: 1.3;
    min-width: 0;
    overflow-wrap: anywhere;   /* long package names wrap instead of pushing the layout */
}

.tcl-tickets-col .tcl-ticket-action,
.tcl-tickets-col .tcl-ticket-action form {
    min-width: 0;
}
.tcl-tickets-col .tcl-ticket-price {
    font-size: 1.2rem;
    white-space: nowrap;
}
.tcl-tickets-col .tcl-ticket-action {
    gap: 12px;
    display: flex;
    align-items: center;
    flex-wrap: wrap;
}
.tcl-tickets-col .tcl-ticket-action form {
    flex: 1;
    min-width: 180px; /* ensure form doesn't shrink too much */
}
.tcl-tickets-col .tcl-ticket-action .tcl-btn-primary {
    flex: 1;
    white-space: normal !important;
    padding: 12px 16px;
    background: #1e3a8a !important;
}

/* ── Quantity stepper (replaces the plain <select>) ── */
.tcl-qty {
    display: inline-flex;
    align-items: stretch;
    height: 44px;
    flex-shrink: 0;
    background: #fff;
    border: 1px solid #d1d5db;
    border-radius: 12px;
    overflow: hidden;
    transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.tcl-qty:focus-within {
    border-color: #3b82f6;
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.15);
}

.tcl-qty-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    padding: 0;
    margin: 0;
    border: 0;
    background: none;
    box-shadow: none;
    color: #374151;
    cursor: pointer;
    transition: background 0.15s ease, color 0.15s ease;
}

.tcl-qty-btn:hover:not(:disabled) {
    background: #f3f4f6;
    color: #111827;
}

/* At the limit for this ticket type: greyed out and unusable. */
.tcl-qty-btn:disabled {
    color: #d5d9e0;
    cursor: not-allowed;
    background: none;
}

.tcl-qty-input {
    width: 46px;
    padding: 0;
    border: 0;
    border-inline: 1px solid #e5e7eb;
    background: transparent;
    text-align: center;
    font: inherit;
    font-size: 1rem;
    font-weight: 700;
    color: #1f2937;
    appearance: textfield;
    -moz-appearance: textfield;
}

/* Hide the native spinners — we provide our own arrows. */
.tcl-qty-input::-webkit-outer-spin-button,
.tcl-qty-input::-webkit-inner-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

.tcl-qty-input:focus {
    outline: none;
}

/* ── Per-ticket description accordion ── */
.tcl-desc-toggle {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    align-self: flex-start;
    margin: 0;
    padding: 0;
    background: none;
    border: 0;
    box-shadow: none;
    cursor: pointer;
    font: inherit;
    font-size: 0.85rem;
    font-weight: 600;
    line-height: 1.2;
    color: #3b82f6;
    transition: color 0.15s ease;
}

.tcl-desc-toggle:hover {
    color: #1d4ed8;
}

.tcl-desc-chevron {
    flex-shrink: 0;
    transition: transform 0.24s cubic-bezier(0.4, 0, 0.2, 1);
}

.tcl-ticket-card.tcl-open .tcl-desc-chevron {
    transform: rotate(180deg);
}

/* Animates height smoothly without needing to know the content height. */
.tcl-desc-panel {
    display: grid;
    grid-template-rows: 0fr;
    transition: grid-template-rows 0.24s cubic-bezier(0.4, 0, 0.2, 1);
}

.tcl-ticket-card.tcl-open .tcl-desc-panel {
    grid-template-rows: 1fr;
}

.tcl-desc-inner {
    overflow: hidden;
    min-height: 0;
    font-size: 0.87rem;
    line-height: 1.6;
    color: #4b5563;
    direction: ltr;
    text-align: left;
}

.tcl-ticket-card.tcl-open .tcl-desc-inner {
    padding-top: 10px;
}

/* The API sends plain text or bullet lists — make both read well. */
.tcl-desc-inner ul,
.tcl-desc-inner ol {
    margin: 0;
    padding-inline-start: 18px;
}

.tcl-desc-inner li {
    margin: 3px 0;
}

.tcl-desc-inner p {
    margin: 0 0 6px;
}

.tcl-desc-inner p:last-child,
.tcl-desc-inner > :last-child {
    margin-bottom: 0;
}

/* How the ticket reaches the buyer — set apart from the marketing copy above it. */
.tcl-delivery {
    margin-top: 10px;
    padding-top: 10px;
    border-top: 1px dashed #e5e7eb;
    font-size: 0.85rem;
    color: #4b5563;
}

.tcl-delivery-title {
    display: flex;
    align-items: center;
    gap: 6px;
    margin-bottom: 4px;
    font-weight: 700;
    color: #1f2937;
}

.tcl-delivery p {
    margin: 0 0 4px;
}

.tcl-delivery p:last-child {
    margin-bottom: 0;
}

@media (prefers-reduced-motion: reduce) {
    .tcl-desc-panel,
    .tcl-desc-chevron {
        transition: none;
    }
}

/* Custom, always-visible scrollbar for the tickets column when it overflows
   (replaces the macOS overlay bar that auto-hides). */
.tcl-tickets-col {
    scrollbar-width: thin;
    scrollbar-color: rgba(0, 0, 0, 0.28) transparent;
}
.tcl-tickets-col::-webkit-scrollbar {
    width: 10px;
}
.tcl-tickets-col::-webkit-scrollbar-track {
    background: rgba(0, 0, 0, 0.05);
    border-radius: 8px;
}
.tcl-tickets-col::-webkit-scrollbar-thumb {
    background: rgba(0, 0, 0, 0.28);
    border-radius: 8px;
}
.tcl-tickets-col::-webkit-scrollbar-thumb:hover {
    background: rgba(0, 0, 0, 0.45);
}

/* Desktop WITH a map: big stadium map on the RIGHT (RTL); compact tickets scroll. */
@media (min-width: 900px) {
    .tcl-inventory-layout.tcl-has-map {
        flex-direction: row;
        align-items: flex-start;
        gap: 40px;
    }
    .tcl-inventory-layout.tcl-has-map .tcl-tickets-col {
        flex: 0 0 450px;
        max-height: 80vh;
        overflow-y: auto;
        padding-inline-end: 10px;
    }
    .tcl-inventory-layout.tcl-has-map .tcl-seatmap-col {
        order: -1;            /* RTL flex row: order -1 = main-start = right side */
        flex: 1 1 auto;
        position: sticky;
        top: 20px;
        display: flex;
        align-items: center;
        justify-content: center;
    }

    /* NO map: tickets fill the whole width in a responsive grid (no wasted space). */
    .tcl-inventory-layout.tcl-no-map .tcl-tickets-col {
        display: grid;
        grid-template-columns: repeat(auto-fill, minmax(450px, 1fr));
        gap: 16px;
    }
}

/* ═══════════════════════════════════════
   Confirmation modal (price change, availability)
   ═══════════════════════════════════════ */
.tcl-modal-overlay {
    position: fixed;
    inset: 0;
    z-index: 999999;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    background: rgba(15, 23, 42, 0.55);
    backdrop-filter: blur(2px);
    animation: tcl-modal-in 0.15s ease-out;
}

@keyframes tcl-modal-in {
    from { opacity: 0; }
    to   { opacity: 1; }
}

.tcl-modal {
    width: 100%;
    max-width: 420px;
    padding: 26px 28px 22px;
    background: #fff;
    border-radius: 16px;
    box-shadow: 0 24px 48px -12px rgba(0, 0, 0, 0.28);
    text-align: center;
}

.tcl-modal-title {
    margin: 0 0 10px;
    font-size: 1.15rem;
    font-weight: 800;
    color: #1f2937;
}

.tcl-modal-text {
    margin: 0 0 22px;
    font-size: 0.95rem;
    line-height: 1.65;
    color: #4b5563;
}

.tcl-modal-actions {
    display: flex;
    gap: 10px;
    justify-content: center;
}

.tcl-modal-actions .tcl-btn-primary {
    flex: 1;
}

.tcl-modal-cancel {
    padding: 12px 20px;
    border: 1px solid #d1d5db;
    border-radius: 10px;
    background: #fff;
    font: inherit;
    font-weight: 600;
    color: #4b5563;
    cursor: pointer;
    transition: background 0.15s ease, border-color 0.15s ease;
}

.tcl-modal-cancel:hover {
    background: #f9fafb;
    border-color: #9ca3af;
}

@media (prefers-reduced-motion: reduce) {
    .tcl-modal-overlay { animation: none; }
}

/* ═══════════════════════════════════════
   Ticket grid (no seat map): keep the cards in step
   ═══════════════════════════════════════ */
@media (min-width: 900px) {
    .tcl-inventory-layout.tcl-no-map .tcl-tickets-col {
        align-items: stretch;   /* every card fills its row */
    }

    /* Equal heights, and the action row anchored to the bottom, so a title that
       wraps to two lines never knocks its neighbours' buttons out of line. */
    .tcl-inventory-layout.tcl-no-map .tcl-ticket-card {
        height: 100%;
        align-items: stretch;
    }

    .tcl-inventory-layout.tcl-no-map .tcl-ticket-content-wrap {
        flex: 1;
    }

    /* Reserve two lines for every title so one- and two-line cards line up. */
    .tcl-inventory-layout.tcl-no-map .tcl-ticket-info h4 {
        min-height: 2.6em;
    }

    /* Push the details toggle to the bottom edge of the card. */
    .tcl-inventory-layout.tcl-no-map .tcl-desc-toggle {
        margin-top: auto;
    }
}

/* The quantity stepper is a single control: themes tend to re-style bare number
   inputs with their own border and radius, which visually detaches the arrows. */
.tcl-qty {
    box-sizing: border-box;
}

.tcl-qty-input {
    border-block: 0 !important;
    border-radius: 0 !important;
    box-shadow: none !important;
    background: transparent !important;
    min-height: 0 !important;
    height: auto !important;
}

.tcl-qty-btn {
    box-shadow: none !important;
    border-radius: 0 !important;
    min-height: 0 !important;
}

/* ═══════════════════════════════════════
   Sandbox notice — shown to every visitor, not just staff.
   Renders only when the plugin points at the test API.
   ═══════════════════════════════════════ */
.tcl-env-banner {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    max-width: 900px;
    margin: 0 auto 22px;
    padding: 14px 18px;
    background: #fffbeb;
    border: 1px solid #fcd34d;
    border-inline-start: 5px solid #d97706;
    border-radius: 12px;
    direction: rtl;
    text-align: right;
    color: #78350f;
    font-size: 0.92rem;
    line-height: 1.6;
}

.tcl-env-banner__icon {
    flex-shrink: 0;
    margin-top: 2px;
    color: #d97706;
}

.tcl-env-banner__text {
    display: flex;
    flex-direction: column;
    gap: 2px;
    min-width: 0;
}

.tcl-env-banner__text strong {
    font-weight: 800;
    color: #92400e;
}

/* WooCommerce pages have their own container widths — keep it aligned there. */
.woocommerce .tcl-env-banner,
.woocommerce-page .tcl-env-banner {
    max-width: none;
}

/* ═══════════════════════════════════════
   Client feedback pass — result date block, provisional kick-off,
   ticket card typography
   ═══════════════════════════════════════ */

/* Date block replacing the stock stadium photo in the results list. The photo
   was identical on every row; the date is what people scan the list for. */
.tcl-result-date {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    width: 92px;
    align-self: stretch;
    padding: 16px 8px;
    background: linear-gradient(135deg, #1e3a8a 0%, #172554 100%);
    color: #fff;
    line-height: 1.1;
}

.tcl-result-date__day {
    font-size: 1.9rem;
    font-weight: 900;
    letter-spacing: -0.02em;
}

.tcl-result-date__month {
    font-size: 0.82rem;
    font-weight: 600;
    opacity: 0.85;
    text-align: center;
}

.tcl-result-date--tbd .tcl-result-date__month {
    font-size: 0.9rem;
    font-weight: 700;
    opacity: 1;
}

@container (max-width: 600px) {
    .tcl-result-date {
        width: 100%;
        flex-direction: row;
        gap: 8px;
        padding: 10px;
        align-self: auto;
    }
    .tcl-result-date__day { font-size: 1.3rem; }
}

/* Provisional kick-off. Buyers book flights around these dates, so it reads as
   a caution rather than a footnote. */
.tcl-provisional {
    margin-top: 10px;
    padding: 8px 12px;
    background: #fffbeb;
    border-inline-start: 3px solid #d97706;
    border-radius: 8px;
    font-size: 0.83rem;
    font-weight: 600;
    line-height: 1.5;
    color: #92400e;
}

#tcl-match-meta .tcl-provisional {
    display: block;
    max-width: 640px;
    margin-inline: auto;
}

/* Ticket mockup hidden for now — delete this rule to bring it back. */
.tcl-ticket-img-wrap.is-hidden {
    display: none !important;
}

/* Price in the theme's dark blue, not the old green. */
.tcl-ticket-price,
.tcl-tickets-col .tcl-ticket-price {
    color: #1e3a8a;
    flex-shrink: 0;
}

/* Ticket name: larger now that the thumbnail is gone, and free to wrap. */
.tcl-tickets-col .tcl-ticket-info {
    align-items: flex-start;
    gap: 14px;
}

.tcl-tickets-col .tcl-ticket-info h4 {
    font-size: 1.15rem;
    line-height: 1.35;
    overflow-wrap: anywhere;
    white-space: normal;
}
