/* ==========================================================================
   Signup Form — LearnQuranBD (Premium redesign)
   Pulls brand colors DIRECTLY from the theme's own variables defined in
   learnquranbd-markup.css (--navy-900, --amber-500, --teal-600, etc.) so it
   always stays in sync with the rest of the site. Fallback values are
   provided in case this file ever loads before markup.css.
   ========================================================================== */

.lq-signup-wrap {
    font-family: 'Poppins', sans-serif;
    color: var(--ink-900, #0E1B33);
}

/* ---------- Page header banner (brand gradient, matches trust-strip) ---------- */
.lq-page-header {
    background: linear-gradient(90deg, var(--navy-900, #0A2E5C), var(--navy-700, #0E47A1), var(--navy-900, #0A2E5C));
    padding: 64px 0 56px;
    text-align: center;
}

.lq-page-header h1 {
    font-family: 'Poppins', sans-serif;
    font-weight: 700;
    font-size: clamp(28px, 3.5vw, 40px);
    color: #fff;
    letter-spacing: -0.015em;
    margin-bottom: 10px;
}

.lq-page-header p.lead {
    color: rgba(255, 255, 255, 0.7);
    font-size: 16px;
    max-width: 480px;
    margin: 0 auto;
}

/* ---------- Layout grid ---------- */
.lq-signup-grid {
    display: grid;
    grid-template-columns: minmax(0, 1.15fr) minmax(0, 0.85fr);
    gap: 48px;
    align-items: start;
    padding: 64px 0;
}

@media (max-width: 991px) {
    .lq-signup-grid {
        display: flex !important;
        flex-direction: column !important;
        padding: 32px 0;
    }
    .lq-signup-illustration {
        order: 2;
        width: 100% !important;
        max-width: 420px !important;
        margin: 28px auto 0 !important;
        flex: none;
    }
    .lq-signup-illustration .arch-frame {
        width: 100% !important;
        max-width: 100% !important;
        height: auto !important;
        aspect-ratio: 4 / 3 !important;
        margin: 0 auto;
        background: none !important;
        box-shadow: none !important;
        padding: 0 !important;
        border-radius: 16px !important;
    }
    .lq-signup-illustration .arch-frame::after {
        display: none;
    }
    .lq-signup-illustration .arch-frame-media {
        top: 0 !important; right: 0 !important; bottom: 0 !important; left: 0 !important;
        border-radius: 16px !important;
    }
}

@media (min-width: 992px) {
    .lq-signup-grid {
        display: grid;
    }
}

/* ---------- Illustration: reuses the theme's own arch-frame visual ---------- */
.lq-signup-illustration .arch-frame {
    max-width: 100%;
    position: sticky;
    top: 100px;
}

@media (max-width: 991px) {
    .lq-signup-illustration .arch-frame {
        position: relative !important;
        top: auto !important;
    }
    .lq-signup-illustration .arch-frame-media {
        position: absolute !important;
        width: auto !important;
        height: auto !important;
        top: 0 !important; right: 0 !important; bottom: 0 !important; left: 0 !important;
    }
}

/* ---------- Card ---------- */
.lq-signup-card {
    background: #fff;
    border: 1px solid var(--line, #E2E9F5);
    border-radius: 24px;
    box-shadow: var(--shadow-card, 0 14px 34px -18px rgba(10, 46, 92, 0.28));
    padding: 40px;
}

@media (max-width: 575px) {
    .lq-signup-card {
        padding: 24px 20px;
        border-radius: 18px;
    }
}

.lq-signup-card .eyebrow {
    margin-bottom: 14px;
}

.lq-signup-card h2 {
    font-family: 'Poppins', sans-serif;
    font-size: 1.6rem;
    font-weight: 700;
    margin-bottom: 28px;
    color: var(--navy-900, #0A2E5C);
    letter-spacing: -0.01em;
}

.lq-signup-card h3.lq-section-title {
    font-family: 'Poppins', sans-serif;
    font-size: 1.15rem;
    font-weight: 700;
    margin: 8px 0 20px;
    padding-top: 28px;
    border-top: 1px dashed var(--line, #E2E9F5);
    color: var(--navy-900, #0A2E5C);
    display: flex;
    align-items: center;
    gap: 10px;
}

.lq-signup-card h3.lq-section-title::before {
    content: '';
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--amber-500, #E08A3C), var(--amber-600, #C7671D));
    flex: none;
}

/* ---------- Student type toggle (premium sliding pill) ---------- */
.lq-type-toggle {
    display: flex;
    background: var(--paper-2, #EDF2FA);
    border: 1px solid var(--line, #E2E9F5);
    border-radius: 50px;
    padding: 5px;
    margin-bottom: 28px;
    position: relative;
}

.lq-type-toggle input[type="radio"] {
    position: absolute;
    opacity: 0;
    pointer-events: none;
}

.lq-type-toggle label {
    flex: 1;
    text-align: center;
    padding: 12px 12px;
    border-radius: 50px;
    font-weight: 600;
    font-size: 0.92rem;
    cursor: pointer;
    color: var(--ink-500, #6D7A94);
    transition: color 0.25s ease;
    margin: 0;
    position: relative;
    z-index: 1;
}

.lq-type-toggle input[type="radio"]:checked + label {
    color: #fff;
}

.lq-type-toggle input#lq-type-adult:checked ~ label[for="lq-type-adult"],
.lq-type-toggle input#lq-type-child:checked ~ label[for="lq-type-child"] {
    background: linear-gradient(135deg, var(--navy-700, #0E47A1), var(--navy-900, #0A2E5C));
    box-shadow: 0 8px 20px -8px rgba(10, 46, 92, 0.55);
}

/* ---------- Field rows: 2-column on desktop, stacked on mobile (keeps the form compact) ---------- */
.lq-field-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0 18px;
}

@media (max-width: 575px) {
    .lq-field-row {
        grid-template-columns: 1fr;
    }
}

/* ---------- Fields ---------- */
.lq-field {
    margin-bottom: 20px;
}

.lq-field label {
    display: block;
    font-weight: 600;
    font-size: 0.86rem;
    margin-bottom: 7px;
    color: var(--ink-900, #0E1B33);
}

.lq-field .lq-optional-tag {
    font-weight: 400;
    color: var(--ink-500, #6D7A94);
    font-size: 0.76rem;
}

.lq-field input[type="text"],
.lq-field input[type="email"],
.lq-field input[type="tel"],
.lq-field input[type="number"],
.lq-field input[type="time"],
.lq-field select {
    width: 100%;
    padding: 12px 14px;
    border: 1.5px solid var(--line, #E2E9F5);
    border-radius: 10px;
    font-size: 0.92rem;
    font-family: inherit;
    background: var(--paper, #F6F9FD);
    color: var(--ink-900, #0E1B33);
    transition: border-color 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
    height: 48px;
}

.lq-field select {
    appearance: none;
    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='%236D7A94' d='M1 1l5 5 5-5'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 14px center;
    padding-right: 36px;
}

.lq-field input:focus,
.lq-field select:focus {
    outline: none;
    border-color: var(--navy-500, #1C63C9);
    background: #fff;
    box-shadow: 0 0 0 4px rgba(28, 99, 201, 0.12);
}

.lq-field small.lq-hint {
    display: block;
    margin-top: 6px;
    color: var(--ink-500, #6D7A94);
    font-size: 0.76rem;
}

.lq-field .lq-custom-input {
    margin-top: 8px;
}

.lq-budget-row {
    display: flex;
    gap: 10px;
}

.lq-budget-row input {
    flex: 1;
}

.lq-budget-row select {
    flex: 0 0 90px;
    width: 90px;
}

.lq-field.lq-field-error input,
.lq-field.lq-field-error select {
    border-color: #D64545;
    background: #FEF4F4;
}

.lq-field-error-msg {
    color: #D64545;
    font-size: 0.78rem;
    margin-top: 6px;
    display: none;
}

.lq-field.lq-field-error .lq-field-error-msg {
    display: block;
}

/* ---------- Days checkbox grid ---------- */
.lq-days-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
}

@media (min-width: 480px) {
    .lq-days-grid {
        grid-template-columns: repeat(4, 1fr);
    }
}

.lq-day-checkbox {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 11px 10px;
    border: 1.5px solid var(--line, #E2E9F5);
    border-radius: 10px;
    cursor: pointer;
    font-size: 0.84rem;
    font-weight: 500;
    background: var(--paper, #F6F9FD);
    transition: all 0.15s ease;
}

.lq-day-checkbox input {
    accent-color: var(--navy-700, #0E47A1);
    width: 15px;
    height: 15px;
    flex: none;
}

.lq-day-checkbox:has(input:checked) {
    border-color: var(--navy-700, #0E47A1);
    background: rgba(14, 71, 161, 0.06);
    color: var(--navy-900, #0A2E5C);
    font-weight: 600;
}

/* ---------- Phone input (intl-tel-input) ---------- */
.lq-field .iti {
    width: 100%;
    display: block;
}

.lq-field .iti input {
    width: 100%;
    height: 48px;
    padding-left: 105px !important;
}

.lq-field .iti .selected-flag {
    padding: 0 6px 0 14px;
    width: auto;
    min-width: 95px;
    white-space: nowrap;
}

.lq-field .iti .selected-dial-code {
    padding-left: 6px;
}

.lq-field .iti .country-list {
    z-index: 30;
    border-radius: 10px;
    box-shadow: var(--shadow-card, 0 14px 34px -18px rgba(10, 46, 92, 0.28));
    border: 1px solid var(--line, #E2E9F5);
    font-family: 'Poppins', sans-serif;
    font-size: 0.86rem;
    margin-top: 4px;
}

/* Prevent the country dropdown list from ever being clipped by parent layout */
.lq-signup-card,
.lq-field {
    overflow: visible;
}

/* ---------- Timezone note ---------- */
.lq-tz-note {
    font-size: 0.76rem;
    color: var(--ink-500, #6D7A94);
    margin-top: 6px;
}

/* ---------- Submit button (reuses theme's .btn .btn-primary look) ---------- */
.lq-signup-submit {
    width: 100%;
    border: none;
    font-family: 'Poppins', sans-serif;
    margin-top: 10px;
}

.lq-signup-legal {
    font-size: 0.78rem;
    color: var(--ink-500, #6D7A94);
    margin-top: 16px;
    text-align: center;
}

.lq-signup-legal a {
    color: var(--navy-700, #0E47A1);
    text-decoration: underline;
    font-weight: 500;
}

/* ---------- Response messages ---------- */
.lq-form-message {
    padding: 14px 18px;
    border-radius: 12px;
    margin-bottom: 22px;
    font-size: 0.88rem;
    font-weight: 500;
    display: none;
}

.lq-form-message.lq-msg-success {
    background: rgba(14, 118, 155, 0.1);
    color: var(--teal-600, #0E769B);
    display: block;
}

.lq-form-message.lq-msg-error {
    background: #FEF4F4;
    color: #D64545;
    display: block;
}

/* Hide sections based on active type — controlled by JS toggling [hidden] */
[data-lq-section][hidden] {
    display: none !important;
}
