/* =========================================================
   JivanSangini — New User Registration
   Desktop-first. Media queries appended at the end — do not
   edit rules above when adjusting for smaller screens.
   ========================================================= */

@import url('https://fonts.googleapis.com/css2?family=Playfair+Display:wght@600;700&family=Poppins:wght@400;500;600&display=swap');

:root {
    --maroon: #5c2444;
    --maroon-dark: #401a30;
    --pink: #8a3a63;
    --gold: #d4a862;
    --cream: #FBF7F9;
    --rose-tint: #F3E8EE;
    --ink: #3a2233;
    --ink-soft: #8c7a86;
    --border-soft: #E4D3DE;
}

html, body {
    margin: 0;
    padding: 0;
    height: 100%;
}

.register-page * {
    box-sizing: border-box;
}

.register-page {
    display: block;
    min-height: 100vh;
    background: var(--cream);
    font-family: 'Poppins', sans-serif;
    color: var(--ink);
}

/* ================= LEFT BRAND PANEL ================= */
.register-brand {
    width: 38%;
    max-width: 460px;
    background: linear-gradient(165deg, var(--maroon) 0%, var(--maroon-dark) 100%);
    color: #fff;
    padding: 36px 44px;
    position: fixed;
    top: 0;
    left: 0;
    height: 100vh;
    display: flex;
    flex-direction: column;
    z-index: 10;
    overflow: hidden;
}

.brand-logo {
    font-family: 'Playfair Display', serif;
    font-size: 30px;
    font-weight: 700;
    margin: 0;
}

.brand-logo span {
    color: var(--gold);
}

.brand-tagline {
    font-family: 'Playfair Display', serif;
    font-style: italic;
    font-size: 15px;
    color: rgba(255, 255, 255, .75);
    margin: 10px 0 0;
}

/* ---- Mala (garland) stepper ---- */
.mala-stepper {
    list-style: none;
    margin: 20px 0;
    padding: 0;
    position: relative;
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    min-height: 0;
}

.mala-stepper::before {
    content: '';
    position: absolute;
    left: 11px;
    top: 12px;
    bottom: 12px;
    width: 2px;
    background: rgba(255, 255, 255, .18);
}

.mala-stepper .mala-thread-fill {
    position: absolute;
    left: 11px;
    top: 12px;
    width: 2px;
    background: var(--gold);
    transition: height .5s ease;
    height: 0%;
}

.mala-bead {
    position: relative;
    display: flex;
    align-items: flex-start;
    gap: 18px;
    opacity: .45;
    transition: opacity .3s ease;
}

.mala-bead .bead {
    width: 24px;
    height: 24px;
    min-width: 24px;
    border-radius: 50%;
    background: var(--maroon-dark);
    border: 2px solid rgba(255, 255, 255, .35);
    position: relative;
    z-index: 1;
    transition: background .3s ease, border-color .3s ease, box-shadow .3s ease;
}

.bead-label h4 {
    font-size: 14.5px;
    font-weight: 600;
    margin: 2px 0 3px;
}

.bead-label p {
    font-size: 12px;
    color: rgba(255, 255, 255, .65);
    margin: 0;
}

.mala-bead.is-active,
.mala-bead.is-complete {
    opacity: 1;
}

.mala-bead.is-active .bead {
    background: var(--pink);
    border-color: var(--gold);
    box-shadow: 0 0 0 4px rgba(212, 168, 98, .25);
}

.mala-bead.is-complete .bead {
    background: var(--gold);
    border-color: var(--gold);
}

.mala-bead.is-complete .bead::after {
    content: '';
    position: absolute;
    left: 7px;
    top: 4px;
    width: 5px;
    height: 9px;
    border-right: 2px solid var(--maroon-dark);
    border-bottom: 2px solid var(--maroon-dark);
    transform: rotate(45deg);
}

.brand-footnote {
    font-size: 13.5px;
    color: rgba(255, 255, 255, .7);
    margin: 0;
}

.brand-footnote a {
    color: var(--gold);
    font-weight: 600;
    text-decoration: none;
}

.brand-footnote a:hover {
    text-decoration: underline;
}

/* ================= RIGHT FORM PANEL ================= */
.register-form-panel {
    margin-left: min(38%, 460px);
    padding: 64px 80px;
    max-width: 780px;
    height: 100vh;
    overflow-y: auto;
    box-sizing: border-box;
}

.mobile-progress {
    display: none;
}

.form-step {
    display: none;
    border: none;
    padding: 0;
    margin: 0;
    animation: stepIn .35s ease;
}

.form-step.is-active {
    display: block;
}

@keyframes stepIn {
    from { opacity: 0; transform: translateY(8px); }
    to { opacity: 1; transform: translateY(0); }
}

.step-eyebrow {
    font-size: 12.5px;
    font-weight: 600;
    letter-spacing: 1.2px;
    text-transform: uppercase;
    color: var(--pink);
}

.step-head h2 {
    font-family: 'Playfair Display', serif;
    font-size: 30px;
    margin: 8px 0 6px;
    color: var(--maroon);
}

.step-sub {
    font-size: 14.5px;
    color: var(--ink-soft);
    margin: 0 0 32px;
}

.form-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 22px 24px;
}

.field-span-2 {
    grid-column: 1 / -1;
}

.field {
    display: flex;
    flex-direction: column;
    position: relative;
}

.field label {
    font-size: 13.5px;
    font-weight: 600;
    margin-bottom: 7px;
    color: var(--ink);
}

.field label em {
    font-style: normal;
    font-weight: 400;
    color: var(--ink-soft);
}

.field input,
.field select {
    font-family: 'Poppins', sans-serif;
    font-size: 14.5px;
    padding: 13px 14px;
    border-radius: 10px;
    border: 1.5px solid var(--border-soft);
    background: #fff;
    color: var(--ink);
    outline: none;
    transition: border-color .2s ease, box-shadow .2s ease;
}

.field input:focus,
.field select:focus {
    border-color: var(--pink);
    box-shadow: 0 0 0 3px rgba(138, 58, 99, .15);
}

.field select {
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20' fill='%238c7a86'%3E%3Cpath d='M5.5 7.5l4.5 4.5 4.5-4.5' stroke='%238c7a86' stroke-width='1.5' fill='none' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 14px center;
    padding-right: 36px;
}

.input-with-prefix {
    display: flex;
    align-items: center;
    border-radius: 10px;
    border: 1.5px solid var(--border-soft);
    background: #fff;
    overflow: hidden;
    transition: border-color .2s ease, box-shadow .2s ease;
}

.input-with-prefix:focus-within {
    border-color: var(--pink);
    box-shadow: 0 0 0 3px rgba(138, 58, 99, .15);
}

.input-prefix {
    padding: 13px 12px;
    font-size: 14px;
    font-weight: 600;
    color: var(--ink-soft);
    background: var(--rose-tint);
    border-right: 1.5px solid var(--border-soft);
}

.input-with-prefix input {
    border: none;
    box-shadow: none !important;
    flex: 1;
}

.field-error {
    display: none;
    font-size: 12px;
    color: var(--maroon);
    margin-top: 6px;
}

.field.has-error input,
.field.has-error select,
.field.has-error .input-with-prefix {
    border-color: var(--maroon);
}

.field.has-error .field-error {
    display: block;
}

/* ---- Pill choice groups (gender / marital status) ---- */
.pill-group {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.pill {
    font-family: 'Poppins', sans-serif;
    font-size: 13.5px;
    font-weight: 500;
    padding: 11px 20px;
    border-radius: 999px;
    border: 1.5px solid var(--border-soft);
    background: #fff;
    color: var(--ink);
    cursor: pointer;
    transition: all .2s ease;
}

.pill:hover {
    border-color: var(--pink);
}

.pill.is-selected {
    background: var(--maroon);
    border-color: var(--maroon);
    color: #fff;
}

/* ---- Photo upload (step 5) ---- */
.photo-upload {
    display: flex;
    align-items: center;
    gap: 20px;
    padding: 20px;
    border-radius: 14px;
    background: var(--rose-tint);
    border: 1.5px dashed var(--border-soft);
    margin-bottom: 32px;
}

.photo-preview {
    width: 72px;
    height: 72px;
    min-width: 72px;
    border-radius: 50%;
    background: #fff;
    border: 1.5px solid var(--border-soft);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--pink);
    overflow: hidden;
}

.photo-preview img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.photo-copy p {
    font-size: 12.5px;
    color: var(--ink-soft);
    margin: 8px 0 0;
    max-width: 380px;
}

.btn-upload {
    font-family: 'Poppins', sans-serif;
    font-size: 13.5px;
    font-weight: 600;
    padding: 10px 20px;
    border-radius: 10px;
    border: 1.5px solid var(--maroon);
    background: #fff;
    color: var(--maroon);
    cursor: pointer;
    transition: background .2s ease, color .2s ease;
}

.btn-upload:hover {
    background: var(--maroon);
    color: #fff;
}

/* ---- Checkbox line (terms) ---- */
.checkbox-line {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    font-size: 13px;
    color: var(--ink-soft);
    cursor: pointer;
    margin-top: 4px;
}

.checkbox-line input {
    margin-top: 2px;
}

.checkbox-line a {
    color: var(--maroon);
    font-weight: 600;
    text-decoration: none;
}

.checkbox-line a:hover {
    text-decoration: underline;
}

#termsError {
    display: none;
    font-size: 12px;
    color: var(--maroon);
    margin-top: 6px;
}

#termsError.show {
    display: block;
}

/* ---- Step actions ---- */
.step-actions {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 40px;
}

.step-actions-single {
    justify-content: flex-end;
}

.btn-back {
    background: none;
    border: none;
    font-family: 'Poppins', sans-serif;
    font-size: 14px;
    font-weight: 600;
    color: var(--ink-soft);
    cursor: pointer;
}

.btn-back:hover {
    color: var(--maroon);
}

.btn-next,
.btn-submit {
    font-family: 'Poppins', sans-serif;
    font-size: 14.5px;
    font-weight: 600;
    padding: 14px 32px;
    border-radius: 999px;
    border: none;
    background: var(--maroon);
    color: #fff;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    transition: background .2s ease, transform .15s ease;
}

.btn-next:hover,
.btn-submit:hover {
    background: var(--maroon-dark);
    transform: translateY(-1px);
}

.btn-submit {
    background: var(--pink);
}

.btn-submit:hover {
    background: #6f2f52;
}

/* ---- Auth tabs (Login / Register) ---- */
.auth-tabs {
    display: flex;
    gap: 20px;
    font-size: 15px;
    font-weight: 600;
    color: var(--ink-soft);
}

.auth-tabs a {
    color: var(--ink-soft);
    text-decoration: none;
}

.auth-tabs a:hover {
    color: var(--maroon);
}

.auth-tab.is-active {
    color: var(--maroon);
}

.auth-tabs-rule {
    border: none;
    border-top: 1.5px solid var(--border-soft);
    margin: 14px 0 32px;
}

/* ---- Inline text-button links (change number, resend, edit) ---- */
.link-btn {
    background: none;
    border: none;
    padding: 0;
    font-family: 'Poppins', sans-serif;
    font-size: inherit;
    font-weight: 600;
    color: var(--maroon);
    text-decoration: underline;
    cursor: pointer;
}

.link-btn:hover {
    color: var(--maroon-dark);
}

.field-hint {
    font-size: 12px;
    color: var(--ink-soft);
    margin: 8px 0 0;
}

.is-hidden {
    display: none !important;
}

/* ---- OTP hero icon ---- */
.otp-hero {
    width: 52px;
    height: 52px;
    border-radius: 14px;
    background: var(--rose-tint);
    color: var(--maroon);
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 24px;
}

/* ---- OTP boxes: small, square, one digit each ---- */
.otp-boxes {
    display: flex;
    gap: 12px;
}

.otp-box {
    width: 48px;
    height: 56px;
    padding: 0;
    text-align: center;
    font-family: 'Poppins', sans-serif;
    font-size: 22px;
    font-weight: 600;
    border-radius: 10px;
    border: 1.5px solid var(--border-soft);
    background: #fff;
    color: var(--ink);
    outline: none;
    transition: border-color .2s ease, box-shadow .2s ease;
}

.otp-box:focus {
    border-color: var(--pink);
    box-shadow: 0 0 0 3px rgba(138, 58, 99, .15);
}

.otp-box.has-error {
    border-color: var(--maroon);
}

/* ---- Resend row ---- */
.resend-row {
    font-size: 13.5px;
    color: var(--ink-soft);
    margin: 16px 0 0;
}

/* ---- Mobile chip (step 6, verified number display) ---- */
.mobile-chip {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 16px;
    border-radius: 999px;
    background: var(--rose-tint);
    color: var(--maroon);
    font-size: 13.5px;
    font-weight: 600;
    margin-bottom: 28px;
}

.mobile-chip svg {
    color: var(--maroon);
}

/* =========================================================
   RESPONSIVE — appended rules only, nothing above is edited
   ========================================================= */

/* ===== Mobile (below 640px): shrink OTP boxes slightly ===== */
@media (max-width: 639.98px) {
    .otp-boxes {
        gap: 8px;
    }

    .otp-box {
        width: 42px;
        height: 50px;
        font-size: 19px;
    }
}

/* ===== Short viewports (desktop/laptop with limited height) ===== */
@media (max-height: 760px) and (min-width: 900px) {
    .register-brand {
        padding: 24px 40px;
    }

    .brand-tagline {
        margin-top: 4px;
    }

    .mala-stepper {
        margin: 12px 0;
    }

    .bead-label h4 {
        font-size: 13.5px;
        margin: 0 0 2px;
    }

    .bead-label p {
        font-size: 11px;
    }

    .mala-bead .bead {
        width: 20px;
        height: 20px;
        min-width: 20px;
    }
}

@media (max-height: 640px) and (min-width: 900px) {
    .brand-footnote {
        display: none;
    }
}

/* ===== Tablet (768px - 1099px) ===== */
@media (max-width: 1099.98px) {
    .register-brand {
        width: 34%;
        padding: 44px 32px;
    }

    .register-form-panel {
        margin-left: 34%;
        padding: 48px 40px;
    }
}

/* ===== Below 900px: stack brand panel as top bar, hide mala labels ===== */
@media (max-width: 899.98px) {
    .register-page {
        display: block;
    }

    .register-brand {
        position: relative;
        top: auto;
        left: auto;
        width: 100%;
        max-width: none;
        height: auto;
        padding: 28px 24px;
        flex-direction: row;
        align-items: center;
        justify-content: space-between;
        z-index: auto;
    }

    .brand-top {
        flex: 1;
    }

    .brand-tagline {
        display: none;
    }

    .mala-stepper,
    .brand-footnote {
        display: none;
    }

    .mobile-progress {
        display: block;
        width: 260px;
    }

    .mobile-progress-track {
        width: 100%;
        height: 6px;
        border-radius: 999px;
        background: rgba(255, 255, 255, .25);
        overflow: hidden;
    }

    .mobile-progress-fill {
        height: 100%;
        width: 20%;
        background: var(--gold);
        transition: width .35s ease;
    }

    .mobile-progress-text {
        font-size: 12px;
        color: rgba(255, 255, 255, .85);
        margin: 8px 0 0;
    }

    .register-form-panel {
        margin-left: 0;
        max-width: none;
        height: auto;
        overflow-y: visible;
        padding: 36px 24px 60px;
    }
}

/* ===== Mobile (below 640px) ===== */
@media (max-width: 639.98px) {
    .register-brand {
        flex-direction: column;
        align-items: flex-start;
        gap: 16px;
        padding: 24px 20px;
    }

    .mobile-progress {
        width: 100%;
    }

    .brand-logo {
        font-size: 24px;
    }

    .step-head h2 {
        font-size: 23px;
    }

    .form-grid {
        grid-template-columns: 1fr;
    }

    .field-span-2 {
        grid-column: auto;
    }

    .photo-upload {
        flex-direction: column;
        align-items: flex-start;
    }

    .step-actions {
        flex-direction: column-reverse;
        gap: 14px;
        align-items: stretch;
    }

    .btn-next,
    .btn-submit {
        justify-content: center;
        width: 100%;
    }

    .btn-back {
        text-align: center;
    }
}






