/* =========================================================
   SASP – Basis (Tokens, Typografie, Formulare, Buttons, Szene, Bewegung)
   Hell als Standard, Dunkel automatisch über das Betriebssystem.
   ========================================================= */
@property --p { syntax: '<number>'; inherits: true; initial-value: 0; }

:root {
  --font: 'IBM Plex Sans Variable', 'IBM Plex Sans', ui-sans-serif, system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
  --display: 'Barlow Condensed', 'IBM Plex Sans Variable', 'Arial Narrow', sans-serif;
  --mono: 'IBM Plex Mono', ui-monospace, 'SF Mono', 'Cascadia Code', Consolas, monospace;

  /* Markenfarben (in beiden Modi gleich) */
  --navy-950: #050d1c;
  --navy-900: #0a1730;
  --navy-800: #0f2244;
  --navy-700: #16305c;
  --navy-600: #1f4078;
  --gold-200: #fbe7b2;
  --gold-300: #f3d488;
  --gold-400: #e4b955;
  --gold-500: #cf9f3a;
  --gold-600: #a77b1e;
  --siren-red: #ff4d5e;
  --siren-blue: #3d8bff;
  --on-dark: #e8eef8;
  --on-dark-2: rgba(226, 233, 245, .74);
  --on-dark-3: rgba(226, 233, 245, .5);

  --bg: #f3f5f9;
  --surface: #ffffff;
  --surface-2: #f8f9fc;
  --hover: #eef1f6;
  --border: #e1e6ee;
  --border-2: #cdd4e0;
  --text: #0f1a2e;
  --text-2: #33415a;
  --muted: #5f6b80;
  --faint: #8f9bb0;

  --primary: #1c3d73;
  --primary-hover: #15305c;
  --on-primary: #ffffff;
  --accent: #96690f;
  --ring: 0 0 0 3px rgba(28, 61, 115, .18);

  --green: #067647; --green-bg: #ecfdf3; --green-bd: #abefc6;
  --red: #b42318;   --red-bg: #fef3f2;   --red-bd: #fecdca;
  --amber: #b54708; --amber-bg: #fffaeb; --amber-bd: #fedf89;
  --blue: #175cd3;  --blue-bg: #eff8ff;  --blue-bd: #b2ddff;
  --purple: #5925dc; --purple-bg: #f4f3ff; --purple-bd: #d9d6fe;
  --teal: #0e7090;  --pink: #c11574;
  --gray-bg: #f2f4f7; --gray-bd: #e4e7ec;
  --series: #2a78d6;

  --radius: 12px;
  --radius-sm: 8px;
  --shadow-sm: 0 1px 2px rgba(15, 26, 46, .06);
  --shadow-md: 0 8px 20px -6px rgba(15, 26, 46, .12), 0 2px 5px -2px rgba(15, 26, 46, .06);
  --shadow-lg: 0 24px 48px -14px rgba(15, 26, 46, .26);

  --ease: cubic-bezier(.22, 1, .36, 1);
  --spring: cubic-bezier(.34, 1.56, .64, 1);

  /* Kompatibilität für ältere Inline-Styles */
  --gold: var(--accent); --gold-2: var(--accent); --gold-3: var(--border-2); --gold-soft: var(--amber-bg);
  --surface-3: var(--hover); --bg-2: var(--surface-2); --font-display: var(--display);
  --green-soft: var(--green-bg); --red-soft: var(--red-bg); --blue-soft: var(--blue-bg); --amber-soft: var(--amber-bg); --purple-soft: var(--purple-bg);
  --cyan: var(--teal);
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #08101e;
    --surface: #0e1728;
    --surface-2: #111c30;
    --hover: #16233b;
    --border: #1e2c46;
    --border-2: #2a3b5b;
    --text: #edf2fa;
    --text-2: #c5cfdf;
    --muted: #8d9ab2;
    --faint: #61708c;
    --primary: #e4b955;
    --primary-hover: #efc86b;
    --on-primary: #1a1304;
    --accent: #e8c26a;
    --ring: 0 0 0 3px rgba(228, 185, 85, .22);
    --green: #47cd89; --green-bg: rgba(23, 178, 106, .13); --green-bd: rgba(23, 178, 106, .34);
    --red: #ff7a72;   --red-bg: rgba(240, 68, 56, .13);   --red-bd: rgba(240, 68, 56, .34);
    --amber: #fdb022; --amber-bg: rgba(247, 144, 9, .13); --amber-bd: rgba(247, 144, 9, .34);
    --blue: #6aa8ff;  --blue-bg: rgba(61, 139, 255, .14); --blue-bd: rgba(61, 139, 255, .36);
    --purple: #a993ff; --purple-bg: rgba(122, 90, 248, .16); --purple-bd: rgba(122, 90, 248, .38);
    --teal: #3cc5e6;  --pink: #f472b6;
    --gray-bg: #16233b; --gray-bd: #2a3b5b;
    --series: #3987e5;
    --shadow-sm: none;
    --shadow-md: 0 10px 26px -10px rgba(0, 0, 0, .7);
    --shadow-lg: 0 24px 48px -14px rgba(0, 0, 0, .8);
    color-scheme: dark;
  }
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: 76px; }
[hidden] { display: none !important; } /* versteckt bleibt versteckt – auch wenn eine Komponente display: flex/grid setzt */
body { margin: 0; background: var(--bg); color: var(--text); font: 14px/1.55 var(--font); -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility; }
img, svg { max-width: 100%; }
a { color: var(--blue); text-decoration: none; transition: color .15s; }
a:hover { text-decoration: underline; text-underline-offset: 2px; }
h1, h2, h3, h4 { font-weight: 600; letter-spacing: 0; line-height: 1.2; margin: 0 0 .5em; color: var(--text); }
/* Überschriften in Barlow Condensed (schmal, wie Beschilderung und Dienstdokumente), kleine Zwischentitel bleiben in Plex */
h1, h2, h3 { font-family: var(--display); letter-spacing: .005em; }
h1 { font-size: 28px; } h2 { font-size: 23px; } h3 { font-size: 18px; } h4 { font-size: 14.5px; }
.display { font-family: var(--display); font-weight: 600; letter-spacing: .01em; }
p { margin: 0 0 1em; }
hr { border: 0; border-top: 1px solid var(--border); margin: 20px 0; }
::selection { background: color-mix(in srgb, var(--primary) 22%, transparent); }
code, kbd { font-family: var(--mono); font-size: .88em; }
kbd { border: 1px solid var(--border-2); border-bottom-width: 2px; border-radius: 4px; padding: 0 5px; color: var(--muted); background: var(--surface); }
:focus-visible { outline: 2px solid var(--blue); outline-offset: 2px; }

.muted { color: var(--muted); }
.small { font-size: 13px; }
.tiny { font-size: 12px; }
.gold { color: var(--accent); }
.text-green { color: var(--green); } .text-red { color: var(--red); } .text-amber { color: var(--amber); } .text-blue { color: var(--blue); }
.nowrap { white-space: nowrap; }
.center { text-align: center; }
.right { text-align: right; }
.mono { font-family: var(--mono); font-variant-numeric: tabular-nums; }
.flex { display: flex; align-items: center; gap: 10px; }
.flex-wrap { flex-wrap: wrap; }
.between { justify-content: space-between; }
.grow { flex: 1; min-width: 0; }
.mt-0 { margin-top: 0 } .mt-1 { margin-top: 8px } .mt-2 { margin-top: 16px } .mt-3 { margin-top: 24px }
.mb-0 { margin-bottom: 0 } .mb-1 { margin-bottom: 8px } .mb-2 { margin-bottom: 16px } .mb-3 { margin-bottom: 24px }
.hidden { display: none !important; }
.sr-only, input.sr-only { position: absolute !important; width: 1px !important; height: 1px !important; padding: 0 !important; margin: -1px; border: 0 !important; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* Icons (Font Awesome 7 ist standardmäßig festbreit) */
.fa-solid, .fa-regular, .fa-brands { line-height: 1; }
.ic-chip { --ic: var(--blue); width: 36px; height: 36px; border-radius: 10px; flex-shrink: 0; display: inline-grid; place-items: center; font-size: 14px;
  color: var(--ic); background: color-mix(in srgb, var(--ic) 13%, transparent); }

/* Goldener Schriftzug mit langsamem Schimmer */
.text-gold { background: linear-gradient(100deg, var(--gold-400) 0%, var(--gold-300) 28%, #fff4d2 46%, var(--gold-300) 62%, var(--gold-500) 100%);
  background-size: 220% auto; -webkit-background-clip: text; background-clip: text; color: transparent; animation: shimmer 7s linear infinite; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 7px; position: relative;
  height: 36px; padding: 0 14px; border-radius: var(--radius-sm);
  border: 1px solid var(--border-2); background: var(--surface); color: var(--text-2);
  font: 500 13.5px/1 var(--font); cursor: pointer; text-decoration: none; white-space: nowrap;
  box-shadow: var(--shadow-sm);
  transition: background-color .15s, border-color .15s, color .15s, box-shadow .2s, transform .15s var(--ease), filter .15s;
}
.btn:hover { background: var(--hover); color: var(--text); text-decoration: none; }
.btn:active { transform: scale(.97); transition-duration: .06s; }
.btn:disabled, .btn.disabled { opacity: .5; pointer-events: none; }
.btn .fa-solid, .btn .fa-regular, .btn .fa-brands { font-size: .95em; opacity: .85; }
.btn-primary { background: linear-gradient(180deg, color-mix(in srgb, var(--primary) 86%, #fff), var(--primary)); border-color: var(--primary); color: var(--on-primary);
  box-shadow: 0 1px 2px rgba(15, 26, 46, .12), inset 0 1px 0 rgba(255, 255, 255, .14); }
.btn-primary:hover { background: var(--primary-hover); border-color: var(--primary-hover); color: var(--on-primary); transform: translateY(-1px); box-shadow: 0 8px 18px -8px color-mix(in srgb, var(--primary) 70%, transparent); }
.btn-primary:active { transform: translateY(0) scale(.97); }
.btn-gold { overflow: hidden; background: linear-gradient(180deg, var(--gold-300), var(--gold-500)); border-color: var(--gold-500); color: #1a1304; font-weight: 600;
  box-shadow: 0 8px 22px -10px rgba(228, 185, 85, .75), inset 0 1px 0 rgba(255, 255, 255, .45); }
.btn-gold::after { content: ''; position: absolute; inset: 0; background: linear-gradient(105deg, transparent 30%, rgba(255, 255, 255, .55) 50%, transparent 70%); transform: translateX(-130%); transition: transform .8s var(--ease); pointer-events: none; }
.btn-gold:hover { background: linear-gradient(180deg, var(--gold-200), var(--gold-400)); color: #1a1304; transform: translateY(-1px); box-shadow: 0 12px 26px -10px rgba(228, 185, 85, .85), inset 0 1px 0 rgba(255, 255, 255, .5); }
.btn-gold:hover::after { transform: translateX(130%); }
.btn-gold .fa-solid, .btn-gold .fa-brands { opacity: 1; }
.btn-glass { background: rgba(255, 255, 255, .08); border-color: rgba(255, 255, 255, .22); color: #fff; box-shadow: none; backdrop-filter: blur(6px); }
.btn-glass:hover { background: rgba(255, 255, 255, .16); border-color: rgba(255, 255, 255, .36); color: #fff; }
.btn-ghost { background: transparent; border-color: transparent; box-shadow: none; }
.btn-ghost:hover { background: var(--hover); }
.btn-danger { color: var(--red); }
.btn-danger:hover { background: var(--red-bg); border-color: var(--red-bd); color: var(--red); }
.btn-success { color: var(--green); }
.btn-success:hover { background: var(--green-bg); border-color: var(--green-bd); color: var(--green); }
.btn-blue { color: var(--blue); }
.btn-blue:hover { background: var(--blue-bg); border-color: var(--blue-bd); color: var(--blue); }
.btn-sm { height: 30px; padding: 0 10px; font-size: 13px; }
.btn-xs { height: 26px; padding: 0 8px; font-size: 12px; gap: 5px; border-radius: 6px; }
.btn-lg { height: 44px; padding: 0 20px; font-size: 15px; border-radius: 10px; }
.btn-icon { width: 36px; padding: 0; }
.btn-icon.btn-sm { width: 30px; }
.btn-block { width: 100%; }
.btn-group { display: inline-flex; gap: 6px; flex-wrap: wrap; }

/* ---------- Badges ---------- */
/* Sachliche Kennzeichnung: eckig, ohne leuchtenden Rand, Symbol in Statusfarbe, Text gut lesbar */
.badge { --bc: var(--muted); display: inline-flex; align-items: center; justify-content: center; gap: 6px; min-width: 22px; height: 22px; padding: 0 8px; border-radius: 5px; font-size: 12px; font-weight: 600; line-height: 1; white-space: nowrap;
  border: 1px solid color-mix(in srgb, var(--bc) 30%, transparent); background: color-mix(in srgb, var(--bc) 12%, var(--surface)); color: color-mix(in srgb, var(--bc) 78%, var(--text)); font-variant-numeric: tabular-nums; }
.badge .fa-solid, .badge .fa-regular { font-size: 11px; width: auto; color: var(--bc); }
.b-green { --bc: var(--green); }
.b-red { --bc: var(--red); }
.b-blue { --bc: var(--blue); }
.b-amber, .b-gold { --bc: var(--amber); }
.b-purple { --bc: var(--purple); }
.b-gray { --bc: var(--muted); }

/* ---------- Formulare ---------- */
label { display: block; font-size: 13px; font-weight: 500; color: var(--text-2); margin-bottom: 6px; }
.req::after { content: ' *'; color: var(--red); }
input[type=text], input[type=password], input[type=email], input[type=number], input[type=date], input[type=datetime-local], input[type=time], input[type=search], input[type=url], input[type=color], select, textarea {
  width: 100%; height: 38px; padding: 0 11px; border-radius: var(--radius-sm); border: 1px solid var(--border-2); background: var(--surface); color: var(--text);
  font: 14px/1.4 var(--font); box-shadow: var(--shadow-sm); outline: none; transition: border-color .15s, box-shadow .2s, background-color .15s;
}
input:hover:not(:focus):not(:disabled), select:hover:not(:focus):not(:disabled), textarea:hover:not(:focus):not(:disabled) { border-color: color-mix(in srgb, var(--primary) 30%, var(--border-2)); }
textarea { height: auto; min-height: 92px; padding: 9px 11px; resize: vertical; }
input[type=color] { padding: 3px; cursor: pointer; }
input[type=file] { max-width: 100%; font: 13px var(--font); color: var(--muted); }
input[type=file]::file-selector-button { height: 32px; padding: 0 12px; margin-right: 10px; border-radius: 8px; border: 1px solid var(--border-2); background: var(--surface); color: var(--text-2);
  font: 500 13px var(--font); cursor: pointer; transition: background-color .15s, border-color .15s; }
input[type=file]::file-selector-button:hover { background: var(--hover); border-color: color-mix(in srgb, var(--primary) 30%, var(--border-2)); }
input:focus, select:focus, textarea:focus { border-color: var(--primary); box-shadow: var(--ring); }
input::placeholder, textarea::placeholder { color: var(--faint); }
input:disabled, select:disabled, textarea:disabled { background: var(--surface-2); color: var(--muted); }
select { appearance: none; padding-right: 32px; cursor: pointer;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 16 16' fill='%23667085'%3E%3Cpath d='M1.6 5.1a.6.6 0 0 1 .85 0L8 10.6l5.55-5.5a.6.6 0 1 1 .85.85l-6 6a.6.6 0 0 1-.85 0l-6-6a.6.6 0 0 1 0-.85z'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right 11px center; }
select[multiple], select[size] { height: auto; background-image: none; padding: 6px; }
input[type=checkbox], input[type=radio] { accent-color: var(--primary); width: 16px; height: 16px; margin: 0; cursor: pointer; flex-shrink: 0; }
.check { display: flex; align-items: flex-start; gap: 9px; font-weight: 400; color: var(--text-2); font-size: 13.5px; cursor: pointer; margin: 0; }
.check input { margin-top: 2px; }
/* Abstandsklassen sollen auch an .check wirken (sonst gewinnt „margin: 0“ oben) */
.check.mt-1 { margin-top: 8px } .check.mt-2 { margin-top: 16px } .check.mt-3 { margin-top: 24px }
.check.mb-1 { margin-bottom: 8px } .check.mb-2 { margin-bottom: 16px } .check.mb-3 { margin-bottom: 24px }
.field { margin-bottom: 16px; }
.field .hint { font-size: 12.5px; color: var(--muted); margin-top: 5px; }
.form-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 16px; }
.form-grid .full { grid-column: 1 / -1; }
.form-grid.cols-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
@media (max-width: 640px) { .form-grid, .form-grid.cols-3 { grid-template-columns: 1fr; } .form-grid > [style*="span"] { grid-column: auto !important; } }
.input-icon { position: relative; }
.input-icon > .fa-solid { position: absolute; left: 11px; top: 50%; transform: translateY(-50%); color: var(--faint); pointer-events: none; font-size: 13px; transition: color .15s; }
.input-icon:focus-within > .fa-solid { color: var(--primary); }
.input-icon input { padding-left: 34px; }

/* ---------- Hinweise ---------- */
/* Hinweise: ruhige Fläche, farbige Kante links, Symbol in einem kleinen Feld, Aktion rechts */
.alert { --ac: var(--blue); display: flex; gap: 12px; align-items: center; min-height: 50px; padding: 9px 12px 9px 14px; border-radius: var(--radius-sm); margin-bottom: 16px; font-size: 13.5px;
  background: var(--surface); border: 1px solid var(--border); box-shadow: inset 3px 0 0 var(--ac), var(--shadow-sm); color: var(--ac); animation: rise .4s var(--ease) backwards; }
.alert > .fa-solid:first-child, .alert > .fa-regular:first-child, .alert > .fa-brands:first-child { flex-shrink: 0; width: 30px; height: 30px; display: grid; place-items: center; border-radius: 7px; font-size: 13.5px;
  background: color-mix(in srgb, var(--ac) 13%, transparent); color: var(--ac); }
.alert > .btn, .alert > form, .alert > a.btn { flex-shrink: 0; }
.alert-success { --ac: var(--green); }
.alert-error { --ac: var(--red); }
.alert-warning { --ac: var(--amber); }
.alert-info { --ac: var(--blue); }
.alert > div { color: var(--text-2); }
.alert strong { color: var(--text); font-weight: 600; }
.alert ul { margin: 4px 0 0; padding-left: 18px; }
.alert .close { margin-left: auto; background: none; border: 0; color: var(--muted); cursor: pointer; padding: 2px; }
.alert .alert-title { display: block; font-size: 13.5px; line-height: 1.3; }
.alert .alert-text { display: block; margin-top: 2px; font-size: 12.5px; color: var(--muted); line-height: 1.4; }
.alert .alert-list { display: flex; flex-wrap: wrap; gap: 4px 6px; margin-top: 5px; padding: 0; list-style: none; }
.alert .alert-list li { display: inline-flex; align-items: center; gap: 6px; height: 22px; padding: 0 8px; border-radius: 4px; font-size: 12px; color: var(--text-2);
  background: color-mix(in srgb, var(--ac) 8%, var(--surface)); }
.alert .alert-list li .fa-solid { font-size: 10.5px; color: var(--ac); }

/* ---------- Rang, Division, Avatare ---------- */
.rank-pill, .div-pill { --pc: var(--muted); display: inline-flex; align-items: center; gap: 6px; height: 24px; padding: 0 9px 0 7px; border-radius: 5px; font-size: 12.5px; font-weight: 550; white-space: nowrap;
  color: color-mix(in srgb, var(--pc) 62%, var(--text)); background: color-mix(in srgb, var(--pc) 10%, var(--surface)); border: 1px solid color-mix(in srgb, var(--pc) 30%, var(--border)); }
.rank-pill { --pc: var(--rc, var(--muted)); }
.rank-pill.only { padding: 0 6px; gap: 0; cursor: help; }
.div-pill { --pc: var(--dc, var(--muted)); }
.div-pill.extra { border-style: dashed; background: transparent; } /* weitere Division (Stammdivision durchgezogen) */
.rank-pill .insignia { stroke: color-mix(in srgb, var(--pc) 82%, var(--text)); }
.div-pill .fa-solid { font-size: 11px; color: color-mix(in srgb, var(--pc) 82%, var(--text)); width: auto; }
.insignia { flex-shrink: 0; }
/* Rollen wie Badges: eckig, farbige Kante statt leuchtendem Rahmen */
.role-pill { --pc: var(--rc, var(--purple)); display: inline-flex; align-items: center; gap: 6px; height: 22px; padding: 0 8px; border-radius: 5px; font-size: 12px; font-weight: 600; white-space: nowrap;
  color: color-mix(in srgb, var(--pc) 78%, var(--text)); background: color-mix(in srgb, var(--pc) 12%, var(--surface)); border: 1px solid color-mix(in srgb, var(--pc) 30%, transparent); }
.role-pill .fa-solid { font-size: 11px; width: auto; color: var(--pc); }
.avatar { --s: 40px; --av-h: 215; width: var(--s); height: var(--s); border-radius: 50%; flex-shrink: 0; object-fit: cover; display: inline-grid; place-items: center;
  background: hsl(var(--av-h) 62% 91%); color: hsl(var(--av-h) 52% 30%); font: 650 calc(var(--s) * .38)/1 var(--font); letter-spacing: 0; }
@media (prefers-color-scheme: dark) { .avatar { background: hsl(var(--av-h) 38% 24%); color: hsl(var(--av-h) 75% 84%); } }
img.avatar { background: var(--hover); }
.avatar.ring { box-shadow: 0 0 0 2px var(--surface), 0 0 0 3px var(--border-2); }

/* ---------- Ordensbänder (Panel und Hall of Fame) ---------- */
.ribbon { --rb: var(--muted); display: inline-block; flex-shrink: 0; width: 38px; height: 12px; border-radius: 2px; vertical-align: middle;
  background: linear-gradient(180deg, rgba(255, 255, 255, .3), rgba(255, 255, 255, 0) 45%, rgba(0, 0, 0, .16)), var(--rb);
  box-shadow: inset 0 0 0 1px rgba(0, 0, 0, .2), 0 1px 2px rgba(0, 0, 0, .25); }
.ribbon.lg { width: 100%; max-width: 160px; height: 22px; border-radius: 3px; }
.ribbon-rack { display: grid; grid-template-columns: repeat(3, 34px); gap: 3px; justify-content: start; }
.ribbon-rack .ribbon { width: 34px; height: 11px; }
.ribbon-rack.sm { grid-template-columns: repeat(6, 22px); gap: 2px; margin-top: 4px; }
.ribbon-rack.sm .ribbon { width: 22px; height: 8px; }

/* ---------- Stellenkarte (öffentliche Stellenbörse, interne Ausschreibungen, Vorschau im Panel) ---------- */
.job-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(310px, 1fr)); gap: 16px; }
.job-grid.two { grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); }
.job-chip { display: inline-flex; align-items: center; gap: 7px; height: 36px; padding: 0 14px; border-radius: 999px; border: 1px solid var(--border-2); background: var(--surface); color: var(--text-2);
  font: 600 13.5px var(--font); cursor: pointer; text-decoration: none; transition: background-color .15s, color .15s, border-color .15s; }
.job-chip span { font-weight: 500; color: var(--muted); }
.job-chip:hover { border-color: var(--text-2); color: var(--text); text-decoration: none; }
.job-chip.active { background: var(--text); border-color: var(--text); color: var(--surface); }
.job-chip.active span { color: color-mix(in srgb, var(--surface) 70%, transparent); }
.job-card { position: relative; display: flex; flex-direction: column; height: 100%; padding: 20px 18px 16px 20px; border-radius: 16px; background: var(--surface); border: 1px solid var(--border-2);
  color: var(--text); transition: border-color .2s, box-shadow .25s, transform .25s var(--ease); }
.job-card:hover { border-color: color-mix(in srgb, var(--text) 45%, var(--border-2)); box-shadow: var(--shadow-md); transform: translateY(-2px); }
.job-card:hover .job-title { text-decoration: underline; text-underline-offset: 3px; text-decoration-thickness: 1.5px; }
.job-link { position: absolute; inset: 0; z-index: 1; border-radius: inherit; }
.job-link:focus-visible { outline: 2px solid var(--blue); outline-offset: 2px; }
.job-top { display: flex; align-items: flex-start; gap: 12px; }
.job-title { flex: 1; margin: 0; font-size: 18.5px; font-weight: 700; line-height: 1.3; letter-spacing: -.01em; color: var(--text);
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; overflow-wrap: anywhere; }
.job-save { position: relative; z-index: 2; flex-shrink: 0; width: 38px; height: 38px; margin: -6px -6px 0 0; border-radius: 10px; border: 0; background: none; color: var(--text); font-size: 19px; cursor: pointer;
  display: grid; place-items: center; transition: background-color .15s, color .15s; }
.job-save:hover { background: var(--hover); }
.job-save.on, [data-save-job].on .fa-solid { color: var(--accent); }
[data-save-job].pop i { animation: save-pop .35s var(--spring); }
@keyframes save-pop { 50% { transform: scale(1.35); } }
.job-company { margin-top: 8px; font-size: 14.5px; color: var(--text-2); }
.job-location { margin-top: 1px; font-size: 14.5px; color: var(--text-2); }
.job-tags { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 14px; }
.job-tag { display: inline-flex; align-items: center; gap: 6px; padding: 4px 9px; border-radius: 6px; background: var(--hover); color: var(--text-2); font-size: 13px; font-weight: 600; line-height: 1.35; }
.job-tag.div i { width: 7px; height: 7px; border-radius: 50%; background: var(--dc); }
.job-foot { display: flex; align-items: center; flex-wrap: wrap; gap: 8px 12px; margin-top: auto; padding-top: 16px; font-size: 12.5px; color: var(--muted); }
.job-new { padding: 2px 8px; border-radius: 6px; background: var(--red-bg); color: var(--red); font-weight: 700; font-size: 12px; }
.job-top-badge { padding: 2px 8px; border-radius: 6px; background: var(--amber-bg); color: var(--amber); font-weight: 700; font-size: 12px; }
.job-easy { display: inline-flex; align-items: center; gap: 6px; }
.job-easy .fa-solid { color: var(--blue); font-size: 11px; }
.job-age { margin-left: auto; }
.job-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.job-list li { display: flex; gap: 12px; align-items: flex-start; font-size: 15px; color: var(--text-2); }
.job-list li .fa-solid { width: 24px; height: 24px; border-radius: 50%; flex-shrink: 0; display: grid; place-items: center; font-size: 11px; margin-top: 1px; background: var(--green-bg); color: var(--green); }
.job-list.profile li .fa-solid { background: var(--blue-bg); color: var(--blue); }

.spinner { width: 22px; height: 22px; border: 2px solid var(--border-2); border-top-color: var(--primary); border-radius: 50%; animation: spin .7s linear infinite; display: inline-block; }
#snow { position: fixed; inset: 0; pointer-events: none; z-index: 9999; }

/* =========================================================
   Szene: Nachthimmel, Skyline, Blaulicht (Startseite, Login, Dashboard)
   Ein hochgeladenes Hintergrundbild ersetzt Skyline und Sterne.
   ========================================================= */
.hero-bg { position: relative; isolation: isolate; overflow: hidden; color: var(--on-dark);
  background:
    radial-gradient(70% 55% at 50% 108%, rgba(56, 120, 220, .30), transparent 70%),
    radial-gradient(90% 80% at 88% -10%, rgba(37, 79, 150, .55), transparent 60%),
    linear-gradient(170deg, var(--navy-800) 0%, var(--navy-900) 55%, var(--navy-950) 100%); }
.hero-bg h1, .hero-bg h2, .hero-bg h3 { color: #fff; }
.scene { position: absolute; inset: 0; z-index: -1; pointer-events: none; overflow: hidden; }
.scene .stars { position: absolute; inset: 0 0 30% 0; opacity: .55;
  background-image:
    radial-gradient(1.2px 1.2px at 24px 40px, #fff 50%, transparent 52%), radial-gradient(1px 1px at 150px 92px, #dbe8ff 50%, transparent 52%),
    radial-gradient(1px 1px at 262px 26px, #fff 50%, transparent 52%), radial-gradient(1.4px 1.4px at 338px 128px, #fff 50%, transparent 52%),
    radial-gradient(1px 1px at 70px 150px, #cfe0ff 50%, transparent 52%), radial-gradient(1.1px 1.1px at 470px 70px, #fff 50%, transparent 52%),
    radial-gradient(1px 1px at 540px 180px, #fff 50%, transparent 52%);
  background-size: 380px 170px, 380px 170px, 380px 170px, 380px 170px, 560px 230px, 560px 230px, 560px 230px;
  mask-image: linear-gradient(#000 30%, transparent); animation: twinkle 7s ease-in-out infinite alternate; }
.scene .grid-lines { position: absolute; inset: 0; background-image: linear-gradient(rgba(255, 255, 255, .045) 1px, transparent 1px), linear-gradient(90deg, rgba(255, 255, 255, .045) 1px, transparent 1px);
  background-size: 64px 64px; background-position: center top; mask-image: radial-gradient(ellipse 75% 70% at 60% 35%, #000 10%, transparent 75%); }
.scene-photo { position: absolute; inset: -2%; background-size: cover; background-position: center; animation: kenburns 40s ease-in-out infinite alternate; }
.scene-photo::after { content: ''; position: absolute; inset: 0;
  background: linear-gradient(90deg, rgba(5, 13, 28, .9) 0%, rgba(5, 13, 28, .62) 45%, rgba(5, 13, 28, .35) 100%), linear-gradient(0deg, rgba(5, 13, 28, .85), transparent 45%); }
/* Animationen außerhalb des sichtbaren Bereichs anhalten (spart Rechenzeit beim Scrollen) – Klasse setzt ein IntersectionObserver */
.anim-off, .anim-off *, .anim-off::before, .anim-off::after, .anim-off *::before, .anim-off *::after { animation-play-state: paused !important; }
/* Diashow: Bilder liegen übereinander und werden überblendet; jedes Bild zoomt langsam (Ken Burns) */
.scene-slides { position: absolute; inset: 0; }
.scene-photo.slide { opacity: 0; transition: opacity 1.6s ease-in-out; animation: none; }
.scene-photo.slide.on { opacity: 1; }
.scene-photo.slide.zoom { animation: kenburns 14s ease-out both; } /* bleibt beim Ausblenden, damit das Bild nicht zurückspringt */
.slide-dots { position: absolute; right: max(20px, calc((100vw - 1240px) / 2)); bottom: 28px; z-index: 2; display: flex; gap: 8px; }
.slide-dots button { width: 34px; height: 18px; padding: 0; border: 0; background: none; cursor: pointer; display: grid; place-items: center; }
.slide-dots span { display: block; width: 100%; height: 3px; border-radius: 3px; background: rgba(255, 255, 255, .28); transition: background-color .3s; overflow: hidden; }
.slide-dots button:hover span { background: rgba(255, 255, 255, .5); }
.slide-dots button.on span { background: linear-gradient(90deg, var(--gold-400) 50%, rgba(255, 255, 255, .28) 50%) right / 200% 100%; animation: slide-progress 7s linear forwards; }
.slide-dots button:focus-visible { outline: 2px solid var(--gold-400); outline-offset: 2px; border-radius: 4px; }
@keyframes slide-progress { to { background-position: left; } }
@media (prefers-reduced-motion: reduce) { .scene-photo.slide.zoom { animation: none; } .slide-dots button.on span { animation: none; background: var(--gold-400); } }
.glow { position: absolute; top: -38vmax; width: 70vmax; height: 70vmax; border-radius: 50%; opacity: .14; will-change: opacity; }
.glow-red { left: -26vmax; background: radial-gradient(closest-side, rgba(255, 77, 94, .65), rgba(255, 77, 94, .18) 55%, transparent); animation: siren 2.8s infinite; }
.glow-blue { right: -26vmax; background: radial-gradient(closest-side, rgba(61, 139, 255, .75), rgba(61, 139, 255, .2) 55%, transparent); animation: siren 2.8s 1.4s infinite; }
.scene.calm .glow { animation: breathe 9s ease-in-out infinite; }
.scene.calm .glow-blue { animation-delay: -4.5s; }
.scene-mark { position: absolute; right: -3%; top: 50%; width: min(560px, 62%); aspect-ratio: 1; translate: 0 -50%;
  background: var(--logo-img, url('/img/logo-720.webp')) center / contain no-repeat; opacity: .09; filter: saturate(.7); animation: drift 28s ease-in-out infinite alternate; }
.skyline { position: absolute; left: 0; right: 0; bottom: 9px; height: clamp(100px, 15vw, 200px); background: url('/img/skyline.svg') repeat-x left bottom / auto 100%; }
.road { position: absolute; left: 0; right: 0; bottom: 0; height: 9px; background: #040b18; overflow: hidden; }
.road::before { content: ''; position: absolute; left: 0; right: 0; top: 0; height: 1px; background: rgba(120, 160, 230, .18); }
.trail { position: absolute; left: -640px; right: 0; height: 2px; border-radius: 2px; will-change: transform; }
.trail-r { top: 2px; background: repeating-linear-gradient(90deg, transparent 0 70px, rgba(255, 82, 82, .1) 70px, rgba(255, 82, 82, .85) 104px, transparent 106px 230px, rgba(255, 82, 82, .1) 230px, rgba(255, 82, 82, .8) 252px, transparent 254px 420px, rgba(255, 82, 82, .1) 420px, rgba(255, 82, 82, .9) 470px, transparent 472px 640px);
  animation: drive 9s linear infinite; }
.trail-w { top: 5px; background: repeating-linear-gradient(90deg, transparent 0 40px, rgba(255, 236, 190, .95) 42px, rgba(255, 236, 190, .1) 80px, transparent 80px 300px, rgba(255, 236, 190, .95) 302px, rgba(255, 236, 190, .1) 330px, transparent 330px 520px, rgba(255, 236, 190, .9) 522px, rgba(255, 236, 190, .1) 566px, transparent 566px 640px);
  animation: drive 12s linear infinite reverse; }
.patrol { position: absolute; left: 21%; bottom: 3px; width: 12px; height: 3px; }
.patrol::before, .patrol::after { content: ''; position: absolute; top: 0; width: 5px; height: 3px; border-radius: 2px; }
.patrol::before { left: 0; background: var(--siren-red); box-shadow: 0 0 8px 3px rgba(255, 77, 94, .75); animation: flash 1.1s steps(1) infinite; }
.patrol::after { right: 0; background: var(--siren-blue); box-shadow: 0 0 8px 3px rgba(61, 139, 255, .8); animation: flash 1.1s .55s steps(1) infinite; }

/* =========================================================
   Bewegung
   ========================================================= */
/* Keine seitenübergreifenden View Transitions: In Hintergrund-Tabs verzögern sie das erste Bild um Sekunden. */
@keyframes spin { to { transform: rotate(360deg); } }
@keyframes rise { from { opacity: 0; transform: translateY(10px); } }
@keyframes fade { from { opacity: 0; } }
@keyframes pop { from { opacity: 0; transform: translateY(-6px) scale(.97); } }
@keyframes zoom-in { from { opacity: 0; transform: scale(.94); } }
@keyframes grow-x { from { transform: scaleX(0); } }
@keyframes ring-fill { from { --p: 0; } }
@keyframes float { 50% { transform: translateY(-12px); } }
@keyframes shimmer { to { background-position: -220% center; } }
@keyframes twinkle { to { opacity: .25; } }
@keyframes kenburns { to { transform: scale(1.1) translate(-1.5%, -1%); } }
@keyframes drift { from { transform: rotate(-7deg) scale(1); } to { transform: rotate(5deg) scale(1.07); } }
@keyframes drive { to { transform: translateX(640px); } }
@keyframes flash { 0% { opacity: 1; } 25% { opacity: .15; } 50% { opacity: 1; } 75%, 100% { opacity: .15; } }
@keyframes siren { 0%, 34%, 100% { opacity: .1; } 6%, 20% { opacity: .5; } 13% { opacity: .16; } }
@keyframes breathe { 0%, 100% { opacity: .1; } 50% { opacity: .3; } }
@keyframes ping { 0% { box-shadow: 0 0 0 0 color-mix(in srgb, currentColor 55%, transparent); } 75%, 100% { box-shadow: 0 0 0 7px transparent; } }

/* ---------- Bestätigung nach Anmeldung und Registrierung: Kreis und Haken zeichnen sich, dann gibt die Fläche die Seite frei ---------- */
.splash { position: fixed; inset: 0; z-index: 1000; display: grid; place-items: center; pointer-events: none; color: #fff;
  background: radial-gradient(circle at 50% 42%, #18346a, #0a1630 72%); animation: splash-out .35s var(--ease) .9s forwards; }
.splash-box { display: grid; justify-items: center; gap: 6px; padding: 24px; text-align: center; animation: splash-away .35s var(--ease) .9s forwards; }
.splash-check { width: 88px; height: 88px; margin-bottom: 14px; fill: none; stroke-linecap: round; stroke-linejoin: round; overflow: visible;
  filter: drop-shadow(0 0 18px rgba(228, 185, 85, .35)); animation: splash-pop .35s var(--spring) .6s; }
.splash-check circle { stroke: var(--gold-400); stroke-width: 3; fill: rgba(228, 185, 85, .1); stroke-dasharray: 145; stroke-dashoffset: 145;
  transform: rotate(-90deg); transform-box: fill-box; transform-origin: center; animation: draw .45s var(--ease) .05s forwards, fill-in .35s ease .35s backwards; }
.splash-check path { stroke: #fff; stroke-width: 4; stroke-dasharray: 31; stroke-dashoffset: 31; animation: draw .25s var(--ease) .4s forwards; }
.splash strong { font: 600 24px/1.2 var(--display); letter-spacing: .02em; animation: rise .35s var(--ease) .3s backwards; }
.splash-box span { color: var(--on-dark-2); font-size: 14.5px; animation: rise .35s var(--ease) .4s backwards; }
@keyframes draw { to { stroke-dashoffset: 0; } }
@keyframes fill-in { from { fill: transparent; } }
@keyframes splash-pop { 50% { transform: scale(1.08); } }
@keyframes splash-out { to { opacity: 0; visibility: hidden; } }
@keyframes splash-away { to { opacity: 0; transform: scale(1.08); } }
/* Erfolgsmeldungen: kleiner Haken, der sich zeichnet */
.alert > .flash-check { flex-shrink: 0; width: 30px; height: 30px; padding: 5px; border-radius: 7px; background: color-mix(in srgb, var(--ac) 13%, transparent);
  fill: none; stroke: var(--ac); stroke-width: 2.3; stroke-linecap: round; stroke-linejoin: round; }
.flash-check circle { stroke-dasharray: 66; stroke-dashoffset: 66; transform: rotate(-90deg); transform-box: fill-box; transform-origin: center; animation: draw .5s var(--ease) .2s forwards; }
.flash-check path { stroke-dasharray: 14; stroke-dashoffset: 14; animation: draw .28s var(--ease) .6s forwards; }
/* Hinweis schließen: ausblenden, dann den Platz weich freigeben */
.alert.bye { opacity: 0; height: 0 !important; min-height: 0; margin-bottom: 0; padding-top: 0; padding-bottom: 0; border-width: 0; overflow: hidden;
  transition: opacity .2s, height .35s var(--ease) .08s, min-height .35s var(--ease) .08s, margin .35s var(--ease) .08s, padding .35s var(--ease) .08s; }
/* Absenden: Kreisel statt Symbol, bis die nächste Seite da ist */
.btn.is-loading { pointer-events: none; }
.btn.is-loading:disabled { opacity: .85; }
.btn.is-loading > .fa-solid:first-child, .btn.is-loading > .fa-regular:first-child, .btn.is-loading > .fa-brands:first-child { display: none; }
.btn.is-loading::before { content: ''; width: 13px; height: 13px; flex: none; border-radius: 50%; border: 2px solid currentColor; border-right-color: transparent; animation: spin .6s linear infinite; }
/* Häkchen und Auswahl: kurzer Federimpuls beim Ankreuzen */
input[type=checkbox]:checked:focus, input[type=radio]:checked:focus { animation: check-pop .3s var(--spring); }
@keyframes check-pop { 50% { transform: scale(1.22); } }

/* Einblenden beim Scrollen: public.js setzt .reveal-ready erst, wenn der Observer läuft – ohne JS bleibt alles sichtbar */
.reveal-ready .reveal:not(.in) { opacity: 0; }
.reveal-ready .reveal.in:not(.instant) { animation: reveal .75s var(--ease) backwards; animation-delay: calc(var(--i, 0) * 70ms); }
@keyframes reveal { from { opacity: 0; transform: translateY(22px); } }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: .01ms !important; animation-delay: 0s !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; transition-delay: 0s !important; }
  .glow { opacity: .2 !important; }
}
