/* =Clearer-Erweiterung
Stylesheet der Clearer-Erweiterung (nach global.css geladen), Admin-Teile in admin/css/clearer_admin.css.
Druck des Kalenders: css/print_clearer_calendar.css.
-------------------------------------------------------------- */

/* =Clearer Tokens
Design-Tokens aus clearer-erweiterung.css (Werte wie global.css); Kategoriefarben je Element inline: --c Farbe, --t Tönung
-------------------------------------------------------------- */
:root {
	--pandi-bg: #fcfcf5;
	--pandi-white: #fff;
	--pandi-header: #20323f;
	--pandi-sidebar: #154466;
	--pandi-subsidebar: #c2c8cc;
	--pandi-subsidebar-line: #90989e;
	--pandi-subsidebar-sep: #4f4f4f;
	--pandi-row: rgba(194, 200, 204, 0.4);
	--pandi-row-alt: rgba(194, 200, 204, 0.2);
	--pandi-row-hover: rgba(194, 200, 204, 0.1);
	--pandi-info-bg: #eaf4fa;
	--pandi-blue: #349ad4;
	--pandi-blue-input: #00add9;
	--pandi-yellow: #fcdb00;
	--pandi-red: #d4330b;
	--pandi-green: #1dd413;
	--pandi-green-dark: #214023;
	--pandi-focus: #f2aa00;
	--pandi-border: #979797;
	--pandi-text: #000;
	--pandi-text-muted: #80868a;
	--pandi-st-red: red;
	--pandi-st-green: green;
	--pandi-st-grey: grey;
	--pandi-st-orange: orange;
	--pandi-grad-blue: linear-gradient(135deg, rgba(20, 157, 211, 1) 0%, rgba(32, 50, 63, 1) 100%);
	--pandi-grad-green: linear-gradient(135deg, rgba(29, 212, 19, 1) 0%, rgba(33, 64, 35, 1) 100%);
	--pandi-grad-grey: linear-gradient(135deg, rgba(212, 212, 212, 1) 0%, rgba(64, 64, 64, 1) 100%);
	--pandi-grad-red: linear-gradient(to right, #ff0000 0%, #d4330b 100%);
	--pandi-font: 'Raleway', sans-serif;
	--pandi-font-serif: 'Playfair Display', serif;
	--pandi-fs-body: 18px;
	--pandi-fs-h1: 22px;
	--pandi-fs-h2: 20px;
	--pandi-fs-menu: 13px;
	--pandi-fs-sub: 16px;
	--pandi-fs-tag: 14px;
	--pandi-fs-button: 20px;
	--pandi-lh-body: 24px;
	--pandi-icon-menu: 32px;
	--pandi-icon-sub: 60px;
	--pandi-icon-header: 40px;
	--pandi-header-h: 75px;
	--pandi-sidebar-w: 120px;
	--pandi-subsidebar-w: 210px;
	--pandi-content-w: 1060px;
	--pandi-content-pad-l: 380px;
	--pandi-content-pad-t: 54px;
	--pandi-box-pad: 22px 18px;
	--pandi-box-gap: 36px;
	--pandi-row-gap: 18px;
	--pandi-label-w: 220px;
	--pandi-input-w: 450px;
	--pandi-input-h: 40px;
	--pandi-radius: 3px;
	--pandi-badge: 20px;
	--pandi-badge-sub: 16px;
	--pandi-avatar: 64px;
	--pandi-shadow-header: 0 1px 5px 0 rgba(0, 0, 0, 0.8);
	--pandi-shadow-box: 0 0 5px 1px rgba(0, 0, 0, 0.4);
	--pandi-shadow-open: 0 0 8px 0 rgba(0, 0, 0, 0.3);
	--pandi-cat-foreign: #5f6b75;
	--pandi-cat-foreign-ring: #8a949c;
	--pandi-today-bg: #fcebe8;
	--pandi-allday-bg: #f4f6f7;
	--pandi-cell-line: #dde2e6;
	--pandi-grid-head: #e9ecef;
	--pandi-grid-head-line: #cbd2d8;
	--pandi-text-secondary: #5f6b75;
	--pandi-btn-outline: #bec3c7;
}

/* =Clearer Allgemein
-------------------------------------------------------------- */
/* Kategorie-Tag (farbig, weiße Schrift) – Ergänzung zum gelben .message_cat */
.cl-tag {
	display: inline-block;
	padding: 5px;
	font-size: var(--pandi-fs-tag);
	font-weight: 500;
	text-transform: uppercase;
	color: var(--pandi-white);
	background: var(--c, var(--pandi-blue));
}

.cl-tag--broadcast {
	background: var(--pandi-blue);
}

/* Recipient chip (clearer: one colleague; office: see admin/css/clearer_admin.css for the multi-chip field) */
.cl-chip {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	padding: 4px 10px;
	border-radius: 14px;
	background: var(--pandi-info-bg);
	border: 1px solid var(--pandi-blue);
	font-size: 16px;
	font-weight: 400;
	color: var(--pandi-header);
}

.cl-chip i {
	color: var(--pandi-blue);
	cursor: pointer;
	font-size: 12px;
}

.cl-iconbtn {
	display: inline-flex;
	width: 32px;
	height: 32px;
	align-items: center;
	justify-content: center;
	border: 1px solid var(--pandi-btn-outline);
	border-radius: var(--pandi-radius);
	background: var(--pandi-white);
	color: var(--pandi-header);
	font-size: 14px;
	cursor: pointer;
}

.cl-iconbtn:hover {
	background: var(--pandi-row-alt);
}

.cl-btn-secondary {
	display: inline-flex;
	height: 32px;
	align-items: center;
	padding: 0 12px;
	border: 1px solid var(--pandi-blue);
	border-radius: var(--pandi-radius);
	background: var(--pandi-white);
	color: var(--pandi-blue);
	font-size: 14px;
	font-weight: 500;
	text-transform: uppercase;
	cursor: pointer;
	text-decoration: none;
}

/* Hinweisbox: oberhalb der Download-Gruppen und unter dem Clearer-Kalender (Monat: zwischen Kalender und Liste, 20px Abstand zum Kalender). Im Kalender mit Link "Nachricht an das Büro schreiben" in eigener Zeile. */
.cl-hint {
	display: flex;
	gap: 16px;
	align-items: flex-start;
	background: var(--pandi-white);
	padding: var(--pandi-box-pad);
	margin: 0 0 36px 0;
	line-height: var(--pandi-lh-body);
}

.cl-hint i {
	color: var(--pandi-blue);
	font-size: 26px;
}

.cl-hint__link {
	display: block;
	margin-top: 6px;
	color: var(--pandi-blue);
}

.cl-iconbtn[disabled] {
	opacity: 0.4;
	cursor: default;
}

.cl-iconbtn[disabled]:hover {
	background: var(--pandi-white);
}

.cl-hint__link,
.cl-detail__link,
.cl-cal__tolist,
.cl-events__actions a {
	text-decoration: none;
}

.cl-hint__link:hover,
.cl-detail__link:hover {
	text-decoration: underline;
}

/* =Clearer Kalender
-------------------------------------------------------------- */
/* Werkzeugleiste: Navigation | Umschalter | Aktionen (in beiden Rollen gleich aufgebaut) */
.cl-cal__toolbar {
	display: flex;
	align-items: center;
	justify-content: space-between;
	margin-bottom: 16px;
}

.cl-cal__nav {
	display: flex;
	align-items: center;
	gap: 12px;
}

.cl-cal__period {
	min-width: 200px;
	text-align: center;
	font-size: 20px;
	font-weight: 700;
	color: var(--pandi-header);
}

.cl-toggle {
	display: inline-flex;
	border: 1px solid var(--pandi-blue);
	border-radius: var(--pandi-radius);
	overflow: hidden;
}

.cl-toggle a {
	display: flex;
	align-items: center;
	height: 32px;
	padding: 0 16px;
	font-size: 14px;
	font-weight: 500;
	color: var(--pandi-blue);
	background: var(--pandi-white);
	text-decoration: none;
	cursor: pointer;
}

.cl-toggle a.is-active {
	background: var(--pandi-blue);
	color: var(--pandi-white);
}

.cl-cal__actions {
	display: flex;
	align-items: center;
	gap: 24px;
}

/* Legende: eine Zeile, Punkte statt Quadrate; rechts Filter (Admin) bzw. "Ihre Clearing-Stelle" (Clearer) */
.cl-cal__legend {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 24px;
	margin-bottom: 16px;
	font-size: 14px;
	color: var(--pandi-header);
}

.cl-cal__legend ul {
	display: flex;
	gap: 20px;
	list-style: none;
	margin: 0;
	padding: 0;
	flex-wrap: wrap;
}

.cl-cal__legend li::before {
	content: '';
	display: inline-block;
	width: 10px;
	height: 10px;
	border-radius: 50%;
	margin-right: 8px;
	vertical-align: -1px;
	background: var(--c);
}

.cl-cal__legend .foreign::before {
	background: transparent;
	box-shadow: inset 0 0 0 1.5px var(--pandi-cat-foreign-ring);
}

.cl-cal__legend .foreign .fa-info-circle {
	margin-left: 6px;
	color: var(--pandi-blue);
	cursor: help;
}

.cl-cal__own b {
	font-weight: 700;
}

/* Monatsraster: Mo–Fr gleich breit, Sa/So 90px; Zellen 80px, max. 2 Chips, danach "+ n weitere" */
.cl-cal__grid {
	display: grid;
	grid-template-columns: repeat(5, 1fr) 90px 90px;
	border: 1px solid var(--pandi-cell-line);
}

.cl-cal__wd {
	height: 34px;
	display: flex;
	align-items: center;
	justify-content: center;
	background: var(--pandi-grid-head);
	border-bottom: 1px solid var(--pandi-grid-head-line);
	font-size: 13px;
	font-weight: 700;
	color: var(--pandi-header);
}

.cl-cal__day {
	min-height: 80px;
	padding: 6px;
	border: 1px solid var(--pandi-cell-line);
	background: var(--pandi-white);
	display: flex;
	flex-direction: column;
	gap: 4px;
	min-width: 0;
	overflow: hidden;
}

.cl-cal__day--other {
	background: var(--pandi-row-alt);
}

.cl-cal__day--today {
	background: var(--pandi-today-bg);
}

.cl-cal__num {
	font-size: 14px;
	font-weight: 500;
	color: var(--pandi-header);
}

.cl-cal__day--other .cl-cal__num {
	font-weight: 300;
	color: var(--pandi-text-muted);
}

.cl-cal__day--today .cl-cal__num {
	font-weight: 700;
	color: var(--pandi-red);
}

.cl-cal__more {
	font-size: 12px;
	font-weight: 500;
	color: var(--pandi-text-secondary);
	cursor: pointer;
}

/* Termin-Chip (Monat und ganztägig-Zeile): Tönung, Punkt, Uhrzeit fett in Kategoriefarbe, Titel dunkel mit Ellipsis */
.cl-cal__event {
	display: flex;
	align-items: center;
	gap: 5px;
	height: 22px;
	padding: 3px 6px;
	border-radius: var(--pandi-radius);
	font-size: 12px;
	line-height: 1.2;
	color: var(--pandi-header);
	background: var(--t, var(--pandi-allday-bg));
	overflow: hidden;
	white-space: nowrap;
	cursor: pointer;
	flex: none;
	min-width: 0;
}

.cl-cal__event::before {
	content: '';
	flex: none;
	width: 8px;
	height: 8px;
	border-radius: 50%;
	background: var(--c);
}

.cl-cal__event time {
	flex: none;
	font-weight: 700;
	color: var(--c);
}

.cl-cal__event span {
	font-weight: 500;
	overflow: hidden;
	text-overflow: ellipsis;
}

/* Clearer-Ansicht: Termine anderer Clearing-Stellen als eigene Klasse (keine Fläche, Ring, grauer Regular-Text), nicht klickbar, als <span> statt <a>, title="Termin einer anderen Clearing-Stelle". Regel steht nach den Kategorie-Regeln. */
.cl-cal__event--foreign {
	background: transparent;
	color: var(--pandi-cat-foreign);
	cursor: default;
	pointer-events: none;
}

.cl-cal__event--foreign::before {
	background: transparent;
	box-shadow: inset 0 0 0 1.5px var(--pandi-cat-foreign-ring);
}

.cl-cal__event--foreign time,
.cl-cal__event--foreign span {
	font-weight: 400;
	color: var(--pandi-cat-foreign);
}

/* Wochenansicht: Kopf mit Tagen, Zeile "ganztägig", Stundenraster 06–22 Uhr (16 × 44px = 704px; die Screens zeigen noch 07–19), Spalten wie im Monat */
.cl-week {
	border: 1px solid var(--pandi-cell-line);
}

.cl-week__head,
.cl-week__allday,
.cl-week__body {
	display: grid;
	grid-template-columns: 64px repeat(5, 1fr) 90px 90px;
}

.cl-week__head {
	background: var(--pandi-grid-head);
	border-bottom: 1px solid var(--pandi-grid-head-line);
}

.cl-week__head > div {
	position: relative;
	height: 48px;
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	gap: 4px;
	font-size: 13px;
	font-weight: 700;
	color: var(--pandi-header);
	border-left: 1px solid var(--pandi-cell-line);
}

.cl-week__head small {
	font-weight: 400;
	color: var(--pandi-text-secondary);
}

.cl-week__head .today {
	color: var(--pandi-red);
	background: var(--pandi-today-bg);
}

.cl-week__head .today small {
	font-weight: 700;
	color: var(--pandi-red);
}

.cl-week__head .today::before {
	content: '';
	position: absolute;
	left: 0;
	right: 0;
	top: 0;
	height: 3px;
	background: var(--pandi-red);
}

.cl-week__allday {
	background: var(--pandi-allday-bg);
	border-bottom: 2px solid var(--pandi-grid-head-line);
}

.cl-week__allday > div {
	min-height: 36px;
	padding: 4px;
	border-left: 1px solid var(--pandi-cell-line);
	display: flex;
	flex-direction: column;
	justify-content: center;
	gap: 3px;
	min-width: 0;
	overflow: hidden;
}

.cl-week__allday > div:first-child,
.cl-week__body > div:first-child {
	border-left: 0;
	font-size: 12px;
	color: var(--pandi-text-secondary);
	text-align: right;
	padding-right: 6px;
}

/* same 10px below the 22:00 line as above the 06:00 line, so both labels fit */
.cl-week__body {
	padding: 10px 0;
}

.cl-week__hours {
	position: relative;
	height: 704px;
}

.cl-week__hours span {
	position: absolute;
	right: 8px;
	font-size: 12px;
	line-height: 1;
	color: var(--pandi-text-secondary);
}

.cl-week__col {
	position: relative;
	height: 704px;
	border-left: 1px solid var(--pandi-cell-line);
	border-bottom: 1px solid var(--pandi-cell-line);
	background-image: linear-gradient(var(--pandi-cell-line) 1px, transparent 1px);
	background-size: 100% 44px;
	min-width: 0;
}

.cl-week__col--today,
.cl-week__allday > .today {
	background-color: var(--pandi-today-bg);
}

/* Terminblock: top = (Beginn − 06:00) × 44px + 1px, height = Dauer × 44px − 2px. Tönung, 3px Balken links, Uhrzeit fett in Farbe, Titel dunkel. Gleichzeitige Termine: Spaltenbreite durch Anzahl teilen (left/width in %, 2px Abstand), Reihenfolge nach Beginn. Blöcke unter 100px Breite (--narrow): nur Beginn, Titel mit hyphens: auto (lang="de"), 1 Zeile je 44px Höhe, Rest per line-clamp. */
.cl-week__event {
	position: absolute;
	background: var(--t, var(--pandi-allday-bg));
	left: 2px;
	right: 2px;
	padding: 4px 6px 4px 8px;
	border-left: 3px solid var(--c);
	border-radius: var(--pandi-radius);
	color: var(--pandi-header);
	overflow: hidden;
	cursor: pointer;
	box-sizing: border-box;
	border-bottom: 2px solid transparent;
	background-clip: padding-box;
}

.cl-week__event time {
	display: block;
	font-size: 11px;
	font-weight: 700;
	color: var(--c);
}

.cl-week__event span {
	display: block;
	font-size: 12px;
	font-weight: 500;
	line-height: 1.25;
}

.cl-week__event--narrow {
	padding: 4px 5px;
}

.cl-week__event--narrow span {
	font-size: 11px;
	hyphens: auto;
	overflow: hidden;
	display: -webkit-box;
	-webkit-box-orient: vertical;
	-webkit-line-clamp: var(--lines, 1);
}

.cl-week__event--foreign {
	background: var(--pandi-white);
	border: 1px solid var(--pandi-grid-head-line);
	color: var(--pandi-cat-foreign);
	pointer-events: none;
	border-bottom: 1px solid var(--pandi-grid-head-line);
}

.cl-week__event--foreign time,
.cl-week__event--foreign span {
	font-weight: 400;
	color: var(--pandi-cat-foreign);
}

.cl-cal__box {
	padding: 20px 18px;
}

.cl-cal--woche .cl-cal__period {
	min-width: 280px;
}

.cl-cal--liste .cl-cal__period {
	min-width: 120px;
}

.cl-toggle a + a {
	border-left: 1px solid var(--pandi-blue);
}

.cl-cal__legend .foreign .fa-info-circle::before {
	content: "\f05a";
}

.cl-cal__own {
	white-space: nowrap;
}

a.cl-cal__event,
a.cl-cal__more,
a.cl-week__event {
	text-decoration: none;
}

a.cl-cal__more:hover {
	color: var(--pandi-blue);
}

.cl-week__event:not(.cl-week__event--narrow) span {
	overflow: hidden;
}

/* =Clearer Terminliste
-------------------------------------------------------------- */
/* Terminliste ("Nächste Termine" und Listenansicht): Punkt, Datum (heute rot), Uhrzeit in Kategoriefarbe, Kategorie grau, ganze Zeile klickbar (öffnet das Modal); Aktionen: Admin nur Stift, Clearer nur ICS-Download */
.cl-events {
	width: 100%;
}

.cl-events__row {
	display: flex;
	align-items: center;
	gap: 16px;
	padding: 12px 10px;
	border-bottom: 1px solid var(--pandi-cell-line);
	cursor: pointer;
}

.cl-events__row:hover {
	background: #f7f8f9;
}

.cl-events__dot {
	width: 10px;
	height: 10px;
	border-radius: 50%;
	background: var(--c);
	flex: none;
}

.cl-events__date {
	width: 160px;
	flex: none;
}

.cl-events__date b {
	display: block;
	font-size: 16px;
	font-weight: 600;
	color: var(--pandi-header);
}

.cl-events__date time {
	display: block;
	margin-top: 4px;
	font-size: 14px;
	font-weight: 600;
	color: var(--c);
}

.cl-events__row--today .cl-events__date b {
	font-weight: 700;
	color: var(--pandi-red);
}

.cl-events__title {
	width: 320px;
	font-size: 18px;
	font-weight: 400;
	flex: 1 1 320px;
	min-width: 0;
	overflow-wrap: anywhere;
}

.cl-events__title small {
	display: block;
	margin-top: 4px;
	font-size: 13px;
	font-weight: 300;
	color: var(--pandi-text-secondary);
}

.cl-events__cat {
	width: 140px;
	flex: none;
	font-size: 16px;
	font-weight: 400;
	line-height: 1.2;
	color: var(--pandi-text-secondary);
}

.cl-events__place {
	display: flex;
	align-items: center;
	gap: 8px;
	font-size: 16px;
	font-weight: 300;
	color: var(--pandi-text-secondary);
	flex: 0 1 220px;
	min-width: 0;
}

.cl-events__actions {
	width: 40px;
	display: flex;
	justify-content: flex-end;
	font-size: 20px;
	color: var(--pandi-blue);
}

/* Box "Nächste Termine" and list view */
.cl-events__head {
	display: flex;
	align-items: baseline;
	justify-content: space-between;
	margin-bottom: 8px;
}

.cl-events__head h2 {
	margin: 0;
	font-size: var(--pandi-fs-h2);
	font-weight: 500;
	color: var(--pandi-header);
}

.cl-events__head a,
.cl-events__foot a {
	font-size: 16px;
	font-weight: 500;
	color: var(--pandi-blue);
	text-decoration: none;
}

.cl-events__foot {
	margin-top: 20px;
	text-align: right;
}

.cl-events__row:focus {
	outline: 2px solid var(--pandi-blue);
	outline-offset: -2px;
}

.cl-events__place .fa {
	flex: none;
}

.cl-events__actions a {
	color: var(--pandi-blue);
	padding: 4px;
}

.cl-events__empty {
	padding: 20px 10px;
	font-size: 16px;
	color: var(--pandi-text-secondary);
}

.cl-events__more {
	padding: 14px;
	text-align: center;
	color: var(--pandi-text-secondary);
}

/* =Clearer Termin-Modal
-------------------------------------------------------------- */
/* Termin-Detailansicht als Modal über dem abgedunkelten Kalender (Admin und Clearer, gleiche Struktur). Falls PANDI schon ein Bootstrap-Modal nutzt, dessen Markup verwenden und nur die Maße übernehmen. */
.cl-modal__backdrop {
	position: fixed;
	inset: 0;
	z-index: 1040;
	background: rgba(32, 50, 63, 0.6);
}

.cl-modal {
	position: fixed;
	z-index: 1050;
	top: 100px;
	left: 50%;
	transform: translateX(-50%);
	width: 820px;
	max-height: calc(100vh - 140px);
	overflow: auto;
	background: var(--pandi-white);
	border-radius: 4px;
	box-shadow: 0 8px 30px rgba(0, 0, 0, 0.35);
}

.cl-modal__close {
	position: absolute;
	top: 12px;
	right: 10px;
	width: 40px;
	height: 40px;
	display: flex;
	align-items: center;
	justify-content: center;
	border-radius: var(--pandi-radius);
	color: var(--pandi-text-secondary);
	font-size: 18px;
	cursor: pointer;
	text-decoration: none;
}

.cl-modal__body {
	padding: 26px 22px 22px;
}

.cl-modal__foot {
	display: flex;
	align-items: center;
	justify-content: space-between;
	/* .pen: 72px incl. the 1px top line -> 15px above */
	padding: 15px 22px 16px;
	border-top: 1px solid var(--pandi-cell-line);
}

.cl-modal__foot .buttons {
	display: flex;
	gap: 16px;
}

.cl-detail__head {
	display: flex;
	justify-content: space-between;
	align-items: flex-start;
	padding: 0 48px 18px 0;
	border-bottom: 1px solid var(--pandi-cell-line);
}

.cl-detail__cat {
	display: inline-flex;
	gap: 8px;
	align-items: center;
	font-size: 14px;
	font-weight: 600;
	line-height: 1;
	color: var(--c);
}

.cl-detail__cat::before {
	content: '';
	width: 10px;
	height: 10px;
	border-radius: 50%;
	background: var(--c);
}

.cl-detail__title {
	margin: 10px 0;
	font-size: 22px;
	font-weight: 700;
	line-height: 1.2;
	color: var(--pandi-header);
}

.cl-detail__when {
	display: flex;
	gap: 10px;
	align-items: center;
	font-size: 16px;
	font-weight: 400;
	line-height: 1.2;
	color: var(--pandi-header);
}

.cl-detail__when .fa {
	font-size: 16px;
}

.cl-detail__when b {
	font-weight: 700;
	color: var(--c);
}

.cl-detail__online {
	display: inline-flex;
	gap: 8px;
	align-items: center;
	padding: 5px 8px;
	background: var(--pandi-info-bg);
	font-size: 13px;
	font-weight: 600;
	line-height: 1;
	text-transform: uppercase;
	color: var(--pandi-header);
	flex: none;
}

.cl-detail__online .fa {
	font-size: 14px;
}

/* labels on the baseline of the first value line (owner ruling 2026-11-19: the .pen shows them too low) */
.cl-detail__row {
	display: flex;
	align-items: baseline;
	margin-top: 18px;
	font-size: 16px;
}

.cl-detail__label {
	box-sizing: border-box;
	width: 150px;
	flex: none;
	padding: 0 20px 0 0;
	text-align: right;
	font-weight: 300;
	line-height: 1.2;
	color: var(--pandi-header);
}

.cl-detail__link {
	color: var(--pandi-blue);
	word-break: break-all;
}

.cl-attach {
	width: 600px;
}

.cl-attach__row {
	display: flex;
	align-items: center;
	gap: 12px;
	padding: 8px 6px;
	border-bottom: 1px solid var(--pandi-cell-line);
}

.cl-attach__row > .fa {
	font-size: 20px;
	color: var(--pandi-text-secondary);
}

.cl-attach__name {
	font-size: 16px;
	font-weight: 400;
	line-height: 1.2;
	color: var(--pandi-blue);
}

.cl-attach__size {
	font-size: 13px;
	font-weight: 300;
	line-height: 1;
	color: var(--pandi-text-secondary);
}

.cl-attach__actions {
	margin-left: auto;
	display: flex;
	gap: 18px;
	font-size: 18px;
	color: var(--pandi-blue);
}

/* Event modal */
body.cl-modal-open {
	overflow: hidden;
}

.cl-modal:focus {
	outline: none;
}

.cl-modal__close:hover {
	background: var(--pandi-row-alt);
}

.cl-detail__when .fa-clock-o {
	color: var(--pandi-text-secondary);
}

/* values as in the .pen "Feld" frames: text top at the row top,
   16px/1.2 regular, black; description 300/1.45 */
.cl-detail__value {
	flex: 1;
	min-width: 0;
	font-weight: 400;
	line-height: 1.2;
	color: #000;
}

.cl-detail__line {
	display: flex;
	align-items: center;
	gap: 10px;
}

.cl-detail__line .fa {
	font-size: 16px;
	color: var(--pandi-header);
}

.cl-detail__linkrow {
	margin-top: 8px;
	gap: 12px;
}

.cl-detail__linkrow .fa-link {
	font-size: 14px;
	color: var(--pandi-blue);
}

.cl-detail__text {
	font-weight: 300;
	line-height: 1.45;
}

.cl-detail__fors {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 10px;
}

.cl-detail__for {
	display: inline-block;
	padding: 5px;
	background: var(--pandi-info-bg);
	font-size: 14px;
	font-weight: 500;
	line-height: 1;
	text-transform: uppercase;
	color: var(--pandi-header);
}

.cl-detail__meta {
	font-size: 13px;
	font-weight: 300;
	line-height: 1;
	color: var(--pandi-text-secondary);
}

.cl-detail__created {
	font-size: 14px;
	line-height: 1.3;
}

.cl-detail__ask {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	text-decoration: none;
}

.cl-detail__ask .fa {
	font-size: 14px;
	color: var(--pandi-blue);
}

.cl-modal .cl-attach {
	width: 100%;
	max-width: 600px;
}

.cl-modal .cl-attach__name {
	text-decoration: none;
	word-break: break-all;
}

.cl-modal .cl-attach__actions a {
	color: var(--pandi-blue);
}

.cl-modal__foot .cl-btn-secondary {
	box-sizing: border-box;
	height: 40px;
	padding: 0 18px;
	font-size: 16px;
	text-decoration: none;
}

/* .pen button widths: Schließen 180, Bearbeiten 200, Online teilnehmen 280 */
.cl-modal__foot #button_grey_submit,
.cl-modal__foot #button_blue_submit {
	display: inline-block;
	width: 180px;
	padding: 0;
	box-sizing: border-box;
	text-align: center;
	text-decoration: none;
}

.cl-modal__foot #button_blue_submit.cl-modal__edit {
	width: 200px;
}

.cl-modal__foot #button_blue_submit.cl-modal__join {
	width: 280px;
}

/* =Clearer Nachrichten
-------------------------------------------------------------- */
/* Filterbox wie .nachrichten_box .filter_box, zweite Zeile "Empfänger:" bzw. "Von:" */
.cl-filter {
	padding: 20px;
	margin: 0 0 36px 0;
	background: var(--pandi-white);
	box-shadow: var(--pandi-shadow-box);
}

.cl-filter h1 {
	margin: 0 0 18px 0;
}

.cl-filter__row {
	display: flex;
	align-items: center;
	gap: 20px;
	margin: 0 0 18px 0;
}

.cl-filter__row:last-child {
	margin: 0;
}

.cl-filter__label {
	width: 110px;
	font-weight: 400;
	color: var(--pandi-header);
}

/* Rundschreiben: Empfänger "Alle Clearer" + blauer Tag neben "An:" */
#messages .message .message_box_middle .cl-broadcast {
	/* .pen "Tag Rundschreiben": 10px after the name, padding 5, 24px high, vertically
	   centred on the 16px "An:" line (negative margins keep the line height unchanged) */
	display: inline-block;
	margin: -4px 0 -4px 10px;
	padding: 5px;
	vertical-align: top;
	line-height: 14px;
	font-size: var(--pandi-fs-tag);
	font-weight: 500;
	text-transform: uppercase;
	color: var(--pandi-white);
	background: var(--pandi-blue);
}

/* Avatar des Büros (kein Benutzerbild): Würfel-Icon wie Menüpunkt "Admin" */
#messages .message .message_box_left .sender_avatar--office {
	display: flex;
	align-items: center;
	justify-content: center;
	background: var(--pandi-cell-line);
	color: var(--pandi-subsidebar-line);
	font-size: 40px;
}

/* Formular "Neue Nachricht": Empfängerwahl per Radio + Autocomplete (Clearer) bzw. Chips/Stellen-Raster (Admin, admin/css). */
.cl-recipient {
	display: flex;
	flex-direction: column;
	gap: 10px;
}

.cl-recipient .radio_area {
	margin: 0;
}

/* Themen der Clearer-Kommunikation (ersetzen Rechnung/Antrag/… des Therapeuten-Moduls) */
.cl-topic--organisatorisches,
.cl-topic--termine,
.cl-topic--faelle,
.cl-topic--sonstiges {
	background: var(--pandi-yellow);
	color: var(--pandi-sidebar);
}

.cl-recipient__hint,
.cl-field-hint {
	margin: 6px 0 0 0;
	font-size: 14px;
	font-weight: 300;
	color: var(--pandi-text-muted);
	clear: both;
	padding-left: 224px;
}

/* message forms: hints start where the inputs start (label column 220px + 20px padding) */
.cl-new-message .cl-recipient__hint,
.cl-new-message .cl-field-hint {
	padding-left: 240px;
}

.cl-recipient__pick {
	position: relative;
	vertical-align: middle;
	display: block;
	margin: 8px 0 0 38px;
}

.cl-recipient__pick .input_text {
	box-sizing: border-box;
	height: 40px;
	padding: 0 10px;
	border: 1px solid var(--pandi-border);
	border-radius: var(--pandi-radius);
	font: 300 18px/1.2 var(--pandi-font);
	color: var(--pandi-blue-input);
	background: var(--pandi-white);
	width: 400px;
}

/* Clearer form: name field in the line of "Clearer-Kollege/in:" as in screen Clearer 5
   (10px after the label, 452 x 40, framed); beats the legacy .new_message_box_to input rules */
.cl-new-message:not(.cl-new-message--admin) .cl-recipient .radio_area {
	width: 100%;
}

#main_content .new_messages .cl-recipient .radio_buttons label[for='clearer-typ-einzeln'] {
	margin-right: 0;
}

/* 40px field centred on the 32px radio line: top-aligned and pulled up 4px, so the radio
   label stays on whole pixels (vertical-align: middle put it at y+0.67 and blurred the dot) */
#main_content .new_messages .cl-recipient .radio_buttons .cl-recipient__pick {
	display: inline-block;
	margin: -4px 0 -4px 10px;
	vertical-align: top;
}

/* the field stays framed while disabled ("Büro" chosen), as in the screen; the legacy
   input_text:disabled rule removes the border with !important, so !important is needed here */
#main_content .new_messages .cl-recipient .radio_buttons .cl-recipient__pick .input_text {
	float: none;
	display: inline-block;
	position: static;
	top: 0;
	width: 452px;
	height: 40px;
	margin: 0;
	border: 1px solid var(--pandi-border) !important;
}

/* a disabled input swallows clicks: let them through to the box, which selects "Clearer-Kollege/in" (js/clearer.js) */
#main_content .new_messages .cl-recipient .radio_buttons .cl-recipient__pick {
	cursor: text;
}

#main_content .new_messages .cl-recipient .radio_buttons .cl-recipient__pick .input_text:disabled {
	pointer-events: none;
}

.cl-recipient__pick .input_text::placeholder {
	color: var(--pandi-text-muted);
}

/* right margin of the message fragments as in the screens (the calendar in adminClearerContent_1 keeps the full width) */
#clearerNachrichtenContent_1 > .nachrichten_box,
#clearerNachrichtenContent_1 > .white_box,
#adminClearerContent_1 > .nachrichten_box,
#adminClearerContent_1 > .white_box {
	margin-right: 26px;
}

.cl-new-message .new_message_box_send {
	text-align: center;
	margin-top: 20px;
}

.cl-new-message .new_message_box_send #button_green_submit {
	width: 200px;
	display: inline-block;
}

/* Attachment row in the clearer message forms: laid out like the "Nachricht" row
   (label on the left, drop zone as wide as the textarea, spacing above) instead of
   the indented legacy attachment bar */
#main_content .new_messages .cl-new-message .new_message_box_attachments,
#messages .message .reply_message_box .clearer_reply_mail_attachment .reply_message_box_attachments {
	width: auto;
	margin: 10px 0 0 0;
}

#main_content .new_messages .cl-new-message .new_message_box_attachments label {
	width: 220px;
}

#messages .message .reply_message_box .clearer_reply_mail_attachment .reply_message_box_attachments label {
	width: 118px;
}

.cl-new-message .new_message_box_attachments .feld,
.clearer_reply_mail_attachment .reply_message_box_attachments .feld {
	float: left;
	width: 732px;
	margin-left: 0;
}

.cl-new-message .new_message_box_attachments .cl-dropzone-wrap,
.clearer_reply_mail_attachment .reply_message_box_attachments .cl-dropzone-wrap {
	max-width: none;
}

.cl-reply-hint {
	padding: 10px 0;
	font-size: 14px;
	font-weight: 300;
	color: var(--pandi-text-muted);
}

/* Fehlerzeile über dem Formular (Text wie die Zeile, die user.js nach einem Sendefehler in die Box schreibt), nur der Abstand zum Formular */
.clearer_send_error {
	margin: 0 0 18px 0;
}

/* =Clearer Downloads
-------------------------------------------------------------- */
/* Gruppenkopf in der weißen Box (auf-/zuklappbar) */
.cl-dlgroup__head {
	display: flex;
	align-items: center;
	gap: 12px;
	padding: 0 0 14px 0;
	cursor: pointer;
}

.cl-dlgroup__head i.folder {
	font-size: 24px;
	color: var(--pandi-header);
}

.cl-dlgroup__title {
	font-size: var(--pandi-fs-h2);
	font-weight: 500;
}

.cl-dlgroup__count {
	font-size: 16px;
	font-weight: 300;
	color: var(--pandi-text-muted);
}

.cl-dlgroup__toggle {
	margin-left: auto;
	font-size: 16px;
	color: var(--pandi-blue);
}

.cl-dlgroup.is-collapsed .cl-dlgroup__head {
	padding-bottom: 0;
}

.cl-dlgroup.is-collapsed #downloads {
	display: none;
}

/* NEU-Markierung (Datei jünger als 14 Tage oder seit letztem Login) */
.cl-new {
	display: inline-block;
	margin-left: 14px;
	padding: 3px 8px;
	border-radius: var(--pandi-radius);
	background: var(--pandi-yellow);
	color: var(--pandi-header);
	font-size: 13px;
	font-style: italic;
	font-weight: 800;
	vertical-align: 2px;
}

.cl-dlgroup__head .cl-new {
	margin-left: 0;
}

/* =Clearer Drop-Zone
-------------------------------------------------------------- */
/* Drop-Zone für JEDEN Datei-Upload (Entscheidung 4.11.2026): ersetzt .cl-file und die Leiste "Neuen Anhang hinzufügen" der Screens. Dateien hineinziehen oder klicken, mehrere Dateien, max. 8 MB je Datei. Vorschlag, noch nicht als Screen gezeichnet. Gewählte Dateien darunter als Zeilen wie .cl-attach__row mit Entfernen. */
.cl-dropzone {
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 12px;
	min-height: 56px;
	padding: 12px 16px;
	border: 2px dashed var(--pandi-border);
	border-radius: var(--pandi-radius);
	background: var(--pandi-row-alt);
	color: var(--pandi-header);
	font-size: 16px;
	cursor: pointer;
}

.cl-dropzone i {
	color: var(--pandi-blue);
	font-size: 26px;
}

.cl-dropzone.is-dragover {
	border-color: var(--pandi-blue);
	background: var(--pandi-info-bg);
}

.cl-dropzone-wrap {
	width: 100%;
	max-width: 600px;
}

.cl-dropzone__input {
	display: none;
}

.cl-dropzone__list {
	margin-top: 8px;
}

.cl-dropzone__list .cl-attach__row {
	width: 100%;
}

.cl-dropzone__list .cl-attach__name {
	color: var(--pandi-header);
	word-break: break-all;
}

.cl-dropzone__list .cl-dropzone__name {
	flex: 1 1 auto;
	min-width: 0;
	height: 36px;
	padding: 0 10px;
	border: 1px solid var(--pandi-border);
	border-radius: var(--pandi-radius);
	font-size: 16px;
	color: var(--pandi-blue-input);
}

.cl-dropzone__list .cl-dropzone__name:focus {
	border-color: var(--pandi-focus);
	outline: none;
}

.cl-dropzone__remove {
	margin-left: auto;
	background: none;
	border: 0;
	padding: 4px 6px;
	cursor: pointer;
	font-size: 18px;
	color: var(--pandi-red);
}

.cl-dropzone__error {
	margin-top: 6px;
	font-size: 14px;
	color: var(--pandi-red);
}
