/* Design wie IT-Portal: gleiche Farben, Karten, eckige Aktionen, weiche Statuspillen. */
:root {
  --ink: #1e2b28; --muted: #61706b; --paper: #fffefa; --line: #d8e1dc;
  --blue: #356fa8; --blue-soft: #eaf3fb; --green: #397861; --green-soft: #e8f4ee;
  --coral: #a85e4d; --coral-soft: #f8ece8; --violet: #6d5c9e; --violet-soft: #f0edf8;
  --warm: #b07436; --warm-soft: #fbf1e3;
  --shadow: 0 16px 40px rgba(38, 64, 55, .09);
  --tint: linear-gradient(180deg, #fdfaf2, #f8f1e1); --tint-line: #e2d8c0;
  --bar: rgba(255, 254, 250, .9); --bar-line: rgba(216, 225, 220, .9);
  --page: radial-gradient(circle at 8% 0%, rgba(84, 146, 183, .15), transparent 30rem), linear-gradient(180deg, #f7f5ee 0%, #edf4ef 100%);
  --card: rgba(255, 254, 250, .88); --tiles: linear-gradient(180deg, #ffffff, #fbf7ee);
  --white: #fff; --hover: #fff; --hover-line: #d8cdb2; --input-line: #9db8ca;
  --blue-ink: #285c8b; --blue-ink-2: #214f70; --warm-ink: #8a5516;
}
* { box-sizing: border-box; }
body {
  margin: 0; overflow-x: hidden; color: var(--ink);
  background: var(--page);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  line-height: 1.5; min-height: 100vh;
}
a { color: inherit; }
button, input { font: inherit; }
a:focus-visible, button:focus-visible, input:focus-visible { outline: 3px solid rgba(53, 111, 168, .35); outline-offset: 3px; }
h1, h2, h3, p { overflow-wrap: anywhere; }
h1 { margin: 0; font-size: clamp(1.8rem, 4vw, 2.8rem); line-height: 1.08; letter-spacing: -.04em; }
h2 { margin: 0 0 14px; font-size: 1.3rem; letter-spacing: -.02em; }
h3 { margin: 0; font-size: 1.02rem; }
.muted { color: var(--muted); }
.pad { padding: 16px; }
.small { font-size: .85rem; }
.eyebrow { margin: 0 0 5px; color: var(--green); font-size: .72rem; font-weight: 850; letter-spacing: .13em; text-transform: uppercase; }

.topbar {
  position: sticky; top: 0; z-index: 20; min-height: 76px; display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px 20px;
  padding: 12px clamp(18px, 4vw, 54px); background: var(--bar); border-bottom: 1px solid var(--bar-line);}
/* Logobereich wie auf der JuHiBo-Labs-Seite: Logo, Trennlinie, Name mit Zeile darunter */
.nav-logo { display: flex; align-items: center; gap: 16px; text-decoration: none; }
.nav-logo img { width: 126px; height: auto; }
.brand-copy { padding-left: 16px; border-left: 1px solid var(--line); }
.brand-copy strong, .brand-copy small { display: block; }
.brand-copy strong { font-size: 1.02rem; }
.brand-copy small { font-size: .75rem; color: var(--muted); }
@media (max-width: 960px) { .brand-copy { display: none; } }
.search { flex: 1 1 260px; max-width: 460px; }
.search input { width: 100%; min-height: 40px; padding: 9px 12px; border: 1px solid var(--input-line); border-radius: 6px; background: var(--paper); color: var(--ink); }

.shell { max-width: 1380px; margin: 0 auto; padding: 30px clamp(18px, 4vw, 54px) 60px; }
.hello { margin-bottom: 26px; }
.layout { display: grid; grid-template-columns: minmax(0, 1.6fr) minmax(0, 1fr); gap: 24px; align-items: start; }
.col { display: grid; gap: 24px; min-width: 0; }
@media (max-width: 860px) { .layout { grid-template-columns: minmax(0, 1fr); } }

.card { padding: 22px; border: 1px solid var(--line); border-radius: 14px; background: var(--card); box-shadow: 0 8px 25px rgba(38, 64, 55, .05); min-width: 0; }
.shell > .notice { margin-bottom: 18px; }
.card-note { margin: 0 0 10px; padding: 8px 10px; border-radius: 8px; background: var(--warm-soft); color: var(--warm-ink); font-size: .85rem; font-weight: 650; }
.notice { display: flex; gap: 12px; border-color: transparent; background: var(--warm-soft); border-top: 4px solid var(--warm); }
.pill { display: inline-flex; width: fit-content; border-radius: 6px; padding: 2px 10px; font-size: .75rem; font-weight: 750; line-height: 1.4; background: #eef1ef; color: #53615d; }
.pill.blue { background: var(--tint); color: var(--blue-ink); box-shadow: inset 0 0 0 1px var(--tint-line); }
.pill.green { background: var(--green-soft); color: var(--green); }
.pill.warm { background: var(--warm-soft); color: var(--warm-ink); }
.pill.violet { background: var(--violet-soft); color: var(--violet); }

.news { list-style: none; margin: 0; padding: 0; }
.news li { padding: 15px 0; border-top: 1px solid var(--line); }
.news li:first-child { border-top: 0; padding-top: 0; }
.news a { text-decoration: none; display: block; }
.news a:hover h3 { text-decoration: underline; }
.news h3 { margin: 6px 0 3px; }
.news p { margin: 0; }

.events { list-style: none; margin: 0; padding: 0; display: grid; gap: 14px; }
.events li { display: flex; gap: 14px; align-items: center; }
.date { flex: none; width: 54px; padding: 5px 0; text-align: center; border: 1px solid var(--line); border-radius: 10px; background: var(--paper); line-height: 1.1; }
.date b { display: block; font-size: 1.25rem; }
.date span { color: var(--muted); font-size: .68rem; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; }

.chips { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 14px; }
.chips button { padding: 5px 12px; border: 1px solid var(--line); border-radius: 6px; background: transparent; color: #4b5c57; font-size: .85rem; font-weight: 680; cursor: pointer; }
.chips button[aria-pressed="true"] { color: #fff; background: var(--blue); border-color: var(--blue); }
.links { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 10px; }
.link { position: relative; min-width: 0; display: flex; flex-direction: column; gap: 2px; padding: 12px; border: 1px solid var(--line); border-radius: 10px; background: var(--paper); text-decoration: none; }
.link:hover { border-color: #cdbf9f; background: var(--tint); }
.link strong { padding-right: 24px; }
.star { position: absolute; top: 6px; right: 6px; padding: 4px; border: 0; background: none; color: var(--muted); font-size: 1.1rem; line-height: 1; cursor: pointer; }
.star[aria-pressed="true"] { color: var(--warm); }
.empty { grid-column: 1 / -1; margin: 0; }

.status { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.status li { display: flex; justify-content: space-between; align-items: center; gap: 12px; }
.menu { display: grid; grid-template-columns: auto 1fr; gap: 6px 14px; margin: 0; }
.menu dt { font-weight: 700; }
.menu dd { margin: 0; }
.contact { margin: 14px 0 0; }

footer { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 12px 20px; padding: 24px clamp(18px, 4vw, 54px); color: var(--muted); border-top: 1px solid var(--line); background: rgba(255, 255, 255, .5); font-size: .82rem; }
footer nav { display: flex; gap: 18px; }
.legal { width: min(760px, calc(100% - 32px)); margin: 70px auto; }
.hint { margin: 12px 0 0; }
.button { min-height: 40px; padding: 9px 14px; border: 1px solid var(--blue); border-radius: 6px; color: #fff; background: var(--blue); font-weight: 720; cursor: pointer; text-decoration: none; }
.button.secondary { color: var(--blue); background: transparent; border-color: var(--input-line); }
.login { display: grid; gap: 10px; max-width: 360px; margin: 18px 0; }
.login input { min-height: 40px; padding: 9px 12px; border: 1px solid var(--input-line); border-radius: 6px; background: var(--paper); color: var(--ink); }
.login-error { margin: 14px 0 0; padding: 10px 12px; border-radius: 6px; color: #7d3a2c; background: var(--coral-soft); font-weight: 700; }
.admin { display: grid; gap: 24px; }
.admin-actions { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; }
.admin-actions form { margin: 0; }
.admin-msg { margin: 0; min-height: 1.5em; font-weight: 700; }
.admin-msg.ok { color: var(--green); }
.admin-msg.bad { color: #7d3a2c; }
.admin .card { display: grid; gap: 12px; align-content: start; }
.admin h2 { margin: 0; }
.admin .rows { display: grid; gap: 10px; }
.admin .row { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; padding-bottom: 10px; border-bottom: 1px solid var(--line); }
.admin input[type="text"], .admin input[type="email"], .admin input:not([type]), .admin select, .admin input[type="password"] { min-height: 38px; padding: 6px 10px; border: 1px solid var(--input-line); border-radius: 6px; background: var(--paper); color: var(--ink); min-width: 0; max-width: 100%; }
.row-tools { display: flex; gap: 4px; margin-left: auto; }
.mini { min-width: 34px; min-height: 34px; border: 1px solid var(--line); border-radius: 6px; background: var(--paper); color: var(--ink); cursor: pointer; }
.check { display: flex; gap: 8px; align-items: center; font-weight: 700; }
.pw-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 24px; }
.req-intro { margin: 0 0 12px; }
.req-form { display: grid; gap: 6px; }
.req-form label { font-size: .85rem; font-weight: 700; margin-top: 6px; }
.req-form input, .req-form select, .req-form textarea { min-height: 40px; padding: 8px 10px; border: 1px solid var(--input-line); border-radius: 6px; background: var(--paper); color: var(--ink); font: inherit; min-width: 0; max-width: 100%; }
.req-form textarea { resize: vertical; }
.req-form .button { margin-top: 10px; }
.req-result { margin: 12px 0 0; font-size: .9rem; }
.dept { display: grid; gap: 8px; padding: 14px; border: 1px solid var(--line); border-radius: 10px; background: var(--paper); }
.dept .row { padding-bottom: 0; border-bottom: 0; }
.req-form > div { display: grid; gap: 6px; }
.link-sep { grid-column: 1 / -1; display: flex; align-items: center; gap: 10px; margin: 8px 0 0; color: var(--muted); font-size: .72rem; font-weight: 800; letter-spacing: .12em; text-transform: uppercase; }
.link-sep::after { content: ""; flex: 1; border-top: 1px solid var(--line); }

/* Anmeldung im Layout des Leitungsraums */
body.login-page { background: #f3f6f2; color: #203e42; font: 16px/1.55 -apple-system, BlinkMacSystemFont, "Segoe UI", Arial, sans-serif; }
.login-wrap { min-height: 100vh; display: grid; place-items: center; padding: 24px; }
.login-card { width: min(100%, 470px); padding: clamp(25px, 5vw, 42px); background: #fff; border: 1px solid #d5e2db; border-radius: 16px; box-shadow: 0 16px 44px #173f4910; }
.login-logo { display: block; width: 180px; max-width: 60%; height: auto; margin: 0 0 22px; }
.login-card .brand { display: flex; align-items: center; gap: 10px; margin-bottom: 28px; color: #173f49; font: 700 1.2rem Georgia, serif; letter-spacing: -.02em; }
.brandmark { width: 32px; height: 32px; display: grid; place-items: center; border-radius: 8px; background: #173f49; color: #fff; font-size: 16px; }
.login-card .eyebrow { display: block; margin: 0 0 10px; color: #547f70; font-size: .72rem; font-weight: 800; letter-spacing: .12em; text-transform: uppercase; }
.login-card h1 { margin: 0 0 10px; color: #173f49; font: 500 2.3rem/1.12 Georgia, "Times New Roman", serif; letter-spacing: -.025em; }
.login-card .intro { margin: 0; color: #5d7371; }
.login-card form { display: grid; gap: 9px; margin-top: 27px; }
.login-card label { margin-top: 5px; color: #173f49; font-size: .9rem; font-weight: 700; }
.login-card input { width: 100%; min-height: 46px; padding: 10px 12px; border: 1px solid #b9cdc3; border-radius: 8px; background: #fff; color: #203e42; font: inherit; }
.login-card .button { display: inline-flex; justify-content: center; align-items: center; min-height: 44px; padding: 9px 16px; border: 1px solid #b8cbc3; border-radius: 8px; background: #fff; color: #173f49; font-size: .89rem; font-weight: 700; cursor: pointer; }
.login-card .button.primary { color: #fff; background: #173f49; border-color: #173f49; }
.login-card .button.primary:hover { background: #285a65; }
.login-card .button.full { width: 100%; margin-top: 8px; }
.login-card .notice.error { margin: 16px 0 0; padding: 16px 18px; border: 1px solid #e9c7bc; border-radius: 10px; background: #f8ece8; color: #803f32; font-size: .9rem; }
.login-card .quiet { margin: 18px 0 0; color: #687d7b; font-size: .8rem; }
.login-card :focus-visible { outline: 3px solid #286b7a; outline-offset: 3px; }
@media (max-width: 600px) { .login-wrap { padding: 14px; } .login-card { padding: 23px; } }

/* Modularer Adminbereich */
.admin-layout { display: grid; grid-template-columns: 210px minmax(0, 1fr); gap: 24px; align-items: start; }
.module-nav { position: sticky; top: 96px; display: grid; gap: 4px; }
.module-link { display: flex; justify-content: space-between; align-items: center; gap: 8px; padding: 10px 12px; border: 0; border-radius: 6px; background: transparent; color: #4b5c57; font: inherit; font-weight: 680; text-align: left; cursor: pointer; }
.module-link:hover, .module-link.active { color: var(--blue-ink-2); background: var(--tint); box-shadow: inset 3px 0 0 var(--blue); }
.module-link .pill { padding: 0 8px; font-size: .7rem; }
.panels { min-width: 0; display: grid; gap: 24px; }
.panel[hidden] { display: none; }
.panel-head { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 10px; }
.panel-head h2 { margin: 0; }
@media (max-width: 860px) {
  .admin-layout { grid-template-columns: minmax(0, 1fr); }
  .module-nav { position: static; display: flex; overflow-x: auto; padding-bottom: 4px; }
  .module-link { flex: none; white-space: nowrap; }
}
.admin > *, .admin-layout > *, .panels > * { min-width: 0; }
.admin-layout { max-width: 100%; }
.admin { grid-template-columns: minmax(0, 1fr); }
.admin .card { grid-template-columns: minmax(0, 1fr); }
.admin .card > * { min-width: 0; max-width: 100%; }
.admin .row > input:not([type="checkbox"]), .admin .row > select { flex: 1 1 140px; width: auto; }
.admin .row > .row-tools { flex: none; }
.admin .row > input[data-k="title"], .admin .row > input[data-k="text"], .admin .row > input[data-k="info"], .admin .row > input[data-k="href"], .admin .row > input[data-k="desc"], .admin .row > input[data-k="name"], .admin .row > input[data-k="cemail"] { flex: 2 1 220px; }

/* Raumbuchung */
.rooms { display: grid; gap: 18px; grid-template-columns: minmax(0, 1fr); }
.rooms > * { min-width: 0; }
.day-bar { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.day-bar input[type="date"], .req-form input[type="date"] { min-height: 40px; padding: 8px 10px; border: 1px solid var(--input-line); border-radius: 6px; background: var(--paper); color: var(--ink); font: inherit; }
.grid-wrap { padding: 0; overflow: auto; }
.room-grid { width: 100%; border-collapse: collapse; min-width: 560px; }
.room-grid th, .room-grid td { border-bottom: 1px solid var(--line); padding: 3px; text-align: left; vertical-align: top; }
.room-grid thead th { position: sticky; top: 0; padding: 10px; background: var(--paper); font-size: .85rem; }
.room-grid thead th small { display: block; color: var(--muted); font-weight: 400; }
.room-grid tbody th { width: 64px; padding: 8px 10px; color: var(--muted); font-size: .78rem; font-weight: 700; font-variant-numeric: tabular-nums; white-space: nowrap; }
.room-grid td { border-left: 1px solid var(--line); min-width: 150px; }
.slot, .slot-booked { display: block; width: 100%; min-height: 34px; border: 0; border-radius: 6px; font: inherit; text-align: left; cursor: pointer; }
.slot { padding: 6px 8px; background: transparent; color: var(--muted); font-size: .78rem; }
.slot:hover:not(:disabled) { background: var(--green-soft); color: var(--green); }
.slot:disabled { cursor: not-allowed; opacity: .35; }
.slot-booked { height: 100%; padding: 6px 8px; background: var(--tint); box-shadow: inset 3px 0 0 var(--blue); color: var(--blue-ink-2); }
.slot-booked:hover { filter: brightness(.96); }
.slot-booked strong, .slot-booked small { display: block; overflow-wrap: anywhere; }
.slot-booked small { color: #4b6d86; font-size: .75rem; }
.room-forms { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 18px; align-items: start; }
.two { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.two > div { display: grid; gap: 6px; }
.code { display: inline-block; margin-top: 4px; padding: 4px 10px; border-radius: 6px; background: var(--green-soft); color: var(--green); font: 700 1.1rem ui-monospace, Menlo, monospace; letter-spacing: .08em; }
.today-list { list-style: none; margin: 0 0 14px; padding: 0; display: grid; gap: 8px; font-size: .9rem; }
.today-list li { display: grid; gap: 1px; }
.today-list small { color: var(--muted); }
.admin .row .narrow, .admin .row > input.narrow { flex: 0 0 90px; width: 90px; }
.admin input[type="number"], .admin input[type="time"] { min-height: 38px; padding: 6px 10px; border: 1px solid var(--input-line); border-radius: 6px; background: var(--paper); color: var(--ink); }

/* MAV */
.mav { display: grid; gap: 18px; grid-template-columns: minmax(0, 1fr); }
.mav > * { min-width: 0; }
.mav-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 18px; align-items: start; }
.mav-members, .mav-docs { list-style: none; margin: 0; padding: 0; display: grid; gap: 14px; }
.mav-members li, .mav-docs li { display: grid; gap: 2px; padding-bottom: 12px; border-bottom: 1px solid var(--line); overflow-wrap: anywhere; }
.mav-members li:last-child, .mav-docs li:last-child { border-bottom: 0; padding-bottom: 0; }
.groups { list-style: none; margin: 0; padding: 0; }
.groups li { padding: 14px 0; border-top: 1px solid var(--line); }
.groups li:first-child { border-top: 0; padding-top: 0; }
.groups p { margin: 4px 0 0; white-space: pre-line; }
.groups a { color: var(--blue); }
#groups-more { margin-top: 10px; }
.admin .row > textarea[data-k] { flex: 3 1 300px; min-width: 0; min-height: 84px; padding: 8px 10px; border: 1px solid var(--input-line); border-radius: 6px; background: var(--paper); color: var(--ink); font: inherit; resize: vertical; }
#news p { white-space: pre-line; }
.mav-admin textarea { width: 100%; min-height: 80px; padding: 8px 10px; border: 1px solid var(--input-line); border-radius: 6px; background: var(--paper); color: var(--ink); font: inherit; resize: vertical; }

/* Rechtliche Seiten */
.legal h2 { margin: 28px 0 8px; font-size: 1.2rem; }
.legal h3 { margin: 18px 0 6px; font-size: 1rem; }
.legal ul { padding-left: 20px; }
.legal li { margin: 6px 0; }
.legal code { padding: 1px 5px; border-radius: 4px; background: #eef1ef; font-size: .85em; }
.todo { background: #fbf1e3; color: #6f4710; padding: 0 4px; border-radius: 4px; }

/* Dezente Gliederung: Modulfarbe als Kopfkante und Icon-Kachel, Tiefe über Schatten.
   Drei ruhige Töne nach Art des Moduls: Information (blau), Handeln (grün), Gremium (violett). */
.card { background: var(--paper); box-shadow: 0 1px 2px rgba(38, 64, 55, .06), 0 12px 30px rgba(38, 64, 55, .08); border-top: 3px solid var(--accent, var(--line)); }
.card.notice { border-top: 3px solid var(--warm); }
[data-module="news"], [data-module="events"], [data-module="links"] { --accent: #6f9bc4; --accent-ink: var(--blue); --accent-soft: var(--blue-soft); }
[data-module="rooms"], [data-module="fleet"], [data-module="servicestation"] { --accent: #7fb09c; --accent-ink: var(--green); --accent-soft: var(--green-soft); }
[data-module="mav"] { --accent: #a99ccb; --accent-ink: var(--violet); --accent-soft: var(--violet-soft); }
[data-module="status"] { --accent: #bcc9c3; --accent-ink: #4d5e58; --accent-soft: #eef1ef; }
.rooms .card { --accent: #7fb09c; --accent-ink: var(--green); --accent-soft: var(--green-soft); }
.mav .card { --accent: #a99ccb; --accent-ink: var(--violet); --accent-soft: var(--violet-soft); }
.card h2 { display: flex; align-items: center; gap: 10px; }
.ico { flex: none; width: 34px; height: 34px; display: grid; place-items: center; border-radius: 9px; color: var(--accent-ink, var(--blue)); background: var(--accent-soft, var(--blue-soft)); }
.admin .card, .admin .card.notice { border-top-color: var(--line); }
.admin .card { box-shadow: 0 1px 2px rgba(38, 64, 55, .05), 0 8px 22px rgba(38, 64, 55, .05); }
.login-card, .grid-wrap { border-top-width: 1px; }

/* Häufig genutzt: Schnellkacheln unter der Begrüßung */
[hidden] { display: none !important; }
.tiles { display: grid; grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); gap: 14px; margin: 0 0 24px; }
.tile { display: flex; align-items: center; gap: 14px; padding: 14px 16px; border: 1px solid var(--line); border-radius: 12px; background: var(--paper); color: var(--ink); text-decoration: none; box-shadow: 0 1px 2px rgba(38, 64, 55, .06), 0 8px 20px rgba(38, 64, 55, .05); transition: transform .15s, box-shadow .15s, border-color .15s; }
.tile:hover { transform: translateY(-2px); border-color: var(--accent); box-shadow: 0 1px 2px rgba(38, 64, 55, .06), 0 14px 28px rgba(38, 64, 55, .1); }
.tile .ico { width: 42px; height: 42px; border-radius: 11px; }
.tile-text { min-width: 0; display: grid; }
.tile-text strong { font-size: 1rem; }
.tile-text small { color: var(--muted); font-size: .82rem; overflow-wrap: anywhere; }
@media (prefers-reduced-motion: reduce) { .tile { transition: none; } .tile:hover { transform: none; } }
html { scroll-behavior: smooth; }
.card h2 { scroll-margin-top: 100px; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
.admin .row > input[data-k="title"], .admin .row > input[data-k="text"] { flex: 3 1 300px; }

/* Schnellzugriff: Reiter, getönte Fläche, umschaltbar zwischen Liste und Kacheln */
.card-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 14px; }
.card-head h2 { margin: 0; }
.seg { display: inline-flex; padding: 3px; border: 1px solid var(--line); border-radius: 8px; background: var(--paper); }
.seg button { display: grid; place-items: center; width: 32px; height: 28px; border: 0; border-radius: 6px; background: transparent; color: var(--muted); cursor: pointer; }
.seg button:hover { color: var(--ink); }
.seg button[aria-pressed="true"] { background: var(--tint); box-shadow: inset 0 0 0 1px var(--tint-line); color: var(--blue); }
[data-module="links"] .chips { gap: 0; margin: 0 0 12px; overflow-x: auto; border-bottom: 1px solid var(--line); flex-wrap: nowrap; }
[data-module="links"] .chips button { flex: none; padding: 8px 12px; border: 0; border-bottom: 2px solid transparent; border-radius: 0; margin-bottom: -1px; background: transparent; color: var(--muted); font-size: .85rem; font-weight: 680; }
[data-module="links"] .chips button:hover { color: var(--ink); }
[data-module="links"] .chips button[aria-pressed="true"] { color: var(--blue); background: transparent; border-bottom-color: var(--blue); }
.links-panel { padding: 8px; border: 1px solid var(--tint-line); border-radius: 12px; background: var(--tint); }
.links { display: grid; gap: 0; grid-template-columns: minmax(0, 1fr); }
.link { position: relative; display: grid; grid-template-columns: auto minmax(0, 1fr) auto auto; align-items: center; gap: 12px; padding: 9px 10px; border: 0; border-radius: 8px; background: transparent; }
.link + .link { border-top: 1px solid var(--tint-line); }
.link:hover { background: var(--hover); border-color: transparent; box-shadow: inset 0 0 0 1px var(--hover-line); }
.link:hover + .link, .link:hover { border-top-color: transparent; }
.link-text { min-width: 0; display: grid; gap: 1px; }
.link strong { padding: 0; font-weight: 650; overflow-wrap: anywhere; }
.badge { width: 32px; height: 32px; display: grid; place-items: center; border-radius: 50%; font-size: .85rem; font-weight: 750; }
.badge.t0 { background: var(--blue-soft); color: var(--blue); }
.badge.t1 { background: var(--green-soft); color: var(--green); }
.badge.t2 { background: var(--violet-soft); color: var(--violet); }
.badge.t3 { background: #f3ecdf; color: #8a5a1f; }
.go { color: var(--muted); opacity: 0; transition: opacity .15s; }
.link:hover .go, .link:focus-within .go { opacity: 1; }
.star { position: static; padding: 4px 6px; }
.link-sep { padding: 12px 10px 4px; margin: 0; }
.link-sep:first-child { padding-top: 4px; }
.link-sep::after { border-top-color: var(--tint-line); }
/* Kacheln */
.links[data-view="tiles"] { grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 8px; }
.links[data-view="tiles"] .link { grid-template-columns: auto minmax(0, 1fr); align-content: start; align-items: start; padding: 12px; border: 1px solid var(--line); border-radius: 10px; background: var(--white); }
.links[data-view="tiles"] .link + .link { border-top: 1px solid var(--line); }
.links[data-view="tiles"] .link:hover { border-color: #cdbf9f; }
.links[data-view="tiles"] .link-text { padding-right: 18px; }
.links[data-view="tiles"] .star { position: absolute; top: 6px; right: 6px; }
.links[data-view="tiles"] .go { display: none; }
.links[data-view="tiles"] .link-sep { grid-column: 1 / -1; }
@media (prefers-reduced-motion: reduce) { .go { transition: none; } }
[data-module="links"] .chips { scrollbar-width: none; }
[data-module="links"] .chips::-webkit-scrollbar { display: none; }
.links[data-view="tiles"] .link { grid-template-columns: minmax(0, 1fr); gap: 8px; }
.links[data-view="tiles"] .link-text { padding-right: 0; }
.link strong { overflow-wrap: break-word; hyphens: auto; }
.links[data-view="tiles"] { grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); }

/* Schnellkacheln als ein durchgehendes Band */
.tiles { display: flex; gap: 0; margin: 0 0 24px; padding: 4px; border: 1px solid var(--line); border-radius: 14px; background: var(--tiles); border-color: var(--tint-line); box-shadow: 0 1px 2px rgba(38, 64, 55, .05), 0 10px 26px rgba(38, 64, 55, .06); }
.tiles .tile { flex: 1 1 0; min-width: 0; border: 0; border-radius: 10px; background: transparent; box-shadow: none; transform: none; }
.tiles .tile + .tile { position: relative; }
.tiles .tile + .tile::before { content: ""; position: absolute; left: 0; top: 18%; bottom: 18%; border-left: 1px solid var(--tint-line); }
.tiles .tile:hover { background: var(--hover); transform: none; box-shadow: inset 0 0 0 1px var(--hover-line); }
.tiles .tile:hover::before, .tiles .tile:hover + .tile::before { opacity: 0; }
.tile-text strong { display: flex; align-items: center; gap: 6px; }
.dot { width: 8px; height: 8px; border-radius: 50%; background: var(--violet); flex: none; }
@media (max-width: 760px) {
  .tiles { flex-direction: column; }
  .tiles .tile + .tile::before { left: 18px; right: 18px; top: 0; bottom: auto; border-left: 0; border-top: 1px solid var(--tint-line); }
}

.part-row { gap: 18px; }
/* Kacheln als erkennbar klickbar: Pfeil-Chip rechts, Titel in Modulfarbe, deutlicher Hover */
.tile { cursor: pointer; }
.tile-text { flex: 1 1 auto; }
.tile .tile-text strong { color: var(--accent-ink, var(--blue)); }
.go-chip { flex: none; margin-left: auto; width: 30px; height: 30px; display: grid; place-items: center; border: 1px solid var(--accent, var(--line)); border-radius: 50%; background: var(--white); color: var(--accent-ink, var(--blue)); font-size: 1rem; line-height: 1; transition: background .15s, color .15s, transform .15s; }
.tile:hover .go-chip, .tile:focus-visible .go-chip { background: var(--accent-ink, var(--blue)); border-color: var(--accent-ink, var(--blue)); color: #fff; transform: translateX(2px); }
.tile:hover .tile-text strong { text-decoration: underline; text-underline-offset: 3px; }
@media (prefers-reduced-motion: reduce) { .go-chip { transition: none; } .tile:hover .go-chip { transform: none; } }

.fleet .fleet-pools { margin: 0; }
.fleet .fleet-pools button { padding: 7px 14px; font-weight: 700; }

/* Fuhrpark: Ansicht Tag/Woche/Monat */
.view-seg button { width: auto; padding: 0 14px; font-weight: 700; font-size: .85rem; }
.legend { display: flex; flex-wrap: wrap; gap: 16px; font-size: .82rem; color: var(--muted); }
.legend span { display: inline-flex; align-items: center; gap: 6px; }
.sw { width: 14px; height: 14px; border-radius: 4px; display: inline-block; border: 1px solid rgba(38, 64, 55, .12); }
.sw.free, .cal-cell.free, .heat td.free { --cell: #e9f4ee; }
.sw.part, .cal-cell.part, .heat td.part { --cell: #f6e7c8; }
.sw.full, .cal-cell.full, .heat td.full { --cell: #b9d3ec; }
.sw { background: var(--cell, var(--white)); }
.sw.free { background: #e9f4ee; } .sw.part { background: #f6e7c8; } .sw.full { background: #b9d3ec; }
.cal, .heat { width: 100%; border-collapse: separate; border-spacing: 0; }
.cal th, .heat th { padding: 8px; background: var(--paper); font-size: .8rem; text-align: center; }
.cal thead th small, .heat thead th small { display: block; color: var(--muted); font-weight: 500; }
.cal tbody th, .heat tbody th { text-align: left; position: sticky; left: 0; z-index: 1; min-width: 130px; border-right: 1px solid var(--line); box-shadow: 2px 0 0 rgba(38, 64, 55, .03); }
.cal tbody th small, .heat tbody th small { display: block; color: var(--muted); font-weight: 400; }
.cal { min-width: 760px; }
.cal td, .heat td { border-bottom: 1px solid var(--line); border-left: 1px solid rgba(38, 64, 55, .06); padding: 0; vertical-align: top; }
.cal-cell { background: var(--cell); }
.cal-cell button { display: grid; gap: 3px; align-content: start; width: 100%; min-height: 64px; padding: 6px; border: 0; background: transparent; text-align: left; cursor: pointer; font: inherit; color: var(--ink); }
.cal-cell button:hover, .heat td button:hover { box-shadow: inset 0 0 0 2px var(--blue); }
.chip-b { display: block; padding: 2px 6px; border-radius: 5px; background: rgba(255, 255, 255, .75); font-size: .72rem; line-height: 1.3; overflow-wrap: anywhere; }
.free-t { color: #4f7a67; font-size: .75rem; }
.is-we { filter: saturate(.7); }
.is-today { box-shadow: inset 0 0 0 2px rgba(53, 111, 168, .55); }
thead .is-today { color: var(--blue); }
.heat { min-width: 880px; }
.heat thead th { padding: 6px 2px; min-width: 24px; font-size: .75rem; }
.heat td { background: var(--cell); }
.heat td button { display: block; width: 100%; height: 34px; border: 0; background: transparent; cursor: pointer; }
.sr-only { position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }

/* CSV-Import als auffälliger Block */
.csv-banner { display: flex; flex-wrap: wrap; align-items: center; gap: 14px 16px; padding: 16px 18px; border: 2px dashed #8fb5d6; border-radius: 12px; background: #eef5fb; }
.csv-banner:focus-within, .csv-banner.drag { border-color: var(--blue); background: #e2eef9; }
.csv-banner .ico { width: 44px; height: 44px; border-radius: 12px; background: var(--white); color: var(--blue); }
.csv-text { flex: 1 1 240px; min-width: 0; display: grid; gap: 2px; }
.csv-text p { margin: 0; }
.csv-pick { cursor: pointer; }
.csv-pick:focus-within { outline: 3px solid rgba(53, 111, 168, .35); outline-offset: 2px; }
.csv-options { margin-top: 10px; display: grid; gap: 8px; }
.admin .rows { grid-template-columns: minmax(0, 1fr); }
.admin .rows > * { min-width: 0; }
.admin .row > input[data-k="title"], .admin .row > input[data-k="text"] { flex: 3 1 min(300px, 100%); }

/* Schnellsuche wie im IT-Portal */
.visually-hidden { position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
.palette-open kbd { margin-left: 6px; padding: 1px 6px; border: 1px solid var(--line); border-radius: 4px; background: var(--paper); font: inherit; font-size: .75rem; color: var(--muted); }
.palette { width: 100%; max-width: min(560px, calc(100vw - 32px)); margin: 12vh auto 0; padding: 0; border: 1px solid var(--line); border-radius: 10px; background: #fffefa; color: var(--ink); box-shadow: 0 24px 60px rgba(31, 42, 38, .28); }
.palette::backdrop { background: rgba(31, 42, 38, .38); }
.palette-input { box-sizing: border-box; width: 100%; padding: 16px 18px; border: 0; border-bottom: 1px solid var(--line); border-radius: 10px 10px 0 0; background: transparent; color: var(--ink); font: inherit; font-size: 1.05rem; }
.palette-input:focus-visible { outline: 2px solid var(--blue); outline-offset: -2px; }
.palette-list { max-height: 50vh; margin: 0; padding: 6px; overflow-y: auto; list-style: none; }
.palette-item { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 10px 12px; border-radius: 6px; cursor: pointer; }
.palette-item.active { background: rgba(53, 111, 168, .1); box-shadow: inset 3px 0 0 var(--blue); }
.palette-label { min-width: 0; overflow-wrap: anywhere; font-weight: 680; }
.palette-item .pill { flex: none; text-align: right; }
.palette-empty, .palette-hint { margin: 0; padding: 10px 18px 14px; color: var(--muted); font-size: .82rem; }
.palette-empty { padding-bottom: 4px; }
@media (max-width: 760px) { .palette-open kbd { display: none; } }

.backup-last { margin: 0; padding: 10px 12px; border-radius: 8px; background: #eef1ef; font-weight: 650; }
.backup-last.ok { background: var(--green-soft); color: var(--green); }
.backup-last.warn { background: var(--warm-soft); color: #8a5516; }
.backup-form { display: grid; gap: 8px; justify-items: start; }
.button.danger { color: #fff; background: #a85e4d; border-color: #a85e4d; }

/* Nach-oben-Knopf (totop.js) */
.totop { position: fixed; right: max(16px, env(safe-area-inset-right)); bottom: max(16px, env(safe-area-inset-bottom)); z-index: 30; width: 44px; height: 44px; display: grid; place-items: center; padding: 0; border: 1px solid var(--line); border-radius: 50%; color: var(--blue); background: var(--paper); box-shadow: 0 1px 2px rgba(38, 64, 55, .08), 0 10px 24px rgba(38, 64, 55, .14); cursor: pointer; }
.totop[hidden] { display: none; }
.totop:hover { color: #fff; background: var(--blue); border-color: var(--blue); }
@media print { .totop { display: none; } }

/* Anmeldeebene in der Kopfzeile: dezent, nur Text mit Punkt */
.whoami { display: inline-flex; align-items: center; gap: 7px; max-width: 220px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--muted); font-size: .82rem; }
.whoami::before { content: ""; flex: none; width: 7px; height: 7px; border-radius: 50%; background: #7fb09c; }
@media (max-width: 640px) { .whoami { display: none; } }

/* Passwörter im Adminbereich: drei gleich hohe Karten, Eingabefelder unten bündig */
.pw-grid { gap: 18px; margin-top: 14px; }
.pw-card { display: flex; flex-direction: column; gap: 6px; padding: 18px 18px 20px; border: 1px solid var(--line); border-radius: 12px; background: var(--white); box-shadow: 0 1px 2px rgba(38, 64, 55, .05); }
.pw-card h3 { margin: 0; color: var(--blue); font-size: 1.05rem; }
.pw-card .pw-desc { margin: 0 0 14px; }
.pw-card .pw-fields { display: grid; gap: 6px; margin-top: auto; }
.pw-card label { margin-top: 6px; font-size: .85rem; font-weight: 700; }
.pw-card label .muted { font-weight: 400; }
.pw-card input { width: 100%; min-height: 40px; padding: 9px 12px; border: 1px solid var(--input-line); border-radius: 8px; background: var(--paper); color: var(--ink); }
.pw-card .button { width: 100%; margin-top: 10px; }
.pw-reset { margin-top: 22px; padding: 16px 18px; border: 1px dashed var(--line); border-radius: 12px; background: rgba(255, 255, 255, .55); }
.pw-reset h3 { margin: 0 0 4px; font-size: 1rem; }
.pw-reset p { margin: 6px 0; }

/* Vorlagen */
.tpl-tools { display: grid; gap: 12px; margin: 16px 0 8px; }
.tpl-search input { width: 100%; min-height: 44px; padding: 10px 14px; border: 1px solid var(--input-line); border-radius: 10px; background: var(--paper); color: var(--ink); }
.tpl-list { display: grid; gap: 10px; margin-top: 10px; }
.tpl-row { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; gap: 14px; align-items: center; padding: 12px 14px; border: 1px solid var(--line); border-radius: 12px; background: var(--white); }
.tpl-row:hover { border-color: var(--blue); }
.tpl-row h3 { margin: 0 0 2px; font-size: 1rem; }
.tpl-row p { margin: 0; }
.tpl-icon { width: 48px; height: 48px; display: grid; place-items: center; border-radius: 10px; font-size: .72rem; font-weight: 800; letter-spacing: .04em; color: #fff; background: #6b7a86; }
.tpl-word { background: #2b6cb0; } .tpl-excel { background: #2f855a; } .tpl-ppt { background: #c05621; } .tpl-odf { background: #5a67a8; } .tpl-pdf { background: #b83232; }
.tpl-upload { display: grid; gap: 10px; margin: 14px 0 22px; padding: 16px; border: 1px dashed var(--line); border-radius: 12px; background: rgba(255, 255, 255, .55); }
.tpl-upload h3 { margin: 0; }
.tpl-item .row { margin: 6px 0; }
@media (max-width: 640px) { .tpl-row { grid-template-columns: auto 1fr; } .tpl-row .button { grid-column: 2; justify-self: start; } }
/* Konten: geänderte, noch nicht gespeicherte Zeile */
#accounts .dept.dirty { border-color: var(--warm); box-shadow: 0 0 0 2px rgba(176, 116, 54, .18); }

/* Farbschemata (totop.js setzt html[data-theme]; ohne Wert gilt das Creme von :root) */
.theme-switch button { width: auto; padding: 0 10px; font-size: .8rem; font-weight: 680; }
html[data-theme="green"] {
  --tint: linear-gradient(180deg, #d9eddf, #f7fbf8); --tint-line: #bcd9c6;
  --bar: linear-gradient(180deg, rgba(212, 235, 220, .96), rgba(255, 255, 255, .94)); --bar-line: #bcd9c6;
  --tiles: linear-gradient(180deg, #d9eddf, #ffffff); --hover-line: #a9cdb6;
}
html[data-theme="pink"] {
  --blue: #b83a76; --blue-soft: #fbe9f1; --blue-ink: #962d5f; --blue-ink-2: #7d244f; --input-line: #d9a0ba;
  --tint: linear-gradient(180deg, #fde8f1, #fff8fb); --tint-line: #f0c3d5;
  --bar: linear-gradient(180deg, rgba(252, 226, 238, .96), rgba(255, 255, 255, .94)); --bar-line: #f0c3d5;
  --page: radial-gradient(circle at 8% 0%, rgba(232, 128, 172, .16), transparent 30rem), linear-gradient(180deg, #fff4f8 0%, #f9ecf2 100%);
  --tiles: linear-gradient(180deg, #fde8f1, #ffffff); --hover-line: #e8b0c8;
}
html[data-theme="dark"] {
  color-scheme: dark;
  --ink: #e6ece9; --muted: #9aaba5; --paper: #1b2522; --line: #33423d;
  --blue: #4a86c0; --blue-soft: #1d2f40; --green: #6fc3a0; --green-soft: #1b3329;
  --coral: #e0917f; --coral-soft: #3a2621; --violet: #b3a6dd; --violet-soft: #2b2640;
  --warm: #d9a05b; --warm-soft: #3a2e1b; --shadow: 0 16px 40px rgba(0, 0, 0, .35);
  --tint: linear-gradient(180deg, #26302c, #1f2926); --tint-line: #3a4a43;
  --bar: rgba(22, 29, 27, .92); --bar-line: rgba(51, 66, 61, .9);
  --page: linear-gradient(180deg, #121917, #0f1513);
  --card: rgba(27, 37, 34, .9); --tiles: linear-gradient(180deg, #222d29, #1b2522);
  --white: #1b2522; --hover: #2a3733; --hover-line: #44574f; --input-line: #4b5f57;
  --blue-ink: #9cc4ea; --blue-ink-2: #b4d3f0; --warm-ink: #e8b878;
}
html[data-theme="dark"] .pill:not(.blue):not(.green):not(.warm):not(.violet) { background: #2a3733; color: #b7c6c0; }
html[data-theme="dark"] [data-module="status"] { --accent-soft: #2a3733; --accent-ink: #b7c6c0; }
html[data-theme="dark"] .sw.free, html[data-theme="dark"] .cal-cell.free, html[data-theme="dark"] .heat td.free { --cell: #1f3a2d; }
html[data-theme="dark"] .sw.part, html[data-theme="dark"] .cal-cell.part, html[data-theme="dark"] .heat td.part { --cell: #4a3b1c; }
html[data-theme="dark"] .sw.full, html[data-theme="dark"] .cal-cell.full, html[data-theme="dark"] .heat td.full { --cell: #1f3a55; }
/* Dunkel: Stellen mit festen hellen Farben (Raumbuchung, Fuhrpark, Vorlagen, MAV, Fußzeile, Schnellsuche) */
html[data-theme="dark"] footer { background: rgba(255, 255, 255, .04); }
html[data-theme="dark"] .chip-b { background: rgba(255, 255, 255, .12); }
html[data-theme="dark"] .pw-reset, html[data-theme="dark"] .tpl-upload { background: rgba(255, 255, 255, .04); }
html[data-theme="dark"] .palette { background: var(--paper); }
html[data-theme="dark"] .chips button { color: var(--muted); }
html[data-theme="dark"] .slot-booked small { color: var(--blue-ink); }
html[data-theme="dark"] .free-t { color: var(--green); }
html[data-theme="dark"] .todo { background: var(--warm-soft); color: var(--warm-ink); }
html[data-theme="dark"] .badge.t3 { background: var(--warm-soft); color: var(--warm-ink); }
html[data-theme="dark"] .backup-last.warn { color: var(--warm-ink); }
html[data-theme="dark"] .csv-banner { border-color: #3d5f7d; background: var(--blue-soft); }
html[data-theme="dark"] .csv-banner:focus-within, html[data-theme="dark"] .csv-banner.drag { background: #223a50; }
html[data-theme="dark"] .sw { background: var(--cell); }
html[data-theme="dark"] .backup-last { background: #2a3733; }
html[data-theme="dark"] .admin-msg.bad { color: #f0a595; }
html[data-theme="dark"] .button:not(.secondary):not(.danger) { background: #3a74ad; border-color: #3a74ad; }
html[data-theme="dark"] .button.secondary { color: var(--blue-ink); }
html[data-theme="dark"] .csv-banner .ico { color: var(--blue-ink); }
html[data-theme="dark"] .tile .tile-text strong { color: var(--ink); }
html[data-theme="dark"] .groups a { color: var(--blue-ink); }

/* Schmale Navigation auf den Unterseiten */
.subnav { display: flex; gap: 6px; margin: 0 0 18px; padding: 4px; overflow-x: auto; border: 1px solid var(--tint-line, var(--line)); border-radius: 12px; background: var(--tiles, var(--paper)); scrollbar-width: none; }
.subnav::-webkit-scrollbar { display: none; }
.subnav a { flex: none; display: inline-flex; align-items: center; gap: 7px; padding: 7px 12px; border-radius: 9px; color: var(--ink); font-size: .9rem; font-weight: 600; text-decoration: none; white-space: nowrap; }
.subnav a svg { color: var(--accent-ink, var(--blue)); }
.subnav a:hover { background: var(--hover); }
.subnav a:focus-visible { outline: 2px solid var(--accent-ink, var(--blue)); outline-offset: 1px; }
.subnav a[aria-current="page"] { background: var(--accent-soft, var(--blue-soft)); color: var(--accent-ink, var(--blue)); }
#mav-intro { margin: 0; } /* Einleitung der MAV-Seite steht unter der Navigationsleiste */
#mav-intro:empty { display: none; }
.rooms > .subnav, .mav > .subnav { margin: -18px 0 0; } /* Grid-Seiten haben schon 18px Lücke: gleicher Abstand wie auf Block-Seiten */
.news a { position: relative; }
.news .dot { position: absolute; top: 5px; right: 0; background: var(--accent-ink, var(--blue)); }
.cancel-dialog { width: calc(100% - 32px); max-width: 460px; margin: 14vh auto 0; color: var(--ink); }
.cancel-dialog::backdrop { background: rgba(31, 42, 38, .38); }
.cancel-dialog .button.secondary { margin-top: 10px; }
.chip-b[data-id] { cursor: pointer; }
.chip-b[data-id]:hover { outline: 2px solid var(--blue); }

/* Autoren-Bereich: Einträge als gegliederte Karten mit beschrifteten Feldern */
.admin-intro { margin: 0; padding: 14px 18px; border: 1px solid var(--tint-line); border-radius: 12px; background: var(--tint); font-size: .92rem; line-height: 1.55; }
.admin .panel-head { padding-bottom: 14px; border-bottom: 1px solid var(--line); }
.admin .panel-head h2 .count { min-width: 26px; padding: 1px 9px; border-radius: 99px; background: var(--blue-soft); color: var(--blue-ink); font-size: .78rem; font-weight: 800; text-align: center; }
.entries { display: grid; gap: 16px; }
.entry { border: 1px solid var(--line); border-radius: 12px; background: var(--paper); overflow: hidden; transition: border-color .15s, box-shadow .15s; }
.entry:focus-within { border-color: var(--blue); box-shadow: 0 0 0 3px rgba(53, 111, 168, .14); }
.entry-head { display: flex; align-items: center; gap: 12px; padding: 9px 10px 9px 14px; border-bottom: 1px solid var(--tint-line); background: var(--tint); }
.entry-num { flex: none; width: 26px; height: 26px; display: grid; place-items: center; border-radius: 50%; background: var(--blue-soft); color: var(--blue-ink); font-size: .8rem; font-weight: 800; }
.entry-title { flex: 1 1 auto; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: .98rem; }
.entry-title.is-empty { color: var(--muted); font-weight: 600; }
.entry-head .row-tools { gap: 6px; }
.entry-head .mini { min-width: 34px; min-height: 34px; font-size: .95rem; transition: background .12s, color .12s; }
.entry-head .mini:hover:not(:disabled) { background: var(--blue-soft); color: var(--blue-ink); }
.entry-head .mini.danger:hover:not(:disabled) { background: var(--coral-soft, #fbe9e4); color: #9a3b28; }
.entry-head .mini:disabled { opacity: .35; cursor: default; }
.entry-body { display: grid; grid-template-columns: repeat(auto-fit, minmax(210px, 1fr)); gap: 16px; padding: 16px; }
.fld { display: grid; gap: 6px; align-content: start; min-width: 0; }
.fld.wide { grid-column: 1 / -1; }
.fld-label { color: var(--muted); font-size: .72rem; font-weight: 800; letter-spacing: .07em; text-transform: uppercase; }
.admin .fld input, .admin .fld select, .admin .fld textarea { width: 100%; max-width: 100%; min-height: 42px; padding: 9px 12px; border: 1px solid var(--input-line); border-radius: 8px; background: var(--white); color: var(--ink); font: inherit; }
.admin .fld textarea { min-height: 96px; resize: vertical; line-height: 1.5; }
.fld input::placeholder, .fld textarea::placeholder { color: var(--muted); opacity: .7; }
.admin .fld input:focus, .admin .fld select:focus, .admin .fld textarea:focus { outline: 2px solid var(--blue); outline-offset: 0; border-color: transparent; }
.fld-count { justify-self: end; margin-top: -2px; color: var(--muted); font-size: .74rem; font-variant-numeric: tabular-nums; }
.fld-count.near { color: var(--warm-ink); font-weight: 700; }
.empty { margin: 0; padding: 28px 18px; border: 1.5px dashed var(--line); border-radius: 12px; color: var(--muted); text-align: center; }
@media (prefers-reduced-motion: reduce) { .entry, .entry-head .mini { transition: none; } }

/* Fuhrpark-, Raum- und Vorlagen-Editor: gleiche Sprache wie die Einträge (Karten, beschriftete Felder) */
.panel h3 { margin: 24px 0 -2px; padding-bottom: 8px; border-bottom: 1px solid var(--line); color: var(--muted); font-size: .76rem; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; }
.panel h3:first-child { margin-top: 4px; }
.subcard { display: grid; gap: 14px; padding: 16px; border: 1px solid var(--line); border-radius: 12px; background: var(--paper); }
.subcard > h3 { margin: 0; padding: 0; border: 0; }
.fgrid { display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); gap: 14px 16px; }
.fgrid.wide, .entry-body > .wide, .fgrid > .wide { grid-column: 1 / -1; }
.item { display: grid; gap: 12px; padding: 14px; border: 1px solid var(--line); border-radius: 10px; background: var(--paper); }
.entry-body > .item { background: var(--tint); border-color: var(--tint-line); }
.item-foot { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 10px 14px; }
.item .row-tools, .tpl-actions { gap: 6px; margin-left: 0; flex-wrap: wrap; }
.item .mini { min-width: 34px; min-height: 34px; transition: background .12s, color .12s; }
.item .mini:hover:not(:disabled) { background: var(--blue-soft); color: var(--blue-ink); }
.item .mini.danger:hover { background: var(--coral-soft); color: #9a3b28; }
.add-line { display: flex; }
.file-badge { flex: none; min-width: 44px; padding: 3px 8px; border-radius: 7px; background: var(--blue-soft); color: var(--blue-ink); font-size: .72rem; font-weight: 800; letter-spacing: .04em; text-align: center; }
.tpl-file .muted { overflow-wrap: anywhere; }
#bookings > .row, #fleet-bookings > .row { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 10px 16px; padding: 12px 14px; border: 1px solid var(--line); border-radius: 10px; background: var(--paper); }
#bookings .row-tools, #fleet-bookings .row-tools { margin-left: 0; flex-wrap: wrap; }
.subcard .check { font-weight: 650; }
.fgrid select { appearance: auto; }
#fleet-root, #rooms-root, #templates-root { display: grid; gap: 14px; min-width: 0; }
#fleet-root > *, #rooms-root > *, #templates-root > * { min-width: 0; }
.admin .fld input[type="file"] { padding: 7px 10px; cursor: pointer; }
.admin input[type="file"]::file-selector-button { margin-right: 12px; padding: 6px 14px; border: 1px solid var(--input-line); border-radius: 6px; background: var(--blue-soft); color: var(--blue-ink); font: inherit; font-weight: 700; cursor: pointer; }
.panels > #editor { display: contents; } /* der Container selbst darf keine leere Rasterzeile mit Abstand erzeugen */

/* Adminbereich: gleiche Optik wie der Autoren-Bereich */
.head-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 16px; }
.head-actions .check { font-weight: 650; font-size: .9rem; }
.admin .part-row { display: flex; flex-wrap: wrap; gap: 8px 12px; padding: 10px 14px; border: 1px solid var(--tint-line); border-radius: 10px; background: var(--tint); border-bottom: 1px solid var(--tint-line); }
.admin .part-row .check { font-weight: 650; font-size: .9rem; }
.entry-body > .checks { display: flex; flex-wrap: wrap; gap: 8px 22px; }
.entry-head .pill { flex: none; }
#accounts .entry.dirty { border-color: var(--warm); box-shadow: 0 0 0 3px rgba(176, 116, 54, .18); }
.admin .fld input[readonly] { background: var(--tint); color: var(--muted); }
.admin .panel > .row { padding-bottom: 0; border-bottom: 0; }
.backup-form { display: grid; gap: 12px; padding: 16px; border: 1px solid var(--line); border-radius: 12px; background: var(--paper); }
#accounts .item-foot { justify-content: flex-start; gap: 10px; }

/* Passwörter, Zurücksetzen, Sicherung: gleiche Sprache wie die übrigen Module */
.panel .pw-card h3, .panel .pw-reset h3 { margin: 0 0 4px; padding: 0; border: 0; color: var(--blue); font-size: 1.05rem; letter-spacing: 0; text-transform: none; }
.panel .pw-reset h3 { color: var(--ink); font-size: 1rem; }
.pw-card { border-radius: 12px; background: var(--paper); }
.pw-card label { color: var(--muted); font-size: .72rem; font-weight: 800; letter-spacing: .07em; text-transform: uppercase; }
.pw-card label .muted { font-weight: 600; letter-spacing: 0; text-transform: none; }
.pw-card input { border-radius: 8px; }
.pw-card input:focus { outline: 2px solid var(--blue); outline-offset: 0; border-color: transparent; }
.pw-reset { border: 1px solid var(--line); border-style: solid; background: var(--paper); }
.pw-reset .row { padding-bottom: 0; border-bottom: 0; }
.backup-last { display: flex; align-items: center; gap: 8px; border: 1px solid transparent; }
.backup-last.ok { border-color: rgba(57, 120, 97, .25); }
.backup-last.warn { border-color: rgba(176, 116, 54, .3); }
.subcard .row { padding-bottom: 0; border-bottom: 0; }
.mav-admin .fld textarea { min-height: 96px; }

/* Trailer „Was kann das Portal?“ (Startseite) */
.trailer video { display: block; width: 100%; aspect-ratio: 16 / 9; border-radius: 10px; background: #000; }
.trailer p { margin: 10px 0 0; }

/* Abmelde-Hinweis (theme.js) */
.session-warning { position: fixed; left: 16px; right: 16px; bottom: 16px; z-index: 50; max-width: 420px; margin: 0 auto; padding: 16px; border: 1px solid var(--line); border-top: 4px solid var(--warm); border-radius: 10px; background: var(--paper); color: var(--ink); box-shadow: 0 6px 18px rgba(0, 0, 0, .22); }
.session-warning p { margin: 8px 0 12px; }
.session-warning .row { display: flex; flex-wrap: wrap; gap: 8px; }
