body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: linear-gradient(rgba(0,0,0,0.5), rgba(0,0,0,0.5)), url('../../assets1/img/Study.jpg');
    background-size: cover;
    background-position: center;
    background-attachment: fixed;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0;
    padding: 10px;
    box-sizing: border-box;
}

.login-container {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-radius: 25px;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
    overflow: hidden;
    max-width: 500px;
    width: 100%;
    max-height: 95vh;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
}

.header-section {
    background: linear-gradient(135deg, #003366 0%, #004080 100%);
    padding: clamp(1rem, 3vw, 2rem);
    text-align: center;
    color: white;
    position: relative;
    flex-shrink: 0;
}

.header-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('https://images.unsplash.com/photo-1523050854058-8df90110c9f1?ixlib=rb-4.0.3&ixid=M3wxMjA3fDB8MHxwaG90by1wYWdlfHx8fGVufDB8fHx8fA%3D%3D&auto=format&fit=crop&w=1000&q=80') center/cover;
    opacity: 0.1;
}

.header-section * {
    position: relative;
    z-index: 1;
}

.logo {
    width: clamp(60px, 15vw, 80px);
    height: clamp(60px, 15vw, 80px);
    background: white;
    border-radius: 50%;
    margin: 0 auto clamp(0.5rem, 2vw, 1rem);
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}

.logo i {
    font-size: clamp(1.5rem, 4vw, 2rem);
    color: #003366;
}

.system-title {
    font-size: clamp(1.1rem, 4vw, 1.5rem);
    font-weight: 700;
    margin: 0;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.3);
    line-height: 1.2;
}

.subtitle {
    font-size: clamp(0.75rem, 2.5vw, 0.9rem);
    opacity: 0.9;
    margin-top: 0.5rem;
    line-height: 1.3;
}

.form-section {
    padding: clamp(1rem, 4vw, 2.5rem);
    flex: 1;
    overflow-y: auto;
}

.welcome-text {
    text-align: center;
    margin-bottom: clamp(1rem, 3vw, 2rem);
    color: #333;
}

.welcome-text h3 {
    font-weight: 600;
    margin-bottom: 0.5rem;
    color: #003366;
    font-size: clamp(1rem, 3vw, 1.2rem);
    line-height: 1.3;
}

.welcome-text p {
    color: #666;
    font-size: clamp(0.8rem, 2.5vw, 0.95rem);
    line-height: 1.4;
}

.google-login-btn {
    width: 100%;
    padding: clamp(0.6rem, 2vw, 0.8rem);
    background: #fff;
    border: 2px solid #e0e0e0;
    border-radius: 15px;
    display: flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    color: #333;
    font-weight: 500;
    transition: all 0.3s ease;
    margin-bottom: 1rem;
    font-size: clamp(0.8rem, 2.5vw, 1rem);
    min-height: 44px; /* Ensure touch-friendly size */
}

.google-login-btn:hover {
    background: #f8f9fa;
    border-color: #4285f4;
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(66, 133, 244, 0.2);
    color: #333;
    text-decoration: none;
}

.google-icon {
    width: clamp(20px, 5vw, 24px);
    height: clamp(20px, 5vw, 24px);
    margin-right: 12px;
    flex-shrink: 0;
}

.alert {
    border-radius: 10px;
    border: none;
    margin-bottom: 1rem;
    padding: clamp(0.5rem, 2vw, 0.75rem);
    font-size: clamp(0.8rem, 2.5vw, 0.9rem);
}

.alert-danger {
    background: linear-gradient(135deg, #ff6b6b, #ee5a52);
    color: white;
}

.alert-success {
    background: linear-gradient(135deg, #51cf66, #40c057);
    color: white;
}

.alert-warning {
    background: linear-gradient(135deg, #f39c12, #e67e22);
    color: white;
}

.features-list {
    list-style: none;
    padding: 0;
    margin: clamp(1rem, 3vw, 1.5rem) 0;
}

.features-list li {
    display: flex;
    align-items: center;
    margin-bottom: clamp(0.5rem, 2vw, 0.8rem);
    color: #666;
    font-size: clamp(0.75rem, 2.2vw, 0.9rem);
    line-height: 1.4;
}

.features-list li i {
    color: #003366;
    margin-right: clamp(0.5rem, 2vw, 0.8rem);
    width: 20px;
    flex-shrink: 0;
    font-size: clamp(0.9rem, 2.5vw, 1rem);
}

.footer-text {
    text-align: center;
    color: #999;
    font-size: clamp(0.7rem, 2vw, 0.8rem);
    margin-top: clamp(1rem, 3vw, 1.5rem);
    line-height: 1.4;
}

.gown-decoration {
    text-align: center;
    margin: clamp(0.5rem, 2vw, 1rem) 0;
    opacity: 0.7;
}

.gown-decoration i {
    font-size: clamp(2rem, 6vw, 3rem);
    color: #003366;
    margin: 0 0.5rem;
}

/* Specific breakpoints for fine-tuning */
@media (max-width: 480px) {
    body {
        padding: 5px;
    }
    
    .login-container {
        border-radius: 20px;
        max-height: 98vh;
    }
    
    .header-section {
        border-radius: 20px 20px 0 0;
    }
}

@media (max-height: 600px) {
    .login-container {
        max-height: 100vh;
    }
    
    .header-section {
        padding: 1rem;
    }
    
    .form-section {
        padding: 1rem;
    }
    
    .logo {
        width: 50px;
        height: 50px;
        margin-bottom: 0.5rem;
    }
    
    .welcome-text {
        margin-bottom: 1rem;
    }
    
    .features-list {
        margin: 1rem 0;
    }
    
    .features-list li {
        margin-bottom: 0.5rem;
    }
    
    .footer-text {
        margin-top: 1rem;
    }
}

@media (max-height: 500px) {
    .gown-decoration {
        display: none;
    }
    
    .features-list {
        margin: 0.5rem 0;
    }
    
    .welcome-text {
        margin-bottom: 0.5rem;
    }
}

/* Ensure text is always readable */
@media (max-width: 320px) {
    .system-title {
        font-size: 1rem;
    }
    
    .subtitle {
        font-size: 0.7rem;
    }
    
    .welcome-text h3 {
        font-size: 0.9rem;
    }
    
    .welcome-text p {
        font-size: 0.75rem;
    }
}