/* ===== Auth pages (login / forgot / reset) — modern split-screen layout ===== */

body.auth-body {
    margin: 0;
    min-height: 100vh;
    font-family: 'Muli', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    color: #2c2c2c;
    background: #f8f9fb;
}

.auth-wrap {
    display: flex;
    min-height: 100vh;
}

/* ----- Left hero panel ----- */
.auth-hero {
    flex: 1.1;
    background: linear-gradient(135deg, #4080ff 0%, #2c5fcf 50%, #1e3a8a 100%);
    color: #fff;
    padding: 60px 60px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    position: relative;
    overflow: hidden;
}
.auth-hero::before,
.auth-hero::after {
    content: '';
    position: absolute;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.06);
    pointer-events: none;
}
.auth-hero::before { width: 400px; height: 400px; top: -120px; right: -120px; }
.auth-hero::after  { width: 320px; height: 320px; bottom: -100px; left: -100px; }

.auth-hero-logo {
    display: flex;
    align-items: center;
    gap: 14px;
    position: relative;
    z-index: 1;
}
.auth-hero-logo img {
    max-width: 56px;
    max-height: 56px;
    background: rgba(255, 255, 255, 0.95);
    padding: 6px;
    border-radius: 10px;
}
.auth-hero-logo .auth-company {
    font-size: 20px;
    font-weight: 600;
    letter-spacing: -0.2px;
}

.auth-hero-content {
    position: relative;
    z-index: 1;
    max-width: 480px;
}
.auth-hero-content h1 {
    font-size: 38px;
    line-height: 1.15;
    margin: 0 0 16px 0;
    font-weight: 700;
    letter-spacing: -0.5px;
}
.auth-hero-content p {
    font-size: 15px;
    line-height: 1.6;
    color: rgba(255, 255, 255, 0.85);
    margin: 0 0 32px 0;
}
.auth-hero-features { list-style: none; padding: 0; margin: 0; }
.auth-hero-features li {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 0;
    font-size: 14px;
    color: rgba(255, 255, 255, 0.9);
}
.auth-hero-features li::before {
    content: '✓';
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 22px;
    height: 22px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.2);
    font-size: 12px;
    font-weight: 700;
    flex-shrink: 0;
}

.auth-hero-footer {
    position: relative;
    z-index: 1;
    font-size: 12px;
    color: rgba(255, 255, 255, 0.65);
}

/* ----- Right form panel ----- */
.auth-form-panel {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 40px 24px;
    background: #fff;
}
.auth-form-inner {
    width: 100%;
    max-width: 400px;
}
.auth-form-title {
    font-size: 26px;
    font-weight: 700;
    color: #1a202c;
    margin: 0 0 6px 0;
    letter-spacing: -0.3px;
}
.auth-form-sub {
    font-size: 14px;
    color: #6c757d;
    margin: 0 0 28px 0;
}

.auth-mobile-logo {
    display: none;
    text-align: center;
    margin-bottom: 24px;
}
.auth-mobile-logo img { max-width: 64px; max-height: 64px; }

.auth-alert {
    padding: 12px 14px;
    border-radius: 8px;
    font-size: 13px;
    margin-bottom: 16px;
    display: flex;
    align-items: flex-start;
    gap: 8px;
}
.auth-alert-success { background: #e6f7ed; color: #1b5e2d; border-left: 3px solid #38a169; }
.auth-alert-error   { background: #fde8e8; color: #9b2c2c; border-left: 3px solid #e53e3e; }

.auth-field {
    margin-bottom: 18px;
}
.auth-field label {
    display: block;
    font-size: 13px;
    font-weight: 600;
    color: #4a5568;
    margin-bottom: 6px;
}
.auth-input-group {
    position: relative;
    display: flex;
    align-items: stretch;
}
.auth-input-group i.field-icon {
    position: absolute;
    left: 14px;
    top: 50%;
    transform: translateY(-50%);
    color: #a0aec0;
    font-size: 15px;
    pointer-events: none;
    z-index: 2;
}
.auth-input {
    width: 100%;
    border: 1.5px solid #e2e8f0;
    border-radius: 8px;
    padding: 11px 14px 11px 42px;
    font-size: 14px;
    color: #2d3748;
    background: #fff;
    transition: border-color 0.15s, box-shadow 0.15s;
    outline: none;
    font-family: inherit;
}
.auth-input::placeholder { color: #cbd5e0; }
.auth-input:focus {
    border-color: #4080ff;
    box-shadow: 0 0 0 3px rgba(64, 128, 255, 0.12);
}
.auth-input.invalid {
    border-color: #e53e3e;
    box-shadow: 0 0 0 3px rgba(229, 62, 62, 0.1);
}
.auth-input.no-icon {
    padding-left: 14px;
}
.auth-input-toggle {
    position: absolute;
    right: 12px;
    top: 50%;
    transform: translateY(-50%);
    background: transparent;
    border: 0;
    color: #a0aec0;
    cursor: pointer;
    padding: 4px 6px;
    font-size: 14px;
    z-index: 2;
}
.auth-input-toggle:hover { color: #4a5568; }

.auth-field-error {
    color: #e53e3e;
    font-size: 12px;
    margin-top: 6px;
    display: none;
}
.auth-field-error:not(:empty) {
    display: block;
}

.auth-row-meta {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 22px;
    font-size: 13px;
}
.auth-row-meta a { color: #4080ff; text-decoration: none; font-weight: 500; }
.auth-row-meta a:hover { text-decoration: underline; }

.auth-btn {
    width: 100%;
    padding: 12px 16px;
    border: 0;
    border-radius: 8px;
    background: linear-gradient(135deg, #4080ff 0%, #2c5fcf 100%);
    color: #fff;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: transform 0.1s, box-shadow 0.15s, opacity 0.15s;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}
.auth-btn:hover { box-shadow: 0 4px 14px rgba(64, 128, 255, 0.32); transform: translateY(-1px); }
.auth-btn:active { transform: translateY(0); }
.auth-btn:disabled { opacity: 0.7; cursor: wait; }
.auth-btn .spinner {
    width: 14px; height: 14px;
    border: 2px solid rgba(255, 255, 255, 0.4);
    border-top-color: #fff;
    border-radius: 50%;
    animation: auth-spin 0.7s linear infinite;
    display: none;
}
.auth-btn.loading .spinner { display: inline-block; }
.auth-btn.loading .btn-label { opacity: 0.85; }
@keyframes auth-spin { to { transform: rotate(360deg); } }

.auth-secondary-link {
    text-align: center;
    margin-top: 20px;
    font-size: 13px;
    color: #6c757d;
}
.auth-secondary-link a { color: #4080ff; text-decoration: none; font-weight: 500; }
.auth-secondary-link a:hover { text-decoration: underline; }

/* Password strength meter (reset page) */
.pw-strength {
    margin-top: 8px;
    height: 4px;
    background: #edf2f7;
    border-radius: 2px;
    overflow: hidden;
}
.pw-strength-bar {
    height: 100%;
    width: 0;
    transition: width 0.2s, background 0.2s;
    border-radius: 2px;
}
.pw-strength-text {
    font-size: 11px;
    color: #718096;
    margin-top: 4px;
}

/* Responsive */
@media (max-width: 900px) {
    .auth-wrap { flex-direction: column; }
    .auth-hero { display: none; }
    .auth-mobile-logo { display: block; }
    .auth-form-panel { min-height: 100vh; padding: 32px 20px; }
}

@media (max-width: 480px) {
    .auth-form-inner { max-width: 100%; }
    .auth-form-title { font-size: 22px; }
}
