/* ==========================================================================
   Events - listing, booking form and receipt.
   Built on the template's tokens so it reads as part of the same site.
   ========================================================================== */

.event-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 30px;
}

.event-card {
    background: #fff;
    border: 1px solid rgba(0, 6, 98, 0.08);
    border-radius: 20px;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    transition: transform .35s ease, box-shadow .35s ease, border-color .35s ease;
}

.event-card:hover {
    transform: translateY(-6px);
    border-color: rgba(116, 118, 255, .4);
    box-shadow: 0 24px 60px -30px rgba(0, 6, 98, .35);
}

.event-card .thumb {
    position: relative;
    aspect-ratio: 16 / 10;
    overflow: hidden;
}

.event-card .thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.event-card .event-date {
    position: absolute;
    left: 18px;
    bottom: 18px;
    background: var(--bg-gradient);
    color: #fff;
    border-radius: 12px;
    padding: 10px 14px;
    text-align: center;
    line-height: 1.1;
    font-size: 13px;
    text-transform: uppercase;
}

.event-card .event-date strong {
    display: block;
    font-size: 22px;
}

.event-card .info {
    padding: 26px 26px 24px;
    display: flex;
    flex-direction: column;
    flex-grow: 1;
}

.event-meta {
    list-style: none;
    margin: 0 0 12px;
    padding: 0;
    display: flex;
    flex-wrap: wrap;
    gap: 16px;
    font-size: 13.5px;
    color: var(--color-paragraph);
}

.event-meta i {
    color: var(--color-primary);
    margin-right: 6px;
}

.event-card h3 {
    font-size: 20px;
    line-height: 30px;
    margin-bottom: 10px;
}

.event-card h3 a { color: var(--color-heading); }
.event-card h3 a:hover { color: var(--color-primary); }
.event-card p { font-size: 15px; line-height: 26px; margin-bottom: 20px; }

.event-card-foot {
    margin-top: auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    border-top: 1px solid rgba(0, 6, 98, .07);
    padding-top: 18px;
}

.event-price { font-weight: 600; color: var(--color-heading); }

.event-flag {
    font-size: 13px;
    font-weight: 500;
    color: #a4a6b3;
    border: 1px solid rgba(0, 6, 98, .12);
    border-radius: 20px;
    padding: 4px 14px;
}

.event-grid.past .event-card .info { padding: 24px; }

.event-empty {
    grid-column: 1 / -1;
    background: var(--bg-gray);
    border-radius: 20px;
    padding: 60px 40px;
    text-align: center;
}

/* --------------------------------------------------------------- booking */

.lead-summary {
    font-size: 19px;
    line-height: 32px;
    color: var(--color-heading);
    margin-bottom: 26px;
}

.event-booking {
    position: sticky;
    top: 110px;
    background: #fff;
    border: 1px solid rgba(0, 6, 98, .1);
    border-radius: 20px;
    padding: 30px 28px;
    box-shadow: 0 24px 60px -40px rgba(0, 6, 98, .4);
}

.event-facts ul { list-style: none; margin: 0 0 26px; padding: 0; }
.event-facts li + li { margin-top: 16px; }
.event-facts .label { display: block; font-size: 13px; color: var(--color-paragraph); margin-bottom: 3px; }
.event-facts .label i { color: var(--color-primary); margin-right: 7px; }
.event-facts strong { color: var(--color-heading); font-weight: 600; line-height: 24px; }

.booking-title { font-size: 19px; margin-bottom: 18px; }

.ticket-options { display: grid; gap: 10px; margin-bottom: 22px; }

.ticket-option {
    display: block;
    border: 1px solid rgba(0, 6, 98, .12);
    border-radius: 12px;
    padding: 14px 16px;
    cursor: pointer;
    transition: border-color .25s ease, background .25s ease;
}

.ticket-option:hover { border-color: rgba(116, 118, 255, .5); }
.ticket-option input { margin-right: 10px; }
.ticket-option:has(input:checked) { border-color: var(--color-primary); background: rgba(116, 118, 255, .06); }
.ticket-option.is-unavailable { opacity: .5; cursor: not-allowed; }

.ticket-body { display: block; }
.ticket-name { display: flex; justify-content: space-between; gap: 12px; font-weight: 600; color: var(--color-heading); }
.ticket-name em { font-style: normal; color: var(--color-primary); }
.ticket-desc { display: block; font-size: 13px; line-height: 20px; color: var(--color-paragraph); margin-top: 4px; }
.ticket-stock { display: block; font-size: 12px; margin-top: 6px; color: var(--color-paragraph); opacity: .8; }

.form-row { margin-bottom: 16px; }
.form-row label { display: block; font-size: 14px; font-weight: 500; color: var(--color-heading); margin-bottom: 6px; }
.form-row label span { font-weight: 400; color: var(--color-paragraph); }

.form-row input,
.form-row textarea {
    width: 100%;
    border: 1px solid rgba(0, 6, 98, .14);
    border-radius: 10px;
    padding: 12px 14px;
    font-size: 15px;
    font-family: inherit;
}

.form-row input:focus,
.form-row textarea:focus { outline: none; border-color: var(--color-primary); }

.field-error { display: block; color: #d63946; font-size: 13px; margin-top: 5px; }

.event-form .btn { margin-top: 8px; }
.w-100 { width: 100%; justify-content: center; }

.booking-note { font-size: 13px; line-height: 21px; color: var(--color-paragraph); margin: 14px 0 0; }

.event-closed { text-align: center; padding: 10px 0; }
.event-closed h4 { font-size: 18px; margin-bottom: 8px; }

/* --------------------------------------------------------------- receipt */

.booking-receipt {
    background: #fff;
    border: 1px solid rgba(0, 6, 98, .1);
    border-radius: 22px;
    padding: 46px 44px;
}

.receipt-status { display: flex; gap: 20px; align-items: flex-start; }
.receipt-status i {
    flex-shrink: 0;
    width: 52px; height: 52px;
    display: flex; align-items: center; justify-content: center;
    border-radius: 50%; font-size: 20px; color: #fff;
}
.receipt-status.is-paid i { background: #2fbf8f; }
.receipt-status.is-pending i { background: #e8a33d; }
.receipt-status h3 { font-size: 22px; margin-bottom: 6px; }
.receipt-status p { margin: 0; }

.receipt-facts { list-style: none; margin: 0; padding: 0; border-top: 1px solid rgba(0, 6, 98, .08); }
.receipt-facts li {
    display: flex; justify-content: space-between; gap: 20px;
    padding: 14px 0; border-bottom: 1px solid rgba(0, 6, 98, .07);
}
.receipt-facts span { color: var(--color-paragraph); }
.receipt-facts strong { color: var(--color-heading); text-align: right; }
.status-paid { color: #2fbf8f !important; }
.status-pending { color: #e8a33d !important; }
.status-cancelled { color: #d63946 !important; }

.receipt-transfer {
    margin-top: 26px; padding: 22px 24px;
    background: var(--bg-gray); border-radius: 14px;
}
.receipt-transfer h4 { font-size: 17px; margin-bottom: 8px; }
.receipt-transfer p { margin: 0; font-size: 15px; line-height: 26px; }

/* ------------------------------------------------------------ responsive */

@media (max-width: 1199px) {
    .event-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 767px) {
    .event-grid { grid-template-columns: minmax(0, 1fr); }
    .event-booking { position: static; padding: 26px 22px; }
    .booking-receipt { padding: 32px 24px; }
    .receipt-facts li { flex-direction: column; gap: 4px; }
    .receipt-facts strong { text-align: left; }
}

.receipt-number {
    font-size: 15px;
    color: var(--color-paragraph);
    margin: -12px 0 22px;
}

.receipt-number strong {
    color: var(--color-heading);
    letter-spacing: 0.02em;
}

.receipt-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
}

/* Printing the confirmation page should produce a clean receipt. */
@media print {
    header,
    footer,
    .receipt-actions,
    .breadcrumb-area {
        display: none !important;
    }

    .booking-receipt {
        border: none;
        padding: 0;
    }

    .blog-area {
        padding: 0 !important;
    }
}

/* ==========================================================================
   Booking form: compact layout
   ========================================================================== */

.event-form .ticket-options {
    display: grid;
    gap: 10px;
    margin-bottom: 20px;
}

.event-form .ticket-option {
    display: block;
    position: relative;
    margin: 0;
    padding: 14px 16px 14px 44px;
    border: 1px solid #e4e4ef;
    border-radius: 12px;
    cursor: pointer;
    transition: border-color 0.18s ease, background-color 0.18s ease;
}

.event-form .ticket-option:hover {
    border-color: #c9c9e6;
    background: #fbfbff;
}

.event-form .ticket-option input {
    position: absolute;
    left: 16px;
    top: 18px;
    width: 18px;
    height: 18px;
    margin: 0;
    accent-color: var(--color-primary, #7476ff);
}

.event-form .ticket-option:has(input:checked) {
    border-color: var(--color-primary, #7476ff);
    background: #f6f6ff;
    box-shadow: 0 0 0 3px rgba(116, 118, 255, 0.12);
}

.event-form .ticket-option.is-unavailable {
    opacity: 0.55;
    cursor: not-allowed;
}

.event-form .ticket-head {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 14px;
}

.event-form .ticket-name {
    font-size: 16px;
    font-weight: 600;
    color: var(--color-heading, #000662);
}

.event-form .ticket-price {
    font-style: normal;
    font-weight: 700;
    font-size: 16px;
    color: var(--color-heading, #000662);
    white-space: nowrap;
}

.event-form .ticket-meta {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 4px 10px;
    margin-top: 3px;
    font-size: 13px;
    line-height: 1.5;
    color: #6f6f88;
}

.event-form .ticket-stock {
    font-weight: 600;
    color: #8a8aa3;
}

/* Two columns on desktop so the form stops being a single tall stack. */
.event-form .form-grid {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 96px;
    gap: 14px;
}

.event-form .form-grid .form-row {
    margin-bottom: 0;
}

.event-form .form-row--full {
    grid-column: 1 / -1;
}

.event-form .form-more .form-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.event-form label {
    display: block;
    margin-bottom: 6px;
    font-size: 14px;
    font-weight: 600;
    color: var(--color-heading, #000662);
}

.event-form input,
.event-form textarea {
    width: 100%;
    min-height: 48px;
    padding: 12px 14px;
    border: 1px solid #e4e4ef;
    border-radius: 10px;
    font-size: 15px;
    transition: border-color 0.18s ease, box-shadow 0.18s ease;
}

.event-form textarea {
    min-height: 74px;
}

.event-form input:focus,
.event-form textarea:focus {
    outline: none;
    border-color: var(--color-primary, #7476ff);
    box-shadow: 0 0 0 3px rgba(116, 118, 255, 0.14);
}

.event-form input.has-error,
.event-form textarea.has-error {
    border-color: #d9483f;
    box-shadow: 0 0 0 3px rgba(217, 72, 63, 0.12);
}

.event-form .form-hint {
    display: block;
    margin-top: 5px;
    font-size: 12.5px;
    color: #8a8aa3;
}

.event-form .field-error {
    display: block;
    margin-top: 5px;
    font-size: 12.5px;
    color: #d9483f;
}

.event-form .form-more {
    margin: 16px 0 18px;
    border-top: 1px solid #eeeef5;
    padding-top: 14px;
}

.event-form .form-more summary {
    cursor: pointer;
    list-style: none;
    font-size: 14px;
    font-weight: 600;
    color: var(--color-primary, #7476ff);
    display: inline-flex;
    align-items: center;
    gap: 7px;
}

.event-form .form-more summary::-webkit-details-marker {
    display: none;
}

.event-form .form-more summary::before {
    content: "+";
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: rgba(116, 118, 255, 0.14);
    font-size: 14px;
    line-height: 1;
}

.event-form .form-more[open] summary::before {
    content: "\2212";
}

.event-form .form-more[open] summary {
    margin-bottom: 14px;
}

.event-form .order-total {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 14px;
    margin-bottom: 16px;
    padding: 14px 16px;
    border-radius: 12px;
    background: #f5f5fb;
}

.event-form .order-total__label {
    font-size: 14px;
    font-weight: 600;
    color: #55556e;
}

.event-form .order-total__value {
    font-size: 20px;
    font-weight: 700;
    color: var(--color-heading, #000662);
}

.event-form .booking-submit {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
}

.event-form .booking-submit.is-loading {
    opacity: 0.72;
    pointer-events: none;
}

.event-form .form-alert {
    margin-bottom: 18px;
    padding: 14px 16px;
    border: 1px solid rgba(217, 72, 63, 0.28);
    border-radius: 12px;
    background: #fdeceb;
    color: #b03127;
    font-size: 14px;
}

.event-form .form-alert ul {
    margin: 6px 0 0;
    padding-left: 18px;
}

@media only screen and (max-width: 575px) {
    .event-form .form-grid,
    .event-form .form-more .form-grid {
        grid-template-columns: minmax(0, 1fr);
    }
}

@media (prefers-reduced-motion: reduce) {
    .event-form .ticket-option,
    .event-form input,
    .event-form textarea {
        transition: none;
    }
}

/* Step by step booking */
.booking-launch__from {
    display: block;
    margin-bottom: 14px;
    font-size: 15px;
    color: #60616c;
}

.booking-launch__from strong {
    color: #000662;
    font-size: 20px;
    font-weight: 700;
}

.booking-launch__btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
}

body.booking-open {
    overflow: hidden;
}

.booking-modal {
    position: fixed;
    inset: 0;
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 24px;
}

.booking-modal[hidden] {
    display: none;
}

.booking-modal__backdrop {
    position: absolute;
    inset: 0;
    background: rgba(8, 6, 40, 0.55);
    backdrop-filter: blur(3px);
}

.booking-modal__dialog {
    position: relative;
    width: 100%;
    max-width: 560px;
    max-height: calc(100vh - 48px);
    overflow-y: auto;
    padding: 28px 30px 30px;
    border-radius: 20px;
    background: #fff;
    box-shadow: 0 30px 80px rgba(6, 4, 40, 0.35);
    animation: booking-rise 0.28s cubic-bezier(0.22, 1, 0.36, 1);
}

@keyframes booking-rise {
    from { opacity: 0; transform: translateY(16px) scale(0.985); }
    to { opacity: 1; transform: none; }
}

.booking-modal__head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 16px;
}

.booking-modal__head h3 {
    margin: 0 0 4px;
    font-size: 22px;
    color: #000662;
}

.booking-modal__head p {
    margin: 0;
    font-size: 14px;
    color: #60616c;
}

.booking-modal__close {
    flex: 0 0 auto;
    width: 38px;
    height: 38px;
    border: 1px solid #e7e7f0;
    border-radius: 50%;
    background: #fff;
    color: #60616c;
    cursor: pointer;
    transition: background-color 0.2s ease, color 0.2s ease;
}

.booking-modal__close:hover {
    background: #000662;
    border-color: #000662;
    color: #fff;
}

.booking-steps {
    display: flex;
    gap: 8px;
    margin: 22px 0 20px;
    padding: 0;
    list-style: none;
}

.booking-steps li {
    flex: 1 1 0;
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 9px 12px;
    border-radius: 999px;
    background: #f6f6fb;
    font-size: 13px;
    font-weight: 600;
    color: #8687a0;
    white-space: nowrap;
}

.booking-steps li span {
    display: grid;
    place-items: center;
    width: 21px;
    height: 21px;
    border-radius: 50%;
    background: #e2e2ee;
    color: #60616c;
    font-size: 12px;
}

.booking-steps li.is-active {
    background: #eceaff;
    color: #000662;
}

.booking-steps li.is-active span {
    background: var(--color-primary, #7476ff);
    color: #fff;
}

.booking-steps li.is-done {
    color: #1c6b45;
    background: #f2fbf6;
}

.booking-steps li.is-done span {
    background: #1c6b45;
    color: #fff;
}

.booking-step__title {
    margin: 0 0 16px;
    font-size: 17px;
    color: #000662;
}

.booking-step[hidden] {
    display: none;
}

.qty-row {
    margin-top: 20px;
}

.qty-stepper {
    display: inline-flex;
    align-items: center;
    gap: 0;
    border: 1px solid #e2e2ee;
    border-radius: 12px;
    overflow: hidden;
}

.qty-stepper button {
    width: 44px;
    height: 46px;
    border: 0;
    background: #f6f6fb;
    color: #000662;
    cursor: pointer;
    transition: background-color 0.2s ease, color 0.2s ease;
}

.qty-stepper button:hover {
    background: var(--color-primary, #7476ff);
    color: #fff;
}

.qty-stepper input {
    width: 74px;
    height: 46px;
    border: 0;
    border-left: 1px solid #e2e2ee;
    border-right: 1px solid #e2e2ee;
    text-align: center;
    font-size: 16px;
    font-weight: 600;
    color: #000662;
    -moz-appearance: textfield;
}

.qty-stepper input::-webkit-outer-spin-button,
.qty-stepper input::-webkit-inner-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

.ticket-options.has-error {
    outline: 2px solid #d6455d;
    outline-offset: 4px;
    border-radius: 12px;
}

.form-row label .opt {
    margin-left: 4px;
    font-size: 12px;
    font-weight: 400;
    color: #8687a0;
}

.booking-review {
    margin: 0 0 18px;
    padding: 4px 0 0;
}

.booking-review > div {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 16px;
    padding: 12px 0;
    border-bottom: 1px solid #eeeef6;
}

.booking-review dt {
    margin: 0;
    font-size: 14px;
    font-weight: 500;
    color: #60616c;
}

.booking-review dd {
    margin: 0;
    font-size: 15px;
    font-weight: 600;
    color: #000662;
    text-align: right;
    overflow-wrap: anywhere;
}

.booking-review__total {
    border-bottom: 0;
    padding-top: 16px;
}

.booking-review__total dt {
    font-size: 16px;
    font-weight: 600;
    color: #000662;
}

.booking-review__total dd {
    font-size: 22px;
    font-weight: 700;
}

.booking-note--pay {
    margin: 0 0 4px;
    font-size: 13px;
    color: #60616c;
}

.booking-actions {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-top: 22px;
}

.booking-actions .btn-ghost {
    padding: 13px 18px;
    border: 1px solid #e2e2ee;
    border-radius: 999px;
    background: #fff;
    font-size: 15px;
    font-weight: 600;
    color: #60616c;
    cursor: pointer;
    transition: border-color 0.2s ease, color 0.2s ease;
}

.booking-actions .btn-ghost:hover {
    border-color: #000662;
    color: #000662;
}

.booking-actions .btn-ghost[hidden],
.booking-actions .booking-next[hidden],
.booking-actions .booking-submit[hidden] {
    display: none;
}

.booking-actions .booking-next,
.booking-actions .booking-submit {
    flex: 1 1 auto;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
}

.booking-submit.is-loading {
    opacity: 0.75;
    pointer-events: none;
}

/* Without the script every step is shown, so the form still works. */
.booking-modal:not(.is-enhanced) .booking-steps,
.booking-modal:not(.is-enhanced) .booking-actions .btn-ghost,
.booking-modal:not(.is-enhanced) .booking-actions .booking-next {
    display: none;
}

.booking-modal:not(.is-enhanced) {
    position: static;
    padding: 0;
    display: block;
}

.booking-modal:not(.is-enhanced) .booking-modal__backdrop,
.booking-modal:not(.is-enhanced) .booking-modal__close {
    display: none;
}

.booking-modal:not(.is-enhanced) .booking-modal__dialog {
    max-width: none;
    max-height: none;
    padding: 0;
    box-shadow: none;
    animation: none;
}

@media (max-width: 575px) {
    .booking-modal {
        padding: 0;
        align-items: flex-end;
    }

    .booking-modal__dialog {
        max-width: none;
        max-height: 94vh;
        border-radius: 20px 20px 0 0;
        padding: 22px 20px 24px;
    }

    .booking-steps li {
        justify-content: center;
        padding: 8px 6px;
        font-size: 12px;
    }

    .booking-actions {
        flex-wrap: wrap;
    }
}

@media (prefers-reduced-motion: reduce) {
    .booking-modal__dialog {
        animation: none;
    }
}

/* The old grid reserved a 96px column for the places field, which now lives
   in its own step, so the detail step pairs its fields evenly instead. */
.event-form .booking-step .form-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

@media (max-width: 575px) {
    .event-form .booking-step .form-grid {
        grid-template-columns: minmax(0, 1fr);
    }
}
