/* =========================================
   ZAPPMAIL PORTAL THEME (FIXED WIDTH VERSION)
   ========================================= */

/* 1. BACKGROUND */
/* We do NOT use display:flex here to avoid breaking Roundcube's grid */
body.task-login {
    background: radial-gradient(circle at top right, #312e81 0%, #1e1b4b 40%, #0f172a 100%) !important;
    background-attachment: fixed !important;
    background-size: cover !important;
    min-height: 100vh !important;
    padding-top: 10vh !important; /* Push form down manually */
}

/* 2. HIDE SIDEBAR & EXTRA FOOTERS */
#layout-sidebar, .header-title, #login-footer, .propform header {
    display: none !important;
}

/* 3. THE LOGIN CARD (Fixed Dimensions) */
#layout-content {
    /* Force Centering */
    margin: 0 auto !important;
    float: none !important;
    
    /* FIX: Force specific width so it cannot be narrow */
    width: 100% !important;
    max-width: 420px !important;
    min-width: 320px !important; 
    
    /* Glassmorphism */
    background: rgba(255, 255, 255, 0.05) !important;
    backdrop-filter: blur(20px) !important;
    -webkit-backdrop-filter: blur(20px) !important;
    border: 1px solid rgba(255, 255, 255, 0.1) !important;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5) !important;
    border-radius: 20px !important;
    padding: 40px !important;
    
    /* Reset Position */
    position: relative !important;
    left: auto !important;
    top: auto !important;
    flex: none !important;
}

/* 4. LOGO & TEXT */
img {
    filter: brightness(0) invert(1) drop-shadow(0 0 5px rgba(255,255,255,0.5)) !important;
    max-height: 50px !important;
    margin: 0 auto 25px auto !important;
    display: block !important;
}

h2, label, .input-group-text {
    color: #f8fafc !important;
    text-shadow: 0 2px 4px rgba(0,0,0,0.5);
}

/* 5. INPUT FIELDS (Force Full Width) */
.form-group, .input-group {
    width: 100% !important;
    margin-bottom: 20px !important;
}

.form-control {
    background: rgba(0, 0, 0, 0.3) !important;
    border: 1px solid rgba(255, 255, 255, 0.15) !important;
    color: white !important;
    border-radius: 10px !important;
    height: 45px !important;
}
.form-control:focus {
    background: rgba(0, 0, 0, 0.5) !important;
    border-color: #6366f1 !important;
    color: white !important;
    box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.3) !important;
}

/* 6. BUTTON */
.btn-primary {
    background: linear-gradient(135deg, #4f46e5 0%, #4338ca 100%) !important;
    border: none !important;
    border-radius: 10px !important;
    font-weight: 700 !important;
    text-transform: uppercase !important;
    letter-spacing: 1px !important;
    height: 45px !important;
    width: 100% !important;
    display: block !important;
    margin-top: 10px !important;
}

/* 7. ALERTS */
.alert {
    background: rgba(239, 68, 68, 0.2) !important;
    border: 1px solid rgba(239, 68, 68, 0.5) !important;
    color: #fca5a5 !important;
    border-radius: 12px !important;
}
