/* Timika — Recruitment Auth Portal (login/register flow) */

body.timika-auth-page.rap-page {
    padding: 16px;
}

.rap-brand .auth-brand-tagline {
    margin-bottom: 28px;
}

.rap-brand-stats {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
    margin-bottom: 28px;
}

.rap-brand-stat {
    background: rgba(255, 255, 255, 0.12);
    border: 1px solid rgba(255, 255, 255, 0.18);
    border-radius: 14px;
    padding: 12px 14px;
    backdrop-filter: blur(8px);
}

.rap-brand-stat .val {
    display: block;
    font-size: 1.1rem;
    font-weight: 800;
    line-height: 1.2;
}

.rap-brand-stat .lbl {
    display: block;
    font-size: 0.72rem;
    opacity: 0.82;
    margin-top: 4px;
}

.rap-panel .auth-panel-header {
    padding-bottom: 4px;
}

.rap-segment {
    display: flex;
    gap: 6px;
    padding: 5px;
    background: #f1f5f9;
    border-radius: 14px;
    margin-bottom: 18px;
    border: 1px solid #e2e8f0;
}

.rap-segment-btn {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 11px 12px;
    border: none;
    border-radius: 10px;
    background: transparent;
    color: #64748b;
    font-size: 0.82rem;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.25s cubic-bezier(0.22, 1, 0.36, 1);
    font-family: inherit;
}

.rap-segment-btn i {
    font-size: 0.95rem;
    opacity: 0.85;
}

.rap-segment-btn.active {
    background: #fff;
    color: var(--auth-primary, #2196F3);
    box-shadow: 0 2px 8px rgba(var(--auth-primary-rgb, 33, 150, 243), 0.15), 0 1px 2px rgba(15, 23, 42, 0.06);
}

.rap-segment-btn:not(.active):hover {
    color: #334155;
    background: rgba(255, 255, 255, 0.6);
}

.rap-panel-body {
    animation: rapFadeIn 0.35s ease;
    min-width: 0;
    overflow-x: hidden;
}

.rap-track-panel.has-result-hired .rap-hero,
.rap-track-panel.has-result-hired .rap-track-form,
.rap-track-panel.has-result-hired .rap-input-hint,
.rap-track-panel.has-result-hired #rapTrackEmpty {
    display: none !important;
}

.rap-track-panel.has-result-hired .rap-result {
    margin-top: 0;
}

@keyframes rapFadeIn {
    from { opacity: 0; transform: translateY(8px); }
    to { opacity: 1; transform: translateY(0); }
}

.rap-hero {
    display: flex;
    align-items: flex-start;
    gap: 14px;
    padding: 16px 18px;
    margin-bottom: 20px;
    border-radius: 16px;
    background: linear-gradient(135deg, rgba(var(--auth-primary-rgb, 33, 150, 243), 0.08), rgba(99, 102, 241, 0.06));
    border: 1px solid rgba(var(--auth-primary-rgb, 33, 150, 243), 0.14);
}

.rap-hero-icon {
    width: 44px;
    height: 44px;
    border-radius: 12px;
    background: var(--auth-primary, #2196F3);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    font-size: 1.1rem;
    box-shadow: 0 6px 16px rgba(var(--auth-primary-rgb, 33, 150, 243), 0.35);
}

.rap-hero-text h3 {
    margin: 0 0 4px;
    font-size: 0.95rem;
    font-weight: 800;
    color: #0f172a;
}

.rap-hero-text p {
    margin: 0;
    font-size: 0.8rem;
    color: #64748b;
    line-height: 1.55;
}

.rap-track-form .input-wrapper {
    margin-bottom: 4px;
}

.rap-track-form .tracking-input {
    direction: ltr;
    text-align: center;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    font-weight: 700;
    font-size: 0.95rem;
}

.rap-input-hint {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 0.75rem;
    color: #94a3b8;
    margin: 8px 0 16px;
}

.rap-input-hint code {
    background: #f1f5f9;
    padding: 2px 8px;
    border-radius: 6px;
    font-size: 0.72rem;
    color: #475569;
    direction: ltr;
}

.rap-submit {
    position: relative;
    overflow: hidden;
}

.rap-submit .loading {
    display: none;
    width: 22px;
    height: 22px;
    border: 2.5px solid rgba(255, 255, 255, 0.35);
    border-top-color: #fff;
    border-radius: 50%;
    animation: rapSpin 0.7s linear infinite;
    margin: 0 auto;
}

.rap-submit.is-loading .btn-text { opacity: 0; }
.rap-submit.is-loading .loading { display: block; position: absolute; inset: 0; margin: auto; }

@keyframes rapSpin {
    to { transform: rotate(360deg); }
}

.rap-empty-state {
    text-align: center;
    padding: 28px 16px;
    color: #94a3b8;
}

.rap-empty-state i {
    font-size: 2.2rem;
    margin-bottom: 12px;
    opacity: 0.45;
    display: block;
}

.rap-empty-state p {
    margin: 0;
    font-size: 0.85rem;
    line-height: 1.6;
}

/* ── نتیجه پیگیری ── */
.rap-result {
    display: none;
    margin-top: 20px;
    animation: rapFadeIn 0.4s ease;
    min-width: 0;
}

.rap-result.is-visible {
    display: block;
}

.rap-result.is-register-mode {
    margin-top: 0;
}

.rap-result-card {
    border-radius: 18px;
    border: 1px solid #e2e8f0;
    overflow: hidden;
    background: #fff;
    box-shadow: 0 4px 20px rgba(15, 23, 42, 0.06);
    min-width: 0;
    max-width: 100%;
}

.rap-result-card.has-inline-register .rap-result-body {
    padding: 14px 16px 16px;
}

.rap-result-card.is-error {
    border-color: #fecaca;
    background: linear-gradient(180deg, #fff 0%, #fef2f2 100%);
}

.rap-result-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 10px;
    padding: 14px 16px;
    background: linear-gradient(135deg, #f8fafc, #fff);
    border-bottom: 1px solid #f1f5f9;
    flex-wrap: wrap;
    min-width: 0;
}

.rap-result-head h4 {
    margin: 0;
    font-size: 0.95rem;
    font-weight: 800;
    color: #0f172a;
}

.rap-status-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 12px;
    border-radius: 999px;
    font-size: 0.75rem;
    font-weight: 700;
    white-space: nowrap;
}

.rap-status-badge::before {
    content: '';
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: currentColor;
    opacity: 0.85;
}

.rap-status-badge--pending { background: #fef3c7; color: #b45309; }
.rap-status-badge--in_review { background: #dbeafe; color: #1d4ed8; }
.rap-status-badge--hired { background: #d1fae5; color: #047857; }
.rap-status-badge--rejected { background: #fee2e2; color: #b91c1c; }
.rap-status-badge--withdrawn { background: #f1f5f9; color: #64748b; }
.rap-status-badge--error { background: #fee2e2; color: #b91c1c; }

.rap-result-body {
    padding: 18px;
    min-width: 0;
    overflow-x: hidden;
}

.rap-info-grid {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    gap: 12px;
    margin-bottom: 18px;
}

.rap-info-item {
    padding: 12px 14px;
    background: #f8fafc;
    border-radius: 12px;
    border: 1px solid #f1f5f9;
    min-width: 0;
}

.rap-info-item .value {
    display: block;
    font-size: 0.88rem;
    font-weight: 700;
    color: #1e293b;
    line-height: 1.4;
    word-break: break-word;
    overflow-wrap: anywhere;
}

.rap-info-item.full {
    grid-column: 1 / -1;
}

.rap-info-item .label {
    display: block;
    font-size: 0.72rem;
    color: #94a3b8;
    margin-bottom: 4px;
    font-weight: 600;
}

.rap-code-display {
    display: flex;
    align-items: stretch;
    justify-content: center;
    gap: 8px;
    margin: 12px 0 0;
    flex-wrap: wrap;
    width: 100%;
    min-width: 0;
}

.rap-code-box {
    font-family: ui-monospace, 'Cascadia Code', monospace;
    font-size: 0.9rem;
    font-weight: 800;
    letter-spacing: 0.06em;
    direction: ltr;
    background: #fff;
    padding: 10px 14px;
    border-radius: 12px;
    border: 2px dashed #34d399;
    color: #065f46;
    flex: 1 1 auto;
    min-width: 0;
    max-width: 100%;
    word-break: break-all;
    overflow-wrap: anywhere;
    text-align: center;
    line-height: 1.4;
}

.rap-progress-wrap {
    margin-bottom: 18px;
}

.rap-progress-label {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 8px;
    font-size: 0.8rem;
    color: #64748b;
}

.rap-progress-label strong {
    color: #0f172a;
    font-weight: 800;
}

.rap-progress-bar {
    height: 10px;
    background: #e2e8f0;
    border-radius: 999px;
    overflow: hidden;
}

.rap-progress-fill {
    height: 100%;
    border-radius: 999px;
    background: linear-gradient(90deg, var(--auth-primary, #2196F3), #818cf8);
    transition: width 0.6s cubic-bezier(0.22, 1, 0.36, 1);
    min-width: 4%;
}

.rap-success-box {
    margin-top: 16px;
    padding: 18px;
    border-radius: 14px;
    background: linear-gradient(135deg, #ecfdf5, #d1fae5);
    border: 1px solid #6ee7b7;
    text-align: center;
}

.rap-success-box .congrats {
    font-size: 0.95rem;
    font-weight: 800;
    color: #047857;
    margin-bottom: 10px;
}

.rap-copy-btn {
    width: 44px;
    height: 44px;
    border: none;
    border-radius: 12px;
    background: #fff;
    color: #047857;
    cursor: pointer;
    transition: all 0.2s ease;
    border: 1px solid #a7f3d0;
    flex-shrink: 0;
}

.rap-copy-btn:hover {
    background: #ecfdf5;
    transform: scale(1.05);
}

.rap-copy-btn.is-copied {
    background: #047857;
    color: #fff;
    border-color: #047857;
}

.rap-register-cta {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    width: 100%;
    margin-top: 12px;
    text-decoration: none;
}

/* ── تایم‌لاین ── */
.rap-timeline-collapse {
    margin-top: 14px;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    overflow: hidden;
    background: #fafbfc;
}

.rap-timeline-collapse summary {
    list-style: none;
    cursor: pointer;
    padding: 12px 14px;
    margin: 0;
    user-select: none;
}

.rap-timeline-collapse summary::-webkit-details-marker {
    display: none;
}

.rap-timeline-collapse summary.rap-timeline-title {
    margin: 0;
    justify-content: space-between;
}

.rap-timeline-collapse summary.rap-timeline-title::after {
    content: '\f078';
    font-family: 'Font Awesome 5 Free';
    font-weight: 900;
    font-size: 0.7rem;
    color: #94a3b8;
    transition: transform 0.2s;
}

.rap-timeline-collapse[open] summary.rap-timeline-title::after {
    transform: rotate(180deg);
}

.rap-timeline-count {
    font-size: 0.72rem;
    background: #e2e8f0;
    color: #475569;
    padding: 2px 8px;
    border-radius: 999px;
    margin-right: auto;
    margin-left: 8px;
}

.rap-timeline-collapse .rap-timeline {
    padding: 0 14px 14px;
}

.rap-timeline-title {
    font-size: 0.82rem;
    font-weight: 800;
    color: #334155;
    margin: 0 0 14px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.rap-timeline {
    list-style: none;
    margin: 0;
    padding: 0;
    position: relative;
}

.rap-timeline::before {
    content: '';
    position: absolute;
    top: 8px;
    bottom: 8px;
    right: 11px;
    width: 2px;
    background: linear-gradient(180deg, var(--auth-primary, #2196F3), #e2e8f0);
    border-radius: 2px;
}

.rap-timeline li {
    position: relative;
    padding: 0 36px 16px 0;
}

.rap-timeline li:last-child {
    padding-bottom: 0;
}

.rap-timeline-dot {
    position: absolute;
    right: 4px;
    top: 4px;
    width: 16px;
    height: 16px;
    border-radius: 50%;
    background: #fff;
    border: 3px solid var(--auth-primary, #2196F3);
    z-index: 1;
}

.rap-timeline li.is-approved .rap-timeline-dot { border-color: #10b981; background: #ecfdf5; }
.rap-timeline li.is-rejected .rap-timeline-dot { border-color: #ef4444; background: #fef2f2; }
.rap-timeline li.is-hired .rap-timeline-dot { border-color: #059669; background: #d1fae5; }

.rap-timeline-card {
    background: #f8fafc;
    border: 1px solid #f1f5f9;
    border-radius: 12px;
    padding: 12px 14px;
}

.rap-timeline-card strong {
    display: block;
    font-size: 0.85rem;
    color: #0f172a;
    margin-bottom: 4px;
}

.rap-timeline-card .action {
    font-size: 0.78rem;
    color: #64748b;
}

.rap-timeline-card time {
    display: block;
    font-size: 0.72rem;
    color: #94a3b8;
    margin-top: 6px;
}

/* ── ثبت‌نام کارمند ── */
.rap-hire-panel {
    display: none;
}

.rap-hire-panel.active {
    display: block;
    animation: rapFadeIn 0.35s ease;
}

.rap-hire-cards {
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.rap-hire-card {
    display: flex;
    gap: 14px;
    padding: 18px;
    border-radius: 16px;
    border: 1px solid #e2e8f0;
    background: #fff;
    transition: all 0.25s ease;
}

.rap-hire-card:hover {
    border-color: rgba(var(--auth-primary-rgb, 33, 150, 243), 0.25);
    box-shadow: 0 8px 24px rgba(var(--auth-primary-rgb, 33, 150, 243), 0.1);
    transform: translateY(-2px);
}

.rap-hire-card-icon {
    width: 48px;
    height: 48px;
    border-radius: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    font-size: 1.2rem;
}

.rap-hire-card-icon.green {
    background: linear-gradient(135deg, #ecfdf5, #a7f3d0);
    color: #047857;
}

.rap-hire-card-icon.blue {
    background: linear-gradient(135deg, #eff6ff, #bfdbfe);
    color: #1d4ed8;
}

.rap-hire-card-body h4 {
    margin: 0 0 6px;
    font-size: 0.92rem;
    font-weight: 800;
    color: #0f172a;
}

.rap-hire-card-body p {
    margin: 0 0 14px;
    font-size: 0.8rem;
    color: #64748b;
    line-height: 1.55;
}

.rap-hire-card .submit-btn {
    width: auto;
    padding: 10px 20px;
    font-size: 0.85rem;
}

.rap-hire-card .submit-btn.secondary {
    background: #f1f5f9;
    color: #334155;
    box-shadow: none;
}

.rap-hire-card .submit-btn.secondary:hover:not(:disabled) {
    background: #e2e8f0;
    box-shadow: 0 4px 12px rgba(15, 23, 42, 0.08);
}

.rap-disabled-notice {
    text-align: center;
    padding: 32px 20px;
    border-radius: 16px;
    background: linear-gradient(135deg, #fffbeb, #fef3c7);
    border: 1px solid #fcd34d;
}

.rap-disabled-notice i {
    font-size: 2rem;
    color: #d97706;
    margin-bottom: 12px;
}

.rap-disabled-notice p {
    margin: 0;
    color: #92400e;
    font-size: 0.9rem;
    font-weight: 600;
}

.rap-back-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    width: 100%;
    padding: 12px;
    color: #64748b;
    font-size: 0.85rem;
    font-weight: 700;
    text-decoration: none;
    border-radius: 12px;
    transition: all 0.2s ease;
}

.rap-back-link:hover {
    color: var(--auth-primary, #2196F3);
    background: rgba(var(--auth-primary-rgb, 33, 150, 243), 0.06);
}

.rap-back-link i {
    font-size: 0.8rem;
}

.rap-track-panel {
    display: none;
}

.rap-track-panel.active {
    display: block;
}

@media (max-width: 640px) {
    .rap-info-grid {
        grid-template-columns: 1fr;
    }

    .rap-brand-stats {
        grid-template-columns: 1fr;
    }

    .rap-segment-btn {
        font-size: 0.75rem;
        padding: 10px 8px;
    }

    .rap-segment-btn span.rap-seg-label {
        display: none;
    }

    .rap-result-head {
        flex-direction: column;
        align-items: flex-start;
    }

    .rap-status-badge {
        align-self: flex-start;
    }
}

@media (prefers-reduced-motion: reduce) {
    .rap-panel-body,
    .rap-result,
    .rap-hire-panel.active {
        animation: none;
    }

    .rap-progress-fill {
        transition: none;
    }

    .rap-hired-confetti {
        display: none;
    }
}

/* ── نتیجه پیشرفته + ثبت‌نام inline ── */
.rap-result-card.is-hired {
    border-color: #6ee7b7;
    box-shadow: 0 8px 32px rgba(5, 150, 105, 0.12);
}

.rap-result-head-main {
    display: flex;
    align-items: center;
    gap: 12px;
    flex: 1;
    min-width: 0;
}

.rap-result-avatar {
    width: 44px;
    height: 44px;
    border-radius: 12px;
    background: linear-gradient(135deg, var(--auth-primary, #2196F3), #818cf8);
    color: #fff;
    font-weight: 800;
    font-size: 1.1rem;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.rap-result-head h4 {
    margin: 0 0 2px;
}

.rap-result-track {
    font-size: 0.72rem;
    color: #94a3b8;
    font-family: ui-monospace, monospace;
    direction: ltr;
    display: inline-flex;
    align-items: center;
    gap: 4px;
}

.rap-already-box {
    display: flex;
    gap: 14px;
    align-items: flex-start;
    padding: 18px;
    margin: 16px 0;
    border-radius: 14px;
    background: linear-gradient(135deg, #eff6ff, #dbeafe);
    border: 1px solid #93c5fd;
}

.rap-already-box > i {
    font-size: 1.6rem;
    color: #2563eb;
    margin-top: 2px;
}

.rap-already-box strong {
    display: block;
    font-size: 0.92rem;
    color: #1e3a8a;
    margin-bottom: 4px;
}

.rap-already-box p {
    margin: 0 0 12px;
    font-size: 0.82rem;
    color: #475569;
}

.rap-result-head-text {
    min-width: 0;
    flex: 1;
}

.rap-result-head-text h4 {
    word-break: break-word;
    overflow-wrap: anywhere;
}

.rap-result-position {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.82rem;
    font-weight: 700;
    color: #475569;
    padding: 10px 12px;
    background: #f8fafc;
    border-radius: 10px;
    margin-bottom: 12px;
    min-width: 0;
}

.rap-result-position i {
    color: var(--auth-primary, #2196F3);
    flex-shrink: 0;
}

.rap-hired-panel {
    margin-top: 12px;
    min-width: 0;
}

.rap-hired-celebration {
    position: relative;
    border-radius: 14px;
    background: linear-gradient(135deg, #ecfdf5 0%, #d1fae5 100%);
    border: 1px solid #6ee7b7;
    overflow: hidden;
    margin-bottom: 14px;
    padding: 14px;
    min-width: 0;
}

.rap-hired-celebration--compact {
    text-align: right;
}

.rap-hired-celebration-inner {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    margin-bottom: 0;
}

.rap-hired-celebration-text {
    flex: 1;
    min-width: 0;
}

.rap-hired-celebration-text h4 {
    margin: 0 0 4px;
    font-size: 0.92rem;
    font-weight: 800;
    color: #065f46;
}

.rap-hired-celebration-text > p {
    margin: 0;
    font-size: 0.78rem;
    color: #047857;
    line-height: 1.55;
}

.rap-hired-confetti {
    position: absolute;
    inset: 0;
    background-image:
        radial-gradient(circle at 20% 30%, rgba(255,255,255,0.4) 2px, transparent 2px),
        radial-gradient(circle at 80% 20%, rgba(16,185,129,0.3) 3px, transparent 3px);
    animation: rapConfetti 4s ease-in-out infinite;
    pointer-events: none;
}

@keyframes rapConfetti {
    0%, 100% { opacity: 0.6; transform: translateY(0); }
    50% { opacity: 1; transform: translateY(-4px); }
}

.rap-hired-trophy {
    width: 44px;
    height: 44px;
    border-radius: 12px;
    background: linear-gradient(135deg, #059669, #10b981);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    flex-shrink: 0;
    box-shadow: 0 4px 14px rgba(5, 150, 105, 0.3);
}

.rap-hired-date {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    font-size: 0.72rem;
    color: #059669;
    margin-top: 6px;
}

.rap-hired-celebration .rap-code-display {
    margin-top: 12px;
}

.rap-reg-section {
    background: #fff;
    border: 1px solid #e2e8f0;
    border-radius: 14px;
    padding: 14px;
    margin-bottom: 12px;
    min-width: 0;
}

.rap-reg-section-head {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 12px;
    padding-bottom: 10px;
    border-bottom: 1px solid #f1f5f9;
    min-width: 0;
}

.rap-reg-section-title {
    min-width: 0;
    flex: 1;
}

.rap-reg-section-head > div {
    min-width: 0;
    flex: 1;
}

.rap-reg-step-num {
    width: 28px;
    height: 28px;
    min-width: 28px;
    min-height: 28px;
    border-radius: 8px;
    background: var(--auth-primary, #2196F3);
    color: #fff;
    font-size: 0.8rem;
    font-weight: 800;
    line-height: 1;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    padding: 0;
    box-sizing: border-box;
    text-align: center;
}

.rap-reg-section-head strong {
    display: block;
    font-size: 0.85rem;
    color: #0f172a;
    margin-bottom: 2px;
}

.rap-reg-section-head .rap-reg-desc {
    display: block;
    font-size: 0.72rem;
    color: #94a3b8;
    line-height: 1.45;
}

/* لیست تک‌ستونه — بدون overflow */
.rap-prefill-list,
.rap-account-stack {
    display: flex;
    flex-direction: column;
    gap: 10px;
    min-width: 0;
}

.rap-prefill-item,
.rap-form-field {
    min-width: 0;
}

.rap-prefill-label,
.rap-form-field label {
    display: block;
    font-size: 0.72rem;
    font-weight: 700;
    color: #64748b;
    margin-bottom: 5px;
}

.rap-prefill-val {
    display: flex;
    align-items: flex-start;
    gap: 8px;
    background: #f0fdf4;
    border: 1px solid #bbf7d0;
    border-radius: 10px;
    padding: 10px 12px;
    min-width: 0;
}

.rap-prefill-val.is-info {
    background: #f8fafc;
    border-color: #e2e8f0;
}

.rap-prefill-val.is-info i {
    color: #6366f1;
}

.rap-prefill-val i {
    color: #16a34a;
    font-size: 0.72rem;
    flex-shrink: 0;
    margin-top: 3px;
}

.rap-prefill-text {
    flex: 1;
    min-width: 0;
    font-size: 0.85rem;
    font-weight: 600;
    color: #166534;
    line-height: 1.5;
    word-break: break-word;
    overflow-wrap: anywhere;
}

.rap-prefill-val.is-info .rap-prefill-text {
    color: #334155;
}

.rap-input-wrap {
    display: flex;
    align-items: center;
    gap: 10px;
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 10px;
    padding: 0 12px;
    min-height: 42px;
    min-width: 0;
    transition: border-color 0.2s, box-shadow 0.2s;
}

.rap-input-wrap:focus-within {
    border-color: var(--auth-primary, #2196F3);
    box-shadow: 0 0 0 3px rgba(var(--auth-primary-rgb, 33, 150, 243), 0.12);
}

.rap-input-wrap i {
    color: #94a3b8;
    font-size: 0.82rem;
    flex-shrink: 0;
}

.rap-input-wrap input {
    border: none;
    background: transparent;
    flex: 1;
    min-width: 0;
    width: 100%;
    font-size: 0.85rem;
    padding: 10px 0;
    outline: none;
    font-family: inherit;
    color: #1e293b;
}

.rap-input-wrap--password {
    position: relative;
    padding-left: 38px;
}

.rap-input-wrap--password input {
    padding-left: 0;
}

.rap-password-toggle {
    position: absolute;
    left: 6px;
    top: 50%;
    transform: translateY(-50%);
    width: 30px;
    height: 30px;
    border: none;
    border-radius: 8px;
    background: transparent;
    color: #94a3b8;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0;
    font-size: 0.9rem;
    transition: color 0.2s, background 0.2s;
    flex-shrink: 0;
}

.rap-password-toggle:hover {
    color: var(--auth-primary, #2196F3);
    background: rgba(var(--auth-primary-rgb, 33, 150, 243), 0.08);
}

.rap-password-toggle i {
    pointer-events: none;
}

.rap-portal-register {
    min-width: 0;
}

.rap-field-hint {
    margin: 6px 0 0;
    font-size: 0.72rem;
    color: #6366f1;
    display: flex;
    align-items: center;
    gap: 5px;
}

.rap-pw-strength {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-top: 8px;
}

.rap-pw-strength .rap-pw-bar {
    flex: 1;
    height: 4px;
    background: #e2e8f0;
    border-radius: 999px;
    position: relative;
    overflow: hidden;
}

.rap-pw-strength .rap-pw-bar::after {
    content: '';
    position: absolute;
    right: 0;
    top: 0;
    height: 100%;
    width: 0;
    border-radius: 999px;
    transition: width 0.3s, background 0.3s;
}

.rap-pw-strength.is-weak .rap-pw-bar::after { width: 33%; background: #ef4444; }
.rap-pw-strength.is-medium .rap-pw-bar::after { width: 66%; background: #f59e0b; }
.rap-pw-strength.is-strong .rap-pw-bar::after { width: 100%; background: #10b981; }

.rap-pw-strength .rap-pw-label {
    font-size: 0.7rem;
    font-weight: 700;
    color: #64748b;
    min-width: 36px;
}

.rap-pw-strength.is-weak .rap-pw-label { color: #ef4444; }
.rap-pw-strength.is-medium .rap-pw-label { color: #f59e0b; }
.rap-pw-strength.is-strong .rap-pw-label { color: #10b981; }

.rap-otp-row {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

.rap-otp-input {
    flex: 1;
    min-width: 140px;
    padding: 12px 16px;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    font-size: 1rem;
    font-weight: 700;
    letter-spacing: 0.2em;
    text-align: center;
    font-family: inherit;
}

.rap-otp-send {
    padding: 12px 18px;
    border: none;
    border-radius: 12px;
    background: linear-gradient(135deg, #059669, #10b981);
    color: #fff;
    font-weight: 700;
    font-size: 0.85rem;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-family: inherit;
    white-space: nowrap;
}

.rap-otp-send:hover { filter: brightness(1.05); }
.rap-otp-send:disabled { opacity: 0.6; cursor: not-allowed; }

.rap-otp-msg {
    margin: 10px 0 0;
    font-size: 0.78rem;
    color: #64748b;
}

.rap-otp-msg.is-ok { color: #059669; }
.rap-otp-msg.is-err { color: #dc2626; }

.rap-register-submit {
    width: 100%;
    margin-top: 6px;
    position: relative;
    overflow: hidden;
    background: linear-gradient(135deg, #059669, #10b981) !important;
    box-shadow: 0 8px 24px rgba(5, 150, 105, 0.35) !important;
}

.rap-register-submit .loading {
    display: none;
    width: 22px;
    height: 22px;
    border: 2.5px solid rgba(255,255,255,0.35);
    border-top-color: #fff;
    border-radius: 50%;
    animation: rapSpin 0.7s linear infinite;
    margin: 0 auto;
}

.rap-register-submit.is-loading .btn-text { opacity: 0; }
.rap-register-submit.is-loading .loading {
    display: block;
    position: absolute;
    inset: 0;
    margin: auto;
}

.rap-page .auth-panel {
    min-width: 0;
    overflow: hidden;
}

.rap-page .auth-panel-body {
    overflow-x: hidden;
}

/* SweetAlert compact */
.swal2-popup.rap-swal-compact-popup,
.swal2-title.rap-swal-compact {
    font-size: 0.95rem !important;
    font-weight: 700 !important;
}

.swal2-html-container.rap-swal-compact-text {
    font-size: 0.82rem !important;
}

.swal2-toast .swal2-title {
    font-size: 0.85rem !important;
    font-weight: 600 !important;
}
