/* SE Ortsplan – Darstellung angelehnt an den GDP (public/css/plan.css), Präfix .se-op */

.se-op {
	--bg: #F5F6F8;
	--surface: #FFFFFF;
	--ink: #1D2433;
	--muted: #667085;
	--line: #DCE0E7;
	--line2: #EEF0F4;
	--accent: #2F5DA8;
	--accent-soft: #E6EDF8;
	/* Schriftart kommt vom Theme – hier wird keine font-family gesetzt. */
	color: var(--ink);
	margin: 0 0 1.5em;
}
.se-op *, .se-op *::before, .se-op *::after { box-sizing: border-box; }

/* Kopfleiste */
.se-op-bar { display: flex; flex-wrap: wrap; gap: 8px 16px; align-items: center; justify-content: space-between; margin: 0 0 10px; font-size: 14px; }
.se-op-nav { display: flex; gap: 12px; align-items: center; }
.se-op-nav a { text-decoration: none; font-weight: 600; }
.se-op-nav span { color: var(--muted); }
.se-op-sel { display: flex; flex-wrap: wrap; gap: 4px; align-items: center; }
.se-op-sel > span { color: var(--muted); margin-right: 4px; }
.se-op-sel button {
	font-family: inherit; font-weight: 500; font-size: 13px; line-height: 1.2; cursor: pointer; border-radius: 999px; padding: 4px 10px; margin: 0;
	border: 1px solid var(--gcol, var(--line)); background: var(--gcol, var(--surface)); color: var(--gfg, var(--ink));
	text-transform: none; letter-spacing: 0; box-shadow: none; min-height: 0; height: auto;
}
.se-op-sel button[aria-pressed="false"] { background: var(--surface); color: var(--muted); border-color: var(--line); }
.se-op-sel button.se-op-all { background: transparent; border-color: var(--line); color: var(--accent); }
.se-op-sel button:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }

/* Volle verfügbare Breite, Höhe unbegrenzt. Waagerecht scrollt es nur, wenn die Mindestbreite der Spalten nicht passt. */
.se-op-scroll { overflow-x: auto; overflow-y: visible; width: 100%; border: 1px solid var(--line); border-radius: 6px; background: var(--surface); }
.se-op .se-op-mx caption { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.se-op-scroll:focus-visible { outline: 2px solid var(--accent); }

/* Matrix – Theme-Tabellenstile neutralisieren */
.se-op table.se-op-mx { width: 100%; border-collapse: separate; border-spacing: 0; table-layout: fixed; margin: 0; max-width: none; border: 0; background: transparent; }
.se-op .se-op-mx th, .se-op .se-op-mx td {
	background: var(--surface); border: 0; border-bottom: 1px solid var(--line2); border-right: 1px solid var(--line2);
	vertical-align: top; font-size: 13px; line-height: 1.3; color: var(--ink); text-transform: none; letter-spacing: 0;
}
.se-op .se-op-mx thead th { text-align: center; padding: 6px 8px; overflow-wrap: anywhere; }
.se-op .se-op-mx thead tr:first-child th {
	height: 36px; font-weight: 600; font-size: 17px; line-height: 1.2;
	color: color-mix(in srgb, var(--gcol) 70%, var(--ink)); border-bottom: 3px solid var(--gcol);
}
.se-op .se-op-mx thead tr:nth-child(2) th {
	height: 44px; vertical-align: middle; font-weight: 600; font-size: 13px;
	color: color-mix(in srgb, var(--gcol) 70%, var(--ink)); background: color-mix(in srgb, var(--gcol) 10%, var(--surface));
}
.se-op .se-op-mx .fx { position: sticky; left: 0; z-index: 2; text-align: left; }
.se-op .se-op-mx .fx2 { position: sticky; left: 118px; z-index: 2; text-align: left; border-right: 2px solid var(--line); }
.se-op .se-op-mx.no-lit .fx { border-right: 2px solid var(--line); }
.se-op .se-op-mx thead tr:first-child th.fx, .se-op .se-op-mx thead tr:first-child th.fx2 { z-index: 3; color: var(--muted); font-weight: 600; font-size: 13px; vertical-align: bottom; border-bottom: 1px solid var(--line); }
.se-op .se-op-mx td { padding: 5px 6px; }
.se-op .se-op-mx .dt { font-weight: 600; white-space: nowrap; padding: 5px 6px 5px 10px; }
.se-op .se-op-mx tr:not(.so) .dt { color: var(--muted); font-weight: 500; }
.se-op .se-op-mx tr.today > * { background: var(--accent-soft); }
.se-op-heute { font-size: 11px; font-weight: 600; color: var(--accent); }
.se-op .se-op-mx thead .vo { font-weight: 400; font-size: 11px; color: var(--muted); }
.se-op .se-op-mx thead th.fr { font-style: italic; font-weight: 500; }
.se-op .se-op-mx td.and { background: color-mix(in srgb, var(--bg) 60%, var(--surface)); }
.se-op .se-op-mx tr.today td.and { background: var(--accent-soft); }

/* Liturgischer Tag */
.se-op .se-op-lt {
	display: inline-block; overflow-wrap: anywhere; font-weight: 500; font-size: 13px; line-height: 1.25;
	background: var(--lit, transparent); color: var(--litfg, var(--ink)); border-radius: 4px; padding: 2px 6px;
}
.se-op .se-op-lt.weiss { border: 1px solid var(--line); }

/* Eintrag */
.se-op a.se-op-mi {
	display: block; width: 100%; text-align: left; text-decoration: none; border: 0; border-left: 3px solid var(--gcol);
	background: color-mix(in srgb, var(--gcol) 10%, var(--surface)); color: var(--ink);
	border-radius: 3px; padding: 3px 6px; margin: 0 0 3px; font-size: 13px; line-height: 1.3;
	break-inside: avoid;
}
.se-op a.se-op-mi:last-child { margin-bottom: 0; }
.se-op a.se-op-mi:hover, .se-op a.se-op-mi:focus-visible { background: color-mix(in srgb, var(--gcol) 22%, var(--surface)); color: var(--ink); }
.se-op .se-op-mi b { font-weight: 600; }
.se-op .se-op-mi .who { color: var(--muted); }
.se-op .se-op-ort { display: block; color: var(--muted); font-size: 12px; }
.se-op .se-op-mi.fremd { border-left-style: dashed; }
.se-op .abg .se-op-in, .se-op .abg .se-op-cti { text-decoration: line-through; }
.se-op .abg { opacity: .7; }
.se-op .se-op-abg { font-size: 11px; font-weight: 600; color: #B3261E; white-space: nowrap; }

/* Karten (Smartphone) */
.se-op-cards { display: none; }
.se-op-day { margin: 0 0 16px; }
.se-op .se-op-dh { font-weight: 600; font-size: 17px; line-height: 1.3; margin: 0 0 8px; padding: 0; color: var(--ink); text-transform: none; letter-spacing: 0; }
.se-op .se-op-dh .se-op-lt { font-size: 12px; vertical-align: middle; margin-left: 6px; }
.se-op-day.today .se-op-dh::after { content: " · Heute"; color: var(--accent); font-size: 14px; }
.se-op a.se-op-card {
	display: flex; gap: 12px; text-decoration: none; color: var(--ink);
	border-left: 5px solid var(--gcol); background: color-mix(in srgb, var(--gcol) 8%, var(--surface));
	border-radius: 4px; padding: 10px 12px; margin: 0 0 8px;
}
.se-op-ct { font-size: 20px; font-weight: 700; line-height: 1.1; min-width: 3.2em; }
.se-op-cb { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.se-op-cti { font-size: 16px; font-weight: 600; }
.se-op-co { font-weight: 600; font-size: 14px; }
.se-op-cl { color: var(--muted); font-size: 14px; }
.se-op-chips { display: flex; flex-wrap: wrap; gap: 4px; margin-top: 4px; }
.se-op-chip { font-size: 12px; border-radius: 999px; padding: 1px 8px; }

.se-op-leer { color: var(--muted); font-style: italic; }
.se-op [hidden] { display: none !important; } /* !important: Theme-Regeln wie td{display:table-cell} sollen ausgeblendete Spalten nicht wieder zeigen */

@media (max-width: 760px) {
	.se-op-scroll { display: none; }
	.se-op-cards { display: block; }
}

@media print {
	.se-op-bar { display: none; }
	.se-op-scroll { overflow: visible; max-height: none; border: 0; }
	.se-op .se-op-mx { min-width: 0 !important; }
	.se-op .se-op-mx thead th, .se-op .se-op-mx .fx, .se-op .se-op-mx .fx2 { position: static; }
	.se-op .se-op-mx tr { break-inside: avoid; }
	.se-op-cards { display: none !important; }
	.se-op-scroll { display: block !important; }
}
