@charset "UTF-8";

/* ───────────────────────────────────────────────────────────
   site-brand.css inline (avoid render-blocking @import request)
   ─────────────────────────────────────────────────────────── */
:root {
  --shell-bg: rgba(5, 13, 28, 0.86);
  --shell-bg-strong: rgba(6, 15, 31, 0.94);
  --shell-surface: rgba(10, 21, 41, 0.78);
  --shell-border: rgba(188, 210, 255, 0.14);
  --shell-text: #edf4ff;
  --shell-muted: rgba(237, 244, 255, 0.72);
  --shell-accent: #2d6dff;
  --shell-accent-strong: #1b52ce;
  --shell-shadow: 0 18px 40px rgba(0, 0, 0, 0.24);
  --shell-radius: 18px;
  --shell-topbar-height: 66px;
  --shell-max-width: min(1280px, calc(100% - 1rem));
  --surface: rgba(16, 32, 64, 0.9);
  --border: rgba(220, 234, 255, 0.16);
  --text: #eaf3ff;
  --muted: rgba(234, 243, 255, 0.74);
  --shadow-lg: 0 22px 56px rgba(0, 0, 0, 0.4);
}

html[data-tema="claro"] {
  --shell-bg: rgba(255, 255, 255, 0.86);
  --shell-bg-strong: rgba(248, 251, 255, 0.94);
  --shell-surface: rgba(255, 255, 255, 0.84);
  --shell-border: rgba(18, 38, 74, 0.1);
  --shell-text: #0d1b34;
  --shell-muted: rgba(13, 27, 52, 0.66);
  --shell-accent: #2d6dff;
  --shell-accent-strong: #1b52ce;
  --shell-shadow: 0 18px 36px rgba(16, 34, 67, 0.12);
  --surface: rgba(255, 255, 255, 0.9);
  --border: rgba(32, 64, 119, 0.14);
  --text: #10203f;
  --muted: rgba(16, 32, 63, 0.72);
  --shadow-lg: 0 18px 44px rgba(35, 65, 118, 0.14);
}

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

.shell-topbar {
  position: sticky;
  top: 0;
  z-index: 1200;
  border-bottom: 1px solid var(--shell-border);
  background: var(--shell-bg);
  backdrop-filter: blur(18px);
  box-shadow: 0 10px 28px rgba(0, 0, 0, 0.16);
}

[id] {
  scroll-margin-top: calc(var(--shell-topbar-height) + 1.2rem);
}

.shell-topbar__inner {
  width: var(--shell-max-width);
  min-height: var(--shell-topbar-height);
  margin: 0 auto;
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 0.9rem;
}

.shell-topbar--public .shell-topbar__inner {
  column-gap: 1.15rem;
  row-gap: 0.6rem;
}

.shell-topbar--public .shell-topbar__brand {
  margin-inline-end: 0.2rem;
}

.shell-topbar--public .shell-topbar__nav ul {
  column-gap: 0.45rem;
  row-gap: 0.25rem;
  flex-wrap: wrap;
  justify-content: center;
}

.shell-topbar--public .shell-topbar__actions {
  flex-shrink: 0;
  margin-inline-start: 0.25rem;
}

.shell-topbar__brand {
  display: inline-flex;
  align-items: center;
  justify-content: flex-start;
  gap: 0.72rem;
  min-width: 52px;
  height: 52px;
  padding: 0 0.82rem 0 0.5rem;
  border-radius: 16px;
  border: 1px solid var(--shell-border);
  background: rgba(255, 255, 255, 0.02);
  flex: none;
}

.shell-topbar__brand:hover {
  text-decoration: none;
  border-color: rgba(255, 255, 255, 0.22);
}

.shell-topbar__brand-symbol {
  width: 36px;
  height: 36px;
  display: block;
  object-fit: contain;
}

.shell-topbar__brand-copy {
  display: inline-flex;
  align-items: center;
  min-width: 0;
}

.shell-topbar__brand-name {
  display: block;
  max-width: 220px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  color: var(--shell-text);
  font-size: 0.98rem;
  font-weight: 900;
  letter-spacing: -0.01em;
}

.shell-topbar__nav {
  min-width: 0;
}

.shell-topbar--app .shell-topbar__nav {
  overflow-x: auto;
  overflow-y: hidden;
  scrollbar-width: thin;
  -webkit-overflow-scrolling: touch;
}

.shell-topbar--app .shell-topbar__nav ul {
  width: max-content;
  min-width: 100%;
  justify-content: flex-start;
  padding-inline: 0.15rem;
}

.shell-topbar--app .shell-topbar__actions {
  flex-shrink: 0;
}

.shell-topbar--app .shell-topbar__brand {
  flex-shrink: 0;
  position: relative;
  z-index: 2;
}

.shell-topbar__nav ul {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.2rem;
}

.shell-topbar__nav a {
  display: inline-flex;
  align-items: center;
  min-height: 42px;
  padding: 0 0.8rem;
  border-radius: 999px;
  color: var(--shell-muted);
  text-decoration: none;
  font-size: 0.92rem;
  font-weight: 700;
  white-space: nowrap;
}

.shell-topbar__nav-mobile-only {
  display: none;
}

@media (max-width: 640px) {
  .shell-topbar__nav-mobile-only {
    display: list-item;
  }
}

.shell-topbar__nav a:hover,
.shell-topbar__nav a.is-active {
  color: var(--shell-text);
  background: rgba(255, 255, 255, 0.08);
}

.shell-topbar__actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 0.55rem;
}

.shell-action {
  position: relative;
  min-height: 42px;
  padding: 0 0.95rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.45rem;
  border-radius: 14px;
  border: 1px solid var(--shell-border);
  color: var(--shell-text);
  text-decoration: none;
  background: rgba(255, 255, 255, 0.04);
  font-size: 0.92rem;
  font-weight: 800;
  line-height: 1;
}

.shell-action:hover {
  text-decoration: none;
  border-color: rgba(255, 255, 255, 0.22);
}

.shell-action--ghost {
  color: var(--shell-text);
}

.shell-action--primary,
.shell-action--user {
  border-color: rgba(45, 109, 255, 0.42);
  background: linear-gradient(180deg, var(--shell-accent), var(--shell-accent-strong));
  color: #ffffff;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.2);
}

.shell-action--icon {
  min-width: 42px;
  width: 42px;
  padding: 0;
}

.shell-action__icon--svg svg {
  display: block;
  width: 1.35rem;
  height: 1.35rem;
}

.shell-user-menu {
  position: relative;
}

.shell-user-menu summary {
  list-style: none;
  cursor: pointer;
}

.shell-user-menu summary::-webkit-details-marker {
  display: none;
}

.shell-user-menu__panel {
  position: absolute;
  top: calc(100% + 10px);
  right: 0;
  min-width: 220px;
  padding: 10px;
  display: grid;
  gap: 6px;
  border-radius: 16px;
  border: 1px solid var(--shell-border);
  background: var(--shell-bg-strong);
  box-shadow: var(--shell-shadow);
}

.shell-user-menu:not([open]) .shell-user-menu__panel {
  display: none;
}

.shell-user-menu__item {
  display: flex;
  align-items: center;
  min-height: 40px;
  padding: 0 12px;
  border-radius: 12px;
  color: var(--shell-text);
  text-decoration: none;
  font-size: 0.9rem;
  font-weight: 700;
}

.shell-user-menu__item:hover,
.shell-user-menu__item.is-active {
  text-decoration: none;
  background: rgba(255, 255, 255, 0.08);
}

.shell-user-menu__item.is-danger {
  color: #ffb3b0;
}

.shell-action__icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 1.05rem;
  line-height: 1;
}

.shell-action__label {
  color: inherit;
}

.shell-action__badge,
.shell-chat-fab__badge {
  position: absolute;
  top: -5px;
  right: -5px;
  min-width: 20px;
  height: 20px;
  padding: 0 6px;
  border-radius: 999px;
  background: #ff5f66;
  color: #ffffff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 0.72rem;
  font-weight: 900;
  line-height: 1;
  border: 2px solid var(--shell-bg-strong);
}

.shell-topbar__menu-toggle {
  display: none;
  width: 42px;
  height: 42px;
  padding: 0;
  border: 1px solid var(--shell-border);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.04);
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 4px;
}

.shell-topbar__menu-toggle span {
  width: 18px;
  height: 2px;
  border-radius: 999px;
  background: var(--shell-text);
}

.shell-topbar--install .shell-topbar__inner {
  grid-template-columns: minmax(0, 1fr) auto;
}

.shell-topbar__brand--install {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  border: 1px solid var(--shell-border);
  border-radius: 16px;
  padding: 0 0.85rem;
  min-height: 52px;
  background: rgba(255, 255, 255, 0.02);
}

.shell-topbar__install-mark {
  line-height: 1;
  font-size: 1.2rem;
}

.install-gate-body .brand-page-shell,
.install-body .brand-page-shell {
  min-height: calc(100vh - 200px);
}

/* Errores del instalador: contraste rojo inequívoco */
.install-alert--danger {
  border: 1px solid rgba(248, 113, 113, 0.75) !important;
  background: linear-gradient(160deg, rgba(127, 29, 29, 0.45), rgba(15, 23, 42, 0.96)) !important;
  box-shadow:
    0 0 0 1px rgba(254, 202, 202, 0.08),
    0 14px 36px rgba(0, 0, 0, 0.35);
}

.install-alert__title {
  display: block;
  color: #fecaca;
  font-size: 1.05rem;
  letter-spacing: 0.01em;
}

.install-alert__list {
  margin: 0.65rem 0 0;
  padding-left: 1.25rem;
  color: #fee2e2;
  line-height: 1.5;
}

.install-alert__list li {
  margin-top: 0.35rem;
}

.install-alert__list li::marker {
  color: #f87171;
}

.install-alert--inline {
  padding: 0.85rem 1rem;
  border-radius: 14px;
  margin-bottom: 0.5rem;
  font-weight: 600;
  color: #fee2e2;
}

html[data-tema="claro"] .install-alert--danger {
  border-color: rgba(185, 28, 28, 0.55) !important;
  background: linear-gradient(160deg, rgba(254, 226, 226, 0.95), rgba(255, 255, 255, 0.98)) !important;
  box-shadow: 0 8px 28px rgba(127, 29, 29, 0.12);
}

html[data-tema="claro"] .install-alert__title {
  color: #991b1b;
}

html[data-tema="claro"] .install-alert__list {
  color: #450a0a;
}

html[data-tema="claro"] .install-alert__list li::marker {
  color: #dc2626;
}

html[data-tema="claro"] .install-alert--inline {
  color: #7f1d1d;
}

.form-group--timezone {
  min-width: 0;
}

.install-timezone-select {
  width: 100%;
  max-width: 100%;
}

/* Evita que filas en grid estiren inputs (columnas altas por zona horaria + ayuda). */
.install-body .install-form .grid {
  align-items: start;
}

.install-body .install-form .form-group {
  align-content: start;
}

.install-body .install-form .form-group .install-input-single {
  align-self: start;
  min-height: 2.75rem;
  max-height: 2.75rem;
  line-height: 1.25;
}

.install-body .install-form .form-group .install-timezone-select {
  align-self: start;
  min-height: 2.75rem;
}

.install-body .install-form .install-grid-credentials .form-group {
  margin-bottom: 0;
}

.shell-footer--install {
  margin-top: 3rem;
}

.shell-footer__inner--install {
  padding-bottom: 1.25rem;
}

.shell-footer__copy--install {
  max-width: 760px;
  margin: 0 auto;
  line-height: 1.55;
}

.shell-footer {
  margin-top: 2rem;
  border-top: 1px solid var(--shell-border);
  background: var(--shell-bg-strong);
}

.shell-footer__pre {
  width: var(--shell-max-width);
  margin: 0 auto;
  padding: 1.25rem 0 0.35rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.75rem;
}

.shell-footer__socials {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  flex-wrap: wrap;
}

.shell-footer__socials a {
  width: 42px;
  height: 42px;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--shell-border);
  background: rgba(255, 255, 255, 0.04);
  color: var(--shell-text);
  text-decoration: none;
  transition: transform 0.15s ease, border-color 0.15s ease, background 0.15s ease;
}

.shell-footer__socials a:hover {
  transform: translateY(-2px);
  border-color: rgba(99, 102, 241, 0.45);
  background: rgba(99, 102, 241, 0.12);
}

.shell-footer__socials svg {
  width: 20px;
  height: 20px;
  display: block;
}

.shell-footer__slogan {
  font-size: 0.92rem;
  color: var(--shell-muted);
  text-align: center;
}

.shell-footer__slogan--flag {
  margin: 0 0 0.55rem;
  font-size: 0.82rem;
  font-weight: 800;
  letter-spacing: 0.2em;
  line-height: 1.6;
  color: var(--shell-muted);
}

.co-flag {
  letter-spacing: 0.22em;
  font-weight: 900;
}

.co-flag span {
  display: inline;
}

.co-y { color: #FCD116; }
.co-b { color: #003893; }
.co-r { color: #CE1126; }

html[data-tema="claro"] .co-y { color: #d4a800; }
html[data-tema="claro"] .co-b { color: #003078; }
html[data-tema="claro"] .co-r { color: #b80e20; }

.footer-dev-link {
  font-weight: 800;
  text-decoration: none;
  color: #e9d07b;
  background-image: linear-gradient(90deg, #f6e7a9 0%, #d8a53a 35%, #fff2c3 50%, #d8a53a 65%, #f6e7a9 100%);
  background-size: 220% 100%;
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  animation: footerGoldShift 7.2s linear infinite;
}

.footer-dev-link:hover {
  text-decoration: underline;
}

@keyframes footerGoldShift {
  0% { background-position: 0% 50%; }
  100% { background-position: 200% 50%; }
}

@media (prefers-reduced-motion: reduce) {
  .footer-dev-link { animation: none; }
}

.shell-footer__inner {
  display: block !important;
  width: var(--shell-max-width);
  margin: 0 auto;
  padding: 1rem 0 1.25rem;
  text-align: center;
}

.shell-footer__links {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.4rem 0.85rem;
  margin: 0 0 0.7rem;
}

.shell-footer__links a {
  white-space: nowrap;
}

.shell-footer__links a,
.shell-footer__copy {
  font-size: 0.88rem;
  color: var(--shell-muted);
}

.shell-footer__copy {
  text-align: center;
  margin: 0 0 0.7rem;
  line-height: 1.55;
}

.shell-footer__links a:hover {
  color: var(--shell-text);
  text-decoration: none;
}

html[data-cookie-dismissed='1'] .brand-cookie-banner {
  display: none !important;
}

.brand-cookie-banner {
  position: fixed;
  left: 50%;
  bottom: 1rem;
  transform: translateX(-50%);
  z-index: 1350;
  width: min(760px, calc(100% - 1rem));
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1rem;
  flex-wrap: wrap;
  padding: 0.85rem 1rem;
  border-radius: 18px;
  border: 1px solid var(--shell-border);
  background: var(--shell-bg-strong);
  box-shadow: var(--shell-shadow);
}

.brand-cookie-banner p {
  margin: 0;
  color: var(--shell-text);
  font-size: 0.92rem;
  flex: 1 1 100%;
  text-align: center;
}

.brand-cookie-banner button {
  min-height: 40px;
  padding: 0 1rem;
  border: 0;
  border-radius: 12px;
  background: linear-gradient(180deg, var(--shell-accent), var(--shell-accent-strong));
  color: #ffffff;
  font-weight: 800;
  cursor: pointer;
}

.brand-cookie-banner__actions {
  display: flex;
  gap: 0.5rem;
  flex-shrink: 0;
  width: 100%;
  justify-content: center;
}

.brand-cookie-banner__prefs-btn {
  min-height: 40px;
  padding: 0 1rem;
  border: 1px solid var(--shell-border);
  border-radius: 12px;
  background: transparent;
  color: var(--shell-text);
  font-weight: 700;
  cursor: pointer;
  white-space: nowrap;
}

.brand-cookie-banner.is-hidden {
  display: none;
}

/* ── Cookie Preferences Modal ── */
.cookie-prefs-overlay {
  position: fixed;
  inset: 0;
  z-index: 1400;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(0, 0, 0, 0.55);
  backdrop-filter: blur(6px);
}

.cookie-prefs-overlay.is-hidden {
  display: none;
}

.cookie-prefs-panel {
  width: min(480px, calc(100% - 2rem));
  background: var(--shell-bg-strong);
  border: 1px solid var(--shell-border);
  border-radius: 20px;
  box-shadow: 0 24px 56px rgba(0, 0, 0, 0.4);
  padding: 1.5rem;
  display: grid;
  gap: 1rem;
}

.cookie-prefs-panel__header {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.cookie-prefs-panel__header h2 {
  margin: 0;
  font-size: 1.1rem;
  color: var(--shell-text);
}

.cookie-prefs-panel__hint {
  font-size: 0.78rem;
  color: var(--shell-muted);
  padding: 0.25rem 0.65rem;
  border: 1px solid var(--shell-border);
  border-radius: 999px;
}

.cookie-prefs-panel__intro {
  margin: 0;
  font-size: 0.88rem;
  color: var(--shell-muted);
}

.cookie-prefs-panel__group {
  display: grid;
  gap: 0;
}

.cookie-prefs-panel__row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.85rem 0.75rem;
  border: 1px solid var(--shell-border);
  background: rgba(255, 255, 255, 0.03);
}

.cookie-prefs-panel__row:first-child {
  border-radius: 14px 14px 0 0;
}

.cookie-prefs-panel__row:last-child {
  border-radius: 0 0 14px 14px;
  border-top: 0;
}

.cookie-prefs-panel__row strong {
  display: block;
  font-size: 0.92rem;
  color: var(--shell-text);
}

.cookie-prefs-panel__row span {
  font-size: 0.8rem;
  color: var(--shell-muted);
}

.cookie-prefs-panel__tag {
  white-space: nowrap;
  font-size: 0.78rem !important;
  font-weight: 700;
  padding: 0.2rem 0.6rem;
  border-radius: 999px;
  border: 1px solid var(--shell-border);
  color: var(--shell-muted) !important;
}

.cookie-prefs-toggle {
  position: relative;
  display: inline-block;
  width: 46px;
  height: 26px;
  flex-shrink: 0;
}

.cookie-prefs-toggle input {
  opacity: 0;
  width: 0;
  height: 0;
  position: absolute;
}

.cookie-prefs-toggle__track {
  position: absolute;
  inset: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.12);
  border: 1px solid var(--shell-border);
  cursor: pointer;
  transition: background 0.2s;
}

.cookie-prefs-toggle__track::after {
  content: '';
  position: absolute;
  top: 3px;
  left: 3px;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: var(--shell-muted);
  transition: transform 0.2s;
}

.cookie-prefs-toggle input:checked + .cookie-prefs-toggle__track {
  background: var(--shell-accent);
  border-color: var(--shell-accent);
}

.cookie-prefs-toggle input:checked + .cookie-prefs-toggle__track::after {
  transform: translateX(20px);
  background: #ffffff;
}

.cookie-prefs-panel__actions {
  display: flex;
  justify-content: flex-end;
  gap: 0.5rem;
}

.cookie-prefs-panel__cancel {
  min-height: 40px;
  padding: 0 1rem;
  border: 1px solid var(--shell-border);
  border-radius: 12px;
  background: transparent;
  color: var(--shell-text);
  font-weight: 700;
  cursor: pointer;
}

.cookie-prefs-panel__save {
  min-height: 40px;
  padding: 0 1.2rem;
  border: 0;
  border-radius: 12px;
  background: linear-gradient(180deg, var(--shell-accent), var(--shell-accent-strong));
  color: #ffffff;
  font-weight: 800;
  cursor: pointer;
}

@media (max-width: 560px) {
  .cookie-prefs-panel__actions {
    justify-content: stretch;
    gap: 0.6rem;
  }

  .cookie-prefs-panel__cancel,
  .cookie-prefs-panel__save {
    flex: 1 1 0;
    width: 100%;
    justify-content: center;
  }
}

html[data-tema="claro"] .cookie-prefs-panel {
  background: rgba(255, 255, 255, 0.98);
  box-shadow: 0 18px 44px rgba(35, 65, 118, 0.14);
}

html[data-tema="claro"] .cookie-prefs-panel__row {
  background: rgba(0, 0, 0, 0.02);
}

html[data-tema="claro"] .cookie-prefs-toggle__track {
  background: rgba(0, 0, 0, 0.1);
}

html[data-tema="claro"] .cookie-prefs-overlay {
  background: rgba(0, 0, 0, 0.35);
}

.shell-chat-fab {
  position: fixed;
  left: auto;
  inset-inline-start: auto;
  inset-inline-end: 1rem;
  right: 1rem;
  bottom: 1rem;
  z-index: 1325;
  width: 58px;
  height: 58px;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid rgba(45, 109, 255, 0.32);
  background: linear-gradient(180deg, var(--shell-accent), var(--shell-accent-strong));
  color: #ffffff;
  text-decoration: none;
  box-shadow: 0 18px 36px rgba(13, 82, 206, 0.35);
}

.shell-chat-fab:hover {
  text-decoration: none;
  transform: translateY(-2px);
}

.shell-chat-fab__icon {
  font-size: 1.15rem;
  line-height: 1;
}

.brand-page-shell {
  width: min(1100px, calc(100% - 1rem));
  margin: 1.35rem auto 0;
  display: grid;
  gap: 1rem;
}

.brand-page-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 22px;
  box-shadow: var(--shadow-lg);
  padding: 1.35rem;
}

.brand-page-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.55rem 1rem;
  margin-bottom: 0.85rem;
  font-size: 0.82rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.brand-page-meta span {
  color: var(--muted);
}

.brand-page-content {
  display: grid;
  gap: 0.95rem;
  line-height: 1.72;
}

.brand-page-content p,
.brand-page-content li {
  color: var(--text);
}

.brand-page-content h2,
.brand-page-content h3 {
  margin-top: 0.25rem;
}

.brand-footer__socials {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
}

.brand-footer__socials a {
  width: 42px;
  height: 42px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: rgba(255, 255, 255, 0.06);
  color: var(--text);
  text-decoration: none;
  font-size: 0.78rem;
  font-weight: 900;
}

.brand-footer__socials a:hover {
  text-decoration: none;
  border-color: rgba(45, 109, 255, 0.4);
}

@media (max-width: 1004px) {
  .shell-topbar__inner {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.45rem;
    position: relative;
    padding-right: 3.05rem;
  }

  .shell-topbar__brand {
    order: 1;
    flex: 0 1 auto;
    min-width: 0;
    margin-right: auto;
  }

  .shell-topbar__actions {
    order: 2;
    gap: 0.35rem;
    flex-wrap: nowrap;
    flex-shrink: 0;
    margin-left: 0;
    margin-right: 0;
    position: absolute;
    right: calc(0.15rem + 42px + 0.35rem);
    top: 50%;
    transform: translateY(-50%);
  }

  .shell-topbar__menu-toggle {
    display: inline-flex;
    order: 3;
    margin: 0;
    position: absolute;
    right: 0.15rem;
    top: 50%;
    transform: translateY(-50%);
  }

  .shell-topbar__nav {
    display: none;
    order: 4;
    position: absolute;
    top: calc(100% + 0.35rem);
    left: 0.35rem;
    right: 0.35rem;
    z-index: 1300;
    padding: 0;
  }

  .shell-topbar__nav.is-open {
    display: block;
  }

  .shell-topbar__nav ul {
    margin: 0;
    padding: 0.45rem;
    border: 1px solid var(--shell-border);
    border-radius: 16px;
    background: #071730;
    box-shadow: var(--shell-shadow);
  }

  .shell-topbar__nav ul {
    flex-direction: column;
    align-items: stretch;
    gap: 0.35rem;
  }

  .shell-topbar__nav a {
    justify-content: flex-start;
    min-height: 40px;
    border-radius: 14px;
    padding-left: 0.9rem;
    background: rgba(255, 255, 255, 0.08);
    color: var(--shell-text);
  }

  .shell-topbar__nav-mobile-only a {
    background: rgba(255, 255, 255, 0.08);
    color: var(--shell-text) !important;
  }

  .shell-action {
    min-height: 40px;
    padding: 0 0.8rem;
  }

  .shell-action__label {
    display: none;
  }

  .shell-user-menu__panel {
    right: -4px;
    min-width: 200px;
  }

  .shell-footer__inner {
    padding-inline: 0.35rem;
  }

  .brand-cookie-banner {
    flex-direction: column;
    align-items: stretch;
  }
}

@media (max-width: 640px) {
  .shell-topbar__actions .shell-action--ghost:not(.shell-action--icon) {
    display: none;
  }
}

@media (max-width: 640px) {
  .shell-topbar__inner {
    min-height: 60px;
    width: 100%;
    gap: 0.32rem;
    padding-inline: 0.35rem;
    padding-right: 3.15rem;
    box-sizing: border-box;
  }

  .shell-topbar__brand {
    min-width: 46px;
    height: 46px;
    padding: 0 0.7rem 0 0.42rem;
    border-radius: 14px;
  }

  .shell-topbar__brand-symbol {
    width: 32px;
    height: 32px;
  }

  .shell-topbar__brand-name {
    max-width: 112px;
    font-size: 0.88rem;
  }

  .shell-action {
    min-width: 40px;
    padding: 0 0.72rem;
    border-radius: 12px;
  }

  .shell-topbar__actions {
    gap: 0.35rem;
    right: calc(0.35rem + 42px + 0.35rem);
  }

  .shell-topbar__menu-toggle {
    margin: 0;
    position: absolute;
    right: 0.35rem;
    top: 50%;
    transform: translateY(-50%);
  }

  .shell-action--user {
    padding: 0 0.9rem;
  }

  .shell-user-menu__panel {
    min-width: 188px;
  }

  .shell-footer {
    margin-top: 1.3rem;
  }

  .shell-chat-fab {
    width: 54px;
    height: 54px;
    left: auto;
    inset-inline-start: auto;
    inset-inline-end: 0.8rem;
    right: 0.8rem;
    bottom: 0.8rem;
  }

  .brand-page-card {
    padding: 1rem;
    border-radius: 18px;
  }
}

/* Topbar app en modo barra horizontal (viewport > 1004px): compactar solo anchos medios. */
@media (min-width: 1005px) and (max-width: 1280px) {
  .shell-topbar--app .shell-topbar__inner {
    gap: 0.65rem;
    padding-inline: 0.35rem;
  }

  .shell-topbar--app .shell-topbar__nav a {
    padding: 0 0.62rem;
    font-size: 0.86rem;
    min-height: 40px;
  }

  .shell-topbar--app .shell-topbar__nav ul {
    gap: 0.12rem;
    padding-inline: 0.08rem;
  }
}

@media (max-width: 480px) {
  .shell-topbar__brand {
    padding-right: 0.42rem;
  }

  .shell-topbar__brand-copy {
    display: none;
  }
}

/* ───────────────────────────────────────────────────────────
   LIGHT THEME — shell component overrides
   ─────────────────────────────────────────────────────────── */

html[data-tema="claro"] .shell-topbar {
  box-shadow: 0 6px 20px rgba(35, 65, 118, 0.08);
}

html[data-tema="claro"] .shell-topbar__brand {
  background: rgba(0, 0, 0, 0.02);
}

html[data-tema="claro"] .shell-topbar__brand:hover {
  border-color: rgba(32, 64, 119, 0.18);
}

html[data-tema="claro"] .shell-topbar__nav a:hover,
html[data-tema="claro"] .shell-topbar__nav a.is-active {
  background: rgba(32, 64, 119, 0.06);
}

html[data-tema="claro"] .shell-action:not(.shell-action--primary):not(.shell-action--user) {
  background: rgba(0, 0, 0, 0.03);
}

html[data-tema="claro"] .shell-action:not(.shell-action--primary):not(.shell-action--user):hover {
  border-color: rgba(32, 64, 119, 0.18);
}

html[data-tema="claro"] .shell-user-menu__item:hover,
html[data-tema="claro"] .shell-user-menu__item.is-active {
  background: rgba(32, 64, 119, 0.06);
}

html[data-tema="claro"] .shell-user-menu__item.is-danger {
  color: #a1323e;
}

html[data-tema="claro"] .shell-action__badge,
html[data-tema="claro"] .shell-chat-fab__badge {
  border-color: var(--shell-bg-strong);
}

html[data-tema="claro"] .shell-topbar__menu-toggle {
  background: rgba(0, 0, 0, 0.03);
}

html[data-tema="claro"] .brand-footer__socials a {
  background: rgba(0, 0, 0, 0.03);
}

html[data-tema="claro"] .shell-chat-fab {
  box-shadow: 0 12px 28px rgba(23, 76, 184, 0.22);
}

@media (max-width: 980px) {
  html[data-tema="claro"] .shell-topbar__nav ul {
    background: rgba(255, 255, 255, 0.98);
  }
}

:root,
html[data-tema="oscuro"] {
  --bg: #071227;
  --bg-soft: #0d1e3a;
  --surface: rgba(16, 32, 64, 0.9);
  --surface-strong: rgba(20, 39, 76, 0.96);
  --border: rgba(220, 234, 255, 0.16);
  --border-strong: rgba(220, 234, 255, 0.24);
  --text: #eaf3ff;
  --muted: rgba(234, 243, 255, 0.74);
  --primary: #198bff;
  --primary-strong: #0d6fdb;
  --danger: #ff6f69;
  --success: #2fd389;
  --warning: #ffcc66;
  --shadow-lg: 0 22px 56px rgba(0, 0, 0, 0.4);
  --radius-sm: 10px;
  --radius-md: 14px;
  --radius-lg: 18px;
  --space-1: 8px;
  --space-2: 12px;
  --space-3: 16px;
  --space-4: 20px;
  --space-5: 28px;
  --link: #9fd4ff;
  --link-hover: #d7ebff;
  /* Ritmo vertical único entre bloques del panel admin (un cambio afecta a todas las pantallas) */
  --portal-stack-gap: var(--space-4);
  --admin-page-bg:
    radial-gradient(1200px 760px at 10% 0%, rgba(31, 125, 255, 0.24), transparent 56%),
    radial-gradient(920px 620px at 86% 10%, rgba(20, 188, 255, 0.2), transparent 60%),
    linear-gradient(180deg, var(--bg), var(--bg-soft));
}

html[data-tema="claro"] {
  color-scheme: light;
  --bg: #f2f6ff;
  --bg-soft: #e7eefb;
  --surface: rgba(255, 255, 255, 0.88);
  --surface-strong: rgba(255, 255, 255, 0.96);
  --border: rgba(32, 64, 119, 0.14);
  --border-strong: rgba(32, 64, 119, 0.24);
  --text: #10203f;
  --muted: rgba(16, 32, 63, 0.72);
  --primary: #266cff;
  --primary-strong: #174cb8;
  --danger: #d94d5a;
  --success: #1fa86a;
  --warning: #c58917;
  --shadow-lg: 0 18px 44px rgba(35, 65, 118, 0.14);
  --link: #195ddf;
  --link-hover: #123f96;
  --scrollbar-thumb: rgba(32, 64, 119, 0.22);
  --admin-page-bg:
    radial-gradient(1000px 640px at 12% 0%, rgba(38, 108, 255, 0.12), transparent 55%),
    radial-gradient(820px 520px at 88% 8%, rgba(20, 150, 220, 0.1), transparent 58%),
    linear-gradient(180deg, var(--bg), var(--bg-soft));
  --portal-stack-gap: var(--space-4);
}

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

*::-webkit-scrollbar {
  width: 8px;
  height: 8px;
}

*::-webkit-scrollbar-track {
  background: transparent;
}

*::-webkit-scrollbar-thumb {
  background: var(--scrollbar-thumb, rgba(224, 236, 255, 0.3));
  border-radius: 999px;
}

html,
body {
  margin: 0;
  padding: 0;
}

body {
  min-height: 100dvh;
  font-family: "Inter", "Segoe UI", Roboto, Arial, sans-serif;
  color: var(--text);
  background: var(--admin-page-bg);
}

a {
  color: var(--link);
  text-decoration: none;
}

a:hover {
  color: var(--link-hover);
  text-decoration: underline;
}

h1,
h2,
h3,
h4,
h5,
h6 {
  color: var(--text);
  margin: 0 0 var(--space-2);
}

p,
span,
small,
li,
label {
  color: var(--muted);
}

ul {
  margin: var(--space-3) 0;
  padding-left: 22px;
}

.container,
.form-container,
.login,
.table-container,
.user-info-container,
.ticket-container,
.anuncio-detalle,
.faq-content,
.faq-sidebar,
.success-message,
.card,
.alert {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
}

.container,
.form-container,
.table-container,
.user-info-container,
.ticket-container,
.anuncio-detalle,
.faq-content,
.faq-sidebar,
.success-message,
.alert {
  width: min(1220px, calc(100% - 1.6rem));
  margin: 24px auto;
  padding: var(--space-4);
}

.login {
  width: min(980px, calc(100% - 1.6rem));
  margin: 24px auto;
  padding: var(--space-4);
}

.admin-container {
  width: min(1240px, calc(100% - 1.4rem));
  margin: 16px auto 28px;
}

.content-area {
  width: 100%;
  padding-top: var(--space-3);
}

/* —— Layout admin: misma separación entre secciones en todo el portal —— */
.content-area.admin-container {
  display: flex;
  flex-direction: column;
  gap: var(--portal-stack-gap);
  padding-bottom: var(--space-4);
}

.content-area.admin-container > .container,
.content-area.admin-container > section.container {
  margin-top: 0 !important;
  margin-bottom: 0 !important;
}

.admin-container .content-area > .page-shell,
.admin-container .content-area > main.page-shell,
.content-area.admin-container > main.page-shell,
.content-area.admin-container > main.page-shell.page-shell--tight {
  display: flex;
  flex-direction: column;
  gap: var(--portal-stack-gap);
  width: min(1240px, calc(100% - 1rem));
  margin-left: auto;
  margin-right: auto;
  margin-top: 0;
  margin-bottom: 0;
  padding-top: 0;
  padding-bottom: 0;
}

.admin-container .page-shell--tight {
  margin-top: 0 !important;
  margin-bottom: 0 !important;
}

.admin-container .page-shell > .page-section,
.admin-container .page-shell > .table-container,
.admin-container .page-shell > .table-card,
main.admin-container .page-shell > .page-section,
main.admin-container .page-shell > .table-container,
main.admin-container .page-shell > .table-card,
.content-area.admin-container > main.page-shell > .page-section,
.content-area.admin-container > main.page-shell > .table-container,
.content-area.admin-container > main.page-shell > .table-card,
.content-area.admin-container > main.page-shell--tight > .report-hero,
.content-area.admin-container > main.page-shell--tight > .report-filter-bar,
.content-area.admin-container > main.page-shell--tight > .report-section,
.content-area.admin-container > main.page-shell--tight > section {
  margin-left: 0 !important;
  margin-right: 0 !important;
  margin-top: 0 !important;
  margin-bottom: 0 !important;
  width: 100% !important;
  max-width: 100% !important;
}

main.admin-container {
  display: flex;
  flex-direction: column;
  align-items: stretch;
}

main.admin-container > .content-area {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: var(--portal-stack-gap);
  width: 100%;
  max-width: 100%;
}

main.admin-container > .content-area > .page-shell {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: var(--portal-stack-gap);
  width: 100%;
  max-width: min(1240px, calc(100% - 1rem));
  margin-left: auto;
  margin-right: auto;
  padding-top: 0;
  padding-bottom: 0;
}

main.admin-container .page-shell > .page-section,
main.admin-container .page-shell > .table-container,
main.admin-container .page-shell > .table-card {
  margin-left: 0 !important;
  margin-right: 0 !important;
  margin-top: 0 !important;
  margin-bottom: 0 !important;
  width: 100% !important;
  max-width: 100% !important;
}

.header {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 1100;
  display: flex;
  align-items: center;
  gap: var(--space-2);
  min-height: 64px;
  padding: 10px 14px;
  background: rgba(8, 19, 40, 0.88);
  border-bottom: 1px solid var(--border);
  backdrop-filter: blur(12px);
}

.header nav {
  display: flex;
  align-items: center;
  gap: 8px;
  width: 100%;
  overflow-x: auto;
  padding-bottom: 2px;
}

.header nav a,
.dropbtn {
  border: 1px solid transparent;
  border-radius: 10px;
  padding: 9px 12px;
  color: var(--text);
  background: transparent;
  font-size: 13px;
  font-weight: 700;
  white-space: nowrap;
}

.header nav a:hover,
.dropbtn:hover {
  background: rgba(255, 255, 255, 0.08);
  text-decoration: none;
}

.header nav a.active,
.dropbtn.active {
  background: rgba(23, 142, 255, 0.2);
  border-color: rgba(23, 142, 255, 0.45);
  color: #ffffff;
}

.menu-button {
  display: none;
  align-items: center;
  justify-content: center;
  min-height: 40px;
  border-radius: 11px;
  padding: 0 14px;
  border: 1px solid rgba(24, 136, 245, 0.5);
  background: linear-gradient(180deg, var(--primary), var(--primary-strong));
  color: #ffffff;
  font-size: 13px;
  font-weight: 800;
  cursor: pointer;
}

.dropdown {
  position: relative;
}

.dropdown-content {
  display: none;
  position: absolute;
  top: calc(100% + 8px);
  left: 0;
  min-width: 240px;
  max-height: min(70vh, 520px);
  overflow: auto;
  background: var(--surface-strong);
  border: 1px solid var(--border-strong);
  border-radius: 12px;
  box-shadow: var(--shadow-lg);
  padding: 8px;
}

.dropdown:hover .dropdown-content,
.dropdown:focus-within .dropdown-content {
  display: block;
}

.dropdown-content a {
  display: block;
  margin: 2px 0;
  padding: 9px 10px;
  border-radius: 9px;
  color: var(--text);
}

.dropdown-content a:hover,
.dropdown-content a.active {
  background: rgba(255, 255, 255, 0.1);
  text-decoration: none;
}

.form-group {
  display: grid;
  gap: 10px;
  text-align: left;
  margin-bottom: 14px;
}

.stack-form {
  display: grid;
  gap: 14px;
}

.grid {
  display: grid;
  gap: 14px;
  margin: 14px 0;
}

.grid.cols-2 {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.grid.cols-3 {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.grid.cols-4 {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.inline-form {
  display: inline-flex;
  margin: 0;
}

.personas-actions {
  display: flex;
  flex-direction: row;
  flex-wrap: nowrap;
  gap: 6px;
  align-items: center;
  justify-content: flex-start;
}

.portal-row-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 34px;
  width: 34px;
  height: 34px;
  padding: 0;
  border-radius: var(--radius-md);
  border: 1px solid var(--border);
  background: rgba(255, 255, 255, 0.05);
  font-size: 1.05rem;
  line-height: 1;
  text-decoration: none;
  color: inherit;
  cursor: pointer;
  box-sizing: border-box;
  flex-shrink: 0;
}

a.portal-row-icon:hover {
  background: rgba(255, 255, 255, 0.1);
  text-decoration: none;
  color: inherit;
}

button.portal-row-icon {
  font: inherit;
}

.portal-row-icon--danger {
  border-color: rgba(248, 113, 113, 0.45);
  color: #f87171;
}

.portal-row-icon--danger:hover {
  background: rgba(248, 113, 113, 0.12);
}

.link-btn--danger {
  color: #f87171;
  border-color: rgba(248, 113, 113, 0.35);
}

.checkbox-row {
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 44px;
}

.checkbox-inline {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-height: 44px;
}

.checkbox-row input[type="checkbox"] {
  width: 18px;
  min-height: 18px;
  margin: 0;
}

.checkbox-inline input[type="checkbox"] {
  width: 18px;
  min-height: 18px;
  margin: 0;
}

.badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 28px;
  border-radius: 999px;
  padding: 0 10px;
  font-size: 12px;
  font-weight: 800;
}

.badge-success {
  background: rgba(47, 211, 137, 0.18);
  color: #cbffe8;
  border: 1px solid rgba(47, 211, 137, 0.34);
}

.badge-danger {
  background: rgba(255, 111, 105, 0.18);
  color: #ffd7d4;
  border: 1px solid rgba(255, 111, 105, 0.34);
}

.badge-neutral {
  background: rgba(159, 212, 255, 0.16);
  color: #d6efff;
  border: 1px solid rgba(159, 212, 255, 0.3);
}

.form-group label {
  display: block;
  font-weight: 700;
  color: var(--muted);
}

input,
select,
textarea {
  width: 100%;
  min-height: 44px;
  border-radius: 12px;
  border: 1px solid var(--border-strong);
  background: rgba(255, 255, 255, 0.08);
  color: var(--text);
  padding: 10px 12px;
  font: inherit;
}

input::placeholder,
textarea::placeholder {
  color: rgba(232, 243, 255, 0.62);
}

input:focus,
select:focus,
textarea:focus {
  outline: none;
  border-color: rgba(24, 138, 252, 0.72);
  box-shadow: 0 0 0 3px rgba(24, 138, 252, 0.24);
}

select[multiple] {
  min-height: 120px;
}

input[type="file"] {
  padding: 10px;
  cursor: pointer;
}

textarea {
  min-height: 120px;
  resize: vertical;
}

input.invalid,
select.invalid,
.invalid {
  border-color: rgba(255, 111, 105, 0.9) !important;
  background: rgba(255, 111, 105, 0.14) !important;
}

button,
input[type="submit"],
.btn,
.btn-primary,
.btn-large,
.btn-block {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 42px;
  border-radius: 11px;
  border: 1px solid rgba(24, 138, 252, 0.5);
  background: linear-gradient(180deg, var(--primary), var(--primary-strong));
  color: #ffffff;
  font-size: 14px;
  font-weight: 800;
  line-height: 1;
  padding: 0 16px;
  cursor: pointer;
  transition: transform 0.18s ease, box-shadow 0.18s ease, filter 0.18s ease;
  text-decoration: none;
}

button:hover,
input[type="submit"]:hover,
.btn:hover {
  transform: translateY(-1px);
  box-shadow: 0 10px 22px rgba(11, 80, 160, 0.32);
  filter: brightness(1.05);
  text-decoration: none;
}

button:disabled,
input[type="submit"]:disabled,
.btn:disabled {
  opacity: 0.62;
  cursor: not-allowed;
  transform: none;
  box-shadow: none;
}

.btn-block,
.btn.btn-block {
  width: 100%;
}

.btn-large,
.btn.btn-large {
  min-height: 46px;
  font-size: 15px;
}

.btn-small,
.small-btn {
  min-height: 34px;
  padding: 0 12px;
  font-size: 12px;
}

.btn-danger {
  border-color: rgba(255, 111, 105, 0.7);
  background: linear-gradient(180deg, #ff7d75, #d44f48);
}

.error,
.alert.error {
  border: 1px solid rgba(255, 111, 105, 0.52);
  background: rgba(255, 111, 105, 0.14);
  color: #ffd3d0;
  border-radius: 12px;
  padding: 11px 12px;
  margin: 12px 0;
}

.success,
.alert.success {
  border: 1px solid rgba(47, 211, 137, 0.52);
  background: rgba(47, 211, 137, 0.14);
  color: #c9ffe7;
  border-radius: 12px;
  padding: 11px 12px;
  margin: 12px 0;
}

.message {
  border: 1px solid rgba(159, 212, 255, 0.45);
  background: rgba(159, 212, 255, 0.12);
  color: #dbf1ff;
  border-radius: 12px;
  padding: 11px 12px;
  margin: 12px 0;
}

.notification {
  border: 1px solid rgba(255, 204, 102, 0.52);
  background: rgba(255, 204, 102, 0.14);
  color: #ffe8b8;
  border-radius: 12px;
  padding: 10px 12px;
}

#copyAlert {
  color: #9cf6c6;
}

table,
#logTable,
.styled-table,
.webs-table {
  width: 100%;
  border-collapse: collapse;
}

table th,
table td,
#logTable th,
#logTable td,
.styled-table th,
.styled-table td,
.webs-table th,
.webs-table td {
  border: 1px solid rgba(220, 234, 255, 0.2);
  padding: 10px;
  text-align: center;
  color: var(--text);
  vertical-align: middle;
}

table th,
#logTable th,
.styled-table thead tr,
.webs-table th {
  background: rgba(19, 40, 76, 0.9);
  color: #f5f9ff;
  font-weight: 800;
}

table tr:nth-child(even),
#logTable tr:nth-child(even),
.styled-table tbody tr:nth-child(even),
.webs-table tr:nth-child(even) {
  background: rgba(255, 255, 255, 0.03);
}

table tr:hover,
#logTable tr:hover,
.styled-table tbody tr:hover,
.webs-table tr:hover {
  background: rgba(255, 255, 255, 0.08);
}

.table-container {
  overflow: auto;
}

.options,
.filter-buttons,
.actions,
.button-container,
.dynamic-buttons {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  margin-bottom: 14px;
}

.options a,
.filter-buttons button,
.link-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 40px;
  border-radius: 10px;
  border: 1px solid rgba(24, 138, 252, 0.5);
  background: linear-gradient(180deg, var(--primary), var(--primary-strong));
  color: #fff;
  font-size: 13px;
  font-weight: 800;
  padding: 0 14px;
}

.options a.active {
  border-color: rgba(47, 211, 137, 0.55);
  background: rgba(47, 211, 137, 0.2);
}

.filter input[type="date"],
.filter input[type="month"],
.filter select,
.small-select {
  min-height: 40px;
}

.tab {
  margin-bottom: 12px;
  border: 1px solid rgba(220, 234, 255, 0.18);
  border-radius: 14px;
  padding: 14px;
  background: rgba(255, 255, 255, 0.03);
}

.tab h2 {
  margin-bottom: 10px;
}

.small-text,
.file-info {
  display: block;
  font-size: 12px;
  color: var(--muted);
  margin: 2px 0 4px;
}

.ticket-messages {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.ticket-message {
  max-width: min(760px, 100%);
  border: 1px solid rgba(220, 234, 255, 0.2);
  border-radius: 13px;
  padding: 12px;
  background: rgba(255, 255, 255, 0.04);
}

.ticket-message.admin,
.ticket-message.manager {
  align-self: flex-end;
  background: rgba(24, 137, 251, 0.16);
}

.ticket-message.user {
  align-self: flex-start;
  background: rgba(255, 255, 255, 0.06);
}

.ticket-message-header {
  display: flex;
  justify-content: space-between;
  gap: 10px;
}

.ticket-message img {
  max-width: 100%;
  border-radius: 8px;
}

.anuncios-flotantes {
  position: sticky;
  top: 72px;
  z-index: 900;
  text-align: center;
  margin-bottom: 14px;
}

.anuncio-flotante {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  border-radius: 10px;
  padding: 9px 11px;
  margin: 0 auto 8px;
  max-width: min(95vw, 950px);
}

.anuncio-flotante p {
  margin: 0;
  color: #ffffff;
}

.anuncio-flotante a,
.anuncio-flotante button {
  background: transparent;
  border: none;
  color: #ffffff;
  cursor: pointer;
}

.faq-section {
  margin-top: 10px;
}

.faq {
  border: 1px solid rgba(220, 234, 255, 0.18);
  border-radius: 10px;
  padding: 11px;
  margin-bottom: 8px;
  cursor: pointer;
  background: rgba(255, 255, 255, 0.03);
  color: var(--text);
}

.faq-answer {
  display: none;
  border: 1px solid rgba(220, 234, 255, 0.18);
  border-top: none;
  border-radius: 0 0 10px 10px;
  padding: 11px;
  margin-top: -8px;
  margin-bottom: 10px;
  background: rgba(255, 255, 255, 0.02);
  color: var(--muted);
}

.faq-answer.show {
  display: block;
}

.modal {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 2000;
  background: rgba(3, 8, 19, 0.66);
  padding: 20px;
}

.modal-content {
  width: min(560px, 100%);
  margin: 12vh auto 0;
  background: var(--surface-strong);
  border: 1px solid var(--border-strong);
  border-radius: 14px;
  padding: 18px;
  color: var(--text);
}

.modal p {
  color: var(--text);
}

.close {
  float: right;
  font-size: 28px;
  color: var(--muted);
  cursor: pointer;
}

.close:hover {
  color: #ffffff;
}

.back-link {
  display: inline-flex;
  margin-bottom: 12px;
  color: #9fd4ff;
  text-decoration: underline;
}

#log-container,
#errorMesage {
  border-radius: 10px;
}

#errorMesage {
  position: fixed;
  top: 16px;
  left: 50%;
  transform: translateX(-50%);
  background: rgba(255, 111, 105, 0.18);
  border: 1px solid rgba(255, 111, 105, 0.6);
  color: #ffd3d0;
  padding: 10px 12px;
  z-index: 2500;
}

.domain-blue {
  background-color: rgba(55, 135, 255, 0.2);
  border: 1px solid rgba(55, 135, 255, 0.9);
  padding: 2px 6px;
  border-radius: 999px;
}

.domain-yellow {
  background-color: rgba(255, 218, 84, 0.2);
  border: 1px solid rgba(255, 218, 84, 0.9);
  padding: 2px 6px;
  border-radius: 999px;
}

.domain-green {
  background-color: rgba(63, 204, 135, 0.2);
  border: 1px solid rgba(63, 204, 135, 0.9);
  padding: 2px 6px;
  border-radius: 999px;
}

.domain-orange {
  background-color: rgba(255, 168, 84, 0.2);
  border: 1px solid rgba(255, 168, 84, 0.9);
  padding: 2px 6px;
  border-radius: 999px;
}

.domain-purple {
  background-color: rgba(167, 126, 255, 0.2);
  border: 1px solid rgba(167, 126, 255, 0.9);
  padding: 2px 6px;
  border-radius: 999px;
}

.site-footer {
  margin-top: 24px;
  border-top: 1px solid rgba(220, 234, 255, 0.16);
  background: rgba(8, 19, 40, 0.88);
  color: rgba(234, 243, 255, 0.7);
}

.site-footer__inner {
  width: min(1240px, calc(100% - 1.2rem));
  min-height: 52px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  font-size: 12px;
}

@media (max-width: 980px) {
  .grid.cols-2,
  .grid.cols-4 {
    grid-template-columns: 1fr;
  }

  .menu-button {
    display: inline-flex;
  }

  .header {
    align-items: flex-start;
    min-height: 56px;
    padding-top: 8px;
    padding-bottom: 8px;
  }

  .header nav {
    display: none;
    flex-direction: column;
    align-items: stretch;
    gap: 6px;
    padding-top: 2px;
  }

  .header nav.active {
    display: flex;
  }

  .header nav a,
  .dropbtn {
    width: 100%;
    text-align: left;
  }

  .dropdown-content {
    position: static;
    min-width: 0;
    width: 100%;
    margin-top: 6px;
  }

  .content-area {
    padding-top: 14px;
  }

  .container,
  .form-container,
  .login,
  .table-container,
  .user-info-container,
  .ticket-container,
  .anuncio-detalle,
  .faq-content,
  .faq-sidebar,
  .success-message,
  .alert {
    width: calc(100% - 1rem);
    margin: 16px auto;
    padding: 14px;
  }

  table,
  #logTable,
  .styled-table,
  .webs-table {
    min-width: 720px;
  }

  .options,
  .filter-buttons,
  .actions,
  .button-container,
  .dynamic-buttons {
    justify-content: stretch;
  }

  .options a,
  .filter-buttons button,
  .link-btn,
  .btn,
  button,
  input[type="submit"] {
    width: 100%;
  }
}

.portal-header {
  position: sticky;
  top: 0;
  z-index: 1200;
  border-bottom: 1px solid rgba(220, 234, 255, 0.16);
  background: rgba(8, 19, 40, 0.92);
  backdrop-filter: blur(12px);
}

.portal-header__inner {
  width: min(1240px, calc(100% - 1rem));
  margin: 0 auto;
  min-height: 64px;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 0;
}

.portal-brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
  color: var(--text);
}

.portal-brand:hover {
  text-decoration: none;
}

.portal-brand__eyebrow {
  font-size: 11px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: rgba(234, 243, 255, 0.62);
}

.portal-brand__copy {
  display: grid;
  gap: 2px;
  min-width: 0;
}

.portal-brand__meta {
  font-size: 12px;
  color: rgba(234, 243, 255, 0.62);
}

.portal-header .nav-menu {
  margin-left: auto;
}

.portal-header .nav-list {
  list-style: none;
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 0;
  padding: 0;
}

.portal-header .nav-list li {
  margin: 0;
  padding: 0;
}

.portal-header .nav-list li a,
.portal-header .nav-group > summary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 38px;
  padding: 0 12px;
  border-radius: 12px;
  border: 1px solid transparent;
  color: rgba(234, 243, 255, 0.8);
  font-size: 13px;
  font-weight: 700;
  text-decoration: none;
  cursor: pointer;
  transition: background-color 0.18s ease, border-color 0.18s ease, color 0.18s ease;
}

.portal-header .nav-list li a:hover,
.portal-header .nav-group > summary:hover {
  background: rgba(255, 255, 255, 0.06);
  border-color: rgba(220, 234, 255, 0.16);
  color: #ffffff;
}

.portal-header .nav-list li a.active,
.portal-header .nav-group > summary.active,
.portal-header .nav-group[open] > summary {
  background: rgba(25, 139, 255, 0.16);
  border-color: rgba(25, 139, 255, 0.36);
  color: #ffffff;
}

.portal-header .nav-list__group {
  position: relative;
}

.portal-header .nav-group {
  position: relative;
}

.portal-header .nav-group > summary {
  list-style: none;
}

.portal-header .nav-group > summary::-webkit-details-marker {
  display: none;
}

.portal-header .nav-submenu {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  min-width: 220px;
  display: grid;
  gap: 6px;
  padding: 10px;
  border-radius: 16px;
  border: 1px solid rgba(220, 234, 255, 0.16);
  background: rgba(8, 19, 40, 0.98);
  box-shadow: 0 18px 30px rgba(0, 0, 0, 0.28);
}

.portal-header .nav-submenu a {
  justify-content: flex-start;
  width: 100%;
}

.page-shell {
  width: min(1240px, calc(100% - 1rem));
  margin: 0 auto;
  padding: 18px 0 28px;
}

.page-shell--tight {
  background: transparent;
  border: none;
  box-shadow: none;
  padding: 0;
  margin: 24px auto;
}

.page-shell--tight > .hero-card,
.page-shell--tight > .summary-grid,
.page-shell--tight > .dashboard-grid {
  margin: 0;
}

.page-head {
  display: grid;
  gap: 8px;
  margin: 8px 0 18px;
}

.page-head p {
  margin: 0;
}

.page-section,
.stat-card,
.panel,
.list-card,
.hero-card,
.banner-card,
.form-panel {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
}

.page-section,
.panel,
.list-card,
.hero-card,
.form-panel {
  padding: 18px;
}

.dashboard-grid,
.panel-grid,
.stat-grid,
.summary-grid {
  display: grid;
  gap: 14px;
}

.dashboard-grid,
.summary-grid {
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
}

.panel-grid {
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
}

.stat-card {
  padding: 16px;
  display: grid;
  gap: 8px;
}

.stat-card__label,
.kicker,
.form-help,
.meta {
  font-size: 12px;
  color: rgba(234, 243, 255, 0.62);
}

.stat-card__value {
  font-size: clamp(26px, 4vw, 36px);
  line-height: 1;
  color: #ffffff;
  font-weight: 800;
}

.stat-card__footer,
.inline-note {
  font-size: 13px;
  color: var(--muted);
}

.hero-card {
  display: grid;
  gap: 12px;
  background: var(--surface);
}

.hero-card__chips,
.chip-list,
.inline-actions,
.table-actions,
.toolbar {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.portal-section-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  padding: 18px;
}

.portal-section-card__header,
.portal-card__header,
.portal-card__header--split {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.portal-action-row,
.portal-stack,
.portal-stack--dense {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.portal-action-row--spaced {
  margin-top: 14px;
}

.portal-stack {
  flex-direction: column;
}

.portal-stack--dense {
  flex-direction: column;
  gap: 8px;
}

.portal-two-col {
  display: grid;
  gap: 16px;
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.portal-card {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(220, 234, 255, 0.14);
  border-radius: 18px;
  padding: 16px;
}

.portal-card--muted {
  background: rgba(8, 19, 40, 0.7);
}

.list-card--compact {
  padding: 14px;
}

.list-card--link {
  text-decoration: none;
  color: inherit;
  transition: transform 0.18s ease, border-color 0.18s ease, background-color 0.18s ease;
}

.list-card--link:hover {
  transform: translateY(-2px);
  border-color: rgba(24, 139, 255, 0.34);
  background: rgba(24, 139, 255, 0.08);
}

.candidate-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 12px 14px;
  border: 1px solid rgba(220, 234, 255, 0.14);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.03);
}

.candidate-row p,
.list-card p,
.portal-card p {
  margin: 4px 0 0;
}

.code-block {
  margin: 0;
  padding: 14px;
  overflow: auto;
  border-radius: 14px;
  border: 1px solid rgba(220, 234, 255, 0.14);
  background: rgba(6, 12, 24, 0.92);
  color: #dcecff;
  font-size: 12px;
  line-height: 1.45;
  white-space: pre-wrap;
  word-break: break-word;
}

/* Lista JSON auditoría: un solo marco, entradas separadas por línea (menos cajas anidadas) */
.auditoria-json-stack {
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  overflow: hidden;
  background: rgba(6, 12, 24, 0.45);
}

.auditoria-json-stack .code-block--flat {
  display: block;
  margin: 0;
  padding: 12px 14px;
  border: none;
  border-radius: 0;
  border-bottom: 1px solid var(--border);
  background: transparent;
}

.auditoria-json-stack .code-block--flat:last-child {
  border-bottom: none;
}

.alert-box {
  margin-top: 14px;
  padding: 14px 16px;
  border-radius: 16px;
  border: 1px solid rgba(220, 234, 255, 0.14);
  background: rgba(24, 139, 255, 0.12);
}

.alert-box--success {
  border-color: rgba(47, 211, 137, 0.28);
  background: rgba(47, 211, 137, 0.12);
}

.alert-box--warning {
  border-color: rgba(255, 186, 0, 0.28);
  background: rgba(255, 186, 0, 0.12);
}

.alert-box--error {
  border-color: rgba(255, 111, 105, 0.28);
  background: rgba(255, 111, 105, 0.12);
}

.chip {
  display: inline-flex;
  align-items: center;
  min-height: 30px;
  padding: 0 10px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.12);
  color: #dcecff;
  font-size: 12px;
  font-weight: 700;
}

.chip--success {
  background: rgba(47, 211, 137, 0.16);
  border-color: rgba(47, 211, 137, 0.28);
}

.chip--warning {
  background: rgba(255, 204, 102, 0.16);
  border-color: rgba(255, 204, 102, 0.28);
}

.chip--danger {
  background: rgba(255, 111, 105, 0.16);
  border-color: rgba(255, 111, 105, 0.28);
}

.chip--muted {
  background: rgba(255, 255, 255, 0.04);
  border-color: rgba(220, 234, 255, 0.1);
  color: rgba(234, 243, 255, 0.72);
}

.page-split,
.field-grid {
  display: grid;
  gap: 14px;
}

.field-grid.cols-2,
.page-split {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.field-grid.cols-3 {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.field-grid.cols-4 {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.field-grid .form-group,
.field-grid label,
.page-split > * {
  min-width: 0;
}

.webconfig-form {
  display: grid;
  gap: 16px;
}

.webconfig-form .portal-section-card__header {
  margin-top: 4px;
  margin-bottom: 2px;
}

.webconfig-form .card {
  padding: 16px;
}

.webconfig-form .grid {
  margin: 0;
}

.webconfig-form .form-group {
  margin-bottom: 0;
}

.webconfig-form .webconfig-page-card {
  display: grid;
  gap: 14px;
}

label .form-help,
.form-group .form-help {
  display: block;
  margin-top: -2px;
}

.table-card table,
.page-section table,
.panel table,
.list-card table,
.table-container table {
  width: 100%;
}

.table-card td,
.table-card th,
.page-section td,
.page-section th,
.panel td,
.panel th,
.list-card td,
.list-card th,
.table-container td,
.table-container th {
  vertical-align: top;
}

.empty-state {
  padding: 18px;
  border: 1px dashed rgba(220, 234, 255, 0.18);
  border-radius: 14px;
  color: var(--muted);
  text-align: center;
}

.legacy-map-stack {
  display: grid;
  gap: 14px;
  margin-top: 16px;
}

.legacy-filter-bar {
  margin-top: 18px;
}

.legacy-bulk-row {
  margin-top: 14px;
  align-items: center;
}

.legacy-map-card {
  display: grid;
  gap: 14px;
}

.legacy-map-form {
  margin-top: 4px;
}

.multi-select {
  min-height: 220px;
}

.ticket-thread {
  display: grid;
  gap: 14px;
}

.ticket-bubble {
  max-width: min(720px, 100%);
  padding: 14px;
  border-radius: 16px;
  border: 1px solid rgba(220, 234, 255, 0.16);
  background: rgba(11, 24, 46, 0.92);
  display: grid;
  gap: 8px;
}

.ticket-bubble--mine {
  margin-left: auto;
  background: rgba(25, 139, 255, 0.18);
  border-color: rgba(25, 139, 255, 0.3);
}

.ticket-bubble__head {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  align-items: center;
}

.ticket-bubble__head strong,
.ticket-bubble__head span {
  color: #ffffff;
}

.ticket-bubble__media {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.ticket-bubble__media img,
.ticket-bubble__media video {
  max-width: min(220px, 100%);
  border-radius: 12px;
  border: 1px solid rgba(220, 234, 255, 0.16);
}

.banner-stack {
  display: grid;
  gap: 10px;
}

.banner-card {
  padding: 14px 16px;
  border-left: 4px solid var(--primary);
}

.banner-card--good {
  border-left-color: var(--success);
}

.banner-card--bad {
  border-left-color: var(--danger);
}

.referral-code {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 12px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.06);
  border: 1px dashed rgba(159, 212, 255, 0.36);
  color: #ffffff;
  font-weight: 800;
  letter-spacing: 0.04em;
}

.key-value {
  display: grid;
  gap: 10px;
}

.key-value__row {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  padding-bottom: 10px;
  border-bottom: 1px solid rgba(220, 234, 255, 0.1);
}

.key-value__row:last-child {
  border-bottom: 0;
  padding-bottom: 0;
}

.alert-inline {
  padding: 12px 14px;
  border-radius: 14px;
  border: 1px solid rgba(220, 234, 255, 0.16);
  background: rgba(255, 255, 255, 0.06);
}

.alert-inline--danger {
  background: rgba(255, 111, 105, 0.14);
  border-color: rgba(255, 111, 105, 0.26);
}

.alert-inline--success {
  background: rgba(47, 211, 137, 0.14);
  border-color: rgba(47, 211, 137, 0.26);
}

.portal-header .menu-toggle {
  display: none;
  margin-left: auto;
  flex-direction: column;
  gap: 4px;
  cursor: pointer;
  padding: 8px;
  border: 1px solid rgba(24, 138, 252, 0.5);
  border-radius: 10px;
  background: linear-gradient(180deg, #198bff, #0d6fdb);
}

.portal-header .menu-toggle span {
  width: 18px;
  height: 2px;
  background: #ffffff;
}

@media (max-width: 980px) {
  .portal-two-col {
    grid-template-columns: 1fr;
  }

  .portal-header__inner {
    width: min(1240px, calc(100% - 0.9rem));
  }

  .field-grid.cols-2,
  .field-grid.cols-3,
  .field-grid.cols-4,
  .page-split {
    grid-template-columns: 1fr;
  }

  .portal-header .nav-menu {
    display: none;
    position: absolute;
    top: calc(100% + 1px);
    left: 0;
    right: 0;
    background: rgba(8, 19, 40, 0.98);
    border-top: 1px solid rgba(220, 234, 255, 0.16);
    padding: 10px;
  }

  .portal-header .nav-menu.active {
    display: flex;
  }

  .portal-header .menu-toggle {
    display: flex;
  }

  .portal-header .nav-list {
    width: 100%;
    flex-direction: column;
  }

  .portal-header .nav-list li a {
    width: 100%;
  }

  .portal-header .nav-list__group,
  .portal-header .nav-group,
  .portal-header .nav-group > summary,
  .portal-header .nav-submenu,
  .portal-header .nav-submenu a {
    width: 100%;
  }

  .portal-header .nav-group > summary {
    justify-content: flex-start;
  }

  .portal-header .nav-submenu {
    position: static;
    min-width: 0;
    margin-top: 6px;
    box-shadow: none;
  }
}

.section-kicker {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #8fd3ff;
}

.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 42px;
  border-radius: 12px;
  padding: 0 16px;
  border: 1px solid transparent;
  font-weight: 700;
  cursor: pointer;
  text-decoration: none;
}

.cron-actions {
  display: grid;
  gap: 10px;
  margin-top: 16px;
}

.cron-inline-form {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: end;
}

.cron-inline-form--compact {
  align-items: center;
}

.cron-field {
  margin-bottom: 0;
  gap: 6px;
}

.cron-field label {
  font-size: 0.8rem;
}

.btn-primary {
  background: linear-gradient(180deg, var(--primary), var(--primary-strong));
  color: #fff;
  border-color: rgba(37, 144, 255, 0.5);
}

.btn-secondary {
  background: rgba(255, 255, 255, 0.06);
  color: #eaf3ff;
  border-color: rgba(220, 234, 255, 0.14);
}

.btn-secondary:hover {
  background: rgba(24, 139, 255, 0.12);
  border-color: rgba(24, 139, 255, 0.28);
}

.chat-page {
  margin-top: 20px;
}

.chat-shell {
  display: grid;
  grid-template-columns: minmax(320px, 380px) minmax(0, 1fr);
  gap: 18px;
}

.chat-sidebar,
.chat-thread,
.chat-contacts,
.chat-conversations {
  padding: 16px;
}

.chat-sidebar {
  display: grid;
  gap: 16px;
  align-self: start;
}

.chat-sidebar__head,
.chat-contacts__head,
.chat-conversations__head,
.chat-thread__head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.chat-contact-list,
.chat-conversation-list {
  display: grid;
  gap: 10px;
  max-height: 28rem;
  overflow: auto;
}

.chat-contact,
.chat-conversation {
  width: 100%;
  text-align: left;
  border: 1px solid var(--border);
  background: rgba(255, 255, 255, 0.03);
  color: var(--text);
  padding: 12px 14px;
  border-radius: 14px;
  cursor: pointer;
}

.chat-contact:hover,
.chat-conversation:hover,
.chat-conversation.active {
  border-color: rgba(24, 139, 255, 0.45);
  background: rgba(24, 139, 255, 0.12);
}

.chat-contact__group,
.chat-conversation span,
.chat-empty,
.form-error {
  display: block;
  font-size: 12px;
  color: var(--muted);
}

.chat-conversation__row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 6px;
}

.chat-conversation p {
  margin: 0 0 8px;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.4;
}

.chat-pill,
.chat-chip {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 24px;
  padding: 0 10px;
  border-radius: 999px;
  background: rgba(24, 139, 255, 0.18);
  border: 1px solid rgba(24, 139, 255, 0.3);
  color: var(--text);
  font-size: 12px;
  font-weight: 700;
}

.chat-thread {
  display: grid;
  grid-template-rows: auto 1fr auto;
  min-height: 70vh;
}

.chat-thread__participants {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 8px;
}

.chat-thread__empty {
  display: grid;
  place-items: center;
  min-height: 22rem;
  color: var(--muted);
  text-align: center;
}

.chat-thread__body {
  display: grid;
  gap: 12px;
  align-content: start;
  padding: 12px 0;
  overflow: auto;
}

.chat-message {
  max-width: min(82%, 720px);
  padding: 14px;
  border-radius: 16px;
  border: 1px solid var(--border);
  background: rgba(255, 255, 255, 0.04);
}

.chat-message.is-mine {
  margin-left: auto;
  background: rgba(24, 139, 255, 0.14);
  border-color: rgba(24, 139, 255, 0.42);
}

.chat-message header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 8px;
}

.chat-message__body {
  white-space: pre-wrap;
  color: var(--text);
}

.chat-message__attachments,
.chat-compose__actions {
  margin-top: 12px;
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.chat-attachment,
.chat-compose__file {
  display: inline-flex;
  align-items: center;
  min-height: 36px;
  padding: 0 12px;
  border-radius: 10px;
  border: 1px solid var(--border);
  background: rgba(255, 255, 255, 0.04);
  color: var(--text);
  text-decoration: none;
}

.chat-compose {
  border-top: 1px solid var(--border);
  padding-top: 16px;
}

.chat-compose textarea {
  width: 100%;
  border-radius: 14px;
  border: 1px solid var(--border);
  background: rgba(7, 18, 39, 0.72);
  color: var(--text);
  padding: 12px 14px;
  resize: vertical;
}

.chat-compose input[type="file"] {
  display: none;
}

@media (max-width: 980px) {
  .chat-shell {
    grid-template-columns: 1fr;
  }

  .chat-thread {
    min-height: 55vh;
  }
}

.portal-stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 14px;
}

.portal-stat-card {
  padding: 18px;
  border-radius: 16px;
  border: 1px solid var(--border);
  background: rgba(255, 255, 255, 0.04);
}

.portal-stat-card span {
  display: block;
  margin-bottom: 10px;
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.portal-stat-card strong {
  display: block;
  color: var(--text);
  font-size: 28px;
}

.checkbox-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 10px 14px;
}

.report-hero,
.report-section,
.report-filter-bar {
  margin-bottom: 0;
  padding: 18px 20px;
  border-radius: var(--radius-lg);
  border: 1px solid var(--border);
  background: var(--surface);
  box-shadow: var(--shadow-lg);
}

.report-filter-bar--spaced {
  margin-top: 12px;
}

.report-empty-state {
  margin-top: 12px;
  padding: 18px 20px;
  border-radius: var(--radius-lg);
  border: 1px dashed color-mix(in srgb, var(--border) 82%, transparent);
  background: color-mix(in srgb, var(--surface) 88%, transparent);
  box-shadow: var(--shadow-lg);
  display: grid;
  gap: 10px;
}

.report-empty-state h3 {
  margin: 0;
  font-size: 1.05rem;
}

.report-empty-state p {
  margin: 0;
  color: var(--muted);
  max-width: 58ch;
}

.report-hero {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 18px;
}

.report-eyebrow {
  margin: 0 0 8px;
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--muted);
}

.report-hero h1,
.report-section h2 {
  margin: 0;
}

.report-hero__greeting {
  font-size: clamp(1.15rem, 4.2vw, 1.75rem);
  font-weight: 700;
  line-height: 1.25;
  word-break: break-word;
  overflow-wrap: anywhere;
  hyphens: auto;
  max-width: 100%;
}

.report-hero__greeting-prefix {
  font-weight: 600;
  opacity: 0.88;
}

.report-hero__greeting-name {
  display: inline;
  font-weight: 700;
}

.perfil-readonly-dl {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.4fr);
  gap: 6px 16px;
  font-size: 0.88rem;
  margin: 0;
}

.perfil-readonly-dl dt {
  margin: 0;
  color: var(--muted);
  font-weight: 500;
}

.perfil-readonly-dl dd {
  margin: 0;
  word-break: break-word;
}

@media (max-width: 640px) {
  .perfil-readonly-dl {
    grid-template-columns: 1fr;
  }
}

.report-subtitle {
  margin: 10px 0 0;
  max-width: 64ch;
  color: var(--muted);
}

.report-hero__actions,
.report-section__meta,
.report-filter-grid__actions {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.report-filter-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 14px;
  align-items: end;
}

.report-filter-grid label {
  display: grid;
  gap: 8px;
}

.report-filter-grid span {
  font-size: 12px;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.report-section__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  margin-bottom: 16px;
}

.report-chip,
.report-live-pill {
  display: inline-flex;
  align-items: center;
  min-height: 34px;
  padding: 0 12px;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: rgba(255, 255, 255, 0.04);
  font-size: 12px;
  color: var(--muted);
}

.report-live-pill {
  border-color: rgba(29, 201, 130, 0.35);
  color: #14d48f;
  background: rgba(20, 212, 143, 0.1);
}

.report-kpi-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 14px;
}

.report-kpi-grid--compact {
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
}

@media (max-width: 719px) {
  .admin-webs-kpi-strip {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px;
  }

  .admin-webs-kpi-strip .report-card {
    min-height: 0;
    padding: 8px 10px;
    gap: 2px;
  }

  .admin-webs-kpi-strip .report-card__label {
    font-size: 11px;
    line-height: 1.2;
  }

  .admin-webs-kpi-strip .report-card__value {
    font-size: 1.05rem;
    line-height: 1.1;
  }
}

.report-card {
  display: grid;
  gap: 10px;
  min-height: 138px;
  padding: 18px;
  border-radius: 18px;
  border: 1px solid var(--border);
  background: rgba(255, 255, 255, 0.03);
}

.report-card__label {
  font-size: 15px;
  color: var(--muted);
}

.report-card__value {
  font-size: clamp(1.5rem, 3vw, 2.25rem);
  line-height: 1.05;
}

.report-delta {
  font-size: 15px;
  font-weight: 600;
}

.report-delta--positive {
  color: #1fd190;
}

.report-delta--negative {
  color: #ff6b7a;
}

.report-delta--muted {
  color: var(--muted);
}

.report-pagination {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 10px;
  margin-top: 14px;
  flex-wrap: wrap;
}

/* ── Informes detail layout ── */

.informes-layout {
  width: min(1240px, calc(100% - 2rem));
  margin: 0 auto;
  display: grid;
  gap: 24px;
  padding: 28px 0 40px;
}

.informes-filters {
  padding: 22px 24px;
}

.informes-filters .form-group {
  margin-bottom: 0;
}

.informes-filter-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 16px;
  margin: 16px 0 0;
}

.informes-filter-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 20px;
  padding-top: 16px;
  border-top: 1px solid var(--border);
}

.informes-kpi-row {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 16px;
}

.informes-table-wrap {
  overflow-x: auto;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
}

.informes-table-wrap table {
  width: 100%;
  border: none;
}

.informes-table-wrap table th:first-child,
.informes-table-wrap table td:first-child {
  border-left: none;
}

.informes-table-wrap table th:last-child,
.informes-table-wrap table td:last-child {
  border-right: none;
}

.informes-table-wrap table thead tr:first-child th {
  border-top: none;
}

.informes-table-wrap table tbody tr:last-child td {
  border-bottom: none;
}

@media (max-width: 900px) {
  .informes-layout {
    width: calc(100% - 1rem);
    gap: 18px;
    padding: 18px 0 28px;
  }

  .informes-filter-grid {
    grid-template-columns: 1fr;
  }

  .informes-kpi-row {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 500px) {
  .informes-kpi-row {
    grid-template-columns: 1fr;
  }
}

/* ── Top webs section ── */

.top-webs-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 16px;
}

.top-webs-head h2 {
  margin: 0;
}

.top-webs-subtitle {
  margin: 4px 0 0;
  font-size: 14px;
  color: var(--muted);
}

.top-webs-per-page {
  display: flex;
  flex-direction: column;
  gap: 6px;
  min-width: 0;
}

.top-webs-per-page span {
  font-size: 12px;
  color: var(--muted);
}

.top-webs-per-page select {
  min-height: 38px;
  width: auto;
  min-width: 80px;
}

.top-webs-table-wrap {
  overflow-x: auto;
  margin: 0 -18px;
  padding: 0 18px;
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}

.top-webs-section table {
  border: none;
}

.top-webs-section table th,
.top-webs-section table td {
  border-left: none;
  border-right: none;
  text-align: left;
  padding: 10px 12px;
}

.top-webs-section table th {
  border-top: none;
}

.top-webs-section table tbody tr:last-child td {
  border-bottom: none;
}

.top-webs-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-top: 18px;
  flex-wrap: wrap;
}

.top-webs-pages {
  display: flex;
  gap: 6px;
}

.top-webs-page {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 36px;
  height: 36px;
  border-radius: 10px;
  border: 1px solid var(--border);
  background: transparent;
  color: var(--text);
  font-size: 14px;
  font-weight: 700;
  text-decoration: none;
}

.top-webs-page:hover {
  background: rgba(38, 108, 255, 0.1);
  border-color: rgba(38, 108, 255, 0.3);
  text-decoration: none;
  color: var(--text);
}

.top-webs-page.is-current {
  background: var(--primary);
  border-color: var(--primary);
  color: #ffffff;
}

.top-webs-total {
  font-size: 13px;
  color: var(--muted);
}

.btn.is-disabled {
  opacity: 0.5;
  pointer-events: none;
}

@media (max-width: 900px) {
  .report-hero,
  .report-section__head {
    flex-direction: column;
    align-items: stretch;
  }

  .top-webs-head {
    flex-direction: column;
    gap: 12px;
  }

  .top-webs-per-page {
    flex-direction: row;
    align-items: center;
  }

  .top-webs-footer {
    flex-direction: column;
    align-items: flex-start;
    gap: 12px;
  }
}

.page-actions {
  display: flex;
  align-items: center;
  gap: 12px;
}

.page-actions--between {
  justify-content: space-between;
}

.payments-form-stack {
  display: grid;
  gap: 18px;
}

.payments-save-row {
  margin-top: 4px;
}

.payments-domain-section {
  display: grid;
  gap: 16px;
}

.payments-web-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.payments-web-card {
  display: grid;
  gap: 14px;
}

.payments-web-card__head,
.admin-web-card__head {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: flex-start;
}

.payments-web-card__head p,
.admin-web-card__head p {
  margin: 4px 0 0;
}

.payments-field-grid input {
  width: 100%;
}

.admin-webs-filters {
  align-items: end;
}

.admin-webs-filters__actions {
  grid-column: 1 / -1;
}

.admin-webs-filters-grid {
  display: grid;
  gap: 10px 12px;
  grid-template-columns: 1fr 1fr;
  grid-template-areas:
    "status root"
    "q jefe"
    "actions actions";
  align-items: end;
}

.admin-webs-filters-grid label {
  display: grid;
  gap: 4px;
  margin: 0;
  min-width: 0;
}

.admin-webs-filters-grid label span {
  font-size: 0.82rem;
  color: var(--muted);
}

.admin-webs-filters-grid select,
.admin-webs-filters-grid input[type="search"] {
  width: 100%;
  min-width: 0;
}

.admin-webs-filters-grid__status {
  grid-area: status;
}

.admin-webs-filters-grid__root {
  grid-area: root;
}

.admin-webs-filters-grid__q {
  grid-area: q;
}

.admin-webs-filters-grid__jefe {
  grid-area: jefe;
}

.admin-webs-filters-grid__actions {
  grid-area: actions;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

@media (min-width: 900px) {
  .admin-webs-filters-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
    grid-template-areas:
      "status root q jefe"
      "actions actions actions actions";
  }

  .admin-webs-filters-grid__actions {
    justify-content: flex-start;
  }
}

.admin-webs-filters-grid__per-page {
  grid-area: per_page;
  max-width: 160px;
}

.admin-webs-filters-grid--compact {
  gap: 8px 10px;
}

.admin-webs-filters-grid--compact label span {
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.admin-webs-filters-grid--compact.admin-webs-filters-grid {
  grid-template-areas:
    "status root"
    "q jefe"
    "per_page per_page"
    "actions actions";
}

@media (min-width: 900px) {
  .admin-webs-filters-grid--compact.admin-webs-filters-grid {
    grid-template-columns: repeat(5, minmax(0, 1fr));
    grid-template-areas:
      "status root q jefe per_page"
      "actions actions actions actions actions";
  }
}

.admin-webs-filter-btn {
  padding: 6px 12px;
  font-size: 12px;
  min-height: 0;
}

.admin-webs-filter-btn--quiet {
  opacity: 0.88;
}

.admin-webs-page .report-hero--compact {
  padding: 12px 14px;
  gap: 12px;
  align-items: center;
}

.admin-webs-page .report-hero--compact .report-eyebrow {
  margin: 0 0 2px;
  font-size: 10px;
  letter-spacing: 0.07em;
}

.admin-webs-page .report-hero--compact h1 {
  font-size: clamp(1.05rem, 2.5vw, 1.35rem);
  line-height: 1.2;
}

.admin-webs-page .report-hero--compact .report-subtitle {
  margin: 4px 0 0;
  font-size: 0.78rem;
  max-width: 48ch;
  line-height: 1.35;
}

.admin-webs-hero__chips .report-chip {
  min-height: 28px;
  padding: 0 10px;
  font-size: 11px;
}

.report-section--flush {
  padding: 12px 14px;
  margin-bottom: 10px;
}

.report-filter-bar--compact {
  padding: 10px 12px;
  margin-bottom: 10px;
}

.admin-webs-kpi-strip--dense .report-card {
  min-height: 0;
  padding: 10px 12px;
  gap: 4px;
  border-radius: 12px;
}

.admin-webs-kpi-strip--dense .report-card__label {
  font-size: 11px;
}

.admin-webs-kpi-strip--dense .report-card__value {
  font-size: clamp(1.15rem, 2.5vw, 1.5rem);
}

.admin-webs-toolbar-section {
  padding-bottom: 10px;
}

.admin-webs-toolbar-drawers {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  gap: 8px;
}

.admin-webs-toolbar-drawers .admin-webs-add-drawer {
  flex: 0 1 auto;
}

.admin-webs-toolbar-summary {
  padding: 6px 12px;
  font-size: 12px;
  min-height: 0;
  white-space: nowrap;
}

.admin-webs-pagination {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 10px 14px;
  padding: 10px 0 12px;
  margin: 0;
  border-bottom: 1px solid var(--border);
}

.admin-webs-pagination--footer {
  border-bottom: none;
  border-top: 1px solid var(--border);
  padding: 12px 0 4px;
  margin-top: 4px;
}

.admin-webs-pagination__meta {
  margin: 0;
  font-size: 12px;
  color: var(--muted);
}

.admin-webs-pagination__range {
  font-weight: 600;
  color: var(--foreground, inherit);
}

.admin-webs-pagination__nav {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.admin-webs-pagination__link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 32px;
  padding: 0 14px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 600;
  border: 1px solid var(--border);
  background: rgba(255, 255, 255, 0.04);
  color: inherit;
  text-decoration: none;
  transition: background 0.15s ease, border-color 0.15s ease;
}

.admin-webs-pagination__link:hover:not(.admin-webs-pagination__link--disabled) {
  background: rgba(255, 255, 255, 0.09);
  border-color: rgba(255, 255, 255, 0.2);
}

.admin-webs-pagination__link--disabled {
  opacity: 0.38;
  cursor: not-allowed;
  pointer-events: none;
}

html[data-tema="claro"] .admin-webs-pagination__link {
  background: rgba(0, 0, 0, 0.03);
}

html[data-tema="claro"] .admin-webs-pagination__link:hover:not(.admin-webs-pagination__link--disabled) {
  background: rgba(0, 0, 0, 0.06);
}

@media (max-width: 520px) {
  .admin-webs-pagination {
    flex-direction: column;
    align-items: stretch;
  }

  .admin-webs-pagination__nav {
    justify-content: center;
  }
}

.admin-webs-add-drawer summary {
  list-style: none;
  cursor: pointer;
}

.admin-webs-add-drawer summary::-webkit-details-marker {
  display: none;
}

.admin-webs-add-drawer__panel {
  margin-top: 14px;
}

.admin-webs-add-drawer__actions {
  grid-column: 1 / -1;
}

.admin-webs-table-wrap .admin-webs-table--desktop {
  min-width: 980px;
}

.admin-webs-table--desktop {
  width: 100%;
  max-width: 100%;
  font-size: 0.8rem;
  border-collapse: separate;
  border-spacing: 0;
  table-layout: auto;
}

.admin-webs-table--desktop th,
.admin-webs-table--desktop td {
  padding: 4px 6px;
  vertical-align: middle;
}

/* Orden: ID, Acciones, Web, Visitas, Dueño, Jefes, Info, Estado, GAM, Indexación, Posición */

/* ID */
.admin-webs-table--desktop th:nth-child(1),
.admin-webs-table--desktop td:nth-child(1) {
  width: 2.75rem;
  white-space: nowrap;
}

/* Acciones */
.admin-webs-table--desktop th:nth-child(2),
.admin-webs-table--desktop td:nth-child(2) {
  width: 6.5rem;
  min-width: 6.5rem;
  text-align: center;
  white-space: nowrap;
}

/* Web */
.admin-webs-table--desktop th:nth-child(3),
.admin-webs-table--desktop td:nth-child(3) {
  min-width: 7rem;
  max-width: 16rem;
}

/* Visitas */
.admin-webs-table--desktop th:nth-child(4),
.admin-webs-table--desktop td:nth-child(4) {
  width: 5.5rem;
  min-width: 5rem;
  max-width: 7rem;
  text-align: center;
  white-space: nowrap;
}

/* Dueño */
.admin-webs-table--desktop th:nth-child(5),
.admin-webs-table--desktop td:nth-child(5) {
  width: 6.5rem;
  min-width: 5.5rem;
  max-width: 9rem;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  vertical-align: middle;
  text-align: center;
}

/* Jefes */
.admin-webs-table--desktop th:nth-child(6),
.admin-webs-table--desktop td:nth-child(6) {
  width: auto;
  min-width: 2.25rem;
  max-width: 5.5rem;
  text-align: center;
  white-space: normal;
  vertical-align: middle;
}

/* Info */
.admin-webs-table--desktop th:nth-child(7),
.admin-webs-table--desktop td:nth-child(7) {
  width: 2.75rem;
  text-align: center;
  white-space: nowrap;
}

/* Estado */
.admin-webs-table--desktop th:nth-child(8),
.admin-webs-table--desktop td:nth-child(8) {
  width: 3.25rem;
  text-align: center;
  white-space: nowrap;
}

/* GAM */
.admin-webs-table--desktop th:nth-child(9),
.admin-webs-table--desktop td:nth-child(9) {
  width: 3rem;
  text-align: center;
  white-space: nowrap;
}

/* Indexación */
.admin-webs-table--desktop th:nth-child(10),
.admin-webs-table--desktop td:nth-child(10) {
  width: 4rem;
  text-align: center;
  white-space: nowrap;
}

/* Posición */
.admin-webs-table--desktop th:nth-child(11),
.admin-webs-table--desktop td:nth-child(11) {
  width: 7rem;
  text-align: center;
  white-space: nowrap;
}

.admin-webs-root-legend {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 8px;
  margin-bottom: 12px;
  width: 100%;
}

.admin-webs-host-pill {
  display: inline-block;
  max-width: 100%;
  vertical-align: middle;
  padding: 1px 7px 3px;
  border-radius: 7px;
  border: 1px solid var(--aw-pill-bd, rgba(255, 255, 255, 0.22));
  background: var(--aw-pill-bg, rgba(255, 255, 255, 0.06));
  color: var(--aw-pill-fg, #e8f0ff);
  box-decoration-break: clone;
}

.admin-webs-host-pill--legend {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 4px 10px;
  font-size: 0.78rem;
  font-weight: 500;
}

button.admin-webs-host-pill--legend,
a.admin-webs-host-pill--legend {
  color: inherit;
  text-decoration: none;
  cursor: pointer;
  font: inherit;
}

button.admin-webs-host-pill--legend:hover,
a.admin-webs-host-pill--legend:hover {
  filter: brightness(1.08);
}

button.admin-webs-host-pill--legend.is-active,
a.admin-webs-host-pill--legend.is-active {
  box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.45), 0 0 0 3px rgba(56, 189, 248, 0.18);
}

.admin-webs-root-legend__clear {
  border: 1px solid rgba(255, 255, 255, 0.22);
  background: rgba(239, 68, 68, 0.14);
  color: #fecaca;
  border-radius: 999px;
  width: 26px;
  height: 26px;
  line-height: 24px;
  text-align: center;
  cursor: pointer;
  font-weight: 700;
}
.admin-webs-root-legend__clear:hover {
  filter: brightness(1.08);
}

.admin-webs-host-pill__legend-host {
  overflow-wrap: anywhere;
  word-break: break-word;
  white-space: normal;
  max-width: min(100%, 20rem);
  line-height: 1.25;
}

/* 20 tonos: matiz cada 18° (360/20) para distinguir muchos dominios raíz sin azules duplicados */
.admin-webs-host-pill--tone0 {
  --aw-pill-bd: hsla(0, 88%, 58%, 0.92);
  --aw-pill-bg: hsla(0, 88%, 58%, 0.14);
  --aw-pill-fg: hsl(0, 95%, 80%);
}

.admin-webs-host-pill--tone1 {
  --aw-pill-bd: hsla(18, 88%, 56%, 0.92);
  --aw-pill-bg: hsla(18, 88%, 56%, 0.14);
  --aw-pill-fg: hsl(18, 95%, 80%);
}

.admin-webs-host-pill--tone2 {
  --aw-pill-bd: hsla(36, 92%, 54%, 0.92);
  --aw-pill-bg: hsla(36, 92%, 54%, 0.14);
  --aw-pill-fg: hsl(36, 96%, 78%);
}

.admin-webs-host-pill--tone3 {
  --aw-pill-bd: hsla(54, 96%, 52%, 0.92);
  --aw-pill-bg: hsla(54, 96%, 52%, 0.14);
  --aw-pill-fg: hsl(54, 98%, 76%);
}

.admin-webs-host-pill--tone4 {
  --aw-pill-bd: hsla(72, 85%, 48%, 0.92);
  --aw-pill-bg: hsla(72, 85%, 48%, 0.14);
  --aw-pill-fg: hsl(72, 90%, 78%);
}

.admin-webs-host-pill--tone5 {
  --aw-pill-bd: hsla(90, 78%, 46%, 0.92);
  --aw-pill-bg: hsla(90, 78%, 46%, 0.14);
  --aw-pill-fg: hsl(90, 85%, 78%);
}

.admin-webs-host-pill--tone6 {
  --aw-pill-bd: hsla(108, 70%, 46%, 0.92);
  --aw-pill-bg: hsla(108, 70%, 46%, 0.14);
  --aw-pill-fg: hsl(108, 80%, 78%);
}

.admin-webs-host-pill--tone7 {
  --aw-pill-bd: hsla(126, 65%, 44%, 0.92);
  --aw-pill-bg: hsla(126, 65%, 44%, 0.14);
  --aw-pill-fg: hsl(126, 75%, 78%);
}

.admin-webs-host-pill--tone8 {
  --aw-pill-bd: hsla(144, 62%, 44%, 0.92);
  --aw-pill-bg: hsla(144, 62%, 44%, 0.14);
  --aw-pill-fg: hsl(144, 72%, 78%);
}

.admin-webs-host-pill--tone9 {
  --aw-pill-bd: hsla(162, 68%, 46%, 0.92);
  --aw-pill-bg: hsla(162, 68%, 46%, 0.14);
  --aw-pill-fg: hsl(162, 78%, 78%);
}

.admin-webs-host-pill--tone10 {
  --aw-pill-bd: hsla(180, 72%, 48%, 0.92);
  --aw-pill-bg: hsla(180, 72%, 48%, 0.14);
  --aw-pill-fg: hsl(180, 82%, 78%);
}

.admin-webs-host-pill--tone11 {
  --aw-pill-bd: hsla(198, 82%, 54%, 0.92);
  --aw-pill-bg: hsla(198, 82%, 54%, 0.14);
  --aw-pill-fg: hsl(198, 90%, 80%);
}

.admin-webs-host-pill--tone12 {
  --aw-pill-bd: hsla(216, 88%, 58%, 0.92);
  --aw-pill-bg: hsla(216, 88%, 58%, 0.14);
  --aw-pill-fg: hsl(216, 92%, 82%);
}

.admin-webs-host-pill--tone13 {
  --aw-pill-bd: hsla(234, 82%, 62%, 0.92);
  --aw-pill-bg: hsla(234, 82%, 62%, 0.14);
  --aw-pill-fg: hsl(234, 90%, 82%);
}

.admin-webs-host-pill--tone14 {
  --aw-pill-bd: hsla(252, 78%, 62%, 0.92);
  --aw-pill-bg: hsla(252, 78%, 62%, 0.14);
  --aw-pill-fg: hsl(252, 88%, 82%);
}

.admin-webs-host-pill--tone15 {
  --aw-pill-bd: hsla(270, 72%, 62%, 0.92);
  --aw-pill-bg: hsla(270, 72%, 62%, 0.14);
  --aw-pill-fg: hsl(270, 85%, 82%);
}

.admin-webs-host-pill--tone16 {
  --aw-pill-bd: hsla(288, 70%, 58%, 0.92);
  --aw-pill-bg: hsla(288, 70%, 58%, 0.14);
  --aw-pill-fg: hsl(288, 82%, 82%);
}

.admin-webs-host-pill--tone17 {
  --aw-pill-bd: hsla(306, 75%, 56%, 0.92);
  --aw-pill-bg: hsla(306, 75%, 56%, 0.14);
  --aw-pill-fg: hsl(306, 88%, 80%);
}

.admin-webs-host-pill--tone18 {
  --aw-pill-bd: hsla(324, 80%, 58%, 0.92);
  --aw-pill-bg: hsla(324, 80%, 58%, 0.14);
  --aw-pill-fg: hsl(324, 90%, 80%);
}

.admin-webs-host-pill--tone19 {
  --aw-pill-bd: hsla(342, 85%, 58%, 0.92);
  --aw-pill-bg: hsla(342, 85%, 58%, 0.14);
  --aw-pill-fg: hsl(342, 92%, 80%);
}

.admin-webs-host-pill--tone-muted {
  --aw-pill-bd: rgba(148, 163, 184, 0.45);
  --aw-pill-bg: rgba(148, 163, 184, 0.08);
  --aw-pill-fg: #cbd5e1;
}

.admin-webs-host-pill--custom {
  --aw-pill-bd: rgba(148, 163, 184, 0.75);
  --aw-pill-bg: rgba(148, 163, 184, 0.14);
  --aw-pill-fg: #f8fbff;
}

.admin-webs-host-pill__link {
  display: inline-flex;
  align-items: baseline;
  gap: 3px;
  max-width: 100%;
  min-width: 0;
  color: inherit;
  text-decoration: none;
}

.admin-webs-host-pill__text {
  min-width: 0;
  flex: 1 1 auto;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.admin-webs-host-pill__sup {
  font-size: 0.58em;
  font-weight: 700;
  line-height: 0;
  opacity: 0.92;
  vertical-align: super;
  flex-shrink: 0;
}

.admin-webs-host-pill__sup--legend {
  font-size: 0.85em;
  line-height: 1;
  vertical-align: middle;
  font-weight: 700;
}

.admin-webs-table__main {
  min-width: 0;
}

/* PC: host completo; móvil: variante corta solo si existe span --mobile */
.admin-webs-host-label--mobile {
  display: none;
}

.webconfig-domain-colors-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(340px, 1fr));
  gap: 12px;
}

.webconfig-domain-color-row {
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding: 10px 12px;
  border: 1px solid rgba(148, 163, 184, 0.2);
  border-radius: 10px;
  background: rgba(15, 23, 42, 0.3);
}

.webconfig-domain-color-head {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
}

.webconfig-domain-color-head .checkbox-row span {
  overflow-wrap: anywhere;
}

.webconfig-domain-color-body {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.webconfig-domain-color-num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 26px;
  height: 26px;
  border-radius: 999px;
  border: 1px solid rgba(148, 163, 184, 0.35);
  background: rgba(15, 23, 42, 0.55);
  font-size: 0.78rem;
  font-weight: 700;
}

.webconfig-domain-color-picker-wrap {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 0.78rem;
  opacity: 0.9;
}

.webconfig-domain-color-picker-wrap input[type="color"] {
  width: 44px;
  height: 30px;
  border: 1px solid rgba(148, 163, 184, 0.35);
  border-radius: 7px;
  background: transparent;
  padding: 1px;
  cursor: pointer;
}

.webconfig-domain-color-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 5px 10px;
  border-radius: 999px;
  border: 1px solid var(--aw-pill-bd, rgba(148, 163, 184, 0.65));
  background: var(--aw-pill-bg, rgba(148, 163, 184, 0.14));
  color: var(--aw-pill-fg, #f8fbff);
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.01em;
}

@media (max-width: 760px) {
  .webconfig-domain-colors-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 760px) {
  .admin-webs-host-pill__link:has(.admin-webs-host-label--mobile) .admin-webs-host-label--pc {
    display: none;
  }

  .admin-webs-host-pill__link:has(.admin-webs-host-label--mobile) .admin-webs-host-label--mobile {
    display: inline;
  }
}

.admin-webs-actions {
  display: flex;
  flex-wrap: nowrap;
  gap: 3px;
  align-items: center;
  justify-content: center;
}

.admin-webs-sort-th {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  color: inherit;
  text-decoration: none;
  font-weight: 600;
  white-space: nowrap;
}

.admin-webs-sort-th:hover {
  text-decoration: underline;
}

.admin-webs-sort-th__hint {
  opacity: 0.75;
  font-weight: 500;
}

.admin-webs-th-static {
  font-weight: 600;
  white-space: nowrap;
}

.admin-webs-td--actions {
  text-align: center;
  vertical-align: middle;
}

.admin-webs-td--dueno {
  text-align: center;
}

.admin-webs-td--jefes {
  text-align: center;
}

.admin-webs-jefes-chips {
  display: inline-flex;
  flex-direction: row;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 2px;
  max-width: 100%;
  line-height: 1;
}

.admin-webs-icon-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  box-sizing: border-box;
  width: 26px;
  height: 26px;
  min-width: 26px;
  min-height: 26px;
  padding: 0;
  margin: 0;
  border-radius: 6px;
  border: 1px solid rgba(220, 234, 255, 0.18);
  background: rgba(255, 255, 255, 0.06);
  color: #eaf3ff;
  text-decoration: none;
  font-size: 14px;
  line-height: 1;
  cursor: pointer;
  appearance: none;
  -webkit-appearance: none;
}

.admin-webs-icon-btn svg {
  width: 13px;
  height: 13px;
  display: block;
  flex: 0 0 13px;
}

.admin-webs-icon-btn--eye svg {
  transform: scale(0.93);
  transform-origin: center;
}

.admin-webs-icon-btn--edit svg {
  transform: scale(1.1);
  transform-origin: center;
}

.admin-webs-icon-btn--danger svg {
  transform: scale(0.92);
  transform-origin: center;
}

.admin-webs-jefe-chip {
  box-sizing: border-box;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 0;
  min-height: 0;
  height: auto;
  padding: 0 2px;
  margin: 0;
  border-radius: 3px;
  border: 1px solid rgba(255, 193, 7, 0.28);
  background: rgba(255, 193, 7, 0.08);
  color: #ffdf9a;
  font-size: 0.56rem;
  font-weight: 600;
  line-height: 1;
  font-variant-numeric: tabular-nums;
  cursor: pointer;
  flex: 0 0 auto;
  flex-shrink: 0;
  vertical-align: middle;
}

.admin-webs-jefe-chip:hover {
  background: rgba(255, 193, 7, 0.15);
  border-color: rgba(255, 193, 7, 0.4);
}

.admin-webs-icon-btn:hover {
  background: rgba(24, 139, 255, 0.16);
  border-color: rgba(24, 139, 255, 0.32);
}

.admin-webs-icon-btn--danger {
  color: #ffd8d6;
  border-color: rgba(255, 111, 105, 0.3);
  background: rgba(255, 111, 105, 0.12);
}

.admin-webs-status-dot {
  display: inline-block;
  width: 10px;
  height: 10px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.14);
  box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.04);
}

.admin-webs-status-dot--available {
  background: linear-gradient(180deg, rgba(35, 255, 173, 0.95), rgba(18, 167, 113, 0.95));
}

.admin-webs-status-dot--busy {
  background: linear-gradient(180deg, rgba(255, 111, 105, 0.95), rgba(205, 53, 47, 0.95));
}

.admin-webs-toast {
  position: fixed;
  inset: 0;
  display: grid;
  place-items: center;
  background: rgba(2, 8, 22, 0.5);
  z-index: 1400;
  padding: 1rem;
}

.admin-webs-toast[hidden] {
  display: none !important;
}

.admin-webs-toast__panel {
  width: min(520px, 100%);
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 16px;
  box-shadow: var(--shadow-lg);
  padding: 16px;
  position: relative;
}

.admin-webs-toast__panel h3 {
  margin: 0 0 8px;
}

.admin-webs-toast__panel p {
  margin: 0;
  color: var(--text-soft);
}

.admin-webs-toast__close {
  position: absolute;
  top: 8px;
  right: 10px;
  border: 0;
  background: transparent;
  color: var(--text-soft);
  font-size: 20px;
  cursor: pointer;
}

.admin-webs-person-slot {
  position: relative;
  display: inline-flex;
  width: 26px;
  height: 26px;
  align-items: center;
  justify-content: center;
  vertical-align: middle;
}

.admin-webs-person-slot > .admin-webs-icon-btn {
  width: 26px;
  height: 26px;
}

.admin-webs-unassign-form {
  position: absolute;
  top: -3px;
  right: -1px;
  margin: 0;
  padding: 0;
  line-height: 0;
}

.admin-webs-unassign-btn {
  box-sizing: border-box;
  width: 20px;
  height: 12px;
  min-width: 20px;
  min-height: 12px;
  padding: 0;
  margin: 0;
  border: 1px solid rgba(0, 0, 0, 0.35);
  border-radius: 999px;
  background: rgba(185, 45, 45, 0.95);
  color: #fff;
  font-size: 10px;
  font-weight: 700;
  line-height: 10px;
  text-align: center;
  cursor: pointer;
  box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.12);
}

.admin-webs-unassign-btn:hover {
  filter: brightness(1.08);
}

.admin-webs-modal {
  position: fixed;
  inset: 0;
  z-index: 1450;
  display: grid;
  place-items: center;
  padding: 1rem;
}

.admin-webs-modal[hidden] {
  display: none !important;
}

.admin-webs-modal__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(2, 8, 22, 0.55);
}

.admin-webs-modal__panel {
  position: relative;
  z-index: 1;
  width: min(420px, 100%);
  max-height: min(72vh, 520px);
  display: flex;
  flex-direction: column;
  gap: 10px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 16px;
  box-shadow: var(--shadow-lg);
  padding: 16px 16px 14px;
}

.admin-webs-modal__panel h3 {
  margin: 0;
  padding-right: 28px;
  font-size: 1.05rem;
}

.admin-webs-modal__hint {
  margin: 0;
  font-size: 0.85rem;
  color: var(--text-soft);
  word-break: break-word;
}

.admin-webs-modal__empty {
  margin: 0;
  font-size: 0.88rem;
  color: var(--text-soft);
}

.admin-webs-modal__close {
  position: absolute;
  top: 8px;
  right: 10px;
  border: 0;
  background: transparent;
  color: var(--text-soft);
  font-size: 20px;
  line-height: 1;
  cursor: pointer;
}

.admin-webs-assign-list-wrap {
  overflow: auto;
  max-height: min(48vh, 360px);
  margin: 0 -4px;
  padding: 0 4px;
}

.admin-webs-assign-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.admin-webs-assign-pick {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 2px;
  width: 100%;
  text-align: left;
  padding: 10px 12px;
  border-radius: 10px;
  border: 1px solid var(--border);
  background: rgba(255, 255, 255, 0.04);
  color: var(--text);
  cursor: pointer;
  font: inherit;
}

.admin-webs-assign-pick:hover {
  border-color: rgba(96, 165, 250, 0.45);
  background: rgba(96, 165, 250, 0.1);
}

.admin-webs-assign-pick__main {
  font-weight: 600;
  font-size: 0.92rem;
}

.admin-webs-assign-pick__sub {
  font-size: 0.78rem;
  color: var(--text-soft);
}

.persona-assigned-webs-box {
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 10px 12px;
  background: rgba(255, 255, 255, 0.03);
  margin-bottom: 10px;
}

.persona-assigned-webs-empty {
  margin: 0;
  color: var(--text-soft);
  font-size: 0.92rem;
}

.persona-assigned-webs-list {
  margin: 0;
  padding-left: 1.1rem;
  color: var(--text);
}

.persona-assigned-webs-list a {
  color: inherit;
  text-decoration: underline;
  text-underline-offset: 2px;
}

.persona-assign-web-row {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-top: 4px;
}

.persona-assign-web-row__label {
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--text-soft);
}

.persona-assign-web-row__controls {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
}

.persona-assign-web-row__controls select {
  min-width: min(100%, 220px);
  flex: 1 1 180px;
}

.admin-webs-actions form {
  margin: 0;
  display: flex;
}

.admin-webs-actions--stack {
  flex-direction: column;
}

.btn-danger-soft {
  color: #ffd8d6;
  border-color: rgba(255, 111, 105, 0.3);
  background: rgba(255, 111, 105, 0.12);
}

.admin-web-card {
  display: grid;
  gap: 12px;
}

.mobile-only-grid {
  display: none;
}

.desktop-only-block {
  display: block;
}

.toolbar--bottom-align {
  align-self: end;
}

.maintenance-body {
  min-height: 100vh;
  background: linear-gradient(180deg, #061127 0%, #071634 100%);
}

.maintenance-shell {
  min-height: 100vh;
  display: grid;
  place-items: start center;
  padding-top: 18px;
  padding-bottom: 48px;
  width: min(1100px, calc(100% - 1rem));
  margin: 0 auto;
}

.maintenance-card {
  max-width: 720px;
  width: min(100%, 720px);
  text-align: center;
  display: grid;
  gap: 18px;
}

.maintenance-card__brand {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 12px;
}

.maintenance-card__brand img {
  width: 56px;
  height: 56px;
  object-fit: contain;
}

.maintenance-card__message {
  margin: 0;
  color: var(--text-soft);
}

.maintenance-card__notes {
  margin: 0;
  padding-left: 18px;
  text-align: left;
  color: var(--text-soft);
}

.maintenance-card__eta,
.maintenance-card__meta {
  margin: 0;
  color: var(--text-muted);
}

.maintenance-card__actions {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}

.maintenance-card__login {
  opacity: 0.8;
}

.site-state-card {
  display: grid;
  gap: 18px;
}

.site-state-card__toggle {
  align-self: start;
}

.site-state-notes-grid {
  display: grid;
  gap: 10px;
  max-height: 320px;
  overflow: auto;
  padding-right: 4px;
}

.site-state-notes-grid label {
  display: grid;
  gap: 6px;
}

@media (max-width: 980px) {
  .payments-web-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 760px) {
  .page-actions,
  .page-actions--between,
  .payments-web-card__head,
  .admin-web-card__head {
    flex-direction: column;
    align-items: stretch;
  }

  /* Ver webs: misma tabla que en escritorio, scroll horizontal compacto */
  .admin-webs-table-wrap {
    display: block;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    margin: 0 -6px;
    padding: 0 6px 6px;
  }

  .admin-webs-table-wrap .admin-webs-table--desktop {
    min-width: 760px;
  }

  .admin-webs-table--desktop {
    font-size: 0.76rem;
  }

  .admin-webs-table--desktop th,
  .admin-webs-table--desktop td {
    padding: 3px 5px;
  }

  .admin-webs-icon-btn {
    width: 24px;
    height: 24px;
    min-width: 24px;
    min-height: 24px;
    border-radius: 5px;
  }

  .admin-webs-icon-btn svg {
    width: 12px;
    height: 12px;
    flex: 0 0 12px;
  }

  .admin-webs-status-dot {
    width: 10px;
    height: 10px;
  }

  .admin-webs-table--desktop th:nth-child(5),
  .admin-webs-table--desktop td:nth-child(5) {
    max-width: 7rem;
    min-width: 3.25rem;
    white-space: normal;
    padding-left: 3px;
    padding-right: 3px;
    vertical-align: middle;
  }

  .admin-webs-td--jefes {
    text-align: center;
  }

  .admin-webs-jefes-chips {
    display: flex;
    flex-direction: row;
    flex-wrap: wrap;
    justify-content: center;
    align-items: center;
    align-content: center;
    gap: 3px;
    width: max-content;
    max-width: 100%;
    margin-left: auto;
    margin-right: auto;
  }

  .admin-webs-jefe-chip {
    font-size: 0.5rem;
    padding: 0 1px;
    border-radius: 2px;
    line-height: 1.05;
  }

  .desktop-only-block {
    display: none;
  }

  .mobile-only-grid {
    display: grid;
    gap: 14px;
  }

  .maintenance-card {
    text-align: left;
  }

  .maintenance-card__brand,
  .maintenance-card__actions {
    justify-content: flex-start;
  }
}

/* ───────────────────────────────────────────────────────────
   LIGHT THEME — component overrides for hardcoded dark values
   ─────────────────────────────────────────────────────────── */

html[data-tema="claro"] body {
  background:
    radial-gradient(1200px 760px at 10% 0%, rgba(38, 108, 255, 0.08), transparent 56%),
    radial-gradient(920px 620px at 86% 10%, rgba(20, 188, 255, 0.06), transparent 60%),
    linear-gradient(180deg, var(--bg), var(--bg-soft));
}

html[data-tema="claro"] input,
html[data-tema="claro"] select,
html[data-tema="claro"] textarea {
  background: rgba(255, 255, 255, 0.72);
  border-color: var(--border-strong);
  color: var(--text);
}

html[data-tema="claro"] input::placeholder,
html[data-tema="claro"] textarea::placeholder {
  color: rgba(16, 32, 63, 0.44);
}

html[data-tema="claro"] input:focus,
html[data-tema="claro"] select:focus,
html[data-tema="claro"] textarea:focus {
  border-color: rgba(38, 108, 255, 0.6);
  box-shadow: 0 0 0 3px rgba(38, 108, 255, 0.14);
}

html[data-tema="claro"] .header {
  background: rgba(255, 255, 255, 0.88);
  border-bottom-color: var(--border);
  backdrop-filter: blur(12px);
}

html[data-tema="claro"] .header nav a:hover,
html[data-tema="claro"] .dropbtn:hover {
  background: rgba(32, 64, 119, 0.06);
}

html[data-tema="claro"] .header nav a.active,
html[data-tema="claro"] .dropbtn.active {
  background: rgba(38, 108, 255, 0.12);
  border-color: rgba(38, 108, 255, 0.3);
  color: var(--primary);
}

html[data-tema="claro"] .dropdown-content {
  background: var(--surface-strong);
  border-color: var(--border-strong);
}

html[data-tema="claro"] .dropdown-content a:hover,
html[data-tema="claro"] .dropdown-content a.active {
  background: rgba(38, 108, 255, 0.08);
}

html[data-tema="claro"] .badge-success {
  background: rgba(31, 168, 106, 0.12);
  color: #0f6b3c;
  border-color: rgba(31, 168, 106, 0.3);
}

html[data-tema="claro"] .badge-danger {
  background: rgba(217, 77, 90, 0.12);
  color: #a1323e;
  border-color: rgba(217, 77, 90, 0.3);
}

html[data-tema="claro"] .badge-neutral {
  background: rgba(38, 108, 255, 0.1);
  color: #1b4a9e;
  border-color: rgba(38, 108, 255, 0.24);
}

html[data-tema="claro"] .error,
html[data-tema="claro"] .alert.error {
  border-color: rgba(217, 77, 90, 0.4);
  background: rgba(217, 77, 90, 0.08);
  color: #8b2630;
}

html[data-tema="claro"] .success,
html[data-tema="claro"] .alert.success {
  border-color: rgba(31, 168, 106, 0.4);
  background: rgba(31, 168, 106, 0.08);
  color: #0f5c33;
}

html[data-tema="claro"] .message {
  border-color: rgba(38, 108, 255, 0.3);
  background: rgba(38, 108, 255, 0.06);
  color: #1a3d7a;
}

html[data-tema="claro"] .notification {
  border-color: rgba(197, 137, 23, 0.4);
  background: rgba(197, 137, 23, 0.08);
  color: #7a5406;
}

html[data-tema="claro"] #copyAlert {
  color: #0f6b3c;
}

html[data-tema="claro"] table th,
html[data-tema="claro"] #logTable th,
html[data-tema="claro"] .styled-table thead tr,
html[data-tema="claro"] .webs-table th {
  background: rgba(38, 68, 120, 0.08);
  color: #10203f;
}

html[data-tema="claro"] table th,
html[data-tema="claro"] table td,
html[data-tema="claro"] #logTable th,
html[data-tema="claro"] #logTable td,
html[data-tema="claro"] .styled-table th,
html[data-tema="claro"] .styled-table td,
html[data-tema="claro"] .webs-table th,
html[data-tema="claro"] .webs-table td {
  border-color: rgba(32, 64, 119, 0.12);
}

html[data-tema="claro"] table tr:nth-child(even),
html[data-tema="claro"] #logTable tr:nth-child(even),
html[data-tema="claro"] .styled-table tbody tr:nth-child(even),
html[data-tema="claro"] .webs-table tr:nth-child(even) {
  background: rgba(38, 68, 120, 0.03);
}

html[data-tema="claro"] table tr:hover,
html[data-tema="claro"] #logTable tr:hover,
html[data-tema="claro"] .styled-table tbody tr:hover,
html[data-tema="claro"] .webs-table tr:hover {
  background: rgba(38, 108, 255, 0.06);
}

html[data-tema="claro"] .tab {
  border-color: var(--border);
  background: rgba(255, 255, 255, 0.5);
}

html[data-tema="claro"] .ticket-message {
  border-color: var(--border);
  background: rgba(255, 255, 255, 0.6);
}

html[data-tema="claro"] .ticket-message.admin,
html[data-tema="claro"] .ticket-message.manager {
  background: rgba(38, 108, 255, 0.08);
}

html[data-tema="claro"] .ticket-message.user {
  background: rgba(255, 255, 255, 0.7);
}

html[data-tema="claro"] .faq {
  border-color: var(--border);
  background: rgba(255, 255, 255, 0.5);
}

html[data-tema="claro"] .faq-answer {
  border-color: var(--border);
  background: rgba(255, 255, 255, 0.4);
}

html[data-tema="claro"] .modal {
  background: rgba(16, 32, 63, 0.32);
}

html[data-tema="claro"] .back-link {
  color: var(--link);
}

html[data-tema="claro"] #errorMesage {
  background: rgba(217, 77, 90, 0.1);
  border-color: rgba(217, 77, 90, 0.4);
  color: #8b2630;
}

html[data-tema="claro"] .site-footer {
  border-top-color: var(--border);
  background: rgba(255, 255, 255, 0.88);
  color: var(--muted);
}

html[data-tema="claro"] .portal-header {
  border-bottom-color: var(--border);
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(12px);
}

html[data-tema="claro"] .portal-brand__eyebrow,
html[data-tema="claro"] .portal-brand__meta {
  color: var(--muted);
}

html[data-tema="claro"] .portal-header .nav-list li a,
html[data-tema="claro"] .portal-header .nav-group > summary {
  color: var(--muted);
}

html[data-tema="claro"] .portal-header .nav-list li a:hover,
html[data-tema="claro"] .portal-header .nav-group > summary:hover {
  background: rgba(32, 64, 119, 0.06);
  border-color: var(--border);
  color: var(--text);
}

html[data-tema="claro"] .portal-header .nav-list li a.active,
html[data-tema="claro"] .portal-header .nav-group > summary.active,
html[data-tema="claro"] .portal-header .nav-group[open] > summary {
  background: rgba(38, 108, 255, 0.1);
  border-color: rgba(38, 108, 255, 0.24);
  color: var(--primary);
}

html[data-tema="claro"] .portal-header .nav-submenu {
  background: var(--surface-strong);
  border-color: var(--border-strong);
  box-shadow: 0 18px 30px rgba(35, 65, 118, 0.12);
}

html[data-tema="claro"] .stat-card__label,
html[data-tema="claro"] .kicker,
html[data-tema="claro"] .form-help,
html[data-tema="claro"] .meta {
  color: var(--muted);
}

html[data-tema="claro"] .stat-card__value {
  color: var(--text);
}

html[data-tema="claro"] .hero-card {
  background: var(--surface);
}

html[data-tema="claro"] .portal-card {
  background: rgba(255, 255, 255, 0.6);
  border-color: var(--border);
}

html[data-tema="claro"] .portal-card--muted {
  background: rgba(242, 246, 255, 0.8);
}

html[data-tema="claro"] .candidate-row {
  border-color: var(--border);
  background: rgba(255, 255, 255, 0.5);
}

html[data-tema="claro"] .code-block {
  background: rgba(16, 32, 63, 0.04);
  border-color: var(--border);
  color: var(--text);
}

html[data-tema="claro"] .auditoria-json-stack {
  background: rgba(16, 32, 63, 0.04);
}

html[data-tema="claro"] .auditoria-json-stack .code-block--flat {
  background: transparent;
}

html[data-tema="claro"] .alert-box {
  border-color: rgba(38, 108, 255, 0.2);
  background: rgba(38, 108, 255, 0.06);
}

html[data-tema="claro"] .alert-box--success {
  border-color: rgba(31, 168, 106, 0.22);
  background: rgba(31, 168, 106, 0.06);
}

html[data-tema="claro"] .alert-box--warning {
  border-color: rgba(197, 137, 23, 0.22);
  background: rgba(197, 137, 23, 0.06);
}

html[data-tema="claro"] .alert-box--error {
  border-color: rgba(217, 77, 90, 0.22);
  background: rgba(217, 77, 90, 0.06);
}

html[data-tema="claro"] .chip {
  background: rgba(32, 64, 119, 0.06);
  border-color: rgba(32, 64, 119, 0.14);
  color: var(--text);
}

html[data-tema="claro"] .chip--success {
  background: rgba(31, 168, 106, 0.1);
  border-color: rgba(31, 168, 106, 0.22);
}

html[data-tema="claro"] .chip--warning {
  background: rgba(197, 137, 23, 0.1);
  border-color: rgba(197, 137, 23, 0.22);
}

html[data-tema="claro"] .chip--danger {
  background: rgba(217, 77, 90, 0.1);
  border-color: rgba(217, 77, 90, 0.22);
}

html[data-tema="claro"] .chip--muted {
  background: rgba(32, 64, 119, 0.04);
  border-color: rgba(32, 64, 119, 0.1);
  color: var(--muted);
}

html[data-tema="claro"] .section-kicker {
  color: var(--primary);
}

html[data-tema="claro"] .btn-secondary {
  background: rgba(32, 64, 119, 0.06);
  color: var(--text);
  border-color: var(--border);
}

html[data-tema="claro"] .btn-secondary:hover {
  background: rgba(38, 108, 255, 0.08);
  border-color: rgba(38, 108, 255, 0.2);
}

html[data-tema="claro"] .btn-danger-soft {
  color: #a1323e;
  border-color: rgba(217, 77, 90, 0.25);
  background: rgba(217, 77, 90, 0.08);
}

html[data-tema="claro"] .report-hero,
html[data-tema="claro"] .report-section,
html[data-tema="claro"] .report-filter-bar {
  background: var(--surface);
  border-color: var(--border);
  box-shadow: var(--shadow-lg);
}

html[data-tema="claro"] .report-card {
  background: rgba(255, 255, 255, 0.6);
  border-color: var(--border);
}

html[data-tema="claro"] .report-card__value {
  color: var(--text);
}

html[data-tema="claro"] .report-chip,
html[data-tema="claro"] .report-live-pill {
  border-color: var(--border);
  background: rgba(255, 255, 255, 0.5);
}

html[data-tema="claro"] .informes-table-wrap {
  background: rgba(255, 255, 255, 0.7);
  border-color: var(--border);
}

html[data-tema="claro"] .informes-filter-actions {
  border-color: var(--border);
}

html[data-tema="claro"] .top-webs-page {
  border-color: #d0d5dd;
  background: #fff;
  color: #344054;
}

html[data-tema="claro"] .top-webs-page:hover {
  background: rgba(38, 108, 255, 0.06);
  border-color: rgba(38, 108, 255, 0.25);
}

html[data-tema="claro"] .top-webs-page.is-current {
  background: var(--primary);
  color: #fff;
  border-color: var(--primary);
}

html[data-tema="claro"] .top-webs-table-wrap {
  border-color: #e5e7eb;
}

html[data-tema="claro"] .report-live-pill {
  border-color: rgba(31, 168, 106, 0.3);
  color: #0f6b3c;
  background: rgba(31, 168, 106, 0.08);
}

html[data-tema="claro"] .report-delta--positive {
  color: #0f6b3c;
}

html[data-tema="claro"] .report-delta--negative {
  color: #a1323e;
}

html[data-tema="claro"] .portal-stat-card {
  background: rgba(255, 255, 255, 0.6);
  border-color: var(--border);
}

html[data-tema="claro"] .ticket-bubble {
  border-color: var(--border);
  background: rgba(255, 255, 255, 0.72);
}

html[data-tema="claro"] .ticket-bubble--mine {
  background: rgba(38, 108, 255, 0.08);
  border-color: rgba(38, 108, 255, 0.2);
}

html[data-tema="claro"] .ticket-bubble__head strong,
html[data-tema="claro"] .ticket-bubble__head span {
  color: var(--text);
}

html[data-tema="claro"] .ticket-bubble__media img,
html[data-tema="claro"] .ticket-bubble__media video {
  border-color: var(--border);
}

html[data-tema="claro"] .referral-code {
  background: rgba(38, 108, 255, 0.06);
  border-color: rgba(38, 108, 255, 0.24);
  color: var(--text);
}

html[data-tema="claro"] .key-value__row {
  border-bottom-color: var(--border);
}

html[data-tema="claro"] .alert-inline {
  border-color: var(--border);
  background: rgba(255, 255, 255, 0.5);
}

html[data-tema="claro"] .alert-inline--danger {
  background: rgba(217, 77, 90, 0.06);
  border-color: rgba(217, 77, 90, 0.2);
}

html[data-tema="claro"] .alert-inline--success {
  background: rgba(31, 168, 106, 0.06);
  border-color: rgba(31, 168, 106, 0.2);
}

html[data-tema="claro"] .empty-state {
  border-color: var(--border);
}

html[data-tema="claro"] .chat-contact,
html[data-tema="claro"] .chat-conversation {
  background: rgba(255, 255, 255, 0.6);
}

html[data-tema="claro"] .chat-contact:hover,
html[data-tema="claro"] .chat-conversation:hover,
html[data-tema="claro"] .chat-conversation.active {
  border-color: rgba(38, 108, 255, 0.3);
  background: rgba(38, 108, 255, 0.06);
}

html[data-tema="claro"] .chat-message {
  background: rgba(255, 255, 255, 0.6);
}

html[data-tema="claro"] .chat-message.is-mine {
  background: rgba(38, 108, 255, 0.08);
  border-color: rgba(38, 108, 255, 0.24);
}

html[data-tema="claro"] .chat-compose textarea {
  background: rgba(255, 255, 255, 0.72);
}

html[data-tema="claro"] .chat-attachment,
html[data-tema="claro"] .chat-compose__file {
  background: rgba(255, 255, 255, 0.6);
}

html[data-tema="claro"] .maintenance-body {
  background:
    radial-gradient(circle at top, rgba(38, 108, 255, 0.08), transparent 34%),
    linear-gradient(180deg, #f2f6ff 0%, #e7eefb 100%);
}

html[data-tema="claro"] .domain-blue {
  background-color: rgba(38, 108, 255, 0.1);
  border-color: rgba(38, 108, 255, 0.5);
}

html[data-tema="claro"] .domain-yellow {
  background-color: rgba(197, 137, 23, 0.1);
  border-color: rgba(197, 137, 23, 0.5);
}

html[data-tema="claro"] .domain-green {
  background-color: rgba(31, 168, 106, 0.1);
  border-color: rgba(31, 168, 106, 0.5);
}

html[data-tema="claro"] .domain-orange {
  background-color: rgba(220, 120, 30, 0.1);
  border-color: rgba(220, 120, 30, 0.5);
}

html[data-tema="claro"] .domain-purple {
  background-color: rgba(130, 80, 220, 0.1);
  border-color: rgba(130, 80, 220, 0.5);
}

html[data-tema="claro"] .banner-card {
  border-left-color: var(--primary);
}

html[data-tema="claro"] .banner-card--good {
  border-left-color: var(--success);
}

html[data-tema="claro"] .banner-card--bad {
  border-left-color: var(--danger);
}

html[data-tema="claro"] .close:hover {
  color: var(--text);
}

html[data-tema="claro"] .options a.active {
  border-color: rgba(31, 168, 106, 0.4);
  background: rgba(31, 168, 106, 0.12);
  color: #0f6b3c;
}

html[data-tema="claro"] input[type="checkbox"],
html[data-tema="claro"] input[type="radio"] {
  accent-color: var(--primary);
}

html[data-tema="claro"] .list-card--link:hover {
  border-color: rgba(38, 108, 255, 0.24);
  background: rgba(38, 108, 255, 0.05);
}

html[data-tema="claro"] .chat-pill,
html[data-tema="claro"] .chat-chip {
  background: rgba(38, 108, 255, 0.1);
  border-color: rgba(38, 108, 255, 0.22);
}

html[data-tema="claro"] .portal-section-card {
  background: var(--surface);
  border-color: var(--border);
}

html[data-tema="claro"] .form-panel {
  background: var(--surface);
  border-color: var(--border);
}

html[data-tema="claro"] .chat-contact:hover,
html[data-tema="claro"] .chat-conversation:hover,
html[data-tema="claro"] .chat-conversation.active {
  border-color: rgba(38, 108, 255, 0.24);
  background: rgba(38, 108, 255, 0.06);
}

html[data-tema="claro"] button:hover,
html[data-tema="claro"] input[type="submit"]:hover,
html[data-tema="claro"] .btn:hover {
  box-shadow: 0 8px 18px rgba(23, 76, 184, 0.18);
}

@media (max-width: 980px) {
  html[data-tema="claro"] .portal-header .nav-menu {
    background: rgba(255, 255, 255, 0.98);
    border-top-color: var(--border);
  }
}

/* ─── Profile avatar ─── */
.profile-hero {
  margin-bottom: 18px;
}

.profile-avatar-wrap {
  position: relative;
  display: inline-block;
  width: 96px;
  height: 96px;
  margin-inline: auto;
  margin-bottom: 10px;
}
.profile-avatar-wrap {
  position: relative;
  display: inline-block;
  width: 96px;
  height: 96px;
}
.profile-avatar-img {
  width: 96px;
  height: 96px;
  border-radius: 50%;
  object-fit: cover;
  border: 3px solid var(--primary, #6366f1);
  box-shadow: 0 4px 14px rgba(99, 102, 241, .25);
}
.profile-avatar-form {
  position: absolute;
  right: -8px;
  bottom: -6px;
  margin: 0;
  width: auto;
  z-index: 3;
}
.profile-avatar-wrap > .profile-avatar-form {
  position: absolute;
  right: -8px;
  bottom: -6px;
  inset: auto;
  transform: none;
}
.profile-avatar-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: var(--primary, #6366f1);
  color: #fff;
  cursor: pointer;
  border: 2px solid var(--bg, #111);
  transition: transform .15s;
}
.profile-avatar-btn::after {
  content: attr(title);
  position: absolute;
  right: 0;
  bottom: 42px;
  padding: 6px 10px;
  border-radius: 10px;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: .01em;
  white-space: nowrap;
  background: rgba(17, 24, 39, 0.92);
  color: rgba(255, 255, 255, 0.92);
  border: 1px solid rgba(255, 255, 255, 0.12);
  box-shadow: 0 10px 30px rgba(0,0,0,.28);
  opacity: 0;
  transform: translateY(6px);
  pointer-events: none;
  transition: opacity .15s ease, transform .15s ease;
}
.profile-avatar-btn:hover::after,
.profile-avatar-btn:focus-visible::after {
  opacity: 1;
  transform: translateY(0);
}
.profile-avatar-btn:hover {
  transform: scale(1.12);
}
.profile-avatar-help {
  margin: 0.4rem 0 0;
  font-size: 0.82rem;
  color: color-mix(in srgb, var(--text, #eaf3ff) 76%, transparent);
}
.profile-avatar-help strong {
  color: var(--primary, #6366f1);
}

/* ─── Badges ─── */
.badge {
  display: inline-block;
  padding: 3px 10px;
  border-radius: 20px;
  font-size: .75rem;
  font-weight: 600;
  letter-spacing: .02em;
}
.badge--success {
  background: rgba(34, 197, 94, .15);
  color: #22c55e;
}
.badge--warning {
  background: rgba(250, 204, 21, .15);
  color: #eab308;
}
.badge--danger {
  background: rgba(239, 68, 68, .15);
  color: #ef4444;
}
.badge--info {
  background: rgba(59, 130, 246, .15);
  color: #3b82f6;
}
html[data-tema="claro"] .badge--success { background: rgba(34, 197, 94, .1); color: #16a34a; }
html[data-tema="claro"] .badge--warning { background: rgba(250, 204, 21, .1); color: #ca8a04; }
html[data-tema="claro"] .badge--danger  { background: rgba(239, 68, 68, .1);  color: #dc2626; }
html[data-tema="claro"] .badge--info    { background: rgba(59, 130, 246, .1);  color: #2563eb; }
html[data-tema="claro"] .profile-avatar-btn { border-color: var(--surface, #fff); }
html[data-tema="claro"] .profile-avatar-btn::after {
  background: rgba(255, 255, 255, 0.96);
  color: rgba(15, 23, 42, 0.92);
  border-color: rgba(2, 6, 23, 0.12);
}

/* ─── Webs: indicador AdManager ─── */
.admin-webs-adm-dot {
  display: inline-block;
  width: 10px;
  height: 10px;
  border-radius: 999px;
  vertical-align: middle;
  box-shadow: 0 0 0 2px rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.12);
}
.admin-webs-adm-dot--ok {
  background: linear-gradient(180deg, rgba(35, 255, 173, 0.95), rgba(18, 167, 113, 0.95));
}
.admin-webs-adm-dot--off {
  background: rgba(255, 255, 255, 0.18);
}
html[data-tema="claro"] .admin-webs-adm-dot {
  box-shadow: 0 0 0 2px rgba(0, 0, 0, 0.03);
  border-color: rgba(0, 0, 0, 0.12);
}
html[data-tema="claro"] .admin-webs-adm-dot--off {
  background: rgba(0, 0, 0, 0.18);
}

.admin-webs-gsc-dot {
  display: inline-block;
  width: 10px;
  height: 10px;
  border-radius: 999px;
  vertical-align: middle;
  box-shadow: 0 0 0 2px rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.12);
}
.admin-webs-gsc-dot--ok {
  background: linear-gradient(180deg, rgba(35, 255, 173, 0.95), rgba(18, 167, 113, 0.95));
}
.admin-webs-gsc-dot--warn {
  background: linear-gradient(180deg, rgba(251, 191, 36, 0.95), rgba(217, 119, 6, 0.95));
}
.admin-webs-gsc-dot--off {
  background: rgba(255, 255, 255, 0.18);
}

.admin-webs-wp-dot {
  display: inline-block;
  width: 10px;
  height: 10px;
  border-radius: 999px;
  vertical-align: middle;
  box-shadow: 0 0 0 2px rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.12);
}
.admin-webs-wp-dot--ok {
  background: linear-gradient(180deg, rgba(35, 255, 173, 0.95), rgba(18, 167, 113, 0.95));
}
.admin-webs-wp-dot--warn {
  background: linear-gradient(180deg, rgba(251, 191, 36, 0.95), rgba(217, 119, 6, 0.95));
}
.admin-webs-wp-dot--error {
  background: linear-gradient(180deg, rgba(248, 113, 113, 0.95), rgba(220, 38, 38, 0.95));
}
.admin-webs-wp-dot--off {
  background: rgba(255, 255, 255, 0.18);
}
html[data-tema="claro"] .admin-webs-wp-dot {
  box-shadow: 0 0 0 2px rgba(0, 0, 0, 0.03);
  border-color: rgba(0, 0, 0, 0.12);
}
html[data-tema="claro"] .admin-webs-wp-dot--off {
  background: rgba(0, 0, 0, 0.18);
}

.admin-webs-gsc-source {
  display: inline-block;
  margin-left: 6px;
  font-size: 10px;
  line-height: 1;
  padding: 2px 6px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.14);
  white-space: nowrap;
}
.admin-webs-gsc-source--scope {
  background: rgba(16, 185, 129, 0.2);
  color: #d1fae5;
}
.admin-webs-gsc-source--root {
  background: rgba(56, 189, 248, 0.18);
  color: #dbeafe;
}
.admin-webs-gsc-source--off {
  background: rgba(148, 163, 184, 0.16);
  color: #cbd5e1;
}
.admin-webs-gsc-pos {
  display: inline-block;
  min-width: 44px;
  margin-right: 4px;
  font-variant-numeric: tabular-nums;
}
.admin-webs-gsc-top {
  display: inline-block;
  font-size: 10px;
  line-height: 1;
  padding: 2px 5px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.14);
}
.admin-webs-gsc-top--yes {
  background: rgba(16, 185, 129, 0.24);
  color: #d1fae5;
}
.admin-webs-gsc-top--no {
  background: rgba(148, 163, 184, 0.16);
  color: #cbd5e1;
}
html[data-tema="claro"] .admin-webs-gsc-dot {
  box-shadow: 0 0 0 2px rgba(0, 0, 0, 0.03);
  border-color: rgba(0, 0, 0, 0.12);
}
html[data-tema="claro"] .admin-webs-gsc-dot--off {
  background: rgba(0, 0, 0, 0.18);
}
html[data-tema="claro"] .admin-webs-gsc-source--scope {
  color: #065f46;
}
html[data-tema="claro"] .admin-webs-gsc-source--root {
  color: #1e3a8a;
}
html[data-tema="claro"] .admin-webs-gsc-source--off {
  color: #334155;
}
html[data-tema="claro"] .admin-webs-gsc-top--yes {
  color: #065f46;
}
html[data-tema="claro"] .admin-webs-gsc-top--no {
  color: #334155;
}

html[data-tema="claro"] .admin-webs-host-pill--tone0 { --aw-pill-fg: hsl(0, 72%, 32%); }
html[data-tema="claro"] .admin-webs-host-pill--tone1 { --aw-pill-fg: hsl(18, 72%, 30%); }
html[data-tema="claro"] .admin-webs-host-pill--tone2 { --aw-pill-fg: hsl(36, 78%, 28%); }
html[data-tema="claro"] .admin-webs-host-pill--tone3 { --aw-pill-fg: hsl(54, 82%, 26%); }
html[data-tema="claro"] .admin-webs-host-pill--tone4 { --aw-pill-fg: hsl(72, 70%, 26%); }
html[data-tema="claro"] .admin-webs-host-pill--tone5 { --aw-pill-fg: hsl(90, 65%, 26%); }
html[data-tema="claro"] .admin-webs-host-pill--tone6 { --aw-pill-fg: hsl(108, 58%, 26%); }
html[data-tema="claro"] .admin-webs-host-pill--tone7 { --aw-pill-fg: hsl(126, 55%, 26%); }
html[data-tema="claro"] .admin-webs-host-pill--tone8 { --aw-pill-fg: hsl(144, 52%, 26%); }
html[data-tema="claro"] .admin-webs-host-pill--tone9 { --aw-pill-fg: hsl(162, 58%, 26%); }
html[data-tema="claro"] .admin-webs-host-pill--tone10 { --aw-pill-fg: hsl(180, 62%, 26%); }
html[data-tema="claro"] .admin-webs-host-pill--tone11 { --aw-pill-fg: hsl(198, 70%, 28%); }
html[data-tema="claro"] .admin-webs-host-pill--tone12 { --aw-pill-fg: hsl(216, 75%, 30%); }
html[data-tema="claro"] .admin-webs-host-pill--tone13 { --aw-pill-fg: hsl(234, 68%, 32%); }
html[data-tema="claro"] .admin-webs-host-pill--tone14 { --aw-pill-fg: hsl(252, 64%, 34%); }
html[data-tema="claro"] .admin-webs-host-pill--tone15 { --aw-pill-fg: hsl(270, 58%, 34%); }
html[data-tema="claro"] .admin-webs-host-pill--tone16 { --aw-pill-fg: hsl(288, 56%, 32%); }
html[data-tema="claro"] .admin-webs-host-pill--tone17 { --aw-pill-fg: hsl(306, 62%, 32%); }
html[data-tema="claro"] .admin-webs-host-pill--tone18 { --aw-pill-fg: hsl(324, 68%, 32%); }
html[data-tema="claro"] .admin-webs-host-pill--tone19 { --aw-pill-fg: hsl(342, 72%, 32%); }
html[data-tema="claro"] .admin-webs-host-pill--tone-muted { --aw-pill-fg: #475569; }

/* Admanager hub */
.admanager-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 0 0 20px;
  padding: 12px 14px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
}
.admanager-nav__link {
  display: inline-flex;
  align-items: center;
  padding: 8px 14px;
  border-radius: 999px;
  font-weight: 600;
  font-size: 14px;
  color: var(--muted);
  text-decoration: none;
  border: 1px solid transparent;
}
.admanager-nav__link:hover {
  color: #fff;
  border-color: var(--border);
}
.admanager-nav__link--active {
  color: #fff;
  background: rgba(25, 139, 255, 0.25);
  border-color: rgba(25, 139, 255, 0.45);
}

.page-shell--admanager {
  display: flex;
  flex-direction: column;
  gap: 0;
}

.admanager-page-header {
  display: flex;
  flex-direction: column;
  gap: 20px;
  margin-bottom: 24px;
}

.page-head--admanager-top {
  margin: 0;
  padding: 18px 20px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
}

.page-head--admanager-top h1 {
  font-size: clamp(1.2rem, 2.2vw, 1.55rem);
  line-height: 1.25;
  margin: 0;
  font-weight: 700;
}

.page-shell--admanager .admanager-nav {
  margin: 0;
}

.admanager-dashboard-kpis {
  margin-top: 8px;
}

.admanager-dashboard-meta {
  margin-top: 20px;
  padding: 14px 18px;
}

.admanager-dashboard-meta__line {
  margin: 0;
  font-size: 14px;
  color: rgba(234, 243, 255, 0.88);
}

.admanager-operacion-grid {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.admanager-operacion-grid .panel {
  width: 100%;
  max-width: 100%;
  padding: 20px;
}

.admanager-operacion-site > .admanager-operacion-summary {
  list-style: none;
  cursor: pointer;
}

.admanager-operacion-site > .admanager-operacion-summary::-webkit-details-marker {
  display: none;
}

.admanager-operacion-site > .admanager-operacion-summary::marker {
  content: "";
}

.admanager-operacion-site:not([open]) > .admanager-operacion-summary .page-head {
  margin-bottom: 0;
}

.admanager-operacion-site[open] > .admanager-operacion-summary {
  margin-bottom: 12px;
  padding-bottom: 12px;
  border-bottom: 1px solid rgba(234, 243, 255, 0.12);
}

.admanager-operacion-site > .admanager-operacion-body {
  padding-top: 4px;
}

.admanager-operacion-grid .field-grid.cols-2 {
  grid-template-columns: repeat(2, minmax(220px, 1fr));
}

@media (max-width: 900px) {
  .admanager-operacion-grid .field-grid.cols-2 {
    grid-template-columns: 1fr;
  }
}

.admanager-network-reveal {
  display: inline-block;
  margin: 0;
  padding: 0;
  border: none;
  border-bottom: 0;
  background: transparent;
  color: inherit;
  font: inherit;
  cursor: help;
  text-align: inherit;
  border-radius: 0;
  white-space: nowrap;
}

.admanager-network-reveal:hover,
.admanager-network-reveal:focus-visible {
  text-decoration: none;
  outline: none;
}

.admanager-network-popover {
  position: fixed;
  z-index: 12000;
  max-width: min(96vw, 320px);
  padding: 10px 12px;
  font-size: 13px;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  word-break: break-all;
  line-height: 1.35;
  background: rgba(10, 18, 38, 0.97);
  color: #e8f0ff;
  border: 1px solid rgba(118, 168, 255, 0.4);
  border-radius: 10px;
  box-shadow: 0 10px 32px rgba(0, 0, 0, 0.5);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.12s ease;
}

.admanager-network-popover.is-visible {
  opacity: 1;
  pointer-events: auto;
}

html[data-tema="claro"] .admanager-network-reveal {
  border-bottom-color: transparent;
}

html[data-tema="claro"] .admanager-network-popover {
  background: #fff;
  color: #0f172a;
  border-color: var(--border);
  box-shadow: 0 10px 28px rgba(0, 0, 0, 0.12);
}

#admanager-create-block-form input[readonly] {
  opacity: 0.9;
  cursor: default;
}

.admanager-path-hint {
  cursor: help;
  display: inline-block;
  max-width: 250px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.admanager-led {
  display: inline-block;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  vertical-align: middle;
  box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.35);
}

.admanager-led--on {
  background: #22c55e;
}

.admanager-led--warn {
  background: #94a3b8;
}

.admanager-led--off {
  background: #ef4444;
}

.admanager-icon-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 36px;
  height: 36px;
  padding: 0 8px;
  border-radius: var(--radius-md, 8px);
  border: 1px solid var(--border);
  background: rgba(255, 255, 255, 0.04);
  color: inherit;
  text-decoration: none;
  font-size: 16px;
  line-height: 1;
  cursor: pointer;
}

.admanager-icon-btn:hover {
  background: rgba(255, 255, 255, 0.08);
}

.admanager-icon-btn--danger {
  border-color: rgba(239, 68, 68, 0.45);
  color: #f87171;
}

.admanager-sites-actions {
  white-space: nowrap;
}

.admanager-sites-actions .admanager-inline-form {
  display: inline-block;
  margin: 0;
  vertical-align: middle;
}

.admanager-txt-eye {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 36px;
  height: 36px;
  border: none;
  background: transparent;
  font-size: 1.25rem;
  cursor: pointer;
  border-radius: var(--radius-md, 8px);
}

.admanager-txt-eye:hover {
  background: rgba(255, 255, 255, 0.08);
}

.admanager-dialog {
  border: none;
  padding: 0;
  background: transparent;
  max-width: min(560px, 94vw);
}

.admanager-dialog::backdrop {
  background: rgba(0, 0, 0, 0.55);
}

.admanager-dialog__panel {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 20px;
  box-shadow: var(--shadow-lg);
}

.admanager-dialog__title {
  margin: 0 0 12px;
  font-size: 1.1rem;
}

.admanager-dialog__pre {
  margin: 0 0 16px;
  padding: 12px;
  max-height: 50vh;
  overflow: auto;
  font-size: 13px;
  white-space: pre-wrap;
  word-break: break-word;
  background: rgba(0, 0, 0, 0.25);
  border-radius: var(--radius-md);
}

.admanager-th-sort {
  color: inherit;
  text-decoration: none;
  font-weight: 600;
}

.admanager-th-sort:hover {
  text-decoration: underline;
}

.admanager-creator--admin {
  color: #86efac;
}

.admanager-creator--legacy {
  color: rgba(234, 243, 255, 0.88);
}

.page-shell--admanager .table-card .table-card__head {
  padding-bottom: 12px;
}

.page-shell--admanager .table-card .table-card__head + table {
  margin-top: 4px;
}
