/* JValen by ValentSoft — sistema visual global
   Puntos de corte: móvil < 768px · tablet 768–991px · escritorio ≥ 992px (barra lateral fija). */
:root {
  --bs-primary: #0f766e;
  --bs-primary-rgb: 15, 118, 110;
  --bs-success: #15803d;
  --bs-success-rgb: 21, 128, 61;
  --bs-danger: #c2414b;
  --bs-danger-rgb: 194, 65, 75;
  --bs-body-font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --ink-950: #102a2e;
  --ink-900: #17363a;
  --ink-800: #26494c;
  --ink-700: #3f5e61;
  --ink-600: #5b7275;
  --ink-500: #7c9092;
  --mist-50: #f7f9f8;
  --mist-100: #eef3f0;
  --mist-200: #dfe8e3;
  --mist-300: #cbd8d2;
  --teal-800: #0b5f59;
  --teal-700: #0f766e;
  --teal-600: #0d9488;
  --teal-100: #ccfbf1;
  --teal-50: #effcf8;
  --lime-300: #bef264;
  --amber-600: #d97706;
  --indigo-600: #4f46e5;
  --rose-600: #e11d48;
  --surface: #ffffff;
  --canvas: #f3f6f4;
  --shadow-xs: 0 1px 2px rgba(16, 42, 46, 0.05);
  --shadow-sm: 0 1px 2px rgba(16, 42, 46, 0.04), 0 6px 18px rgba(16, 42, 46, 0.06);
  --shadow-md: 0 18px 50px rgba(16, 42, 46, 0.12);
  --radius-sm: 0.65rem;
  --radius-md: 0.95rem;
  --radius-lg: 1.4rem;
  --sidebar-width: 16.5rem;
  --topbar-height: 4rem;
  --bottom-nav-height: 4.1rem;
  --gutter: clamp(1rem, 3vw, 2.25rem);
  --transition: 160ms ease;
}

* { box-sizing: border-box; }
html { min-width: 320px; scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  min-height: 100vh;
  margin: 0;
  color: var(--ink-950);
  background: var(--canvas);
  font-family: var(--bs-body-font-family);
  font-size: 0.94rem;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  -webkit-tap-highlight-color: rgba(13, 148, 136, 0.12);
}
a { color: var(--teal-700); text-underline-offset: 0.2em; transition: color var(--transition); }
a:hover { color: var(--ink-950); }
h1, h2, h3, h4, h5, h6 { color: var(--ink-950); font-weight: 750; letter-spacing: -0.022em; }
.text-secondary { color: var(--ink-600) !important; }
.min-vh-75 { min-height: 75vh; }
.icon { width: 1.15rem; height: 1.15rem; flex: 0 0 auto; }
.skip-link { position: absolute; z-index: 2000; top: -3rem; left: 1rem; padding: 0.5rem 0.9rem; border-radius: var(--radius-sm); color: #fff; background: var(--ink-950); }
.skip-link:focus { top: 1rem; color: #fff; }
:focus-visible { outline: 3px solid rgba(13, 148, 136, 0.35); outline-offset: 2px; }

/* ---------- Estructura de la aplicación ---------- */
.app-layout { display: flex; min-height: 100vh; }
.app-content { display: flex; flex: 1 1 auto; flex-direction: column; min-width: 0; }
.app-main { flex: 1 0 auto; width: 100%; max-width: 1440px; margin: 0 auto; padding: clamp(1.25rem, 2.6vw, 2.25rem) var(--gutter) 3rem; }
.app-footer { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 0.25rem 1rem; padding: 1.1rem var(--gutter) 1.5rem; border-top: 1px solid var(--mist-200); color: var(--ink-500); font-size: 0.74rem; }

/* Barra lateral */
.app-sidebar {
  --bs-offcanvas-width: min(86vw, 19rem);
  --bs-offcanvas-bg: var(--ink-950);
  display: flex;
  flex-direction: column;
  color: rgba(255, 255, 255, 0.78);
  background:
    radial-gradient(circle at 0% 0%, rgba(94, 234, 212, 0.16), transparent 16rem),
    var(--ink-950);
}
.sidebar-head { display: flex; align-items: center; justify-content: space-between; gap: 0.75rem; padding: 1.15rem 1.15rem 0.9rem; }
.sidebar-org { margin: 0.25rem 0.85rem 0.75rem; padding: 0.75rem 0.85rem; border: 1px solid rgba(255, 255, 255, 0.08); border-radius: var(--radius-sm); background: rgba(255, 255, 255, 0.05); line-height: 1.25; }
.sidebar-org-label { display: block; color: rgba(255, 255, 255, 0.45); font-size: 0.62rem; font-weight: 700; letter-spacing: 0.12em; text-transform: uppercase; }
.sidebar-org-name { display: block; margin-top: 0.2rem; overflow: hidden; color: #fff; font-size: 0.88rem; text-overflow: ellipsis; white-space: nowrap; }
.sidebar-org-role { color: var(--lime-300); font-size: 0.72rem; font-weight: 600; }
.sidebar-nav { flex: 1 1 auto; overflow-y: auto; padding: 0.25rem 0.7rem 1rem; scrollbar-width: thin; scrollbar-color: rgba(255, 255, 255, 0.18) transparent; }
.side-group { display: grid; gap: 0.12rem; padding-top: 0.55rem; }
.side-group + .side-group { margin-top: 0.4rem; border-top: 1px solid rgba(255, 255, 255, 0.06); }
.side-title { padding: 0.35rem 0.7rem 0.25rem; color: rgba(255, 255, 255, 0.42); font-size: 0.64rem; font-weight: 750; letter-spacing: 0.13em; text-transform: uppercase; }
.side-link {
  position: relative;
  display: flex;
  align-items: center;
  gap: 0.72rem;
  width: 100%;
  min-height: 2.5rem;
  padding: 0.5rem 0.7rem;
  border: 0;
  border-radius: 0.6rem;
  color: rgba(255, 255, 255, 0.72);
  background: transparent;
  font-size: 0.875rem;
  font-weight: 560;
  text-align: left;
  text-decoration: none;
  transition: color var(--transition), background-color var(--transition);
}
.side-link .icon { width: 1.08rem; height: 1.08rem; opacity: 0.85; }
.side-link:hover { color: #fff; background: rgba(255, 255, 255, 0.07); }
.side-link.active { color: #fff; background: rgba(94, 234, 212, 0.14); font-weight: 650; }
.side-link.active::before { position: absolute; top: 0.55rem; bottom: 0.55rem; left: -0.7rem; width: 3px; border-radius: 0 3px 3px 0; background: var(--lime-300); content: ""; }
.side-link.active .icon { color: var(--lime-300); opacity: 1; }
.sidebar-foot { padding: 0.75rem 0.7rem calc(0.9rem + env(safe-area-inset-bottom)); border-top: 1px solid rgba(255, 255, 255, 0.08); }
.sidebar-user { display: flex; align-items: center; gap: 0.6rem; padding: 0.4rem 0.7rem 0.6rem; }
.sidebar-user-email { overflow: hidden; color: rgba(255, 255, 255, 0.8); font-size: 0.8rem; text-overflow: ellipsis; white-space: nowrap; }
.side-logout:hover { color: #fecdd3; background: rgba(225, 29, 72, 0.12); }

/* Barra superior */
.app-topbar {
  position: sticky;
  z-index: 1020;
  top: 0;
  display: flex;
  align-items: center;
  gap: 0.75rem;
  min-height: var(--topbar-height);
  padding: 0.6rem var(--gutter);
  padding-top: calc(0.6rem + env(safe-area-inset-top));
  border-bottom: 1px solid rgba(16, 42, 46, 0.07);
  background: rgba(243, 246, 244, 0.86);
  backdrop-filter: saturate(160%) blur(14px);
}
.topbar-brand { color: var(--ink-950) !important; }
.topbar-brand .brand-mark { width: 2rem; height: 2rem; }
.topbar-context { align-items: center; gap: 0.5rem; color: var(--ink-600); font-size: 0.85rem; font-weight: 600; }
.topbar-context .icon { color: var(--teal-700); }
.topbar-actions { display: flex; align-items: center; gap: 0.4rem; margin-left: auto; }
.icon-button {
  display: inline-grid;
  width: 2.6rem;
  height: 2.6rem;
  place-items: center;
  border: 1px solid transparent;
  border-radius: 0.75rem;
  color: var(--ink-700);
  background: transparent;
  transition: background-color var(--transition), color var(--transition);
}
.icon-button:hover { color: var(--ink-950); background: rgba(16, 42, 46, 0.06); }
.app-sidebar .icon-button { color: rgba(255, 255, 255, 0.75); }
.app-sidebar .icon-button:hover { color: #fff; background: rgba(255, 255, 255, 0.08); }
.user-menu { display: flex; align-items: center; gap: 0.55rem; padding: 0.25rem 0.55rem 0.25rem 0.25rem; border: 1px solid var(--mist-200); border-radius: 999px; color: var(--ink-800); background: var(--surface); font-size: 0.82rem; font-weight: 600; }
.user-menu:hover { border-color: var(--mist-300); }
.user-menu-email { max-width: 14rem; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.user-avatar {
  display: grid;
  flex: 0 0 auto;
  width: 2rem;
  height: 2rem;
  place-items: center;
  border-radius: 50%;
  color: var(--ink-950);
  background: linear-gradient(135deg, #d8f7ed, #bef264);
  font-size: 0.72rem;
  font-weight: 800;
  text-transform: uppercase;
}
.dropdown-menu { --bs-dropdown-link-active-bg: var(--teal-700); padding: 0.4rem; border: 1px solid var(--mist-200); border-radius: var(--radius-md); font-size: 0.88rem; }
.dropdown-item { display: flex; align-items: center; gap: 0.6rem; padding: 0.55rem 0.7rem; border-radius: 0.5rem; }
.dropdown-item .icon { width: 1rem; height: 1rem; color: var(--ink-500); }
.dropdown-item.active .icon, .dropdown-item.text-danger .icon { color: inherit; }
.dropdown-header { overflow: hidden; color: var(--ink-500); font-size: 0.72rem; text-overflow: ellipsis; }

/* Navegación inferior en móvil */
.bottom-nav {
  position: fixed;
  z-index: 1030;
  right: 0;
  bottom: 0;
  left: 0;
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  min-height: var(--bottom-nav-height);
  padding: 0.3rem 0.35rem calc(0.3rem + env(safe-area-inset-bottom));
  border-top: 1px solid var(--mist-200);
  background: rgba(255, 255, 255, 0.94);
  box-shadow: 0 -8px 24px rgba(16, 42, 46, 0.06);
  backdrop-filter: blur(14px);
}
.bottom-nav a, .bottom-nav button {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.18rem;
  border: 0;
  border-radius: 0.7rem;
  color: var(--ink-500);
  background: transparent;
  font-size: 0.66rem;
  font-weight: 650;
  text-decoration: none;
}
.bottom-nav .icon { width: 1.3rem; height: 1.3rem; }
.bottom-nav .active { color: var(--teal-700); }
.bottom-nav .active .icon { padding: 0.12rem; border-radius: 0.5rem; background: var(--teal-100); }

/* Marca */
.brand-lockup { display: inline-flex; align-items: center; gap: 0.7rem; color: #fff; text-decoration: none; letter-spacing: -0.035em; }
.brand-lockup:hover { color: inherit; }
.brand-mark { width: 2.25rem; height: 2.25rem; border-radius: 0.72rem; box-shadow: 0 5px 15px rgba(0, 0, 0, 0.18); object-fit: contain; }
.brand-copy { display: flex; flex-direction: column; line-height: 1; }
.brand-copy strong { font-size: 1.08rem; font-weight: 800; letter-spacing: -0.045em; }
.brand-copy small { margin-top: 0.27rem; color: rgba(255, 255, 255, 0.5); font-size: 0.54rem; font-weight: 700; letter-spacing: 0.12em; text-transform: uppercase; }

/* ---------- Cabeceras de página ---------- */
.page-header { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 1rem 1.5rem; margin-bottom: 1.5rem; }
.page-header > :first-child { flex: 1 1 18rem; min-width: 0; }
.page-header > :last-child:not(:first-child) { display: flex; flex-wrap: wrap; gap: 0.5rem; }
.page-title { margin-bottom: 0.15rem; font-size: clamp(1.45rem, 1.2rem + 1vw, 2rem); line-height: 1.2; }
.page-eyebrow { display: inline-block; margin-bottom: 0.3rem; color: var(--teal-700); font-size: 0.7rem; font-weight: 750; letter-spacing: 0.12em; text-transform: uppercase; }
.back-link { display: inline-flex; align-items: center; gap: 0.3rem; margin-bottom: 0.5rem; color: var(--ink-600); font-size: 0.82rem; font-weight: 650; text-decoration: none; }
.back-link:hover { color: var(--teal-700); }
.split-heading { margin-bottom: 0.75rem; font-size: 1.12rem; }

/* ---------- Tarjetas y métricas ---------- */
.card { overflow: hidden; border: 1px solid rgba(24, 63, 64, 0.08) !important; border-radius: var(--radius-md); background: var(--surface); box-shadow: var(--shadow-sm) !important; }
.card-header, .card-footer { border-color: var(--mist-200); background: var(--mist-50) !important; }
.card-header { padding: 0.85rem 1.15rem; color: var(--ink-900); font-size: 0.84rem; font-weight: 750 !important; letter-spacing: 0.01em; }
.card-footer { padding: 0.85rem 1.15rem; }
.card-body { padding: 1.15rem; }
.panel-heading { display: flex; align-items: center; gap: 0.6rem; }
.panel-heading::before { width: 0.4rem; height: 0.4rem; flex: 0 0 auto; border-radius: 50%; background: var(--teal-600); box-shadow: 0 0 0 4px rgba(13, 148, 136, 0.12); content: ""; }
.metric { --metric-rgb: 15, 118, 110; position: relative; height: 100%; overflow: hidden; }
.metric .card-body { position: relative; display: grid; grid-template-columns: 1fr auto; gap: 0.25rem 0.75rem; align-items: start; padding: 1.1rem 1.15rem; }
.metric::after { position: absolute; right: -2.2rem; bottom: -2.6rem; width: 7rem; height: 7rem; border-radius: 50%; background: rgba(var(--metric-rgb), 0.07); content: ""; }
.metric-label { color: var(--ink-600); font-size: 0.78rem; font-weight: 600; line-height: 1.3; }
.metric-value { grid-column: 1; align-self: end; margin-top: 0.5rem; color: var(--ink-950); font-size: clamp(1.6rem, 1.2rem + 1.4vw, 2.25rem); font-weight: 800; letter-spacing: -0.045em; line-height: 1; }
.metric small { grid-column: 1; }
.metric-icon { display: grid; grid-row: 1 / span 2; grid-column: 2; width: 2.5rem; height: 2.5rem; place-items: center; border-radius: 0.8rem; color: rgb(var(--metric-rgb)); background: rgba(var(--metric-rgb), 0.1); }
.metric-icon .icon, .metric-icon svg { width: 1.2rem; height: 1.2rem; }
.metric-leaves { --metric-rgb: 217, 119, 6; }
.metric-contracts { --metric-rgb: 79, 70, 229; }
.metric-health { --metric-rgb: 225, 29, 72; }
a.metric { color: inherit; text-decoration: none; transition: transform var(--transition), box-shadow var(--transition); }
a.metric:hover { box-shadow: var(--shadow-md) !important; transform: translateY(-2px); }

/* ---------- Botones y formularios ---------- */
.btn { --bs-btn-padding-x: 1rem; --bs-btn-padding-y: 0.58rem; display: inline-flex; align-items: center; justify-content: center; gap: 0.45rem; border-radius: 0.68rem; font-size: 0.88rem; font-weight: 650; transition: transform var(--transition), box-shadow var(--transition), color var(--transition), background-color var(--transition), border-color var(--transition); }
.btn .icon { width: 1rem; height: 1rem; }
.btn:hover { transform: translateY(-1px); }
.btn:active { transform: translateY(0); }
.btn-primary { border-color: var(--teal-700); background: linear-gradient(135deg, var(--teal-700), var(--teal-600)); box-shadow: 0 4px 14px rgba(15, 118, 110, 0.22); }
.btn-primary:hover, .btn-primary:focus { border-color: var(--teal-800); background: linear-gradient(135deg, #0b655f, #0f8279); box-shadow: 0 8px 20px rgba(15, 118, 110, 0.28); }
.btn-outline-primary { --bs-btn-color: var(--teal-700); --bs-btn-border-color: #a6d7d1; --bs-btn-bg: #fff; --bs-btn-hover-bg: var(--teal-50); --bs-btn-hover-color: var(--ink-950); --bs-btn-hover-border-color: #73beb5; --bs-btn-active-bg: var(--teal-100); --bs-btn-active-color: var(--ink-950); --bs-btn-active-border-color: #73beb5; }
.btn-outline-secondary { --bs-btn-color: var(--ink-700); --bs-btn-border-color: var(--mist-300); --bs-btn-bg: #fff; --bs-btn-hover-color: var(--ink-950); --bs-btn-hover-bg: var(--mist-100); --bs-btn-hover-border-color: #b7c7c0; --bs-btn-active-bg: var(--ink-950); --bs-btn-active-border-color: var(--ink-950); --bs-btn-active-color: #fff; }
.btn-outline-danger { --bs-btn-bg: #fff; }
.btn-success { box-shadow: 0 4px 14px rgba(21, 128, 61, 0.18); }
.btn-sm { --bs-btn-padding-x: 0.7rem; --bs-btn-padding-y: 0.36rem; border-radius: 0.55rem; font-size: 0.79rem; }
.btn-lg { --bs-btn-padding-x: 1.35rem; --bs-btn-padding-y: 0.78rem; border-radius: 0.82rem; font-size: 1rem; }
.btn-link { box-shadow: none !important; }
.form-label { margin-bottom: 0.38rem; color: var(--ink-800); font-size: 0.79rem; font-weight: 650; }
.form-control, .form-select { min-height: 2.75rem; border: 1px solid var(--mist-300); border-radius: var(--radius-sm); color: var(--ink-950); background-color: #fbfcfb; font-size: 0.92rem; transition: border-color var(--transition), box-shadow var(--transition), background-color var(--transition); }
.form-control-sm, .form-select-sm { min-height: 2.2rem; font-size: 0.82rem; }
textarea.form-control { min-height: 6rem; }
select[multiple].form-select { min-height: 10rem; }
.form-control:hover, .form-select:hover { border-color: #a9beb7; }
.form-control:focus, .form-select:focus { border-color: var(--teal-600); background-color: #fff; box-shadow: 0 0 0 0.22rem rgba(13, 148, 136, 0.14); }
.form-control::placeholder { color: #94a6a2; }
.form-control[type="file"] { padding: 0.42rem; }
.form-control[type="file"]::file-selector-button { margin: -0.42rem 0.8rem -0.42rem -0.42rem; padding: 0.68rem 0.9rem; border: 0; border-right: 1px solid var(--mist-200); color: var(--ink-800); background: var(--mist-100); font-weight: 650; }
.form-check-input { width: 1.15rem; height: 1.15rem; border-color: var(--mist-300); }
.form-check-input:checked { border-color: var(--teal-700); background-color: var(--teal-700); }
.form-check-label { font-size: 0.88rem; }
.form-text { color: var(--ink-500); font-size: 0.78rem; }
.invalid-feedback { font-size: 0.78rem; }
.input-group-text { border-color: var(--mist-300); background: var(--mist-100); font-size: 0.8rem; }
fieldset:disabled .form-control, fieldset:disabled .form-select { background-color: var(--mist-50); }
.select-search-wrap { position: relative; }
.select-search-icon { position: absolute; z-index: 2; top: 50%; left: 0.9rem; width: 1rem; height: 1rem; color: var(--ink-500); pointer-events: none; transform: translateY(-50%); }
.select-search-input { padding-right: 2.5rem; padding-left: 2.55rem; background-color: #fff; }
.select-search-status { min-height: 1.2rem; margin-top: 0.3rem; color: var(--ink-500); font-size: 0.73rem; }
.form-section-title { display: flex; align-items: center; gap: 0.55rem; margin: 0; color: var(--ink-900); font-size: 0.95rem; font-weight: 750; }
.form-section-title .icon { color: var(--teal-700); }
.sticky-actions { position: sticky; z-index: 5; bottom: 0; display: flex; justify-content: flex-end; gap: 0.5rem; padding: 0.85rem 1.15rem; border-top: 1px solid var(--mist-200); background: rgba(255, 255, 255, 0.95); backdrop-filter: blur(8px); }
.filter-bar .card-body { padding: 0.9rem 1rem; }

/* Formularios plegables */
.record-form > summary { display: inline-flex; list-style: none; }
.record-form > summary::-webkit-details-marker { display: none; }
.record-form[open] > summary { margin-bottom: 0.4rem; color: var(--ink-950); background: var(--mist-100); }
.record-form > .card, .record-form > form.card { border-style: dashed !important; box-shadow: none !important; background: var(--mist-50); }

/* ---------- Tablas y listas ---------- */
.table { --bs-table-bg: transparent; --bs-table-hover-bg: rgba(204, 251, 241, 0.25); margin-bottom: 0; color: var(--ink-900); }
.table > :not(caption) > * > * { padding: 0.85rem 1.1rem; border-bottom-color: var(--mist-200); vertical-align: middle; }
.table thead th { border-bottom-width: 1px; color: var(--ink-600); background: var(--mist-50); font-size: 0.68rem; font-weight: 750; letter-spacing: 0.07em; text-transform: uppercase; white-space: nowrap; }
.table tbody tr:last-child td { border-bottom: 0; }
.table a.fw-semibold { color: var(--ink-950); }
.table a.fw-semibold:hover { color: var(--teal-700); }
.table-responsive { scrollbar-width: thin; }
.list-group-item { padding: 0.85rem 1.15rem; border-color: var(--mist-200); color: var(--ink-900); background: transparent; }
.list-group-item-action { transition: background-color var(--transition); }
.list-group-item-action:hover { color: var(--ink-950); background: rgba(204, 251, 241, 0.25); }
.data-list { display: grid; grid-template-columns: minmax(7.5rem, 38%) 1fr; gap: 0; margin: 0; }
.data-list dt, .data-list dd { margin: 0; padding: 0.5rem 0; border-bottom: 1px dashed var(--mist-200); }
.data-list dt { padding-right: 0.75rem; color: var(--ink-600); font-size: 0.8rem; font-weight: 600; }
.data-list dd { min-width: 0; color: var(--ink-950); font-size: 0.88rem; font-weight: 600; overflow-wrap: anywhere; }
.data-list dt:nth-last-child(2), .data-list dd:last-child { border-bottom: 0; }
.data-list .is-empty { color: var(--ink-500); font-weight: 400; }
.empty-state { padding: 2.75rem 1.5rem !important; color: var(--ink-500) !important; text-align: center; }
.empty-state::before { display: block; width: 2.5rem; height: 2.5rem; margin: 0 auto 0.7rem; border-radius: 50%; background: var(--mist-100); content: "—"; font-size: 1.2rem; line-height: 2.4rem; }

/* ---------- Estados ---------- */
.badge { padding: 0.38rem 0.6rem; border-radius: 999px; font-size: 0.68rem; font-weight: 700; letter-spacing: 0.02em; }
.text-bg-success { color: #166534 !important; background: #dcfce7 !important; }
.text-bg-warning { color: #92400e !important; background: #fef3c7 !important; }
.text-bg-danger { color: #be123c !important; background: #ffe4e6 !important; }
.text-bg-secondary { color: #475569 !important; background: #e2e8f0 !important; }
.text-bg-info { color: #075985 !important; background: #e0f2fe !important; }
.text-bg-light { color: var(--ink-700) !important; background: var(--mist-100) !important; }
.text-bg-primary { color: #115e59 !important; background: var(--teal-100) !important; }
.alert { border: 1px solid transparent; border-radius: var(--radius-sm); box-shadow: var(--shadow-xs); font-size: 0.88rem; }
.alert-info { border-color: #bae6fd; color: #075985; background: #f0f9ff; }
.alert-success { border-color: #bbf7d0; color: #166534; background: #f0fdf4; }
.alert-danger { border-color: #fecdd3; color: #9f1239; background: #fff1f2; }
.alert-warning { border-color: #fde68a; color: #92400e; background: #fffbeb; }
.flash-stack { display: grid; gap: 0.5rem; margin-bottom: 1.25rem; }
.flash-stack .alert { margin: 0; }

/* ---------- Componentes de módulos ---------- */
.quick-links { display: grid; gap: 0.5rem; }
.quick-link { display: flex; align-items: center; gap: 0.75rem; padding: 0.7rem 0.8rem; border: 1px solid var(--mist-200); border-radius: var(--radius-sm); color: var(--ink-900); background: #fff; font-size: 0.87rem; font-weight: 600; text-decoration: none; transition: border-color var(--transition), background-color var(--transition), transform var(--transition); }
.quick-link:hover { border-color: #a6d7d1; color: var(--ink-950); background: var(--teal-50); transform: translateX(2px); }
.quick-link > .icon:first-child { width: 2.1rem; height: 2.1rem; padding: 0.45rem; border-radius: 0.6rem; color: var(--teal-700); background: var(--teal-50); }
.quick-link > .icon:last-child { margin-left: auto; width: 1rem; color: var(--ink-500); }
.activity-item { display: flex; justify-content: space-between; gap: 1rem; padding: 0.8rem 1.15rem; }
.activity-name { color: var(--ink-900); font-size: 0.86rem; font-weight: 600; }
.activity-time { flex: 0 0 auto; color: var(--ink-500); font-size: 0.75rem; }
.contract-item, .request-item, .document-item { padding: 0.95rem 1.15rem; }
.contract-item strong, .request-item strong, .document-item strong { color: var(--ink-950); }
.request-meta, .document-meta, .contract-meta { color: var(--ink-600); font-size: 0.8rem; }
.status-live { display: inline-flex; align-items: center; gap: 0.4rem; color: #166534; font-size: 0.78rem; font-weight: 700; }
.status-live::before { width: 0.48rem; height: 0.48rem; border-radius: 50%; background: #22c55e; box-shadow: 0 0 0 4px rgba(34, 197, 94, 0.12); content: ""; }
.employee-documents { scroll-margin-top: 6rem; }
.employee-document-list { min-height: 18rem; border-right: 1px solid var(--mist-200); background: var(--mist-50); }
.employee-document-form { background: #fff; }
.greeting-date { display: inline-block; color: var(--ink-500); font-size: 0.85rem; }
.greeting-date::first-letter { text-transform: uppercase; }

/* Cabecera de perfil */
.profile-hero { position: relative; display: grid; grid-template-columns: auto 1fr auto; gap: 1rem 1.25rem; align-items: center; margin-bottom: 1.25rem; padding: 1.25rem; overflow: hidden; border: 1px solid rgba(24, 63, 64, 0.08); border-radius: var(--radius-lg); background: linear-gradient(120deg, #fff 55%, var(--teal-50)); box-shadow: var(--shadow-sm); }
.profile-hero::after { position: absolute; top: -4rem; right: -3rem; width: 12rem; height: 12rem; border-radius: 50%; background: radial-gradient(circle, rgba(190, 242, 100, 0.35), transparent 70%); content: ""; pointer-events: none; }
.profile-avatar { display: grid; width: 4.25rem; height: 4.25rem; place-items: center; border-radius: 1.2rem; color: #fff; background: linear-gradient(135deg, var(--teal-700), var(--teal-600)); box-shadow: 0 8px 20px rgba(15, 118, 110, 0.25); font-size: 1.35rem; font-weight: 800; letter-spacing: -0.03em; }
.profile-name { margin: 0; font-size: clamp(1.3rem, 1.1rem + 1vw, 1.75rem); line-height: 1.2; }
.profile-meta { display: flex; flex-wrap: wrap; gap: 0.4rem; margin-top: 0.5rem; }
.chip { display: inline-flex; align-items: center; gap: 0.35rem; padding: 0.28rem 0.6rem; border: 1px solid var(--mist-200); border-radius: 999px; color: var(--ink-700); background: rgba(255, 255, 255, 0.85); font-size: 0.76rem; font-weight: 600; }
.chip .icon { width: 0.85rem; height: 0.85rem; color: var(--teal-700); }
.profile-actions { position: relative; z-index: 1; display: flex; flex-wrap: wrap; gap: 0.5rem; justify-content: flex-end; }

/* Pestañas y filtros desplazables */
.tab-scroller, .segmented { position: relative; display: flex; gap: 0.3rem; overflow-x: auto; scrollbar-width: none; -webkit-overflow-scrolling: touch; }
.tab-scroller::-webkit-scrollbar, .segmented::-webkit-scrollbar { display: none; }
.employee-tabs { flex-wrap: nowrap; margin-bottom: 1.25rem; padding: 0.3rem; border: 1px solid var(--mist-200) !important; border-radius: 0.85rem; background: #fff; box-shadow: var(--shadow-xs); }
.employee-tabs .nav-link { display: inline-flex; align-items: center; gap: 0.45rem; padding: 0.5rem 0.85rem; border: 0 !important; border-radius: 0.6rem; color: var(--ink-600); font-size: 0.85rem; font-weight: 600; white-space: nowrap; }
.employee-tabs .nav-link .icon { width: 1rem; height: 1rem; }
.employee-tabs .nav-link:hover { color: var(--ink-950); background: var(--mist-100); }
.employee-tabs .nav-link.active { color: #fff; background: var(--ink-950); }
.can-scroll-right { mask-image: linear-gradient(90deg, #000 85%, transparent); }
.can-scroll-left { mask-image: linear-gradient(90deg, transparent, #000 15%); }
.can-scroll-left.can-scroll-right { mask-image: linear-gradient(90deg, transparent, #000 12%, #000 88%, transparent); }
.segmented { padding: 0.25rem; border: 1px solid var(--mist-200); border-radius: 0.75rem; background: #fff; }
.segmented .btn { flex: 0 0 auto; border: 0; border-radius: 0.55rem !important; box-shadow: none; white-space: nowrap; }
.segmented .btn:not(.active) { background: transparent; }

/* Organigrama */
.org-tree { margin: 0; padding-left: 1.6rem; border-left: 2px solid var(--mist-200); list-style: none; }
.org-tree.org-root { padding-left: 0; border-left: 0; }
.org-node { position: relative; padding: 0.4rem 0; }
.org-tree:not(.org-root) > .org-node::before { position: absolute; top: 1.7rem; left: -1.6rem; width: 1.3rem; border-top: 2px solid var(--mist-200); content: ""; }
.org-card { display: inline-flex; align-items: center; gap: 0.7rem; min-width: min(16rem, 100%); max-width: 100%; padding: 0.6rem 0.9rem 0.6rem 0.6rem; border: 1px solid var(--mist-200); border-radius: var(--radius-sm); background: #fff; box-shadow: var(--shadow-xs); }
.org-avatar { display: grid; flex: 0 0 auto; width: 2.3rem; height: 2.3rem; place-items: center; border-radius: 0.65rem; color: var(--teal-700); background: var(--teal-100); font-size: 0.75rem; font-weight: 800; }

/* Calendario del equipo */
.team-calendar { border-collapse: separate; border-spacing: 0; }
.team-calendar th, .team-calendar td { min-width: 2rem; height: 2.3rem; padding: 0.2rem !important; border-right: 1px solid var(--mist-100); text-align: center; font-size: 0.76rem; }
.team-calendar thead th { position: sticky; top: 0; z-index: 2; letter-spacing: 0; text-transform: none; }
.team-calendar .cal-name { position: sticky; z-index: 3; left: 0; min-width: 11rem; padding-left: 0.9rem !important; border-right: 1px solid var(--mist-200); background: #fff; font-weight: 600; text-align: left; white-space: nowrap; }
.team-calendar thead .cal-name { z-index: 4; background: var(--mist-50); }
.cal-dow { color: var(--ink-500); font-size: 0.64rem; font-weight: 500; }
.cal-today { box-shadow: inset 0 -3px 0 var(--teal-600); }
.cal-weekend { background: var(--mist-100); }
.cal-holiday { background: #fef3c7; }
.cal-vacation { background: #5eead4 !important; }
.cal-vacation-pending { background: repeating-linear-gradient(45deg, #ccfbf1, #ccfbf1 4px, #fff 4px, #fff 8px) !important; }
.cal-leave { background: #93c5fd !important; }
.cal-leave-pending { background: repeating-linear-gradient(45deg, #dbeafe, #dbeafe 4px, #fff 4px, #fff 8px) !important; }
.cal-it { background: #fca5a5 !important; }
.calendar-legend { display: flex; flex-wrap: wrap; gap: 0.4rem 1rem; color: var(--ink-600); }
.calendar-legend span { display: inline-flex; align-items: center; gap: 0.35rem; }
.calendar-legend .cal-cell { display: inline-block; width: 0.9rem; height: 0.9rem; border: 1px solid rgba(16, 42, 46, 0.08); border-radius: 0.25rem; }

/* Informes y avisos */
.report-card { display: block; color: inherit; transition: transform var(--transition), box-shadow var(--transition); }
.report-card:hover { box-shadow: var(--shadow-md) !important; transform: translateY(-2px); }
.report-card .card-body { display: flex; gap: 0.9rem; align-items: flex-start; }
.report-card h2 { color: var(--ink-950); font-size: 1rem; }
.report-icon { display: grid; flex: 0 0 auto; width: 2.5rem; height: 2.5rem; place-items: center; border-radius: 0.75rem; color: var(--teal-700); background: var(--teal-50); }
.report-table td, .report-table th { white-space: nowrap; }
.report-table td:first-child, .report-table th:first-child { position: sticky; z-index: 1; left: 0; background: #fff; box-shadow: 1px 0 0 var(--mist-200); }
.report-table thead th:first-child { background: var(--mist-50); }
.alert-row { padding: 0.8rem 1.15rem; }
.alert-row-danger { box-shadow: inset 3px 0 0 var(--bs-danger); }
.alert-row-warning { box-shadow: inset 3px 0 0 #f59e0b; }
.alert-row-info { box-shadow: inset 3px 0 0 #38bdf8; }
.stars { color: #f59e0b; letter-spacing: 0.05em; white-space: nowrap; }

/* ---------- Páginas públicas ---------- */
.public-shell {
  overflow-x: hidden;
  background:
    radial-gradient(circle at 85% 12%, rgba(94, 234, 212, 0.18), transparent 30rem),
    radial-gradient(circle at 8% 82%, rgba(190, 242, 100, 0.13), transparent 24rem),
    #f8faf8;
}
.public-navbar { position: relative; z-index: 2; padding: 1.1rem 0; padding-top: calc(1.1rem + env(safe-area-inset-top)); }
.public-navbar .brand-lockup { color: var(--ink-950); }
.public-navbar .brand-copy small { color: var(--ink-500); }
.public-nav-actions { display: flex; align-items: center; gap: 0.55rem; }
.public-main { position: relative; z-index: 1; }
.public-footer { padding: 1.5rem 0 2rem; color: var(--ink-500); font-size: 0.75rem; }
.hero { position: relative; min-height: calc(100vh - 6.5rem); padding-block: clamp(3rem, 7vw, 7rem); }
.hero::before { position: absolute; z-index: -1; top: 10%; right: -18%; width: 34rem; height: 34rem; border: 1px solid rgba(15, 118, 110, 0.1); border-radius: 50%; box-shadow: 0 0 0 5rem rgba(15, 118, 110, 0.025), 0 0 0 10rem rgba(15, 118, 110, 0.018); content: ""; }
.hero-badge { display: inline-flex; align-items: center; gap: 0.5rem; margin-bottom: 1.2rem; padding: 0.48rem 0.72rem; border: 1px solid rgba(15, 118, 110, 0.14); border-radius: 999px; color: var(--teal-700); background: rgba(255, 255, 255, 0.72); box-shadow: var(--shadow-xs); font-size: 0.76rem; font-weight: 750; letter-spacing: 0.04em; }
.hero-badge::before { width: 0.45rem; height: 0.45rem; border-radius: 50%; background: var(--teal-600); box-shadow: 0 0 0 4px rgba(13, 148, 136, 0.12); content: ""; }
.hero-title { max-width: 13ch; margin-bottom: 1.25rem; font-size: clamp(2.6rem, 6vw, 5.2rem); font-weight: 800; letter-spacing: -0.06em; line-height: 0.98; }
.hero-title span { color: var(--teal-700); }
.hero-copy { max-width: 39rem; color: var(--ink-600); font-size: clamp(1.05rem, 1.8vw, 1.22rem); line-height: 1.65; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 0.75rem; margin-top: 2rem; }
.hero-proof { display: flex; flex-wrap: wrap; gap: 0.7rem 1.4rem; margin-top: 2rem; color: var(--ink-600); font-size: 0.8rem; font-weight: 600; }
.hero-proof span::before { margin-right: 0.4rem; color: var(--teal-600); content: "✓"; font-weight: 900; }
.product-preview { position: relative; padding: 1rem; border: 1px solid rgba(255, 255, 255, 0.7); border-radius: 1.7rem; background: rgba(255, 255, 255, 0.58); box-shadow: var(--shadow-md); transform: rotate(1.2deg); backdrop-filter: blur(15px); }
.product-preview::before { position: absolute; z-index: -1; inset: 12% -7% -9% 12%; border-radius: 2rem; background: linear-gradient(145deg, rgba(190, 242, 100, 0.5), rgba(94, 234, 212, 0.3)); content: ""; }
.preview-window { overflow: hidden; border: 1px solid var(--mist-200); border-radius: 1.15rem; background: #fff; }
.preview-topbar { display: flex; align-items: center; gap: 0.35rem; padding: 0.8rem 1rem; border-bottom: 1px solid var(--mist-200); background: var(--ink-950); }
.preview-topbar i { width: 0.45rem; height: 0.45rem; border-radius: 50%; background: rgba(255, 255, 255, 0.34); }
.preview-content { padding: clamp(1.25rem, 4vw, 2.25rem); }
.preview-kicker { color: var(--ink-500); font-size: 0.7rem; font-weight: 750; letter-spacing: 0.08em; text-transform: uppercase; }
.preview-title { margin: 0.25rem 0 1.4rem; font-size: 1.35rem; }
.preview-metrics { display: grid; grid-template-columns: repeat(3, 1fr); gap: 0.65rem; }
.preview-metric { min-height: 5.5rem; padding: 0.85rem; border: 1px solid var(--mist-200); border-radius: 0.8rem; background: #fbfcfb; }
.preview-metric span { display: block; color: var(--ink-500); font-size: 0.61rem; }
.preview-metric strong { display: block; margin-top: 0.35rem; font-size: 1.45rem; line-height: 1; }
.preview-list { display: grid; gap: 0.7rem; margin-top: 1.15rem; }
.preview-row { display: grid; grid-template-columns: 2rem 1fr auto; gap: 0.7rem; align-items: center; padding: 0.65rem; border-radius: 0.7rem; background: var(--mist-50); }
.preview-avatar { display: grid; width: 2rem; height: 2rem; place-items: center; border-radius: 50%; color: var(--teal-700); background: var(--teal-100); font-size: 0.65rem; font-weight: 800; }
.preview-row span { color: var(--ink-700); font-size: 0.7rem; font-weight: 650; }
.preview-status { width: 2.8rem; height: 0.42rem; border-radius: 999px; background: #bbf7d0; }

/* Autenticación */
.auth-layout { display: grid; min-height: calc(100vh - 7rem); place-items: center; padding-block: 2rem 4rem; }
.app-shell .auth-layout { min-height: calc(100vh - 12rem); }
.auth-card { position: relative; width: min(100%, 32rem); overflow: visible; border-radius: var(--radius-lg); box-shadow: var(--shadow-md) !important; }
.auth-card::before { position: absolute; z-index: -1; inset: -0.7rem 1.8rem 0.7rem -0.7rem; border-radius: var(--radius-lg); background: linear-gradient(135deg, rgba(190, 242, 100, 0.4), rgba(94, 234, 212, 0.24)); content: ""; }
.auth-card .card-body { padding: clamp(1.5rem, 5vw, 2.6rem) !important; }
.auth-icon { display: grid; width: 3rem; height: 3rem; margin-bottom: 1.25rem; place-items: center; border-radius: 1rem; color: var(--teal-700); background: var(--teal-100); font-size: 1.15rem; font-weight: 800; }
.auth-title { font-size: clamp(1.6rem, 4vw, 2rem); }
.auth-footer { color: var(--ink-600); }
.auth-footer a { font-weight: 700; }

/* ---------- Animación ---------- */
@keyframes rise-in { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: translateY(0); } }
.app-main > *, .public-main > * { animation: rise-in 360ms both; }

/* ---------- Escritorio: barra lateral fija ---------- */
@media (min-width: 992px) {
  .app-sidebar { position: sticky; top: 0; flex: 0 0 var(--sidebar-width); width: var(--sidebar-width); height: 100vh; background-color: var(--ink-950) !important; }
  .app-sidebar .offcanvas-body { display: contents; }
}

/* ---------- Tablet y móvil ---------- */
@media (max-width: 991.98px) {
  .app-sidebar .sidebar-nav { padding-bottom: 1.5rem; }
  .profile-hero { grid-template-columns: auto 1fr; }
  .profile-actions { grid-column: 1 / -1; justify-content: flex-start; }
  .hero { padding-top: 2.5rem; }
  .product-preview { margin-top: 3.5rem; transform: none; }
}

/* ---------- Móvil ---------- */
@media (max-width: 767.98px) {
  body.app-shell { padding-bottom: calc(var(--bottom-nav-height) + env(safe-area-inset-bottom)); }
  .app-topbar { min-height: 3.6rem; }
  .app-main { padding-top: 1.1rem; padding-bottom: 2rem; }
  .app-footer { justify-content: center; text-align: center; }
  .app-footer span:last-child { display: none; }
  /* 16px evita el zoom automático de iOS al enfocar campos. */
  .form-control, .form-select { min-height: 2.9rem; font-size: 1rem; }
  .form-control-sm, .form-select-sm { min-height: 2.5rem; font-size: 0.95rem; }
  .btn { --bs-btn-padding-y: 0.66rem; }
  .btn-sm { --bs-btn-padding-y: 0.46rem; }
  .page-header { align-items: stretch; margin-bottom: 1.15rem; }
  .page-header > :last-child:not(:first-child) { width: 100%; }
  .page-header > :last-child:not(:first-child) > .btn,
  .page-header > :last-child:not(:first-child) > a,
  .page-header > :last-child:not(:first-child) > form { flex: 1 1 auto; }
  .page-header > :last-child:not(:first-child) form .btn { width: 100%; }
  .page-header > a.btn:last-child:not(:first-child) { display: flex; }
  /* Tres o más acciones: fila desplazable en lugar de botones apilados. */
  .page-header > :last-child:not(:first-child):has(> :nth-child(3)) { flex-wrap: nowrap; overflow-x: auto; margin-inline: calc(var(--gutter) * -1); padding: 0.1rem var(--gutter) 0.3rem; scrollbar-width: none; }
  .page-header > :last-child:not(:first-child):has(> :nth-child(3)) > * { flex: 0 0 auto; }
  .card-body { padding: 1rem; }
  .empty-state { padding: 1.6rem 1rem !important; }
  .card-header { padding: 0.8rem 1rem; }
  .list-group-item, .contract-item, .request-item, .document-item { padding: 0.85rem 1rem; }
  .request-item > .d-flex, .document-item { align-items: flex-start !important; flex-direction: column; gap: 0.75rem; }
  .request-item .text-end { width: 100%; text-align: left !important; }
  .request-actions .d-flex { justify-content: stretch !important; }
  .request-actions .d-flex .btn { flex: 1; }
  .document-item .btn { width: 100%; }
  .employee-document-list { min-height: auto; border-right: 0; border-bottom: 1px solid var(--mist-200); }
  .profile-hero { gap: 0.85rem; padding: 1rem; border-radius: var(--radius-md); }
  .profile-avatar { width: 3.4rem; height: 3.4rem; border-radius: 1rem; font-size: 1.1rem; }
  .profile-actions .btn { flex: 1 1 auto; }
  .employee-tabs { position: sticky; z-index: 10; top: calc(3.6rem + env(safe-area-inset-top)); margin-inline: calc(var(--gutter) * -1); border-width: 0 0 1px !important; border-radius: 0; box-shadow: none; background: rgba(243, 246, 244, 0.94); backdrop-filter: blur(10px); }
  .employee-tabs .nav-link { padding: 0.5rem 0.75rem; }
  .data-list { grid-template-columns: minmax(6.5rem, 42%) 1fr; }
  .metric .card-body { padding: 0.9rem; }
  .metric-icon { width: 2.1rem; height: 2.1rem; border-radius: 0.65rem; }
  .metric-label { font-size: 0.72rem; }
  .sticky-actions { bottom: calc(var(--bottom-nav-height) + env(safe-area-inset-bottom)); }
  .sticky-actions .btn { flex: 1; }
  .team-calendar .cal-name { min-width: 7.5rem; max-width: 7.5rem; overflow: hidden; text-overflow: ellipsis; }
  .team-calendar th, .team-calendar td { min-width: 1.85rem; }
  .flash-stack { position: sticky; z-index: 15; top: calc(3.9rem + env(safe-area-inset-top)); }
  .hero-title { font-size: clamp(2.5rem, 13vw, 3.8rem); }
  .hero-actions .btn { width: 100%; }
  .preview-metrics { grid-template-columns: 1fr; }
  .preview-metric { min-height: 4.5rem; }

  /* Tablas apiladas: cada fila se convierte en una tarjeta. */
  .table-stack thead { display: none; }
  .table-stack, .table-stack tbody, .table-stack tr, .table-stack td { display: block; width: 100%; }
  .table-stack tr { position: relative; padding: 0.75rem 1rem; border-bottom: 1px solid var(--mist-200); }
  .table-stack tbody tr:last-child { border-bottom: 0; }
  .table-stack > :not(caption) > * > * { padding: 0.2rem 0; border: 0; }
  .table-stack td[data-label] { display: grid; grid-template-columns: minmax(6.5rem, 38%) 1fr; gap: 0.75rem; align-items: baseline; text-align: left !important; }
  .table-stack td[data-label]::before { color: var(--ink-500); font-size: 0.72rem; font-weight: 650; content: attr(data-label); }
  .table-stack td[data-label]:first-child { display: block; padding-bottom: 0.35rem; font-size: 0.95rem; }
  .table-stack td[data-label]:first-child::before, .table-stack td[data-label=""]::before { display: none; }
  .table-stack td[data-label=""] { display: flex; flex-wrap: wrap; gap: 0.4rem; padding-top: 0.55rem; }
  .table-stack td[data-label=""] form, .table-stack td[data-label=""] > .btn { flex: 1 1 0; min-width: 6.5rem; }
  .table-stack td[data-label=""] .btn { width: 100%; }
  .table-stack td[data-label]:first-child { font-weight: 650; }
  .table-stack .row-full td { display: block; }
  .table-stack td .badge { justify-self: start; width: max-content; }
  .table-stack td details { width: 100%; }
}

@media (max-width: 575.98px) {
  .public-nav-actions .btn:first-child { display: none; }
  .brand-mark { width: 2rem; height: 2rem; }
  .auth-layout { padding-top: 1rem; }
  .auth-card::before { inset: -0.4rem 0.6rem 0.5rem -0.4rem; }
  .split-heading { font-size: 1.02rem; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; animation-duration: 0.01ms !important; animation-iteration-count: 1 !important; transition-duration: 0.01ms !important; }
}

@media print {
  .app-sidebar, .app-topbar, .bottom-nav, .app-footer, .page-header .btn, .record-form, form .btn { display: none !important; }
  .app-main { max-width: none; padding: 0; }
  .card { box-shadow: none !important; break-inside: avoid; }
  body { background: #fff; }
}

/* Filas enlazadas: toda la fila abre el detalle. */
.min-w-0 { min-width: 0; }
.table tbody tr { position: relative; }
.stretched-link-row::after { position: absolute; z-index: 1; inset: 0; content: ""; }
.back-link::before { width: 0.9rem; height: 0.9rem; background: currentColor; content: ""; -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2.4' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m15 18-6-6 6-6'/%3E%3C/svg%3E") center / contain no-repeat; mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2.4' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m15 18-6-6 6-6'/%3E%3C/svg%3E") center / contain no-repeat; }

.calendar-scroll { max-height: 70vh; }
.secret-value { padding: 0.15rem 0.45rem; border-radius: 0.35rem; color: var(--ink-950); background: #fff; font-size: 1rem; user-select: all; }

/* Marca de agua ValentSoft: por encima de la barra de navegación inferior en móvil. */
@media (max-width: 767.98px) {
  body.app-shell { --vs-watermark-bottom: calc(var(--bottom-nav-height) + 10px); }
}

.sync-summary { white-space: pre-line; }
