:root {
  /* The app's dark/light theme is entirely custom (this file's CSS
     variables + theme.js's [data-theme] attribute) - native form controls
     (date picker icon/popup, scrollbars, etc.) don't follow that on their
     own, they follow the `color-scheme` property instead. Without this,
     input[type="date"]'s calendar icon renders light-mode regardless of
     the app's actual theme - on mobile in dark mode it's effectively
     invisible against the dark background. Set on :root (not just .input)
     so every native control benefits, not only date inputs. Attribute
     selectors are live, so this also updates immediately when
     SinpeGuardTheme.toggle() flips [data-theme] - no extra JS needed. */
  color-scheme: light;
  --bg: #f5f7f6;
  --surface: #ffffff;
  --surface-2: #edf2ef;
  --surface-3: #e4ebe6;
  --text: #172019;
  --muted: #68736b;
  --line: #dbe3dd;
  --green: #1f9d45;
  --green-2: #39c760;
  --green-soft: #e2f6e7;
  --yellow: #a67600;
  --yellow-soft: #fff2c2;
  --red: #c63232;
  --red-soft: #fde4e4;
  --blue: #2676d9;
  --shadow: 0 14px 40px rgba(18, 32, 22, .08);
  --radius: 18px;
}

html[data-theme="dark"] {
  color-scheme: dark;
  --bg: #0d1113;
  --surface: #14191c;
  --surface-2: #1b2226;
  --surface-3: #232c31;
  --text: #f3f6f4;
  --muted: #a5b0a8;
  --line: #2c363b;
  --green: #40d063;
  --green-2: #61e27c;
  --green-soft: #15371f;
  --yellow: #f1c94f;
  --yellow-soft: #3e3517;
  --red: #ff6262;
  --red-soft: #441f21;
  --blue: #66a8ff;
  --shadow: 0 18px 50px rgba(0, 0, 0, .30);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  transition: background .2s ease, color .2s ease;
}
a { color: inherit; text-decoration: none; }
button, input, select { font: inherit; }
button { cursor: pointer; }
.container { width: min(1180px, calc(100% - 36px)); margin: 0 auto; }
.card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}
.btn {
  border: 0;
  border-radius: 12px;
  padding: 13px 16px;
  font-weight: 750;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  white-space: nowrap;
}
/* [hidden] and .btn's own display:inline-flex are equal specificity - without
   this, .btn's rule (declared after the UA stylesheet) wins the cascade and
   silently keeps a hidden .btn element visible. Affected both the
   REVIEW-row and Gmail-disconnect confirm/cancel buttons before this was
   added - found while screenshot-verifying the Gmail ERROR-state UI. */
.btn[hidden] { display: none; }
/* No app-wide rule existed for this at all before - found 2026-08-26 while
   screenshot-verifying merchant-admin's new credential-reveal ack-gate on a
   real device: the "Listo, ocultar" button was genuinely disabled
   (unclickable) but rendered fully green/active, indistinguishable from an
   enabled button - a merchant would have no visual cue they need to check
   the box first. Only scoped disabled styles existed before
   (.row-actions .btn:disabled, .table-action:disabled in merchant.css) -
   this is the one place .btn itself is styled, so it belongs here, not
   duplicated per-app. */
.btn:disabled { opacity: .5; cursor: not-allowed; }
.btn-primary { background: var(--green); color: white; }
.btn-ghost { background: var(--surface-2); color: var(--text); border: 1px solid var(--line); }
.btn-danger { background: var(--red-soft); color: var(--red); border: 1px solid color-mix(in srgb, var(--red) 25%, transparent); }
.muted { color: var(--muted); }
/* Real loading placeholder, not a hardcoded fake value or raw "Cargando"
   text shown while the real data is still in flight - a shared utility
   since both merchant-admin and platform-admin had the same flicker. */
.skeleton {
  display: inline-block; min-width: 2.4em; height: 1em; border-radius: 5px;
  background: var(--surface-2);
  animation: skeleton-pulse 1.1s ease-in-out infinite;
}
@keyframes skeleton-pulse { 0%, 100% { opacity: 0.55; } 50% { opacity: 1; } }
.badge {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 6px 9px; border-radius: 999px; font-size: 12px; font-weight: 800;
}
.accepted { color: var(--green); background: var(--green-soft); }
.review { color: var(--yellow); background: var(--yellow-soft); }
.rejected { color: var(--red); background: var(--red-soft); }
.pending { color: var(--muted); background: var(--surface-2); }
.theme-toggle {
  width: 44px; height: 44px; border-radius: 12px; border: 1px solid var(--line);
  background: var(--surface); color: var(--text);
}
.input {
  width: 100%; padding: 11px 12px; border-radius: 11px;
  border: 1px solid var(--line); background: var(--surface); color: var(--text);
  outline: none;
}
.input:focus { border-color: var(--green); box-shadow: 0 0 0 3px color-mix(in srgb, var(--green) 13%, transparent); }
.logo { display: flex; align-items: center; gap: 10px; font-weight: 850; font-size: 20px; }
.logo-mark {
  width: 34px; height: 34px; border-radius: 11px;
  display: grid; place-items: center; background: var(--green-soft); color: var(--green);
  font-size: 20px;
}
