/* CCM 3.0 — die bewährte Anmeldeseite (views/login.php, Stil in app.css .ccm-auth) dezent im 3.0-Look:
   tiefes Schwarz statt Anthrazit, klares CCM-Rot, Jost wie im Intranet, dazu das Intro aus dem Kundenbereich.
   Aufbau, Abstände und Verhalten bleiben unverändert. */
@font-face { font-family: "CCM Jost"; src: url("../fonts/jost-latin-400-normal.woff2") format("woff2"); font-weight: 400; font-display: swap; }
@font-face { font-family: "CCM Jost"; src: url("../fonts/jost-latin-500-normal.woff2") format("woff2"); font-weight: 500; font-display: swap; }
@font-face { font-family: "CCM Jost"; src: url("../fonts/jost-latin-600-normal.woff2") format("woff2"); font-weight: 600; font-display: swap; }
@font-face { font-family: "CCM Serif"; src: url("../fonts/cormorant-garamond-latin-300-normal.woff2") format("woff2"); font-weight: 300; font-display: swap; }

.ccm-auth {
  --a-bg: #030303;
  --a-panel: #08080a;
  --a-surface: #0e0e10;
  --a-line: rgba(255, 255, 255, .08);
  --a-line-strong: rgba(255, 255, 255, .15);
  --a-text: #ffffff;
  --a-muted: #a1a1a1;
  --a-faint: #6e6e6e;
  --a-accent: #E30613;
  --a-accent-hi: #ff2a36;
  font-family: "CCM Jost", "Futura", "Segoe UI", system-ui, sans-serif;
}
.ccm-auth__panel { border-right-color: rgba(227, 6, 19, .45); }
.ccm-auth__title { font-family: "CCM Jost", "Futura", "Segoe UI", system-ui, sans-serif; font-weight: 600; letter-spacing: -.01em; }
.ccm-auth__input { background: #0c0c0e; }
.ccm-auth__input:-webkit-autofill,
.ccm-auth__input:-webkit-autofill:hover,
.ccm-auth__input:-webkit-autofill:focus { -webkit-box-shadow: 0 0 0 100px #0c0c0e inset, 0 0 0 3px rgba(227, 6, 19, .22); }
.ccm-auth__input:focus { background: #111113; box-shadow: 0 0 0 3px rgba(227, 6, 19, .22), 0 0 20px -4px rgba(227, 6, 19, .6); }
.ccm-auth__input:-webkit-autofill:focus { -webkit-box-shadow: 0 0 0 100px #111113 inset, 0 0 0 3px rgba(227, 6, 19, .22), 0 0 20px -4px rgba(227, 6, 19, .6); }
.ccm-auth__submit { background: #E30613; box-shadow: 0 10px 26px -12px rgba(227, 6, 19, .95); }
.ccm-auth__submit:hover { background: #ff1a27; box-shadow: 0 10px 30px -10px rgba(227, 6, 19, 1), 0 0 22px -2px rgba(255, 42, 54, .5); }
.ccm-auth__error { border-color: rgba(227, 6, 19, .5); background: rgba(227, 6, 19, .1); }
/* drei Stationen (Im Dienst · Im Tuning · Pause) — „Bereit“ gibt es in 3.0 nicht mehr */
.ccm-auth__figures { grid-template-columns: repeat(3, minmax(0, 1fr)); }

/* ---------- Linke Spalte: Graffiti wie im Intranet, ganz leise unter der Zeichnung ---------- */
.ccm-auth__graffiti {
  position: absolute; inset: 0; background: center / cover no-repeat; opacity: .16;
  filter: saturate(.9) brightness(.7) contrast(1.15);
  -webkit-mask-image: radial-gradient(120% 90% at 30% 45%, #000 25%, rgba(0, 0, 0, .5) 60%, transparent 88%);
  mask-image: radial-gradient(120% 90% at 30% 45%, #000 25%, rgba(0, 0, 0, .5) 60%, transparent 88%);
}
.ccm-auth__grid { opacity: .32; }

/* ---------- Schriftzug statt Logo-GIF ---------- */
.ccm-auth__marke { margin: 0 0 .9rem; color: #fff; font-family: "CCM Serif", "Cormorant Garamond", Georgia, serif; font-weight: 300; font-size: clamp(2rem, 3.2vw, 2.9rem); line-height: 1.02; letter-spacing: -.005em; }
.ccm-auth__marke em { display: block; font-style: italic; color: #ff5a63; }
.ccm-auth__marke--mobil { display: none; font-size: 1.7rem; margin-bottom: 1.6rem; }
.ccm-auth__marke--mobil em { display: inline; }
@media (max-width: 61.99rem) { .ccm-auth__marke--mobil { display: block; } }

/* ---------- Kopf: Begrüßung nach Tageszeit ---------- */
.ccm-auth__gruss {
  display: inline-flex; align-items: center; gap: .5rem; margin: 0 0 .55rem;
  color: #ff5a63; font-size: .72rem; font-weight: 600; letter-spacing: .22em; text-transform: uppercase;
}
.ccm-auth__gruss::before { content: ""; width: .4rem; height: .4rem; border-radius: 50%; background: #E30613; box-shadow: 0 0 10px rgba(227, 6, 19, .9); }

/* ---------- Felder mit Symbol ---------- */
.ccm-auth__input-wrap--ico > .ccm-auth__ico { position: absolute; left: .95rem; top: 50%; transform: translateY(-50%); color: var(--a-faint); pointer-events: none; transition: color .15s ease; }
.ccm-auth__input-wrap--ico .ccm-auth__input { padding-left: 2.75rem; }
.ccm-auth__input-wrap--ico:focus-within > .ccm-auth__ico { color: #ff5a63; }
.ccm-auth__input-wrap .ccm-auth__input { padding-right: 3.2rem; }
.ccm-auth__reveal--auge { display: grid; place-items: center; width: 2.4rem; min-height: 2.4rem; padding: 0; }
.ccm-auth__reveal--auge .ccm-auth__ico--auf, .ccm-auth__reveal--auge[aria-pressed="true"] .ccm-auth__ico--zu { display: none; }
.ccm-auth__reveal--auge[aria-pressed="true"] .ccm-auth__ico--auf { display: block; }
.ccm-auth__caps { display: flex; align-items: center; gap: .4rem; margin: .5rem 0 0; color: #F5B544; font-size: .78rem; font-weight: 600; }
.ccm-auth__caps[hidden] { display: none; }
.ccm-auth__caps .ccm-auth__ico { width: 15px; height: 15px; }

/* ---------- Angemeldet bleiben: Schalter statt Häkchen ---------- */
.ccm-auth__remember-box { width: 2.3rem; height: 1.3rem; border-radius: 999px; background: #1a1a1d; }
.ccm-auth__remember-box::after {
  left: .17rem; top: 50%; width: .9rem; height: .9rem; border: 0; border-radius: 50%; background: #8a8a8a;
  opacity: 1; transform: translateY(-50%); transition: transform .2s cubic-bezier(.2, .8, .2, 1), background .15s ease;
}
.ccm-auth__remember input:checked + .ccm-auth__remember-box::after { opacity: 1; background: #fff; transform: translate(1rem, -50%); }

/* ---------- Anmelden: Pfeil, Ladekreis ---------- */
.ccm-auth__submit { display: flex; align-items: center; justify-content: center; gap: .55rem; }
.ccm-auth__pfeil { transition: transform .2s ease; }
.ccm-auth__submit:hover .ccm-auth__pfeil { transform: translateX(4px); }
.ccm-auth__submit.is-laedt .ccm-auth__pfeil { display: none; }
.ccm-auth__submit.is-laedt::after { content: ""; width: 1rem; height: 1rem; border: 2px solid rgba(255, 255, 255, .35); border-top-color: #fff; border-radius: 50%; animation: ccmAuthDreh .7s linear infinite; }
@keyframes ccmAuthDreh { to { transform: rotate(360deg); } }

/* ---------- Fehler: einmal kurz schütteln ---------- */
.ccm-auth__form-inner.is-fehler { animation: ccmAuthWackeln .45s ease .2s; }
@keyframes ccmAuthWackeln { 20%, 60% { transform: translateX(-7px); } 40%, 80% { transform: translateX(7px); } }

/* ---------- Handy: kleiner Werkstattstatus unter der Überschrift (die linke Spalte ist dort aus) ---------- */
.ccm-auth__chip { display: inline-flex; align-items: center; gap: .5rem; margin: -.9rem 0 1.4rem; padding: .4rem .75rem; border: 1px solid var(--a-line); border-radius: 999px; background: rgba(255, 255, 255, .03); color: var(--a-muted); font-size: .78rem; }
.ccm-auth__chip b { color: var(--a-text); font-weight: 600; }
.ccm-auth__chip-dot { width: .5rem; height: .5rem; border-radius: 50%; background: #6e6e6e; }
.ccm-auth__chip.is-open .ccm-auth__chip-dot { background: #3ecf8e; box-shadow: 0 0 8px rgba(62, 207, 142, .8); }
@media (min-width: 62rem) { .ccm-auth__chip { display: none; } }

/* ---------- Sanftes Hereinkommen (nach dem Intro) ---------- */
.ccm-auth__form-inner > * { animation: ccmAuthRein .6s cubic-bezier(.2, .8, .2, 1) both; }
.ccm-auth__form-inner > *:nth-child(2) { animation-delay: .05s; } .ccm-auth__form-inner > *:nth-child(3) { animation-delay: .1s; }
.ccm-auth__form-inner > *:nth-child(4) { animation-delay: .15s; } .ccm-auth__form-inner > *:nth-child(5) { animation-delay: .2s; }
.ccm-auth__panel-inner { animation: ccmAuthRein .8s cubic-bezier(.2, .8, .2, 1) .1s both; }
.ccm-auth-intro-an .ccm-auth__form-inner > *, .ccm-auth-intro-an .ccm-auth__panel-inner { animation-delay: 1.5s; }
@keyframes ccmAuthRein { from { opacity: 0; transform: translateY(12px); } }
@media (prefers-reduced-motion: reduce) {
  .ccm-auth__form-inner > *, .ccm-auth__panel-inner, .ccm-auth__form-inner.is-fehler { animation: none; }
}

/* Intro wie im Kundenbereich: einmal pro Browser-Sitzung, nur mit Bewegung (Klasse setzt das Skript in login.php) */
.ccm-auth-intro { display: none; }
.ccm-auth-intro-an .ccm-auth-intro {
  position: fixed; inset: 0; z-index: 3000; display: grid; place-items: center; align-content: center; gap: 1.2rem;
  background: #050505; pointer-events: none; animation: ccmAuthVorhang .85s cubic-bezier(.77, 0, .18, 1) 1.2s both;
}
.ccm-auth-intro span {
  padding: 0 1rem; color: #fff; white-space: nowrap; text-align: center; line-height: 1;
  font-family: "CCM Serif", "Cormorant Garamond", Georgia, serif; font-weight: 300; font-size: clamp(1.4rem, 7vw, 5rem);
  animation: ccmAuthSchrift 1.05s cubic-bezier(.16, 1, .3, 1) both;
}
.ccm-auth-intro i {
  display: block; width: min(86vw, 58rem); height: 1px; background: #E30613; box-shadow: 0 0 18px 2px rgba(227, 6, 19, .6);
  transform-origin: left center; animation: ccmAuthLinie .95s cubic-bezier(.77, 0, .18, 1) .15s both;
}
@keyframes ccmAuthSchrift { from { opacity: 0; letter-spacing: .32em; filter: blur(10px); } }
@keyframes ccmAuthLinie { from { transform: scaleX(0); } }
@keyframes ccmAuthVorhang { to { clip-path: inset(0 0 100% 0); visibility: hidden; } }
