/* Local prospecting panel. Tokens and components from DESIGN.md (light
   theme only, ERP-family look: borders instead of shadows, soft pills).
   Three shells from one HTML (DESIGN.md "Phone and tablet"): the 240px
   sidebar from 1024px, an icon rail from 640px, and on phones an app bar,
   a bottom tab bar and a "Más" sheet. */

:root {
  --canvas: #F4F6FB;
  --surface: #FFFFFF;
  --surface-muted: #F6F8FA;
  --text: #0F1729;
  --text-muted: #5B6472;
  --border: #E1E5EB;
  --primary: #1E4F8A;
  --primary-hover: #183F6E;
  --primary-soft: #E3EAF3;
  --success: #007E35;
  --success-soft: #E8FCEB;
  --success-text: #00672A;
  --warning: #A95B00;
  --warning-soft: #FFF5ED;
  --warning-text: #894800;
  --danger: #D3222C;
  --danger-soft: #FFF4F2;
  --danger-text: #B5001B;
  --info: #006FA9;
  --info-soft: #EEF8FF;
  --info-text: #005E8F;
  --float-shadow: 0 8px 24px rgba(15, 23, 41, .10);
  --focus-ring: 0 0 0 3px rgba(30, 79, 138, .20);
  --font: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", sans-serif;
  --mono: ui-monospace, "SF Mono", "Cascadia Mono", Menlo, monospace;
  --sidebar: 240px;
  --sidebar-collapsed: 68px;
  --rail: 88px;
  --appbar-h: 52px;
  --tabbar-h: 58px;
  --safe-top: env(safe-area-inset-top, 0px);
  --safe-right: env(safe-area-inset-right, 0px);
  --safe-bottom: env(safe-area-inset-bottom, 0px);
  --safe-left: env(safe-area-inset-left, 0px);
  /* Side gutters of the content, and where sticky bottom bars rest (above
     the phone's tab bar; the bottom edge elsewhere). */
  --gutter-l: 32px;
  --gutter-r: 32px;
  --sticky-bottom: 0px;
  /* How far toasts rise to clear the page's sticky action bar. */
  --toast-lift: 0px;
  color-scheme: light;
}

*, *::before, *::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; background: var(--canvas); }

body {
  margin: 0;
  background: var(--canvas);
  color: var(--text);
  font: 400 14px/1.5 var(--font);
  overflow-wrap: break-word;
}

a, button, label, summary, select, input, textarea { -webkit-tap-highlight-color: transparent; }

a { color: var(--primary); text-decoration: none; }
@media (hover: hover) { a:hover { text-decoration: underline; } }
a:not(.btn, .tab, .chip, .foot-link):active { opacity: .65; }
.nav a:active { opacity: 1; }

h1, h2, h3 { margin: 0; font-weight: 600; }
/* DESIGN.md: weights 400/500/600, never 700+ (also inside a 600 title). */
b, strong { font-weight: 600; }

/* The hidden attribute wins over component display rules (app.js shows
   and hides buttons with it). */
[hidden] { display: none !important; }

/* One of two wordings, by screen (phone or not). */
.only-phone { display: none !important; }

code, .mono { font-family: var(--mono); font-size: 13px; }

.num { font-variant-numeric: tabular-nums; }

.muted { color: var(--text-muted); }

.small { font-size: 13px; }

.visually-hidden {
  position: absolute !important;
  width: 1px; height: 1px;
  overflow: hidden; clip: rect(0 0 0 0);
  white-space: nowrap; border: 0; padding: 0; margin: -1px;
}

.icon { flex: none; vertical-align: middle; }

.skip-link {
  position: fixed;
  left: 8px;
  top: -64px;
  z-index: 100;
  padding: 12px 16px;
  border-radius: 8px;
  background: var(--primary);
  color: #fff;
  font-weight: 500;
}
.skip-link:focus { top: calc(8px + var(--safe-top)); outline: none; box-shadow: var(--focus-ring); }

/* ---------- App shell: sidebar (1024px and wider) ---------- */

.nav-toggle { position: absolute; opacity: 0; pointer-events: none; }

.appbar, .tabbar, .nav-button, .short { display: none; }

.sidebar {
  position: fixed;
  inset: 0 auto 0 0;
  width: var(--sidebar);
  background: var(--surface);
  border-right: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  z-index: 40;
  overflow-y: auto;
  overscroll-behavior: contain;
}

.sidebar-logo {
  height: 60px;
  flex: none;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 0 16px;
  font-weight: 600;
  font-size: 16px;
  border-bottom: 1px solid var(--border);
}

.logo-mark {
  width: 32px; height: 32px;
  border-radius: 8px;
  background: var(--primary);
  color: #fff;
  display: grid;
  place-items: center;
  flex: none;
}

.campaign-picker { padding: 12px 16px; border-bottom: 1px solid var(--border); }
.campaign-picker label { display: block; font-size: 12px; font-weight: 500; color: var(--text-muted); margin-bottom: 4px; }
.picker-row { display: flex; gap: 8px; }
.picker-row select { flex: 1; min-width: 0; min-height: 40px; height: 40px; padding: 0 8px; font-size: 13px; }

.nav { padding: 12px 8px; display: flex; flex-direction: column; gap: 2px; flex: 1 0 auto; }

.nav a, .foot-link {
  position: relative;
  height: 40px;
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: flex-start;
  gap: 12px;
  padding: 0 12px;
  border-radius: 8px;
  color: var(--text);
  font: 400 14px/1.2 var(--font);
  transition: background-color 150ms ease-out, color 150ms ease-out;
}
@media (hover: hover) { .nav a:hover, .foot-link:hover { background: var(--surface-muted); text-decoration: none; } }
.nav a:active, .foot-link:active { background: var(--surface-muted); }
.nav a:focus-visible, .foot-link:focus-visible { outline: none; box-shadow: var(--focus-ring); }
.nav a[aria-current="page"], .foot-link[aria-current="page"] { background: var(--primary-soft); color: var(--primary); font-weight: 500; }
.nav a[aria-current="page"]::before {
  content: "";
  position: absolute;
  left: -8px; top: 8px; bottom: 8px;
  width: 3px;
  border-radius: 0 3px 3px 0;
  background: var(--primary);
}

.badge {
  display: inline-grid;
  place-items: center;
  min-width: 20px;
  height: 20px;
  padding: 0 6px;
  border-radius: 999px;
  background: var(--warning);
  color: #fff;
  font: 600 12px/1 var(--font);
  font-variant-numeric: tabular-nums;
}
.nav-badge { margin-left: auto; }

.sidebar-foot { padding: 8px; border-top: 1px solid var(--border); display: flex; flex-direction: column; gap: 2px; }
.sidebar-foot form { margin: 0; }
.sidebar-foot button { width: 100%; justify-content: flex-start; }
.sidebar-foot .btn.foot-link { padding: 0 12px; border: 0; font: 400 14px/1.2 var(--font); }
.collapse-form { display: none; }
.sidebar-user {
  margin: 0;
  padding: 4px 12px;
  font-size: 13px;
  color: var(--text-muted);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  display: flex;
  align-items: center;
  gap: 6px;
}

.content {
  margin-left: var(--sidebar);
  padding: 32px;
  min-height: 100vh;
}
.content-inner { max-width: 1120px; margin: 0 auto; }

.nav-scrim { display: none; }

/* With a mouse the sidebar can shrink to icons (names on hover). */
@media (min-width: 1024px) and (pointer: fine) {
  .collapse-form { display: block; }
  body.nav-collapsed .sidebar { width: var(--sidebar-collapsed); }
  body.nav-collapsed .content { margin-left: var(--sidebar-collapsed); }
  body.nav-collapsed .sidebar .label,
  body.nav-collapsed .campaign-picker,
  body.nav-collapsed .sidebar-user { display: none; }
  body.nav-collapsed .nav a, body.nav-collapsed .foot-link, body.nav-collapsed .sidebar-foot button { justify-content: center; padding: 0; }
  body.nav-collapsed .sidebar-logo { justify-content: center; padding: 0; }
  body.nav-collapsed .nav-badge { position: absolute; top: 2px; right: 4px; min-width: 18px; height: 18px; padding: 0 4px; font-size: 11px; }
}

/* ---------- App shell: icon rail (tablets, 640-1023px) ---------- */

@media (min-width: 640px) and (max-width: 1023.98px) {
  :root { --gutter-l: 24px; --gutter-r: max(24px, var(--safe-right)); }
  .content { margin-left: calc(var(--rail) + var(--safe-left)); padding: 24px var(--gutter-r) 32px 24px; }
  .nav-button {
    display: grid;
    place-items: center;
    width: 48px; height: 48px;
    border-radius: 12px;
    color: var(--text);
    cursor: pointer;
    flex: none;
  }
  .nav-button:active { background: var(--surface-muted); }
  .nav-button .icon + .icon, .nav-toggle:checked ~ .sidebar .nav-button .icon:first-child { display: none; }
  .nav-toggle:checked ~ .sidebar .nav-button .icon + .icon { display: block; }
  .nav-toggle:focus-visible ~ .sidebar .nav-button { box-shadow: var(--focus-ring); }

  .sidebar { padding-left: var(--safe-left); width: calc(var(--rail) + var(--safe-left)); transition: width 180ms ease-out, box-shadow 180ms ease-out; }

  /* Rail: icon over a short label. */
  .nav-toggle:not(:checked) ~ .sidebar .sidebar-logo { justify-content: center; padding: 0; height: 64px; }
  .nav-toggle:not(:checked) ~ .sidebar .logo-mark,
  .nav-toggle:not(:checked) ~ .sidebar .label,
  .nav-toggle:not(:checked) ~ .sidebar .campaign-picker,
  .nav-toggle:not(:checked) ~ .sidebar .sidebar-user { display: none; }
  .nav-toggle:not(:checked) ~ .sidebar .short { display: block; }
  .nav-toggle:not(:checked) ~ .sidebar .nav { padding: 8px; gap: 4px; }
  .nav-toggle:not(:checked) ~ .sidebar :is(.nav a, .foot-link) {
    flex-direction: column;
    justify-content: center;
    gap: 4px;
    height: auto;
    min-height: 60px;
    padding: 8px 2px;
    border-radius: 12px;
    font-size: 12px;
    font-weight: 500;
    text-align: center;
    color: var(--text-muted);
  }
  .nav-toggle:not(:checked) ~ .sidebar :is(.nav a, .foot-link)[aria-current="page"] { color: var(--primary); }
  .nav-toggle:not(:checked) ~ .sidebar :is(.nav a, .foot-link) .icon { width: 22px; height: 22px; color: var(--text); }
  .nav-toggle:not(:checked) ~ .sidebar :is(.nav a, .foot-link)[aria-current="page"] .icon { color: var(--primary); }
  .nav-toggle:not(:checked) ~ .sidebar .nav a[aria-current="page"]::before { left: -8px; top: 14px; bottom: 14px; }
  .nav-toggle:not(:checked) ~ .sidebar .nav-badge { position: absolute; top: 4px; left: calc(50% + 4px); margin: 0; box-shadow: 0 0 0 2px var(--surface); }

  /* Expanded: the full menu over the content. */
  .nav-toggle:checked ~ .sidebar { width: calc(280px + var(--safe-left)); box-shadow: var(--float-shadow); }
  .nav-toggle:checked ~ .sidebar .sidebar-logo { padding-left: 8px; gap: 8px; }
  .nav-toggle:checked ~ .sidebar :is(.nav a, .foot-link) { height: 48px; font-size: 15px; }
  .nav-toggle:checked ~ .nav-scrim { display: block; position: fixed; inset: 0; background: rgba(15, 23, 41, .25); z-index: 35; }
  body:has(.nav-toggle:checked) { overflow: hidden; }
}

/* ---------- App shell: phones (below 640px) ---------- */

@media (max-width: 639.98px) {
  :root {
    --gutter-l: max(16px, var(--safe-left));
    --gutter-r: max(16px, var(--safe-right));
    --sticky-bottom: calc(var(--tabbar-h) + var(--safe-bottom));
  }
  body { font-size: 15px; }

  .appbar {
    display: flex;
    position: sticky;
    top: 0;
    z-index: 25;
    align-items: center;
    gap: 12px;
    min-height: calc(var(--appbar-h) + var(--safe-top));
    padding: var(--safe-top) var(--gutter-r) 0 var(--gutter-l);
    background: var(--surface);
    border-bottom: 1px solid var(--border);
  }
  .appbar-text { flex: 1; min-width: 0; display: flex; flex-direction: column; justify-content: center; }
  .appbar-title { font-size: 17px; font-weight: 600; line-height: 1.25; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
  .appbar-campaign { font-size: 12px; line-height: 1.3; color: var(--text-muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
  .appbar-status {
    flex: none;
    display: inline-flex;
    align-items: center;
    gap: 4px;
    height: 26px;
    padding: 0 10px;
    border-radius: 999px;
    background: var(--danger-soft);
    color: var(--danger-text);
    font-size: 12px;
    font-weight: 500;
  }

  /* "Más": the sidebar as a bottom sheet. Hidden (not focusable) while
     closed. */
  .sidebar {
    inset: auto 0 0 0;
    width: auto;
    max-height: calc(100vh - var(--safe-top) - 32px);
    max-height: calc(100dvh - var(--safe-top) - 32px);
    border-right: 0;
    border-radius: 16px 16px 0 0;
    padding: 0 var(--safe-right) var(--safe-bottom) var(--safe-left);
    box-shadow: 0 -8px 32px rgba(15, 23, 41, .18);
    transform: translateY(105%);
    visibility: hidden;
    transition: transform 220ms cubic-bezier(.2, .8, .2, 1), visibility 0s linear 220ms;
    z-index: 60;
  }
  .nav-toggle:checked ~ .sidebar { transform: none; visibility: visible; transition: transform 220ms cubic-bezier(.2, .8, .2, 1), visibility 0s; }
  .nav-toggle:checked ~ .nav-scrim { display: block; position: fixed; inset: 0; background: rgba(15, 23, 41, .32); z-index: 55; }
  body:has(.nav-toggle:checked) { overflow: hidden; }

  /* The top row is the grab handle: dragging it down closes the sheet
     (app.js), so the browser must not take the gesture for a scroll. */
  .sidebar-logo { position: relative; height: 60px; padding: 8px 8px 0 16px; border-bottom: 0; touch-action: none; }
  .sidebar-logo::before {
    content: "";
    position: absolute;
    top: 6px; left: 50%;
    width: 36px; height: 4px;
    margin-left: -18px;
    border-radius: 2px;
    background: var(--border);
  }
  .sidebar-logo .label { flex: 1; }
  .nav-button {
    display: grid;
    place-items: center;
    order: 3;
    width: 44px; height: 44px;
    border-radius: 999px;
    background: var(--surface-muted);
    color: var(--text-muted);
    cursor: pointer;
  }
  .nav-button .icon:first-child { display: none; }
  .nav-button:active { background: var(--border); }
  .campaign-picker { padding: 4px 16px 12px; }
  .picker-row select { height: 44px; min-height: 44px; font-size: 16px; }
  .nav { padding: 4px 8px 8px; flex: none; }
  .nav a.in-tabbar { display: none; }
  .nav a, .foot-link { height: 52px; gap: 14px; padding: 0 12px; font-size: 16px; border-radius: 10px; }
  .sidebar-foot .btn.foot-link { font-size: 16px; }
  .nav a .icon, .foot-link .icon { width: 22px; height: 22px; color: var(--text-muted); }
  .nav a[aria-current="page"] .icon, .foot-link[aria-current="page"] .icon { color: var(--primary); }
  .nav a[aria-current="page"]::before { display: none; }
  .sidebar-foot { padding: 8px; }
  .sidebar-user { padding: 8px 12px; }

  /* Tab bar. */
  .tabbar {
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    position: fixed;
    left: 0; right: 0; bottom: 0;
    z-index: 30;
    height: calc(var(--tabbar-h) + var(--safe-bottom));
    padding: 0 var(--safe-right) var(--safe-bottom) var(--safe-left);
    background: var(--surface);
    border-top: 1px solid var(--border);
    transition: transform 150ms ease-out;
  }
  .tab {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 2px;
    min-width: 0;
    color: var(--text-muted);
    font: 500 12px/1.2 var(--font);
    cursor: pointer;
  }
  .tab-icon {
    display: grid;
    place-items: center;
    width: 52px; height: 30px;
    border-radius: 15px;
    color: var(--text);
    transition: background-color 150ms ease-out;
  }
  .tab-label { max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
  .tab[aria-current="page"], .tab.is-current { color: var(--primary); }
  .tab[aria-current="page"] .tab-icon, .tab.is-current .tab-icon { background: var(--primary-soft); color: var(--primary); }
  .tab:active .tab-icon { background: var(--border); }
  .tab:focus-visible { outline: none; }
  .tab:focus-visible .tab-icon, .nav-toggle:focus-visible ~ .tabbar label.tab .tab-icon { box-shadow: var(--focus-ring); }
  .tab-badge { position: absolute; top: 4px; left: calc(50% + 6px); box-shadow: 0 0 0 2px var(--surface); }

  /* With the keyboard up the tab bar steps aside and sticky bars rest on
     the bottom edge. */
  body:has(:is(input:not([type="checkbox"], [type="radio"], [type="file"], [type="hidden"]), textarea, select):focus) { --sticky-bottom: 0px; }
  body:has(:is(input:not([type="checkbox"], [type="radio"], [type="file"], [type="hidden"]), textarea, select):focus) .tabbar { transform: translateY(110%); }

  .content, body.nav-collapsed .content {
    margin-left: 0;
    min-height: 0;
    padding: 16px var(--gutter-r) calc(var(--tabbar-h) + var(--safe-bottom) + 32px) var(--gutter-l);
  }
  input, select, textarea { scroll-margin-top: calc(var(--appbar-h) + var(--safe-top) + 16px); scroll-margin-bottom: 24px; }

  /* Focused screens (reading a mail, editing it): like a pushed view in an
     iOS app, no tab bar; the app bar's back control leads out, and the
     page's own action bar rests on the bottom edge. */
  body:has([data-review], .mail-edit) { --sticky-bottom: 0px; }
  body:has([data-review], .mail-edit) .tabbar { display: none; }
  body:has([data-review], .mail-edit) .content { padding-bottom: calc(var(--safe-bottom) + 24px); }

  .appbar-back {
    flex: none;
    display: inline-flex;
    align-items: center;
    gap: 2px;
    min-width: 44px;
    height: 44px;
    margin-left: -10px;
    padding-right: 8px;
    border-radius: 10px;
    color: var(--primary);
    font-size: 16px;
    font-weight: 500;
  }
  .appbar-back:active { background: var(--surface-muted); opacity: 1; }
  .appbar-back:focus-visible { outline: none; box-shadow: var(--focus-ring); }
  /* Mails: the position ("3 de 12", thin meter, ‹ ›) takes the app bar. */
  .appbar:has(.appbar-progress) .appbar-text,
  .appbar:has(.appbar-progress) .appbar-status { display: none; }
  .appbar-progress { flex: 1; min-width: 0; display: flex; align-items: center; gap: 0; }
  .appbar-progress .review-pos { display: flex; flex-direction: column; align-items: center; gap: 4px; flex: 1; min-width: 0; font-size: 15px; font-weight: 600; font-variant-numeric: tabular-nums; }
  .appbar-progress .review-meter { display: block; width: min(120px, 100%); height: 4px; }
  .appbar-progress .review-nav { display: inline-grid; place-items: center; width: 44px; height: 44px; flex: none; border-radius: 10px; color: var(--text); }
  .appbar-progress .review-nav:active { background: var(--surface-muted); opacity: 1; }
  .appbar-progress .review-nav-gap { width: 44px; flex: none; }
  .appbar-progress:last-child > :last-child { margin-right: -10px; }
  /* The help button, always last (after the position in Mails). */
  .appbar-help {
    flex: none;
    display: inline-grid;
    place-items: center;
    width: 44px; height: 44px;
    margin-right: -10px;
    border-radius: 10px;
    color: var(--text-muted);
  }
  .appbar-help:active { background: var(--surface-muted); color: var(--primary); opacity: 1; }
  .appbar-help:focus-visible { outline: none; box-shadow: var(--focus-ring); }
}

/* ---------- Page header ---------- */

.page-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 24px;
  flex-wrap: wrap;
}
.page-header h1 { font-size: 26px; line-height: 1.25; letter-spacing: -0.01em; }
.page-header .subtitle { margin: 4px 0 0; font-size: 14px; color: var(--text-muted); }
.page-actions { display: flex; gap: 8px; flex-wrap: wrap; }
.page-actions form { margin: 0; }
.page-actions:empty { display: none; }

.section { margin-top: 24px; }
.section-title { font-size: 16px; font-weight: 600; margin: 0 0 12px; }

/* ---------- Buttons ---------- */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  height: 40px;
  padding: 0 16px;
  border-radius: 8px;
  border: 1px solid transparent;
  font: 500 14px/1 var(--font);
  cursor: pointer;
  white-space: nowrap;
  text-decoration: none;
  touch-action: manipulation;
  transition: background-color 150ms ease-out, border-color 150ms ease-out, transform 150ms ease-out, box-shadow 150ms ease-out;
}
.btn:hover { text-decoration: none; }
.btn:active { transform: scale(.97); }
.btn:focus-visible { outline: none; box-shadow: var(--focus-ring); border-color: var(--primary); }
.btn[disabled], .btn[aria-disabled="true"] { opacity: .5; cursor: not-allowed; transform: none; }

.btn-primary { background: var(--primary); color: #fff; }
.btn-secondary { background: var(--surface); color: var(--text); border-color: var(--border); }
.btn-ghost { background: transparent; color: var(--text); }
.btn-danger-soft { background: var(--danger-soft); color: var(--danger-text); border-color: transparent; }
@media (hover: hover) {
  .btn-primary:hover { background: var(--primary-hover); }
  .btn-secondary:hover, .btn-ghost:hover { background: var(--surface-muted); }
  .btn-danger-soft:hover { border-color: var(--danger); }
}
.btn-primary:active { background: var(--primary-hover); }
.btn-secondary:active, .btn-ghost:active { background: var(--surface-muted); }
.btn-danger-soft:active { border-color: var(--danger); }
/* Compact padding for buttons inside rows and banners; still 40px tall
   (DESIGN.md: controls are 40px, the user clicks a lot). */
.btn-small { height: 40px; padding: 0 12px; font-size: 13px; }
.btn-icon { width: 40px; padding: 0; }
.btn-block { width: 100%; }

.btn-primary kbd { background: rgba(255, 255, 255, .16); border-color: rgba(255, 255, 255, .35); color: #fff; }
.btn-danger-soft kbd { background: transparent; border-color: rgba(181, 0, 27, .25); color: var(--danger-text); }

kbd {
  font: 500 12px/1 var(--mono);
  padding: 2px 6px;
  border: 1px solid var(--border);
  border-bottom-width: 2px;
  border-radius: 4px;
  background: var(--surface-muted);
  color: var(--text-muted);
}

/* ---------- Cards ---------- */

.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 24px;
}
.card + .card { margin-top: 24px; }
.card-title { font-size: 20px; font-weight: 600; margin: 0 0 4px; }
.card-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 16px; flex-wrap: wrap; margin-bottom: 16px; }
.card-head > div:first-child { flex: 1 1 280px; min-width: 0; }

/* A card that folds to its title row (Buscar's search form, Contactos'
   upload): a chevron on the right, open while it is the next step. */
.fold { padding: 0; }
.fold > summary {
  display: flex;
  align-items: center;
  gap: 12px;
  min-height: 64px;
  padding: 16px 24px;
  border-radius: 12px;
  cursor: pointer;
  list-style: none;
}
.fold > summary::-webkit-details-marker { display: none; }
.fold > summary .card-title { margin: 0; }
.fold-hint { display: block; margin-top: 2px; font-size: 13px; font-weight: 400; color: var(--text-muted); }
.fold > summary .chev { margin-left: auto; color: var(--text-muted); transition: transform 150ms ease-out; }
.fold[open] > summary .chev { transform: rotate(180deg); }
.fold[open] > summary { border-radius: 12px 12px 0 0; }
.fold > summary:focus-visible { outline: none; box-shadow: var(--focus-ring); }
.fold > summary:active { background: var(--surface-muted); }
@media (hover: hover) { .fold > summary:hover { background: var(--surface-muted); } }
.fold-body { padding: 0 24px 24px; }

/* ---------- Banners ---------- */

.banner {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 16px;
  border-radius: 12px;
  margin-bottom: 16px;
  border: 1px solid transparent;
  flex-wrap: wrap;
}
.banner p { margin: 0; flex: 1; min-width: 200px; }
.banner form { margin: 0; }
.banner-info { background: var(--info-soft); color: var(--info-text); }
.banner-warning { background: var(--warning-soft); color: var(--warning-text); }
.banner-danger { background: var(--danger-soft); color: var(--danger-text); }
.banner-success { background: var(--success-soft); color: var(--success-text); }

progress {
  -webkit-appearance: none;
  appearance: none;
  width: 160px;
  height: 6px;
  border: 0;
  border-radius: 999px;
  background: rgba(0, 94, 143, .15);
  color: var(--info);
  overflow: hidden;
}
progress::-webkit-progress-bar { background: rgba(0, 94, 143, .15); border-radius: 999px; }
progress::-webkit-progress-value { background: var(--info); border-radius: 999px; }
progress::-moz-progress-bar { background: var(--info); border-radius: 999px; }

/* ---------- Hoy: task rows and KPIs ---------- */

.tasks { display: flex; flex-direction: column; gap: 8px; }
.task {
  display: flex;
  align-items: center;
  gap: 16px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 16px 16px 16px 24px;
  min-height: 72px;
}
.task-text { flex: 1; font-size: 16px; font-weight: 500; }
.task form { margin: 0; }
.task.is-muted .task-text { color: var(--text-muted); font-weight: 400; font-size: 14px; }
.dot { width: 10px; height: 10px; border-radius: 50%; flex: none; background: var(--border); }
.dot-warning { background: var(--warning); }
.dot-info { background: var(--info); }
.dot-success { background: var(--success); }
.dot-danger { background: var(--danger); }

.kpis { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; }
.kpi { background: var(--surface); border: 1px solid var(--border); border-radius: 12px; padding: 16px 24px; }
.kpi-label { font-size: 13px; color: var(--text-muted); }
.kpi-value { font-size: 28px; font-weight: 600; line-height: 1.3; font-variant-numeric: tabular-nums; }
.kpi-hint { font-size: 12px; color: var(--text-muted); }
.kpi-foot { margin: 12px 0 0; }
.kpi-foot .back-link { display: inline-flex; }
.home-pause { display: none; }
@media (max-width: 900px) { .kpis { grid-template-columns: repeat(2, minmax(0, 1fr)); } }

/* iPad portrait: tasks and KPIs side by side. */
@media (min-width: 760px) and (max-width: 1023.98px) {
  .home-grid { display: grid; grid-template-columns: minmax(0, 1.6fr) minmax(0, 1fr); gap: 24px; align-items: start; }
  .home-grid > .section { margin-top: 0; }
  .home-grid .kpis { grid-template-columns: 1fr; gap: 8px; }
  .home-grid .kpi { display: grid; grid-template-columns: 1fr auto; align-items: baseline; column-gap: 12px; padding: 12px 16px; }
  .home-grid .kpi-value { grid-row: 1 / span 2; grid-column: 2; font-size: 26px; }
  .home-grid .kpi-label { font-size: 14px; color: var(--text); font-weight: 500; }
}

/* ---------- Pills ---------- */

.pill {
  display: inline-flex;
  align-items: center;
  height: 22px;
  padding: 0 10px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 500;
  white-space: nowrap;
  background: var(--surface-muted);
  color: var(--text-muted);
  border: 1px solid var(--border);
}
.pill-success { background: var(--success-soft); color: var(--success-text); border-color: transparent; }
.pill-warning { background: var(--warning-soft); color: var(--warning-text); border-color: transparent; }
.pill-danger { background: var(--danger-soft); color: var(--danger-text); border-color: transparent; }
.pill-info { background: var(--info-soft); color: var(--info-text); border-color: transparent; }
.pills { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }

/* Filter chips (links) */
.chips { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 16px; }
.chip {
  display: inline-flex; align-items: center; gap: 6px;
  height: 40px; padding: 0 12px;
  border: 1px solid var(--border); border-radius: 8px;
  background: var(--surface); color: var(--text); font-size: 13px;
  white-space: nowrap;
}
@media (hover: hover) { .chip:hover { background: var(--surface-muted); text-decoration: none; } }
.chip:active { background: var(--surface-muted); }
.chip:focus-visible { outline: none; box-shadow: var(--focus-ring); }
.chip[aria-current="true"] { background: var(--primary-soft); color: var(--primary); border-color: var(--primary-soft); font-weight: 500; }
.chip .num { color: var(--text-muted); }

/* ---------- Tables ---------- */

.table-wrap {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 12px;
  overflow-x: auto;
  container-type: inline-size;
}
table { width: 100%; border-collapse: collapse; font-size: 14px; }
th {
  height: 40px;
  padding: 0 16px;
  text-align: left;
  font-size: 13px;
  font-weight: 500;
  color: var(--text-muted);
  background: var(--surface-muted);
  border-bottom: 1px solid var(--border);
  white-space: nowrap;
}
td { padding: 12px 16px; border-bottom: 1px solid var(--border); vertical-align: top; }
tbody tr:last-child td { border-bottom: 0; }
@media (hover: hover) { tbody tr:hover { background: var(--surface-muted); } }
td.num, th.num { text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; }
td .sub { display: block; font-size: 13px; color: var(--text-muted); }
td form { margin: 0; display: inline; }
.cell-actions { display: flex; gap: 8px; flex-wrap: wrap; justify-content: flex-end; }
th.select-cell, td.select-cell { width: 48px; padding-right: 0; }
td.select-cell input { margin-top: 2px; }
.select-hit { display: inline-flex; align-items: center; justify-content: center; cursor: pointer; }
td.emails-cell { min-width: 240px; }
td a.sub { color: var(--primary); }
.addr-part { white-space: nowrap; }
.cell-list { list-style: none; margin: 0; padding: 0; overflow-wrap: anywhere; }
.cell-list li + li { margin-top: 4px; }
.more-list > summary { display: inline-flex; align-items: center; gap: 2px; color: var(--primary); font-size: 13px; cursor: pointer; list-style: none; }
.more-list > summary::-webkit-details-marker { display: none; }
.more-list > summary .icon { transition: transform 150ms ease-out; }
.more-list[open] > summary .icon { transform: rotate(180deg); }
.more-list[open] > summary { margin-bottom: 4px; }
.clamp > summary { display: block; list-style: none; cursor: pointer; }
.clamp > summary::-webkit-details-marker { display: none; }
.cell-label { display: none; }
td.cell-mail { overflow-wrap: anywhere; }
.bulk-actions { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.bulk-actions .select-all[hidden], .bulk-count[hidden] { display: none; }
.bulk-count { margin-right: auto; color: var(--text-muted); font-size: 13px; font-variant-numeric: tabular-nums; }
/* Buscar empresas: the bulk bar follows the list and stays in reach at the
   bottom while scrolling it (the list can be hundreds of cards long). */
.bulk-form { display: flex; flex-direction: column; }
.bulk-form > .bulk-actions {
  order: 2;
  position: sticky;
  bottom: calc(var(--sticky-bottom) + var(--safe-bottom) + 12px);
  z-index: 5;
  margin-top: 12px;
  padding: 8px 12px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 12px;
  box-shadow: var(--float-shadow);
}
.last-run { margin: 0 0 12px; }

/* Below 900px of card width a row reads better as a card than as squeezed
   columns (phones, iPad portrait, iPad landscape beside the menu): the key
   field as the title, the status pill beside it, the rest as "Label: value"
   lines and the actions as full-width buttons. */
@container (max-width: 900px) {
  table.stack thead { display: none; }
  table.stack, table.stack tbody { display: block; width: 100%; }
  table.stack tr {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    column-gap: 12px;
    row-gap: 4px;
    align-items: start;
    padding: 14px 16px;
    border-bottom: 1px solid var(--border);
  }
  table.stack tr:has(> td.select-cell) { grid-template-columns: 32px minmax(0, 1fr) auto; }
  table.stack tbody tr:last-child { border-bottom: 0; }
  table.stack td { display: block; width: auto; min-width: 0; padding: 0; border: 0; text-align: left; overflow-wrap: anywhere; grid-column: 1 / -1; }
  table.stack td.cell-title { grid-column: 1; grid-row: 1; font-size: 16px; font-weight: 600; }
  table.stack td.cell-title .sub { font-weight: 400; }
  table.stack td.cell-status { grid-column: -2 / -1; grid-row: 1; justify-self: end; display: flex; flex-wrap: wrap; gap: 4px; justify-content: flex-end; }
  table.stack td.cell-status .sub { flex-basis: 100%; text-align: right; }
  table.stack td.cell-status[data-label] { flex-direction: column; align-items: flex-end; gap: 2px; }
  table.stack td.cell-status[data-label]::before { content: attr(data-label); font-size: 12px; }
  table.stack td.select-cell { grid-column: 1; grid-row: 1; width: auto; padding: 0; }
  table.stack tr:has(> td.select-cell) td.cell-title { grid-column: 2; }
  table.stack tr:has(> td.select-cell) td:not(.select-cell, .cell-title, .cell-status) { grid-column: 2 / -1; }
  table.stack td[data-label]::before { content: attr(data-label) ": "; color: var(--text-muted); font: 400 13px/1.5 var(--font); }
  table.stack td.cell-title[data-label]::before { content: none; }
  table.stack td.num { text-align: left; white-space: normal; }
  td.emails-cell { min-width: 0; }
  .cell-actions { display: grid; grid-template-columns: repeat(auto-fit, minmax(140px, 220px)); margin-top: 8px; }
  .cell-actions form { display: block; }
  .cell-actions .btn { width: 100%; }
  .cell-actions .btn-ghost { border-color: var(--border); }
  .addr-part { white-space: normal; }
  /* A long text (a candidate's reason) shows 3 lines; a tap opens it. */
  .cell-label { display: inline; color: var(--text-muted); font: 400 13px/1.5 var(--font); }
  .clamp:not([open]) > summary { display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 3; overflow: hidden; }
  /* A status with an explanation (a mailbox's pause reason) gets its own
     row under the title, so neither squeezes the other. */
  table.stack tr:has(> td.cell-status .sub) > td.cell-title { grid-column: 1 / -1; }
  table.stack td.cell-status:has(.sub) { grid-column: 1 / -1; grid-row: 2; justify-self: start; justify-content: flex-start; }
  table.stack td.cell-status .sub { order: 2; }
  table.stack td.cell-status:has(.sub) .sub { text-align: left; }
}

/* Narrow cards (phones): the status goes under the title, so the title and
   its link keep the whole width. */
@container (max-width: 520px) {
  table.stack tr, table.stack tr:has(> td.select-cell) { grid-template-columns: minmax(0, 1fr); }
  table.stack tr:has(> td.select-cell) { grid-template-columns: 32px minmax(0, 1fr); }
  table.stack td.cell-title { grid-column: 1 / -1; }
  table.stack tr:has(> td.select-cell) td.cell-title { grid-column: 2 / -1; }
  table.stack td.cell-status, table.stack tr:has(> td.select-cell) td.cell-status {
    grid-column: 1 / -1; grid-row: 2; justify-self: start; justify-content: flex-start; margin: 2px 0 4px;
  }
  table.stack tr:has(> td.select-cell) td.cell-status { grid-column: 2 / -1; }
  table.stack td.cell-status .sub { text-align: left; }
  .cell-actions { grid-template-columns: repeat(auto-fit, minmax(120px, 1fr)); }
  table.stack td.cell-status[data-label] { flex-direction: row; align-items: center; gap: 6px; }
  table.stack td.cell-status[data-label]::before { content: attr(data-label) ":"; font-size: 13px; }
}

.pager { display: flex; justify-content: space-between; align-items: center; margin-top: 16px; gap: 8px; flex-wrap: wrap; }
.pager-links { display: flex; gap: 8px; }
.pager-top { margin: 0 0 12px; }

/* ---------- Empty states ---------- */

.empty {
  text-align: center;
  padding: 48px;
  color: var(--text-muted);
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 12px;
  overflow-wrap: anywhere;
}
.empty .icon { color: #9AA3AF; margin-bottom: 12px; }
.empty p { margin: 0 0 16px; }
.empty p:last-child { margin-bottom: 0; }

/* ---------- Forms ---------- */

.form { max-width: 720px; }
.form-section { margin-bottom: 24px; scroll-margin-top: 16px; }
.form-section h2 { font-size: 20px; margin-bottom: 4px; }
.form-section > .muted { margin: 0 0 16px; }
.field { margin-bottom: 16px; }
.field label, .field .label { display: block; font-weight: 500; margin-bottom: 4px; }
.field .help { display: block; font-size: 13px; color: var(--text-muted); margin-top: 4px; }
.field .error { display: flex; gap: 6px; align-items: flex-start; font-size: 13px; color: var(--danger-text); margin-top: 4px; }
.field-short { max-width: 240px; }
.row { display: grid; grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); gap: 16px; }

input[type="text"], input[type="email"], input[type="url"], input[type="number"], input[type="password"],
input[type="time"], input[type="search"], select, textarea {
  width: 100%;
  min-height: 40px;
  padding: 8px 12px;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: var(--surface);
  color: var(--text);
  font: 400 14px/1.5 var(--font);
  transition: border-color 150ms ease-out, box-shadow 150ms ease-out;
}
textarea { min-height: 96px; resize: vertical; }
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--primary); box-shadow: var(--focus-ring); }
input[aria-invalid="true"], textarea[aria-invalid="true"] { border-color: var(--danger); }
input[type="file"] { font: inherit; max-width: 100%; }
input[type="file"]::file-selector-button {
  height: 40px;
  margin-right: 12px;
  padding: 0 14px;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: var(--surface);
  color: var(--text);
  font: 500 14px/1 var(--font);
  cursor: pointer;
}
input[type="checkbox"] { width: 16px; height: 16px; accent-color: var(--primary); }
.check { display: inline-flex; align-items: center; gap: 8px; font-weight: 400; margin-right: 16px; cursor: pointer; }
.checks { display: flex; flex-wrap: wrap; gap: 8px 0; }
.form-actions { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; margin-top: 8px; }
.inline-form { display: flex; gap: 8px; flex-wrap: wrap; align-items: flex-end; }
.inline-form .field { margin: 0; flex: 1; min-width: 200px; }
.inline-qty { display: inline-flex; align-items: center; gap: 8px; }
.inline-qty input[type="number"] { width: 96px; }
.step-row { display: flex; gap: 8px 16px; flex-wrap: wrap; align-items: center; }
.step-row + .step-row { margin-top: 12px; }
.step-row form { margin: 0; }

/* Long forms (Campaña): section links on top, "Guardar" always reachable. */
.section-nav { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 16px; }
.form-actions.is-sticky {
  position: sticky;
  bottom: var(--sticky-bottom);
  z-index: 5;
  margin: 0;
  padding: 12px 0;
  background: var(--canvas);
  border-top: 1px solid var(--border);
}
.card .form-actions.is-sticky { margin: 8px -24px -24px; padding: 12px 24px; background: var(--surface); border-radius: 0 0 12px 12px; }
/* A field reached with Tab (or scrolled to by the browser) stops above the
   sticky bar instead of under it. */
html:has(.form-actions.is-sticky) { scroll-padding-bottom: calc(var(--sticky-bottom) + 88px); }

.alert-list { margin: 0; padding-left: 20px; }

/* ---------- Email review card ---------- */

.review { background: var(--surface); border: 1px solid var(--border); border-radius: 12px; }
.review-head {
  display: flex;
  justify-content: space-between;
  gap: 8px 16px;
  padding: 16px 24px;
  border-bottom: 1px solid var(--border);
  flex-wrap: wrap;
}
.review-who { font-size: 20px; font-weight: 600; }
.review-who .muted { font-weight: 400; }
.review-who, .review-to { overflow-wrap: anywhere; }
.review-to { font-size: 13px; color: var(--text-muted); }
.review-body { padding: 24px; }
.reading { max-width: 680px; }
.subject-label { font-size: 13px; color: var(--text-muted); margin-bottom: 2px; }
.subject { font-size: 16px; font-weight: 600; margin-bottom: 16px; overflow-wrap: anywhere; }
.mail-text { font-size: 16px; line-height: 1.6; white-space: pre-wrap; overflow-wrap: anywhere; margin: 0; }
.mail-footer {
  margin-top: 16px;
  padding-top: 12px;
  border-top: 1px dashed var(--border);
  color: var(--text-muted);
  font-size: 14px;
  line-height: 1.6;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}
.followup { border-top: 1px solid var(--border); }
.followup summary {
  cursor: pointer;
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 2px 8px;
  padding: 12px 24px;
  font-weight: 500;
  list-style: none;
}
.followup summary::-webkit-details-marker { display: none; }
.followup summary .chev { order: -1; color: var(--text-muted); transition: transform 150ms ease-out; }
.followup[open] > summary .chev { transform: rotate(180deg); }
.followup summary:active { background: var(--surface-muted); }
.followup summary:focus-visible { outline: none; box-shadow: inset var(--focus-ring); }
.followup .when { font-weight: 400; color: var(--text-muted); font-size: 13px; }
.followup-body { padding: 0 24px 24px; }
.review-actions {
  position: sticky;
  bottom: var(--sticky-bottom);
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 12px 24px;
  border-top: 1px solid var(--border);
  background: var(--surface);
  border-radius: 0 0 12px 12px;
  flex-wrap: wrap;
}
.review-actions, .form-actions.is-sticky { padding-bottom: calc(12px + var(--safe-bottom)); }
.card .form-actions.is-sticky { padding-bottom: calc(12px + var(--safe-bottom)); }
.review-actions form { margin: 0; }
.review-progress { margin-left: auto; display: flex; align-items: center; gap: 8px; color: var(--text-muted); font-variant-numeric: tabular-nums; }
.review-meter { display: none; }
.review-nav { display: inline-grid; width: 40px; }
.shortcuts { margin-top: 12px; font-size: 13px; color: var(--text-muted); }

/* ---------- Replies ---------- */

.reply { background: var(--surface); border: 1px solid var(--border); border-radius: 12px; padding: 16px 24px; }
.reply + .reply { margin-top: 16px; }
.reply-head { display: flex; justify-content: space-between; gap: 8px 12px; flex-wrap: wrap; align-items: center; }
.reply-name { font-weight: 600; font-size: 16px; }
.reply-reason { margin: 8px 0; }
.suggested {
  margin: 8px 0 12px;
  padding: 12px 16px;
  background: var(--surface-muted);
  border: 1px solid var(--border);
  border-radius: 8px;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
  font: 400 14px/1.6 var(--font);
  max-width: 680px;
}
.reply-actions { display: flex; gap: 8px; flex-wrap: wrap; }
.reply-actions form { margin: 0; }

/* ---------- Definition lists (settings) ---------- */

.facts { display: grid; grid-template-columns: minmax(140px, 220px) 1fr; gap: 12px 24px; margin: 0; }
.facts dt { color: var(--text-muted); }
.facts dd { margin: 0; overflow-wrap: anywhere; min-width: 0; }
@media (max-width: 600px) { .facts { grid-template-columns: 1fr; gap: 2px; } .facts dd { margin-bottom: 12px; } }

/* ---------- Guía (docs/guia-operativa.md rendered by markdown.go) ---------- */

.guide-sections { margin-top: 16px; display: flex; flex-direction: column; gap: 8px; }
.guide-sections .card + .card { margin-top: 0; }
.guide-section > summary h2 { font-size: 18px; }
.guide-body { font-size: 15px; line-height: 1.6; overflow-wrap: break-word; }
.guide-body > :first-child { margin-top: 0; }
.guide-body p, .guide-body ul, .guide-body ol, .guide-body h3, .guide-body h4 { max-width: 76ch; }
.guide-body p { margin: 0 0 12px; }
.guide-body h3 { font-size: 17px; margin: 24px 0 8px; }
.guide-body h4 { font-size: 15px; margin: 16px 0 6px; }
.guide-body ul, .guide-body ol { margin: 0 0 12px; padding-left: 22px; }
.guide-body li + li { margin-top: 6px; }
.guide-body li > ul, .guide-body li > ol { margin: 6px 0 0; }
.guide-body li > p { margin: 8px 0 0; }
.guide-body code { padding: 1px 4px; border: 1px solid var(--border); border-radius: 4px; background: var(--surface-muted); overflow-wrap: anywhere; }
.guide-body .table-wrap { margin: 0 0 16px; }
.guide-code {
  margin: 0 0 16px;
  padding: 12px 16px;
  background: var(--surface-muted);
  border: 1px solid var(--border);
  border-radius: 8px;
  font: 400 13px/1.6 var(--mono);
  white-space: pre-wrap;
  white-space: break-spaces;
  overflow-wrap: anywhere;
}
.guide-code code { padding: 0; border: 0; background: none; }
.guide-section, .guide-body h3 { scroll-margin-top: 16px; }
@container (max-width: 900px) {
  table.guide-table td:empty { display: none; }
}

/* ---------- Ayuda (docs/ayuda rendered by help.go) ---------- */

/* The help button: next to the page title on tablets and desktop (on a
   phone the app bar carries it, .appbar-help). */
.page-heading { min-width: 0; }
.page-title-row { display: flex; align-items: center; gap: 4px; }
.help-button {
  display: inline-grid;
  place-items: center;
  flex: none;
  width: 40px; height: 40px;
  border-radius: 999px;
  color: var(--text-muted);
  transition: background-color 150ms ease-out, color 150ms ease-out;
}
.help-button:active { background: var(--surface-muted); color: var(--primary); opacity: 1; }
.help-button:focus-visible { outline: none; box-shadow: var(--focus-ring); }
@media (hover: hover) { .help-button:hover { background: var(--surface-muted); color: var(--primary); text-decoration: none; } }

/* A discreet "?" next to one part of a screen (the "help-link" partial).
   On a touch screen its 44px target overlaps the line around it. */
.help-link {
  display: inline-grid;
  place-items: center;
  width: 24px; height: 24px;
  margin: -4px 0;
  border-radius: 999px;
  color: var(--text-muted);
  vertical-align: middle;
}
.help-link:active { color: var(--primary); opacity: 1; }
.help-link:focus-visible { outline: none; box-shadow: var(--focus-ring); }
@media (hover: hover) { .help-link:hover { background: var(--surface-muted); color: var(--primary); } }

/* /ayuda: one card per topic. */
.help-group + .help-group { margin-top: 24px; }
.help-topics {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 12px;
}
.help-topic {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  height: 100%;
  padding: 16px;
  color: var(--text);
  transition: border-color 150ms ease-out, background-color 150ms ease-out;
}
.help-topic:active { background: var(--surface-muted); opacity: 1; }
.help-topic:focus-visible { outline: none; box-shadow: var(--focus-ring); border-color: var(--primary); }
@media (hover: hover) { .help-topic:hover { border-color: var(--primary); text-decoration: none; } }
.help-topic-icon {
  display: grid;
  place-items: center;
  flex: none;
  width: 36px; height: 36px;
  border-radius: 8px;
  background: var(--primary-soft);
  color: var(--primary);
}
.help-topic-text { min-width: 0; }
.help-topic-title { display: block; font-size: 16px; font-weight: 600; line-height: 1.3; }
.help-topic-summary { display: block; margin-top: 2px; font-size: 14px; color: var(--text-muted); }

/* /ayuda/{tema}: the sections open, an index of them first. */
.help-toc { padding: 16px 24px; }
.help-toc-title { margin: 0 0 4px; font-size: 13px; font-weight: 600; color: var(--text-muted); }
.help-toc ol { list-style: none; margin: 0; padding: 0; columns: 2 260px; column-gap: 24px; }
.help-toc li { break-inside: avoid; }
.help-toc a { display: flex; align-items: center; min-height: 36px; font-size: 15px; }
.help-sections { margin-top: 16px; display: flex; flex-direction: column; gap: 16px; }
.help-sections .card + .card { margin-top: 0; }
.help-section > .card-title { margin-bottom: 12px; }
.help-section, .help-sections .guide-body h3 { scroll-margin-top: 16px; }
.help-foot { display: flex; flex-wrap: wrap; gap: 0 24px; margin: 24px 0 0; }
.help-foot .back-link { gap: 6px; }

/* Pages before the login: "¿Problemas para entrar?", folded under the
   card; a link to the help on the other bare pages. */
.login-help { width: 100%; max-width: 420px; }
.bare:has(.card-wide) .login-help { max-width: 600px; }
.login-help > summary {
  display: flex;
  align-items: center;
  gap: 8px;
  min-height: 44px;
  padding: 0 8px;
  border-radius: 8px;
  color: var(--primary);
  font-weight: 500;
  cursor: pointer;
  list-style: none;
}
.login-help > summary::-webkit-details-marker { display: none; }
.login-help > summary .chev { display: inline-flex; margin-left: auto; color: var(--text-muted); transition: transform 150ms ease-out; }
.login-help[open] > summary .chev { transform: rotate(180deg); }
.login-help > summary:focus-visible { outline: none; box-shadow: var(--focus-ring); }
.login-help > summary:active { background: var(--surface-muted); }
@media (hover: hover) { .login-help > summary:hover { background: var(--surface-muted); } }
.login-help-body {
  margin-top: 8px;
  padding: 16px 20px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 12px;
}
.login-help-body section + section { margin-top: 20px; }
.login-help-body h2 { margin: 0 0 6px; font-size: 16px; }
.bare-help { gap: 6px; }

/* ---------- Toasts ---------- */

.toast-close-toggle { position: absolute; opacity: 0; pointer-events: none; }
.toast {
  position: fixed;
  right: 24px;
  bottom: calc(var(--sticky-bottom) + var(--toast-lift) + 24px);
  width: 380px;
  max-width: calc(100vw - 32px);
  display: flex;
  gap: 12px;
  align-items: flex-start;
  padding: 16px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 12px;
  box-shadow: var(--float-shadow);
  z-index: 50;
  animation: toast-out 200ms ease-out 5s forwards;
}
.toast.is-error { animation-delay: 8s; }
.toast .icon { color: var(--success); margin-top: 1px; }
.toast.is-error .icon { color: var(--danger); }
.toast p { margin: 0; flex: 1; min-width: 0; overflow-wrap: anywhere; }
.toast-close {
  flex: none;
  width: 28px; height: 28px;
  display: grid; place-items: center;
  border-radius: 6px;
  color: var(--text-muted);
  cursor: pointer;
}
@media (hover: hover) { .toast-close:hover { background: var(--surface-muted); } }
.toast-close:active { background: var(--surface-muted); }
.toast-close-toggle:focus-visible + .toast .toast-close { box-shadow: var(--focus-ring); }
.toast-close-toggle:checked + .toast { display: none; }
@keyframes toast-out { to { opacity: 0; visibility: hidden; transform: translateY(8px); } }
@keyframes toast-hide { to { opacity: 0; visibility: hidden; } }
/* Toasts never cover a sticky action bar (review, bulk, save): they rest
   above it. */
body:has(.form-actions.is-sticky, .review-actions, .bulk-form > .bulk-actions) { --toast-lift: calc(72px + var(--safe-bottom)); }

/* ---------- Bare pages (login, 2FA, lock, errors) ---------- */

.bare {
  min-height: 100vh;
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 16px;
  padding: calc(24px + var(--safe-top)) max(16px, var(--safe-right)) calc(24px + var(--safe-bottom)) max(16px, var(--safe-left));
}
.bare-brand { display: flex; align-items: center; gap: 10px; font-size: 16px; font-weight: 600; }
.bare .card { width: 100%; max-width: 420px; overflow-wrap: anywhere; }
.bare .card h1 { font-size: 26px; margin-bottom: 8px; }
.bare .card.card-wide { max-width: 600px; }
.bare .card > ol { padding-left: 20px; }

/* ---------- Users, login with 2FA ---------- */

.steps { padding-left: 20px; margin: 16px 0; }
.steps > li + li { margin-top: 20px; }
.steps form { margin-top: 8px; }
.enroll-grid { display: grid; grid-template-columns: 258px minmax(0, 1fr); gap: 16px 24px; align-items: start; margin-top: 12px; }
.enroll-qr { display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.enroll-here { display: flex; flex-direction: column; align-items: flex-start; gap: 8px; }
.qr {
  display: block;
  width: 240px; height: 240px;
  padding: 8px;
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 8px;
  image-rendering: pixelated;
}
.btn-otp {
  background: var(--surface); color: var(--text); border-color: var(--border);
  white-space: normal; height: auto; min-height: 44px; padding: 10px 14px; line-height: 1.25; text-align: left;
}
.secret-row { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.secret-box {
  display: inline-block;
  padding: 8px 12px;
  background: var(--surface-muted);
  border: 1px solid var(--border);
  border-radius: 8px;
  font: 500 15px/1.5 var(--mono);
  letter-spacing: .04em;
  overflow-wrap: anywhere;
  user-select: all;
  -webkit-user-select: all;
}
input.code-input { font: 500 18px/1.2 var(--mono); letter-spacing: .15em; max-width: 200px; }
.codes {
  column-count: 2;
  column-gap: 24px;
  margin: 16px 0 8px;
  padding: 16px;
  background: var(--surface-muted);
  border: 1px solid var(--border);
  border-radius: 8px;
  font: 500 15px/1.8 var(--mono);
  overflow-x: auto;
  user-select: all;
  -webkit-user-select: all;
}
@media (max-width: 480px) { .codes { column-count: 1; } }
.recovery-entry { margin-top: 16px; }
.recovery-entry summary { cursor: pointer; color: var(--primary); min-height: 40px; display: flex; align-items: center; }
.recovery-entry form { margin-top: 8px; }
/* A link on its own line after a sentence (a comfortable target). */
.back-link { display: flex; align-items: center; width: fit-content; min-height: 40px; }

/* ---------- Copy fallback (app.js) ---------- */

.copy-buffer { position: fixed; top: 0; left: 0; width: 1px; height: 1px; opacity: 0; pointer-events: none; }

/* ---------- Phones: content ---------- */

@media (max-width: 639.98px) {
  .page-header { margin-bottom: 16px; gap: 12px; }
  /* The title is in the app bar; the h1 stays for screen readers. */
  .page-header:not(:has(.subtitle)):has(.page-actions:empty) { margin: 0; gap: 0; }
  .page-header h1 {
    position: absolute;
    width: 1px; height: 1px;
    overflow: hidden; clip: rect(0 0 0 0);
    white-space: nowrap; margin: -1px;
  }
  .page-header .subtitle { margin: 0; font-size: 14px; }
  .page-actions, .page-actions form { width: 100%; }
  .page-actions > *, .page-actions form .btn { flex: 1 1 auto; width: 100%; }

  .section { margin-top: 20px; }
  .section-title { font-size: 17px; }
  .card { padding: 16px; }
  .card + .card { margin-top: 16px; }
  .card-title { font-size: 18px; }
  .card-head { margin-bottom: 12px; }
  .card-head > .btn, .card-head > form, .card-head > form .btn { width: 100%; }
  .fold { padding: 0; }
  .fold > summary { min-height: 56px; padding: 12px 16px; }
  .fold-body { padding: 0 16px 16px; }
  .qty-word { display: none; }
  .banner { padding: 12px; gap: 8px 12px; }
  .banner p { min-width: 0; flex-basis: calc(100% - 28px); }
  .banner > .btn, .banner > form, .banner > form .btn { width: 100%; }
  .banner progress { width: 100%; }
  /* The app bar already says "En pausa": the banner keeps one line. */
  .banner-more { display: none; }
  .banner-row { flex-wrap: nowrap; }
  .banner-row p { flex-basis: auto; }
  .banner-row > form, .banner-row > form .btn { width: auto; flex: none; }
  .empty { padding: 32px 16px; }

  .btn { font-size: 15px; }
  .btn-small { font-size: 14px; }
  .form-actions .btn, .form-actions form { flex: 1 1 auto; }
  .form-actions .btn-primary { flex-grow: 2; }
  .btn-primary.btn-block, .bare .btn-primary { height: 48px; }

  .only-phone { display: revert !important; }
  .not-phone { display: none !important; }

  /* Hoy: the tasks come first. The campaign is in the app bar, and "Pausar
     todo" waits after the KPIs (not the first thing under the thumb). */
  .page-header:has(~ .home-grid) { margin: 0; gap: 0; }
  .page-header:has(~ .home-grid) :is(.subtitle, .page-actions) { display: none; }
  .home-pause { display: block; margin-top: 20px; }
  .home-pause .btn { width: 100%; }
  .task { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 10px 12px; padding: 14px 16px; min-height: 0; }
  .task > .btn, .task > form { grid-column: 2; width: 100%; }
  .task > form .btn { width: 100%; }
  .task.is-muted .task-text { font-size: 15px; }
  .kpis { gap: 8px; }
  .kpi { padding: 12px 14px; }
  .kpi-value { font-size: 24px; }

  /* Lists */
  .chips {
    flex-wrap: nowrap;
    overflow-x: auto;
    margin-left: calc(-1 * var(--gutter-l));
    margin-right: calc(-1 * var(--gutter-r));
    padding: 0 var(--gutter-r) 2px var(--gutter-l);
    scrollbar-width: none;
    scroll-padding-inline: var(--gutter-l);
  }
  .chips::-webkit-scrollbar { display: none; }
  .chip { flex: none; font-size: 14px; }
  .pager { justify-content: center; }
  .pager > .small { width: 100%; text-align: center; }
  .pager-links { width: 100%; }
  .pager-links .btn { flex: 1; }

  /* Forms: one column, full-width controls. */
  .row { grid-template-columns: minmax(0, 1fr); gap: 0 12px; }
  .row.row-tight { grid-template-columns: repeat(auto-fit, minmax(96px, 1fr)); gap: 12px; }
  .field-short { max-width: none; }
  .inline-form { flex-direction: column; align-items: stretch; gap: 12px; }
  .inline-form .field { min-width: 0; }
  .inline-form > .btn, .inline-form > .check { width: 100%; }
  .step-row { align-items: stretch; flex-direction: column; gap: 4px; }
  .step-row + .step-row { margin-top: 14px; }
  .step-row .inline-form { flex-direction: row; align-items: center; flex-wrap: nowrap; gap: 8px; }
  .step-row .inline-form > .btn { width: auto; flex: 1 1 auto; min-width: 0; padding: 0 10px; }
  .inline-qty { flex: none; }
  input[type="file"] { width: 100%; }
  .inline-qty input[type="number"] { width: 88px; }
  .check { margin-right: 0; }
  .checks { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 12px; }
  input.code-input { max-width: none; font-size: 24px; text-align: center; letter-spacing: .3em; padding-left: .3em; }
  .section-nav {
    flex-wrap: nowrap;
    overflow-x: auto;
    margin-left: calc(-1 * var(--gutter-l));
    margin-right: calc(-1 * var(--gutter-r));
    padding: 0 var(--gutter-r) 2px var(--gutter-l);
    scrollbar-width: none;
  }
  .section-nav::-webkit-scrollbar { display: none; }
  /* A section reached from those links starts under the app bar. */
  .form-section { scroll-margin-top: calc(var(--appbar-h) + var(--safe-top) + 12px); }
  .card .form-actions.is-sticky { margin: 8px -16px -16px; padding: 12px 16px; }
  /* While typing, the keyboard's room belongs to the text: the save bar
     stops floating (it waits at the end of the form) until the keyboard
     goes away. */
  form:has(:is(input:not([type="checkbox"], [type="radio"], [type="file"], [type="hidden"], [type="submit"], [type="button"]), textarea):focus) > .form-actions.is-sticky {
    position: static;
    box-shadow: none;
  }
  .form-actions.is-sticky {
    margin-left: calc(-1 * var(--gutter-l));
    margin-right: calc(-1 * var(--gutter-r));
    padding: 12px var(--gutter-r) 12px var(--gutter-l);
    background: var(--surface);
    box-shadow: 0 -4px 16px rgba(15, 23, 41, .06);
  }

  /* Mails: the review goes edge to edge, the actions under the thumb. */
  .review, .mail-edit {
    margin-left: calc(-1 * var(--gutter-l));
    margin-right: calc(-1 * var(--gutter-r));
    border-radius: 0;
    border-left: 0;
    border-right: 0;
  }
  .review-head { padding: 14px var(--gutter-r) 14px var(--gutter-l); }
  .review-who { font-size: 18px; }
  .review-body { padding: 16px var(--gutter-r) 20px var(--gutter-l); }
  .subject { font-size: 17px; }
  .mail-text { font-size: 17px; }
  .mail-footer { font-size: 15px; }
  .followup summary { min-height: 52px; padding: 12px var(--gutter-r) 12px var(--gutter-l); font-size: 16px; }
  .followup-body { padding: 0 var(--gutter-r) 20px var(--gutter-l); }
  /* One row under the thumb: Rechazar · Editar · Aprobar (the position is
     in the app bar). */
  .review-actions {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) minmax(0, 1.4fr);
    grid-template-areas: "reject edit approve";
    gap: 8px;
    padding: 8px var(--gutter-r) calc(8px + var(--safe-bottom)) var(--gutter-l);
    border-radius: 0;
    box-shadow: 0 -4px 16px rgba(15, 23, 41, .06);
  }
  .review-actions #approve-form { grid-area: approve; }
  .review-actions #edit-link { grid-area: edit; }
  .review-actions #reject-form { grid-area: reject; }
  .review-actions > form > .btn, .review-actions > .btn { width: 100%; height: 48px; padding: 0 8px; gap: 6px; }
  .review-actions .review-progress { display: none; }
  /* The guidance line only on the first mail. */
  .page-header:has(~ .review:not([data-first])) .subtitle { display: none; }
  .page-header:has(~ .review:not([data-first])) { margin: 0; }
  .shortcuts { margin-top: 16px; }
  /* Editar mail: the field is the screen (Cancelar is in the save bar). */
  .page-header:has(~ .mail-edit) { margin: 0; }
  .page-header:has(~ .mail-edit) :is(.subtitle, .page-actions) { display: none; }
  .mail-edit { padding: 12px var(--gutter-r) 0 var(--gutter-l); }
  .mail-edit textarea, .mail-edit input[type="text"] { font-size: 17px; line-height: 1.55; }
  .mail-edit textarea#body { min-height: 45vh; }
  .mail-edit .form-actions.is-sticky { margin: 8px calc(-1 * var(--gutter-r)) 0 calc(-1 * var(--gutter-l)); padding-bottom: calc(12px + var(--safe-bottom)); }
  .mail-edit:has(:is(input[type="text"], textarea):focus) .form-actions.is-sticky { padding-bottom: 12px; }

  /* Buscar empresas: the bulk bar goes edge to edge above the tab bar. */
  .bulk-form > .bulk-actions {
    bottom: var(--sticky-bottom);
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 4px 8px;
    margin: 0 calc(-1 * var(--gutter-r)) 0 calc(-1 * var(--gutter-l));
    padding: 6px var(--gutter-r) 10px var(--gutter-l);
    border: 0;
    border-top: 1px solid var(--border);
    border-radius: 0;
    box-shadow: 0 -4px 16px rgba(15, 23, 41, .06);
  }
  .bulk-actions .select-all { grid-column: 1; }
  .bulk-actions .bulk-count { grid-column: 2; justify-self: end; margin: 0; font-size: 14px; }
  .bulk-actions .select-all[hidden] + .bulk-count { grid-column: 1 / -1; justify-self: start; }
  .bulk-actions .btn { width: 100%; padding: 0 8px; font-size: 14px; }
  .bulk-actions .btn-primary { grid-column: 1; grid-row: 2; }
  .bulk-actions .btn-danger-soft { grid-column: 2; grid-row: 2; }

  /* Respuestas */
  .reply { padding: 16px; }
  .reply-actions > * { flex: 1 1 140px; padding: 0 10px; }
  .reply-actions > form { flex-basis: 100%; padding: 0; }
  .reply-actions form .btn { width: 100%; }
  .suggested { font-size: 15px; }

  /* Login, 2FA */
  .bare { justify-content: flex-start; padding-top: calc(32px + var(--safe-top)); }
  .bare .card { padding: 20px; }
  .bare .card h1 { font-size: 24px; }
  .steps { padding-left: 18px; }
  .enroll-grid { display: flex; flex-direction: column; }
  .enroll-here { order: -1; align-items: stretch; }
  .btn-otp { background: var(--primary); color: #fff; border-color: transparent; min-height: 48px; justify-content: center; text-align: center; }
  .btn-otp:active { background: var(--primary-hover); }
  .qr { width: 176px; height: 176px; }
  .secret-row { flex-direction: column; align-items: stretch; }
  .secret-box { text-align: center; }
  .codes { font-size: 17px; column-gap: 16px; }
  .codes + .form-actions .btn { width: 100%; }

  .guide-section, .guide-body h3 { scroll-margin-top: calc(var(--appbar-h) + var(--safe-top) + 12px); }
  .guide-section > summary h2 { font-size: 17px; }

  /* Ayuda: the app bar carries the help button and the way back. */
  .page-header .help-button { display: none; }
  .help-toc { padding: 12px 16px; }
  .help-toc ol { columns: 1; }
  .help-toc a { min-height: 44px; font-size: 16px; }
  .help-section, .help-sections .guide-body h3 { scroll-margin-top: calc(var(--appbar-h) + var(--safe-top) + 12px); }
  .help-section > .card-title { font-size: 18px; }
  .help-topics { grid-template-columns: minmax(0, 1fr); gap: 8px; }
  .help-topic { padding: 14px 16px; }

  /* Toasts above the tab bar and above the page's sticky bar. */
  .toast { left: 12px; right: 12px; bottom: calc(var(--sticky-bottom) + var(--toast-lift) + 12px); width: auto; max-width: none; }
  body:has(.form-actions.is-sticky, .review-actions, .bulk-form > .bulk-actions) { --toast-lift: 72px; }
  body:has(.review[data-review], .card.mail-edit) { --toast-lift: calc(72px + var(--safe-bottom)); }
  body:has(.bulk-form > .bulk-actions) { --toast-lift: 116px; }
}

/* ---------- Tablets: content ---------- */

@media (min-width: 640px) and (max-width: 1023.98px) {
  .review-actions > form > .btn, .review-actions > .btn { height: 44px; }
}

/* Phones in landscape (a short rail): the rail keeps the four daily
   screens (the phone's tab bar) under the menu button, which opens the
   rest; the page header gets compact. */
@media (min-width: 640px) and (max-width: 1023.98px) and (max-height: 500px) {
  .nav-toggle:not(:checked) ~ .sidebar .sidebar-logo { height: 52px; }
  .nav-toggle:not(:checked) ~ .sidebar .nav { padding: 4px 8px; gap: 2px; }
  .nav-toggle:not(:checked) ~ .sidebar .nav a:not(.in-tabbar),
  .nav-toggle:not(:checked) ~ .sidebar .sidebar-foot { display: none; }
  .nav-toggle:not(:checked) ~ .sidebar :is(.nav a, .foot-link) { min-height: 56px; padding: 6px 2px; gap: 2px; }
  .nav-toggle:not(:checked) ~ .sidebar .nav a[aria-current="page"]::before { top: 12px; bottom: 12px; }
  .nav-toggle:checked ~ .sidebar :is(.nav a, .foot-link) { height: 44px; }
  .content { padding-top: 16px; padding-bottom: calc(24px + var(--safe-bottom)); }
  .page-header { margin-bottom: 12px; }
  .page-header h1 { font-size: 20px; }
  .page-header .subtitle { display: none; }
  .review-actions { padding-top: 8px; padding-bottom: calc(8px + var(--safe-bottom)); }
  .review-head { padding-top: 12px; padding-bottom: 12px; }
  .review-body { padding-top: 16px; }
}

/* ---------- Touch screens ---------- */

/* Every control is at least 44px on a touch screen (DESIGN.md's 40px is for
   the mouse), and fields use 16px text so Safari does not zoom in when the
   on-screen keyboard opens. Keyboard hints are hidden: the buttons are
   always there, and the keys still work with a keyboard. */
@media (pointer: coarse) {
  .btn, .btn-small { height: 44px; }
  .btn-icon, .review-nav { width: 44px; }
  .nav a, .foot-link, .chip { min-height: 44px; }
  .nav a, .foot-link { height: 44px; }
  .picker-row select { height: 44px; min-height: 44px; font-size: 16px; padding: 0 4px 0 8px; }
  .picker-row .btn { padding: 0 10px; min-width: 44px; }
  input[type="text"], input[type="email"], input[type="url"], input[type="number"], input[type="password"],
  input[type="time"], input[type="search"], input[type="file"], select, textarea { min-height: 44px; font-size: 16px; }
  input[type="file"]::file-selector-button { height: 44px; font-size: 16px; }
  input[type="checkbox"] { width: 22px; height: 22px; }
  .check { min-height: 44px; }
  .select-hit { min-width: 44px; min-height: 44px; margin: -11px; }
  th.select-cell, td.select-cell { width: 56px; }
  td a.sub { display: flex; align-items: center; gap: 4px; min-height: 44px; }
  td details summary { display: flex; align-items: center; min-height: 44px; }
  /* The 44px target of "dónde" overlaps the line around it instead of
     stretching it. */
  .cell-list a.small { display: inline-flex; align-items: center; min-height: 44px; margin-block: -12px; padding: 0 4px; vertical-align: middle; }
  .followup summary { min-height: 52px; }
  .recovery-entry summary, .back-link { min-height: 44px; }
  .help-button { width: 44px; height: 44px; }
  .help-toc a { min-height: 44px; }
  /* A link alone in a list item or a table cell ("Ver también") is a full
     44px row, like "En esta página". */
  .guide-body .link-item > a, .guide-body .link-cell > a { display: inline-flex; align-items: center; min-width: 44px; min-height: 44px; }
  .help-link { width: 44px; height: 44px; margin: -12px -10px; }
  .toast-close { width: 44px; height: 44px; margin: -10px -10px -10px 0; }
  .btn kbd, .keys-hint { display: none; }
}
@media (pointer: coarse) and (min-width: 1024px) {
  .nav a, .foot-link { height: 48px; }
}

/* ---------- Motion ---------- */

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition: none !important; animation: none !important; }
  .btn:active { transform: none; }
  /* Toasts still go away on time, only without moving. */
  .toast { animation: toast-hide 1ms linear 5s forwards !important; }
  .toast.is-error { animation-delay: 8s !important; }
}
