@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@300;400;600;700&display=swap');

:root {
    --primary: #2563eb;
    --primary-glow: rgba(37, 99, 235, 0.4);
    --accent: #0ea5e9;
    --bg-dark: #0a0c10;
    --bg-card: rgba(15, 18, 26, 0.85);
    --glass-border: rgba(255, 255, 255, 0.08);
    --text-main: #f8fafc;
    --text-dim: #94a3b8;
    --error: #ef4444;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    -webkit-tap-highlight-color: transparent;
}

body {
    background: var(--bg-dark);
    background-image:
        radial-gradient(at 0% 0%, rgba(37, 99, 235, 0.15) 0px, transparent 50%),
        radial-gradient(at 100% 100%, rgba(14, 165, 233, 0.1) 0px, transparent 50%);
    color: var(--text-main);
    font-family: 'Outfit', sans-serif;
    min-height: 100vh;
    overflow-x: hidden;
    overflow-y: auto;
}

.login-container {
    width: 100%;
    max-width: 400px;
    padding: 2rem;
    position: relative;
    z-index: 10;
    margin: 0 auto;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.glass-card {
    background: var(--bg-card);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid var(--glass-border);
    border-radius: 32px;
    padding: 3rem 2.5rem;
    box-shadow: 0 40px 100px -20px rgba(0, 0, 0, 0.7);
    animation: fadeIn 0.8s cubic-bezier(0.16, 1, 0.3, 1);
    position: relative;
}

.settings-trigger {
    position: absolute;
    top: 1.5rem;
    right: 1.5rem;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid var(--glass-border);
    border-radius: 12px;
    padding: 10px;
    color: var(--text-dim);
    cursor: pointer;
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 100;
}

.settings-trigger:hover {
    background: rgba(255, 255, 255, 0.1);
    color: var(--text-main);
    transform: rotate(90deg) scale(1.1);
    border-color: rgba(255, 255, 255, 0.2);
}

.logo-section {
    text-align: center;
    margin-bottom: 3rem;
}

.logo-icon {
    width: 64px;
    height: 64px;
    background: linear-gradient(135deg, var(--primary), var(--accent));
    border-radius: 18px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 1rem;
    box-shadow: 0 8px 30px var(--primary-glow);
    transition: all 0.6s cubic-bezier(0.16, 1, 0.3, 1);
}

.logo-icon.custom-logo {
    width: 100%;
    height: auto;
    max-height: 180px;
    background: transparent !important;
    box-shadow: none !important;
    border-radius: 0;
    margin-bottom: 2.5rem;
}

.logo-icon.custom-logo img {
    max-height: 140px;
    max-width: 100%;
    width: auto;
    object-fit: contain;
    filter: drop-shadow(0 10px 25px rgba(0, 0, 0, 0.5));
}

h1 {
    font-size: 1.75rem;
    font-weight: 700;
    letter-spacing: -0.03em;
    margin-bottom: 0.5rem;
    background: linear-gradient(to bottom, #fff, #94a3b8);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

p.subtitle {
    color: var(--text-dim);
    font-size: 0.875rem;
    letter-spacing: 0.02em;
}

.input-group {
    margin-bottom: 1.75rem;
    position: relative;
}

.input-group label {
    display: block;
    margin-bottom: 0.6rem;
    font-size: 0.7rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--text-dim);
}

.field-wrap {
    position: relative;
}

.input-group input {
    width: 100%;
    background: rgba(0, 0, 0, 0.3);
    border: 1px solid var(--glass-border);
    border-radius: 14px;
    padding: 0.85rem 1.25rem;
    color: white;
    font-size: 1rem;
    transition: all 0.3s ease;
    padding-right: 3rem;
    /* Space for the eye icon */
}

.input-group input:focus {
    outline: none;
    border-color: var(--primary);
    background: rgba(0, 0, 0, 0.4);
    box-shadow: 0 0 0 4px var(--primary-glow);
}

.password-toggle {
    position: absolute;
    right: 0.85rem;
    top: 50%;
    transform: translateY(-50%);
    background: transparent;
    border: none;
    color: var(--text-dim);
    cursor: pointer;
    padding: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    border-radius: 8px;
}

.password-toggle:hover {
    color: var(--primary);
    background: rgba(255, 255, 255, 0.05);
}

.btn-primary {
    width: 100%;
    background: linear-gradient(135deg, var(--primary), var(--accent));
    color: white;
    border: none;
    padding: 1.1rem;
    border-radius: 14px;
    font-size: 1rem;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
    margin-top: 1rem;
    box-shadow: 0 10px 25px -5px var(--primary-glow);
}

.btn-primary:hover {
    transform: translateY(-3px) scale(1.02);
    box-shadow: 0 20px 40px -10px var(--primary-glow);
}

.btn-primary:active {
    transform: translateY(0) scale(1);
}

.feedback-toast {
    position: fixed;
    bottom: 2rem;
    left: 50%;
    transform: translateX(-50%) translateY(100px);
    background: rgba(16, 185, 129, 0.9);
    backdrop-filter: blur(10px);
    color: white;
    padding: 1rem 2rem;
    border-radius: 100px;
    font-size: 0.875rem;
    font-weight: 600;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.4);
    transition: all 0.5s cubic-bezier(0.16, 1, 0.3, 1);
    z-index: 2000;
    opacity: 0;
}

.feedback-toast.show {
    transform: translateX(-50%) translateY(0);
    opacity: 1;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(30px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@media (max-width: 480px) {
    .login-container {
        padding: 1.5rem;
    }

    .glass-card {
        padding: 2.5rem 2rem;
    }
}