:root {
  font-family:
    Inter,
    system-ui,
    -apple-system,
    BlinkMacSystemFont,
    "Segoe UI",
    sans-serif;
  color: #4877bc;
  background: #eef3f7;
  line-height: 1.5;
  --fkb-blau: #4877bc;
  --fkb-blau-dunkel: #3568b3;
  --fkb-hell: #eef3f7;
  --fkb-weiss: #ffffff;
  --fkb-orange: #c85b1d;
}

* {
  box-sizing: border-box;
}

html {
  overflow-x: hidden;
}

body {
  margin: 0;
  min-width: 320px;
  overflow-wrap: anywhere;
  background: #eef3f7;
}

.anleger {
  width: min(100% - 1rem, 48rem);
  margin-inline: auto;
  padding-block: 1rem 2rem;
  display: grid;
  gap: 1rem;
}

.modul {
  position: relative;
}

.karte {
  padding: 1.4rem;
  border-radius: 1.35rem;
  background: #fff;
  box-shadow: 0 0.4rem 1.5rem rgb(23 32 51 / 8%);
}

/* Kopf- und Modul-Icons präsenter darstellen */
.icon {
  width: 3rem;
  height: 3rem;
  margin-bottom: 0.8rem;
}

.label {
  margin: 0;
  color: #5b6475;
  font-size: 0.95rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.kalender-link {
  display: inline-flex;
  width: auto;
  align-items: center;
  justify-content: center;
  gap: 0.65rem;

  margin-top: 1.5rem;
  padding: 0.8rem 1.2rem;

  border: 0.12rem solid #b54b1f;
  border-radius: 999px;

  color: #b54b1f;
  background: #fff;

  font-size: 1rem;
  font-weight: 700;
  line-height: 1.2;
  text-decoration: none;

  transition:
    transform 160ms ease,
    color 160ms ease,
    background-color 160ms ease,
    box-shadow 160ms ease;
}

.kalender-link:hover,
.kalender-link:focus-visible {
  color: #fff;
  background: #b54b1f;
  transform: translateY(-0.12rem);
  box-shadow: 0 0.5rem 1.2rem rgb(181 75 31 / 20%);
}

.kalender-link i {
  color: currentColor;
  font-size: 1.15rem;
}

.kalender-link__icon {
  display: inline-flex;
  width: 1.35rem;
  height: 1.35rem;
  flex: 0 0 auto;
  align-items: center;
  justify-content: center;
  transition: transform 160ms ease;
}

.kalender-link__icon svg {
  display: block;
  width: 100%;
  height: 100%;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.kalender-link:hover .kalender-link__icon {
  transform: scale(1.12) rotate(-4deg);
}

@media (min-width: 42rem) {
  .anleger {
    width: min(100% - 1.5rem, 50rem);
    padding-block: 2rem 3rem;
  }

  .karte {
    padding: 1.8rem;
  }
}

@media (max-width: 23rem) {
  .anleger {
    width: min(100% - 0.75rem, 48rem);
    gap: 0.75rem;
    padding-block: 0.5rem 1rem;
  }

  .karte {
    border-radius: 1rem;
  }
}

/* =========================================
   KOPF – LOGO
   ========================================= */

.kopf {
  position: relative;
}

/* Kopfbereich als stabile Flexbox */
.modul-kopf {
  display: flex;
  align-items: center;
  gap: 2.5rem;

  padding-right: 3rem;
}

/* Uhr-Icon */
.modul-kopf .icon {
  display: flex;
  align-items: center;
  justify-content: center;

  flex: 0 0 auto;

  width: 72px;
  height: 72px;

  margin-top: -4px;
}

.modul-kopf .icon svg {
  width: 100%;
  height: 100%;
}

.modul-kopf__text {
  flex: 1;
  min-width: 0;

  display: flex;
  flex-direction: column;
  justify-content: center;
}

/* Titel: groß und gezielt zweizeilig */
.modul-kopf h1 {
  margin: 0;

  font-size: clamp(3rem, 5vw, 5rem);
  line-height: 0.95;

  letter-spacing: -0.02em;
}

.modul-kopf .einleitung {
  margin-top: 0.75rem;

  font-size: clamp(1rem, 1.4vw, 1.45rem);

  color: #5f78b9;
}

/* Logo sitzt sauber rechts */
.kopf__logo {
  flex: 0 0 auto;
  margin-left: auto;

  width: clamp(85px, 10vw, 155px);
  max-height: 150px;
  height: auto;

  display: block;
  object-fit: contain;

  background: none;
  border: 0;
  box-shadow: none;
}

.kopf__inhalt {
  min-width: 0;
}

.modul-kopf .icon--champagner {
  display: flex;
  align-items: center;
  justify-content: center;

  flex: 0 0 auto;

  width: 72px;
  height: 72px;

  color: #5f7fc8;
}

.modul-kopf .icon--champagner i {
  font-size: 64px;
  line-height: 1;
}

.modul-kopf h1 {
  font-size: clamp(2.5rem, 6vw, 4rem);
  white-space: normal;
}

/* =========================================
   TABLET
   ========================================= */

@media (max-width: 800px) {
  .modul-kopf {
    gap: 1.5rem;
    padding: 1.5rem;
  }

  .modul-kopf .icon {
    width: 60px;
    height: 60px;
  }

  .modul-kopf__text {
    flex: 1 1 auto;
    min-width: 0;

    display: flex;
    flex-direction: column;
    justify-content: center;
  }

  .modul-kopf h1 {
    margin: 0;

    width: auto;
    max-width: none;

    font-size: clamp(3rem, 4.6vw, 4.8rem);
    line-height: 0.98;
    letter-spacing: -0.025em;

    white-space: nowrap;
    overflow-wrap: normal;
    word-break: normal;
  }

  .modul-kopf h1 {
    font-size: clamp(2.5rem, 6vw, 4rem);
    white-space: normal;
  }

  .kopf__logo {
    width: clamp(90px, 15vw, 125px);
    max-height: 120px;
  }

  .modul-kopf .icon--champagner {
    width: 60px;
    height: 60px;
  }

  .modul-kopf .icon--champagner i {
    font-size: 52px;
  }
}

.panel-rueckweg {
  position: sticky;
  top: 0;
  left: max(0.75rem, env(safe-area-inset-left));
  z-index: 9999;

  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;

  min-height: 3.25rem;
  padding: 0 0.8rem;

  margin:
    max(0.75rem, env(safe-area-inset-top))
    0
    0.75rem
    max(0.75rem, env(safe-area-inset-left));

  border: 0;
  border-radius: 999px;

  background: var(--fkb-blau);
  color: var(--fkb-weiss);

  font-family: inherit;
  font-size: 1.4rem;
  font-weight: 700;
  line-height: 1;

  cursor: pointer;
  box-shadow: 0 0.25rem 0.8rem rgba(20, 36, 56, 0.18);

  -webkit-appearance: none;
  appearance: none;

  transition:
    background-color 0.2s ease,
    transform 0.15s ease;
}

.panel-rueckweg > span {
  display: block;
  line-height: 1;
  transform: translateY(-0.07em);
}

.panel-rueckweg:hover {
  background: var(--fkb-blau-dunkel);
}

.panel-rueckweg:active {
  transform: scale(0.98);
}

.panel-rueckweg:focus-visible {
  outline: 0.2rem solid var(--fkb-weiss);
  outline-offset: 0.2rem;
}
/* =========================================
   SMARTPHONE
   ========================================= */

@media (max-width: 560px) {
  .modul-kopf {
    gap: 0.9rem;
    padding: 1.25rem;
  }

  .modul-kopf .icon {
    width: 46px;
    height: 46px;
    margin-top: -2px;
  }

  .modul-kopf h1 {
    max-width: 8.5ch;

    font-size: clamp(2.1rem, 8.5vw, 3.3rem);
    line-height: 0.98;
  }

  .kopf__logo {
    width: clamp(68px, 19vw, 86px);
    max-height: 86px;
  }

  .modul-kopf .icon--champagner {
    display: flex;
    align-items: center;
    justify-content: center;

    flex: 0 0 auto;

    width: 72px;
    height: 72px;

    color: #5f7fc8;
  }

  .modul-kopf .icon--champagner i {
    display: block;
    font-size: 64px;
    line-height: 1;
  }
}

/* =========================================
   SEHR KLEINE SMARTPHONES
   ========================================= */

@media (max-width: 390px) {
  .modul-kopf {
    gap: 0.65rem;
    padding: 1rem;
  }

  .modul-kopf .icon {
    width: 40px;
    height: 40px;
  }

  .modul-kopf h1 {
    max-width: 8.5ch;
    font-size: clamp(1.85rem, 8.8vw, 2.6rem);
  }

  .kopf__logo {
    width: 64px;
    max-height: 72px;
  }
}
