/* static/css/checkout/payment.css */

:root {
    --hexaco-light: #F9FF9F;
    --eq-light: #FFD5C4;
    --enneagram-light: #C2E5E5;
    --sq-light: #D1E6F9;
    --aq-light: #FFCB9B;
}

/* ===== Globals ===== */
h1 {
    text-align: center;
    font-size: 32px;
    margin-bottom: 20px;
}

h2 {
    text-align: center;
    font-family: inherit;
    font-weight: 700;
    font-size: 28px;
    color: #274285;
}

del {
    color: grey;
    font-weight: normal;
}

.payment-container {
    background-color: #f7faff;
}

.width-controller {
    max-width: 600px;
    margin: auto;
}

/* ===== Reference-style checkout card ===== */
.pay-header {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 16px;
    margin: 10px auto 16px;
}

.pay-title {
    text-align: left;
    font-size: 30px;
    font-weight: 800;
    color: #1f2a44;
    margin: 0;
}

.pay-currency select {
    appearance: none;
    -webkit-appearance: none;
    border: 0;
    background: transparent;
    color: #6b7280;
    font-weight: 700;
    font-size: 14px;
    padding: 4px 22px 4px 6px;
    cursor: pointer;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath fill='none' stroke='%236b7280' stroke-width='1.6' d='M1 1.5 6 6.5l5-5'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 2px center;
}

.pay-card {
    background: #f4f6fb;
    border: 1px solid #eaeffa;
    border-radius: 16px;
    padding: 28px 30px;
    margin: 0 auto;
}

.pay-total {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
}

.pay-total-label { font-weight: 700; color: #1f2a44; font-size: 18px; }
.pay-total-amount { font-weight: 800; color: #2f8a5b; font-size: 22px; }

.pay-divider {
    border: 0;
    border-top: 1px solid #e3e8ef;
    margin: 16px 0 20px;
}

.pay-fields {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-bottom: 22px;
}

.pay-input {
    width: 100%;
    box-sizing: border-box;
    background: #fff;
    border: 1px solid #e3e8ef;
    border-radius: 10px;
    padding: 14px 16px;
    font-size: 15px;
    color: #1f2a44;
}

.pay-input::placeholder { color: #9aa3b2; }

.pay-input:focus {
    outline: 0;
    border-color: #2f8a5b;
    box-shadow: 0 0 0 3px rgba(47, 138, 91, .15);
}

.pay-method-label {
    font-weight: 800;
    color: #1f2a44;
    font-size: 18px;
    margin: 6px 0 14px;
}

#payment-element { margin-bottom: 20px; }

.payment-form { width: 100%; }

.pay-submit {
    width: 100%;
    border: 0;
    border-radius: 12px;
    cursor: pointer;
    background: #3f7d58;
    color: #fff;
    font-size: 17px;
    font-weight: 700;
    padding: 16px 20px;
    transition: background .15s ease;
}

.pay-submit:hover { background: #366b4c; }
.pay-submit:disabled { opacity: .7; cursor: default; }

.pay-errors {
    color: #e74545;
    font-size: 14px;
    margin-top: 10px;
    text-align: center;
}

.pay-disclaimer {
    margin: 18px 4px 0;
    color: #8a93a5;
    font-size: 13px;
    line-height: 1.5;
    text-align: center;
}

/* ===== Email auto-save status (update_email.js) ===== */
.email-input-wrapper {
    position: relative;
    display: block;
    width: 100%;
}

#email-status-text { line-height: normal; }

.email-status {
    display: flex;
    align-items: center;
    font-size: 14px;
    margin-top: 6px;
    text-align: left;
    transition: opacity 0.3s ease;
}

.email-status i {
    font-size: 16px;
    margin-right: 5px;
}

.saving-icon { color: #274285; }
.saved-icon { color: #274285; }
.error-icon { color: #e74545; }

.spinner {
    display: inline-block;
    width: 16px;
    height: 16px;
    border: 2px solid #ccc;
    border-top: 2px solid #007bff;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

/* ===== Countdown / discount alert ===== */
.discount-alert {
    display: flex;
    align-items: center;
    gap: 8px;
    color: white;
    background: #e74545;
    padding: 10px;
    border-radius: 8px;
    line-height: normal;
    font-size: 14px;
    min-height: 50px;
    max-width: 600px;
    width: 100%;
    margin: auto;
}

.discount-alert .info-icon { margin-top: 2px; }
.discount-alert .larger { font-size: 18px; }

.btn-discount {
    font-size: 18px;
    font-weight: 700;
    color: white;
    margin-left: auto;
    text-wrap-mode: nowrap;
}

#countdown-timer {
    font-size: 18px;
    font-weight: bold;
}

/* ===== Custom review ===== */
.tests-review-container {
    display: flex;
    align-items: center;
    flex-direction: column;
    margin: auto;
    gap: 10px;
}

/* ===== Benefits ===== */
.list-group {
    background-color: #fff;
    margin-bottom: 10px;
    overflow: hidden;
    border: 1px solid #eaeffa;
    box-shadow: 0px 2px 6px #e6edfc8f;
    padding: 20px;
}

.list-group-item {
    border: none;
    border-bottom: 1px solid rgb(234 239 250);
    line-height: normal;
    display: flex;
    flex-direction: row;
    align-items: flex-start;
    gap: 10px;
    padding: 1rem 1rem 1rem 0;
}

.list-group-item i {
    font-size: 24px;
    color: #274285;
    padding: 6px;
    background: aliceblue;
    border-radius: 20px;
}

.benefits-illustration {
    width: 40%;
    margin: 20px auto;
    position: relative;
    display: flex;
    justify-content: center;
    align-items: center;
}

.benefits-illustration::before {
    content: '';
    position: absolute;
    width: 300px;
    height: 300px;
    background-color: #e3f3ff;
    border-radius: 50%;
    z-index: 0;
}

.benefits-illustration img {
    position: relative;
    z-index: 1;
    max-width: 100%;
    height: auto;
}

.unlock-button {
    display: flex;
    align-items: center;
    width: 50%;
    margin: 20px auto;
}

/* ===== FAQs ===== */
section.faq-container { padding: 0; }

.accordion-item:first-of-type {
    border-top-left-radius: 10px;
    border-top-right-radius: 10px;
}

.faq-container { background-color: #f7faff; }
.faq-container h3 { font-family: inherit; }

.faq-list {
    display: flex;
    padding: 40px 0 0;
    flex-direction: column;
    justify-content: center;
}

.accordion-item {
    background-color: #fff;
    border: none;
    border-radius: 10px;
    margin-bottom: 10px;
    overflow: hidden;
    border: 1px solid #eaeffa;
    box-shadow: 0px 2px 6px #e6edfc8f;
}

.accordion-button {
    background: white;
    color: black;
    box-shadow: none;
}

.accordion-button:focus { box-shadow: none; }

.accordion-button:not(.collapsed) {
    color: #274285;
    background-color: white;
    box-shadow: inset 0 -1px 0 rgb(234 239 250);
}

/* ===== Responsive ===== */
@media (max-width: 768px) {

    .pay-card { padding: 22px 18px; }
    .pay-title { font-size: 24px; }

    .benefits { padding: 40px 0 0; }

    .discount-mb-header {
        display: flex;
        flex-direction: column;
        align-items: flex-start;
        gap: 6px;
    }

    .unlock-button {
        width: 100%;
        position: relative;
        z-index: 100;
    }

    .benefits-illustration {
        width: 60%;
        margin: 20px auto;
    }

    /* Countdown */
    .countdown-section {
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        margin: 0 !important;
        background-color: #274285;
        padding: 10px 20px;
        text-align: center;
        z-index: 1000;
        border-radius: 0;
    }

}