/**
 * Authentication Page Styles
 * Login Page - Modern Light Style - FULLY RESPONSIVE
 */

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

html, body {
    max-width: 100%;
    overflow-x: hidden;
    height: 100%;
}

body {
    font-family: 'Inter', sans-serif;
    background: linear-gradient(135deg, #f0f9ff 0%, #e0e7ff 100%);
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    padding: 1rem;
}

/* Animated Background */
body::before {
    content: '';
    position: fixed;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(99, 102, 241, 0.05) 1px, transparent 1px);
    background-size: 50px 50px;
    animation: moveBackground 20s linear infinite;
    z-index: 0;
    pointer-events: none;
}

@keyframes moveBackground {
    0% {
        transform: translate(0, 0);
    }
    100% {
        transform: translate(50px, 50px);
    }
}

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

.login-box {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(20px);
    border: 1px solid rgba(99, 102, 241, 0.2);
    border-radius: 20px;
    padding: 3rem;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.08),
                0 0 40px rgba(99, 102, 241, 0.1);
    width: 100%;
}

.logo-section {
    text-align: center;
    margin-bottom: 2.5rem;
}

.logo-icon {
    width: 120px;
    height: 120px;
    margin: 0 auto 1.5rem;
    background: #ffffff;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 3rem;
    color: white;
    box-shadow: 0 8px 25px rgba(99, 102, 241, 0.3);
    animation: logoFloat 3s ease-in-out infinite;
    border: 3px solid #6366f1;
    padding: 0.75rem;
    overflow: hidden;
}

/* CSS untuk logo sekolah (image) */
.school-logo {
    width: 80%;
    height: 80%;
    object-fit: contain;
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.1));
}

/* CSS untuk icon fontawesome (fallback) */
.logo-icon i {
    background: linear-gradient(135deg, #6366f1, #8b5cf6);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

@keyframes logoFloat {
    0%, 100% {
        transform: translateY(0);
    }
    50% {
        transform: translateY(-10px);
    }
}

.logo-section h1 {
    font-size: 1.5rem;
    font-weight: 700;
    color: #1e293b;
    margin-bottom: 0.5rem;
    word-wrap: break-word;
}

.school-name {
    color: #475569;
    font-size: 1rem;
    font-weight: 500;
}

.alert {
    padding: 1rem 1.25rem;
    border-radius: 10px;
    margin-bottom: 1.5rem;
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
    font-size: 0.875rem;
    animation: slideDown 0.3s ease-out;
    word-wrap: break-word;
}

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.alert i {
    flex-shrink: 0;
    margin-top: 2px;
}

.alert-error {
    background: rgba(239, 68, 68, 0.1);
    border: 1px solid #ef4444;
    color: #dc2626;
}

.login-form .form-group {
    margin-bottom: 1.5rem;
}

.login-form label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 500;
    color: #1e293b;
    font-size: 0.875rem;
}

.login-form label i {
    color: #6366f1;
    margin-right: 0.5rem;
}

.login-form input {
    width: 100%;
    padding: 0.875rem 1rem;
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 10px;
    color: #1e293b;
    font-size: 0.875rem;
    transition: all 0.3s ease;
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
}

.login-form input:focus {
    outline: none;
    border-color: #6366f1;
    box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.1),
                0 0 20px rgba(99, 102, 241, 0.15);
}

.login-form input::placeholder {
    color: #94a3b8;
}

.btn-login {
    width: 100%;
    padding: 1rem;
    background: linear-gradient(135deg, #6366f1, #8b5cf6);
    border: none;
    border-radius: 10px;
    color: white;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(99, 102, 241, 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.2), transparent);
    transition: left 0.5s ease;
}

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

.btn-login:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(99, 102, 241, 0.4);
}

.btn-login:active {
    transform: translateY(0);
}

.info-box {
    margin-top: 2rem;
    padding: 1rem;
    background: rgba(59, 130, 246, 0.08);
    border: 1px solid rgba(59, 130, 246, 0.2);
    border-radius: 10px;
    text-align: center;
}

.info-box p {
    margin: 0.5rem 0;
    font-size: 0.8125rem;
    color: #475569;
    word-wrap: break-word;
}

.info-box strong {
    color: #3b82f6;
}

.copyright {
    text-align: center;
    margin-top: 2rem;
    color: #64748b;
    font-size: 0.875rem;
    word-wrap: break-word;
}

/* Responsive - Tablet */
@media (max-width: 768px) {
    body {
        padding: 1rem;
    }

    .login-box {
        padding: 2.5rem 1.5rem;
    }

    .logo-icon {
        width: 100px;
        height: 100px;
        padding: 0.625rem;
    }
    
    .school-logo {
        width: 75%;
        height: 75%;
    }

    .logo-section h1 {
        font-size: 1.375rem;
    }

    .school-name {
        font-size: 0.9375rem;
    }
}

/* Responsive - Mobile */
@media (max-width: 480px) {
    body {
        padding: 0.75rem;
    }

    .login-container {
        max-width: 100%;
    }
    
    .login-box {
        padding: 2rem 1.5rem;
        border-radius: 16px;
    }
    
    .logo-icon {
        width: 90px;
        height: 90px;
        padding: 0.5rem;
        margin-bottom: 1rem;
    }
    
    .school-logo {
        width: 70%;
        height: 70%;
    }
    
    .logo-section {
        margin-bottom: 2rem;
    }
    
    .logo-section h1 {
        font-size: 1.25rem;
        line-height: 1.4;
    }
    
    .school-name {
        font-size: 0.875rem;
    }

    .alert {
        padding: 0.875rem 1rem;
        font-size: 0.8125rem;
        gap: 0.625rem;
    }

    .login-form .form-group {
        margin-bottom: 1.25rem;
    }

    .login-form label {
        font-size: 0.8125rem;
        margin-bottom: 0.375rem;
    }

    .login-form input {
        padding: 0.75rem 0.875rem;
        font-size: 0.875rem;
        border-radius: 8px;
    }

    .btn-login {
        padding: 0.875rem 1rem;
        font-size: 0.9375rem;
        border-radius: 8px;
    }

    .info-box {
        padding: 0.875rem;
        margin-top: 1.5rem;
    }

    .info-box p {
        font-size: 0.75rem;
        margin: 0.375rem 0;
    }

    .copyright {
        font-size: 0.8125rem;
        margin-top: 1.5rem;
    }
}

/* Responsive - Very Small Mobile */
@media (max-width: 360px) {
    .login-box {
        padding: 1.75rem 1.25rem;
    }

    .logo-icon {
        width: 80px;
        height: 80px;
        padding: 0.375rem;
    }
    
    .school-logo {
        width: 65%;
        height: 65%;
    }

    .logo-section h1 {
        font-size: 1.125rem;
    }

    .school-name {
        font-size: 0.8125rem;
    }

    .login-form input {
        font-size: 0.8125rem;
        padding: 0.625rem 0.75rem;
    }

    .btn-login {
        font-size: 0.875rem;
    }

    .info-box p {
        font-size: 0.6875rem;
    }
}
