/* ===== Google Font Import ===== */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800&display=swap');

/* ===== CSS Variables ===== */
:root {
    --primary: #6c5ce7;
    --primary-dark: #5a4bd1;
    --primary-light: #a29bfe;
    --primary-glow: rgba(108, 92, 231, 0.3);
    --secondary: #00cec9;
    --accent: #fd79a8;
    --bg-dark: #0c0c1d;
    --bg-card: rgba(255, 255, 255, 0.05);
    --bg-input: rgba(255, 255, 255, 0.08);
    --text-white: #ffffff;
    --text-light: #b2b2cc;
    --text-muted: #6c6c8a;
    --border-color: rgba(255, 255, 255, 0.1);
    --shadow-primary: 0 8px 32px rgba(108, 92, 231, 0.3);
    --primary-solid: #6c5ce7;
    --shadow-card: 0 8px 32px rgba(0, 0, 0, 0.3);
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* ===== Reset & Base ===== */
*, *::before, *::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html, body {
    height: 100%;
    overflow: hidden;
}

body {
    font-family: 'Inter', sans-serif;
    background: var(--bg-dark);
    color: var(--text-white);
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
}

/* ===== Background & Particles Hidden ===== */
.bg-animated,
.particles,
.particle {
    display: none;
}


/* ===== Login Container ===== */
.login-container {
    position: relative;
    z-index: 10;
    display: flex;
    width: 950px;
    max-width: 95vw;
    min-height: 560px;
    border-radius: 24px;
    overflow: hidden;
    background: #1a1a2e;
    border: 1px solid var(--border-color);
    box-shadow: var(--shadow-card);
    animation: containerSlideUp 0.8s cubic-bezier(0.4, 0, 0.2, 1) forwards;
    opacity: 0;
    transform: translateY(40px);
}

@keyframes containerSlideUp {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* ===== Left Panel (Illustration) ===== */
.login-left {
    flex: 1;
    background: var(--primary-solid);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 50px 40px;
    position: relative;
    overflow: hidden;
}

.login-left::before,
.login-left::after {
    display: none;
}

.illustration-wrapper {
    position: relative;
    z-index: 1;
    text-align: center;
}

.illustration-svg {
    width: 280px;
    height: 280px;
    margin-bottom: 30px;
    animation: floatIllustration 6s ease-in-out infinite;
}

@keyframes floatIllustration {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-15px); }
}

.login-left h2 {
    font-size: 26px;
    font-weight: 700;
    margin-bottom: 12px;
    letter-spacing: -0.5px;
}

.login-left p {
    font-size: 14px;
    color: rgba(255, 255, 255, 0.7);
    line-height: 1.6;
    max-width: 300px;
}

/* ===== Right Panel (Form) ===== */
.login-right {
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 50px 45px;
}

.login-header {
    margin-bottom: 35px;
}

.login-header .brand-icon {
    width: 48px;
    height: 48px;
    background: var(--primary-solid);
    border-radius: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 24px;
    box-shadow: var(--shadow-primary);
    animation: brandPulse 3s ease-in-out infinite;
}

@keyframes brandPulse {
    0%, 100% { box-shadow: 0 4px 20px rgba(108, 92, 231, 0.3); }
    50% { box-shadow: 0 4px 30px rgba(108, 92, 231, 0.6); }
}

.login-header .brand-icon svg {
    width: 24px;
    height: 24px;
    fill: white;
}

.login-header h1 {
    font-size: 28px;
    font-weight: 700;
    margin-bottom: 8px;
    letter-spacing: -0.5px;
}

.login-header p {
    font-size: 14px;
    color: var(--text-muted);
}

/* ===== Form Styles ===== */
.form-group {
    margin-bottom: 22px;
    position: relative;
    animation: formSlideIn 0.6s ease forwards;
    opacity: 0;
    transform: translateX(20px);
}

.form-group:nth-child(1) { animation-delay: 0.3s; }
.form-group:nth-child(2) { animation-delay: 0.45s; }

@keyframes formSlideIn {
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

.form-group label {
    display: block;
    font-size: 13px;
    font-weight: 500;
    color: var(--text-light);
    margin-bottom: 8px;
    transition: var(--transition);
}

.input-wrapper {
    position: relative;
}

.input-wrapper .input-icon {
    position: absolute;
    left: 16px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-muted);
    transition: var(--transition);
    pointer-events: none;
}

.input-wrapper .input-icon svg {
    width: 18px;
    height: 18px;
    stroke: currentColor;
    fill: none;
    stroke-width: 2;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.form-input {
    width: 100%;
    padding: 14px 16px 14px 48px;
    background: var(--bg-input);
    border: 1.5px solid var(--border-color);
    border-radius: 12px;
    color: var(--text-white);
    font-size: 14px;
    font-family: 'Inter', sans-serif;
    transition: var(--transition);
    outline: none;
}

.form-input::placeholder {
    color: var(--text-muted);
}

.form-input:focus {
    border-color: var(--primary);
    background: rgba(108, 92, 231, 0.08);
    box-shadow: 0 0 0 4px var(--primary-glow);
}

.form-input:focus + .input-icon,
.form-input:focus ~ .input-icon {
    color: var(--primary);
}

/* ===== Eye Toggle ===== */
.toggle-password {
    position: absolute;
    right: 16px;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    color: var(--text-muted);
    cursor: pointer;
    padding: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition);
    border-radius: 6px;
}

.toggle-password:hover {
    color: var(--primary-light);
    background: rgba(108, 92, 231, 0.1);
}

.toggle-password svg {
    width: 18px;
    height: 18px;
    stroke: currentColor;
    fill: none;
    stroke-width: 2;
    stroke-linecap: round;
    stroke-linejoin: round;
}

/* ===== Form Options ===== */
.form-options {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 28px;
    animation: formSlideIn 0.6s ease forwards;
    opacity: 0;
    transform: translateX(20px);
    animation-delay: 0.6s;
}

.remember-check {
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
}

.remember-check input[type="checkbox"] {
    display: none;
}

.checkmark {
    width: 18px;
    height: 18px;
    border: 2px solid var(--border-color);
    border-radius: 5px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition);
    flex-shrink: 0;
}

.remember-check input:checked ~ .checkmark {
    background: var(--primary);
    border-color: var(--primary);
}

.checkmark svg {
    width: 12px;
    height: 12px;
    stroke: white;
    fill: none;
    stroke-width: 3;
    stroke-linecap: round;
    stroke-linejoin: round;
    opacity: 0;
    transform: scale(0);
    transition: var(--transition);
}

.remember-check input:checked ~ .checkmark svg {
    opacity: 1;
    transform: scale(1);
}

.remember-check span {
    font-size: 13px;
    color: var(--text-light);
}

.forgot-link {
    font-size: 13px;
    color: var(--primary-light);
    text-decoration: none;
    font-weight: 500;
    transition: var(--transition);
}

.forgot-link:hover {
    color: var(--primary);
    text-decoration: underline;
}

/* ===== Submit Button ===== */
.btn-login {
    width: 100%;
    padding: 15px;
    background: var(--primary-solid);
    color: white;
    border: none;
    border-radius: 12px;
    font-size: 15px;
    font-weight: 600;
    font-family: 'Inter', sans-serif;
    cursor: pointer;
    transition: var(--transition);
    position: relative;
    overflow: hidden;
    animation: formSlideIn 0.6s ease forwards;
    opacity: 0;
    transform: translateX(20px);
    animation-delay: 0.75s;
}

.btn-login::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.2), transparent);
    transition: 0.5s;
}

.btn-login:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-primary);
}

.btn-login:hover::before {
    left: 100%;
}

.btn-login:active {
    transform: translateY(0) scale(0.98);
}

/* ===== Divider ===== */
.divider {
    display: flex;
    align-items: center;
    gap: 16px;
    margin: 24px 0;
    animation: formSlideIn 0.6s ease forwards;
    opacity: 0;
    transform: translateX(20px);
    animation-delay: 0.9s;
}

.divider::before,
.divider::after {
    content: '';
    flex: 1;
    height: 1px;
    background: var(--border-color);
}

.divider span {
    font-size: 12px;
    color: var(--text-muted);
    white-space: nowrap;
}

/* ===== Social Login ===== */
.social-login {
    display: flex;
    gap: 12px;
    animation: formSlideIn 0.6s ease forwards;
    opacity: 0;
    transform: translateX(20px);
    animation-delay: 1.05s;
}

.social-btn {
    flex: 1;
    padding: 12px;
    background: var(--bg-input);
    border: 1.5px solid var(--border-color);
    border-radius: 12px;
    color: var(--text-light);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition);
}

.social-btn:hover {
    border-color: var(--primary);
    background: rgba(108, 92, 231, 0.08);
    transform: translateY(-2px);
}

.social-btn svg {
    width: 20px;
    height: 20px;
}

/* ===== Responsive ===== */
@media (max-width: 768px) {
    .login-container {
        flex-direction: column;
        max-height: 95vh;
        overflow-y: auto;
    }

    .login-left {
        padding: 35px 30px;
        min-height: auto;
    }

    .illustration-svg {
        width: 180px;
        height: 180px;
        margin-bottom: 20px;
    }

    .login-left h2 {
        font-size: 20px;
    }

    .login-right {
        padding: 30px 25px;
    }
}

@media (max-width: 480px) {
    .login-left {
        display: none;
    }

    .login-container {
        border-radius: 16px;
    }
}
