/* =====================================================================
   olaugh.de CRM – Look wie die neue Homepage (Navy + Gold, Yantramanav)
   Tokens nach docs/design-relaunch/rollout/site/assets/css/relaunch.css
   Kein Framework, keine externen Anfragen (Schriften liegen in assets/fonts/).
   Hinweis: Media-Query-Breakpoints (900, 600 px) sind Literale.
   ===================================================================== */

/* ── Schriften (selbst gehostet) ── */
@font-face { font-family: "Yantramanav"; font-style: normal; font-weight: 400; font-display: swap;
  src: url("fonts/yantramanav-latin-400-normal.woff2") format("woff2"); }
@font-face { font-family: "Yantramanav"; font-style: normal; font-weight: 500; font-display: swap;
  src: url("fonts/yantramanav-latin-500-normal.woff2") format("woff2"); }
@font-face { font-family: "Yantramanav"; font-style: normal; font-weight: 700; font-display: swap;
  src: url("fonts/yantramanav-latin-700-normal.woff2") format("woff2"); }
@font-face { font-family: "Yantramanav"; font-style: normal; font-weight: 900; font-display: swap;
  src: url("fonts/yantramanav-latin-900-normal.woff2") format("woff2"); }
/* Nur für die Logo-Wortmarke */
@font-face { font-family: "Playfair Display"; font-style: italic; font-weight: 400; font-display: swap;
  src: url("fonts/playfair-400-italic.woff2") format("woff2"); }

/* ── Tokens: Hex-Rückfall, darunter OKLCH (gleiche Werte wie Homepage) ── */
:root {
  --ink:        #0F1F35;
  --navy:       #1A2E4A;
  --navy-line:  #2F4C70;
  --navy-soft:  #243D5E;
  --paper:      #F7F9FB;
  --mist:       #EEF2F6;
  --mist-line:  #D3DCE7;
  --text:       #14243B;
  --text-soft:  #44566E;
  --on-dark:    #E9EEF5;
  --on-dark-soft:#AFBDD0;
  --gold:       #C9A84C;
  --gold-hover: #D9BC62;
  --amber:      #7B5800;
  --white:      #FFFFFF;
  --gruen:      #2D6A4F;
  --rot:        #8B2E2E;
  --hair-dark:  rgb(233 238 245 / .16);
  /* Rückwärtskompatible Namen (alte Seiten, Inline-Styles) */
  --cream: var(--paper);
  --warm:  var(--mist);
  --stone: var(--mist-line);
  --muted: var(--text-soft);
}
@supports (color: oklch(0% 0 0)) {
  :root {
    --ink: oklch(23.8% 0.048 257);
    --navy: oklch(29.9% 0.057 257);
    --navy-line: oklch(41.1% 0.070 255);
    --navy-soft: oklch(35.6% 0.066 256);
    --paper: oklch(98.1% 0.003 248);
    --mist: oklch(95.9% 0.007 248);
    --mist-line: oklch(88.5% 0.014 252);
    --text: oklch(25.9% 0.049 257);
    --text-soft: oklch(44.8% 0.046 256);
    --on-dark: oklch(94.7% 0.011 257);
    --on-dark-soft: oklch(79.4% 0.031 256);
    --gold: oklch(74.3% 0.117 90);
    --gold-hover: oklch(80.2% 0.115 92);
    --amber: oklch(48.5% 0.100 82);
  }
}
:root {
  --radius: 6px;
  --tap: 2.75rem;                     /* 44 px */
  --font-head: "Yantramanav", "Arial Narrow", system-ui, sans-serif;
  --font-body: "Yantramanav", "Arial Narrow", system-ui, sans-serif;
  --font-logo: "Playfair Display", Georgia, serif;
}

* { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--paper);
  color: var(--text);
  font: 400 1.0625rem/1.6 var(--font-body);   /* 17 px */
}

h1, h2, h3 { font-family: var(--font-head); font-weight: 700; color: var(--ink); line-height: 1.15; }
h1 { font-size: 2rem; margin: 1.2rem 0 1rem; }
h2 { font-size: 1.4rem; margin: 1.6rem 0 0.7rem; }
h3 { font-size: 1.15rem; }

a { color: var(--amber); text-underline-offset: 0.15em; }
a:hover { color: var(--ink); }

:focus-visible { outline: 3px solid var(--navy); outline-offset: 3px; border-radius: 2px; }

/* ── Wortmarke ─────────────────────────────────────────────────────── */

.marke { display: inline-flex; align-items: baseline; gap: 0.7rem; color: var(--on-dark); line-height: 1; }
.marke-wort { font-family: var(--font-logo); font-style: italic; font-weight: 400; font-size: 1.7rem; letter-spacing: -0.01em; }
.marke-o { color: var(--gold); }
.marke small {
  font-family: var(--font-head); font-style: normal; font-size: 0.875rem; font-weight: 500;
  color: var(--on-dark-soft); letter-spacing: 0.12em; text-transform: uppercase;
  padding-left: 0.7rem; border-left: 1px solid var(--gold);
}

/* ── Kopf & Navigation (Portal) ────────────────────────────────────── */

.kopf { background: var(--navy); border-bottom: 3px solid var(--gold); --focus: var(--gold); }
.kopf :focus-visible, .admin-sidebar :focus-visible { outline-color: var(--gold); }
.kopf-innen {
  max-width: 1100px; margin: 0 auto; padding: 0.6rem 1rem;
  display: flex; flex-wrap: wrap; align-items: center; gap: 0.5rem 1.5rem;
}
.nav { display: flex; flex-wrap: wrap; gap: 0.15rem; margin-left: auto; }
.nav a {
  display: inline-flex; align-items: center; min-height: var(--tap);
  color: var(--on-dark); text-decoration: none; font-size: 1.0625rem; font-weight: 500;
  padding: 0.35rem 0.8rem; border-radius: var(--radius);
}
.nav a:hover { background: rgb(201 168 76 / 0.18); color: var(--white); }
.nav a.aktiv { background: var(--gold); color: var(--ink); font-weight: 700; }

/* ── Inhalt ────────────────────────────────────────────────────────── */

.inhalt { max-width: 1100px; margin: 0 auto; padding: 0.5rem 1rem 3rem; }
.fuss { text-align: center; color: var(--text-soft); font-size: 0.9375rem; padding: 1.5rem 0 2.5rem; }

/* ── Admin: Navy-Seitenleiste ──────────────────────────────────────── */

.admin-layout { display: flex; min-height: 100vh; }
.admin-sidebar {
  width: 292px; background: var(--navy); color: var(--on-dark);
  border-right: 3px solid var(--gold); padding: 1.4rem 0; flex-shrink: 0;
  position: sticky; top: 0; align-self: flex-start; height: 100vh; overflow-y: auto;
}
.admin-sidebar .sb-logo {
  padding: 0 1.3rem 1.2rem; border-bottom: 1px solid var(--hair-dark); margin-bottom: 1rem;
  display: flex; align-items: baseline; gap: 0.7rem; color: var(--on-dark); line-height: 1;
}
.admin-sidebar .sb-logo .marke-wort { font-size: 1.7rem; }
.admin-sidebar .sb-logo small {
  font-size: 0.875rem; letter-spacing: 0.12em; color: var(--on-dark-soft); font-weight: 500;
  text-transform: uppercase; padding-left: 0.7rem; border-left: 1px solid var(--gold);
}
.sb-gruppe { margin-bottom: 1.2rem; }
.sb-gruppe h4 {
  font-family: var(--font-head); font-size: 0.875rem; text-transform: uppercase; letter-spacing: 0.1em;
  color: var(--gold); padding: 0 1.3rem; margin: 0 0 0.35rem; font-weight: 700;
}
.sb-item {
  display: block; min-height: var(--tap); padding: 0.45rem 1.3rem;
  border-left: 3px solid transparent; text-decoration: none; color: var(--on-dark);
}
.sb-item.aktiv { background: var(--navy-soft); border-left-color: var(--gold); }
.sb-item:hover:not(.aktiv) { background: var(--navy-soft); }
.sb-item .label { display: flex; align-items: center; gap: 0.55rem; font-weight: 700; font-size: 1.0625rem; color: var(--on-dark); line-height: 1.3; }
.sb-item .desc { font-size: 0.9375rem; color: var(--on-dark-soft); margin: 0.1rem 0 0 1.75rem; line-height: 1.35; }
.admin-main { flex: 1; min-width: 0; padding: 2.1rem 2.6rem; max-width: 1300px; }
.admin-main h1 { margin: 0 0 0.25rem; }
.admin-layout + .fuss { margin-left: 292px; }

/* Dashboard: Übersichtskacheln + Modul-Kacheln */
.uebersicht { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(230px, 100%), 1fr)); gap: 1rem; margin-bottom: 2rem; }
.u-karte, .karte, .m-kachel, .naechster-schritt, .login-karte {
  background: var(--white); border: 1px solid var(--mist-line); border-top: 3px solid var(--gold);
}
.u-karte { border-radius: var(--radius); padding: 1.1rem 1.25rem; box-shadow: 0 2px 10px rgb(15 31 53 / 0.05); }
.u-head { display: flex; justify-content: space-between; align-items: flex-start; }
.u-label { font-size: 0.9375rem; color: var(--text-soft); font-weight: 700; letter-spacing: 0.02em; }
.u-zahl { font-family: var(--font-head); font-weight: 900; font-size: 2.2rem; line-height: 1.1; color: var(--ink); margin: 0.3rem 0; }
.u-sub { font-size: 0.9375rem; color: var(--text-soft); }

.modul-titel { display: flex; align-items: center; gap: 0.6rem; margin: 0 0 0.9rem; }
.modul-titel h2 { font-size: 0.9375rem; text-transform: uppercase; letter-spacing: 0.1em; color: var(--amber); font-weight: 700; margin: 0; font-family: var(--font-head); }
.modul-titel .linie { flex: 1; height: 1px; background: var(--mist-line); }
.module { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(210px, 100%), 1fr)); gap: 0.8rem; margin-bottom: 1.8rem; }
.m-kachel { border-radius: var(--radius); padding: 0.9rem 1rem; transition: box-shadow 0.18s, transform 0.18s; }
.m-kachel:hover { box-shadow: 0 6px 16px rgb(15 31 53 / 0.1); transform: translateY(-1px); }
.m-top { margin-bottom: 0.35rem; font-size: 1.2rem; }
.m-titel { font-weight: 700; font-size: 1.0625rem; color: var(--ink); }
.m-zahl { font-family: var(--font-head); font-weight: 900; font-size: 1.5rem; color: var(--amber); margin: 0.15rem 0; }
.m-sub { font-size: 0.9375rem; color: var(--text-soft); margin-bottom: 0.5rem; min-height: 1.9em; line-height: 1.35; }
.m-fuss { display: flex; justify-content: space-between; align-items: center; padding-top: 0.5rem; border-top: 1px solid var(--mist-line); font-size: 0.9375rem; font-weight: 700; }
.m-fuss a { text-decoration: none; display: inline-flex; align-items: center; min-height: var(--tap); }

.netzwerk-zeile { display: flex; justify-content: space-between; align-items: center; padding: 0.5rem 0; border-top: 1px solid var(--mist-line); }
.netzwerk-zeile:first-child { border-top: none; }

.plus {
  display: inline-flex; align-items: center; justify-content: center; width: 1.75rem; height: 1.75rem;
  border-radius: 50%; background: var(--gold); color: var(--ink); font-weight: 800; font-size: 1.1rem; text-decoration: none;
  position: relative;
}
/* Trefferfläche mindestens 44 px, ohne das sichtbare Symbol zu vergrößern */
.plus::after { content: ""; position: absolute; inset: -0.55rem; }
a.plus { width: 1.75rem !important; height: 1.75rem !important; font-size: 1.1rem !important; }
.plus:hover { background: var(--gold-hover); color: var(--ink); }

/* ── Erklärsektion ── */

.erklaerung {
  background: var(--white); border-left: 3px solid var(--gold); border: 1px solid var(--mist-line); border-left: 3px solid var(--gold);
  border-radius: var(--radius); padding: 0.7rem 1rem; margin: -0.4rem 0 1.2rem;
  color: var(--text-soft);
}

/* ── Karten ── */

.karte { border-radius: var(--radius); padding: 1.1rem 1.3rem; margin-bottom: 1.2rem; box-shadow: 0 1px 12px rgb(15 31 53 / 0.05); }
.kacheln { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(230px, 100%), 1fr)); gap: 1rem; }
.kachel-zahl { font-family: var(--font-head); font-weight: 900; font-size: 2.2rem; color: var(--amber); }

/* ── Tabellen ── */

table.liste { width: 100%; border-collapse: collapse; background: var(--white);
  border: 1px solid var(--mist-line); border-radius: var(--radius); overflow: hidden; }
.liste th {
  background: var(--navy); color: var(--on-dark); text-align: left;
  padding: 0.65rem 0.8rem; font-size: 0.9375rem; letter-spacing: 0.06em;
  text-transform: uppercase; font-weight: 700; border-bottom: 3px solid var(--gold);
}
.liste td { padding: 0.65rem 0.8rem; border-top: 1px solid var(--mist-line); vertical-align: top; }
.liste tr:nth-child(even) td { background: var(--paper); }
.liste .zahl { text-align: right; white-space: nowrap; }

/* ── Formulare ── */

form.block { max-width: 640px; }
label { display: block; margin: 0.9rem 0 0.3rem; font-weight: 700; font-size: 1.0625rem; }
input[type="text"], input[type="email"], input[type="password"], input[type="date"],
input[type="number"], input[type="search"], input[type="tel"], input[type="url"], select, textarea {
  width: 100%; min-height: var(--tap); padding: 0.55rem 0.75rem; font: inherit; color: var(--text);
  background: var(--white); border: 1px solid var(--text-soft); border-radius: var(--radius);
}
input:focus, select:focus, textarea:focus { outline: 3px solid var(--navy); outline-offset: 1px; border-color: var(--navy); }
input[type="checkbox"], input[type="radio"] { width: 1.3rem; height: 1.3rem; accent-color: var(--navy); }
textarea { min-height: 120px; resize: vertical; }

/* Passwort anzeigen/verbergen */
.pw-wrap { position: relative; display: block; }
.pw-wrap input { padding-right: 6.4rem; }
.pw-toggle {
  position: absolute; right: 0.2rem; top: 50%; transform: translateY(-50%);
  min-height: var(--tap); min-width: var(--tap); margin: 0;
  background: none; border: none; cursor: pointer; padding: 0.3rem 0.7rem;
  font: 700 0.9375rem var(--font-body); color: var(--amber); line-height: 1;
}
.pw-toggle:hover, .pw-toggle:focus-visible { color: var(--ink); background: none; }

.felder-zeile { display: flex; gap: 1rem; flex-wrap: wrap; }
.felder-zeile > div { flex: 1 1 180px; }

/* Buttons wie auf der Homepage: Gold-Hauptbutton mit dunklem Text */
button, .knopf {
  display: inline-flex; align-items: center; justify-content: center; gap: 0.4rem;
  min-height: var(--tap); margin-top: 1rem; padding: 0.55rem 1.4rem;
  font: 700 1.0625rem var(--font-body); color: var(--ink);
  background: var(--gold); border: 2px solid var(--gold); border-radius: var(--radius); cursor: pointer;
  text-decoration: none; line-height: 1.2;
}
button:hover, .knopf:hover { background: var(--gold-hover); border-color: var(--gold-hover); color: var(--ink); }
button:active, .knopf:active { transform: translateY(1px); }
.knopf-klein { padding: 0.4rem 1rem; font-size: 1rem; margin: 0.1rem 0; }
.knopf-neutral { background: transparent; color: var(--text); border: 2px solid var(--text-soft); }
.knopf-neutral:hover { background: var(--mist); border-color: var(--ink); color: var(--ink); }
.knopf-rot { background: var(--rot); border-color: var(--rot); color: var(--white); }
.knopf-rot:hover { background: var(--ink); border-color: var(--ink); color: var(--white); }
.knopf-aktiv { background: var(--gruen); border-color: var(--gruen); color: var(--white); }
.knopf-aktiv:hover { background: var(--ink); border-color: var(--ink); color: var(--white); }
form.inline { display: inline; margin: 0; }
form.inline button { margin-top: 0; }

/* ── Ideen-Voting ── */
.ideen-liste { list-style: none; padding: 0; }
.ideen-liste li { display: flex; align-items: baseline; flex-wrap: wrap; gap: 0.6rem; padding: 0.6rem 0; border-top: 1px solid var(--mist-line); }
.ideen-liste li:first-child { border-top: 0; }
.ideen-liste form.inline button { min-width: 9.5rem; }

/* ── Status-Badges ── */

.badge {
  display: inline-block; padding: 0.1rem 0.7rem; border-radius: 99px;
  font-size: 0.9375rem; font-weight: 700; white-space: nowrap;
  background: var(--mist); color: var(--text); border: 1px solid var(--mist-line);
}
.badge-neu, .badge-offen { background: #F3EBCB; color: var(--amber); border-color: var(--gold); }
.badge-bestaetigt { background: #E3EAF3; color: var(--navy); border-color: #B7C5D8; }
.badge-bezahlt, .badge-teilnahme_bestaetigt, .badge-member { background: #E2EFE8; color: var(--gruen); border-color: #A9CBBB; }
.badge-storniert { background: #F3E3E3; color: var(--rot); border-color: #D8B7B7; }

/* ── Flash ── */

.flash { padding: 0.75rem 1rem; border-radius: var(--radius); margin: 0.8rem 0; }
.flash-ok { background: #E2EFE8; color: var(--gruen); border: 1px solid #A9CBBB; }
.flash-fehler { background: #F3E3E3; color: var(--rot); border: 1px solid #D8B7B7; }

/* ── Login-Seiten ── */

body.login-body {
  display: flex; min-height: 100vh; align-items: center; justify-content: center; padding: 1rem;
  background: var(--navy); background-image: linear-gradient(180deg, var(--ink), var(--navy));
}
.login-karte {
  border-radius: var(--radius); padding: 0 2.2rem 2rem; width: 100%; max-width: 440px;
  box-shadow: 0 12px 40px rgb(0 0 0 / 0.35); overflow: hidden;
}
.marke-login { display: flex; margin: 0 -2.2rem 1.5rem; padding: 1.3rem 2.2rem; background: var(--navy); }
.login-karte h1 { margin-top: 0; font-size: 1.7rem; }
.login-links { margin-top: 1.2rem; }
.login-links a { display: inline-flex; align-items: center; min-height: var(--tap); }

/* ── Kleinkram ── */

.hinweis { color: var(--text-soft); font-size: 0.9375rem; }
.naechster-schritt { border-radius: var(--radius); padding: 18px 20px; margin: 16px 0 22px; border-width: 2px; border-top-width: 3px; border-color: var(--gold); }
.naechster-schritt h2 { margin-top: 0; }
.suchleiste { display: flex; gap: 0.6rem; align-items: flex-end; margin-bottom: 1rem; max-width: 480px; }
.suchleiste button { margin-top: 0; }
.aktionen-zelle { white-space: nowrap; }
.trenner-gold { border: 0; border-top: 2px solid var(--gold); margin: 1.5rem 0; }
.text-muted { color: var(--text-soft); }
.text-xs { font-size: 0.9375rem; }

/* Ausstiegs-Ampel (Farbe + Text, nie nur Farbe) */
.ampel { display: inline-flex; align-items: center; gap: 0.4rem; padding: 0.1rem 0.7rem 0.1rem 0.5rem; border-radius: 99px;
  font-size: 0.9375rem; font-weight: 700; white-space: nowrap; border: 1px solid var(--mist-line); background: var(--mist); color: var(--text); }
.ampel-punkt { width: 0.65rem; height: 0.65rem; border-radius: 50%; background: var(--text-soft); display: inline-block; }
.ampel-gruen { background: #E2EFE8; color: var(--gruen); border-color: #A9CBBB; }
.ampel-gruen .ampel-punkt { background: var(--gruen); }
.ampel-gelb { background: #F3EBCB; color: var(--amber); border-color: var(--gold); }
.ampel-gelb .ampel-punkt { background: #D4A017; }
.ampel-rot { background: #F3E3E3; color: var(--rot); border-color: #D8B7B7; }
.ampel-rot .ampel-punkt { background: var(--rot); }
.ampel-grau .ampel-punkt { background: var(--text-soft); }

/* ── Schmale Bildschirme ── */

@media (max-width: 900px) {
  .admin-layout { display: block; }
  .admin-layout + .fuss { margin-left: 0; }
  .admin-sidebar { width: auto; position: static; height: auto; overflow: visible; border-right: 0; border-bottom: 3px solid var(--gold); padding: 1rem 0 0.6rem; }
  .admin-sidebar .sb-logo { padding: 0 1rem 0.8rem; margin-bottom: 0.6rem; }
  .sb-gruppe { display: flex; flex-wrap: wrap; align-items: center; gap: 0 0.2rem; padding: 0 0.6rem; margin-bottom: 0.4rem; }
  .sb-gruppe h4 { flex-basis: 100%; padding: 0 0.4rem; }
  .sb-item { padding: 0.35rem 0.7rem; border-left: 0; border-bottom: 3px solid transparent; border-radius: var(--radius); }
  .sb-item.aktiv { border-bottom-color: var(--gold); }
  .sb-item .desc { display: none; }
  .admin-main { padding: 1.2rem 1rem 2rem; }
  .nav { margin-left: 0; }
  /* Breite Tabellen scrollen in sich, nie die Seite */
  table.liste { display: block; max-width: 100%; overflow-x: auto; }
}
@media (max-width: 600px) {
  h1 { font-size: 1.7rem; }
  .login-karte { padding: 0 1.4rem 1.6rem; }
  .marke-login { margin: 0 -1.4rem 1.2rem; padding: 1.1rem 1.4rem; }
  .suchleiste { flex-wrap: wrap; max-width: none; }
}
