/* ============================================================
   EduMaster ERP — Auth Page Styles
   Login / Signup Page
   ============================================================ */

.auth-container {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 100vh;
    width: 100%;
    background: linear-gradient(135deg, #4338CA 0%, #6366F1 30%, #818CF8 60%, #06B6D4 100%);
    padding: 20px;
    position: relative;
    overflow: hidden;
}

.auth-container::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background:
        radial-gradient(circle at 30% 20%, rgba(255, 255, 255, 0.08) 0%, transparent 40%),
        radial-gradient(circle at 70% 80%, rgba(6, 182, 212, 0.1) 0%, transparent 40%);
    animation: authBgFloat 15s ease-in-out infinite;
}

@keyframes authBgFloat {
    0%, 100% { transform: translate(0, 0); }
    50% { transform: translate(-2%, -1%); }
}

.auth-card {
    background: #FFFFFF;
    border-radius: 24px;
    padding: 40px;
    width: 100%;
    max-width: 440px;
    position: relative;
    z-index: 1;
    box-shadow:
        0 20px 60px rgba(0, 0, 0, 0.15),
        0 4px 16px rgba(0, 0, 0, 0.05);
    animation: authCardEntrance 0.6s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
}

@keyframes authCardEntrance {
    0% {
        opacity: 0;
        transform: translateY(40px) scale(0.95);
    }
    100% {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

.auth-header {
    text-align: center;
    margin-bottom: 28px;
}

.auth-logo {
    width: 64px;
    height: 64px;
    border-radius: 16px;
    object-fit: cover;
    margin-bottom: 12px;
    filter: drop-shadow(0 4px 12px rgba(79, 70, 229, 0.25));
}

.auth-title {
    font-family: var(--font-heading);
    font-size: 1.8rem;
    font-weight: 800;
    background: linear-gradient(135deg, #4F46E5, #06B6D4);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 4px;
}

.auth-subtitle {
    font-size: 0.85rem;
    color: var(--text-muted);
}

.auth-tabs {
    display: flex;
    gap: 4px;
    background: #F1F5F9;
    border-radius: 12px;
    padding: 4px;
    margin-bottom: 24px;
}

.auth-tab {
    flex: 1;
    padding: 10px 16px;
    border-radius: 10px;
    border: none;
    background: transparent;
    font-family: var(--font-body);
    font-size: 0.88rem;
    font-weight: 600;
    color: var(--text-secondary);
    cursor: pointer;
    transition: all 0.2s ease;
}

.auth-tab.active {
    background: #FFFFFF;
    color: var(--primary);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
}

.auth-tab:hover:not(.active) {
    color: var(--text-primary);
}

.auth-error {
    font-size: 0.82rem;
    color: #DC2626;
    background: #FEF2F2;
    border: 1px solid #FECACA;
    border-radius: 10px;
    padding: 10px 14px;
    margin-bottom: 16px;
    display: none;
    animation: errorShake 0.4s ease;
}

.auth-error:not(:empty) {
    display: block;
}

@keyframes errorShake {
    0%, 100% { transform: translateX(0); }
    25% { transform: translateX(-6px); }
    75% { transform: translateX(6px); }
}

.auth-card .form-group {
    margin-bottom: 16px;
}

.auth-card .form-label {
    color: var(--text-primary);
    font-weight: 600;
    font-size: 0.82rem;
}

.auth-card .form-input {
    background: #F8FAFC;
    border: 1.5px solid #E2E8F0;
    padding: 12px 16px;
    font-size: 0.9rem;
    border-radius: 12px;
}

.auth-card .form-input:focus {
    background: #FFFFFF;
    border-color: var(--primary);
    box-shadow: 0 0 0 4px rgba(79, 70, 229, 0.1);
}

.auth-btn {
    width: 100%;
    padding: 14px 24px;
    font-size: 0.95rem;
    font-weight: 700;
    border-radius: 14px;
    margin-top: 4px;
}

.auth-link {
    display: block;
    text-align: center;
    margin-top: 14px;
    font-size: 0.82rem;
    color: var(--primary);
    background: none;
    border: none;
    cursor: pointer;
    font-family: var(--font-body);
    font-weight: 500;
    transition: color 0.2s;
}

.auth-link:hover {
    color: var(--accent);
    text-decoration: underline;
}

/* ============================================================
   Logout Button in Sidebar
   ============================================================ */
.btn-logout {
    display: flex;
    align-items: center;
    gap: 10px;
    width: 100%;
    padding: 10px 14px;
    margin-top: 12px;
    border-radius: 10px;
    border: 1px solid rgba(255, 255, 255, 0.15);
    background: rgba(239, 68, 68, 0.1);
    color: rgba(255, 255, 255, 0.8);
    font-family: var(--font-body);
    font-size: 0.82rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
}

.btn-logout svg {
    width: 18px;
    height: 18px;
}

.btn-logout:hover {
    background: rgba(239, 68, 68, 0.25);
    color: #FFFFFF;
    border-color: rgba(239, 68, 68, 0.3);
}

/* ============================================================
   Auth Divider
   ============================================================ */
.auth-divider {
    display: flex;
    align-items: center;
    gap: 12px;
    margin: 20px 0;
    color: var(--text-muted);
    font-size: 0.78rem;
}
.auth-divider::before,
.auth-divider::after {
    content: '';
    flex: 1;
    height: 1px;
    background: #E2E8F0;
}

/* ============================================================
   Google Sign-In Button
   ============================================================ */
.btn-google {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    padding: 12px 24px;
    border: 1.5px solid #E2E8F0;
    border-radius: 14px;
    background: #FFFFFF;
    font-family: var(--font-body);
    font-size: 0.9rem;
    font-weight: 600;
    color: #374151;
    cursor: pointer;
    transition: all 0.2s ease;
    box-shadow: 0 1px 4px rgba(0,0,0,0.06);
}
.btn-google:hover {
    background: #F8FAFC;
    border-color: #C7D2FE;
    box-shadow: 0 4px 12px rgba(79, 70, 229, 0.1);
    transform: translateY(-1px);
}
.btn-google:active {
    transform: translateY(0);
}

/* ============================================================
   Auth Footer
   ============================================================ */
.auth-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-top: 24px;
    padding-top: 16px;
    border-top: 1px solid #F1F5F9;
}

.auth-branding {
    display: flex;
    align-items: center;
    gap: 4px;
    font-size: 0.75rem;
}

.powered-by {
    color: var(--text-muted);
}

.brand-name {
    font-weight: 700;
    background: linear-gradient(135deg, #4F46E5, #06B6D4);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.privacy-link {
    font-size: 0.75rem;
    color: var(--text-muted);
    text-decoration: none;
    transition: color 0.2s;
}
.privacy-link:hover {
    color: var(--primary);
}

/* ============================================================
   Responsive Auth
   ============================================================ */
@media (max-width: 480px) {
    .auth-card {
        padding: 28px 20px;
    }

    .auth-title {
        font-size: 1.5rem;
    }

    .auth-logo {
        width: 52px;
        height: 52px;
    }
}
