﻿/* =========================================================
   BOX OFFICE CINE VERSE
   SEAT SELECTION
   #1 REFERENCE VISUAL DIRECTION
   ========================================================= */


/* =========================================================
   VARIABLES
   ========================================================= */

:root {
    --seat-bg: #1b2430;
    --seat-border: #344150;
    --seat-available: #263442;

    --seat-selected: #e50914;
    --seat-selected-border: #ff3944;

    --seat-held: #6f5a22;
    --seat-held-border: #a88932;

    --seat-booked: #11161d;
    --seat-booked-border: #1c242e;

    --seat-text: #f5f7fa;
    --seat-muted: #8d98a5;

    --seat-gap: 8px;
}


/* =========================================================
   MAIN PAGE
   ========================================================= */

.seats-main {
    min-height: 100vh;

    padding: 42px 42px 34px;

    color: var(--text-primary, #ffffff);

    background:
        radial-gradient(
            circle at 50% 0%,
            rgba(229, 9, 20, 0.08),
            transparent 38%
        ),
        var(--bg-main, #080b10);
}


/* =========================================================
   HEADER
   ========================================================= */

.seats-header {
    width: 100%;

    max-width: 1180px;

    margin: 0 auto 22px;

    display: flex;

    align-items: flex-start;

    justify-content: space-between;

    gap: 20px;
}


.seats-header-copy {
    min-width: 0;
}


.section-label {
    display: inline-block;

    margin-bottom: 7px;

    font-size: 10px;

    font-weight: 800;

    letter-spacing: 1.8px;

    color: #e50914;
}


.seats-header h1 {
    margin: 0;

    font-size: clamp(25px, 3vw, 36px);

    line-height: 1.05;

    font-weight: 800;

    letter-spacing: -0.8px;
}


.seats-header p {
    margin: 8px 0 0;

    color: var(--text-secondary, #8d98a5);

    font-size: 13px;
}


.back-home {
    flex: 0 0 auto;

    display: inline-flex;

    align-items: center;

    justify-content: center;

    min-height: 38px;

    padding: 0 14px;

    border: 1px solid rgba(255, 255, 255, 0.08);

    border-radius: 7px;

    color: #dce2e8;

    text-decoration: none;

    font-size: 12px;

    font-weight: 700;

    background: rgba(255, 255, 255, 0.025);

    transition:
        transform 0.18s ease,
        background 0.18s ease,
        border-color 0.18s ease;
}


.back-home:hover {
    transform: translateX(-2px);

    background: rgba(255, 255, 255, 0.06);

    border-color: rgba(255, 255, 255, 0.15);
}


/* =========================================================
   SCREENING SUMMARY
   ========================================================= */

.screening-summary {
    width: 100%;

    max-width: 1180px;

    margin: 0 auto 25px;

    display: grid;

    grid-template-columns: minmax(240px, 1fr) auto;

    align-items: center;

    gap: 24px;

    padding: 16px 18px;

    border: 1px solid rgba(255, 255, 255, 0.07);

    border-radius: 10px;

    background: rgba(255, 255, 255, 0.025);

    box-shadow:
        0 18px 45px rgba(0, 0, 0, 0.18);
}


.summary-movie span,
.summary-detail span,
.selected-info span,
.price-info span {
    display: block;

    margin-bottom: 5px;

    font-size: 9px;

    font-weight: 800;

    letter-spacing: 1.35px;

    text-transform: uppercase;

    color: var(--seat-muted);
}


.summary-movie h2 {
    margin: 0;

    font-size: 19px;

    line-height: 1.15;

    font-weight: 800;

    color: #ffffff;
}


.summary-details {
    display: flex;

    align-items: center;

    justify-content: flex-end;

    gap: 25px;

    flex-wrap: wrap;
}


.summary-detail {
    min-width: 80px;
}


.summary-detail strong {
    display: block;

    font-size: 12px;

    font-weight: 700;

    color: #e6ebf0;
}


/* =========================================================
   CINEMA ROOM
   ========================================================= */

.cinema-room {
    width: 100%;

    max-width: 1180px;

    margin: 0 auto;

    padding: 22px 18px 20px;

    border: 1px solid rgba(255, 255, 255, 0.055);

    border-radius: 12px;

    background:
        linear-gradient(
            180deg,
            rgba(255, 255, 255, 0.018),
            rgba(255, 255, 255, 0)
        );
}


/* =========================================================
   SCREEN
   ========================================================= */

.screen-wrapper {
    width: min(620px, 82%);

    margin: 0 auto 25px;

    text-align: center;

    position: relative;
}


.screen-glow {
    position: absolute;

    left: 10%;

    right: 10%;

    top: -5px;

    height: 38px;

    pointer-events: none;

    filter: blur(25px);

    background: rgba(229, 9, 20, 0.12);
}


.screen {
    position: relative;

    height: 26px;

    display: flex;

    align-items: center;

    justify-content: center;

    border-radius: 3px 3px 50% 50%;

    border: 1px solid rgba(255, 255, 255, 0.22);

    color: rgba(255, 255, 255, 0.82);

    font-size: 9px;

    font-weight: 800;

    letter-spacing: 2.8px;

    background:
        linear-gradient(
            180deg,
            #e9edf1 0%,
            #b9c1c9 100%
        );

    box-shadow:
        0 7px 20px rgba(255, 255, 255, 0.08);
}


.screen-wrapper p {
    margin: 7px 0 0;

    color: #5e6873;

    font-size: 9px;

    letter-spacing: 1px;
}


/* =========================================================
   SEAT MAP
   ========================================================= */

.seat-map {
    width: min(820px, 100%);

    margin: 0 auto;

    display: flex;

    flex-direction: column;

    gap: 10px;

    overflow-x: auto;

    padding: 3px 5px 8px;
}


/* =========================================================
   SEAT ROW
   ========================================================= */

.seat-row {
    min-width: max-content;

    display: flex;

    align-items: center;

    gap: 9px;
}


.row-label {
    width: 22px;

    flex: 0 0 22px;

    text-align: center;

    color: #687480;

    font-size: 9px;

    font-weight: 800;

    letter-spacing: 0.5px;
}


.seat-row-seats {
    display: flex;

    align-items: center;

    gap: var(--seat-gap);

    min-width: 0;
}


/* =========================================================
   AISLE
   ========================================================= */

.seat-aisle {
    width: 18px;

    flex: 0 0 18px;
}


/* =========================================================
   SEAT
   ========================================================= */

.seat {
    position: relative;

    width: 39px;

    height: 34px;

    flex: 0 0 39px;

    padding: 0;

    border: 1px solid var(--seat-border);

    border-radius: 7px 7px 4px 4px;

    background: var(--seat-available);

    color: var(--seat-text);

    font-family: inherit;

    font-size: 10px;

    font-weight: 800;

    cursor: pointer;

    user-select: none;

    transition:
        transform 0.18s ease,
        background 0.18s ease,
        border-color 0.18s ease,
        box-shadow 0.18s ease;
}


.seat::before {
    content: "";

    position: absolute;

    left: 5px;

    right: 5px;

    top: -4px;

    height: 5px;

    border-radius: 4px 4px 1px 1px;

    border: 1px solid rgba(255, 255, 255, 0.06);

    border-bottom: 0;

    background: inherit;
}


.seat-number {
    position: relative;

    z-index: 1;
}


.seat:hover:not(:disabled) {
    transform: translateY(-2px);

    border-color: rgba(255, 255, 255, 0.35);

    box-shadow:
        0 7px 15px rgba(0, 0, 0, 0.2);
}


.seat:focus-visible {
    outline: 2px solid rgba(229, 9, 20, 0.85);

    outline-offset: 3px;
}


/* =========================================================
   STANDARD
   ========================================================= */

.seat-type-standard {
    background: var(--seat-available);
}


/* =========================================================
   VIP
   ========================================================= */

.seat-type-vip {
    background: #352b1f;

    border-color: #655238;
}


/* =========================================================
   PREMIUM
   ========================================================= */

.seat-type-premium {
    background: #293229;

    border-color: #435244;
}


/* =========================================================
   SELECTED
   ========================================================= */

.seat.selected,
.seat.seat-state-selected {
    background: var(--seat-selected);

    border-color: var(--seat-selected-border);

    color: #ffffff;

    transform: translateY(-2px);

    box-shadow:
        0 8px 18px rgba(229, 9, 20, 0.24);
}


/* =========================================================
   HELD
   ========================================================= */

.seat.seat-state-held {
    background: var(--seat-held);

    border-color: var(--seat-held-border);

    color: #d6c58c;

    cursor: not-allowed;

    opacity: 0.82;
}


/* =========================================================
   BOOKED
   ========================================================= */

.seat.seat-state-booked,
.seat.occupied {
    background: var(--seat-booked);

    border-color: var(--seat-booked-border);

    color: #46515c;

    cursor: not-allowed;

    opacity: 0.62;
}


/* =========================================================
   DISABLED
   ========================================================= */

.seat:disabled {
    pointer-events: none;
}


/* =========================================================
   LEGEND
   ========================================================= */

.seat-legend {
    display: flex;

    align-items: center;

    justify-content: center;

    gap: 23px;

    flex-wrap: wrap;

    margin-top: 22px;

    padding-top: 17px;

    border-top: 1px solid rgba(255, 255, 255, 0.05);
}


.legend-item {
    display: inline-flex;

    align-items: center;

    gap: 7px;

    color: #7f8a95;

    font-size: 10px;

    font-weight: 700;
}


.legend-seat {
    width: 14px;

    height: 12px;

    border-radius: 3px 3px 2px 2px;

    border: 1px solid var(--seat-border);

    display: inline-block;
}


.legend-seat.available {
    background: var(--seat-available);
}


.legend-seat.selected {
    background: var(--seat-selected);

    border-color: var(--seat-selected-border);
}


.legend-seat.held {
    background: var(--seat-held);

    border-color: var(--seat-held-border);
}


.legend-seat.booked {
    background: var(--seat-booked);

    border-color: var(--seat-booked-border);
}


/* =========================================================
   EMPTY STATE
   ========================================================= */

.booking-empty {
    width: min(500px, 100%);

    margin: 25px auto;

    padding: 30px 20px;

    text-align: center;

    border: 1px dashed rgba(255, 255, 255, 0.1);

    border-radius: 10px;

    background: rgba(255, 255, 255, 0.02);
}


.booking-empty strong {
    display: block;

    margin-bottom: 7px;

    color: #ffffff;

    font-size: 14px;
}


.booking-empty p {
    margin: 0;

    color: #7d8791;

    font-size: 11px;

    line-height: 1.6;
}


/* =========================================================
   FOOTER
   ========================================================= */

.seat-footer {
    width: 100%;

    max-width: 1180px;

    margin: 18px auto 0;

    display: grid;

    grid-template-columns: 1fr auto auto;

    align-items: center;

    gap: 20px;

    padding: 15px 17px;

    border: 1px solid rgba(255, 255, 255, 0.07);

    border-radius: 9px;

    background: rgba(11, 15, 21, 0.92);

    box-shadow:
        0 -12px 35px rgba(0, 0, 0, 0.14);
}


.selected-info strong,
.price-info strong {
    display: block;

    color: #ffffff;

    font-size: 13px;

    font-weight: 800;
}


#selectedSeats {
    max-width: 360px;

    overflow: hidden;

    text-overflow: ellipsis;

    white-space: nowrap;
}


.price-info {
    text-align: right;
}


.price-info strong {
    font-size: 17px;

    letter-spacing: -0.3px;
}


#currencyLabel {
    margin-right: 4px;

    color: #9da6af;

    font-size: 11px;
}


/* =========================================================
   BUTTON
   ========================================================= */

#proceedPayment {
    min-width: 215px;

    min-height: 43px;

    border: 0;

    border-radius: 7px;

    background: #e50914;

    color: #ffffff;

    font-family: inherit;

    font-size: 11px;

    font-weight: 800;

    letter-spacing: 0.7px;

    cursor: pointer;

    transition:
        transform 0.18s ease,
        background 0.18s ease,
        box-shadow 0.18s ease,
        opacity 0.18s ease;
}


#proceedPayment:hover:not(:disabled) {
    transform: translateY(-1px);

    background: #f20d18;

    box-shadow:
        0 9px 24px rgba(229, 9, 20, 0.24);
}


#proceedPayment:active:not(:disabled) {
    transform: translateY(0);
}


#proceedPayment:disabled {
    opacity: 0.38;

    cursor: not-allowed;
}


/* =========================================================
   CUSTOMER MODAL
   ========================================================= */

.cine-customer-modal {
    position: fixed;

    inset: 0;

    z-index: 9999;

    display: flex;

    align-items: center;

    justify-content: center;

    padding: 20px;

    background: rgba(0, 0, 0, 0.78);

    backdrop-filter: blur(7px);
}


.cine-customer-dialog {
    width: min(460px, 100%);

    max-height: calc(100vh - 40px);

    overflow-y: auto;

    padding: 24px;

    border: 1px solid rgba(255, 255, 255, 0.09);

    border-radius: 12px;

    background: #0d1218;

    box-shadow:
        0 30px 80px rgba(0, 0, 0, 0.5);
}


.cine-customer-dialog h2 {
    margin: 0 0 6px;

    color: #ffffff;

    font-size: 20px;
}


.cine-customer-dialog .modal-subtitle {
    margin: 0 0 20px;

    color: #7f8993;

    font-size: 11px;

    line-height: 1.5;
}


.cine-form-group {
    margin-bottom: 13px;
}


.cine-form-group label {
    display: block;

    margin-bottom: 6px;

    color: #aab3bc;

    font-size: 10px;

    font-weight: 800;

    letter-spacing: 0.7px;

    text-transform: uppercase;
}


.cine-form-group input {
    width: 100%;

    box-sizing: border-box;

    min-height: 42px;

    padding: 0 12px;

    border: 1px solid #27313b;

    border-radius: 6px;

    outline: none;

    background: #151c24;

    color: #ffffff;

    font-family: inherit;

    font-size: 12px;

    transition:
        border-color 0.18s ease,
        box-shadow 0.18s ease;
}


.cine-form-group input:focus {
    border-color: #e50914;

    box-shadow:
        0 0 0 3px rgba(229, 9, 20, 0.1);
}


.cine-modal-summary {
    margin: 17px 0;

    padding: 13px;

    border: 1px solid rgba(255, 255, 255, 0.06);

    border-radius: 7px;

    background: rgba(255, 255, 255, 0.025);
}


.cine-modal-summary-row {
    display: flex;

    justify-content: space-between;

    gap: 15px;

    margin-bottom: 7px;

    color: #7f8993;

    font-size: 10px;
}


.cine-modal-summary-row:last-child {
    margin-bottom: 0;
}


.cine-modal-summary-row strong {
    color: #ffffff;

    text-align: right;
}


.cine-modal-error {
    display: none;

    margin-bottom: 13px;

    padding: 10px 11px;

    border: 1px solid rgba(229, 9, 20, 0.25);

    border-radius: 6px;

    background: rgba(229, 9, 20, 0.08);

    color: #ff6a71;

    font-size: 10px;

    line-height: 1.5;
}


.cine-modal-actions {
    display: grid;

    grid-template-columns: 1fr 1fr;

    gap: 9px;

    margin-top: 18px;
}


.cine-modal-actions button {
    min-height: 41px;

    border-radius: 6px;

    font-family: inherit;

    font-size: 10px;

    font-weight: 800;

    letter-spacing: 0.5px;

    cursor: pointer;
}


.cine-modal-cancel {
    border: 1px solid #2b343e;

    background: #171e26;

    color: #aeb7c0;
}


.cine-modal-confirm {
    border: 0;

    background: #e50914;

    color: #ffffff;
}


.cine-modal-actions button:disabled {
    opacity: 0.45;

    cursor: not-allowed;
}


/* =========================================================
   RESPONSIVE
   ========================================================= */

@media (max-width: 1000px) {

    .seats-main {
        padding: 32px 25px;
    }


    .screening-summary {
        grid-template-columns: 1fr;
    }


    .summary-details {
        justify-content: flex-start;
    }


    .seat-footer {
        grid-template-columns: 1fr auto;
    }


    #proceedPayment {
        grid-column: 1 / -1;

        width: 100%;
    }
}


@media (max-width: 700px) {

    .seats-main {
        margin-left: 0;

        padding: 25px 14px 22px;
    }


    .seats-header {
        align-items: flex-start;
    }


    .seats-header h1 {
        font-size: 27px;
    }


    .seats-header p {
        font-size: 11px;
    }


    .screening-summary {
        padding: 14px;
    }


    .summary-details {
        gap: 15px;
    }


    .cinema-room {
        padding: 17px 8px;
    }


    .screen-wrapper {
        width: 88%;
    }


    .seat-map {
        justify-content: flex-start;

        overflow-x: auto;

        scrollbar-width: thin;
    }


    .seat-footer {
        grid-template-columns: 1fr;

        gap: 13px;
    }


    .price-info {
        text-align: left;
    }


    #proceedPayment {
        grid-column: auto;

        width: 100%;
    }
}


@media (max-width: 460px) {

    .back-home {
        padding: 0 10px;

        font-size: 10px;
    }


    .summary-details {
        display: grid;

        grid-template-columns: 1fr 1fr;

        width: 100%;
    }


    .seat {
        width: 35px;

        flex-basis: 35px;

        height: 32px;
    }


    .seat-row {
        gap: 7px;
    }


    .seat-row-seats {
        gap: 6px;
    }


    .seat-aisle {
        width: 13px;

        flex-basis: 13px;
    }
}
