.losada-portal {
	max-width: 900px;
	margin: 2em auto;
	font-family: inherit;
}
.losada-portal-header {
	border-bottom: 1px solid #ddd;
	margin-bottom: 1.5em;
	padding-bottom: 1em;
}
.losada-portal-role {
	color: #555;
	font-weight: 600;
}
.losada-portal-nav ul {
	list-style: none;
	margin: 0 0 2em;
	padding: 0;
	display: flex;
	flex-wrap: wrap;
	gap: 0.75em;
}
.losada-portal-nav li {
	background: #f4f4f4;
	border: 1px solid #ddd;
	border-radius: 6px;
	padding: 0.75em 1.25em;
}
.losada-portal-nav em {
	color: #888;
	font-style: normal;
	font-size: 0.85em;
	display: block;
}
.losada-portal-users {
	border-top: 1px solid #ddd;
	padding-top: 1.5em;
}
.losada-portal-add-user {
	display: flex;
	flex-wrap: wrap;
	gap: 1em;
	align-items: flex-end;
	margin-bottom: 1.5em;
}
.losada-portal-add-user label {
	display: flex;
	flex-direction: column;
	font-size: 0.9em;
	gap: 0.25em;
}
.losada-portal-add-user input,
.losada-portal-add-user select {
	padding: 0.5em;
	min-width: 200px;
}
.losada-portal-hint {
	flex-basis: 100%;
	color: #888;
	font-size: 0.85em;
	margin: 0;
}
.losada-portal-message {
	background: #eef7ee;
	border: 1px solid #b7dfb7;
	padding: 0.75em 1em;
	border-radius: 6px;
}
.losada-portal-user-table {
	width: 100%;
	border-collapse: collapse;
}
.losada-portal-user-table th,
.losada-portal-user-table td {
	text-align: left;
	padding: 0.5em 0.75em;
	border-bottom: 1px solid #eee;
}
.losada-portal-login {
	max-width: 360px;
}
.losada-portal-last-login {
	color: #888;
	font-size: 0.9em;
}
.losada-portal-tiles {
	display: flex;
	flex-wrap: wrap;
	gap: 0.75em;
	margin-bottom: 2em;
}
.losada-portal-tile {
	display: block;
	background: #305496;
	color: #fff;
	padding: 1em 1.25em;
	border-radius: 8px;
	text-decoration: none;
	font-weight: 600;
	min-width: 100px;
	text-align: center;
}
.losada-portal-tile:hover {
	background: #24406f;
	color: #fff;
}
.losada-portal-tile-disabled {
	background: #eee;
	color: #999;
	cursor: default;
}
.losada-portal-tile-disabled em {
	display: block;
	font-style: normal;
	font-weight: 400;
	font-size: 0.75em;
}
.losada-portal-calendar {
	margin-bottom: 2em;
}
.losada-portal-calendar-grid {
	width: 100%;
	border-collapse: collapse;
	max-width: 500px;
}
.losada-portal-calendar-grid th, .losada-portal-calendar-grid td {
	text-align: center;
	padding: 0.6em 0.3em;
	border: 1px solid #eee;
}
.losada-portal-calendar-grid td.is-empty {
	background: #fafafa;
	border-color: #fafafa;
}
.losada-portal-calendar-grid td.is-today {
	background: #305496;
	color: #fff;
	font-weight: 700;
	border-radius: 4px;
}
.losada-portal-calendar-grid td.has-task {
	position: relative;
}
.losada-portal-calendar-grid td.has-task::after {
	content: '';
	display: block;
	width: 6px;
	height: 6px;
	border-radius: 50%;
	background: #e6b800;
	margin: 0.2em auto 0;
}
.losada-portal-calendar-legend {
	font-size: 0.8em;
	color: #888;
}
.losada-portal-calendar-legend .has-task {
	display: inline-block;
	width: 6px;
	height: 6px;
	border-radius: 50%;
	background: #e6b800;
}
.losada-portal-tasks h3 {
	margin-bottom: 0.5em;
}
.losada-portal-task-form {
	display: flex;
	gap: 0.5em;
	margin-bottom: 1em;
	flex-wrap: wrap;
}
.losada-portal-task-form input[type="text"] {
	flex: 1 1 200px;
	padding: 0.5em;
}
.losada-portal-task-form input[type="date"] {
	padding: 0.5em;
}
.losada-portal-task-items {
	list-style: none;
	margin: 0;
	padding: 0;
}
.losada-portal-task-items li {
	display: flex;
	align-items: center;
	gap: 0.6em;
	padding: 0.4em 0;
	border-bottom: 1px solid #eee;
}
.losada-portal-task-check {
	background: none;
	border: none;
	font-size: 1.1em;
	cursor: pointer;
	padding: 0;
}
.losada-portal-task-title {
	flex: 1;
}
.losada-portal-task-title.is-done {
	text-decoration: line-through;
	color: #999;
}
.losada-portal-task-empty {
	color: #888;
	font-style: italic;
}
.losada-portal-task-completed {
	margin-top: 1em;
}
.losada-portal-task-completed summary {
	cursor: pointer;
	color: #555;
}
.losada-portal-task-assignee {
	background: #eef2fb;
	color: #305496;
	font-size: 0.8em;
	padding: 0.1em 0.5em;
	border-radius: 10px;
}
.losada-portal-task-assigned-date {
	color: #aaa;
	font-size: 0.78em;
}
.losada-portal-task-items li.is-past-due {
	background: #fdeeee;
}
.losada-portal-task-due {
	color: #888;
	font-size: 0.85em;
}
.losada-portal-task-items li.is-past-due .losada-portal-task-due {
	color: #b23;
	font-weight: 700;
}
.losada-portal-task-extension {
	flex-basis: 100%;
	background: #fff8e1;
	border-radius: 4px;
	padding: 0.4em 0.6em;
	font-size: 0.85em;
	display: flex;
	align-items: center;
	gap: 0.75em;
	flex-wrap: wrap;
}
.losada-portal-task-due-edit {
	flex-basis: 100%;
}
.losada-portal-task-due-edit summary {
	cursor: pointer;
	color: #305496;
	font-size: 0.8em;
}
.losada-portal-task-due-edit form {
	display: flex;
	gap: 0.5em;
	margin-top: 0.4em;
	align-items: center;
}
.losada-portal-task-due-edit input {
	padding: 0.3em;
}
.losada-portal-task-items li.is-completed-on-time {
	background: #eaf7ea;
}
.losada-portal-task-items li.is-completed-on-time .losada-portal-task-due {
	color: #1e7b34;
}
.losada-portal-task-items li.is-completed-late .losada-portal-task-due {
	color: #a02020;
}

/* Calendar */
.losada-portal-calendar-nav {
	display: flex;
	align-items: center;
	gap: 0.75em;
	margin-bottom: 0.5em;
}
.losada-portal-calendar-nav h3 {
	margin: 0;
	min-width: 160px;
}
.losada-portal-calendar-nav a {
	text-decoration: none;
	color: #305496;
	font-weight: 600;
}
.losada-portal-calendar-today {
	margin-left: auto;
	font-size: 0.85em;
}
.losada-portal-calendar-grid {
	width: 100%;
	border-collapse: collapse;
	table-layout: fixed;
}
.losada-portal-calendar-grid th, .losada-portal-calendar-grid td {
	text-align: left;
	vertical-align: top;
	padding: 0.4em;
	border: 1px solid #eee;
	height: 4.5em;
	font-size: 0.85em;
}
.losada-portal-calendar-grid th {
	text-align: center;
	font-size: 0.8em;
	color: #888;
}
.losada-portal-calendar-grid td.is-empty {
	background: #fafafa;
	border-color: #fafafa;
}
.losada-portal-calendar-grid td.is-weekend {
	background: #f4f6fb;
}
.losada-portal-calendar-grid td.is-holiday {
	background: #fdeeee;
}
.losada-portal-calendar-grid td.is-today {
	outline: 2px solid #305496;
	outline-offset: -2px;
}
.losada-portal-cal-daynum {
	font-weight: 700;
	color: inherit;
	text-decoration: none;
}
.losada-portal-cal-holiday-name {
	display: block;
	font-size: 0.75em;
	color: #b23;
}
.losada-portal-calendar-grid td.has-task .losada-portal-cal-daynum::after {
	content: '';
	display: inline-block;
	width: 5px;
	height: 5px;
	border-radius: 50%;
	background: #e6b800;
	margin-left: 4px;
}
.losada-portal-cal-event {
	display: flex;
	justify-content: space-between;
	align-items: center;
	gap: 0.25em;
	font-size: 0.78em;
	padding: 0.1em 0.35em;
	border-radius: 3px;
	margin-top: 0.2em;
	color: #fff;
	line-height: 1.3;
}
.losada-portal-cal-event .losada-portal-link-button {
	color: #fff;
	opacity: 0.8;
}
.losada-cat-class { background: #2e7d32; }
.losada-cat-inspection { background: #6a1b9a; }
.losada-cat-consultation { background: #e65100; }
.losada-cat-meeting { background: #1565c0; }
.losada-cat-other { background: #616161; }

.losada-portal-calendar-legend {
	font-size: 0.8em;
	color: #666;
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 0.3em 0.9em;
	margin-top: 0.75em;
}
.legend-swatch {
	display: inline-block;
	width: 10px;
	height: 10px;
	border-radius: 2px;
	margin-right: 0.2em;
	vertical-align: middle;
}
.legend-swatch.is-weekend { background: #f4f6fb; border: 1px solid #ddd; }
.legend-swatch.is-holiday { background: #fdeeee; border: 1px solid #f3c; }
.legend-swatch.has-task-dot { background: #e6b800; border-radius: 50%; width: 8px; height: 8px; }

.losada-portal-cal-quickadd {
	margin-top: 1.5em;
	padding: 1em;
	background: #f9f9f9;
	border-radius: 8px;
}
.losada-portal-cal-quickadd-forms {
	display: flex;
	gap: 2em;
	flex-wrap: wrap;
	margin-top: 0.75em;
}
.losada-portal-cal-quickadd .losada-portal-task-form {
	flex-direction: column;
	align-items: flex-start;
	max-width: 320px;
}
.losada-portal-cal-quickadd input, .losada-portal-cal-quickadd select {
	width: 100%;
	padding: 0.5em;
	box-sizing: border-box;
}
.losada-portal-cal-allday {
	display: flex;
	align-items: center;
	gap: 0.4em;
	font-size: 0.9em;
}
.losada-portal-cancel {
	align-self: center;
	color: #888;
}
.losada-portal-inline-action {
	display: inline;
	margin: 0;
}
.losada-portal-link-button {
	background: none;
	border: none;
	padding: 0;
	color: #2271b1;
	text-decoration: underline;
	cursor: pointer;
	font-size: inherit;
}
.losada-portal-danger {
	color: #b32d2e;
}
