:root { --maxw: 72ch; }
* { box-sizing: border-box; }
html { font-family: system-ui, -apple-system, Segoe UI, Roboto, Inter, Arial, sans-serif; }
body { margin: 0; color: #111; background: #fff; line-height: 1.6; }
.container { max-width: var(--maxw); margin: 0 auto; padding: 1rem; }
h1, h2, h3 { line-height: 1.2; }
a { text-decoration: underline; }
a:focus-visible, button:focus-visible { outline: 2px solid currentColor; outline-offset: 3px; }
.lede { font-size: 1.1rem; }
[aria-disabled="true"] { pointer-events: none; opacity: .6; }

/* --- Navigation & Layout --- */
.nav-links ul {
  display: flex;
  flex-wrap: wrap;
  gap: .5rem 1rem;
  list-style: none;
  padding: 0;
  margin: 0 0 1rem 0;
}
.nav-links a {
  background: #f5f5f5;
  padding: .4rem .8rem;
  border-radius: .5rem;
  text-decoration: none;
  color: #111;
}
.nav-links a:hover,
.nav-links a:focus-visible {
  background: #e5e5e5;
}
section {
  margin-bottom: 2rem;
  border-bottom: 1px solid #eee;
  padding-bottom: 1rem;
}
footer {
  border-top: 1px solid #ddd;
  margin-top: 2rem;
  font-size: .875rem;
  color: #555;
}

/* --- Mini-Check-Styles --- */
.check-item { margin-bottom: 2rem; }
button { cursor: pointer; font: inherit; }
#tastatur-testarea {
  border: 2px dashed #ccc;
  padding: 1rem;
  margin-top: .5rem;
}
.result { font-weight: 600; margin-top: .5rem; }
.result.ok { color: #007a33; }     /* Grün */
.result.warn { color: #b00020; }   /* Rot */

.progressbar {
  height: .5rem;
  background: #eee;
  margin-top: .25rem;
  border-radius: .25rem;
  overflow: hidden;
  width: 100%;
}
#progress-fill {
  height: 100%;
  width: 0%;
  background: #007a33;
  transition: width .4s ease;
}

/* --- Accessibly Hidden (Screenreader only) --- */
.sr-only {
  position: absolute !important;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0,0,0,0);
  white-space: nowrap; border: 0;
}

/* --- Kontrast-Check Grid & Cards --- */
.contrast-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
  margin: .75rem 0;
}
.contrast-card {
  display: flex;
  flex-direction: column;
  gap: .25rem;
  align-items: flex-start;
  text-align: left;
  width: 100%;
  border: 2px solid #ddd;
  border-radius: .6rem;
  padding: 1rem;
  background: #fff;
  transition: transform .15s ease, box-shadow .15s ease, border-color .15s ease;
}
.contrast-card:focus-visible,
.contrast-card:hover {
  outline: none;
  border-color: #007a33;
  box-shadow: 0 0 0 4px rgba(0,122,51,.12);
  transform: translateY(-1px);
}
.card-title { font-weight: 700; }
.card-body  { font-size: .95rem; line-height: 1.45; }

/* Gute Lesbarkeit – hoher Kontrast */
.card-good {
  color: #111;
  background: #fff;
  border-color: #cfd8dc;
}

/* Schlechte Lesbarkeit – geringer Kontrast (absichtlich grenzwertig) */
.card-poor {
  color: #6e6e6e;
  background: #f2f3f5;
  border-color: #e0e0e0;
}

/* Feedback + Badge */
.badge {
  display: inline-block;
  margin-top: .5rem;
  padding: .4rem .6rem;
  border-radius: .5rem;
  font-weight: 600;
  background: #ecfdf5;   /* sanftes Grün */
  color: #065f46;
  border: 1px solid #10b981;
}

/* Kleine „Pulse“-Animation beim Erfolg */
@keyframes pulse-ok {
  0%   { transform: scale(1); }
  50%  { transform: scale(1.02); }
  100% { transform: scale(1); }
}
.badge.show {
  animation: pulse-ok .4s ease-in-out;
}

