body { font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif; background-color: #f0f2f5; display: flex; flex-direction: column; align-items: center; margin: 0; padding: 20px; color: #333; }
.main-container { width: 100%; max-width: 900px; }
.login-wrapper { width: 100%; max-width: 450px; }
header { display: flex; justify-content: space-between; align-items: center; width: 100%; margin-bottom: 20px; }
header h1 { margin: 0; color: #2c3e50; }
.header-buttons { display: flex; gap: 10px; align-items: center; }
.container { background-color: #fff; padding: 30px; border-radius: 8px; box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1); width: 100%; margin-bottom: 20px; box-sizing: border-box; }
h1, h2, h3 { color: #2c3e50; text-align: center; margin-top: 0; margin-bottom: 20px; }
h3 { font-size: 1.2em; border-bottom: 1px solid #eee; padding-bottom: 10px; }
form label { display: block; margin-bottom: 8px; font-weight: bold; color: #555; }
form input[type="text"], form input[type="number"], form input[type="date"], form input[type="email"], form input[type="password"] { width: 100%; padding: 10px; margin-bottom: 15px; border: 1px solid #ccc; border-radius: 4px; box-sizing: border-box; }

/* --- Refactored Button Styles --- */
.btn, .button-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 10px 15px;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 16px;
    font-family: inherit;
    text-decoration: none;
    text-align: center;
    white-space: nowrap;
    transition: background-color 0.3s ease;
    box-sizing: border-box;
}

.btn-full-width { width: 100%; }
.btn-auto-width { width: auto; }

.btn-primary { background-color: #3498db; color: white; }
.btn-primary:hover { background-color: #2980b9; }
.btn-primary:disabled { background-color: #bdc3c7; cursor: not-allowed; }

.btn-danger { background-color: #e74c3c; color: white; }
.btn-danger:hover { background-color: #c0392b; }

.btn-warning { background-color: #f39c12; color: white; }
.btn-warning:hover { background-color: #e67e22; }

.btn-success { background-color: #27ae60; color: white; }
.btn-success:hover { background-color: #229954; }

.btn-secondary { background-color: #95a5a6; color: white; }
.btn-secondary:hover { background-color: #7f8c8d; }

.btn-small { font-size: 12px; padding: 5px 10px; }

/* --- End Refactored Button Styles --- */

p.error { color: #e74c3c; text-align: center; margin-top: 10px; }
p.message { color: #27ae60; text-align: center; margin-top: 10px; }
#searchInput, #userSearchInput { width: 100%; padding: 10px; margin-bottom: 20px; border: 1px solid #ccc; border-radius: 4px; box-sizing: border-box; }
.table-container { max-height: 400px; overflow-y: auto; border: 1px solid #ddd; border-radius: 4px; }
table { width: 100%; border-collapse: collapse; }
th, td { padding: 12px 15px; text-align: left; border-bottom: 1px solid #ddd; white-space: nowrap; }
th { background-color: #f4f6f8; position: sticky; top: 0; }
tbody tr:nth-child(even) { background-color: #f9f9f9; }
.actions-cell button { margin-right: 5px; }
.modal { display: none; position: fixed; z-index: 1; left: 0; top: 0; width: 100%; height: 100%; overflow: auto; background-color: rgba(0,0,0,0.4); }
.modal-content { background-color: #fefefe; margin: 10% auto; padding: 20px; border: 1px solid #888; width: 80%; max-width: 500px; border-radius: 8px; }
.close-btn { color: #aaa; float: right; font-size: 28px; font-weight: bold; cursor: pointer; }
.password-wrapper { position: relative; }
.toggle-password { position: absolute; top: 35%; right: 10px; transform: translateY(-50%); cursor: pointer; color: #aaa; }
#password-requirements { background-color: #f9f9f9; border: 1px solid #eee; border-radius: 4px; padding: 15px; margin-top: -10px; margin-bottom: 15px; font-size: 14px; }
#password-requirements.hidden { display: none; }
#password-requirements ul { list-style-type: none; padding: 0; margin: 0; }
#password-requirements li { margin-bottom: 5px; color: #e74c3c; }
#password-requirements li.valid { color: #27ae60; }
#password-requirements li::before { font-family: "Font Awesome 5 Free"; font-weight: 900; margin-right: 10px; }
#password-requirements li::before { content: "\f00d"; /* fa-times (cross) */ }
#password-requirements li.valid::before { content: "\f00c"; /* fa-check */ }
#userList, #invitationList, #currentCollaboratorList { list-style-type: none; padding: 0; max-height: 150px; overflow-y: auto; border: 1px solid #eee; border-radius: 4px; }
#userList li, #invitationList li, #currentCollaboratorList li { display: flex; justify-content: space-between; align-items: center; padding: 8px; border-bottom: 1px solid #eee; }
.invitation-actions button, .collaborator-actions button { width: auto; font-size: 12px; padding: 5px 10px; }
.hidden { display: none; }
