/* ═══════════════════════════════════════════════════════════════════
   EazX — Auth Page Styles (auth.css)
   Clean, sharp login with minimal border radius
   ═══════════════════════════════════════════════════════════════════ */

.auth-page {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    overflow: hidden;
    padding: var(--space-lg);
}

/* ─── Animated Background ────────────────────────────────────────── */
.auth-bg {
    position: fixed;
    inset: 0;
    z-index: 0;
    background: var(--bg-primary);
}

.auth-bg::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: 
        radial-gradient(ellipse at 20% 50%, rgba(6, 182, 212, 0.08) 0%, transparent 50%),
        radial-gradient(ellipse at 80% 20%, rgba(14, 165, 233, 0.06) 0%, transparent 50%),
        radial-gradient(ellipse at 50% 80%, rgba(99, 102, 241, 0.05) 0%, transparent 50%);
    animation: gradientShift 20s ease-in-out infinite;
}

/* Floating orbs */
.auth-orb {
    position: absolute;
    border-radius: 50%;
    filter: blur(80px);
    animation: float 8s ease-in-out infinite;
    z-index: 0;
}

.auth-orb-1 {
    width: 400px;
    height: 400px;
    background: rgba(6, 182, 212, 0.06);
    top: 10%;
    left: 15%;
    animation-delay: 0s;
    animation-duration: 14s;
}

.auth-orb-2 {
    width: 300px;
    height: 300px;
    background: rgba(99, 102, 241, 0.04);
    bottom: 10%;
    right: 10%;
    animation-delay: -4s;
    animation-duration: 12s;
}

.auth-orb-3 {
    width: 250px;
    height: 250px;
    background: rgba(14, 165, 233, 0.04);
    top: 50%;
    right: 30%;
    animation-delay: -2s;
    animation-duration: 16s;
}

/* Grid pattern overlay */
.auth-grid {
    position: absolute;
    inset: 0;
    background-image: 
        linear-gradient(rgba(6, 182, 212, 0.02) 1px, transparent 1px),
        linear-gradient(90deg, rgba(6, 182, 212, 0.02) 1px, transparent 1px);
    background-size: 64px 64px;
    z-index: 0;
}

/* ─── Login Card ─────────────────────────────────────────────────── */
.auth-card {
    position: relative;
    z-index: 1;
    width: 100%;
    max-width: 400px;
    background: rgba(15, 19, 32, 0.85);
    backdrop-filter: blur(40px);
    -webkit-backdrop-filter: blur(40px);
    border: 1px solid var(--border-medium);
    border-radius: 12px;
    padding: 40px 36px 36px;
    box-shadow: var(--shadow-lg), 0 0 60px rgba(6, 182, 212, 0.06);
    animation: slideUp 0.4s ease-out;
}

.auth-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 50%;
    height: 1px;
    background: linear-gradient(90deg, transparent, var(--accent-primary), transparent);
    opacity: 0.4;
}

/* ─── Logo / Brand ───────────────────────────────────────────────── */
.auth-brand {
    text-align: center;
    margin-bottom: 32px;
}

.auth-logo {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 52px;
    height: 52px;
    background: var(--accent-gradient);
    border-radius: 12px;
    margin-bottom: 16px;
    box-shadow: 0 4px 24px rgba(6, 182, 212, 0.3);
    animation: bounceIn 0.5s ease-out;
}

.auth-logo svg {
    width: 24px;
    height: 24px;
    fill: white;
}

.auth-title {
    font-size: 28px;
    font-weight: 800;
    background: var(--accent-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 6px;
    letter-spacing: -0.5px;
}

.auth-subtitle {
    color: var(--text-tertiary);
    font-size: 13px;
    font-weight: 400;
}

/* ─── Form ───────────────────────────────────────────────────────── */
.auth-form {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.form-group {
    position: relative;
    display: flex;
    flex-direction: column;
}

.input-wrapper {
    position: relative;
    width: 100%;
}

.form-label {
    display: block;
    font-size: 11px;
    font-weight: 600;
    color: var(--text-tertiary);
    margin-bottom: 8px;
    text-transform: uppercase;
    letter-spacing: 0.8px;
}

.form-input {
    width: 100%;
    padding: 13px 16px 13px 44px;
    background: var(--bg-tertiary);
    border: 1px solid var(--border-subtle);
    border-radius: 8px;
    color: var(--text-primary);
    font-size: 14px;
    letter-spacing: 0.5px;
    transition: all var(--transition-base);
    box-sizing: border-box;
}

.form-input::placeholder {
    color: var(--text-muted);
    letter-spacing: 2px;
    font-size: 13px;
}

.form-input:focus {
    outline: none;
    border-color: var(--accent-primary);
    box-shadow: 0 0 0 3px rgba(6, 182, 212, 0.12);
    background: rgba(21, 26, 46, 0.9);
}

/* Icon inside input */
.form-icon {
    position: absolute;
    left: 14px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-muted);
    display: flex;
    align-items: center;
    pointer-events: none;
    transition: color var(--transition-fast);
    z-index: 1;
}

.form-icon svg {
    width: 16px;
    height: 16px;
    display: block;
}

.input-wrapper:focus-within .form-icon {
    color: var(--accent-primary);
}

/* ─── Key Hint ───────────────────────────────────────────────────── */
.key-hint {
    font-size: 11px;
    color: var(--text-muted);
    margin-top: 6px;
    letter-spacing: 0.5px;
    opacity: 0.7;
}

/* ─── Login Button ───────────────────────────────────────────────── */
.auth-btn {
    width: 100%;
    padding: 14px;
    margin-top: 8px;
    font-size: 13px;
    font-weight: 700;
    border-radius: 8px;
    background: var(--accent-gradient);
    color: white;
    position: relative;
    overflow: hidden;
    transition: all var(--transition-base);
    box-shadow: 0 2px 16px rgba(6, 182, 212, 0.25);
    letter-spacing: 1px;
    text-transform: uppercase;
    border: none;
    cursor: pointer;
}

.auth-btn::before {
    content: '';
    position: absolute;
    inset: 0;
    background: rgba(255, 255, 255, 0.08);
    opacity: 0;
    transition: opacity var(--transition-base);
}

.auth-btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 24px rgba(6, 182, 212, 0.4);
}

.auth-btn:hover::before {
    opacity: 1;
}

.auth-btn:active {
    transform: translateY(0);
}

.auth-btn span {
    position: relative;
    z-index: 1;
}

.auth-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    transform: none;
}

.auth-btn .spinner {
    display: none;
    margin: 0 auto;
}

.auth-btn.loading span {
    display: none;
}

.auth-btn.loading .spinner {
    display: block;
    border-color: rgba(255, 255, 255, 0.3);
    border-top-color: white;
}

/* ─── Error Message ──────────────────────────────────────────────── */
.auth-error {
    padding: 10px 14px;
    background: rgba(244, 63, 94, 0.08);
    border: 1px solid rgba(244, 63, 94, 0.2);
    border-radius: 8px;
    color: var(--error);
    font-size: 13px;
    display: none;
    align-items: center;
    gap: 8px;
    animation: slideDown 0.25s ease-out;
}

.auth-error.visible {
    display: flex;
}

.auth-error svg {
    flex-shrink: 0;
    opacity: 0.9;
}

/* ─── Security Badge ─────────────────────────────────────────────── */
.auth-security {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    margin-top: 28px;
    color: var(--text-muted);
    font-size: 12px;
    letter-spacing: 0.2px;
}

.auth-security svg {
    width: 12px;
    height: 12px;
    fill: var(--success);
    opacity: 0.8;
    flex-shrink: 0;
}

/* ─── Responsive ─────────────────────────────────────────────────── */
@media (max-width: 480px) {
    .auth-card {
        padding: 32px 24px 28px;
        border-radius: 10px;
    }
    
    .auth-title {
        font-size: 24px;
    }
}
