:root {
    --primary-color: #432c74;
    --accent-color: #17b890;
    --light-surface: #f4f4fb;
}

body,
.auth-body {
    margin: 0;
    font-family: 'Segoe UI', Tahoma, sans-serif;
    background: linear-gradient(135deg, #1c1c44, #2b1346);
    color: #1a1a1a;
    min-height: 100vh;
}

.auth-page {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 100vh;
    padding: 40px 20px;
}

.auth-card {
    background: white;
    border-radius: 20px;
    width: 100%;
    max-width: 420px;
    padding: 36px;
    box-shadow: 0 30px 60px rgba(15, 5, 30, 0.35);
}

.auth-header {
    text-align: center;
    margin-bottom: 26px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
}

.auth-logo-img {
    width: 100px;
    height: auto;
}

.auth-logo-text {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.auth-logo {
    font-size: 1.6rem;
    letter-spacing: 2px;
    font-weight: 700;
    color: var(--primary-color);
}

.auth-description {
    margin-top: 6px;
    color: #555;
    font-size: 0.95rem;
}

.auth-flash {
    border-radius: 10px;
    padding: 10px 12px;
    font-size: 0.9rem;
    margin-bottom: 14px;
}

.auth-flash--success {
    background: #eaf9f3;
    border: 1px solid #b8efd8;
    color: #0d6b4d;
}

.auth-flash--error {
    background: #fff1f2;
    border: 1px solid #fecdd3;
    color: #b42318;
}

.auth-otp-note {
    background: #f4f4fb;
    border: 1px solid #e2e3f3;
    border-radius: 10px;
    padding: 10px 12px;
    color: #3c3553;
    margin-bottom: 16px;
    font-size: 0.9rem;
}

.auth-otp-note small {
    display: block;
    margin-top: 6px;
    color: #5b5873;
}

.auth-form {
    display: flex;
    flex-direction: column;
    gap: 18px;
}

.auth-label {
    display: block;
    font-size: 0.85rem;
    font-weight: 600;
    color: #555;
    margin-bottom: 6px;
}

.auth-field input,
.auth-input {
    width: 100%;
    padding: 12px 14px;
    border-radius: 10px;
    border: 1px solid #dcdce6;
    font-size: 1rem;
    transition: border 0.2s ease, box-shadow 0.2s ease;
}

.auth-field {
    position: relative;
}

.password-toggle {
    position: absolute;
    right: 10px;
    top: 38px;
    border: none;
    background: transparent;
    color: #5f6368;
    font-size: 0.85rem;
    cursor: pointer;
    padding: 2px 6px;
}

.password-rules {
    list-style: none;
    margin: -8px 0 0;
    padding: 0;
    display: grid;
    gap: 4px;
    font-size: 0.85rem;
}

.password-rules li {
    color: #b42318;
}

.password-rules li.is-valid {
    color: #0f9d58;
}

.password-rules li::before {
    content: "• ";
}

.auth-field input:focus,
.auth-input:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(67, 44, 116, 0.20);
}

.auth-error {
    margin-top: 4px;
    font-size: 0.8rem;
    color: #d32f2f;
}

.remember-row {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 0.9rem;
    color: #555;
}

.auth-checkbox {
    width: 18px;
    height: 18px;
    accent-color: var(--primary-color);
}

.auth-label--checkbox {
    margin: 0;
    font-size: 0.9rem;
}

.auth-submit {
    width: 100%;
    padding: 12px;
    border-radius: 12px;
    border: none;
    background: var(--primary-color);
    color: white;
    font-weight: 600;
    font-size: 1rem;
    cursor: pointer;
    transition: transform 0.2s ease;
}

.auth-submit:hover {
    transform: translateY(-2px);
}

.auth-help {
    margin-top: 18px;
    font-size: 0.8rem;
    color: #666;
    text-align: center;
}

.auth-actions {
    margin-top: 12px;
    text-align: center;
}

.auth-link-btn {
    background: none;
    border: none;
    color: var(--primary-color);
    font-weight: 600;
    text-decoration: underline;
    cursor: pointer;
    padding: 0;
}

.auth-actions .auth-submit {
    width: 100%;
}

.auth-help code {
    background: var(--light-surface);
    padding: 2px 6px;
    border-radius: 4px;
    font-size: 0.8rem;
}

@media (max-width: 480px) {
    .auth-card {
        padding: 24px;
    }

    .auth-page {
        padding: 20px;
    }
}
