/*
  MEDLEARNING – CSS-NAVIGATION: mobilkarussell.css

  mk01 – Gemeinsame seitliche Navigation und Wechselansichten

  Fachgebiete und Informationskarten wechseln bei höchstens 880 px,
  KI-Beispielfragen bei höchstens 620 px. Die Grenzwerte entsprechen
  den jeweiligen Layoutumbrüchen in startseite.css. Ohne JavaScript
  bleiben sämtliche Inhalte einschließlich Links sichtbar.
*/

/* ============================================================
   mk01 – Gemeinsame seitliche Navigation und Wechselansichten
   ============================================================ */

.mk01-steuerung {
  display: none;
}

/* Die Steuerung wird nur bei aktivem Wechselmodus eingeblendet. */
.mk01-karussell[data-mk01-mobil="true"] {
  --mk01-pfeilgroesse: 32px;
  --mk01-seitenraum: 38px;
  --mk01-punktraum: 32px;
  position: relative;
  padding-inline: var(--mk01-seitenraum);
  padding-bottom: var(--mk01-punktraum);
}

.mk01-karussell[data-mk01-mobil="true"] .mk01-steuerung {
  display: block;
  position: absolute;
  inset: 0;
  z-index: 3;
  pointer-events: none;
}

.mk01-pfeil {
  position: absolute;
  top: calc((100% - var(--mk01-punktraum)) / 2);
  display: grid;
  place-items: center;
  width: var(--mk01-pfeilgroesse);
  height: var(--mk01-pfeilgroesse);
  padding: 0;
  border: 1px solid rgba(36, 48, 94, .10);
  border-radius: 50%;
  background: rgba(8, 38, 92, .13);
  color: #24305e;
  transform: translateY(-50%);
  transition: background-color 180ms ease, color 180ms ease, border-color 180ms ease;
  pointer-events: auto;
}

.mk01-pfeil-zurueck { left: 0; }
.mk01-pfeil-weiter { right: 0; }

@media (hover: hover) and (pointer: fine) {
  .mk01-pfeil:not(:disabled):hover {
    background: var(--bs01-blau);
    border-color: var(--bs01-blau);
    color: #fff;
  }
}

.mk01-pfeil:not(:disabled):focus-visible {
  background: var(--bs01-blau);
  border-color: var(--bs01-blau);
  color: #fff;
}

.mk01-pfeil:disabled {
  opacity: .32;
  cursor: default;
}

.mk01-pfeil .ml-symbol {
  width: 20px;
  height: 20px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2.3;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.mk01-punkte {
  position: absolute;
  bottom: 0;
  left: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  transform: translateX(-50%);
  pointer-events: auto;
}

.mk01-punkt {
  display: grid;
  place-items: center;
  width: 25px;
  height: 28px;
  padding: 0;
  border: 0;
  background: transparent;
}

.mk01-punkt::before {
  content: "";
  width: 7px;
  height: 7px;
  border-radius: 9px;
  background: #b7c6df;
  transition: width 180ms ease, background-color 180ms ease;
}

.mk01-punkt[aria-current="true"]::before {
  width: 19px;
  background: #24305e;
}

.mk01-karussell[data-mk01-mobil="true"] .mk01-spur {
  touch-action: pan-y;
}

.mk01-karussell[data-mk01-mobil="true"] .mk01-spur > .mk01-seite:not(.mk01-sichtbar) {
  display: none !important;
}

.mk01-karussell[data-mk01-mobil="true"] .mk01-spur > .mk01-sichtbar {
  animation: mk01-einblenden 260ms ease both;
}

@keyframes mk01-einblenden {
  from { opacity: .5; transform: translateX(4px); }
  to { opacity: 1; transform: translateX(0); }
}

/* Im Wechselmodus bleiben die Karten untereinander nicht gestapelt. */
.mk01-karussell[data-mk01-mobil="true"] .ix05-informationsraster.mk01-spur {
  display: block;
}

.mk01-karussell[data-mk01-mobil="true"] .ix04-beispielfragen.mk01-spur > .mk01-seite {
  min-height: 88px;
}

@media (max-width: 620px) {
  .mk01-karussell[data-mk01-mobil="true"] {
    --mk01-pfeilgroesse: 29px;
    --mk01-seitenraum: 35px;
  }
}

@media (max-width: 360px) {
  .mk01-karussell[data-mk01-mobil="true"] {
    --mk01-pfeilgroesse: 27px;
    --mk01-seitenraum: 34px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .mk01-karussell[data-mk01-mobil="true"] .mk01-spur > .mk01-sichtbar {
    animation: none !important;
  }
}
