* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: "Poppins", sans-serif;
    min-height: 100vh;
    background: linear-gradient(135deg, #0d7c8a 0%, #1fa3b7 50%, #4dd4e8 100%);
    overflow-x: hidden;
    position: relative;
}

/* Animated Background Elements */
.bg-animation {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    overflow: hidden;
    z-index: 0;
    pointer-events: none;
}

.floating-shape {
    position: absolute;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.1);
    animation: float 20s infinite ease-in-out;
}

.shape-1 {
    width: 300px;
    height: 300px;
    top: -100px;
    left: -100px;
    animation-delay: 0s;
}

.shape-2 {
    width: 200px;
    height: 200px;
    top: 50%;
    right: -50px;
    animation-delay: 5s;
}

.shape-3 {
    width: 150px;
    height: 150px;
    bottom: 100px;
    left: 20%;
    animation-delay: 10s;
}

.shape-4 {
    width: 250px;
    height: 250px;
    bottom: -50px;
    right: 15%;
    animation-delay: 15s;
}

@keyframes float {
    0%,
    100% {
        transform: translateY(0) rotate(0deg);
        opacity: 0.3;
    }

    50% {
        transform: translateY(-50px) rotate(180deg);
        opacity: 0.6;
    }
}

/* Main Container */
.login-container {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    position: relative;
    z-index: 1;
}

/* Login Card */
.login-card {
    background: rgba(255, 255, 255, 0.95);
    border-radius: 30px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    overflow: hidden;
    max-width: 450px;
    width: 100%;
    backdrop-filter: blur(10px);
    animation: slideUp 0.8s ease-out;
}

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(50px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Header Section */
.login-header {
    background: linear-gradient(135deg, #1fa3b7 0%, #0d7c8a 100%);
    padding: 40px 30px;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.login-header::before {
    content: "";
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(
        circle,
        rgba(255, 255, 255, 0.1) 0%,
        transparent 70%
    );
    animation: pulse 3s infinite;
}

@keyframes pulse {
    0%,
    100% {
        transform: scale(1);
        opacity: 0.5;
    }

    50% {
        transform: scale(1.1);
        opacity: 0.8;
    }
}

.logo-wrapper {
    width: 80px;
    height: 80px;
    margin: 0 auto 20px;
    background: white;
    border-radius: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
    animation: rotate 10s linear infinite;
    position: relative;
    z-index: 1;
}

@keyframes rotate {
    0%,
    100% {
        transform: rotate(0deg) scale(1);
    }

    50% {
        transform: rotate(10deg) scale(1.05);
    }
}

.logo-wrapper i {
    font-size: 40px;
    background: linear-gradient(135deg, #1fa3b7, #0d7c8a);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.login-header h1 {
    color: white;
    font-size: 28px;
    font-weight: 700;
    margin-bottom: 5px;
    position: relative;
    z-index: 1;
}

.login-header p {
    color: rgba(255, 255, 255, 0.9);
    font-size: 14px;
    margin: 0;
    position: relative;
    z-index: 1;
}

/* Form Section */
.login-body {
    padding: 40px 30px;
}

.form-label {
    color: #333;
    font-weight: 500;
    margin-bottom: 8px;
    font-size: 14px;
}

.input-group-custom {
    position: relative;
    margin-bottom: 25px;
}

.input-icon {
    position: absolute;
    left: 18px;
    top: 50%;
    transform: translateY(-50%);
    color: #1fa3b7;
    font-size: 18px;
    z-index: 2;
    margin-top: 16px;
    transition: all 0.3s ease;
}

.form-control {
    padding: 14px 20px 14px 50px;
    border: 2px solid #e0e0e0;
    border-radius: 15px;
    font-size: 15px;
    transition: all 0.3s ease;
    background: #f8f9fa;
}

.form-control:focus {
    border-color: #1fa3b7;
    box-shadow: 0 0 0 0.2rem rgba(31, 163, 183, 0.15);
    background: white;
}

.form-control:focus + .input-icon {
    color: #0d7c8a;
    transform: translateY(-50%) scale(1.1);
}

/* Password Toggle */
.password-toggle {
    position: absolute;
    right: 18px;
    top: 50%;
    transform: translateY(-50%);
    cursor: pointer;
    color: #6c757d;
    font-size: 18px;
    margin-top: 16px;
    z-index: 2;
    transition: all 0.3s ease;
}

.password-toggle:hover {
    color: #1fa3b7;
}

/* Remember Me & Forgot Password */
.form-options {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 25px;
    flex-wrap: wrap;
    gap: 10px;
}

.form-check {
    margin: 0;
}

.form-check-input {
    width: 20px;
    height: 20px;
    border: 2px solid #1fa3b7;
    cursor: pointer;
}

.form-check-input:checked {
    background-color: #1fa3b7;
    border-color: #1fa3b7;
}

.form-check-label {
    color: #666;
    font-size: 14px;
    margin-top: 5px;
    margin-left: 8px;
    cursor: pointer;
}

.forgot-link {
    color: #1fa3b7;
    text-decoration: none;
    font-size: 14px;
    font-weight: 500;
    transition: all 0.3s ease;
}

.forgot-link:hover {
    color: #0d7c8a;
    text-decoration: underline;
}

/* Login Button */
.btn-login {
    width: 100%;
    padding: 14px;
    background: linear-gradient(135deg, #1fa3b7 0%, #0d7c8a 100%);
    border: none;
    border-radius: 15px;
    color: white;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(31, 163, 183, 0.3);
}

.btn-login::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.5s;
}

.btn-login:hover::before {
    left: 100%;
}

.btn-login:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(31, 163, 183, 0.4);
}

.btn-login:active {
    transform: translateY(0);
}

/* Loading State */
.btn-login.loading {
    pointer-events: none;
    opacity: 0.8;
}

.btn-login .spinner {
    display: none;
}

.btn-login.loading .spinner {
    display: inline-block;
    margin-right: 10px;
}

/* Divider */
.divider {
    text-align: center;
    margin: 25px 0;
    position: relative;
}

.divider::before {
    content: "";
    position: absolute;
    top: 50%;
    left: 0;
    right: 0;
    height: 1px;
    background: #e0e0e0;
}

.divider span {
    background: white;
    padding: 0 15px;
    color: #999;
    font-size: 13px;
    position: relative;
    z-index: 1;
}

/* Register Link */
.register-link {
    text-align: center;
    margin-top: 25px;
    color: #666;
    font-size: 14px;
}

.register-link a {
    color: #1fa3b7;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.3s ease;
}

.register-link a:hover {
    color: #0d7c8a;
    text-decoration: underline;
}

/* Alert Messages */
.alert-custom {
    border-radius: 12px;
    border: none;
    padding: 12px 15px;
    font-size: 14px;
    margin-bottom: 20px;
    animation: slideDown 0.3s ease-out;
}

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Responsive Design */
@media (max-width: 576px) {
    .login-header {
        padding: 30px 20px;
    }

    .login-header h1 {
        font-size: 24px;
    }

    .login-body {
        padding: 30px 20px;
    }

    .logo-wrapper {
        width: 70px;
        height: 70px;
    }

    .logo-wrapper i {
        font-size: 35px;
    }

    .form-options {
        flex-direction: column;
        align-items: flex-start;
    }
}

@media (min-width: 768px) and (max-width: 991px) {
    .login-card {
        max-width: 500px;
    }
}

@media (min-width: 992px) {
    .login-card {
        max-width: 480px;
    }
}
