* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    overflow-x: hidden;
    width: 100%;
}

:root {
    --bg-primary: #ffffff;
    --bg-secondary: #f8f9fa;
    --bg-card: #ffffff;
    --accent: #02a75a;
    --accent-dark: #018a4a;
    --accent-hover: #03c468;
    --text-primary: #212529;
    --text-secondary: #848787;
    --border: #dee2e6;
    --border-light: #ced4da;
    --error: #dc3545;
    --success: #02a75a;
    --shadow-sm: rgba(0, 0, 0, 0.075);
    --shadow-lg: rgba(0, 0, 0, 0.15);
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    background: var(--bg-primary);
    color: var(--text-primary);
    min-height: 100vh;
    width: 100%;
    max-width: 100vw;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    position: relative;
    overflow-x: hidden;
}

body::before {
    content: '';
    position: fixed;
    top: -50%;
    right: -20%;
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, rgba(2, 167, 90, 0.04) 0%, transparent 70%);
    border-radius: 50%;
    animation: float 20s ease-in-out infinite;
    pointer-events: none;
}

body::after {
    content: '';
    position: fixed;
    bottom: -30%;
    left: -10%;
    width: 500px;
    height: 500px;
    background: radial-gradient(circle, rgba(2, 167, 90, 0.03) 0%, transparent 70%);
    border-radius: 50%;
    animation: float 15s ease-in-out infinite reverse;
    pointer-events: none;
}

@keyframes float {
    0%, 100% {
        transform: translate(0, 0) scale(1);
    }
    50% {
        transform: translate(-50px, 50px) scale(1.1);
    }
}

.container {
    position: relative;
    z-index: 1;
    width: 100%;
    max-width: 440px;
    margin: 0 auto;
}

.login-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 20px;
    padding: 48px 40px;
    box-shadow: 0 20px 60px var(--shadow-lg), 0 0 1px rgba(2, 167, 90, 0.1);
    backdrop-filter: blur(20px);
    animation: slideUp 0.6s ease-out;
    position: relative;
}

.login-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent, var(--accent), transparent);
    opacity: 0.3;
    border-radius: 20px 20px 0 0;
}

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.logo {
    text-align: center;
    margin-bottom: 32px;
}

.logo-img {
    width: 150px;
    height: auto;
    margin: 0 auto 20px;
    display: block;
}

.logo h1 {
    font-size: 28px;
    font-weight: 700;
    color: var(--accent);
    margin-bottom: 8px;
    letter-spacing: -0.5px;
    text-shadow: none;
}

.logo p {
    color: var(--text-secondary);
    font-size: 14px;
    font-weight: 400;
    letter-spacing: -0.1px;
}

.error-message {
    background: rgba(220, 53, 69, 0.1);
    border: 1px solid rgba(220, 53, 69, 0.25);
    border-radius: 12px;
    padding: 14px 18px;
    margin-bottom: 24px;
    font-size: 14px;
    color: var(--error);
    animation: shake 0.4s ease-in-out;
    font-weight: 500;
}

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

.form-group {
    margin-bottom: 24px;
}

label {
    display: block;
    font-size: 13px;
    font-weight: 600;
    color: var(--text-secondary);
    margin-bottom: 10px;
    transition: color 0.2s ease;
    letter-spacing: 0.3px;
    text-transform: uppercase;
}

.input-wrapper {
    position: relative;
}

input {
    width: 100%;
    padding: 15px 18px;
    background: var(--bg-secondary);
    border: 1.5px solid var(--border);
    border-radius: 12px;
    font-size: 15px;
    color: var(--text-primary);
    font-family: inherit;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    outline: none;
    font-weight: 500;
}

input:hover {
    border-color: var(--border-light);
}

input:focus {
    border-color: var(--accent);
    background: var(--bg-card);
    box-shadow: 0 0 0 4px rgba(2, 167, 90, 0.1);
    transform: translateY(-1px);
}

.form-group:focus-within label {
    color: var(--accent);
}

input::placeholder {
    color: var(--text-secondary);
    opacity: 0.4;
    font-weight: 400;
}

input.invalid {
    border-color: var(--error);
    animation: shake 0.4s ease-in-out;
}

.input-error {
    color: var(--error);
    font-size: 12px;
    margin-top: 6px;
    font-weight: 500;
    opacity: 0;
    transform: translateY(-5px);
    transition: all 0.3s ease;
}

.input-error.show {
    opacity: 1;
    transform: translateY(0);
}

.btn {
    width: 100%;
    padding: 16px;
    background: var(--accent);
    border: none;
    border-radius: 12px;
    font-size: 15px;
    font-weight: 600;
    color: #ffffff;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
    box-shadow: 0 4px 16px rgba(2, 167, 90, 0.2);
    letter-spacing: 0.3px;
    margin-top: 8px;
}

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

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

.btn:hover {
    transform: translateY(-2px);
    background: var(--accent-hover);
    box-shadow: 0 8px 24px rgba(2, 167, 90, 0.3);
}

.btn:active {
    transform: translateY(0);
    box-shadow: 0 2px 8px rgba(2, 167, 90, 0.25);
}

.divider {
    text-align: center;
    margin: 32px 0;
    position: relative;
}

.divider::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 0;
    right: 0;
    height: 1px;
    background: var(--border);
}

.divider span {
    background: var(--bg-card);
    padding: 0 20px;
    color: var(--text-secondary);
    font-size: 12px;
    position: relative;
    letter-spacing: 0.5px;
    text-transform: uppercase;
    font-weight: 600;
}

.register-link {
    text-align: center;
    margin-top: 28px;
}

.register-link p {
    color: var(--text-secondary);
    font-size: 14px;
    font-weight: 500;
}

.register-link a {
    color: var(--accent);
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    letter-spacing: 0.2px;
}

.register-link a::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--accent);
    transition: width 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.register-link a:hover::after {
    width: 100%;
}

.register-link a:hover {
    color: var(--accent-hover);
    text-shadow: none;
}

@media (max-width: 480px) {
    body {
        padding: 15px;
    }

    .login-card {
        padding: 36px 24px;
        width: 100%;
    }

    .logo h1 {
        font-size: 24px;
    }

    body::before,
    body::after {
        width: 400px;
        height: 400px;
    }
}

