/* ==========================================================================
   documentation.lu by iMMOSOLUTIONS
   Farben und Formen abgeleitet aus dem Logo: Dachlinie rot/blau, Aktenblatt.
   ========================================================================== */

:root {
  --navy: #123a63;
  --navy-d: #0c2843;
  --navy-l: #1d5490;
  --red: #c8102e;
  --red-d: #a20c24;
  --ink: #23282c;
  --muted: #6b7580;
  --line: #e1e6eb;
  --line-2: #eef1f4;
  --paper: #f5f7f9;
  --white: #fff;
  --ok: #1b7f4c;
  --warn: #a86300;

  --f-display: "Archivo", "Helvetica Neue", Arial, sans-serif;
  --f-body: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Arial, sans-serif;

  --r: 3px;
  --shadow: 0 1px 2px rgba(18, 58, 99, .06), 0 8px 24px rgba(18, 58, 99, .06);
  --shadow-l: 0 2px 4px rgba(18, 58, 99, .08), 0 18px 50px rgba(18, 58, 99, .12);
  --wrap: 1160px;
}

*, *::before, *::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: var(--f-body);
  font-size: 16px;
  line-height: 1.65;
  color: var(--ink);
  background: var(--white);
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; height: auto; display: block; }
a { color: var(--navy); text-decoration: none; }
a:hover { color: var(--red); }

h1, h2, h3, h4 {
  font-family: var(--f-display);
  font-weight: 700;
  line-height: 1.15;
  letter-spacing: -.015em;
  color: var(--navy);
  margin: 0 0 .5em;
}
h1 { font-size: clamp(1.7rem, 6vw, 3.2rem); }
h2 { font-size: clamp(1.35rem, 4vw, 2.1rem); }
h3 { font-size: 1.15rem; }
p { margin: 0 0 1.1em; }

.wrap { width: 100%; max-width: var(--wrap); margin: 0 auto; padding: 0 clamp(16px, 4vw, 24px); }
.wrap-narrow { max-width: 760px; }

/* Eyebrow / Label ------------------------------------------------------- */
.eyebrow {
  font-family: var(--f-display);
  font-size: .72rem;
  font-weight: 600;
  letter-spacing: .18em;
  text-transform: uppercase;
  color: var(--red);
  margin: 0 0 .9rem;
  display: block;
}
.eyebrow.is-navy { color: var(--navy-l); }

/* Dachlinie – das Signaturelement (aus dem Logo) ------------------------- */
.roof { display: block; width: 132px; height: 16px; margin: 0 0 22px; overflow: visible; }
.roof line { stroke-width: 2.5; stroke-linecap: square; }
.roof .r-l { stroke: var(--red); }
.roof .r-r { stroke: var(--navy); }
.roof.is-center { margin-left: auto; margin-right: auto; }

/* Buttons ---------------------------------------------------------------- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: .55em;
  font-family: var(--f-display);
  font-size: .92rem;
  font-weight: 600;
  letter-spacing: .01em;
  padding: 13px 24px;
  border-radius: var(--r);
  border: 1.5px solid transparent;
  cursor: pointer;
  transition: background .15s ease, color .15s ease, border-color .15s ease, transform .15s ease;
  text-align: center;
  line-height: 1.2;
}
.btn:hover { transform: translateY(-1px); }
.btn-primary { background: var(--red); color: #fff; }
.btn-primary:hover { background: var(--red-d); color: #fff; }
.btn-navy { background: var(--navy); color: #fff; }
.btn-navy:hover { background: var(--navy-d); color: #fff; }
.btn-ghost { border-color: var(--line); color: var(--navy); background: #fff; }
.btn-ghost:hover { border-color: var(--navy); color: var(--navy); }
.btn-light { background: rgba(255,255,255,.12); color: #fff; border-color: rgba(255,255,255,.4); }
.btn-light:hover { background: #fff; color: var(--navy); }
.btn-sm { padding: 8px 14px; font-size: .82rem; }
.btn-block { width: 100%; justify-content: center; }
.btn-danger { background: #fff; border-color: #e6c3c9; color: var(--red); }
.btn-danger:hover { background: var(--red); color: #fff; border-color: var(--red); }
.btn[disabled] { opacity: .5; pointer-events: none; }

/* Kopfzeile -------------------------------------------------------------- */
.site-head {
  position: sticky; top: 0; z-index: 50;
  background: rgba(255,255,255,.94);
  backdrop-filter: saturate(140%) blur(8px);
  border-bottom: 1px solid var(--line);
}
.site-head .bar { display: flex; align-items: center; gap: 28px; height: 140px; min-width: 0; }
.brand { display: flex; align-items: center; flex: 0 1 auto; min-width: 0; }
.brand img { height: 100px; width: auto; max-width: 100%; }
.site-nav { display: flex; align-items: center; gap: 26px; margin-left: auto; }
.site-nav a:not(.btn) {
  font-size: .93rem; font-weight: 500; color: var(--ink); position: relative; padding: 4px 0;
}
/* Buttons behalten ihre eigenen Farben – sonst faerbt die Regel darueber
   die Schrift dunkel und der Text verschwindet auf dunklem Grund. */
.site-nav a.btn { white-space: nowrap; }
.site-nav a.btn-navy, .site-nav a.btn-navy:hover,
.site-nav a.btn-primary, .site-nav a.btn-primary:hover { color: #fff; }
.site-nav a.btn-ghost { color: var(--navy); }
.site-nav a:not(.btn)::after {
  content: ""; position: absolute; left: 0; right: 100%; bottom: 0; height: 2px;
  background: var(--red); transition: right .2s ease;
}
.site-nav a:not(.btn):hover::after { right: 0; }
.nav-toggle {
  display: none; margin-left: auto; background: none; border: 1px solid var(--line);
  border-radius: var(--r); padding: 9px 12px; cursor: pointer; color: var(--navy);
  font-family: var(--f-display); font-weight: 600; font-size: .85rem;
}

/* Sprachwahl als ruhiges Klappmenue ------------------------------------- */
.lang-pick { position: relative; }
.lang-pick > summary {
  display: inline-flex; align-items: center; gap: 6px; cursor: pointer;
  list-style: none; padding: 7px 10px; border-radius: var(--r);
  font-family: var(--f-display); font-size: .82rem; font-weight: 600;
  letter-spacing: .04em; color: var(--muted);
  transition: color .15s ease, background .15s ease;
}
.lang-pick > summary::-webkit-details-marker { display: none; }
.lang-pick > summary:hover { color: var(--navy); background: var(--paper); }
.lang-pick[open] > summary { color: var(--navy); background: var(--paper); }
.lang-pick .chev { transition: transform .18s ease; }
.lang-pick[open] .chev { transform: rotate(180deg); }
.lang-menu {
  position: absolute; right: 0; top: calc(100% + 8px); z-index: 60; min-width: 168px;
  background: #fff; border: 1px solid var(--line); border-radius: var(--r);
  box-shadow: var(--shadow-l); padding: 6px; display: flex; flex-direction: column;
}
.lang-menu::before {
  content: ""; position: absolute; left: 0; right: 0; top: 0; height: 2px;
  background: linear-gradient(90deg, var(--red) 0 50%, var(--navy) 50% 100%);
}
.lang-menu a {
  padding: 9px 12px; border-radius: 2px; font-size: .9rem; color: var(--ink);
  white-space: nowrap;
}
.lang-menu a::after { display: none; }
.lang-menu a:hover { background: var(--paper); color: var(--navy); }
.lang-menu a.on { color: var(--red); font-weight: 600; }
.lang-menu a.on::before { content: "· "; }

/* Hero ------------------------------------------------------------------- */
.hero { position: relative; padding: 84px 0 92px; overflow: hidden; background: var(--white); }
.hero::before {
  content: ""; position: absolute; inset: 0 0 0 50%;
  background: var(--paper);
  clip-path: polygon(14% 0, 100% 0, 100% 100%, 0 100%);
  z-index: 0;
}
.hero .wrap { position: relative; z-index: 1; }
.hero-grid { display: grid; grid-template-columns: 1.05fr .95fr; gap: 64px; align-items: center; }
.hero h1 { margin-bottom: .45em; }
.hero h1 .accent { color: var(--red); }
.hero .lead { font-size: 1.12rem; color: #454c53; max-width: 34em; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 28px; }
.hero-note { margin-top: 26px; font-size: .88rem; color: var(--muted); display: flex; gap: 8px; align-items: center; }

/* Hero-Bild im Markenrahmen ------------------------------------------------ */
.hero-figure { position: relative; margin: 0 0 34px; }
.hero-figure .frame {
  position: relative; background: #fff; border: 1px solid var(--line);
  border-radius: var(--r); overflow: hidden; box-shadow: var(--shadow-l);
}
.hero-figure .frame::before {
  content: ""; display: block; height: 4px;
  background: linear-gradient(90deg, var(--red) 0 50%, var(--navy) 50% 100%);
}
.hero-figure img { display: block; width: 100%; height: auto; }
.hero-badge {
  position: absolute; left: -20px; bottom: -26px; z-index: 2;
  display: flex; align-items: center; gap: 13px; max-width: 82%;
  background: #fff; border: 1px solid var(--line); border-radius: var(--r);
  box-shadow: var(--shadow-l); padding: 15px 20px 15px 17px;
}
.hero-badge::before {
  content: ""; position: absolute; left: 0; top: 12px; bottom: 12px; width: 3px;
  background: var(--red);
}
.hero-badge .ico { flex: 0 0 auto; display: grid; place-items: center; }
.hero-badge .t {
  font-family: var(--f-display); font-weight: 600; font-size: .95rem;
  color: var(--navy); line-height: 1.3;
}
.hero-badge .s { font-size: .82rem; color: var(--muted); line-height: 1.4; }

/* Dateityp-Chip ---------------------------------------------------------- */
.chip {
  flex: 0 0 auto; width: 40px; height: 46px; border-radius: 2px; position: relative;
  background: var(--paper); border: 1.5px solid var(--line);
  display: grid; place-items: center;
  font-family: var(--f-display); font-size: .58rem; font-weight: 700; letter-spacing: .06em;
  color: var(--muted); text-transform: uppercase;
}
.chip::after {
  content: ""; position: absolute; top: -1px; right: -1px; width: 11px; height: 11px;
  background: #fff; border-left: 1.5px solid var(--line); border-bottom: 1.5px solid var(--line);
}
.chip.is-pdf { color: var(--red); border-color: #eec8ce; background: #fdf3f4; }
.chip.is-pdf::after { border-color: #eec8ce; }
.chip.is-img { color: var(--navy-l); border-color: #c9dcee; background: #f2f7fc; }
.chip.is-img::after { border-color: #c9dcee; }
.chip.is-plan { color: var(--navy); border-color: #c9d5e0; background: #f1f5f9; }
.chip.is-plan::after { border-color: #c9d5e0; }
.chip.is-sheet { color: var(--ok); border-color: #c6ddd0; background: #f2f8f5; }
.chip.is-sheet::after { border-color: #c6ddd0; }
.chip.is-zip, .chip.is-doc, .chip.is-other { color: var(--muted); }

/* Markenband: von wem die Projekte stammen -------------------------------- */
.brandbar { padding: 30px 0; background: #fff; border-top: 1px solid var(--line); }
.brandbar-inner { display: flex; align-items: center; gap: 40px; flex-wrap: wrap; }
.brandbar-mark { flex: 0 0 auto; display: flex; flex-direction: column; }
.brandbar-mark .eyebrow { margin-bottom: .55rem; }
.brandbar-mark img { height: 62px; width: auto; }
.brandbar-text {
  flex: 1 1 340px; margin: 0; font-size: .95rem; color: #4b545c;
  padding-left: 40px; border-left: 1px solid var(--line); max-width: 46em;
}

/* Wortmarke in der Fusszeile */
.foot-brand { margin-top: 28px; }
.foot-brand > span:first-child {
  display: block; font-family: var(--f-display); font-size: .68rem; font-weight: 600;
  letter-spacing: .16em; text-transform: uppercase; color: #7d94ad; margin-bottom: 10px;
}
.foot-brand-chip {
  background: #fff; border-radius: var(--r); padding: 10px 16px; display: inline-block;
}
.foot-brand-chip img { height: 42px; width: auto; display: block; }

/* Abschnitte ------------------------------------------------------------- */
.section { padding: 88px 0; }
.section.is-paper { background: var(--paper); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.section.is-navy { background: var(--navy); color: #dfe7ef; }
.section.is-navy h2, .section.is-navy h3 { color: #fff; }
.section-head { max-width: 640px; margin-bottom: 48px; }
.section-head.is-center { margin-left: auto; margin-right: auto; text-align: center; }
.section-head p { color: #4b545c; margin-bottom: 0; }
.is-navy .section-head p { color: #b9c8d8; }

/* Ablauf – echte Reihenfolge, daher nummeriert ---------------------------- */
.steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 2px; background: var(--line); }
.step { background: #fff; padding: 34px 30px 38px; position: relative; }
.step .num {
  font-family: var(--f-display); font-size: .78rem; font-weight: 700; letter-spacing: .14em;
  color: var(--red); display: block; margin-bottom: 14px;
}
.step h3 { margin-bottom: .4em; }
.step p { color: #4b545c; font-size: .95rem; margin: 0; }

/* Kacheln ---------------------------------------------------------------- */
.tiles { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.tile {
  background: #fff; border: 1px solid var(--line); border-radius: var(--r);
  padding: 26px 24px 28px; transition: border-color .18s ease, transform .18s ease, box-shadow .18s ease;
}
.tile:hover { border-color: var(--navy); transform: translateY(-2px); box-shadow: var(--shadow); }
.tile h3 { font-size: 1.02rem; margin-bottom: .35em; }
.tile p { font-size: .92rem; color: #4b545c; margin: 0; }
.tile .tile-ico { width: 34px; height: 34px; margin-bottom: 16px; }

/* Formulare -------------------------------------------------------------- */
.field { margin-bottom: 18px; }
.field label, .lbl {
  display: block; font-family: var(--f-display); font-size: .78rem; font-weight: 600;
  letter-spacing: .08em; text-transform: uppercase; color: var(--navy); margin-bottom: 7px;
}
.input, input[type=text], input[type=email], input[type=password], input[type=tel],
input[type=date], input[type=search], select, textarea {
  width: 100%; padding: 12px 14px; font-family: var(--f-body); font-size: .96rem; color: var(--ink);
  background: #fff; border: 1.5px solid var(--line); border-radius: var(--r); transition: border-color .15s ease, box-shadow .15s ease;
}
textarea { min-height: 150px; resize: vertical; }
input:focus, select:focus, textarea:focus {
  outline: none; border-color: var(--navy); box-shadow: 0 0 0 3px rgba(18,58,99,.1);
}
input[type=file] { padding: 10px; background: var(--paper); }
.hint { font-size: .82rem; color: var(--muted); margin-top: 6px; }
.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
.check { display: flex; gap: 10px; align-items: flex-start; font-size: .9rem; color: #4b545c; }
.check input { width: auto; margin-top: 4px; flex: 0 0 auto; }
.hp { position: absolute !important; left: -9999px !important; }

/* Meldungen -------------------------------------------------------------- */
.alert {
  padding: 14px 18px; border-radius: var(--r); margin-bottom: 20px; font-size: .93rem;
  border-left: 3px solid var(--navy); background: var(--paper); color: var(--ink);
}
.alert-ok { border-color: var(--ok); background: #f1f8f4; color: #14603a; }
.alert-error { border-color: var(--red); background: #fdf3f4; color: #8d0b20; }
.alert-info { border-color: var(--navy-l); background: #f2f7fc; }
.alert-warn { border-color: var(--warn); background: #fdf7ee; color: #7a4900; }

/* Karten / Panels -------------------------------------------------------- */
.panel { background: #fff; border: 1px solid var(--line); border-radius: var(--r); }
.panel-head {
  padding: 18px 24px; border-bottom: 1px solid var(--line);
  display: flex; align-items: center; gap: 14px; flex-wrap: wrap;
}
.panel-head h2, .panel-head h3 { margin: 0; font-size: 1.05rem; }
.panel-body { padding: 24px; }
.panel-foot { padding: 16px 24px; border-top: 1px solid var(--line); background: var(--paper); }

/* Login-Karte mit Dachrahmen --------------------------------------------- */
.auth-wrap { min-height: calc(100vh - 140px); display: grid; place-items: center; padding: 56px 20px; background: var(--paper); }
.auth-card { width: 100%; max-width: 440px; background: #fff; border: 1px solid var(--line); box-shadow: var(--shadow-l); }
.auth-card .cap { height: 4px; background: linear-gradient(90deg, var(--red) 0 50%, var(--navy) 50% 100%); }
.auth-card .inner { padding: 38px 36px 34px; }
.auth-card h1 { font-size: 1.6rem; }
.auth-links { margin-top: 20px; font-size: .88rem; display: flex; justify-content: space-between; gap: 12px; }

/* Tabellen --------------------------------------------------------------- */
.table-scroll { overflow-x: auto; -webkit-overflow-scrolling: touch; }
table.data { width: 100%; border-collapse: collapse; font-size: .93rem; }
table.data th {
  text-align: left; font-family: var(--f-display); font-size: .72rem; letter-spacing: .1em;
  text-transform: uppercase; color: var(--muted); font-weight: 600;
  padding: 12px 16px; border-bottom: 1px solid var(--line); white-space: nowrap;
}
table.data td { padding: 14px 16px; border-bottom: 1px solid var(--line-2); vertical-align: middle; }
table.data tr:last-child td { border-bottom: 0; }
table.data tbody tr:hover { background: #fafbfc; }
table.data td.right, table.data th.right { text-align: right; }
.nowrap { white-space: nowrap; }

/* Badges ----------------------------------------------------------------- */
.badge {
  display: inline-block; font-family: var(--f-display); font-size: .68rem; font-weight: 600;
  letter-spacing: .08em; text-transform: uppercase; padding: 4px 9px; border-radius: 2px;
  background: var(--paper); color: var(--muted); border: 1px solid var(--line);
}
.badge-active { background: #f1f8f4; color: #14603a; border-color: #c6ddd0; }
.badge-archived { background: var(--paper); color: var(--muted); }
.badge-new { background: #fdf3f4; color: var(--red); border-color: #eec8ce; }
.badge-navy { background: #f2f7fc; color: var(--navy); border-color: #c9dcee; }

/* Projektliste (Kunde) ---------------------------------------------------- */
.pcards { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(300px, 100%), 1fr)); gap: 20px; }
.pcard {
  background: #fff; border: 1px solid var(--line); border-radius: var(--r); padding: 0;
  display: flex; flex-direction: column; transition: border-color .18s ease, box-shadow .18s ease, transform .18s ease;
}
.pcard:hover { border-color: var(--navy); box-shadow: var(--shadow); transform: translateY(-2px); }
.pcard-img {
  position: relative; aspect-ratio: 16 / 9; overflow: hidden; background: var(--paper);
  border-bottom: 1px solid var(--line-2);
}
.pcard-img img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform .4s ease; }
.pcard:hover .pcard-img img { transform: scale(1.03); }
.pcard-img.is-empty { display: grid; place-items: center; background: var(--paper); }
.pcard-img.is-empty svg { width: 88px; height: auto; opacity: .5; }
.pcard-img::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 3px;
  background: linear-gradient(90deg, var(--red) 0 50%, var(--navy) 50% 100%);
}
.pcard .top { padding: 22px 24px 18px; }
.pcard .ref { font-family: var(--f-display); font-size: .7rem; letter-spacing: .16em; text-transform: uppercase; color: var(--red); }
.pcard h3 { margin: 6px 0 4px; font-size: 1.12rem; }
.pcard .addr { font-size: .9rem; color: var(--muted); margin: 0; }
.pcard .bottom {
  margin-top: auto; padding: 14px 24px; border-top: 1px solid var(--line-2);
  display: flex; align-items: center; justify-content: space-between; font-size: .85rem; color: var(--muted);
}

/* Hinweis auf den Betreiber im Kundenbereich */
.owner-note {
  margin-top: 48px; padding-top: 22px; border-top: 1px solid var(--line);
  display: flex; align-items: center; gap: 16px; flex-wrap: wrap;
}
.owner-note span {
  font-family: var(--f-display); font-size: .68rem; font-weight: 600;
  letter-spacing: .16em; text-transform: uppercase; color: var(--muted);
}
.owner-note img { height: 40px; width: auto; }

/* Titelbild auf der Projektseite */
.project-cover {
  margin: 0 0 30px; border: 1px solid var(--line); border-radius: var(--r);
  overflow: hidden; box-shadow: var(--shadow); position: relative; background: var(--paper);
}
.project-cover::before {
  content: ""; position: absolute; left: 0; right: 0; top: 0; height: 4px; z-index: 1;
  background: linear-gradient(90deg, var(--red) 0 50%, var(--navy) 50% 100%);
}
.project-cover img { display: block; width: 100%; height: auto; max-height: 380px; object-fit: cover; }

/* Dokumentenliste -------------------------------------------------------- */
.doc-group { margin-bottom: 34px; }
.doc-group > h3 {
  font-size: .82rem; letter-spacing: .12em; text-transform: uppercase; color: var(--muted);
  border-bottom: 1px solid var(--line); padding-bottom: 10px; margin-bottom: 4px;
}
.doc-row {
  display: flex; align-items: center; gap: 16px; padding: 14px 4px;
  border-bottom: 1px solid var(--line-2);
}
.doc-row .info { min-width: 0; }
.doc-row .info .t { font-weight: 500; color: var(--ink); word-break: break-word; }
.doc-row .info .s { font-size: .82rem; color: var(--muted); }
.doc-row .act { margin-left: auto; display: flex; gap: 8px; align-items: center; }

/* Fusszeile -------------------------------------------------------------- */
.site-foot { background: var(--navy); color: #b9c8d8; padding: 64px 0 28px; font-size: .92rem; }
.site-foot a { color: #dfe7ef; }
.site-foot a:hover { color: #fff; }
.foot-grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr; gap: 44px; padding-bottom: 40px; }
.foot-grid h4 {
  font-family: var(--f-display); color: #fff; font-size: .76rem; letter-spacing: .14em;
  text-transform: uppercase; margin: 0 0 16px;
}
.foot-logo { background: #fff; padding: 14px 20px; border-radius: var(--r); display: inline-block; margin-bottom: 20px; }
.foot-logo img { height: 62px; }
.foot-list { list-style: none; margin: 0; padding: 0; }
.foot-list li { margin-bottom: 9px; }
.foot-bottom {
  border-top: 1px solid rgba(255,255,255,.14); padding-top: 22px;
  display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; font-size: .84rem; color: #8ea3b8;
}

/* Admin ------------------------------------------------------------------ */
.admin { display: grid; grid-template-columns: 256px 1fr; min-height: 100vh; }
.admin-side { background: var(--navy); color: #cfdae6; display: flex; flex-direction: column; }
.admin-side .side-head { padding: 20px 18px 18px; border-bottom: 1px solid rgba(255,255,255,.12); }
.admin-side .side-head .logo-box { background: #fff; padding: 12px 14px; border-radius: var(--r); display: block; }
.admin-side .side-head .logo-box img { height: 44px; width: 100%; object-fit: contain; }
.admin-side nav { padding: 18px 12px; flex: 1; }
.admin-side nav a {
  display: flex; align-items: center; gap: 11px; padding: 10px 14px; border-radius: var(--r);
  color: #cfdae6; font-size: .93rem; font-weight: 500; margin-bottom: 3px;
}
.admin-side nav a:hover { background: rgba(255,255,255,.08); color: #fff; }
.admin-side nav a.on { background: var(--red); color: #fff; }
.admin-side nav .grp {
  font-family: var(--f-display); font-size: .68rem; letter-spacing: .14em; text-transform: uppercase;
  color: #7d94ad; padding: 18px 14px 8px;
}
.admin-side .side-foot { padding: 16px 22px 22px; border-top: 1px solid rgba(255,255,255,.12); font-size: .84rem; }
.admin-main { background: var(--paper); min-width: 0; }
.admin-top {
  background: #fff; border-bottom: 1px solid var(--line); padding: 18px 32px;
  display: flex; align-items: center; gap: 16px; flex-wrap: wrap;
}
.admin-top h1 { margin: 0; font-size: 1.4rem; }
.admin-top .tools { margin-left: auto; display: flex; gap: 10px; flex-wrap: wrap; }
.admin-body { padding: 28px 32px 64px; }
.stat-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 18px; margin-bottom: 28px; }
.stat { background: #fff; border: 1px solid var(--line); border-radius: var(--r); padding: 20px 22px; }
.stat .k { font-family: var(--f-display); font-size: .72rem; letter-spacing: .12em; text-transform: uppercase; color: var(--muted); }
.stat .v { font-family: var(--f-display); font-size: 2rem; font-weight: 700; color: var(--navy); line-height: 1.1; margin-top: 6px; }
.stat .v small { font-size: .9rem; color: var(--red); font-weight: 600; }
.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 22px; align-items: start; }
.grid-2-side { display: grid; grid-template-columns: 1.6fr 1fr; gap: 22px; align-items: start; }
.tabs { display: flex; gap: 4px; border-bottom: 1px solid var(--line); margin-bottom: 24px; flex-wrap: wrap; }
.tabs a {
  padding: 11px 16px; font-family: var(--f-display); font-weight: 600; font-size: .88rem;
  color: var(--muted); border-bottom: 2px solid transparent; margin-bottom: -1px;
}
.tabs a.on { color: var(--navy); border-color: var(--red); }
.dropzone {
  border: 2px dashed var(--line); border-radius: var(--r); background: #fff; padding: 34px 24px;
  text-align: center; transition: border-color .15s ease, background .15s ease; cursor: pointer;
}
.dropzone.hover { border-color: var(--red); background: #fdf3f4; }
.dropzone .big { font-family: var(--f-display); font-weight: 600; color: var(--navy); }
#filelist { margin-top: 14px; font-size: .88rem; color: var(--muted); text-align: left; }
#filelist div { padding: 4px 0; border-bottom: 1px solid var(--line-2); }
.inline-form { display: inline; }
.muted { color: var(--muted); }
.small { font-size: .86rem; }
.mt-0 { margin-top: 0; } .mb-0 { margin-bottom: 0; }
.mt-24 { margin-top: 24px; } .mb-24 { margin-bottom: 24px; }
.empty { text-align: center; padding: 48px 24px; color: var(--muted); }
.empty .big { font-family: var(--f-display); font-weight: 600; color: var(--navy); font-size: 1.05rem; margin-bottom: 6px; }

/* Zugaenglichkeit --------------------------------------------------------- */
:focus-visible { outline: 3px solid rgba(200,16,46,.45); outline-offset: 2px; }
.skip {
  position: absolute; left: -9999px; top: 0; background: var(--navy); color: #fff; padding: 12px 18px; z-index: 100;
}
.skip:focus { left: 8px; top: 8px; color: #fff; }

/* Bewegungsreduktion ------------------------------------------------------ */
@media (prefers-reduced-motion: reduce) {
  * { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
}

/* Responsiv --------------------------------------------------------------- */
@media (max-width: 1240px) {
  .site-head .bar { gap: 20px; }
  .site-nav { gap: 18px; }
  .site-nav a:not(.btn) { font-size: .88rem; }
}

@media (max-width: 1080px) {
  .brand img { height: 74px; }
  .site-head .bar { height: 118px; }
  .site-nav { gap: 14px; }
}

@media (max-width: 1000px) {
  .hero-grid { grid-template-columns: 1fr; gap: 44px; }
  .hero-figure { margin-bottom: 30px; }
  .hero-badge { left: 14px; bottom: -22px; max-width: calc(100% - 28px); }
  .hero::before { display: none; }
  .steps { grid-template-columns: 1fr; }
  .tiles { grid-template-columns: repeat(2, 1fr); }
  .stat-grid { grid-template-columns: repeat(2, 1fr); }
  .grid-2, .grid-2-side { grid-template-columns: 1fr; }
  .foot-grid { grid-template-columns: 1fr 1fr; }
  .admin { grid-template-columns: 1fr; }
  .admin-side { position: static; }
  .admin-side .side-head { padding: 14px 16px 12px; border-bottom: 0; }
  .admin-side .side-head .logo-box { display: inline-block; padding: 8px 12px; }
  .admin-side .side-head .logo-box img { height: 38px; width: auto; }
  .admin-side nav { display: flex; flex-wrap: wrap; gap: 4px; padding: 0 12px 12px; }
  .admin-side nav a { padding: 9px 12px; font-size: .88rem; }
  .admin-side nav .grp { display: none; }
  .admin-side .side-foot {
    display: flex; gap: 12px; align-items: center; justify-content: space-between;
    padding: 10px 16px; border-top: 1px solid rgba(255,255,255,.12);
  }
}
/* Ab hier klappt die Navigation ins Menue – das Logo braucht den Platz */
@media (max-width: 940px) {
  .site-nav {
    display: none; position: absolute; left: 0; right: 0; top: 100%; background: #fff;
    border-bottom: 1px solid var(--line); flex-direction: column; align-items: stretch;
    gap: 0; padding: 10px 24px 22px;
  }
  .site-nav.open { display: flex; }
  .site-nav a:not(.btn) { padding: 13px 0; border-bottom: 1px solid var(--line-2); }
  .site-nav .btn { margin-top: 14px; justify-content: center; border-bottom: 0; }
  .site-nav .lang-pick { padding: 10px 0 4px; border-bottom: 1px solid var(--line-2); }
  .site-nav .lang-pick > summary { padding-left: 0; }
  .site-nav .lang-menu { position: static; box-shadow: none; margin-top: 6px; }
  .nav-toggle { display: block; }
  .site-head .bar { height: 104px; gap: 14px; }
  .brand img { height: 72px; }
}

@media (max-width: 720px) {
  .brandbar-inner { gap: 22px; }
  .brandbar-mark img { height: 52px; }
  .foot-brand-chip img { height: 38px; }
  .owner-note img { height: 34px; }
  .brandbar-text { padding-left: 0; border-left: 0; padding-top: 4px; flex-basis: 100%; }
  .section { padding: 60px 0; }
  .hero { padding: 52px 0 60px; }
  .tiles { grid-template-columns: 1fr; }
  .field-row { grid-template-columns: 1fr; }
  .foot-grid { grid-template-columns: 1fr; gap: 32px; }
  .admin-top, .admin-body { padding-left: 18px; padding-right: 18px; }
  .doc-row { flex-wrap: wrap; }
  .doc-row .act { width: 100%; margin-left: 0; }
  .pcards { grid-template-columns: 1fr; }
  .panel-body, .panel-head, .panel-foot { padding-left: 20px; padding-right: 20px; }
  .auth-card .inner { padding: 30px 24px 28px; }
  .hero-actions .btn, .section .hero-actions .btn { flex: 1 1 220px; justify-content: center; }
  .foot-bottom { flex-direction: column; gap: 10px; }
}

/* Handys hochkant */
@media (max-width: 600px) {
  .hero-badge { left: 10px; right: 10px; bottom: -18px; max-width: none; padding: 13px 15px; }
  .hero-badge .t { font-size: .88rem; }
  .hero-figure { margin-bottom: 26px; }
  .site-head .bar { height: 88px; }
  .brand img { height: 58px; }
  .site-nav { top: 100%; }
  .auth-wrap { min-height: 0; padding: 36px 16px; }
  .section { padding: 48px 0; }
  .hero { padding: 40px 0 48px; }
  .section-head { margin-bottom: 32px; }
  .stat-grid { grid-template-columns: 1fr; gap: 14px; }
  .step { padding: 26px 22px 30px; }
  .tile { padding: 22px 20px 24px; }
  table.data th, table.data td { padding: 11px 12px; }
  .doc-row .act .btn { flex: 1 1 auto; justify-content: center; }
  .site-foot { padding: 48px 0 24px; }
  .admin-top h1 { font-size: 1.2rem; }
}

/* Sehr schmale Geraete */
@media (max-width: 460px) {
  .brandbar { padding: 24px 0; }
  .brandbar-mark img { height: 46px; }
  .site-head .bar { height: 72px; gap: 8px; }
  .brand img { height: 44px; }
  .site-nav { top: 100%; padding-left: 16px; padding-right: 16px; }
  .nav-toggle { padding: 8px 10px; font-size: .78rem; }
  .btn { padding: 12px 18px; font-size: .88rem; }
  .doc-row .chip, .chip { width: 34px; height: 40px; }
  .stat .v { font-size: 1.7rem; }
}

/* Sehr schmale Geraete (iPhone SE und aehnlich) */
@media (max-width: 370px) {
  .site-head .bar { height: 64px; gap: 6px; }
  .brand img { height: 38px; }
  .nav-toggle { padding: 7px 9px; font-size: .74rem; }
  .wrap { padding: 0 14px; }
}

/* Druck ------------------------------------------------------------------- */
@media print {
  .site-head, .site-foot, .admin-side, .btn { display: none !important; }
  body { background: #fff; }
}
