/* OKRs AtentaMente · hoja de estilos
   Identidad tomada de atentamente.mx. Tipografía Jost (OFL) servida localmente con respaldo del sistema. */

@font-face {
  font-family: "Jost";
  src: url("../fonts/Jost-VariableFont_wght.ttf") format("truetype-variations"),
       url("../fonts/Jost-VariableFont_wght.ttf") format("truetype");
  font-weight: 100 900;
  font-style: normal;
  font-display: swap;
}

:root {
  /* Marca */
  --navy: #22314E;
  --beige: #F5F0EA;
  --white: #FFFFFF;
  --yellow: #F0BA54;
  --teal: #1A7F83;
  --coral: #F15D4A;
  --beige-line: #EFE8DE;

  /* Derivados con contraste suficiente */
  --text: var(--navy);
  --muted: #5B6478;
  --line: #E4DCCF;
  --teal-dark: #146468;
  --teal-soft: #E3F1F1;
  --yellow-hover: #E9AA35;
  --focus: var(--teal);

  /* Semáforo (texto oscuro sobre fondo claro, contraste AA) */
  --green-bg: #E2F2E7;  --green-fg: #1D6534;  --green-dot: #2F9E55;
  --yellow-bg: #FCEFD2; --yellow-fg: #7A5100; --yellow-dot: #E0A022;
  --red-bg: #FCE3DF;    --red-fg: #A12617;    --red-dot: #E0442F;
  --gray-bg: #ECEDF1;   --gray-fg: #4A5265;   --gray-dot: #8A91A3;

  --radius: 10px;
  --radius-sm: 6px;
  --shadow: 0 1px 2px rgba(34, 49, 78, .06), 0 2px 8px rgba(34, 49, 78, .05);
  --font: "Jost", system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --space-1: 4px; --space-2: 8px; --space-3: 12px; --space-4: 16px; --space-5: 24px; --space-6: 32px;
  --sidebar-w: 240px;
}

*, *::before, *::after { box-sizing: border-box; }
[hidden] { display: none !important; }
html { font-size: 16px; -webkit-text-size-adjust: 100%; }
body {
  margin: 0; font-family: var(--font); font-weight: 400; font-size: 1rem; line-height: 1.5;
  color: var(--text); background: var(--beige);
}
h1, h2, h3, h4 { font-weight: 600; line-height: 1.25; margin: 0 0 var(--space-3); }
h1 { font-size: 1.75rem; }
h2, .h2 { font-size: 1.375rem; }
h3, .h3 { font-size: 1.125rem; }
h4 { font-size: 1rem; }
p { margin: 0 0 var(--space-3); }
a { color: var(--teal-dark); text-underline-offset: 2px; }
a:hover { color: var(--navy); }
code { background: var(--beige-line); padding: 1px 5px; border-radius: 4px; font-size: .9em; }
small, .small { font-size: .875rem; }
.muted { color: var(--muted); }
.eyebrow { display: block; font-size: .75rem; font-weight: 600; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); border: 0; }
.skip-link { position: absolute; left: -999px; top: 8px; background: var(--white); padding: 8px 12px; z-index: 100; }
.skip-link:focus { left: 8px; }

:focus-visible { outline: 3px solid var(--focus); outline-offset: 2px; border-radius: 4px; }

/* ---------- Estructura ---------- */
.demo-banner { background: var(--navy); color: var(--white); text-align: center; font-size: .875rem; padding: 6px 12px; }
.shell { display: flex; min-height: 100vh; }
.sidebar {
  width: var(--sidebar-w); flex-shrink: 0; background: var(--white); border-right: 1px solid var(--line);
  display: flex; flex-direction: column; padding: var(--space-4); gap: var(--space-4);
  position: sticky; top: 0; height: 100vh; overflow-y: auto;
}
.brand { display: flex; align-items: center; gap: 10px; }
.brand-mark {
  width: 36px; height: 36px; border-radius: 50%; background: var(--yellow); color: var(--navy);
  display: grid; place-items: center; font-weight: 700; font-size: 1.25rem;
}
.brand-text { font-weight: 700; font-size: 1.05rem; line-height: 1.1; }
.brand-text small { display: block; font-weight: 500; font-size: .75rem; color: var(--teal-dark); letter-spacing: .08em; text-transform: uppercase; }
.brand-lg .brand-mark { width: 44px; height: 44px; font-size: 1.5rem; }
.team-switch select { width: 100%; margin-top: 4px; }
.nav { display: flex; flex-direction: column; gap: 2px; }
.nav a {
  display: flex; align-items: center; gap: 10px; padding: 9px 10px; border-radius: var(--radius-sm);
  color: var(--navy); text-decoration: none; font-weight: 500;
}
.nav a:hover { background: var(--beige); }
.nav a.active { background: var(--teal-soft); color: var(--teal-dark); box-shadow: inset 3px 0 0 var(--teal); }
.nav a.secondary { font-weight: 400; padding-left: 38px; font-size: .95rem; }
.nav-icon { width: 18px; text-align: center; opacity: .8; }
.nav-sep { height: 1px; background: var(--beige-line); margin: 6px 0; }
.nav-global { border-top: 1px solid var(--beige-line); padding-top: var(--space-3); }
.sidebar-foot { margin-top: auto; border-top: 1px solid var(--beige-line); padding-top: var(--space-3); display: flex; flex-direction: column; gap: 8px; }
.me { display: flex; align-items: center; gap: 10px; }
.me-name { font-weight: 500; font-size: .9rem; line-height: 1.2; }
.me-name small { display: block; color: var(--muted); font-weight: 400; }
.avatar {
  width: 32px; height: 32px; border-radius: 50%; background: var(--navy); color: var(--white);
  display: grid; place-items: center; font-size: .8rem; font-weight: 600; flex-shrink: 0;
}
.main-col { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.topbar {
  display: flex; align-items: center; gap: var(--space-4); padding: 10px var(--space-5);
  background: var(--white); border-bottom: 1px solid var(--line); position: sticky; top: 0; z-index: 10;
}
.menu-btn { display: none; background: none; border: 1px solid var(--line); border-radius: var(--radius-sm); font-size: 1.25rem; padding: 4px 10px; color: var(--navy); cursor: pointer; }
.context { display: flex; flex-wrap: wrap; gap: var(--space-2); align-items: center; flex: 1; min-width: 0; }
.ctx-chip {
  display: inline-flex; flex-direction: column; padding: 2px 10px; border-left: 3px solid var(--yellow);
  font-weight: 600; font-size: .95rem; line-height: 1.2;
}
.ctx-chip .eyebrow { font-size: .68rem; }
.ctx-chip select { border: none; background: transparent; font: inherit; font-weight: 600; color: var(--navy); padding: 0 18px 0 0; min-height: 0; }
.search input { width: 240px; }
.content { padding: var(--space-5); max-width: 1280px; width: 100%; }
.content:focus { outline: none; }

/* ---------- Páginas ---------- */
.page-head { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: var(--space-4); margin-bottom: var(--space-5); }
.page-head h1 { margin-bottom: 4px; }
.page-head p { margin: 0; }
.actions { display: flex; flex-wrap: wrap; gap: var(--space-2); align-items: center; }
.card {
  background: var(--white); border: 1px solid var(--line); border-radius: var(--radius);
  padding: var(--space-5); margin-bottom: var(--space-5); box-shadow: var(--shadow);
}
.card-head { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: flex-start; gap: var(--space-3); margin-bottom: var(--space-3); }
.card-head h2, .card-head h3 { margin: 0; }
.card.compact { padding: var(--space-4); }
.card.muted-card { background: #FBF8F4; box-shadow: none; }
.grid-2 { display: grid; grid-template-columns: minmax(0, 2fr) minmax(0, 1fr); gap: var(--space-5); align-items: start; }
.grid-3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--space-4); }
.stack > * + * { margin-top: var(--space-3); }
.section-title { display: flex; align-items: center; gap: 10px; margin: var(--space-5) 0 var(--space-3); }
.section-title h2 { margin: 0; }
.list { list-style: none; padding: 0; margin: 0; }
.list > li { padding: 10px 0; border-bottom: 1px solid var(--beige-line); }
.list > li:last-child { border-bottom: none; }
dl.meta { display: grid; grid-template-columns: max-content 1fr; gap: 6px 16px; margin: 0; }
dl.meta dt { color: var(--muted); font-size: .9rem; }
dl.meta dd { margin: 0; }
.pre { white-space: pre-line; }
.empty-state { text-align: center; padding: var(--space-6) var(--space-4); color: var(--muted); }
.empty-state h1, .empty-state h2 { color: var(--navy); }
.empty-state .btn { margin-top: var(--space-2); }
.breadcrumb { font-size: .9rem; color: var(--muted); margin-bottom: var(--space-2); }
.breadcrumb a { color: var(--muted); }

/* ---------- Botones ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px; min-height: 40px;
  padding: 8px 16px; border-radius: var(--radius-sm); border: 1px solid var(--navy); background: var(--white);
  color: var(--navy); font: inherit; font-weight: 500; text-decoration: none; cursor: pointer; line-height: 1.2;
}
.btn:hover { background: var(--beige); color: var(--navy); }
.btn-primary { background: var(--yellow); border-color: var(--yellow); color: var(--navy); font-weight: 600; }
.btn-primary:hover { background: var(--yellow-hover); border-color: var(--yellow-hover); }
.btn-teal { background: var(--teal); border-color: var(--teal); color: var(--white); }
.btn-teal:hover { background: var(--teal-dark); color: var(--white); }
.btn-ghost { border-color: transparent; background: transparent; }
.btn-ghost:hover { background: var(--beige); }
.btn-danger { border-color: var(--red-fg); color: var(--red-fg); }
.btn-danger:hover { background: var(--red-bg); color: var(--red-fg); }
.btn-sm { min-height: 32px; padding: 4px 10px; font-size: .9rem; }
.btn-block { width: 100%; }
.btn[disabled] { opacity: .55; cursor: not-allowed; }
.link-btn { background: none; border: none; padding: 0; color: var(--teal-dark); font: inherit; cursor: pointer; text-decoration: underline; text-underline-offset: 2px; }
form.inline { display: inline; }

/* ---------- Formularios ---------- */
.form { display: flex; flex-direction: column; gap: var(--space-4); }
.form-row { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: var(--space-4); }
.field { display: flex; flex-direction: column; gap: 6px; }
.field > label, .field > .label { font-weight: 500; }
.field .hint { font-size: .85rem; color: var(--muted); margin: 0; }
input[type=text], input[type=email], input[type=password], input[type=date], input[type=number], input[type=search], input[type=url], input:not([type]), select, textarea {
  font: inherit; color: var(--navy); background: var(--white); border: 1px solid #CFC6B8; border-radius: var(--radius-sm);
  padding: 8px 10px; min-height: 40px; width: 100%;
}
textarea { min-height: 96px; resize: vertical; }
input:focus, select:focus, textarea:focus { border-color: var(--teal); outline: 2px solid var(--teal-soft); outline-offset: 0; }
input:focus-visible, select:focus-visible, textarea:focus-visible { outline: 3px solid var(--focus); outline-offset: 1px; }
.field.has-error input, .field.has-error select, .field.has-error textarea { border-color: var(--red-fg); }
.field-error { color: var(--red-fg); font-size: .875rem; margin: 0; font-weight: 500; }
.checkbox { display: flex; align-items: center; gap: 8px; }
.checkbox input { width: 18px; height: 18px; accent-color: var(--teal); }
.radio-group { display: flex; flex-wrap: wrap; gap: var(--space-2); }
.radio-pill { position: relative; }
.radio-pill input { position: absolute; opacity: 0; }
.radio-pill span { display: inline-flex; align-items: center; gap: 6px; padding: 6px 12px; border: 1px solid #CFC6B8; border-radius: 999px; cursor: pointer; background: var(--white); }
.radio-pill input:checked + span { border-color: var(--teal); background: var(--teal-soft); color: var(--teal-dark); font-weight: 600; }
.radio-pill input:focus-visible + span { outline: 3px solid var(--focus); outline-offset: 2px; }
.form-actions { display: flex; flex-wrap: wrap; gap: var(--space-2); align-items: center; padding-top: var(--space-2); }
.reason-box { border-left: 3px solid var(--yellow); background: #FFF8EA; padding: var(--space-3); border-radius: var(--radius-sm); }
fieldset { border: 1px solid var(--line); border-radius: var(--radius); padding: var(--space-4); margin: 0; }
legend { font-weight: 600; padding: 0 6px; }

/* ---------- Avisos ---------- */
.alert { padding: 12px 16px; border-radius: var(--radius-sm); margin-bottom: var(--space-4); border-left: 4px solid; background: var(--white); }
.alert-success { border-color: var(--green-dot); background: var(--green-bg); color: var(--green-fg); }
.alert-error { border-color: var(--red-dot); background: var(--red-bg); color: var(--red-fg); }
.alert-warning { border-color: var(--yellow-dot); background: var(--yellow-bg); color: var(--yellow-fg); }
.alert-info { border-color: var(--teal); background: var(--teal-soft); color: var(--teal-dark); }

/* ---------- Semáforo e insignias ---------- */
.badge {
  display: inline-flex; align-items: center; gap: 6px; padding: 2px 10px; border-radius: 999px;
  font-size: .85rem; font-weight: 600; white-space: nowrap; line-height: 1.6;
}
.badge .dot { width: 8px; height: 8px; border-radius: 50%; background: currentColor; flex-shrink: 0; }
.badge-green { background: var(--green-bg); color: var(--green-fg); } .badge-green .dot { background: var(--green-dot); }
.badge-yellow { background: var(--yellow-bg); color: var(--yellow-fg); } .badge-yellow .dot { background: var(--yellow-dot); }
.badge-red { background: var(--red-bg); color: var(--red-fg); } .badge-red .dot { background: var(--red-dot); }
.badge-gray { background: var(--gray-bg); color: var(--gray-fg); } .badge-gray .dot { background: var(--gray-dot); }
.tag { display: inline-block; padding: 1px 8px; border-radius: 4px; font-size: .78rem; font-weight: 600; background: var(--beige-line); color: var(--navy); vertical-align: middle; }
.tag-teal { background: var(--teal-soft); color: var(--teal-dark); }
.tag-coral { background: #FDE6E2; color: #A12617; }
.tag-example { background: #EDE7F6; color: #4A2F7A; }
.counts { display: flex; flex-wrap: wrap; gap: 6px; }
.flag-stale { color: var(--gray-fg); font-size: .82rem; font-weight: 500; white-space: nowrap; }
.flag-stale::before { content: "◔ "; }

/* ---------- Tablero ---------- */
.alert-strip { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: var(--space-3); margin-bottom: var(--space-5); }
.alert-tile {
  background: var(--white); border: 1px solid var(--line); border-radius: var(--radius); padding: var(--space-3) var(--space-4);
  display: flex; flex-direction: column; gap: 2px; text-decoration: none; color: var(--navy); border-top: 4px solid var(--gray-dot);
}
.alert-tile:hover { box-shadow: var(--shadow); color: var(--navy); }
.alert-tile strong { font-size: 1.6rem; font-weight: 600; line-height: 1.1; }
.alert-tile.red { border-top-color: var(--red-dot); }
.alert-tile.yellow { border-top-color: var(--yellow-dot); }
.alert-tile.gray { border-top-color: var(--gray-dot); }
.filters { display: flex; flex-wrap: wrap; gap: var(--space-3); align-items: flex-end; margin-bottom: var(--space-4); }
.filters .field { min-width: 180px; }
.objective-block { margin-bottom: var(--space-5); }
.objective-head {
  display: flex; flex-wrap: wrap; justify-content: space-between; gap: var(--space-3); align-items: flex-start;
  background: var(--white); border: 1px solid var(--line); border-bottom: none; border-radius: var(--radius) var(--radius) 0 0;
  padding: var(--space-4) var(--space-4) var(--space-3);
}
.objective-head h3 { margin: 2px 0 4px; }
.objective-head h3 a { color: var(--navy); text-decoration: none; }
.objective-head h3 a:hover { text-decoration: underline; }
.objective-head .meta-line { font-size: .88rem; color: var(--muted); }
.table-wrap { background: var(--white); border: 1px solid var(--line); border-radius: 0 0 var(--radius) var(--radius); overflow-x: auto; }
.table-wrap.standalone { border-radius: var(--radius); }
table.table { width: 100%; border-collapse: collapse; font-size: .95rem; }
.table th { text-align: left; font-weight: 600; font-size: .8rem; color: var(--muted); text-transform: uppercase; letter-spacing: .04em; padding: 10px 12px; border-bottom: 1px solid var(--line); background: #FBF8F4; white-space: nowrap; }
.table td { padding: 12px; border-bottom: 1px solid var(--beige-line); vertical-align: top; }
.table tr:last-child td { border-bottom: none; }
.table tr.row-link { cursor: pointer; }
.table tr.row-link:hover td { background: #FCFAF7; }
.table tr.is-alert td:first-child { box-shadow: inset 3px 0 0 var(--red-dot); }
.table tr.is-risk td:first-child { box-shadow: inset 3px 0 0 var(--yellow-dot); }
.table .kr-title { font-weight: 500; color: var(--navy); text-decoration: none; }
.table td.cell-main { min-width: 240px; }
.table .kr-title:hover { text-decoration: underline; }
.table .sub { display: block; font-size: .82rem; color: var(--muted); margin-top: 2px; }
.progress { display: flex; flex-direction: column; gap: 4px; min-width: 120px; }
.bar { height: 6px; border-radius: 999px; background: var(--beige-line); overflow: hidden; }
.bar > span { display: block; height: 100%; background: var(--teal); border-radius: 999px; }
.draft-card { border-style: dashed; }
.pending-list { margin: 6px 0 0; padding-left: 18px; color: var(--yellow-fg); font-size: .9rem; }

/* ---------- Detalle ---------- */
.kr-hero { display: flex; flex-wrap: wrap; gap: var(--space-5); align-items: center; }
.kr-hero .big { font-size: 2rem; font-weight: 600; line-height: 1.1; }
.timeline { list-style: none; margin: 0; padding: 0; }
.timeline li { position: relative; padding: 0 0 var(--space-4) var(--space-5); border-left: 2px solid var(--beige-line); margin-left: 6px; }
.timeline li:last-child { padding-bottom: 0; }
.timeline li::before { content: ""; position: absolute; left: -7px; top: 4px; width: 12px; height: 12px; border-radius: 50%; background: var(--white); border: 2px solid var(--teal); }
.timeline .when { font-size: .85rem; color: var(--muted); }
.comment { border-left: 3px solid var(--teal); padding: 8px 12px; background: #FBF8F4; border-radius: 0 var(--radius-sm) var(--radius-sm) 0; margin-bottom: var(--space-3); }
.comment.proposal { border-left-color: var(--yellow); }
.comment.return_note { border-left-color: var(--coral); }
.comment .who { font-size: .85rem; color: var(--muted); }

/* ---------- Plan anual ---------- */
.category-block { margin-bottom: var(--space-6); }
.category-title { display: flex; align-items: center; justify-content: space-between; gap: var(--space-3); border-bottom: 2px solid var(--yellow); padding-bottom: 6px; margin-bottom: var(--space-4); }
.category-title h2 { margin: 0; }
.specific { background: #FBF8F4; border: 1px solid var(--beige-line); border-radius: var(--radius-sm); padding: var(--space-3) var(--space-4); margin-top: var(--space-3); }
.quarter-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--space-3); margin-top: var(--space-3); }
.quarter { border: 1px solid var(--beige-line); border-radius: var(--radius-sm); padding: var(--space-3); font-size: .92rem; }
.quarter h4 { font-size: .8rem; text-transform: uppercase; letter-spacing: .05em; color: var(--muted); margin-bottom: 6px; }
.status-pill { display: inline-flex; align-items: center; gap: 8px; padding: 6px 14px; border-radius: 999px; font-weight: 600; background: var(--teal-soft); color: var(--teal-dark); }
.status-pill.submitted { background: var(--yellow-bg); color: var(--yellow-fg); }
.status-pill.returned { background: var(--red-bg); color: var(--red-fg); }
.status-pill.approved { background: var(--green-bg); color: var(--green-fg); }

/* ---------- Reunión ---------- */
.meeting-layout { display: grid; grid-template-columns: minmax(0, 3fr) minmax(0, 2fr); gap: var(--space-5); align-items: start; }
.section-num { display: inline-grid; place-items: center; width: 28px; height: 28px; border-radius: 50%; background: var(--navy); color: var(--white); font-size: .85rem; font-weight: 600; flex-shrink: 0; }
.change-list { margin: 4px 0 0; padding-left: 18px; font-size: .88rem; }
.minutes textarea { min-height: 260px; }
.task-row { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px; }
.task-row .task-title { font-weight: 500; }
.task-status-form select { width: auto; min-height: 32px; padding: 4px 8px; }
.sticky-side { position: sticky; top: 76px; }

/* ---------- Asistente ---------- */
.assistant { border: 1px solid var(--teal); border-radius: var(--radius); background: #F6FBFB; padding: var(--space-4); }
.assistant h3 { display: flex; align-items: center; gap: 8px; color: var(--teal-dark); }
.assistant .ai-actions { display: flex; flex-wrap: wrap; gap: 8px; }
.assistant .ai-result { margin-top: var(--space-3); }
.assistant .suggestion { background: var(--white); border: 1px solid var(--line); border-radius: var(--radius-sm); padding: var(--space-3); margin-bottom: var(--space-2); }
.assistant .suggestion .text { white-space: pre-line; margin: 6px 0; }
.assistant ul { margin: 4px 0 var(--space-3); padding-left: 18px; }
.assistant .loading { color: var(--muted); }
.field.ai-flag input, .field.ai-flag textarea { border-color: var(--yellow-dot); background: #FFFBF1; }
.field.ai-applied input, .field.ai-applied textarea { border-color: var(--teal); background: #F1F9F9; }

/* ---------- Pantallas sin menú (acceso) ---------- */
body.bare { display: grid; place-items: center; min-height: 100vh; padding: var(--space-4); }
.bare-main { width: 100%; max-width: 420px; }
.bare-card { background: var(--white); border: 1px solid var(--line); border-radius: 14px; padding: var(--space-6); box-shadow: var(--shadow); }
.bare-card .brand { margin-bottom: var(--space-5); }

/* ---------- Responsivo ---------- */
@media (max-width: 1100px) {
  .alert-strip { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .meeting-layout, .grid-2 { grid-template-columns: minmax(0, 1fr); }
  .sticky-side { position: static; }
  .quarter-grid { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 860px) {
  .sidebar {
    position: fixed; left: 0; top: 0; z-index: 50; transform: translateX(-100%); transition: transform .2s ease;
    box-shadow: 0 0 30px rgba(34,49,78,.25);
  }
  .sidebar.open { transform: none; }
  .menu-btn { display: inline-block; }
  .topbar { padding: 8px var(--space-4); flex-wrap: wrap; gap: var(--space-2); position: static; }
  .search { width: 100%; order: 3; }
  .search input { width: 100%; }
  .content { padding: var(--space-4); }
  h1 { font-size: 1.45rem; }
  .card { padding: var(--space-4); }
  .grid-3 { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 1024px) {
  /* Tabla de KRs como tarjetas apiladas: estado y acción siempre visibles */
  .table-cards thead { display: none; }
  .table-cards, .table-cards tbody, .table-cards tr, .table-cards td { display: block; width: 100%; }
  .table-cards tr { padding: var(--space-3) var(--space-4); border-bottom: 1px solid var(--beige-line); }
  .table-cards td { border: none; padding: 3px 0; min-width: 0; }
  .table-cards td[data-label] { display: inline-block; width: auto; margin-right: 16px; font-size: .9rem; }
  .table-cards td[data-label] .sub { display: inline; margin-left: 4px; }
  .table-cards .progress { display: inline-flex; flex-direction: row; align-items: center; gap: 8px; min-width: 0; }
  .table-cards .progress .bar { width: 80px; }
  .table-cards td[data-label]::before { content: attr(data-label) ": "; color: var(--muted); font-size: .82rem; }
  .table-cards td.cell-main::before, .table-cards td.cell-status::before, .table-cards td.cell-action::before { content: none; }
  .table-cards td.cell-status, .table-cards td.cell-action { display: inline-block; width: auto; margin-right: 8px; margin-top: 6px; }
  .table-cards tr.is-alert td:first-child, .table-cards tr.is-risk td:first-child { box-shadow: none; }
  .table-cards tr.is-alert { box-shadow: inset 4px 0 0 var(--red-dot); }
  .table-cards tr.is-risk { box-shadow: inset 4px 0 0 var(--yellow-dot); }
}
@media (max-width: 520px) {
  .alert-strip { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
  .page-head { align-items: flex-start; }
}
@media (prefers-reduced-motion: reduce) { * { transition: none !important; } }
@media print {
  .sidebar, .topbar, .demo-banner, .form-actions, .btn { display: none !important; }
  body { background: #fff; }
}
