/* ═══════════════════════════════════════════════
   MHMCloud Auth Pages (Login + Register)
   assets/css/auth.css
════════════════════════════════════════════════ */

body:has(.auth-page) .top-bar,
body:has(.auth-page) header,
body:has(.auth-page) footer {
    display: none !important;
}
body:has(.auth-page) {
    background: #f0f4fb;
    margin: 0;
    padding: 0;
}

.auth-page {
    min-height: 100vh;
    display: flex;
}
.auth-split {
    display: flex;
    width: 100%;
    min-height: 100vh;
}

/* ── LEFT PANEL ── */
.auth-left {
    width: 420px;
    flex-shrink: 0;
    background: linear-gradient(150deg, var(--primary-blue) 0%, var(--dark-blue) 60%, #001040 100%);
    color: white;
    display: flex;
    flex-direction: column;
    padding: 40px;
    position: relative;
    overflow: hidden;
}
.auth-left::before {
    content: '';
    position: absolute;
    width: 350px; height: 350px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(255,211,0,0.1) 0%, transparent 70%);
    bottom: -100px; right: -80px;
    pointer-events: none;
}
.auth-left::after {
    content: '';
    position: absolute;
    width: 200px; height: 200px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(255,255,255,0.05) 0%, transparent 70%);
    top: 60px; left: -50px;
    pointer-events: none;
}

.auth-brand {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--primary-yellow);
    text-decoration: none;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: auto;
}
.auth-brand i { color: white; font-size: 1.8rem; }
.auth-brand strong { color: var(--primary-yellow); }

.auth-left-body {
    margin: auto 0;
    position: relative;
    z-index: 1;
}
.auth-left-body h2 {
    font-size: 2rem;
    font-weight: 800;
    margin-bottom: 12px;
    line-height: 1.2;
}
.auth-left-body p {
    font-size: 1rem;
    opacity: 0.8;
    margin-bottom: 36px;
    line-height: 1.6;
}
.auth-feature-list {
    display: flex;
    flex-direction: column;
    gap: 16px;
}
.auth-feature {
    display: flex;
    align-items: center;
    gap: 14px;
    font-size: 0.9rem;
    font-weight: 500;
}
.auth-feature i {
    width: 38px; height: 38px;
    background: rgba(255,255,255,0.1);
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--primary-yellow);
    font-size: 0.95rem;
    flex-shrink: 0;
}

/* ── RIGHT PANEL ── */
.auth-right {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 40px 24px;
    background: #f0f4fb;
    overflow-y: auto;
}
.auth-form-wrap {
    width: 100%;
    max-width: 500px;
}
.auth-title {
    font-size: 1.8rem;
    font-weight: 800;
    color: var(--primary-blue);
    margin-bottom: 6px;
}
.auth-sub {
    font-size: 0.9rem;
    color: #64748b;
    margin-bottom: 28px;
}
.auth-sub a {
    color: var(--primary-blue);
    font-weight: 600;
    text-decoration: none;
}
.auth-sub a:hover { text-decoration: underline; }

/* Messages */
.auth-msg {
    padding: 13px 16px;
    border-radius: 10px;
    font-size: 0.875rem;
    font-weight: 500;
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    gap: 10px;
}
.auth-msg.error   { background: #fee2e2; color: #dc2626; border: 1px solid #fecaca; }
.auth-msg.success { background: #dcfce7; color: #16a34a; border: 1px solid #bbf7d0; }
.auth-msg a { color: inherit; font-weight: 700; }

/* Fields */
.auth-field {
    margin-bottom: 18px;
}
.auth-field-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 14px;
}
.auth-field label {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.82rem;
    font-weight: 600;
    color: #374151;
    margin-bottom: 7px;
}
.req { color: #dc2626; }
.opt { color: #94a3b8; font-weight: 400; font-size: 0.75rem; }
.auth-forgot {
    font-size: 0.78rem;
    color: var(--primary-blue);
    text-decoration: none;
    font-weight: 600;
}
.auth-forgot:hover { text-decoration: underline; }

.auth-input-wrap {
    display: flex;
    align-items: center;
    background: white;
    border: 1.5px solid #e2e8f0;
    border-radius: 10px;
    padding: 0 14px;
    transition: border-color 0.2s, box-shadow 0.2s;
    gap: 10px;
}
.auth-input-wrap:focus-within {
    border-color: var(--primary-blue);
    box-shadow: 0 0 0 3px rgba(0,61,165,0.1);
}
.auth-input-wrap i {
    color: #94a3b8;
    font-size: 0.9rem;
    flex-shrink: 0;
    width: 16px;
}
.auth-input-wrap input {
    flex: 1;
    border: none;
    outline: none;
    padding: 13px 0;
    font-size: 0.9rem;
    font-family: 'Poppins', sans-serif;
    color: #1e293b;
    background: none;
    min-width: 0;
}
.auth-input-wrap input::placeholder { color: #cbd5e1; }
.pass-toggle {
    background: none;
    border: none;
    cursor: pointer;
    padding: 4px;
    color: #94a3b8;
    font-size: 0.85rem;
    flex-shrink: 0;
    transition: color 0.2s;
}
.pass-toggle:hover { color: var(--primary-blue); }

/* Remember / Terms */
.auth-remember { margin-bottom: 20px; }
.auth-check {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    cursor: pointer;
    font-size: 0.85rem;
    color: #475569;
    line-height: 1.5;
}
.auth-check input[type="checkbox"] {
    width: 16px; height: 16px;
    margin-top: 2px;
    accent-color: var(--primary-blue);
    flex-shrink: 0;
}
.auth-check a { color: var(--primary-blue); font-weight: 600; text-decoration: none; }
.auth-check a:hover { text-decoration: underline; }

/* Submit button */
.auth-submit-btn {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    background: var(--primary-blue);
    color: white;
    border: none;
    border-radius: 10px;
    padding: 15px;
    font-size: 1rem;
    font-weight: 700;
    font-family: 'Poppins', sans-serif;
    cursor: pointer;
    transition: background 0.2s, transform 0.2s;
}
.auth-submit-btn:hover { background: var(--dark-blue); transform: translateY(-1px); }

/* Password strength */
.auth-password-strength {
    margin: -10px 0 16px;
    display: flex;
    align-items: center;
    gap: 10px;
}
.strength-bar {
    flex: 1;
    height: 4px;
    background: #e2e8f0;
    border-radius: 4px;
    overflow: hidden;
}
.strength-fill {
    height: 100%;
    border-radius: 4px;
    transition: width 0.3s, background 0.3s;
    width: 0%;
}
#strengthLabel {
    font-size: 0.75rem;
    font-weight: 600;
    white-space: nowrap;
}

/* ── Responsive ── */
@media (max-width: 900px) {
    .auth-left { display: none; }
    .auth-right { padding: 40px 20px; }
}
@media (max-width: 500px) {
    .auth-field-row { grid-template-columns: 1fr; }
    .auth-form-wrap { max-width: 100%; }
}
