/**
 * KIDDIE BLOCKS PH - CHECKOUT FUNNEL CSS
 * Brand Standards: Prussian Blue (#091951), Dusty Sky (#9DB6DA), Cherry Red (#F12020)
 */

.checkout-modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: rgba(9, 25, 81, 0.85);
    backdrop-filter: blur(6px);
    z-index: 10000;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 16px;
    box-sizing: border-box;
}

.checkout-modal-overlay.active {
    display: flex;
    animation: fadeInModal 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

.checkout-modal-dialog {
    background: #FFFFFF;
    width: 100%;
    max-width: 680px;
    max-height: 92vh;
    border-radius: 20px;
    box-shadow: 0 25px 60px rgba(9, 25, 81, 0.35);
    border: 2px solid var(--prussian-blue, #091951);
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

/* Header */
.checkout-header {
    background: var(--prussian-blue, #091951);
    color: #FFFFFF;
    padding: 16px 22px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-shrink: 0;
}

.checkout-badge {
    font-size: 7.5pt;
    font-weight: 700;
    color: var(--dusty-sky, #9DB6DA);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    display: block;
}

.checkout-brand-title h2 {
    font-family: 'ABeeZee', sans-serif;
    font-size: 13pt;
    color: #FFFFFF;
    margin: 2px 0 0 0;
}

.checkout-close-btn {
    background: transparent;
    border: none;
    color: #FFFFFF;
    font-size: 16pt;
    cursor: pointer;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s;
}

.checkout-close-btn:hover {
    background: rgba(255, 255, 255, 0.2);
}

/* Body */
.checkout-body {
    flex: 1;
    overflow-y: auto;
    padding: 22px 24px;
    background: #F8FAFC;
    scrollbar-width: thin;
}

.checkout-form-section {
    background: #FFFFFF;
    border: 1.5px solid #E2E8F0;
    border-radius: 14px;
    padding: 16px 18px;
    margin-bottom: 18px;
}

.form-section-heading {
    font-family: 'ABeeZee', sans-serif;
    font-size: 10pt;
    color: var(--prussian-blue, #091951);
    margin-bottom: 14px;
    border-bottom: 1px dashed #E2E8F0;
    padding-bottom: 6px;
}

.form-row {
    display: flex;
    gap: 12px;
    margin-bottom: 12px;
}

.form-row.two-col {
    display: grid;
    grid-template-columns: 1fr 1fr;
}

.form-group {
    display: flex;
    flex-direction: column;
}

.form-group.full-width {
    width: 100%;
}

.form-group label {
    font-size: 7.5pt;
    font-weight: 700;
    color: #334155;
    margin-bottom: 4px;
    text-transform: uppercase;
    letter-spacing: 0.3px;
}

.form-group label .req {
    color: var(--cherry-red, #F12020);
}

.form-group input {
    padding: 10px 12px;
    border-radius: 8px;
    border: 1.5px solid #CBD5E1;
    font-family: 'Montserrat', sans-serif;
    font-size: 8.5pt;
    color: #0F172A;
    outline: none;
    transition: all 0.2s;
    background: #FFFFFF;
}

.form-group input:focus {
    border-color: var(--prussian-blue, #091951);
    box-shadow: 0 0 0 3px rgba(9, 25, 81, 0.1);
}

.form-group input.input-error {
    border-color: #EF4444;
    background: #FEF2F2;
}

.form-error-msg {
    font-size: 7pt;
    color: #EF4444;
    font-weight: 600;
    margin-top: 3px;
    display: none;
}

/* Logistics & Order Summary Box */
.checkout-summary-box {
    background: #EEF4FC;
    border: 1.5px solid var(--dusty-sky, #9DB6DA);
    border-radius: 14px;
    padding: 16px 18px;
    margin-bottom: 18px;
}

.summary-box-heading {
    font-family: 'ABeeZee', sans-serif;
    font-size: 10pt;
    color: var(--prussian-blue, #091951);
    margin-bottom: 10px;
    border-bottom: 1px solid rgba(9, 25, 81, 0.1);
    padding-bottom: 6px;
}

.summary-item-row {
    display: flex;
    justify-content: space-between;
    font-size: 8.5pt;
    margin-bottom: 6px;
    color: #334155;
}

.summary-item-row.highlight-row {
    color: var(--prussian-blue, #091951);
    font-weight: 700;
}

.sum-item-val {
    font-weight: 700;
}

.summary-delivery-badge {
    background: #FFFFFF;
    border: 1px solid var(--dusty-sky, #9DB6DA);
    color: var(--prussian-blue, #091951);
    padding: 6px 12px;
    border-radius: 8px;
    font-size: 8pt;
    margin: 8px 0;
    text-align: center;
}

.summary-total-row {
    border-top: 1.5px dashed var(--dusty-sky, #9DB6DA);
    padding-top: 8px;
    margin-top: 6px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-family: 'ABeeZee', sans-serif;
    font-size: 11pt;
    font-weight: 800;
    color: var(--prussian-blue, #091951);
}

.sum-total-val {
    font-size: 15pt;
    color: var(--cherry-red, #F12020);
}

/* Action Wrap */
.checkout-action-wrap {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
}

.btn-proceed-maya {
    width: 100%;
    background: var(--cherry-red, #F12020);
    color: #FFFFFF;
    border: none;
    padding: 14px 20px;
    border-radius: 50px;
    font-family: 'Montserrat', sans-serif;
    font-size: 10pt;
    font-weight: 800;
    cursor: pointer;
    box-shadow: 0 6px 18px rgba(241, 32, 32, 0.35);
    transition: all 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
}

.btn-proceed-maya:hover:not(:disabled) {
    background: #D01414;
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(241, 32, 32, 0.45);
}

.btn-proceed-maya:disabled {
    opacity: 0.65;
    cursor: not-allowed;
}

.checkout-guarantee {
    font-size: 7.5pt;
    color: #64748B;
    text-align: center;
    line-height: 1.4;
    max-width: 480px;
}

/* Mobile */
@media (max-width: 600px) {
    .checkout-modal-overlay {
        padding: 0;
    }
    .checkout-modal-dialog {
        max-height: 100vh;
        height: 100vh;
        border-radius: 0;
        border: none;
    }
    .form-row.two-col {
        grid-template-columns: 1fr;
    }
    .checkout-body {
        padding: 16px;
    }
}
