/* ═══════════════════════════════════════════════════════════
   AUTH — Screentext AI (login / signup / logout pages)
═══════════════════════════════════════════════════════════ */

/* ─── Background & Ambient ──────────────────────────────── */
body {
    background-color: #0b0c10;
    color: #c5c6c7;
    margin: 0;
    font-family: 'Inter', sans-serif;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    overflow-x: hidden;
}

.blob {
    position: absolute;
    filter: blur(80px);
    z-index: -1;
    border-radius: 50%;
    opacity: 0.5;
}
.blob-1 {
    top: -100px;
    left: -100px;
    width: 400px;
    height: 400px;
    background: rgba(69, 162, 158, 0.2);
}
.blob-2 {
    bottom: -100px;
    right: -100px;
    width: 500px;
    height: 500px;
    background: rgba(102, 252, 241, 0.15);
}

/* ─── Page wrapper ─────────────────────────────────────── */
.auth-wrapper {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 2rem 1rem;
    position: relative;
    z-index: 1;
}

.auth-brand {
    font-size: 1.5rem;
    font-weight: 900;
    letter-spacing: 2px;
    color: #fff;
    text-decoration: none;
    margin-bottom: 2rem;
    display: flex;
    align-items: center;
}

.auth-brand span {
    background: linear-gradient(90deg, #10b981, #3b82f6);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    margin-left: 0.25rem;
}

/* ─── Card ─────────────────────────────────────────────── */
.auth-card {
    background: #1f2833;
    border: 1px solid rgba(102, 252, 241, 0.2);
    border-radius: 16px;
    padding: 2.5rem;
    width: 100%;
    max-width: 420px;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.5);
    position: relative;
    overflow: hidden;
}

.auth-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 4px;
    background: linear-gradient(90deg, #45a29e, #66fcf1);
}

.auth-card-header {
    text-align: center;
    margin-bottom: 2rem;
}

.auth-icon {
    width: 48px;
    height: 48px;
    background: rgba(102, 252, 241, 0.1);
    color: #66fcf1;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1rem;
}

.auth-icon svg {
    width: 24px;
    height: 24px;
}

.auth-title {
    font-size: 1.5rem;
    font-weight: 700;
    color: #fff;
    margin: 0 0 0.5rem;
}

.auth-subtitle {
    font-size: 0.9rem;
    color: #888;
    margin: 0;
}

/* ─── Google OAuth button ──────────────────────────────── */
.btn-social {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    width: 100%;
    padding: 0.75rem 1rem;
    background: #1a1a1d;
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    color: #c5c6c7;
    font-size: 0.9rem;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.2s;
    cursor: pointer;
    box-sizing: border-box;
}

.btn-social:hover {
    background: #252830;
    border-color: rgba(255, 255, 255, 0.2);
    color: #fff;
}

.social-icon {
    width: 20px;
    height: 20px;
}

/* ─── Divider ───────────────────────────────────────────── */
.auth-divider {
    display: flex;
    align-items: center;
    gap: 1rem;
    color: #666;
    font-size: 0.8rem;
    margin: 1.5rem 0;
}

.auth-divider::before,
.auth-divider::after {
    content: '';
    flex: 1;
    height: 1px;
    background: rgba(255, 255, 255, 0.1);
}

/* ─── Form fields ──────────────────────────────────────── */
.form-group {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    margin-bottom: 1.25rem;
}

.form-label-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.form-label {
    font-size: 0.85rem;
    font-weight: 600;
    color: #e0e0e0;
}

.form-forgot {
    font-size: 0.8rem;
    color: #45a29e;
    text-decoration: none;
}
.form-forgot:hover {
    color: #66fcf1;
    text-decoration: underline;
}

.input-wrapper {
    position: relative;
    display: flex;
    align-items: center;
}

.form-input {
    background: #0b0c10;
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    color: #fff;
    font-size: 0.95rem;
    font-family: inherit;
    padding: 0.75rem 1rem;
    padding-right: 2.5rem; /* Space for eye icon */
    outline: none;
    transition: border-color 0.2s, box-shadow 0.2s;
    width: 100%;
    box-sizing: border-box;
}

.form-input:focus {
    border-color: #66fcf1;
    box-shadow: 0 0 0 2px rgba(102, 252, 241, 0.2);
}

.form-input::placeholder {
    color: #666;
}

.form-input-error {
    border-color: #ef4444 !important;
}

.toggle-pw {
    position: absolute;
    right: 0.75rem;
    background: none;
    border: none;
    color: #666;
    cursor: pointer;
    padding: 0;
    display: flex;
    align-items: center;
    justify-content: center;
}
.toggle-pw:hover {
    color: #c5c6c7;
}

.eye-icon {
    width: 18px;
    height: 18px;
}
.toggle-pw.active .eye-icon {
    color: #66fcf1;
}

.form-error {
    color: #ef4444;
    font-size: 0.8rem;
    margin-top: -0.25rem;
}

.form-error-box {
    background: rgba(239, 68, 68, 0.1);
    border: 1px solid rgba(239, 68, 68, 0.3);
    border-radius: 8px;
    padding: 0.75rem;
    margin-bottom: 1.25rem;
    font-size: 0.85rem;
    color: #f87171;
}
.form-error-box p {
    margin: 0;
}

/* ─── Submit button ─────────────────────────────────────── */
.btn-primary {
    background-color: #66fcf1;
    color: #0b0c10;
    border: none;
    border-radius: 8px;
    font-size: 1rem;
    font-weight: 700;
    padding: 0.8rem 1rem;
    cursor: pointer;
    transition: all 0.2s ease;
    text-align: center;
    font-family: inherit;
}
.btn-primary:hover {
    background-color: #45a29e;
    color: #ffffff;
}

.btn-full {
    width: 100%;
    margin-top: 1rem;
}

/* ─── Footer and Links ──────────────────────────────────── */
.auth-footer-text {
    text-align: center;
    margin-top: 1.5rem;
    font-size: 0.9rem;
    color: #888;
}

.auth-link {
    color: #66fcf1;
    text-decoration: none;
    font-weight: 600;
}
.auth-link:hover {
    text-decoration: underline;
    color: #45a29e;
}

.auth-legal {
    text-align: center;
    margin-top: 2rem;
    font-size: 0.8rem;
    color: #666;
    max-width: 320px;
}

.auth-link-subtle {
    color: #888;
    text-decoration: underline;
}
.auth-link-subtle:hover {
    color: #aaa;
}

/* Password Strength Meter */
.pw-strength {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 1.25rem;
}
.pw-strength-bar {
    flex: 1;
    height: 6px;
    background: rgba(255,255,255,0.1);
    border-radius: 3px;
    overflow: hidden;
}
.pw-strength-fill {
    height: 100%;
    width: 0;
    transition: width 0.3s ease, background-color 0.3s ease;
}
.pw-strength-label {
    font-size: 0.75rem;
    font-weight: 600;
    width: 40px;
    text-align: right;
}

/* ─── Alert Messages (Django Messages) ──────────────────── */
.auth-messages {
    margin-bottom: 1.5rem;
}

.auth-alert {
    padding: 0.75rem 1rem;
    border-radius: 8px;
    font-size: 0.85rem;
    margin-bottom: 0.5rem;
}
.auth-alert-error {
    background: rgba(239, 68, 68, 0.1);
    border: 1px solid rgba(239, 68, 68, 0.3);
    color: #f87171;
}
.auth-alert-success {
    background: rgba(16, 185, 129, 0.1);
    border: 1px solid rgba(16, 185, 129, 0.3);
    color: #34d399;
}

