/* Register Page — Centered Card OTP Design */

body.auth-body {
    background: var(--surface, #faf4e8);
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 100vh;
    padding: 1rem;
    font-family: var(--font-body, 'Outfit', sans-serif);
}

.register-page {
    width: 100%;
    max-width: 420px;
}

.register-card {
    background: white;
    border-radius: var(--radius-md, 10px);
    padding: 2.5rem 2rem;
    box-shadow: 0 2px 8px rgba(24, 86, 108, 0.08);
    position: relative;
}

/* Back button */
.register-back-btn {
    position: absolute;
    top: 1.5rem;
    left: 1.5rem;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-muted, #745d4a);
    text-decoration: none;
    border-radius: 8px;
    transition: all 0.2s;
}

.register-back-btn:hover {
    color: var(--primary, #18566c);
    background: var(--primary-soft, #eef4f6);
}

/* Header */
.register-header {
    text-align: center;
    margin-bottom: 2rem;
}

.register-logo-link {
    display: inline-block;
    margin-bottom: 1.5rem;
}

.register-logo {
    width: 80px;
    height: 80px;
    border-radius: var(--radius-md, 10px);
    object-fit: cover;
    display: block;
}

.register-title {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text-dark, #303030);
    margin-bottom: 0.5rem;
}

.register-subtitle {
    font-size: 0.9rem;
    color: var(--text-muted, #745d4a);
}

/* Alert */
.register-alert {
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
    padding: 0.9rem 1rem;
    background: #fef2f2;
    border: 1px solid #fecaca;
    border-radius: 8px;
    color: #b91c1c;
    font-size: 0.9rem;
    margin-bottom: 1.5rem;
    line-height: 1.5;
}

.register-alert--error {
    color: #b91c1c;
}

/* Steps */
.register-step {
    display: none;
}

.register-step.active {
    display: block;
}

/* Fields */
.register-field {
    margin-bottom: 1rem;
}

.register-label {
    display: block;
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--text-dark, #303030);
    margin-bottom: 0.5rem;
}

.register-input {
    width: 100%;
    padding: 0.75rem 1rem;
    font-size: 1rem;
    border: 1px solid var(--border-color, #ece2cc);
    border-radius: 8px;
    font-family: inherit;
    color: var(--text-dark, #303030);
    outline: none;
    transition: border-color 0.2s;
}

.register-input:focus {
    border-color: var(--primary, #18566c);
    box-shadow: 0 0 0 3px rgba(24, 86, 108, 0.1);
}

.register-input-wrap {
    position: relative;
    display: flex;
    align-items: center;
}

.register-input-wrap .register-input {
    padding-right: 2.75rem;
}

.register-eye-btn {
    position: absolute;
    right: 0.75rem;
    background: none;
    border: none;
    cursor: pointer;
    color: var(--text-muted, #745d4a);
    display: flex;
    align-items: center;
    padding: 0;
}

.register-eye-btn:hover {
    color: var(--primary, #18566c);
}

.register-eye-icon {
    width: 18px;
    height: 18px;
    pointer-events: none;
}

/* Phone input */
.register-phone-wrap {
    display: flex;
    gap: 0.5rem;
}

.register-phone-prefix {
    display: flex;
    align-items: center;
    padding: 0 1rem;
    background: var(--primary-soft, #eef4f6);
    border: 1px solid var(--border-color, #ece2cc);
    border-radius: 8px;
    font-weight: 600;
    color: var(--text-dark, #303030);
    min-width: 70px;
    font-size: 0.95rem;
}

.register-phone-input {
    flex: 1;
    padding: 0.75rem 1rem;
    font-size: 1rem;
    border: 1px solid var(--border-color, #ece2cc);
    border-radius: 8px;
    font-family: inherit;
    color: var(--text-dark, #303030);
    outline: none;
    transition: border-color 0.2s;
}

.register-phone-input:focus {
    border-color: var(--primary, #18566c);
    box-shadow: 0 0 0 3px rgba(24, 86, 108, 0.1);
}

/* Tabs */
.register-tabs {
    display: flex;
    border-bottom: 2px solid var(--border-color, #ece2cc);
    margin-bottom: 1.5rem;
}

.register-tab {
    flex: 1;
    padding: 1rem 0.5rem;
    text-align: center;
    font-size: 0.95rem;
    font-weight: 600;
    color: var(--text-muted, #745d4a);
    cursor: pointer;
    transition: all 0.2s;
    position: relative;
    border: none;
    background: none;
}

.register-tab:hover {
    color: var(--primary, #18566c);
}

.register-tab.active {
    color: var(--primary, #18566c);
}

.register-tab.active::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 100%;
    height: 2px;
    background: var(--primary, #18566c);
}

/* Field error */
.register-field-error {
    color: #ef4444;
    font-size: 0.85rem;
    margin-top: 0.5rem;
    display: none;
}

.register-field-error.show {
    display: block;
}

/* Checkbox */
.register-checkbox {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.85rem;
    color: var(--text-muted, #745d4a);
    margin: 1.25rem 0;
    cursor: pointer;
}

.register-checkbox input[type="checkbox"] {
    width: 16px;
    height: 16px;
    cursor: pointer;
}

.register-checkbox a {
    color: var(--primary, #18566c);
    text-decoration: underline;
}

/* OTP Info */
.register-otp-info {
    text-align: center;
    font-size: 0.9rem;
    color: var(--text-muted, #745d4a);
    margin-bottom: 0.75rem;
    line-height: 1.5;
}

.register-otp-info strong {
    display: block;
    color: var(--text-dark, #303030);
    font-weight: 600;
    margin-top: 0.25rem;
}

/* WhatsApp button */
.register-whatsapp {
    display: inline-block;
    width: 100%;
    padding: 0.6rem;
    background: #25d366;
    color: white;
    text-align: center;
    text-decoration: none;
    border-radius: 8px;
    font-size: 0.9rem;
    font-weight: 500;
    margin-bottom: 1.25rem;
    transition: background 0.2s;
}

.register-whatsapp:hover {
    background: #1a9d50;
}

/* OTP boxes */
.register-otp-wrap {
    position: relative;
    margin: 1.5rem 0;
}

.register-otp-boxes {
    display: flex;
    gap: 0.75rem;
    justify-content: center;
}

.register-otp-digit {
    width: 50px;
    height: 50px;
    font-size: 1.5rem;
    font-weight: 700;
    text-align: center;
    line-height: 50px;
    border: 1px solid var(--border-color, #ece2cc);
    border-radius: 8px;
    font-family: 'Courier New', monospace;
    transition: border-color 0.2s, box-shadow 0.2s;
    user-select: none;
    pointer-events: none;
}

.register-otp-digit.active {
    border-color: var(--primary, #18566c);
    box-shadow: 0 0 0 3px rgba(24, 86, 108, 0.1);
}

.register-otp-real {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    cursor: pointer;
    z-index: 2;
    font-size: 16px;
}

/* Buttons */
.register-btn {
    width: 100%;
    padding: 0.85rem;
    background: var(--primary, #18566c);
    color: white;
    border: none;
    border-radius: 8px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.2s;
    margin-top: 0.5rem;
}

.register-btn:hover:not(:disabled) {
    background: var(--primary-dark, #0f3a4a);
}

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

.register-btn-row {
    display: flex;
    gap: 0.75rem;
    margin-top: 1.25rem;
}

.register-btn-secondary {
    flex: 1;
    padding: 0.85rem;
    background: transparent;
    color: var(--primary, #18566c);
    border: 1px solid var(--border-color, #ece2cc);
    border-radius: 8px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
}

.register-btn-secondary:hover {
    background: var(--primary-soft, #eef4f6);
}

/* Loading */
.register-loading {
    text-align: center;
    font-size: 0.9rem;
    color: var(--text-muted, #745d4a);
    margin-top: 1rem;
}

/* Footer */
.register-footer {
    text-align: center;
    font-size: 0.9rem;
    color: var(--text-muted, #745d4a);
    margin-top: 1.5rem;
}

.register-footer a {
    color: var(--primary, #18566c);
    text-decoration: none;
    font-weight: 600;
}

.register-footer a:hover {
    text-decoration: underline;
}

/* Mobile */
@media (max-width: 600px) {
    .register-card {
        padding: 2rem 1.5rem;
        border-radius: 8px;
    }

    .register-title {
        font-size: 1.3rem;
    }

    .register-logo {
        width: 70px;
        height: 70px;
    }

    .register-otp-digit {
        width: 45px;
        height: 45px;
        line-height: 45px;
        font-size: 1.3rem;
    }
}