:root {
    --login-bg: #111426;
    /* Deep Navy */
    --card-bg: #1a1e36;
    /* Lighter Navy */
    --input-bg: #161a30;
    /* Input Dark */
    --primary: #3699ff;
    --secondary: #009ef7;
    --text-primary: #ffffff;
    --text-secondary: #9299b8;
    --border: rgba(255, 255, 255, 0.08);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Outfit', sans-serif;
}

body {
    background-color: var(--login-bg);
    height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    position: relative;
}

/* Background Blobs */
.blob {
    position: absolute;
    width: 500px;
    height: 500px;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    filter: blur(120px);
    border-radius: 50%;
    z-index: -1;
    animation: move 20s infinite alternate;
    opacity: 0.15; /* Elegant glow */
}

.blob-1 {
    top: -150px;
    left: -150px;
}

.blob-2 {
    bottom: -150px;
    right: -150px;
    animation-delay: -5s;
}

@keyframes move {
    from {
        transform: translate(0, 0) scale(1);
    }

    to {
        transform: translate(120px, 120px) scale(1.25);
    }
}

/* Login Card */
.login-container {
    width: 100%;
    max-width: 440px; /* Enlarged from 340px */
    padding: 24px;
    perspective: 1000px;
}

.login-card {
    background: var(--card-bg);
    border: 1px solid var(--border);
    border-radius: 16px; /* Modernized rounder corners */
    padding: 44px 36px; /* Generous breathing space */
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3), 0 0 50px rgba(54, 153, 255, 0.05);
    transform-style: preserve-3d;
    animation: cardIn 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes cardIn {
    from {
        opacity: 0;
        transform: translateY(30px) rotateX(-10deg);
    }

    to {
        opacity: 1;
        transform: translateY(0) rotateX(0);
    }
}

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

.login-header .logo {
    width: 100%;
    max-width: 220px;
    height: auto;
    background: transparent;
    border-radius: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 8px;
    box-shadow: none;
}

.login-header .logo img {
    max-width: 100%;
    filter: drop-shadow(0 5px 15px rgba(0, 0, 0, 0.2));
}

.login-header h1 {
    color: var(--text-primary);
    font-size: 2rem;
    font-weight: 700;
    margin-bottom: 8px;
}

.login-header p {
    color: var(--text-secondary);
    font-size: 1rem;
}

/* Form Styling */
.form-group {
    margin-bottom: 20px; /* Spacious group layout */
    position: relative;
}

.form-group label {
    display: block; /* Show labels with clean styling */
    color: var(--text-secondary);
    font-size: 0.9rem;
    font-weight: 500;
    margin-bottom: 8px;
    margin-left: 4px;
}

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

.input-wrapper i {
    position: absolute;
    left: 18px;
    color: var(--text-secondary);
    font-size: 1.2rem;
    transition: color 0.3s;
}

.input-wrapper input {
    width: 100%;
    background: var(--input-bg);
    border: 1px solid var(--border);
    border-radius: 10px; /* Premium larger border radius */
    padding: 13px 40px 13px 48px; /* Taller, premium layout */
    color: var(--text-primary);
    font-size: 0.95rem;
    outline: none;
    transition: all 0.3s;
}

.input-wrapper input:focus {
    border-color: var(--primary);
    background: rgba(255, 255, 255, 0.05);
    box-shadow: 0 0 0 4px rgba(54, 153, 255, 0.15); /* Sleek focus ring */
}

.input-wrapper input:focus+i {
    color: var(--primary);
}

/* Fix Autofill changing input background to white */
.input-wrapper input:-webkit-autofill,
.input-wrapper input:-webkit-autofill:hover, 
.input-wrapper input:-webkit-autofill:focus, 
.input-wrapper input:-webkit-autofill:active {
    -webkit-box-shadow: 0 0 0 30px var(--input-bg) inset !important;
    -webkit-text-fill-color: var(--text-primary) !important;
    transition: background-color 5000s ease-in-out 0s;
}

.input-wrapper .toggle-password {
    position: absolute;
    right: 18px;
    left: auto !important;
    cursor: pointer;
    color: var(--text-secondary);
    font-size: 1.1rem;
    transition: color 0.3s;
    z-index: 10;
}

.input-wrapper .toggle-password:hover {
    color: var(--text-primary);
}

/* Utils */
.flex-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 20px;
}

.remember-me {
    display: flex;
    align-items: center;
    gap: 8px;
    color: var(--text-secondary);
    font-size: 0.88rem;
    cursor: pointer;
}

.remember-me input {
    accent-color: var(--primary);
    width: 18px;
    height: 18px;
    cursor: pointer;
}

.forgot-password {
    color: var(--primary);
    font-size: 0.88rem;
    text-decoration: none;
    font-weight: 500;
    transition: color 0.3s;
}

.forgot-password:hover {
    color: var(--secondary);
    text-decoration: underline;
}

.btn-login {
    width: 100%;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    color: white;
    border: none;
    border-radius: 10px;
    padding: 13px; /* Taller login button */
    font-size: 0.95rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
}

.btn-login:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 25px -5px rgba(54, 153, 255, 0.4);
}

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

.login-footer {
    text-align: center;
    margin-top: 16px;
    color: var(--text-secondary);
    font-size: 0.85rem;
}

.login-footer a {
    color: var(--primary);
    text-decoration: none;
    font-weight: 600;
}
