html {
  font-size: 14px;
}

@media (min-width: 768px) {
  html {
    font-size: 16px;
  }
}

.btn:focus, .btn:active:focus, .btn-link.nav-link:focus, .form-control:focus, .form-check-input:focus {
  box-shadow: 0 0 0 0.1rem white, 0 0 0 0.25rem #258cfb;
}

html {
  position: relative;
  min-height: 100%;
}

body {
  margin-bottom: 60px;
  background: #f5f7f8;
  color: #17242b;
}

.form-floating > .form-control-plaintext::placeholder, .form-floating > .form-control::placeholder {
  color: var(--bs-secondary-color);
  text-align: end;
}

.form-floating > .form-control-plaintext:focus::placeholder, .form-floating > .form-control:focus::placeholder {
  text-align: start;
}

.hero {
  max-width: 54rem;
  padding: 4rem 0 2rem;
}

.hero h1 {
  color: #155d64;
  font-size: clamp(2.5rem, 8vw, 5rem);
  font-weight: 700;
  letter-spacing: -0.04em;
}

.eyebrow {
  color: #39737a;
  font-size: 0.85rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.status-card {
  max-width: 54rem;
  padding: 1.5rem;
  background: #fff;
  border: 1px solid #d8e2e4;
  border-radius: 0.75rem;
  box-shadow: 0 0.5rem 1.5rem rgb(23 36 43 / 6%);
}

.status-card h2 {
  font-size: 1.25rem;
}

.flow-card {
  max-width: 46rem;
  margin: 3rem auto;
  padding: clamp(1.5rem, 5vw, 3rem);
  background: #fff;
  border: 1px solid #d8e2e4;
  border-radius: 0.75rem;
  box-shadow: 0 0.5rem 1.5rem rgb(23 36 43 / 6%);
}

.flow-card h1 {
  color: #155d64;
  margin-bottom: 1.25rem;
}

.patient-form {
  margin-top: 2rem;
}

.form-actions {
  display: flex;
  justify-content: flex-end;
  margin-top: 2rem;
  padding-top: 1.5rem;
  border-top: 1px solid #d8e2e4;
}

.symptom-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(12rem, 1fr));
  gap: 0.25rem 1rem;
}

.pain-details[hidden] {
  display: none;
}

.form-actions.has-back {
  justify-content: space-between;
  align-items: center;
}

.required-badge,
.required::after {
  display: inline-block;
  margin-left: 0.5rem;
  padding: 0.1rem 0.5rem;
  color: #fff;
  background: #b02a37;
  border-radius: 0.25rem;
  font-size: 0.75rem;
  font-weight: 700;
  line-height: 1.4;
  vertical-align: middle;
}

.required::after {
  content: attr(data-required-label);
}

.required-note {
  padding: 0.75rem 1rem;
  background: #fbeeee;
  border-left: 0.25rem solid #b02a37;
  border-radius: 0.25rem;
}

.date-picker {
  position: relative;
}

/* Nativer Kalender nur als Popup-Quelle; sichtbar bleibt das Textfeld im Format TT.MM.JJJJ. */
.date-picker-native {
  position: absolute;
  right: 0;
  bottom: 0;
  width: 1px;
  height: 1px;
  padding: 0;
  border: 0;
  opacity: 0;
  pointer-events: none;
}

.list-row {
  margin-bottom: 0.5rem;
}

.list-row[hidden] {
  display: none;
}

/* ---- Ordinationsansicht der Anamnese ---- */
.case-header {
  margin-bottom: 1.5rem;
  padding: 1.25rem 1.5rem;
  background: #fff;
  border: 1px solid #d8e2e4;
  border-radius: 0.75rem;
  box-shadow: 0 0.5rem 1.5rem rgb(23 36 43 / 6%);
}

.case-header h1 {
  margin-bottom: 0.75rem;
  color: #155d64;
  font-size: 1.75rem;
}

.case-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 1.5rem;
  align-items: start;
}

@media (min-width: 992px) {
  .case-layout {
    grid-template-columns: 18rem minmax(0, 1fr);
  }
}

.case-nav {
  padding: 1rem;
  background: #fff;
  border: 1px solid #d8e2e4;
  border-radius: 0.75rem;
}

@media (min-width: 992px) {
  .case-nav {
    position: sticky;
    top: 1rem;
    max-height: calc(100vh - 2rem);
    overflow-y: auto;
  }
}

.case-nav-title {
  margin-bottom: 0.5rem;
  color: #39737a;
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.case-nav-list {
  margin: 0;
  padding: 0;
  list-style: none;
}

.case-nav-list a {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  padding: 0.35rem 0.5rem;
  color: #17242b;
  border-radius: 0.4rem;
  font-size: 0.9rem;
  text-decoration: none;
}

.case-nav-list a:hover,
.case-nav-list a.is-current {
  background: #e8f1f2;
}

.case-nav-list a.is-current {
  font-weight: 600;
}

.case-nav-number,
.case-section-number {
  display: inline-flex;
  flex: 0 0 auto;
  align-items: center;
  justify-content: center;
  color: #fff;
  background: #155d64;
  border-radius: 50%;
  font-weight: 700;
}

.case-nav-number {
  width: 1.5rem;
  height: 1.5rem;
  font-size: 0.75rem;
}

.case-nav-label {
  flex: 1 1 auto;
  line-height: 1.25;
}

.case-nav-dot {
  flex: 0 0 auto;
  width: 0.6rem;
  height: 0.6rem;
  background: #c5d0d3;
  border-radius: 50%;
}

.case-nav-dot[data-state="filled"] {
  background: #2e8b57;
}

.case-nav-dot[data-state="error"] {
  background: #b02a37;
}

.case-nav-tools {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-top: 1rem;
  padding-top: 1rem;
  border-top: 1px solid #d8e2e4;
}

.case-section {
  margin-bottom: 1rem;
  background: #fff;
  border: 1px solid #d8e2e4;
  border-radius: 0.75rem;
  box-shadow: 0 0.25rem 1rem rgb(23 36 43 / 5%);
  scroll-margin-top: 1rem;
}

.case-section-staff {
  border-left: 0.35rem solid #c98a1b;
}

.case-section-header {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  padding: 1rem 1.25rem;
  cursor: pointer;
  list-style: none;
  user-select: none;
}

.case-section-header::-webkit-details-marker {
  display: none;
}

.case-section-header::after {
  content: "";
  flex: 0 0 auto;
  width: 0.6rem;
  height: 0.6rem;
  margin-left: 0.25rem;
  border-right: 2px solid #39737a;
  border-bottom: 2px solid #39737a;
  transform: rotate(45deg);
  transition: transform 0.15s ease;
}

.case-section[open] > .case-section-header::after {
  transform: rotate(-135deg);
}

.case-section[open] > .case-section-header {
  border-bottom: 1px solid #d8e2e4;
  background: #f3f8f8;
  border-radius: 0.75rem 0.75rem 0 0;
}

.case-section-number {
  width: 2rem;
  height: 2rem;
  font-size: 0.95rem;
}

.case-section-title {
  flex: 1 1 auto;
  color: #155d64;
  font-size: 1.1rem;
  font-weight: 600;
}

.case-section-status {
  flex: 0 0 auto;
  padding: 0.15rem 0.6rem;
  color: #55666d;
  background: #eef2f3;
  border-radius: 999px;
  font-size: 0.75rem;
  font-weight: 600;
  white-space: nowrap;
}

.case-section-status[data-state="filled"] {
  color: #1d6b40;
  background: #e3f4ea;
}

.case-section-status[data-state="error"] {
  color: #fff;
  background: #b02a37;
}

.case-section-body {
  padding: 1.25rem;
}

.case-save-bar {
  position: sticky;
  bottom: 0;
  z-index: 5;
  display: flex;
  justify-content: flex-end;
  margin: 0 -0.5rem 1rem;
  padding: 0.75rem 1rem;
  background: rgb(255 255 255 / 95%);
  border: 1px solid #d8e2e4;
  border-radius: 0.75rem;
  box-shadow: 0 -0.25rem 1rem rgb(23 36 43 / 8%);
}

.case-save-bar {
  flex-wrap: wrap;
  align-items: center;
  gap: 0.5rem 1rem;
}

.case-save-hint {
  flex: 1 1 16rem;
  margin: 0;
  padding: 0.4rem 0.75rem;
  color: #6b4a08;
  background: #fdf3dc;
  border-left: 0.25rem solid #c98a1b;
  border-radius: 0.25rem;
  font-size: 0.9rem;
}

.case-save-note {
  order: -1;
}

.case-save-hint {
  order: -2;
}

.case-save-hint a {
  color: inherit;
  font-weight: 600;
}

/* ---- MediMe Markenauftritt ---- */
:root {
  --medime-navy: #155b9b;
  --medime-blue: #168ee0;
  --medime-cyan: #2fc9e8;
  --medime-teal: #12b79b;
  --medime-green: #53d58e;
  --medime-ink: #14324a;
  --medime-muted: #607889;
  --medime-line: #d9e9f2;
  --medime-surface: #ffffff;
  --medime-soft-blue: #edf8fe;
  --medime-soft-green: #edfbf5;
  --medime-gradient: linear-gradient(125deg, var(--medime-blue), var(--medime-teal));
  --medime-shadow: 0 1.25rem 3.5rem rgb(21 91 155 / 10%);
  --bs-primary: #177fc7;
  --bs-primary-rgb: 23, 127, 199;
  --bs-link-color: #156dae;
  --bs-link-hover-color: #0f927d;
}

html {
  scroll-behavior: smooth;
}

body {
  min-height: 100vh;
  margin-bottom: 5.5rem;
  color: var(--medime-ink);
  background:
    radial-gradient(circle at 2% 12%, rgb(47 201 232 / 12%), transparent 24rem),
    radial-gradient(circle at 98% 86%, rgb(83 213 142 / 10%), transparent 26rem),
    #f7fbfd;
  font-family: Inter, Avenir, "Segoe UI", system-ui, -apple-system, sans-serif;
  line-height: 1.65;
}

a {
  color: var(--bs-link-color);
  text-underline-offset: 0.18em;
}

a:hover {
  color: var(--bs-link-hover-color);
}

.site-navbar {
  min-height: 4.75rem;
  padding: 0.5rem 0;
  background: rgb(255 255 255 / 88%);
  border-bottom: 1px solid rgb(217 233 242 / 85%);
  box-shadow: 0 0.5rem 2rem rgb(21 91 155 / 6%);
  backdrop-filter: blur(14px);
}

/* Harte Größenbegrenzung, damit das hochauflösende Logo nie die Navigation aufzieht. */
.site-navbar .navbar-brand {
  display: flex;
  flex: 0 0 7.5rem;
  align-items: center;
  width: 7.5rem;
  max-width: 7.5rem;
  height: 2.5rem;
  margin-right: 1.5rem;
  padding: 0;
  overflow: hidden;
}

.site-navbar .brand-logo {
  display: block;
  flex: none;
  width: 10rem;
  max-width: none;
  height: auto;
  margin-left: -1.25rem;
}

.site-navbar .nav-link {
  position: relative;
  margin: 0 0.15rem;
  padding: 0.55rem 0.85rem !important;
  color: #37566c;
  border-radius: 999px;
  font-size: 0.94rem;
  font-weight: 600;
  text-decoration: none;
  transition: color 160ms ease, background-color 160ms ease;
}

.site-navbar .nav-link:hover,
.site-navbar .nav-link:focus-visible {
  color: var(--medime-navy);
  background: var(--medime-soft-blue);
}

.site-navbar .navbar-text {
  color: var(--medime-muted);
  font-size: 0.88rem;
}

.navbar-toggler {
  border-color: var(--medime-line);
  border-radius: 0.8rem;
}

.site-shell {
  padding-top: clamp(2rem, 5vw, 4.5rem);
  padding-bottom: 4rem;
}

h1,
h2,
h3,
h4,
h5,
h6 {
  color: var(--medime-ink);
  font-weight: 720;
  letter-spacing: -0.025em;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  margin-bottom: 1rem;
  color: var(--medime-teal);
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.14em;
}

.eyebrow::before {
  width: 1.75rem;
  height: 0.18rem;
  content: "";
  background: var(--medime-gradient);
  border-radius: 999px;
}

.hero {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(18rem, 0.85fr);
  gap: clamp(2rem, 6vw, 6rem);
  align-items: center;
  max-width: none;
  min-height: 30rem;
  padding: clamp(2rem, 7vw, 6rem) 0 clamp(3rem, 7vw, 5rem);
}

.hero h1 {
  margin-bottom: 1.5rem;
  color: var(--medime-navy);
  font-size: clamp(2.75rem, 6vw, 5.5rem);
  font-weight: 780;
  letter-spacing: -0.06em;
  line-height: 0.98;
}

.hero h1 span {
  color: transparent;
  background: var(--medime-gradient);
  background-clip: text;
  -webkit-background-clip: text;
}

.hero .lead {
  max-width: 38rem;
  margin-bottom: 0;
  color: var(--medime-muted);
  font-size: clamp(1.05rem, 2vw, 1.3rem);
}

.hero-visual {
  position: relative;
  display: grid;
  place-items: center;
  aspect-ratio: 1;
  isolation: isolate;
}

.hero-visual::before {
  position: absolute;
  z-index: -2;
  width: 76%;
  height: 76%;
  content: "";
  background: linear-gradient(145deg, rgb(47 201 232 / 18%), rgb(83 213 142 / 19%));
  border-radius: 42% 58% 55% 45% / 48% 40% 60% 52%;
  filter: blur(2px);
  animation: medime-float 8s ease-in-out infinite;
}

.hero-visual img {
  width: min(100%, 28rem);
  filter: drop-shadow(0 1.5rem 2rem rgb(21 91 155 / 16%));
  mix-blend-mode: multiply;
}

.hero-orbit {
  position: absolute;
  z-index: -1;
  border: 1px solid rgb(22 142 224 / 18%);
  border-radius: 50%;
}

.hero-orbit::after {
  position: absolute;
  width: 0.7rem;
  height: 0.7rem;
  content: "";
  background: var(--medime-green);
  border-radius: 50%;
  box-shadow: 0 0 0 0.4rem rgb(83 213 142 / 14%);
}

.hero-orbit-one {
  width: 88%;
  height: 88%;
  transform: rotate(16deg);
}

.hero-orbit-one::after {
  top: 18%;
  right: 5%;
}

.hero-orbit-two {
  width: 63%;
  height: 63%;
  transform: rotate(-24deg);
}

.hero-orbit-two::after {
  bottom: 5%;
  left: 16%;
  background: var(--medime-blue);
  box-shadow: 0 0 0 0.4rem rgb(22 142 224 / 14%);
}

@keyframes medime-float {
  0%, 100% { transform: translateY(0) rotate(0); }
  50% { transform: translateY(-0.75rem) rotate(3deg); }
}

.status-card,
.flow-card,
.case-header,
.case-nav,
.case-section {
  background: rgb(255 255 255 / 94%);
  border: 1px solid var(--medime-line);
  box-shadow: var(--medime-shadow);
}

.status-card {
  display: flex;
  gap: 1.25rem;
  align-items: flex-start;
  max-width: none;
  margin-bottom: 2rem;
  padding: clamp(1.5rem, 4vw, 2.25rem);
  border-radius: 1.5rem;
}

.status-card h2 {
  margin-bottom: 0.55rem;
  color: var(--medime-navy);
  font-size: clamp(1.25rem, 3vw, 1.6rem);
}

.status-card p:not(.eyebrow) {
  max-width: 54rem;
  color: var(--medime-muted);
}

.status-card-icon {
  display: inline-grid;
  flex: 0 0 auto;
  place-items: center;
  width: 3.25rem;
  height: 3.25rem;
  color: #fff;
  background: var(--medime-gradient);
  border-radius: 1rem;
  box-shadow: 0 0.75rem 1.5rem rgb(18 183 155 / 20%);
  font-size: 1.35rem;
  font-weight: 800;
}

.flow-card {
  max-width: 50rem;
  margin-top: 0;
  padding: clamp(1.5rem, 5vw, 3.25rem);
  border-radius: 1.5rem;
}

.flow-card h1,
.flow-card h2 {
  color: var(--medime-navy);
}

/* ---- Einstieg in die Patient:innen-Anamnese ---- */
.invitation-hero {
  position: relative;
  display: flex;
  align-items: center;
  min-height: min(43rem, calc(100vh - 10.5rem));
  margin: -1.5rem 0 0;
  padding: clamp(1.25rem, 5vw, 4rem);
  overflow: hidden;
  background:
    linear-gradient(90deg, rgb(242 249 248 / 98%) 0%, rgb(242 249 248 / 93%) 38%, rgb(242 249 248 / 24%) 68%),
    url("../images/anamnesis-welcome.png") center / cover no-repeat;
  border: 1px solid rgb(255 255 255 / 80%);
  border-radius: 2rem;
  box-shadow: 0 1.75rem 4rem rgb(21 91 155 / 15%);
  isolation: isolate;
}

.invitation-hero::after {
  position: absolute;
  inset: 0;
  z-index: -1;
  content: "";
  background: linear-gradient(180deg, transparent 65%, rgb(17 76 92 / 10%));
  pointer-events: none;
}

.invitation-card {
  width: min(100%, 39rem);
  padding: clamp(1.5rem, 4vw, 3rem);
  background: rgb(255 255 255 / 93%);
  border: 1px solid rgb(255 255 255 / 90%);
  border-radius: 1.5rem;
  box-shadow: 0 1.25rem 3rem rgb(20 50 74 / 16%);
  backdrop-filter: blur(14px);
}

.invitation-card h1 {
  margin-bottom: 1.15rem;
  color: var(--medime-navy);
  font-size: clamp(2.15rem, 5vw, 3.6rem);
  letter-spacing: -0.055em;
  line-height: 1.03;
}

.invitation-card h1 span {
  color: transparent;
  background: var(--medime-gradient);
  background-clip: text;
  -webkit-background-clip: text;
}

.invitation-lead {
  margin-bottom: 1.35rem;
  color: #49697b;
  font-size: 1.08rem;
  line-height: 1.7;
}

.invitation-trust {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin: 0 0 1.5rem;
  padding: 0;
  list-style: none;
}

.invitation-trust li {
  padding: 0.38rem 0.75rem;
  color: #236a62;
  background: var(--medime-soft-green);
  border: 1px solid #c8ecdf;
  border-radius: 999px;
  font-size: 0.8rem;
  font-weight: 700;
}

.invitation-security-note {
  display: flex;
  gap: 0.85rem;
  align-items: flex-start;
  margin-bottom: 1.5rem;
  padding: 1rem;
  color: #3e6071;
  background: rgb(237 248 254 / 78%);
  border: 1px solid #cbe7f3;
  border-radius: 1rem;
}

.invitation-security-note p {
  margin: 0;
  font-size: 0.9rem;
  line-height: 1.55;
}

.invitation-security-note strong {
  display: block;
  margin-bottom: 0.12rem;
  color: var(--medime-navy);
}

.invitation-lock {
  display: grid;
  flex: 0 0 auto;
  place-items: center;
  width: 2rem;
  height: 2rem;
  color: #fff;
  background: var(--medime-gradient);
  border-radius: 50%;
  font-weight: 800;
}

.invitation-action .btn {
  width: 100%;
  padding: 0.85rem 1.25rem;
}

.invitation-language {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(12rem, 1.2fr) auto;
  gap: 0.75rem;
  align-items: center;
  margin-bottom: 1rem;
}

.invitation-language label {
  color: var(--medime-navy);
  font-size: 0.9rem;
  font-weight: 700;
}

@media (max-width: 575.98px) {
  .invitation-language {
    grid-template-columns: 1fr auto;
  }

  .invitation-language label {
    grid-column: 1 / -1;
  }
}

.invitation-action .btn span {
  display: inline-block;
  margin-left: 0.5rem;
  transition: transform 140ms ease;
}

.invitation-action .btn:hover span {
  transform: translateX(0.2rem);
}

.invitation-emergency {
  margin: 1rem 0 0;
  color: #6c5c42;
  font-size: 0.79rem;
  line-height: 1.5;
  text-align: center;
}

.btn {
  padding: 0.62rem 1.1rem;
  border-radius: 0.75rem;
  font-weight: 700;
  transition: transform 140ms ease, box-shadow 140ms ease, background-color 140ms ease;
}

.btn:hover {
  transform: translateY(-1px);
}

.btn-primary {
  color: #fff;
  background: var(--medime-gradient);
  border-color: transparent;
  box-shadow: 0 0.6rem 1.25rem rgb(21 91 155 / 18%);
}

.btn-primary:hover,
.btn-primary:focus,
.btn-primary:active {
  color: #fff !important;
  background: linear-gradient(125deg, #116eb8, #0d9c85) !important;
  border-color: transparent !important;
  box-shadow: 0 0.8rem 1.5rem rgb(21 91 155 / 24%) !important;
}

.btn-outline-primary {
  color: var(--medime-navy);
  border-color: #83bddf;
}

.btn-outline-primary:hover {
  color: #fff;
  background: var(--medime-gradient);
  border-color: transparent;
}

.btn-outline-secondary {
  color: #4d687a;
  background: #fff;
  border-color: #c5d9e5;
}

.form-label {
  margin-bottom: 0.4rem;
  color: #274b63;
  font-size: 0.92rem;
  font-weight: 700;
}

.form-control,
.form-select {
  min-height: 2.85rem;
  color: var(--medime-ink);
  background-color: #fbfdfe;
  border-color: #cfe1eb;
  border-radius: 0.7rem;
}

textarea.form-control {
  min-height: auto;
}

.form-control:focus,
.form-select:focus,
.form-check-input:focus {
  border-color: var(--medime-blue);
  box-shadow: 0 0 0 0.24rem rgb(22 142 224 / 14%);
}

.form-check-input:checked {
  background-color: var(--medime-teal);
  border-color: var(--medime-teal);
}

.form-text,
.text-muted {
  color: var(--medime-muted) !important;
}

.progress {
  height: 0.65rem;
  background: #dfedf4;
  border-radius: 999px;
}

.progress-bar {
  background: var(--medime-gradient);
  border-radius: 999px;
}

.alert {
  border-width: 1px;
  border-radius: 0.9rem;
}

.alert-info {
  color: #175372;
  background: var(--medime-soft-blue);
  border-color: #c4e7f7;
}

.alert-success {
  color: #156651;
  background: var(--medime-soft-green);
  border-color: #bfead8;
}

.alert-warning {
  color: #72581b;
  background: #fff9e8;
  border-color: #f0dfac;
}

.required-note {
  color: #6e3c46;
  background: #fff5f6;
  border-color: #d56478;
  border-radius: 0.6rem;
}

.required-badge,
.required::after {
  background: #c7435a;
  border-radius: 999px;
}

.table-responsive {
  background: #fff;
  border: 1px solid var(--medime-line);
  border-radius: 1rem;
  box-shadow: 0 0.75rem 2rem rgb(21 91 155 / 7%);
}

.table {
  margin-bottom: 0;
}

.table > :not(caption) > * > * {
  padding: 0.9rem 1rem;
  border-bottom-color: #e6f0f5;
}

.table thead th {
  color: #3c6077;
  background: #f2f9fc;
  border-bottom-width: 1px;
  font-size: 0.78rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.table-sort-link {
  display: inline-flex;
  gap: 0.3rem;
  align-items: center;
  padding: 0;
  color: inherit;
  background: transparent;
  border: 0;
  font: inherit;
  letter-spacing: inherit;
  text-align: left;
  text-transform: inherit;
  text-decoration: none;
}

.table-sort-link:hover,
.table-sort-link:focus-visible {
  color: var(--medime-navy);
  text-decoration: underline;
  text-underline-offset: 0.2rem;
}

.case-status-group th {
  padding-block: 0.65rem;
  color: var(--medime-navy);
  background: #e8f5f7;
  border-top: 1px solid #cce3e7;
  font-size: 0.9rem;
  letter-spacing: 0.02em;
}

.case-status-count {
  display: inline-grid;
  min-width: 1.6rem;
  min-height: 1.6rem;
  margin-left: 0.4rem;
  place-items: center;
  color: #24626b;
  background: #fff;
  border-radius: 999px;
  font-size: 0.78rem;
}

.case-overview-table tbody + tbody .case-status-group th {
  border-top-width: 2px;
}

.case-header,
.case-nav,
.case-section {
  border-radius: 1rem;
}

.case-header {
  padding: 1.5rem 1.75rem;
}

.case-header h1,
.case-section-title {
  color: var(--medime-navy);
}

.case-nav-title {
  color: var(--medime-teal);
}

.case-nav-list a {
  color: #34546a;
  border-radius: 0.65rem;
}

.case-nav-list a:hover,
.case-nav-list a.is-current {
  color: var(--medime-navy);
  background: linear-gradient(90deg, var(--medime-soft-blue), var(--medime-soft-green));
}

.case-nav-number,
.case-section-number {
  background: var(--medime-gradient);
  box-shadow: 0 0.3rem 0.8rem rgb(21 91 155 / 14%);
}

.case-nav-dot[data-state="filled"] {
  background: var(--medime-teal);
}

.case-section {
  overflow: clip;
}

.case-section[open] > .case-section-header {
  background: linear-gradient(90deg, var(--medime-soft-blue), rgb(237 251 245 / 65%));
  border-bottom-color: var(--medime-line);
}

.case-section-staff {
  border-left-color: var(--medime-teal);
}

.case-section-status[data-state="filled"] {
  color: #08735c;
  background: #e2f8ef;
}

.case-save-bar {
  background: rgb(255 255 255 / 92%);
  border-color: var(--medime-line);
  border-radius: 1rem;
  box-shadow: 0 -0.5rem 2rem rgb(21 91 155 / 10%);
  backdrop-filter: blur(12px);
}

/* ---- Datenschutzinformation ---- */
.privacy-page {
  max-width: 58rem;
  margin: 0 auto;
}

.privacy-header {
  margin-bottom: 1.5rem;
}

.privacy-header h1 {
  margin-bottom: 1rem;
  color: var(--medime-navy);
  font-size: clamp(2.25rem, 6vw, 4rem);
}

.privacy-header .lead {
  max-width: 46rem;
  color: var(--medime-muted);
}

.privacy-version {
  margin-bottom: 0;
  color: var(--medime-muted);
  font-size: 0.9rem;
}

.privacy-draft,
.privacy-navigation,
.privacy-section {
  margin-bottom: 1.25rem;
  padding: clamp(1.25rem, 4vw, 2rem);
  background: rgb(255 255 255 / 94%);
  border: 1px solid var(--medime-line);
  border-radius: 1.25rem;
  box-shadow: 0 0.75rem 2rem rgb(21 91 155 / 7%);
}

.privacy-draft {
  color: #72581b;
  background: #fff9e8;
  border-color: #f0dfac;
}

.privacy-draft strong {
  display: block;
  margin-bottom: 0.4rem;
  font-size: 1.05rem;
}

.privacy-draft p,
.privacy-section > :last-child {
  margin-bottom: 0;
}

.privacy-navigation h2,
.privacy-section h2 {
  color: var(--medime-navy);
  font-size: clamp(1.35rem, 3vw, 1.7rem);
}

.privacy-navigation ol {
  columns: 2 18rem;
  gap: 2rem;
  margin-bottom: 0;
  padding-left: 1.25rem;
}

.privacy-navigation li {
  break-inside: avoid;
  margin-bottom: 0.25rem;
}

.privacy-section {
  scroll-margin-top: 1rem;
}

.privacy-section h3 {
  margin-top: 1.75rem;
  color: #275c7b;
  font-size: 1.15rem;
}

.privacy-section address {
  padding: 1rem 1.15rem;
  background: var(--medime-soft-blue);
  border-left: 0.25rem solid var(--medime-blue);
  border-radius: 0.65rem;
  font-style: normal;
}

.draft-field {
  padding: 0.05rem 0.2rem;
  color: #6b5012;
  background: #fff0bd;
  box-decoration-break: clone;
  -webkit-box-decoration-break: clone;
}

.privacy-table {
  min-width: 42rem;
  font-size: 0.92rem;
}

.privacy-table code {
  color: #185e79;
  white-space: nowrap;
}

.email-sender-summary {
  margin-bottom: 1.25rem;
}

.email-signature-input {
  min-height: 10rem;
  font-family: inherit;
  white-space: pre-wrap;
}

.footer {
  min-height: 4.5rem;
  color: var(--medime-muted);
  background: rgb(255 255 255 / 76%);
  border-top: 1px solid var(--medime-line);
}

.footer-content {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 4.5rem;
}

.footer-brand {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.88rem;
  font-weight: 650;
}

.footer-brand img {
  width: 2.4rem;
  height: 2.4rem;
  object-fit: contain;
  mix-blend-mode: multiply;
}

.footer a {
  font-size: 0.88rem;
  font-weight: 600;
  text-decoration: none;
}

@media (max-width: 767.98px) {
  body {
    margin-bottom: 6rem;
  }

  .site-navbar .navbar-collapse {
    padding: 0.75rem 0 0.5rem;
  }

  .site-navbar .nav-link {
    margin: 0.1rem 0;
  }

  .site-navbar form,
  .site-navbar .navbar-collapse > .btn {
    margin-top: 0.65rem;
  }

  .hero {
    grid-template-columns: 1fr;
    min-height: auto;
    padding-top: 1.5rem;
    text-align: center;
  }

  .hero .eyebrow {
    justify-content: center;
  }

  .hero-visual {
    width: min(80vw, 22rem);
    margin: -1rem auto 0;
  }

  .status-card {
    flex-direction: column;
  }

  .flow-card {
    margin: 0 auto 2rem;
  }

  .invitation-hero {
    min-height: auto;
    margin-top: -0.75rem;
    padding: 8rem 0.75rem 0.75rem;
    background:
      linear-gradient(180deg, rgb(242 249 248 / 10%) 0%, rgb(242 249 248 / 94%) 32%, rgb(242 249 248 / 100%) 62%),
      url("../images/anamnesis-welcome.png") 72% top / auto 22rem no-repeat,
      #f2f9f8;
    border-radius: 1.25rem;
  }

  .invitation-card {
    padding: 1.5rem;
    border-radius: 1.15rem;
  }

  .invitation-card h1 {
    font-size: clamp(2rem, 10vw, 2.75rem);
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  .hero-visual::before {
    animation: none;
  }

  .btn {
    transition: none;
  }

  .invitation-action .btn span {
    transition: none;
  }
}

.thanks-card {
  text-align: center;
}

.thanks-image {
  display: block;
  width: min(100%, 22rem);
  height: auto;
  margin: 0 auto 1.5rem;
  border-radius: 1.5rem;
}

.thanks-lead {
  font-size: 1.25rem;
}

.case-layout-single {
  display: block;
}
