/* ─────────────────────────────────────────
   Registration Wizard — register-wizard.css
   ───────────────────────────────────────── */

/* Outer wrapper */
.rw-outer {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 32px 16px;
    box-sizing: border-box;
}

/* Wizard card */
.rw-card {
    background: rgba(15, 14, 22, .92);
    backdrop-filter: blur(32px) saturate(1.5);
    -webkit-backdrop-filter: blur(32px) saturate(1.5);
    border: 1px solid rgba(255, 255, 255, .08);
    border-radius: 22px;
    padding: 36px 44px 40px;
    width: 600px;
    max-width: 97vw;
    box-shadow: 0 24px 80px rgba(0, 0, 0, .6);
    animation: rw-card-in .45s cubic-bezier(.22,1,.36,1);
    box-sizing: border-box;
}

@keyframes rw-card-in {
    from { opacity: 0; transform: translateY(24px) scale(.98); }
    to   { opacity: 1; transform: translateY(0)   scale(1);   }
}

/* ── Step progress bar ── */
.rw-progress {
    margin-bottom: 38px;
}

.rw-step-track {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    position: relative;
}

.rw-track-line {
    position: absolute;
    top: 15px;
    left: 20px;
    right: 20px;
    height: 2px;
    background: rgba(255, 255, 255, .08);
    z-index: 0;
    border-radius: 2px;
}

.rw-track-fill {
    position: absolute;
    top: 15px;
    left: 20px;
    height: 2px;
    background: linear-gradient(90deg, #12a19a, #0e7e78);
    border-radius: 2px;
    z-index: 0;
    transition: width .45s cubic-bezier(.4,0,.2,1);
}

.rw-step-dot {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 7px;
    position: relative;
    z-index: 1;
    flex: 1;
}

.rw-dot-circle {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: rgb(43, 43, 43);
    border: 2px solid rgba(255, 255, 255, .14);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    font-weight: 700;
    color: rgb(101 101 101);
    transition: all .35s ease;
}

.rw-dot-label {
    font-size: 9px;
    font-weight: 700;
    letter-spacing: .5px;
    text-transform: uppercase;
    color: rgba(255, 255, 255, .25);
    white-space: nowrap;
    text-align: center;
    transition: color .3s;
}

.rw-step-dot.active .rw-dot-circle {
    background: linear-gradient(135deg, #12a19a, #0e7e78);
    border-color: transparent;
    color: #fff;
    box-shadow: 0 0 0 5px rgba(18, 161, 154, .22), 0 4px 12px rgba(18, 161, 154, .35);
    transform: scale(1.1);
}

.rw-step-dot.active .rw-dot-label {
    color: #12a19a;
}

.rw-step-dot.done .rw-dot-circle {
    background: rgb(4 35 33);
    border-color: #12a19a;
    color: #12a19a;
}

.rw-step-dot.done .rw-dot-label {
    color: rgba(255, 255, 255, .45);
}

/* ── Step content ── */
.rw-steps-wrap {
    position: relative;
}

.rw-step {
    animation: rw-step-in .3s cubic-bezier(.22,1,.36,1);
}

.rw-step.hidden,
.hidden {
    display: none !important;
}

@keyframes rw-step-in {
    from { opacity: 0; transform: translateX(18px); }
    to   { opacity: 1; transform: translateX(0); }
}

@keyframes rw-step-back {
    from { opacity: 0; transform: translateX(-18px); }
    to   { opacity: 1; transform: translateX(0); }
}

.rw-step.animate-back {
    animation: rw-step-back .3s cubic-bezier(.22,1,.36,1);
}

/* Logo + headings */
.rw-logo {
    display: block;
    margin: 0 auto 18px;
    height: 38px;
}

.rw-title {
    font-size: 21px;
    font-weight: 800;
    color: #fff;
    margin: 0 0 6px;
    text-align: center;
    letter-spacing: -.3px;
}

.rw-sub {
    font-size: 13px;
    color: rgba(255, 255, 255, .42);
    margin: 0 0 28px;
    text-align: center;
    line-height: 1.5;
}

/* ── Form fields ── */
.rw-field {
    margin-bottom: 20px;
}

.rw-field label {
    display: block;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: .6px;
    text-transform: uppercase;
    color: rgba(255, 255, 255, .5);
    margin-bottom: 8px;
}

.rw-optional {
    font-weight: 400;
    text-transform: none;
    letter-spacing: 0;
    color: rgba(255, 255, 255, .28);
    font-size: 10px;
    margin-left: 4px;
}

.rw-field input[type="text"],
.rw-field input[type="email"],
.rw-field input[type="password"],
.rw-field textarea {
    width: 100%;
    padding: 12px 16px;
    font-size: 15px;
    color: #fff;
    background: rgba(255, 255, 255, .05);
    border: 1px solid rgba(255, 255, 255, .11);
    border-radius: 11px;
    outline: none;
    transition: border-color .2s, background .2s, box-shadow .2s;
    box-sizing: border-box;
    font-family: inherit;
    height: 40px;
}

.rw-field textarea {
    resize: none;
    overflow: hidden;
    height: 120px;
}

.rw-field input::placeholder,
.rw-field textarea::placeholder {
    color: rgba(255, 255, 255, .22);
}

.rw-field input[type="text"]:focus,
.rw-field input[type="email"]:focus,
.rw-field input[type="password"]:focus,
.rw-field textarea:focus {
    border-color: rgba(18, 161, 154, .6);
    background: rgba(18, 161, 154, .05);
    box-shadow: 0 0 0 3px rgba(18, 161, 154, .12);
}

/* GDPR row */
.rw-gdpr {
    display: flex;
    align-items: center;
    gap: 11px;
    margin-bottom: 20px;
}

.rw-gdpr input[type="checkbox"] {
    width: 17px;
    height: 17px;
    flex-shrink: 0;
    accent-color: #12a19a;
    cursor: pointer;
}

.rw-gdpr label {
    font-size: 13px;
    color: rgba(255, 255, 255, .6);
    cursor: pointer;
    line-height: 1.4;
}

.rw-gdpr label a {
    color: #12a19a;
    text-decoration: underline;
}

/* Username availability indicator */
.rw-input-status-wrap {
    position: relative;
}

.rw-input-status-wrap input {
    padding-right: 44px !important;
}

.rw-username-status {
    position: absolute;
    right: 14px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 17px;
    line-height: 1;
    transition: opacity .2s;
}

.rw-username-status.rw-status-ok::after    { content: '✓'; color: #12a19a; }
.rw-username-status.rw-status-bad::after   { content: '✗'; color: #e6007e; }
.rw-username-status.rw-status-checking::after { content: '···'; color: rgba(255,255,255,.35); font-size: 13px; }

.rw-field-hint {
    display: block;
    font-size: 11px;
    margin-top: 6px;
    color: rgba(255, 255, 255, .35);
    min-height: 13px;
    transition: color .2s;
}

.rw-username-status.rw-status-ok   ~ .rw-field-hint { color: #12a19a; }
.rw-username-status.rw-status-bad  ~ .rw-field-hint { color: #e6007e; }

/* ── Avatar picker (Step 2) ── */
.rw-avatar-section {
    display: flex;
    flex-direction: column;
    align-items: center;
    margin-bottom: 26px;
}

.rw-avatar-circle {
    width: 92px;
    height: 92px;
    border-radius: 50%;
    background: rgba(18, 161, 154, .1);
    border: 2px dashed rgba(18, 161, 154, .45);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    position: relative;
    overflow: hidden;
    transition: border-color .2s, background .2s, box-shadow .2s;
    flex-shrink: 0;
}

.rw-avatar-circle:hover {
    border-color: #12a19a;
    background: rgba(18, 161, 154, .18);
    box-shadow: 0 0 0 5px rgba(18, 161, 154, .12);
}

.rw-avatar-circle img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 50%;
}

#rw-avatar-initial {
    font-size: 38px;
    font-weight: 800;
    color: rgba(18, 161, 154, .7);
    pointer-events: none;
    user-select: none;
}

.rw-avatar-overlay {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, .5);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity .2s;
    border-radius: 50%;
    font-size: 26px;
    color: #fff;
    font-weight: 700;
}

.rw-avatar-circle:hover .rw-avatar-overlay {
    opacity: 1;
}

.rw-avatar-hint {
    margin-top: 11px;
    font-size: 12px;
    color: rgba(255, 255, 255, .38);
    text-align: center;
    margin-bottom: 2px;
}

.rw-avatar-notrequired {
    margin: 0;
    font-size: 11px;
    color: rgba(255, 255, 255, .22);
    text-align: center;
    letter-spacing: .2px;
}

.rw-avatar-remove-btn {
    margin-top: 8px;
    padding: 5px 16px;
    background: none;
    border: 1px solid rgba(230, 0, 126, .4);
    border-radius: 8px;
    color: rgba(230, 0, 126, .8);
    font-size: 12px;
    font-weight: 600;
    cursor: pointer;
    font-family: inherit;
    transition: background .15s, color .15s;
}

.rw-avatar-remove-btn:hover {
    background: rgba(230, 0, 126, .1);
    color: #e6007e;
}

/* ── Colour scheme step ── */
.rw-clr-preview {
    border-radius: 16px;
    padding: 22px 24px;
    margin-bottom: 24px;
    display: flex;
    align-items: center;
    gap: 18px;
    background-color: #1e1e28;
    color: #ffffff;
    transition: background-color .25s, color .25s;
    border: 1px solid rgba(255,255,255,.06);
}

.rw-clr-preview-avatar {
    width: 52px;
    height: 52px;
    border-radius: 50%;
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 22px;
    font-weight: 800;
    background: rgba(255,255,255,.15);
    transition: background .25s, color .25s;
}

.rw-clr-preview-name {
    font-size: 17px;
    font-weight: 700;
    margin-bottom: 4px;
}

.rw-clr-preview-sub {
    font-size: 12px;
    opacity: .55;
}

.rw-clr-pickers {
    display: flex;
    gap: 16px;
    margin-bottom: 22px;
}

.rw-clr-picker-row {
    flex: 1;
    display: flex;
    align-items: center;
    gap: 10px;
    background: rgba(255,255,255,.05);
    border: 1px solid rgba(255,255,255,.1);
    border-radius: 11px;
    padding: 10px 14px;
}

.rw-clr-picker-row label {
    font-size: 12px;
    font-weight: 600;
    color: rgba(255,255,255,.5);
    text-transform: uppercase;
    letter-spacing: .5px;
    flex-shrink: 0;
    margin: 0;
}

.rw-clr-picker-row input[type="color"] {
    width: 36px;
    height: 30px;
    border: none;
    border-radius: 7px;
    padding: 2px;
    background: none;
    cursor: pointer;
    flex-shrink: 0;
}

.rw-clr-hex {
    font-size: 12px;
    color: rgba(255,255,255,.35);
    font-family: monospace;
    letter-spacing: .5px;
}

.rw-clr-presets-label {
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: .6px;
    color: rgba(255,255,255,.4);
    margin-bottom: 10px;
}

.rw-clr-presets {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 4px;
}

.rw-clr-preset {
    width: 52px;
    height: 40px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    font-weight: 700;
    cursor: pointer;
    border: 2px solid transparent;
    transition: transform .15s, border-color .15s, box-shadow .15s;
    user-select: none;
}

.rw-clr-preset:hover {
    transform: scale(1.1);
    box-shadow: 0 4px 12px rgba(0,0,0,.35);
}

.rw-clr-preset.active {
    border-color: #12a19a;
    box-shadow: 0 0 0 3px rgba(18,161,154,.3), 0 4px 12px rgba(0,0,0,.3);
    transform: scale(1.08);
}

/* ── Option cards (Steps 4 & 5) ── */
.rw-option-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
    margin-bottom: 8px;
}

.rw-option-card {
    background: rgba(255, 255, 255, .04);
    border: 1.5px solid rgba(255, 255, 255, .09);
    border-radius: 13px;
    padding: 16px 10px 14px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 9px;
    cursor: pointer;
    transition: all .2s ease;
    text-align: center;
    user-select: none;
    position: relative;
}

.rw-option-card:hover {
    background: rgba(18, 161, 154, .09);
    border-color: rgba(18, 161, 154, .35);
    transform: translateY(-2px);
}

.rw-option-card.selected {
    background: rgba(18, 161, 154, .15);
    border-color: #12a19a;
    box-shadow: 0 0 0 3px rgba(18, 161, 154, .18), 0 6px 18px rgba(18, 161, 154, .12);
}

.rw-option-card.selected::after {
    content: '✓';
    position: absolute;
    top: 6px;
    right: 8px;
    font-size: 11px;
    color: #12a19a;
    font-weight: 700;
}

.rw-option-icon {
    font-size: 26px;
    line-height: 1;
}

.rw-option-label {
    font-size: 12px;
    font-weight: 600;
    color: rgba(255, 255, 255, .72);
    line-height: 1.3;
}

.rw-option-card.selected .rw-option-label {
    color: #fff;
}

/* ── Social links (Step 5) ── */
.rw-socials-list {
    margin-bottom: 14px;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.rw-socials-empty {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    padding: 28px 0 20px;
    color: rgba(255, 255, 255, .3);
}

.rw-socials-empty-icon {
    font-size: 28px;
    opacity: .45;
}

.rw-socials-empty-text {
    font-size: 14px;
    font-weight: 500;
}

.rw-social-row {
    display: flex;
    align-items: center;
    gap: 12px;
    background: rgba(255, 255, 255, .05);
    border: 1px solid rgba(255, 255, 255, .08);
    border-radius: 12px;
    padding: 11px 14px;
    animation: rw-step-in .2s ease;
}

.rw-social-icon {
    width: 28px;
    height: 28px;
    border-radius: 7px;
    object-fit: cover;
    flex-shrink: 0;
}

.rw-social-row-text {
    flex: 1;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.rw-social-name {
    font-size: 13px;
    font-weight: 700;
    color: rgba(255, 255, 255, .85);
}

.rw-social-link-text {
    font-size: 12px;
    color: rgba(255, 255, 255, .32);
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.rw-social-del {
    background: none;
    border: none;
    color: rgba(255, 255, 255, .25);
    cursor: pointer;
    font-size: 15px;
    padding: 4px 6px;
    transition: color .15s, background .15s;
    border-radius: 6px;
    flex-shrink: 0;
    line-height: 1;
}

.rw-social-del:hover {
    color: #e6007e;
    background: rgba(230, 0, 126, .1);
}

/* "Add a social link" trigger button */
.rw-social-add-trigger {
    width: 100%;
    padding: 12px;
    background: rgba(18, 161, 154, .08);
    border: 1px dashed rgba(18, 161, 154, .35);
    border-radius: 12px;
    color: #12a19a;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    font-family: inherit;
    transition: background .2s, border-color .2s;
    margin-bottom: 4px;
}

.rw-social-add-trigger:hover {
    background: rgba(18, 161, 154, .14);
    border-color: rgba(18, 161, 154, .6);
}

/* Add panel */
.rw-social-add-panel {
    background: rgba(255, 255, 255, .04);
    border: 1px solid rgba(255, 255, 255, .1);
    border-radius: 14px;
    padding: 18px;
    margin-bottom: 4px;
    animation: rw-step-in .2s ease;
}

.rw-social-add-panel-title {
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: .6px;
    color: rgba(255, 255, 255, .4);
    margin-bottom: 12px;
}

.rw-social-type-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 8px;
    margin-bottom: 14px;
}

.rw-social-type-btn {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 6px;
    padding: 10px 6px;
    background: rgba(255, 255, 255, .05);
    border: 1.5px solid rgba(255, 255, 255, .09);
    border-radius: 11px;
    color: rgba(255, 255, 255, .65);
    font-size: 12px;
    font-weight: 600;
    cursor: pointer;
    font-family: inherit;
    transition: border-color .15s, background .15s, color .15s;
}

.rw-social-type-btn:hover {
    border-color: rgba(18, 161, 154, .45);
    background: rgba(18, 161, 154, .08);
    color: #fff;
}

.rw-social-type-btn.active {
    border-color: #12a19a;
    background: rgba(18, 161, 154, .14);
    color: #fff;
}

.rw-social-type-icon {
    width: 28px;
    height: 28px;
    border-radius: 7px;
    object-fit: cover;
}

/* URL input row inside the panel */
.rw-social-url-row {
    border-top: 1px solid rgba(255, 255, 255, .07);
    padding-top: 14px;
    display: flex;
    flex-direction: column;
    gap: 10px;
    animation: rw-step-in .18s ease;
}

.rw-social-url-input {
    width: 100%;
    padding: 11px 14px;
    background: rgba(255, 255, 255, .06);
    border: 1px solid rgba(255, 255, 255, .12);
    border-radius: 11px;
    color: #fff;
    font-size: 14px;
    font-family: inherit;
    outline: none;
    box-sizing: border-box;
    transition: border-color .2s;
}

.rw-social-url-input::placeholder { color: rgba(255, 255, 255, .22); }
.rw-social-url-input:focus { border-color: rgba(18, 161, 154, .6); }

.rw-social-panel-actions {
    display: flex;
    gap: 8px;
    justify-content: flex-end;
}

/* Ghost (secondary) button */
.rw-btn-ghost {
    background: none;
    border: 1px solid rgba(255, 255, 255, .15);
    border-radius: 10px;
    color: rgba(255, 255, 255, .5);
    font-size: 13px;
    font-weight: 600;
    padding: 9px 18px;
    cursor: pointer;
    font-family: inherit;
    transition: background .15s, color .15s;
}

.rw-btn-ghost:hover {
    background: rgba(255, 255, 255, .07);
    color: rgba(255, 255, 255, .85);
}

.rw-social-cancel-top {
    width: 100%;
    margin-top: 10px;
}

/* ── Error message ── */
.rw-error {
    display: none;
    color: #ff7096;
    font-size: 13px;
    background: rgba(230, 0, 126, .08);
    border: 1px solid rgba(230, 0, 126, .2);
    border-radius: 10px;
    padding: 10px 15px;
    margin-top: 10px;
    line-height: 1.5;
}

/* ── Navigation buttons ── */
.rw-nav {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-top: 32px;
    gap: 12px;
}

.rw-btn {
    padding: 13px 28px;
    font-size: 15px;
    font-weight: 700;
    border-radius: 11px;
    border: none;
    cursor: pointer;
    transition: all .2s;
    letter-spacing: .2px;
    font-family: inherit;
}

.rw-btn:disabled {
    opacity: .5;
    cursor: not-allowed;
    transform: none !important;
}

.rw-btn-back {
    background: rgba(255, 255, 255, .07);
    color: rgba(255, 255, 255, .65);
    border: 1px solid rgba(255, 255, 255, .11);
}

.rw-btn-back:hover:not(:disabled) {
    background: rgba(255, 255, 255, .12);
    color: rgba(255, 255, 255, .9);
}

.rw-btn-next {
    background: linear-gradient(135deg, #12a19a, #0e7e78);
    color: #fff;
    box-shadow: 0 4px 18px rgba(18, 161, 154, .38);
    flex: 1;
    max-width: 220px;
    margin-left: auto;
}

.rw-btn-next:hover:not(:disabled) {
    box-shadow: 0 6px 24px rgba(18, 161, 154, .55);
    transform: translateY(-1px);
}

/* ── Image upload popup ── */
.rw-upload-popup-inner {
    width: 76%;
    max-width: 840px;
    height: 78%;
    background: #fff;
    border-radius: 12px;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    box-shadow: 0 20px 60px rgba(0, 0, 0, .4);
}

.rw-upload-title {
    background: #f0f0f8;
    border-bottom: 2px solid #ddd;
    padding: 18px 24px;
    font-size: 18px;
    font-weight: 700;
    color: #222;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
}

.rw-upload-close {
    position: absolute;
    right: 14px;
    top: 50%;
    transform: translateY(-50%);
    width: 36px;
    height: 36px;
    cursor: pointer;
    opacity: .7;
    transition: opacity .15s;
}

.rw-upload-close:hover { opacity: 1; }

/* Back to login link */
.rw-back-login {
    text-align: center;
    margin-top: 20px;
    font-size: 13px;
    color: rgba(255, 255, 255, .38);
}

.rw-back-login a {
    color: #12a19a;
    text-decoration: none;
    font-weight: 600;
}

.rw-back-login a:hover { text-decoration: underline; }

/* ── Mobile responsive ── */
@media (max-width: 520px) {
    .rw-card {
        padding: 24px 20px 28px;
    }

    .rw-option-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .rw-dot-label {
        font-size: 7.5px;
    }

    .rw-btn-next {
        max-width: none;
    }
}

@media (max-width: 360px) {
    .rw-option-grid {
        grid-template-columns: repeat(1, 1fr);
    }
}
