/* Portal Ciudadano AMDC — sistema visual (paleta propuesta para la demo, editable) */
@font-face { font-family: "Inter"; src: url("../fonts/inter.woff2") format("woff2"); font-weight: 100 900; font-display: swap; }

:root {
  --ink: #10243A; --ink-2: #1c3653; --primary: #2457C5; --primary-600: #1c4aad; --primary-700: #173d8f; --primary-50: #eef3fd; --primary-100: #dbe6fb;
  --accent: #F1C644; --accent-50: #fdf6dc; --surface: #F5F7FB; --surface-2: #eef2f8; --muted: #64748B; --line: #e2e8f1; --white: #fff;
  --success: #15803d; --success-50: #e8f6ee; --warning: #a16207; --warning-50: #fdf4e1; --danger: #b91c1c; --danger-50: #fdecec; --info: #2457C5; --info-50: #eef3fd;
  --r-sm: 8px; --r: 12px; --r-lg: 16px; --r-xl: 22px;
  --sh-1: 0 1px 2px rgba(16,36,58,.06), 0 1px 3px rgba(16,36,58,.06);
  --sh-2: 0 4px 14px rgba(16,36,58,.08), 0 2px 4px rgba(16,36,58,.05);
  --sh-3: 0 18px 40px rgba(16,36,58,.14), 0 4px 10px rgba(16,36,58,.06);
  --t-fast: 150ms; --t: 200ms; --ease: cubic-bezier(.2,.7,.2,1);
  --font: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
  --sidebar: 264px;
}
*, *::before, *::after { box-sizing: border-box; }
[hidden] { display: none !important; }
@keyframes grow { from { width: 0; } }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body { margin: 0; font-family: var(--font); color: var(--ink); background: var(--white); font-size: 15px; line-height: 1.55; -webkit-font-smoothing: antialiased; }
img, svg { max-width: 100%; display: block; }
a { color: var(--primary); text-decoration: none; }
a:hover { text-decoration: underline; text-underline-offset: 3px; }
h1, h2, h3, h4 { line-height: 1.2; margin: 0 0 .5em; letter-spacing: -.01em; }
h1 { font-size: clamp(1.6rem, 1.2rem + 1.6vw, 2.3rem); font-weight: 750; }
h2 { font-size: clamp(1.3rem, 1.1rem + .8vw, 1.7rem); font-weight: 700; }
h3 { font-size: 1.1rem; font-weight: 650; }
p { margin: 0 0 1em; }
small, .small { font-size: .85rem; }
.muted { color: var(--muted); }
.sr-only { position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); border: 0; }
:focus-visible { outline: 3px solid var(--primary); outline-offset: 2px; border-radius: 6px; }
.skip-link { position: absolute; left: 12px; top: -60px; background: var(--ink); color: #fff; padding: 10px 14px; border-radius: var(--r-sm); z-index: 1000; }
.skip-link:focus { top: 12px; }
::selection { background: var(--primary-100); }

/* ------------------------------------------------ layout */
.container { width: 100%; max-width: 1200px; margin: 0 auto; padding: 0 20px; }
.container-narrow { max-width: 860px; }
.stack > * + * { margin-top: var(--gap, 16px); }
.row { display: flex; gap: var(--gap, 12px); align-items: center; flex-wrap: wrap; }
.row-between { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; }
.grid { display: grid; gap: var(--gap, 16px); }
.grid-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.grid-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.grid-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.grid-auto { grid-template-columns: repeat(auto-fill, minmax(min(260px, 100%), 1fr)); }
@media (max-width: 1024px) { .grid-4 { grid-template-columns: repeat(2, minmax(0, 1fr)); } .grid-3 { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 680px) { .grid-2, .grid-3, .grid-4 { grid-template-columns: 1fr; } .container { padding: 0 16px; } }
.hide-mobile { } @media (max-width: 760px) { .hide-mobile { display: none !important; } }
.show-mobile { display: none !important; } @media (max-width: 760px) { .show-mobile { display: initial !important; } }

/* ------------------------------------------------ demo banner */
.demo-banner { background: var(--ink); color: #dbe6fb; font-size: .8rem; padding: 6px 16px; display: flex; gap: 10px; align-items: center; justify-content: center; flex-wrap: wrap; position: relative; z-index: 60; }
.demo-banner strong { color: var(--accent); letter-spacing: .02em; }
.demo-banner a, .demo-banner button { color: #fff; text-decoration: underline; background: none; border: 0; font: inherit; cursor: pointer; padding: 0; }
.demo-banner .dot { width: 8px; height: 8px; border-radius: 50%; background: var(--accent); box-shadow: 0 0 0 0 rgba(241,198,68,.6); animation: pulse 2.4s infinite; }
@keyframes pulse { 0% { box-shadow: 0 0 0 0 rgba(241,198,68,.55); } 70% { box-shadow: 0 0 0 10px rgba(241,198,68,0); } 100% { box-shadow: 0 0 0 0 rgba(241,198,68,0); } }

/* ------------------------------------------------ buttons */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 44px; padding: 10px 18px; border-radius: var(--r); border: 1px solid transparent;
  font: 600 .95rem/1.2 var(--font); cursor: pointer; text-decoration: none !important; transition: background var(--t-fast) var(--ease), transform var(--t-fast) var(--ease), box-shadow var(--t) var(--ease), border-color var(--t-fast); white-space: nowrap; }
.btn:active { transform: translateY(1px) scale(.99); }
.btn[disabled], .btn.is-loading { opacity: .6; pointer-events: none; }
.btn-primary { background: var(--primary); color: #fff; box-shadow: 0 6px 16px -6px rgba(36,87,197,.55); }
.btn-primary:hover { background: var(--primary-600); box-shadow: 0 10px 22px -8px rgba(36,87,197,.6); }
.btn-accent { background: var(--accent); color: var(--ink); }
.btn-accent:hover { background: #e9b925; }
.btn-dark { background: var(--ink); color: #fff; }
.btn-dark:hover { background: var(--ink-2); }
.btn-outline { background: #fff; color: var(--ink); border-color: var(--line); }
.btn-outline:hover { border-color: #c5d2e6; background: var(--surface); }
.btn-ghost { background: transparent; color: var(--primary); }
.btn-ghost:hover { background: var(--primary-50); }
.btn-danger { background: var(--danger); color: #fff; }
.btn-danger:hover { background: #991b1b; }
.btn-success { background: var(--success); color: #fff; }
.btn-sm { min-height: 36px; padding: 6px 12px; font-size: .85rem; border-radius: 10px; }
.btn-lg { min-height: 52px; padding: 14px 24px; font-size: 1.02rem; border-radius: 14px; }
.btn-block { width: 100%; }
.btn .spinner { width: 16px; height: 16px; border: 2px solid currentColor; border-right-color: transparent; border-radius: 50%; animation: spin .7s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.icon { width: 20px; height: 20px; flex: none; stroke: currentColor; fill: none; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.icon-sm { width: 16px; height: 16px; } .icon-lg { width: 28px; height: 28px; }

/* ------------------------------------------------ cards, badges */
.card { background: #fff; border: 1px solid var(--line); border-radius: var(--r-lg); box-shadow: var(--sh-1); }
.card-pad { padding: 20px; } @media (max-width: 680px) { .card-pad { padding: 16px; } }
.card-hover { transition: transform var(--t) var(--ease), box-shadow var(--t) var(--ease), border-color var(--t); }
.card-hover:hover { transform: translateY(-3px); box-shadow: var(--sh-2); border-color: #cfdbee; }
.card-title { font-weight: 650; font-size: 1.02rem; margin: 0 0 4px; }
.surface { background: var(--surface); border-radius: var(--r-lg); }
.badge { display: inline-flex; align-items: center; gap: 6px; padding: 3px 10px; border-radius: 999px; font-size: .78rem; font-weight: 600; line-height: 1.5; white-space: nowrap; }
.badge::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: currentColor; opacity: .85; }
.badge.plain::before { display: none; }
.tone-neutral { background: var(--surface-2); color: #475569; }
.tone-info { background: var(--info-50); color: var(--primary-700); }
.tone-success { background: var(--success-50); color: var(--success); }
.tone-warning { background: var(--warning-50); color: var(--warning); }
.tone-danger { background: var(--danger-50); color: var(--danger); }
.tone-accent { background: var(--accent-50); color: #7a5a00; }
.chip { display: inline-flex; align-items: center; gap: 6px; min-height: 36px; padding: 6px 14px; border-radius: 999px; border: 1px solid var(--line); background: #fff; color: var(--ink); font-size: .88rem; cursor: pointer; transition: all var(--t-fast); }
.chip:hover { border-color: var(--primary); color: var(--primary); text-decoration: none; }
.chip.is-active { background: var(--ink); color: #fff; border-color: var(--ink); }
.alert { padding: 14px 16px; border-radius: var(--r); display: flex; gap: 12px; align-items: flex-start; border: 1px solid transparent; }
.alert .icon { margin-top: 2px; }
.alert-info { background: var(--info-50); border-color: var(--primary-100); }
.alert-warning { background: var(--warning-50); border-color: #f4dfae; }
.alert-danger { background: var(--danger-50); border-color: #f5c9c9; }
.alert-success { background: var(--success-50); border-color: #bfe5cd; }
.divider { height: 1px; background: var(--line); margin: 16px 0; border: 0; }
.kbd { font-family: ui-monospace, Consolas, monospace; background: var(--surface-2); border: 1px solid var(--line); border-radius: 6px; padding: 1px 6px; font-size: .82rem; }
.mono { font-family: ui-monospace, Consolas, monospace; }

/* ------------------------------------------------ forms */
.field { display: flex; flex-direction: column; gap: 6px; }
.field + .field { margin-top: 16px; }
.label { font-weight: 600; font-size: .92rem; }
.label .req { color: var(--danger); margin-left: 2px; }
.help { color: var(--muted); font-size: .84rem; }
.explain { display: inline-flex; gap: 6px; align-items: flex-start; font-size: .82rem; color: var(--primary-700); background: var(--primary-50); padding: 6px 10px; border-radius: 8px; }
.error-text { color: var(--danger); font-size: .85rem; font-weight: 500; display: flex; gap: 6px; align-items: center; }
.input, .select, .textarea { width: 100%; min-height: 46px; padding: 10px 14px; border: 1.5px solid #d3dcea; border-radius: var(--r); background: #fff; font: 400 .98rem var(--font); color: var(--ink); transition: border-color var(--t-fast), box-shadow var(--t-fast); }
.textarea { min-height: 110px; resize: vertical; }
.input:hover, .select:hover, .textarea:hover { border-color: #b8c6dd; }
.input:focus, .select:focus, .textarea:focus { outline: none; border-color: var(--primary); box-shadow: 0 0 0 4px rgba(36,87,197,.15); }
.has-error .input, .has-error .select, .has-error .textarea, .has-error .combobox-input { border-color: var(--danger); }
.input-group { position: relative; }
.input-group .prefix { position: absolute; left: 14px; top: 50%; transform: translateY(-50%); color: var(--muted); font-weight: 600; }
.input-group .input { padding-left: 34px; }
.form-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px 18px; }
.form-grid .span-2 { grid-column: span 2; }
.form-grid .field + .field { margin-top: 0; }
@media (max-width: 680px) { .form-grid { grid-template-columns: 1fr; } .form-grid .span-2 { grid-column: auto; } }

/* toggle */
.toggle { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 12px 14px; border: 1.5px solid var(--line); border-radius: var(--r); cursor: pointer; background: #fff; transition: border-color var(--t-fast), background var(--t-fast); min-height: 52px; }
.toggle:hover { border-color: #c5d2e6; }
.toggle input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.toggle .track { position: relative; width: 48px; height: 28px; border-radius: 999px; background: #cbd5e1; flex: none; transition: background var(--t) var(--ease); }
.toggle .track::after { content: ""; position: absolute; top: 3px; left: 3px; width: 22px; height: 22px; border-radius: 50%; background: #fff; box-shadow: 0 1px 3px rgba(0,0,0,.25); transition: transform var(--t) var(--ease); }
.toggle input:checked + .track { background: var(--primary); }
.toggle input:checked + .track::after { transform: translateX(20px); }
.toggle input:focus-visible + .track { outline: 3px solid var(--primary); outline-offset: 2px; }
.toggle:has(input:checked) { border-color: var(--primary-100); background: var(--primary-50); }

/* radios as cards */
.choice-list { display: grid; gap: 10px; }
.choice-list.cols-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); } @media (max-width: 680px) { .choice-list.cols-2 { grid-template-columns: 1fr; } }
.choice { position: relative; display: flex; gap: 12px; align-items: center; padding: 12px 14px; border: 1.5px solid var(--line); border-radius: var(--r); cursor: pointer; min-height: 52px; transition: all var(--t-fast); background: #fff; }
.choice:hover { border-color: #c5d2e6; }
.choice input { width: 20px; height: 20px; accent-color: var(--primary); flex: none; margin: 0; }
.choice:has(input:checked) { border-color: var(--primary); background: var(--primary-50); box-shadow: 0 0 0 3px rgba(36,87,197,.08); }
.check { display: flex; gap: 12px; align-items: flex-start; padding: 12px 14px; border: 1.5px solid var(--line); border-radius: var(--r); cursor: pointer; }
.check input { width: 22px; height: 22px; margin-top: 1px; accent-color: var(--primary); flex: none; }
.check:has(input:checked) { border-color: var(--success); background: var(--success-50); }

/* combobox */
.combobox { position: relative; }
.combobox-input { padding-right: 40px !important; }
.combobox-toggle { position: absolute; right: 6px; top: 6px; width: 34px; height: 34px; border: 0; background: transparent; border-radius: 8px; color: var(--muted); cursor: pointer; display: grid; place-items: center; }
.combobox-list { position: absolute; z-index: 40; left: 0; right: 0; top: calc(100% + 6px); background: #fff; border: 1px solid var(--line); border-radius: var(--r); box-shadow: var(--sh-3); max-height: 290px; overflow: auto; padding: 6px; margin: 0; list-style: none; animation: pop var(--t) var(--ease); }
.combobox-list[hidden] { display: none; }
.combobox-option { padding: 10px 12px; border-radius: 8px; cursor: pointer; font-size: .94rem; display: flex; gap: 8px; align-items: center; }
.combobox-option[aria-selected="true"], .combobox-option:hover { background: var(--primary-50); color: var(--primary-700); }
.combobox-option mark { background: var(--accent-50); color: inherit; border-radius: 3px; padding: 0 1px; }
.combobox-empty { padding: 12px; color: var(--muted); font-size: .9rem; }
.combobox-manual { border-top: 1px solid var(--line); margin-top: 4px; padding-top: 6px; }
@keyframes pop { from { opacity: 0; transform: translateY(-4px) scale(.98); } to { opacity: 1; transform: none; } }

/* repeater */
.repeater { border: 1.5px dashed #cdd8ea; border-radius: var(--r); padding: 12px; background: #fbfcfe; }
.repeater-row { background: #fff; border: 1px solid var(--line); border-radius: 10px; padding: 12px; display: grid; grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); gap: 10px; position: relative; animation: pop var(--t) var(--ease); }
.repeater-row + .repeater-row { margin-top: 10px; }
.repeater-row .field + .field { margin-top: 0; }
.repeater-row .row-index { position: absolute; top: -10px; left: 10px; background: var(--ink); color: #fff; font-size: .72rem; border-radius: 999px; padding: 1px 8px; }
.repeater-remove { position: absolute; top: 6px; right: 6px; }

/* stepper */
.stepper { display: flex; gap: 6px; list-style: none; margin: 0; padding: 0; counter-reset: s; overflow-x: auto; scrollbar-width: none; }
.stepper::-webkit-scrollbar { display: none; }
.stepper li { flex: 1 1 0; min-width: 110px; }
.stepper a, .stepper span { display: flex; flex-direction: column; gap: 6px; font-size: .8rem; color: var(--muted); text-decoration: none; padding-top: 10px; border-top: 4px solid var(--line); transition: border-color var(--t); }
.stepper .num { font-weight: 700; font-size: .75rem; letter-spacing: .04em; text-transform: uppercase; }
.stepper .done a, .stepper .done span { border-color: var(--success); color: var(--ink); }
.stepper .current a, .stepper .current span { border-color: var(--primary); color: var(--ink); font-weight: 600; }
@media (max-width: 680px) { .stepper li { min-width: 60px; } .stepper .txt { display: none; } .stepper .current .txt { display: block; } .stepper .current { min-width: 150px; } }

/* dropzone */
.req-card { border: 1.5px solid var(--line); border-radius: var(--r-lg); background: #fff; padding: 16px; transition: border-color var(--t), box-shadow var(--t); }
.req-card.is-done { border-color: #bfe5cd; }
.req-card.is-observed { border-color: #f1c98c; background: #fffcf5; }
.req-card.is-drag { border-color: var(--primary); box-shadow: 0 0 0 4px rgba(36,87,197,.12); }
.req-card + .req-card { margin-top: 12px; }
.req-head { display: flex; justify-content: space-between; gap: 12px; align-items: flex-start; }
.req-title { font-weight: 600; }
.req-meta { display: flex; flex-wrap: wrap; gap: 6px 12px; font-size: .8rem; color: var(--muted); margin-top: 6px; }
.dropzone { margin-top: 12px; border: 2px dashed #c8d4e8; border-radius: var(--r); padding: 18px; text-align: center; background: var(--surface); transition: all var(--t-fast); }
.dropzone.is-over { background: var(--primary-50); border-color: var(--primary); transform: scale(1.01); }
.dropzone .actions { display: flex; gap: 8px; justify-content: center; flex-wrap: wrap; margin-top: 10px; }
.file-pill { display: flex; align-items: center; gap: 12px; margin-top: 12px; padding: 10px 12px; background: var(--surface); border-radius: 10px; }
.file-pill .thumb { width: 44px; height: 44px; border-radius: 8px; background: #fff; border: 1px solid var(--line); display: grid; place-items: center; overflow: hidden; flex: none; }
.file-pill .thumb img { width: 100%; height: 100%; object-fit: cover; }
.file-pill .info { min-width: 0; flex: 1; }
.file-pill .name { font-weight: 600; font-size: .9rem; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.progress { height: 6px; border-radius: 999px; background: var(--surface-2); overflow: hidden; }
.progress > span { display: block; height: 100%; background: linear-gradient(90deg, var(--primary), #5b8def); border-radius: inherit; transition: width var(--t) var(--ease); }

/* camera */
.camera-stage { position: relative; background: #0b1726; border-radius: var(--r-lg); overflow: hidden; aspect-ratio: 4/3; display: grid; place-items: center; }
.camera-stage video, .camera-stage canvas, .camera-stage img { width: 100%; height: 100%; object-fit: cover; }
.camera-frame { position: absolute; inset: 12% 10%; border: 3px solid rgba(255,255,255,.9); border-radius: 18px; box-shadow: 0 0 0 999px rgba(11,23,38,.45); pointer-events: none; }
.camera-frame.face { inset: 10% 26%; border-radius: 50% / 45%; }
.camera-hint { position: absolute; bottom: 12px; left: 0; right: 0; text-align: center; color: #fff; font-size: .9rem; text-shadow: 0 1px 3px rgba(0,0,0,.6); }
.camera-controls { display: flex; gap: 10px; justify-content: center; flex-wrap: wrap; margin-top: 14px; }
.shutter { width: 68px; height: 68px; border-radius: 50%; border: 5px solid #fff; background: var(--primary); box-shadow: 0 0 0 3px var(--primary); cursor: pointer; transition: transform var(--t-fast); }
.shutter:active { transform: scale(.92); }

/* tabs */
.tabs { display: flex; gap: 4px; border-bottom: 1px solid var(--line); overflow-x: auto; scrollbar-width: none; }
.tab { padding: 12px 14px; border: 0; background: none; font: 600 .92rem var(--font); color: var(--muted); cursor: pointer; border-bottom: 3px solid transparent; margin-bottom: -1px; white-space: nowrap; min-height: 44px; }
.tab[aria-selected="true"] { color: var(--ink); border-color: var(--primary); }
.tab-panel[hidden] { display: none; }
.tab-panel { animation: fadeUp var(--t) var(--ease); }
@keyframes fadeUp { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }

/* modal & drawer */
.modal-backdrop { position: fixed; inset: 0; background: rgba(11,23,38,.55); backdrop-filter: blur(3px); z-index: 200; display: grid; place-items: center; padding: 16px; animation: fade var(--t) var(--ease); }
.modal-backdrop[hidden] { display: none; }
.modal { background: #fff; border-radius: var(--r-xl); width: min(620px, 100%); max-height: calc(100vh - 32px); overflow: auto; box-shadow: var(--sh-3); animation: modalIn 260ms var(--ease); }
.modal.wide { width: min(860px, 100%); }
.modal-head { display: flex; justify-content: space-between; align-items: center; padding: 18px 20px; border-bottom: 1px solid var(--line); position: sticky; top: 0; background: #fff; z-index: 2; }
.modal-head h2 { font-size: 1.15rem; margin: 0; }
.modal-body { padding: 20px; }
.modal-foot { padding: 14px 20px; border-top: 1px solid var(--line); display: flex; justify-content: flex-end; gap: 10px; flex-wrap: wrap; position: sticky; bottom: 0; background: #fff; }
@keyframes fade { from { opacity: 0; } to { opacity: 1; } }
@keyframes modalIn { from { opacity: 0; transform: translateY(18px) scale(.97); } to { opacity: 1; transform: none; } }
@media (max-width: 680px) { .modal-backdrop { align-items: end; padding: 0; } .modal { border-radius: 22px 22px 0 0; max-height: 92vh; } }
.icon-btn { width: 40px; height: 40px; display: grid; place-items: center; border-radius: 10px; border: 0; background: transparent; cursor: pointer; color: var(--muted); }
.icon-btn:hover { background: var(--surface); color: var(--ink); }

/* toasts */
.toasts { pointer-events: none; position: fixed; right: 16px; bottom: 16px; z-index: 300; display: flex; flex-direction: column; gap: 10px; max-width: min(420px, calc(100vw - 32px)); }
.toast { background: var(--ink); color: #fff; padding: 14px 16px; border-radius: var(--r); box-shadow: var(--sh-3); display: flex; gap: 10px; align-items: flex-start; animation: toastIn 300ms var(--ease); font-size: .92rem; }
.toast.success { background: #0f5132; } .toast.error { background: #7f1d1d; } .toast.warning { background: #7a4d00; }
.toast.leaving { animation: toastOut 250ms var(--ease) forwards; }
@keyframes toastIn { from { opacity: 0; transform: translateY(12px) scale(.96); } to { opacity: 1; transform: none; } }
@keyframes toastOut { to { opacity: 0; transform: translateX(30px); } }
@media (max-width: 760px) { .toasts { bottom: 84px; left: 16px; right: 16px; max-width: none; } }

/* save indicator */
.save-state { display: inline-flex; align-items: center; gap: 6px; font-size: .82rem; color: var(--muted); }
.save-state .dotx { width: 8px; height: 8px; border-radius: 50%; background: var(--success); }
.save-state.saving .dotx { background: var(--accent); animation: pulse 1.2s infinite; }
.save-state.error .dotx { background: var(--danger); }

/* timeline */
.timeline { list-style: none; margin: 0; padding: 0; position: relative; }
.timeline::before { content: ""; position: absolute; left: 11px; top: 6px; bottom: 6px; width: 2px; background: var(--line); }
.timeline li { position: relative; padding: 0 0 18px 38px; }
.timeline li::before { content: ""; position: absolute; left: 4px; top: 4px; width: 16px; height: 16px; border-radius: 50%; background: #fff; border: 3px solid var(--primary); }
.timeline li.t-warn::before { border-color: var(--warning); } .timeline li.t-ok::before { border-color: var(--success); background: var(--success); } .timeline li.t-bad::before { border-color: var(--danger); }
.timeline li.t-muted::before { border-color: #cbd5e1; }
.timeline .t-title { font-weight: 600; }
.timeline .t-meta { font-size: .8rem; color: var(--muted); }
.timeline .t-desc { font-size: .9rem; margin-top: 3px; color: #334155; }

/* stage progress */
.stages { display: flex; gap: 4px; margin: 10px 0 4px; }
.stages .st { flex: 1; height: 8px; border-radius: 999px; background: var(--surface-2); position: relative; overflow: hidden; }
.stages .st.done { background: var(--success); }
.stages .st.current { background: var(--primary-100); }
.stages .st.current::after { content: ""; position: absolute; inset: 0; background: linear-gradient(90deg, transparent, var(--primary), transparent); animation: shimmer 1.8s infinite; }
@keyframes shimmer { from { transform: translateX(-100%); } to { transform: translateX(100%); } }
.stage-list { list-style: none; padding: 0; margin: 0; display: grid; gap: 8px; }
.stage-list li { display: flex; gap: 10px; align-items: center; font-size: .9rem; }
.stage-list .ic { width: 24px; height: 24px; border-radius: 50%; display: grid; place-items: center; font-size: .75rem; font-weight: 700; flex: none; background: var(--surface-2); color: var(--muted); }
.stage-list .done .ic { background: var(--success); color: #fff; }
.stage-list .current .ic { background: var(--primary); color: #fff; box-shadow: 0 0 0 4px var(--primary-100); }
.stage-list .current { font-weight: 650; }

/* tables */
.table-wrap { overflow-x: auto; border: 1px solid var(--line); border-radius: var(--r-lg); background: #fff; }
.table { width: 100%; border-collapse: collapse; font-size: .92rem; }
.table th { text-align: left; font-size: .74rem; text-transform: uppercase; letter-spacing: .05em; color: var(--muted); padding: 12px 14px; background: var(--surface); border-bottom: 1px solid var(--line); white-space: nowrap; }
.table td { padding: 12px 14px; border-bottom: 1px solid var(--line); vertical-align: middle; }
.table tr:last-child td { border-bottom: 0; }
.table tbody tr { transition: background var(--t-fast); }
.table tbody tr:hover { background: #fafcff; }
.table .num { text-align: right; font-variant-numeric: tabular-nums; }
@media (max-width: 760px) { .table .p3 { display: none; } }
@media (max-width: 520px) { .table .p2 { display: none; } }

/* KPIs */
.kpi { padding: 16px 18px; border-radius: var(--r-lg); background: #fff; border: 1px solid var(--line); display: flex; flex-direction: column; gap: 4px; position: relative; overflow: hidden; }
.kpi .k-label { font-size: .8rem; color: var(--muted); font-weight: 600; }
.kpi .k-value { font-size: 1.7rem; font-weight: 750; letter-spacing: -.02em; font-variant-numeric: tabular-nums; }
.kpi .k-foot { font-size: .78rem; color: var(--muted); }
.kpi.accent::after { content: ""; position: absolute; right: -18px; top: -18px; width: 70px; height: 70px; border-radius: 50%; background: var(--accent-50); }
a.kpi:hover { text-decoration: none; border-color: var(--primary-100); box-shadow: var(--sh-2); }

/* empty */
.empty { text-align: center; padding: 36px 20px; color: var(--muted); }
.empty .icon { width: 44px; height: 44px; margin: 0 auto 10px; color: #9fb0c8; }

/* next action */
.next-action { display: flex; gap: 14px; align-items: center; padding: 16px; border-radius: var(--r-lg); background: linear-gradient(135deg, var(--primary-50), #fff); border: 1px solid var(--primary-100); }
.next-action .na-icon { width: 46px; height: 46px; border-radius: 14px; background: var(--primary); color: #fff; display: grid; place-items: center; flex: none; }
.next-action.warn { background: linear-gradient(135deg, var(--warning-50), #fff); border-color: #f4dfae; }
.next-action.warn .na-icon { background: #d97706; }
.next-action.ok { background: linear-gradient(135deg, var(--success-50), #fff); border-color: #bfe5cd; }
.next-action.ok .na-icon { background: var(--success); }
.next-action .na-body { flex: 1; min-width: 0; }
@media (max-width: 520px) { .next-action { flex-wrap: wrap; } .next-action .btn { width: 100%; } }

/* app shell (portal/admin) */
.shell { display: grid; grid-template-columns: var(--sidebar) minmax(0, 1fr); min-height: calc(100vh - 32px); }
.sidebar { background: #fff; border-right: 1px solid var(--line); padding: 18px 14px; position: sticky; top: 0; height: 100vh; overflow-y: auto; display: flex; flex-direction: column; gap: 6px; }
.sidebar.dark { background: var(--ink); border-color: transparent; color: #cbd6e6; }
.brand { display: flex; align-items: center; gap: 10px; padding: 4px 8px 14px; color: inherit; text-decoration: none !important; }
.brand img { width: 40px; height: 40px; }
.brand b { display: block; font-size: .95rem; line-height: 1.15; color: var(--ink); }
.sidebar.dark .brand b { color: #fff; }
.brand span { font-size: .75rem; color: var(--muted); }
.nav-link { display: flex; align-items: center; gap: 12px; padding: 10px 12px; border-radius: 10px; color: #334155; font-weight: 550; font-size: .93rem; text-decoration: none !important; min-height: 44px; transition: background var(--t-fast), color var(--t-fast); }
.nav-link:hover { background: var(--surface); color: var(--ink); }
.nav-link.is-active { background: var(--primary-50); color: var(--primary-700); }
.sidebar.dark .nav-link { color: #b9c6da; }
.sidebar.dark .nav-link:hover { background: rgba(255,255,255,.06); color: #fff; }
.sidebar.dark .nav-link.is-active { background: rgba(241,198,68,.14); color: var(--accent); }
.nav-link .count { margin-left: auto; background: var(--primary); color: #fff; font-size: .72rem; padding: 1px 8px; border-radius: 999px; }
.sidebar.dark .nav-link .count { background: var(--accent); color: var(--ink); }
.nav-section { font-size: .7rem; text-transform: uppercase; letter-spacing: .08em; color: #94a3b8; padding: 14px 12px 4px; }
.main { min-width: 0; max-width: 100%; display: flex; flex-direction: column; overflow-x: clip; }
.topbar { display: flex; align-items: center; gap: 12px; padding: 12px 24px; border-bottom: 1px solid var(--line); background: rgba(255,255,255,.9); backdrop-filter: blur(8px); position: sticky; top: 0; z-index: 50; }
.topbar .spacer { flex: 1; }
.page { padding: 24px; max-width: 1280px; width: 100%; }
.page-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 16px; flex-wrap: wrap; margin-bottom: 20px; }
.page-head h1 { margin: 0; }
.crumbs { font-size: .82rem; color: var(--muted); margin-bottom: 6px; }
.avatar { width: 38px; height: 38px; border-radius: 50%; background: linear-gradient(135deg, var(--primary), #5b8def); color: #fff; display: grid; place-items: center; font-weight: 700; font-size: .85rem; flex: none; }
.avatar.gold { background: linear-gradient(135deg, #e9b925, var(--accent)); color: var(--ink); }
.menu-btn { display: none; }
.bottom-nav { display: none; }
@media (max-width: 960px) {
  .shell { grid-template-columns: minmax(0, 1fr); }
  .sidebar { position: fixed; left: 0; top: 0; bottom: 0; width: 290px; z-index: 150; transform: translateX(-105%); transition: transform 260ms var(--ease); box-shadow: var(--sh-3); }
  .sidebar.open { transform: none; }
  .sidebar-backdrop { position: fixed; inset: 0; background: rgba(11,23,38,.45); z-index: 140; }
  .menu-btn { display: grid; }
  .topbar { padding: 10px 16px; }
  .page { padding: 16px; padding-bottom: 96px; }
  .bottom-nav { display: flex; position: fixed; bottom: 0; left: 0; right: 0; z-index: 90; background: #fff; border-top: 1px solid var(--line); padding: 6px 6px calc(6px + env(safe-area-inset-bottom)); justify-content: space-around; }
  .bottom-nav a { display: flex; flex-direction: column; align-items: center; gap: 2px; font-size: .68rem; color: var(--muted); padding: 6px 8px; border-radius: 10px; min-width: 60px; min-height: 48px; text-decoration: none; }
  .bottom-nav a.is-active { color: var(--primary); background: var(--primary-50); }
}
.dropdown { position: relative; }
.dropdown-menu { position: absolute; right: 0; top: calc(100% + 8px); min-width: 280px; background: #fff; border: 1px solid var(--line); border-radius: var(--r-lg); box-shadow: var(--sh-3); padding: 8px; z-index: 120; animation: pop var(--t) var(--ease); max-height: 70vh; overflow: auto; }
.dropdown-menu[hidden] { display: none; }
.dropdown-item { display: flex; gap: 10px; align-items: center; width: 100%; text-align: left; padding: 9px 10px; border-radius: 8px; border: 0; background: none; font: inherit; font-size: .9rem; color: var(--ink); cursor: pointer; text-decoration: none !important; }
.dropdown-item:hover { background: var(--surface); }
.dropdown-label { font-size: .7rem; text-transform: uppercase; letter-spacing: .07em; color: var(--muted); padding: 8px 10px 4px; }

/* guide */
.guide { position: relative; background: linear-gradient(120deg, var(--ink), #1e3b64); color: #e4ecf8; border-radius: var(--r-lg); padding: 16px 18px; overflow: hidden; }
.guide::after { content: ""; position: absolute; right: -40px; top: -40px; width: 160px; height: 160px; border-radius: 50%; background: radial-gradient(circle, rgba(241,198,68,.35), transparent 70%); }
.guide h3 { color: #fff; margin-bottom: 8px; font-size: 1rem; }
.guide ol { margin: 0; padding-left: 18px; display: grid; gap: 4px; font-size: .9rem; }
.guide .close { position: absolute; top: 8px; right: 8px; color: #cbd6e6; z-index: 2; }

/* split review */
.split { display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr); gap: 18px; align-items: start; }
.split > .sticky { position: sticky; top: 76px; }
.split.split-main { grid-template-columns: minmax(0, 1.65fr) minmax(0, 1fr); }
.filters-grid { grid-template-columns: 2fr 1fr 1fr; }
@media (max-width: 1100px) { .split, .split.split-main { grid-template-columns: minmax(0, 1fr); } .split > .sticky { position: static; } }
@media (max-width: 680px) { .filters-grid { grid-template-columns: 1fr; } [style*="grid-column:span 2"] { grid-column: auto !important; } .choice-list[style*="grid-template-columns"] { grid-template-columns: 1fr !important; } }
.viewer { border-radius: var(--r-lg); overflow: hidden; background: #0b1726; min-height: 420px; display: flex; flex-direction: column; }
.viewer-bar { display: flex; justify-content: space-between; align-items: center; gap: 10px; padding: 10px 14px; color: #dbe6fb; font-size: .85rem; background: #122238; flex-wrap: wrap; }
.viewer-body { flex: 1; display: grid; place-items: center; min-height: 480px; background: repeating-conic-gradient(#0f1d30 0% 25%, #0c192a 0% 50%) 50% / 24px 24px; }
.viewer-body iframe { width: 100%; height: 640px; border: 0; background: #fff; }
.viewer-body img { max-height: 640px; object-fit: contain; transition: transform var(--t) var(--ease); }
.compare { display: grid; grid-template-columns: 1fr 1fr; gap: 2px; width: 100%; }
.compare figure { margin: 0; background: #0b1726; }
.compare figcaption { color: #dbe6fb; font-size: .78rem; padding: 6px 10px; }
.req-review { border: 1px solid var(--line); border-radius: var(--r); padding: 12px; cursor: pointer; transition: all var(--t-fast); background: #fff; }
.req-review:hover { border-color: #c5d2e6; }
.req-review.is-current { border-color: var(--primary); box-shadow: 0 0 0 3px rgba(36,87,197,.12); }
.req-review + .req-review { margin-top: 8px; }
.seg { display: inline-flex; border: 1px solid var(--line); border-radius: 10px; overflow: hidden; }
.seg button { border: 0; background: #fff; padding: 8px 10px; font: 600 .8rem var(--font); cursor: pointer; color: var(--muted); min-height: 36px; }
.seg button + button { border-left: 1px solid var(--line); }
.seg button.on-accepted { background: var(--success-50); color: var(--success); }
.seg button.on-observed { background: var(--warning-50); color: var(--warning); }
.seg button.on-pending { background: var(--surface-2); color: var(--ink); }
.seg button.on-not_applicable { background: var(--surface-2); color: var(--ink); }

/* kanban */
.kanban { display: grid; grid-auto-flow: column; grid-auto-columns: minmax(260px, 1fr); gap: 12px; overflow-x: auto; padding-bottom: 8px; }
.k-col { background: var(--surface); border-radius: var(--r-lg); padding: 10px; min-height: 300px; display: flex; flex-direction: column; gap: 8px; transition: background var(--t-fast), box-shadow var(--t-fast); }
.k-col.is-over { background: var(--primary-50); box-shadow: inset 0 0 0 2px var(--primary); }
.k-col.is-denied { background: var(--danger-50); box-shadow: inset 0 0 0 2px var(--danger); }
.k-col h3 { font-size: .85rem; margin: 4px 6px 4px; display: flex; justify-content: space-between; }
.k-card { background: #fff; border: 1px solid var(--line); border-radius: 12px; padding: 12px; cursor: grab; box-shadow: var(--sh-1); transition: transform var(--t-fast), box-shadow var(--t-fast); }
.k-card:hover { box-shadow: var(--sh-2); }
.k-card.dragging { opacity: .5; transform: rotate(2deg); }
.k-card.bounce { animation: bounceBack 420ms var(--ease); }
@keyframes bounceBack { 0% { transform: translateX(0); } 25% { transform: translateX(-8px); } 50% { transform: translateX(6px); } 75% { transform: translateX(-3px); } 100% { transform: none; } }

/* notifications preview: WhatsApp & email */
.phone { width: 340px; max-width: 100%; margin: 0 auto; background: #0b1726; border-radius: 42px; padding: 12px; box-shadow: var(--sh-3), inset 0 0 0 2px #2a3a52; }
.phone-screen { border-radius: 32px; overflow: hidden; background: #efe7dd; height: 600px; display: flex; flex-direction: column; }
.wa-head { background: #075e54; color: #fff; padding: 34px 14px 12px; display: flex; align-items: center; gap: 10px; }
.wa-head .wa-av { width: 36px; height: 36px; border-radius: 50%; background: #fff; display: grid; place-items: center; overflow: hidden; }
.wa-head b { display: block; font-size: .92rem; }
.wa-head small { opacity: .8; font-size: .72rem; }
.wa-body { flex: 1; padding: 14px 10px; overflow-y: auto; background-color: #efe7dd; background-image: radial-gradient(rgba(0,0,0,.035) 1px, transparent 1px); background-size: 14px 14px; display: flex; flex-direction: column; gap: 8px; }
.wa-day { align-self: center; background: #e1f2fb; color: #3c5566; font-size: .7rem; padding: 3px 10px; border-radius: 8px; }
.wa-bubble { align-self: flex-start; background: #fff; border-radius: 0 10px 10px 10px; padding: 8px 10px 4px; max-width: 86%; box-shadow: 0 1px 1px rgba(0,0,0,.12); font-size: .86rem; color: #111b21; animation: bubbleIn 380ms var(--ease) both; }
.wa-bubble .wa-meta { text-align: right; font-size: .66rem; color: #667781; margin-top: 2px; display: flex; gap: 4px; justify-content: flex-end; align-items: center; }
.wa-bubble .wa-btn { display: block; text-align: center; border-top: 1px solid #e9edef; margin: 8px -10px 0; padding: 8px 10px 6px; color: #027eb5; font-weight: 600; font-size: .85rem; }
.ticks { color: #8696a0; letter-spacing: -3px; } .ticks.read { color: #53bdeb; }
@keyframes bubbleIn { from { opacity: 0; transform: translateY(10px) scale(.96); } to { opacity: 1; transform: none; } }
.email-frame { border: 1px solid var(--line); border-radius: var(--r-lg); overflow: hidden; background: #fff; }
.email-head { padding: 14px 16px; border-bottom: 1px solid var(--line); background: var(--surface); font-size: .85rem; display: grid; gap: 3px; }
.email-head .subj { font-weight: 700; font-size: 1rem; color: var(--ink); }
.email-frame iframe { width: 100%; height: 520px; border: 0; display: block; }
.preview-note { display: flex; gap: 8px; align-items: center; justify-content: center; font-size: .82rem; color: var(--warning); background: var(--warning-50); padding: 8px 12px; border-radius: 10px; margin-bottom: 14px; }

/* checkout */
.checkout { display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr); gap: 20px; align-items: start; }
@media (max-width: 900px) { .checkout { grid-template-columns: 1fr; } }
.sim-banner { background: repeating-linear-gradient(-45deg, var(--accent-50), var(--accent-50) 12px, #fbefc0 12px, #fbefc0 24px); border: 1px solid #efd98a; color: #6b4f00; padding: 12px 14px; border-radius: var(--r); font-weight: 650; display: flex; gap: 10px; align-items: center; }
.card-visual { aspect-ratio: 1.586; max-width: 360px; border-radius: 18px; padding: 20px; color: #fff; background: linear-gradient(135deg, #1e3b64, var(--primary) 60%, #5b8def); position: relative; overflow: hidden; box-shadow: var(--sh-3); display: flex; flex-direction: column; justify-content: space-between; transition: transform 500ms var(--ease); }
.card-visual::before { content: ""; position: absolute; width: 260px; height: 260px; border-radius: 50%; right: -90px; top: -120px; background: rgba(255,255,255,.12); }
.card-visual .chip-c { width: 42px; height: 32px; border-radius: 6px; background: linear-gradient(135deg, #f7d86a, #c9a227); }
.card-visual .pan { font-family: ui-monospace, Consolas, monospace; font-size: 1.2rem; letter-spacing: .12em; }
.card-visual .demo-tag { position: absolute; right: 16px; top: 16px; background: rgba(0,0,0,.25); padding: 3px 8px; border-radius: 999px; font-size: .7rem; font-weight: 700; }
.card-option { display: flex; align-items: center; gap: 12px; }
.card-option .last4 { font-family: ui-monospace, Consolas, monospace; font-weight: 700; }
.pay-state { text-align: center; padding: 30px 16px; }
.pay-state .big-icon { width: 76px; height: 76px; border-radius: 50%; display: grid; place-items: center; margin: 0 auto 14px; }
.pay-state .big-icon.ok { background: var(--success-50); color: var(--success); animation: popIn 500ms var(--ease); }
.pay-state .big-icon.bad { background: var(--danger-50); color: var(--danger); animation: shake 500ms var(--ease); }
.pay-state .big-icon.wait { background: var(--primary-50); color: var(--primary); }
.pay-state .big-icon .icon { width: 38px; height: 38px; }
@keyframes popIn { 0% { transform: scale(.4); opacity: 0; } 60% { transform: scale(1.12); opacity: 1; } 100% { transform: scale(1); } }
@keyframes shake { 0%,100% { transform: none; } 20% { transform: translateX(-8px); } 40% { transform: translateX(8px); } 60% { transform: translateX(-5px); } 80% { transform: translateX(5px); } }
.ring { width: 64px; height: 64px; border-radius: 50%; border: 5px solid var(--primary-100); border-top-color: var(--primary); animation: spin .9s linear infinite; margin: 0 auto 16px; }
.summary-line { display: flex; justify-content: space-between; gap: 12px; padding: 8px 0; border-bottom: 1px dashed var(--line); font-size: .92rem; }
.summary-line.total { border-bottom: 0; font-weight: 750; font-size: 1.15rem; padding-top: 12px; }

/* auth */
.auth-wrap { min-height: calc(100vh - 32px); display: grid; grid-template-columns: 1fr 1fr; }
.auth-side { background: radial-gradient(1200px 600px at -10% -10%, #2b62d6 0%, transparent 60%), radial-gradient(800px 500px at 110% 120%, rgba(241,198,68,.35), transparent 60%), var(--ink); color: #dbe6fb; padding: 48px; display: flex; flex-direction: column; justify-content: space-between; position: relative; overflow: hidden; }
.auth-side h2 { color: #fff; font-size: 2rem; }
.auth-main { display: grid; place-items: center; padding: 32px 20px; }
.auth-card { width: min(460px, 100%); }
@media (max-width: 900px) { .auth-wrap { grid-template-columns: 1fr; } .auth-side { display: none; } }
.otp { display: flex; gap: 8px; justify-content: space-between; }
.otp input { width: 100%; max-width: 56px; height: 60px; text-align: center; font-size: 1.5rem; font-weight: 700; border: 1.5px solid #d3dcea; border-radius: 12px; }
.otp input:focus { outline: none; border-color: var(--primary); box-shadow: 0 0 0 4px rgba(36,87,197,.15); }
.progress-steps { display: flex; gap: 6px; margin-bottom: 18px; }
.progress-steps span { flex: 1; height: 5px; border-radius: 999px; background: var(--surface-2); }
.progress-steps span.on { background: var(--primary); }

/* misc */
.dl { display: grid; grid-template-columns: minmax(120px, 40%) 1fr; gap: 8px 14px; font-size: .92rem; margin: 0; }
.dl dt { color: var(--muted); }
.dl dd { margin: 0; font-weight: 550; overflow-wrap: anywhere; }
@media (max-width: 520px) { .dl { grid-template-columns: 1fr; gap: 2px; } .dl dd { margin-bottom: 8px; } }
.list-plain { list-style: none; padding: 0; margin: 0; }
.list-plain > li + li { border-top: 1px solid var(--line); }
.item-link { display: flex; gap: 14px; align-items: center; padding: 14px 4px; color: inherit; text-decoration: none !important; border-radius: 10px; transition: background var(--t-fast); }
.item-link:hover { background: var(--surface); }
.item-link .grow { flex: 1; min-width: 0; }
.truncate { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pill-icon { width: 42px; height: 42px; border-radius: 12px; background: var(--primary-50); color: var(--primary); display: grid; place-items: center; flex: none; }
.pill-icon.gold { background: var(--accent-50); color: #8a6500; }
.pill-icon.green { background: var(--success-50); color: var(--success); }
.pill-icon.red { background: var(--danger-50); color: var(--danger); }
.qr-box { background: #fff; padding: 12px; border-radius: 16px; display: inline-block; box-shadow: var(--sh-2); }
.qr-box img { width: 180px; height: 180px; image-rendering: pixelated; }
.source-note { font-size: .8rem; color: var(--muted); border-left: 3px solid var(--accent); padding: 6px 10px; background: var(--accent-50); border-radius: 0 8px 8px 0; }
details.faq { border: 1px solid var(--line); border-radius: var(--r); background: #fff; }
details.faq + details.faq { margin-top: 10px; }
details.faq summary { cursor: pointer; padding: 16px 18px; font-weight: 600; list-style: none; display: flex; justify-content: space-between; gap: 12px; }
details.faq summary::-webkit-details-marker { display: none; }
details.faq summary::after { content: "+"; font-size: 1.3rem; line-height: 1; color: var(--primary); transition: transform var(--t); }
details.faq[open] summary::after { transform: rotate(45deg); }
details.faq > div { padding: 0 18px 16px; color: #334155; animation: fadeUp var(--t) var(--ease); }
.skeleton { background: linear-gradient(90deg, var(--surface-2), #f7f9fc, var(--surface-2)); background-size: 200% 100%; animation: sk 1.2s infinite; border-radius: 8px; }
@keyframes sk { from { background-position: 200% 0; } to { background-position: -200% 0; } }
.fade-in { animation: fadeUp 380ms var(--ease) both; }
.stagger > * { animation: fadeUp 420ms var(--ease) both; }
.stagger > *:nth-child(2) { animation-delay: 50ms; } .stagger > *:nth-child(3) { animation-delay: 100ms; } .stagger > *:nth-child(4) { animation-delay: 150ms; }
.stagger > *:nth-child(5) { animation-delay: 200ms; } .stagger > *:nth-child(6) { animation-delay: 250ms; } .stagger > *:nth-child(n+7) { animation-delay: 300ms; }

@view-transition { navigation: auto; }
::view-transition-old(root), ::view-transition-new(root) { animation-duration: 220ms; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; scroll-behavior: auto !important; }
  @view-transition { navigation: none; }
}
@media print { .sidebar, .topbar, .bottom-nav, .demo-banner, .toasts { display: none !important; } .shell { display: block; } }
.table .mono, .table a.mono { white-space: nowrap; }

/* catálogo por categorías dentro del portal */
.cat-tiles { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(300px, 100%), 1fr)); gap: 12px; }
.cat-tile { display: flex; gap: 14px; align-items: center; padding: 16px; background: #fff; border: 1px solid var(--line); border-radius: var(--r-lg); color: var(--ink); text-decoration: none !important; transition: border-color var(--t-fast), box-shadow var(--t), transform var(--t-fast); }
.cat-tile:hover { border-color: var(--primary-100); box-shadow: var(--sh-2); transform: translateY(-2px); }
.cat-tile .grow { flex: 1; min-width: 0; }
.cat-tile b { display: block; }
.cat-tile small { display: block; color: var(--muted); font-size: .82rem; line-height: 1.35; }
.cat-tile .count { font-size: .8rem; font-weight: 700; color: var(--muted); background: var(--surface); border-radius: 999px; padding: 2px 10px; }
.proc-list { background: #fff; border: 1px solid var(--line); border-radius: var(--r-lg); }
.proc-row { display: flex; gap: 14px; align-items: center; padding: 12px 16px; }
.proc-row + .proc-row { border-top: 1px solid var(--line); }
.proc-row .grow { flex: 1; min-width: 0; }
@media (max-width: 700px) { .proc-row { flex-direction: column; align-items: stretch; } .proc-row form { justify-content: flex-end; flex-wrap: wrap !important; } }
