:root {
    --ar-primary: #c7382b;
    --ar-primary-hover: #a92a1f;
    --ar-primary-soft: #fdf2f0;
    --ar-dark: #0f141d;
    --ar-dark-surface: #161d28;
    --ar-text-main: #0f172a;
    --ar-text-sub: #64748b;
    --ar-border: #e2e8f0;
    --ar-body-bg: #f8fafc;
}

* {
    box-sizing: border-box;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    -webkit-tap-highlight-color: transparent;
}

[x-cloak] {
    display: none !important;
}

body {
    background-color: var(--ar-body-bg);
    background-image:
        radial-gradient(at 15% 15%, rgba(199, 56, 43, 0.03) 0px, transparent 50%),
        radial-gradient(at 85% 85%, rgba(15, 20, 29, 0.03) 0px, transparent 50%);
    color: var(--ar-text-main);
    min-height: 100vh;
    min-height: 100dvh;
    display: flex;
    flex-direction: column;
    padding-bottom: 74px;
}

/* ==================== GLOBAL HEADER ==================== */
.ar-mobile-nav {
    background: #ffffff;
    border-bottom: 1px solid #edf0f2;
    padding: 0.9rem 1.5rem;
    position: sticky;
    top: 0;
    z-index: 1020;
}

.brand-logo {
    font-weight: 800;
    font-size: 1.35rem;
    letter-spacing: -0.5px;
    color: #0f172a;
    text-decoration: none;
}

.brand-logo span {
    color: var(--ar-primary);
}

.btn-nav-action {
    background: #0f172a;
    color: #ffffff !important;
    font-size: 0.8rem;
    font-weight: 600;
    padding: 0.45rem 1.15rem;
    border-radius: 50rem;
    border: none;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 4px;
    transition: all 0.2s ease;
}

.btn-nav-action:hover {
    background: #1e293b;
    transform: translateY(-1px);
}

/* ==================== AUTH CONTAINER & CARD ==================== */
.auth-wrapper {
    width: 100%;
    max-width: 460px;
    margin: auto;
    padding: 1.5rem 1.25rem;
    display: flex;
    flex-direction: column;
    justify-content: center;
    flex-grow: 1;
}

.auth-card {
    background: #ffffff;
    border-radius: 24px;
    border: 1px solid #e9eef2;
    box-shadow: 0 10px 30px -5px rgba(15, 23, 42, 0.06), 0 4px 6px -2px rgba(15, 23, 42, 0.02);
    padding: 2.25rem 1.75rem;
}

.badge-pill-soft {
    background: var(--ar-primary-soft);
    color: var(--ar-primary);
    border-radius: 50rem;
    font-size: 0.72rem;
    font-weight: 700;
    padding: 0.35rem 0.9rem;
    letter-spacing: 0.6px;
    text-transform: uppercase;
    display: inline-block;
    margin-bottom: 0.85rem;
}

.auth-title {
    font-size: 1.65rem;
    font-weight: 800;
    letter-spacing: -0.6px;
    line-height: 1.2;
    color: #0f172a;
    margin-bottom: 0.4rem;
}

.auth-subtitle {
    font-size: 0.88rem;
    color: var(--ar-text-sub);
    line-height: 1.5;
    margin-bottom: 1.5rem;
}

/* ==================== FORM INPUTS & TOGGLES ==================== */
.form-floating>.form-control {
    border: 1.5px solid #cbd5e1;
    border-radius: 14px;
    font-size: 0.95rem;
    height: 56px;
    padding-top: 1.625rem;
    padding-bottom: 0.625rem;
    background-color: #fafbfc;
    transition: all 0.2s ease;
}

.form-floating>.form-control:focus {
    border-color: var(--ar-primary);
    background-color: #ffffff;
    box-shadow: 0 0 0 4px rgba(199, 56, 43, 0.12);
}

.form-floating>label {
    color: #64748b;
    font-size: 0.85rem;
    font-weight: 500;
}

/* Password Input Wrapper with Fixed Eye Button */
.password-wrapper {
    position: relative;
    width: 100%;
}

.password-wrapper .form-control {
    padding-right: 48px;
}

.btn-toggle-eye {
    position: absolute;
    right: 14px;
    top: 50%;
    transform: translateY(-50%);
    background: transparent;
    border: none;
    outline: none;
    color: #94a3b8;
    font-size: 1.2rem;
    padding: 4px;
    cursor: pointer;
    z-index: 5;
    display: flex;
    align-items: center;
    justify-content: center;
}

.btn-toggle-eye:hover {
    color: #475569;
}

/* ==================== BUTTONS & SOCIAL ==================== */
.btn-ar-primary {
    background-color: var(--ar-primary) !important;
    border-color: var(--ar-primary) !important;
    color: #ffffff !important;
    font-size: 0.95rem;
    font-weight: 700;
    height: 52px;
    border-radius: 50rem !important;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    box-shadow: 0 6px 16px rgba(199, 56, 43, 0.28) !important;
    transition: all 0.2s ease;
    text-decoration: none;
    width: 100%;
    border: none;
}

.btn-ar-primary:hover:not(:disabled) {
    background-color: var(--ar-primary-hover) !important;
    box-shadow: 0 8px 20px rgba(199, 56, 43, 0.38) !important;
    transform: translateY(-1px);
}

.btn-ar-primary:disabled {
    background-color: #f0a39c !important;
    border-color: #f0a39c !important;
    color: #ffffff !important;
    opacity: 0.8 !important;
    box-shadow: none !important;
    cursor: not-allowed;
}

.btn-social {
    width: 100%;
    height: 48px;
    border: 1.5px solid #cbd5e1;
    border-radius: 12px;
    font-size: 0.88rem;
    font-weight: 600;
    color: #334155;
    background: #ffffff;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.6rem;
    transition: all 0.15s ease;
    text-decoration: none;
}

.btn-social:hover {
    background-color: #f8fafc;
    border-color: #94a3b8;
    color: #0f172a;
}

/* Divider Line with Text */
.or-divider {
    position: relative;
    text-align: center;
    margin: 1.25rem 0;
}

.or-divider::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 0;
    right: 0;
    height: 1px;
    background: #e2e8f0;
}

.or-divider span {
    position: relative;
    background: #ffffff;
    padding: 0 0.85rem;
    font-size: 0.76rem;
    font-weight: 600;
    color: #94a3b8;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* ==================== OTP DIGITS INPUT ==================== */
.otp-inputs-wrapper {
    display: flex;
    justify-content: space-between;
    gap: 8px;
    margin-bottom: 1.5rem;
    width: 100%;
}

.otp-digit-input {
    width: 100%;
    max-width: 52px;
    height: 56px;
    border-radius: 12px;
    border: 1.5px solid #cbd5e1;
    text-align: center;
    font-size: 1.35rem;
    font-weight: 700;
    color: #0f172a;
    background-color: #fafbfc;
    padding: 0;
    margin: 0;
    transition: all 0.15s ease-in-out;
    -moz-appearance: textfield;
}

.otp-digit-input::-webkit-outer-spin-button,
.otp-digit-input::-webkit-inner-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

.otp-digit-input:focus {
    outline: none;
    border-color: var(--ar-primary);
    background-color: #ffffff;
    box-shadow: 0 0 0 4px rgba(199, 56, 43, 0.12);
}

/* ==================== NOTICES & LINKS ==================== */
.security-notice-box {
    background: #f8fafc;
    border: 1px dashed #cbd5e1;
    border-radius: 14px;
    padding: 0.85rem 1rem;
    margin-top: 1.5rem;
    font-size: 0.78rem;
    color: #64748b;
    display: flex;
    align-items: flex-start;
    gap: 10px;
    line-height: 1.4;
}

.resend-link {
    color: var(--ar-primary);
    font-weight: 700;
    text-decoration: none;
    cursor: pointer;
}

.resend-link.disabled {
    color: #94a3b8;
    pointer-events: none;
    cursor: default;
}

/* ==================== STATS STRIP ==================== */
.stats-card-compact {
    background: #ffffff;
    border: 1px solid var(--ar-border);
    border-radius: 16px;
    padding: 0.85rem 1rem;
    margin-top: 1.25rem;
    display: flex;
    align-items: center;
    justify-content: space-around;
    text-align: center;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.02);
}

.stats-card-compact .stat-item h6 {
    font-weight: 800;
    margin-bottom: 0;
    font-size: 1.05rem;
    color: #0f172a;
}

.stats-card-compact .stat-item small {
    font-size: 0.72rem;
    color: #64748b;
    text-transform: uppercase;
    letter-spacing: 0.3px;
    display: block;
}

.stat-divider {
    width: 1px;
    height: 28px;
    background: #e2e8f0;
}

/* ==================== BOTTOM NAV (MOBILE) ==================== */
.ar-bottom-nav {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: #ffffff;
    border-top: 1px solid #edf0f2;
    display: flex;
    align-items: center;
    justify-content: space-around;
    height: 64px;
    z-index: 1030;
    padding: 0 0.5rem;
}

.nav-tab-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    color: #94a3b8;
    font-size: 0.68rem;
    font-weight: 600;
    flex: 1;
    padding: 4px 0;
}

.nav-tab-item.active {
    color: var(--ar-primary);
}

.nav-tab-center {
    position: relative;
    top: -12px;
}

.nav-tab-center .center-circle-btn {
    width: 48px;
    height: 48px;
    background: var(--ar-primary);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #ffffff;
    font-size: 1.35rem;
    box-shadow: 0 4px 12px rgba(199, 56, 43, 0.4);
    border: 3px solid #ffffff;
}

@media (min-width: 768px) {
    body {
        padding-bottom: 0;
    }

    .ar-bottom-nav {
        display: none;
    }
}