/* TW Responsive Phase 4 – nur explizit markierte Inhaltsbereiche. */
.tw-r4-content {
  --tw-r4-gap: clamp(12px, 2vw, 24px);
  box-sizing: border-box;
  width: 100%;
  max-width: 100%;
  min-width: 0;
  overflow-wrap: anywhere;
}
.tw-r4-content *, .tw-r4-content *::before, .tw-r4-content *::after { box-sizing: border-box; }
.tw-r4-content :is(img, video, iframe, svg) { max-width: 100%; height: auto; }
.tw-r4-content :is(pre, code) { overflow-wrap: anywhere; }
.tw-r4-content pre { max-width: 100%; overflow-x: auto; }
.tw-r4-content .tw-r4-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 270px), 1fr));
  gap: var(--tw-r4-gap);
}
.tw-r4-content.tw-r4-columns-one .tw-r4-grid { grid-template-columns: minmax(0, 1fr); }
.tw-r4-content.tw-r4-columns-two .tw-r4-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.tw-r4-content.tw-r4-columns-three .tw-r4-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.tw-r4-content .tw-r4-card {
  min-width: 0;
  padding: clamp(12px, 2vw, 20px);
  background: #EBEBE9;
  border: 1px solid #A1A69F;
  border-radius: 8px;
}
.tw-r4-content .tw-r4-table-scroll { max-width: 100%; overflow-x: auto; overscroll-behavior-inline: contain; }
.tw-r4-content .tw-r4-table-scroll table { width: 100%; min-width: 580px; border-collapse: collapse; }
.tw-r4-content .tw-r4-table-scroll th,
.tw-r4-content .tw-r4-table-scroll td { padding: 10px 12px; border-bottom: 1px solid #A1A69F; text-align: left; }
@media (max-width: 720px) {
  .tw-r4-content.tw-r4-columns-two .tw-r4-grid,
  .tw-r4-content.tw-r4-columns-three .tw-r4-grid { grid-template-columns: minmax(0, 1fr); }
}

/* Phase 5: isolierte Vorschau. Alle Regeln auf .tw-r5-demo begrenzt. */
.tw-r5-demo { max-width: 1040px; margin: 24px auto; padding: clamp(16px, 2.5vw, 28px); background: #EBEBE9; border-radius: 10px; color: #1C201F; }
.tw-r5-demo .tw-r5-heading { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; flex-wrap: wrap; margin-bottom: 20px; }
.tw-r5-demo .tw-r5-heading h2 { margin: 4px 0 8px; font-size: clamp(22px, 3vw, 30px); line-height: 1.2; }
.tw-r5-demo .tw-r5-heading p { margin: 0; line-height: 1.5; }
.tw-r5-demo .tw-r5-eyebrow { display: block; font-size: 10px; font-weight: 800; text-transform: uppercase; letter-spacing: .08em; color: #6C7B76; }
.tw-r5-demo .tw-r5-status { flex: none; padding: 6px 10px; border-radius: 12px; background: #6C7B76; color: #fff; font-size: 11px; }
.tw-r5-demo .tw-r4-card { background: #fff; }
.tw-r5-demo .tw-r4-card h3 { font-size: 16px; margin: 8px 0; }
.tw-r5-demo .tw-r4-card p { margin: 0; line-height: 1.5; }
.tw-r5-demo .tw-r5-table-title { margin: 22px 0 8px; font-size: 16px; }
.tw-r5-demo .tw-r4-table-scroll { background: #fff; border: 1px solid #A1A69F; border-radius: 6px; }
.tw-r5-demo .tw-r4-table-scroll th { background: #6C7B76; color: #fff; }
.tw-r5-demo .tw-r4-table-scroll td { background: #fff; }
@media (max-width: 480px) { .tw-r5-demo { margin: 12px 0; padding: 14px; } }
