* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    background: linear-gradient(135deg, #2c3e50 0%, #4a5568 50%, #2d3748 100%);
    min-height: 100vh;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    position: relative;
    overflow-x: hidden;
}

/* Main layout */
.page-container {
    min-height: 100vh;
    display: flex;
    position: relative;
}

.page-container::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: url("data:image/svg+xml,%3Csvg width='100' height='100' viewBox='0 0 100 100' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M11 18c3.866 0 7-3.134 7-7s-3.134-7-7-7-7 3.134-7 7 3.134 7 7 7zm48 25c3.866 0 7-3.134 7-7s-3.134-7-7-7-7 3.134-7 7 3.134 7 7 7zm-43-7c1.657 0 3-1.343 3-3s-1.343-3-3-3-3 1.343-3 3 1.343 3 3 3zm63 31c1.657 0 3-1.343 3-3s-1.343-3-3-3-3 1.343-3 3 1.343 3 3 3zM34 90c1.657 0 3-1.343 3-3s-1.343-3-3-3-3 1.343-3 3 1.343 3 3 3zm56-76c1.657 0 3-1.343 3-3s-1.343-3-3-3-3 1.343-3 3 1.343 3 3 3zM12 86c2.21 0 4-1.79 4-4s-1.79-4-4-4-4 1.79-4 4 1.79 4 4 4zm28-65c2.21 0 4-1.79 4-4s-1.79-4-4-4-4 1.79-4 4 1.79 4 4 4zm23-11c2.76 0 5-2.24 5-5s-2.24-5-5-5-5 2.24-5 5 2.24 5 5 5zm-6 60c2.21 0 4-1.79 4-4s-1.79-4-4-4-4 1.79-4 4 1.79 4 4 4zm29 22c2.76 0 5-2.24 5-5s-2.24-5-5-5-5 2.24-5 5 2.24 5 5 5zM32 63c2.76 0 5-2.24 5-5s-2.24-5-5-5-5 2.24-5 5 2.24 5 5 5zm57-13c2.76 0 5-2.24 5-5s-2.24-5-5-5-5 2.24-5 5 2.24 5 5 5zm-9-21c1.105 0 2-.895 2-2s-.895-2-2-2-2 .895-2 2 .895 2 2 2zM60 91c1.105 0 2-.895 2-2s-.895-2-2-2-2 .895-2 2 .895 2 2 2zM35 41c1.105 0 2-.895 2-2s-.895-2-2-2-2 .895-2 2 .895 2 2 2zM12 60c1.105 0 2-.895 2-2s-.895-2-2-2-2 .895-2 2 .895 2 2 2z' fill='%23ffffff' fill-opacity='0.03' fill-rule='evenodd'/%3E%3C/svg%3E");
    z-index: 0;
}

/* Login side */
.login-wrapper {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2rem;
    position: relative;
    z-index: 1;
    flex: 1;
    background: linear-gradient(135deg, rgba(74, 85, 104, 0.3), rgba(45, 55, 72, 0.3));
}

.login-container {
    background: rgba(255, 255, 255, 0.07);
    backdrop-filter: blur(20px);
    border-radius: 24px;
    border: 1px solid rgba(255, 255, 255, 0.15);
    box-shadow: 
        0 20px 40px rgba(0, 0, 0, 0.2),
        0 0 0 1px rgba(255, 255, 255, 0.15) inset;
    width: 100%;
    max-width: 420px;
    padding: 3rem 2.5rem;
    position: relative;
    animation: slideUp 0.8s ease-out;
}

/* Branding side */
.branding-side {
    background: linear-gradient(135deg, #4a5568 0%, #2d3748 100%);
    padding: 4rem;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    overflow: hidden;
    flex: 1;
    z-index: 1;
}

.branding-side::before,
.branding-side::after {
    content: '';
    position: absolute;
    border-radius: 50%;
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.1), rgba(255, 255, 255, 0.05));
}

.branding-side::before {
    width: 400px;
    height: 400px;
    top: -150px;
    right: -100px;
    opacity: 0.5;
}

.branding-side::after {
    width: 350px;
    height: 350px;
    bottom: -100px;
    left: -50px;
    opacity: 0.4;
}

.branding-content {
    position: relative;
    z-index: 1;
    color: white;
    text-align: center;
    max-width: 600px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    height: 100%;
}

.branding-content h1 {
    font-size: 2.8rem;
    font-weight: 700;
    margin-bottom: 1.5rem;
    background: linear-gradient(to right, #ffffff, #e2e8f0);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.branding-content .lead {
    font-size: 1.2rem;
    opacity: 0.9;
    margin-bottom: 0;
    max-width: 80%;
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1.5rem;
    margin-top: 3rem;
}

.feature-item {
    background: rgba(255, 255, 255, 0.08);
    border-radius: 16px;
    padding: 1.5rem;
    text-align: left;
    border: 1px solid rgba(255, 255, 255, 0.15);
    transition: all 0.3s ease;
}

.feature-item:hover {
    transform: translateY(-5px);
    background: rgba(255, 255, 255, 0.12);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
}

.feature-item h3 {
    font-size: 1.1rem;
    margin-bottom: 0.5rem;
    color: white;
}

.feature-item p {
    font-size: 0.9rem;
    opacity: 0.8;
    margin: 0;
}

/* Logo */
.logo-container {
    width: 180px;
    height: 100px;
    background: linear-gradient(135deg, rgba(240, 240, 240, 0.9), rgba(230, 230, 230, 0.8));
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 1px solid rgba(255, 255, 255, 0.2);
    animation: pulse 2s ease-in-out infinite;
    margin-bottom: 2rem;
}

.logo-container img {
    width: 100%;
    height: 100%;
    object-fit: fill;
    border-radius: 10px;
}

/* Login form styles */
.login-header {
    text-align: center;
    margin-bottom: 2.5rem;
}

.login-header h2 {
    color: white;
    font-weight: 700;
    margin-bottom: 0.5rem;
    font-size: 1.8rem;
}

.login-header p {
    color: rgba(255, 255, 255, 0.8);
    font-size: 0.95rem;
}

.form-group {
    position: relative;
    margin-bottom: 1.5rem;
    animation: fadeInUp 0.6s ease-out;
    animation-fill-mode: both;
}

.form-control {
    background: rgba(255, 255, 255, 0.05);
    border: 2px solid rgba(255, 255, 255, 0.1);
    border-radius: 16px;
    padding: 1rem 1rem 1rem 3rem;
    color: white;
    font-size: 1rem;
    height: 60px;
    transition: all 0.3s ease;
    width: 100%;
}

.form-control:focus {
    background: rgba(255, 255, 255, 0.1);
    border-color: rgba(255, 255, 255, 0.3);
    box-shadow: 0 0 0 4px rgba(255, 255, 255, 0.1);
    outline: none;
}

.form-control::placeholder {
    color: rgba(255, 255, 255, 0.5);
}

.input-icon {
    position: absolute;
    left: 1rem;
    top: 50%;
    transform: translateY(-50%);
    color: rgba(255, 255, 255, 0.7);
    font-size: 1.1rem;
    z-index: 2;
    transition: all 0.3s ease;
}

.form-group:focus-within .input-icon {
    color: white;
}

.btn-login {
    width: 100%;
    padding: 1rem;
    border: none;
    border-radius: 16px;
    background: linear-gradient(135deg, #4a5568, #2d3748);
    color: white;
    font-weight: 600;
    font-size: 1.1rem;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
    margin-top: 1rem;
    animation: fadeInUp 0.6s ease-out 0.3s both;
}

.btn-login:hover {
    color: #cccccc;
    background: linear-gradient(135deg, #2d3748, #1a202c);
    transform: translateY(-2px);
    box-shadow: 0 10px 20px rgba(45, 55, 72, 0.3);
}

.btn-login:active {
    transform: translateY(-1px);
}

.btn-login:disabled {
    opacity: 0.7;
    transform: none;
    cursor: not-allowed;
}

/* Copyright */
.copyright {
    position: fixed;
    bottom: 1rem;
    left: 50%;
    transform: translateX(-50%);
    color: rgba(255, 255, 255, 0.6);
    font-size: 0.85rem;
    text-align: center;
    z-index: 10;
}

/* Toast styles */
.toast-container {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 1050;
}

.toast {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    border: none;
    border-radius: 12px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
}

.toast-success {
    border-left: 4px solid #28a745;
}

.toast-error {
    border-left: 4px solid #dc3545;
}

/* Animations */
@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes pulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.05); }
}

/* Responsive design */
@media (max-width: 768px) {
    .page-container {
        flex-direction: column;
    }

    .login-wrapper {
        min-height: 100vh;
    }

    .branding-side {
        display: none;
    }

    .login-container {
        padding: 2rem 1.5rem;
    }

    .copyright {
        position: relative;
        margin-top: 2rem;
        padding: 1rem;
    }
}

@media (max-width: 480px) {
    .login-container {
        padding: 1.5rem 1rem;
    }

    .form-control {
        height: 55px;
        padding: 0.8rem 0.8rem 0.8rem 2.5rem;
    }

    .btn-login {
        padding: 0.9rem;
        font-size: 1rem;
    }
}

/* Back to Home Button */
.back-home-btn {
    position: fixed;
    top: 20px;
    left: 20px;
    color: rgba(255, 255, 255, 0.8);
    font-size: 1.5rem;
    text-decoration: none;
    transition: all 0.3s ease;
    z-index: 1050;
    display: flex;
    align-items: center;
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(5px);
    border-radius: 50px;
    padding: 8px 12px;
    border: 1px solid rgba(255, 255, 255, 0.2);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

.back-home-btn i {
    transition: transform 0.3s ease;
}

.back-home-btn:hover {
    color: #3498db;
    background: rgba(255, 255, 255, 0.2);
}

.back-home-btn:hover i {
    transform: translateX(-5px);
}

/* Tooltip for back button */
.back-tooltip {
    margin-left: 10px;
    font-size: 0.9rem;
    color: rgba(255, 255, 255, 0.9);
    transition: all 0.3s ease;
}

.back-home-btn:hover .back-tooltip {
    color: white;
}

/* Add responsive styles for the back button */
@media (max-width: 768px) {
    .back-home-btn {
        top: 15px;
        left: 15px;
        font-size: 1.3rem;
    }
}

@media (max-width: 480px) {
    .back-tooltip {
        display: none;
    }
    
    .back-home-btn {
        padding: 6px;
    }
}

/* Add floating particles */
@keyframes float {
    0% { transform: translateY(0px) rotate(0deg); }
    50% { transform: translateY(-20px) rotate(5deg); }
    100% { transform: translateY(0px) rotate(0deg); }
}

.particle {
    position: absolute;
    width: 80px;
    height: 80px;
    border-radius: 50%;
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.1), rgba(255, 255, 255, 0.05));
    z-index: 0;
    transition: transform 0.3s ease-out;
    will-change: transform;
}

.particle:nth-child(1) {
    top: 10%;
    left: 10%;
    width: 60px;
    height: 60px;
}

.particle:nth-child(2) {
    top: 60%;
    /* left: 80%; */
    width: 100px;
    height: 100px;
}

.particle:nth-child(3) {
    top: 80%;
    left: 20%;
    width: 40px;
    height: 40px;
}

.particle:nth-child(4) {
    top: 30%;
    left: 70%;
    width: 50px;
    height: 50px;
}

.particle:nth-child(5) {
    top: 50%;
    left: 30%;
    width: 70px;
    height: 70px;
}

.register-link {
    color: #3498db;
    text-decoration: none;
    font-weight: 600;
}

.register-link:hover {
    color: #2980b9;
    text-decoration: underline;
}