:root {
  --green: #1f4d3a;
  --green-dark: #123126;
  --green-soft: #e8f0eb;
  --gold: #9a762e;
  --gold-soft: #f7f1e4;
  --ink: #1b2923;
  --muted: #5e6c65;
  --surface: #fff;
  --canvas: #f1f4f1;
  --line: #cfd8d1;
  --line-strong: #aebdb4;
  --danger: #a23b35;
  --danger-soft: #fbeae7;
  --warning: #805812;
  --warning-soft: #fbf2dc;
  --radius: .375rem;
  --shadow: 0 .1875rem .625rem rgb(18 49 38 / .08);
}

* { box-sizing: border-box; }

html { min-width: 20rem; background: var(--canvas); }

body {
  min-height: 100vh;
  margin: 0;
  color: var(--ink);
  background: var(--canvas);
  font: 1rem/1.5 Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

.app-shell { display: grid; grid-template-rows: auto minmax(0, 1fr) auto; min-height: 100dvh; }

button, input, select, textarea { font: inherit; }
a { color: var(--green); }

a:focus-visible, button:focus-visible, input:focus-visible, select:focus-visible, textarea:focus-visible {
  outline: .1875rem solid #b78a2b;
  outline-offset: .125rem;
}

.site-header { background: var(--surface); border-top: .25rem solid var(--gold); border-bottom: .0625rem solid var(--line); }
.site-header__inner, .page-shell, .site-footer { width: 100%; margin: 0 auto; padding-right: clamp(1rem, 3vw, 3rem); padding-left: clamp(1rem, 3vw, 3rem); }

.site-header__inner, .page-heading, .record-header, .panel__heading, .site-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
}

.site-header__inner { min-height: 5.75rem; padding-top: .75rem; padding-bottom: .75rem; }
.page-shell { padding-top: clamp(1.5rem, 3vw, 2.5rem); padding-bottom: 2.5rem; }
.site-footer { min-height: 4rem; color: var(--muted); border-top: .0625rem solid var(--line); background: var(--surface); font-size: .8125rem; }

.brand { display: flex; align-items: center; min-width: 0; gap: 1rem; color: inherit; text-decoration: none; }
.brand__logo { width: 4.125rem; height: 3.75rem; object-fit: contain; flex: 0 0 auto; }
.brand__copy { display: grid; gap: .0625rem; min-width: 0; }
.brand__institution, .brand__subtitle, .eyebrow, .stat__label {
  color: var(--muted); font-size: .75rem; letter-spacing: .08em; text-transform: uppercase;
}
.brand strong { color: var(--green-dark); font-size: 1.375rem; letter-spacing: .04em; }
.brand__subtitle { letter-spacing: 0; text-transform: none; }

.main-nav, .filters, .filter-actions, .form-actions, .record-header__actions { display: flex; align-items: center; gap: .75rem; }
.main-nav { display: grid; flex: 1 1 42rem; grid-template-columns: repeat(3, minmax(0, 1fr)); }
.main-nav > a:not(.button) { padding: .5rem .25rem; color: var(--green-dark); font-size: .9375rem; font-weight: 700; text-align: center; text-decoration: none; }
.main-nav > a:not(.button):hover { color: var(--green); }
.main-nav > a:not(.button)[aria-current="page"] { color: var(--green); border-bottom: .1875rem solid var(--gold); }

h1, h2, h3, p { margin-top: 0; }
h1, h2, h3 { color: var(--green-dark); }
h1 { margin-bottom: .5rem; font: clamp(1.875rem, 3vw, 2.625rem)/1.15 Georgia, "Times New Roman", serif; }
h2 { margin-bottom: .25rem; font-size: 1.25rem; }
h3 { margin: 1.5rem 0 .5rem; font-size: 1rem; }

.page-heading { align-items: flex-end; margin-bottom: 1.5rem; padding-bottom: 1.25rem; border-bottom: .0625rem solid var(--line); }
.page-heading--compact { align-items: center; }
.page-heading__description, .panel__heading p, .follow-up-form > p, .record-header p { margin-bottom: 0; color: var(--muted); }

.button {
  display: inline-flex; align-items: center; justify-content: center; min-height: 2.75rem; padding: .625rem 1rem;
  color: #fff; background: var(--green); border: .0625rem solid var(--green); border-radius: var(--radius);
  cursor: pointer; font-weight: 700; text-decoration: none;
}
.button:hover { background: var(--green-dark); border-color: var(--green-dark); }
.button--small { min-height: 2.25rem; padding: .375rem .75rem; font-size: .875rem; }
.button--secondary { color: var(--green); background: var(--surface); border-color: var(--line-strong); }
.button--secondary:hover { color: var(--green-dark); background: var(--green-soft); border-color: var(--green); }
.text-link, .back-link { font-weight: 700; }
.back-link { display: inline-block; margin-bottom: 1rem; }

.stats-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 1rem; margin-bottom: 1.5rem; }
.stat, .panel, .public-notice { background: var(--surface); border: .0625rem solid var(--line); border-radius: var(--radius); }
.stat { display: grid; gap: .125rem; min-height: 8.75rem; padding: 1.25rem; border-top: .25rem solid var(--green); }
.stat strong { color: var(--green-dark); font: 2.125rem/1.1 Georgia, "Times New Roman", serif; }
.stat > span:last-child, .field small, .muted { color: var(--muted); font-size: .8125rem; }
.stat--warning { border-top-color: var(--gold); }
.stat--warning strong { color: var(--warning); }

.panel { margin-bottom: 1.5rem; padding: 1.5rem; box-shadow: var(--shadow); }
.panel--table { padding: 0; overflow: hidden; }
.panel--table .panel__heading { padding: 1.25rem 1.5rem; border-bottom: .0625rem solid var(--line); background: #fbfcfb; }
.panel__heading { align-items: flex-end; }
.count { color: var(--muted); font-size: .875rem; white-space: nowrap; }

.filters { flex-wrap: wrap; align-items: flex-end; }
.field { display: grid; flex: 1 1 12rem; gap: .375rem; }
.field--search { flex-basis: 22rem; }
label { color: var(--green-dark); font-size: .875rem; font-weight: 700; }
input, select, textarea { width: 100%; padding: .625rem .75rem; color: var(--ink); background: #fff; border: .0625rem solid var(--line-strong); border-radius: .25rem; }
textarea { resize: vertical; }
input:focus, select:focus, textarea:focus { border-color: var(--green); }
.select-shell { position: relative; width: 100%; }
.select-shell--pdp .select-shell__control {
  appearance: none;
  padding-right: 2.5rem;
  min-height: 2.75rem;
  border-color: #d7e2db;
  border-radius: .6rem;
  background: linear-gradient(180deg, #ffffff 0%, #f8fbf9 100%);
  box-shadow: 0 1px 0 rgba(255, 255, 255, .8) inset;
}
.select-shell--pdp .select-shell__control:focus {
  border-color: var(--green);
  box-shadow: 0 0 0 3px rgba(31, 77, 58, 0.12);
}
.select-shell__arrow {
  position: absolute;
  top: 50%;
  right: .9rem;
  transform: translateY(-50%);
  color: var(--muted);
  pointer-events: none;
}
.field-error { margin: 0; color: var(--danger); font-size: .8125rem; font-weight: 600; }

select.is-multi-hidden {
  display: none !important;
}
.multi-select-dropdown {
  position: relative;
  width: 100%;
  min-width: 0;
}

.multi-select-toggle {
  width: 100%;
  border: 1px solid var(--line-strong);
  border-radius: .25rem;
  padding: 0.68rem 0.9rem;
  min-height: 42px;
  background: #ffffff;
  color: var(--ink);
  font-size: 0.94rem;
  font-family: inherit;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.6rem;
  cursor: pointer;
  transition:
    border-color .15s ease,
    box-shadow .15s ease,
    background-color .15s ease;
}

.single-select-option {
  width: 100%;
  border: 1px solid var(--line-strong);
  border-radius: .25rem;
  padding: 0.68rem 0.9rem;
  background: #ffffff;
  color: var(--ink);
  font: inherit;
  font-size: 0.94rem;
  text-align: left;
  cursor: pointer;
  transition:
    border-color .15s ease,
    box-shadow .15s ease,
    background-color .15s ease;
}

.multi-select-toggle:hover {
  border-color: #b9cec2;
  background: #fcfdfc;
}

.single-select-option:hover {
  border-color: #b9cec2;
  background: #fcfdfc;
}

.multi-select-toggle:focus-visible {
  outline: none;
  border-color: var(--green);
  box-shadow: 0 0 0 3px rgba(31, 77, 58, 0.14);
  background: #ffffff;
}

.single-select-option:focus-visible {
  outline: none;
  border-color: var(--green);
  box-shadow: 0 0 0 3px rgba(31, 77, 58, 0.14);
  background: #ffffff;
}

.multi-select-value {
  flex: 1 1 auto;
  min-width: 0;
  text-align: left;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  line-height: 1.25;
}

.multi-select-arrow {
  font-size: 0.78rem;
  color: var(--muted);
  transition: transform .15s ease;
}

.multi-select-dropdown.is-open .multi-select-arrow {
  transform: rotate(180deg);
}

.multi-select-panel {
  position: absolute;
  top: calc(100% + 0.28rem);
  left: 0;
  right: 0;
  z-index: 24;
  display: none;
  border: 1px solid #d9e5de;
  border-radius: 12px;
  background: #ffffff;
  box-shadow: 0 12px 28px rgba(15, 23, 42, 0.12);
  overflow: hidden;
}

.multi-select-dropdown.is-open .multi-select-panel {
  display: block;
}

.multi-select-panel-inner {
  display: flex;
  flex-direction: column;
  background: #ffffff;
}

.multi-select-search-wrap {
  padding: 0.6rem 0.65rem 0.45rem;
  border-bottom: 1px solid #edf3ef;
  background: #ffffff;
}

.multi-select-search-input {
  width: 100%;
  min-height: 36px;
  border: 1px solid #d7e2db;
  border-radius: 9px;
  padding: 0.5rem 0.72rem;
  background: #f8fbf9;
  color: var(--ink);
  font: inherit;
  font-size: 0.84rem;
}

.multi-select-search-input:focus {
  outline: none;
  border-color: var(--green);
  box-shadow: 0 0 0 3px rgba(31, 77, 58, 0.12);
  background: #ffffff;
}

.multi-select-search-count {
  flex: 1 1 auto;
  min-width: 0;
  color: var(--muted);
  font-size: 0.74rem;
  line-height: 1.2;
  letter-spacing: 0.02em;
}

.multi-select-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.6rem;
  padding: 0.45rem 0.7rem 0.5rem;
  border-bottom: 1px solid #edf3ef;
  background: #ffffff;
}

.multi-select-actions {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  flex: 0 0 auto;
}

.multi-select-action-link {
  border: none;
  padding: 0;
  background: transparent;
  color: var(--green);
  font: inherit;
  font-size: 0.76rem;
  font-weight: 700;
  line-height: 1.2;
  cursor: pointer;
  text-decoration: none;
}

.multi-select-action-link:hover,
.multi-select-action-link:focus-visible {
  color: var(--green-dark);
  text-decoration: underline;
}

.multi-select-action-link:focus-visible {
  outline: none;
}

.multi-select-options-list {
  max-height: 260px;
  overflow: auto;
  padding: 0.3rem;
}

.multi-select-option {
  display: flex;
  align-items: flex-start;
  gap: 0.72rem;
  padding: 0.5rem 0.55rem;
  border-radius: 9px;
  font-size: 0.86rem;
  cursor: pointer;
  transition: background-color .15s ease;
}

.single-select-option[aria-selected="true"] {
  border-color: #9fb8aa;
  background: #eef6f1;
}

.multi-select-option-text {
  flex: 1 1 auto;
  min-width: 0;
  display: grid;
  gap: 0.14rem;
  white-space: normal;
  overflow-wrap: anywhere;
  line-height: 1.28;
}

.multi-select-option-label {
  min-width: 0;
}

.multi-select-option-subtext {
  color: var(--muted);
  font-size: 0.73rem;
  font-weight: 700;
  line-height: 1.2;
}

.multi-select-option:hover {
  background: #f4f8f5;
}

.multi-select-option:focus-within {
  background: #eef6f1;
}

.multi-select-checkbox {
  accent-color: var(--green);
  width: 0.95rem;
  height: 0.95rem;
  min-height: 0.95rem;
  padding: 0;
  margin-top: 0.12rem;
  flex: 0 0 auto;
}

.multi-select-checkbox:focus-visible {
  outline: 2px solid rgba(31, 77, 58, 0.32);
  outline-offset: 2px;
}

.multi-select-empty {
  padding: 0.8rem 0.7rem;
  font-size: 0.82rem;
  color: var(--muted);
}

.multi-select-dropdown.is-disabled .multi-select-toggle {
  opacity: 0.62;
  background: #f6f8f7;
  cursor: not-allowed;
}


.table-wrap { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; }
th, td { padding: 1rem 1.5rem; text-align: left; border-bottom: .0625rem solid var(--line); vertical-align: top; }
th { color: #45554d; background: #eef2ef; font-size: .75rem; letter-spacing: .06em; text-transform: uppercase; }
tbody tr { transition: background-color .15s ease; }
tbody tr:hover { background: #f7faf8; }
tbody tr:last-child td { border-bottom: 0; }
.record-link { display: grid; gap: .125rem; color: inherit; text-decoration: none; }
.record-link:hover strong { color: var(--green); text-decoration: underline; }
td small { display: block; margin-top: .375rem; color: var(--muted); }
.table-action { text-align: right; }

.badge { display: inline-flex; align-items: center; min-height: 1.75rem; padding: .25rem .5rem; border-radius: 999rem; font-size: .75rem; font-weight: 700; white-space: nowrap; }
.badge--stage { color: var(--green); background: var(--green-soft); }
.badge--alta { color: var(--danger); background: var(--danger-soft); }
.badge--media { color: var(--warning); background: var(--warning-soft); }
.badge--baja { color: #426453; background: #edf4ef; }
.date--overdue { color: var(--danger); font-weight: 700; }

.empty-state { display: grid; justify-items: center; gap: .75rem; padding: 3rem 1.5rem; text-align: center; }
.empty-state h1, .empty-state h2, .empty-state p { margin-bottom: 0; }
.public-notice { padding: 1rem 1.25rem; color: #5b491e; background: var(--gold-soft); border-color: #dfcb96; font-size: .875rem; }

.record-form { width: min(100%, 72rem); }
.record-form--pdp { width: 100%; }
.pdp-table { min-width: 61rem; table-layout: fixed; }
.pdp-table th, .pdp-table td { padding: .625rem; }
.pdp-table th { color: var(--ink); background: #d9dfdb; letter-spacing: .02em; text-align: center; text-transform: none; }
.pdp-table th:first-child { width: 4%; }
.pdp-table th:nth-child(2) { width: 40%; }
.pdp-table th:nth-child(3) { width: 10%; }
.pdp-table textarea, .pdp-table input { min-width: 0; padding: .5rem; }
.pdp-table textarea { display: block; min-height: 5.25rem; }
.pdp-shared-content { vertical-align: top; }
.pdp-table small { display: block; margin-top: .375rem; color: var(--muted); font-size: .75rem; }
.pdp-document-title { margin-bottom: 1rem; text-align: center; }
.pdp-document-title p { margin: 0; font-size: 1.125rem; font-weight: 700; }
.pdp-editor-tools {
  position: relative;
  margin: 0;
  border: .0625rem solid #d7e2db;
  border-radius: .6rem;
  background: linear-gradient(180deg, #ffffff 0%, #f8fbf9 100%);
  overflow: clip;
}
.pdp-editor-tools summary {
  list-style: none;
}
.pdp-editor-tools summary::-webkit-details-marker {
  display: none;
}
.pdp-editor-tools__summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: .8rem 1rem;
  cursor: pointer;
}
.pdp-editor-tools__summary strong {
  display: block;
  color: var(--green-dark);
  font-size: .95rem;
}
.pdp-editor-tools__summary small {
  display: block;
  color: var(--muted);
  font-size: .8rem;
}
.pdp-editor-tools__caret {
  flex: 0 0 auto;
  color: var(--muted);
  transition: transform .15s ease;
}
.pdp-editor-tools[open] .pdp-editor-tools__caret {
  transform: rotate(180deg);
}
.pdp-editor-tools__body {
  display: grid;
  gap: .9rem;
  padding: 0 1rem 1rem;
}
.pdp-editor-tools__grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: .9rem;
}
.pdp-editor-tools__title {
  color: var(--green-dark);
  font-size: .95rem;
}
.pdp-editor-tools__actions { display: flex; flex-wrap: wrap; gap: .6rem; }
.pdp-editor-tools__help { margin: 0; }
.pdp-search-hit {
  border-color: var(--gold) !important;
  box-shadow: 0 0 0 3px rgba(154, 118, 46, 0.16);
}
.pdp-search-float {
  position: fixed;
  right: 1rem;
  bottom: 1rem;
  z-index: 60;
  display: grid;
  justify-items: end;
  gap: .6rem;
  max-width: min(26rem, calc(100vw - 2rem));
  pointer-events: none;
}
.pdp-search-fab,
.pdp-search-panel,
.pdp-tools-fab,
.pdp-holders-panel {
  pointer-events: auto;
}
.pdp-search-fab {
  width: 3rem;
  height: 3rem;
  min-height: 3rem;
  padding: 0;
  border-radius: 999rem;
  box-shadow: var(--shadow);
}
.pdp-tools-fab {
  width: auto;
  min-width: 7.5rem;
  min-height: 3rem;
  padding-inline: 1rem;
  border-radius: 999rem;
  box-shadow: var(--shadow);
  letter-spacing: .02em;
}
.pdp-tools-fab:hover {
  transform: translateY(-1px);
}
.pdp-search-fab span {
  font-size: 1.15rem;
  line-height: 1;
}
.pdp-search-panel {
  width: min(24rem, calc(100vw - 2rem));
  box-shadow: 0 20px 40px rgba(15, 23, 42, 0.18);
}
.pdp-holders-panel {
  position: absolute;
  right: 9rem;
  bottom: 0;
  width: min(56rem, calc(100vw - 2rem));
  max-height: min(36rem, calc(100vh - 8rem));
  box-shadow: 0 20px 40px rgba(15, 23, 42, 0.18);
  overflow: auto;
}
.pdp-holders-panel__grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: .75rem;
}
.pdp-holders-panel__column {
  display: grid;
  gap: .5rem;
}
.pdp-holders-panel__list {
  display: grid;
  gap: .5rem;
  max-height: 18rem;
  overflow: auto;
  padding-right: .1rem;
}
.pdp-holders-panel__row {
  display: grid;
  grid-template-columns: auto minmax(22rem, 3fr) minmax(12rem, 1fr) minmax(10rem, 1fr) auto;
  align-items: start;
  gap: .5rem;
  border: .0625rem solid var(--line);
  border-radius: .5rem;
  background: #fff;
  width: 100%;
  padding: .55rem .65rem;
}
.pdp-offices-panel__row {
  grid-template-columns: auto minmax(0, 1fr) auto;
}
.pdp-holders-panel__checkbox {
  margin-top: .15rem;
  accent-color: var(--green);
}
.pdp-holders-panel__item-text {
  min-width: 0;
  overflow-wrap: anywhere;
  white-space: normal;
  font-size: .9rem;
  line-height: 1.25;
}
.pdp-holders-panel__meta {
  display: grid;
  gap: .35rem;
  min-width: 0;
}
.pdp-holders-panel__edit {
  width: 100%;
  padding: .45rem .55rem;
  border: .0625rem solid var(--line-strong);
  border-radius: .4rem;
  font-size: .86rem;
  min-width: 0;
}
.pdp-holders-panel__edit:focus {
  border-color: var(--green);
  outline: none;
}
.pdp-holders-panel__selected-actions {
  display: flex;
  flex-wrap: wrap;
  gap: .45rem;
  justify-content: flex-end;
}
.pdp-holders-panel__mini {
  min-height: 2rem;
  padding: .25rem .55rem;
  border-radius: .4rem;
}
.pdp-search-panel[hidden] {
  display: none;
}
.pdp-search-panel.is-open {
  display: grid;
}
.pdp-total { margin: 1rem 0 0; font-weight: 700; text-align: right; }
.pdp-total output { display: inline-block; min-width: 4ch; }
.pdp-total-help { margin: .25rem 0 0; color: var(--muted); font-size: .8125rem; text-align: right; }

@media (max-width: 42rem) {
  .pdp-search-float {
    right: .75rem;
    bottom: .75rem;
    left: .75rem;
    max-width: none;
    justify-items: stretch;
  }
  .pdp-search-fab,
  .pdp-search-panel {
    width: 100%;
  }
  .pdp-tools-fab,
  .pdp-holders-panel {
    width: 100%;
  }
  .pdp-holders-panel {
    right: .5rem;
    bottom: 3.75rem;
  }
  .pdp-holders-panel__row {
    grid-template-columns: auto minmax(0, 1fr);
  }
  .pdp-holders-panel__meta,
  .pdp-holders-panel__selected-actions {
    grid-column: 1 / -1;
  }
  .pdp-holders-panel {
    max-height: calc(100vh - 7rem);
  }
}
.form-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1.25rem; }
.field--full { grid-column: 1 / -1; }
.form-actions { margin-top: 1.5rem; }
.record-header { align-items: flex-end; margin-bottom: 1.5rem; padding-bottom: 1.25rem; border-bottom: .0625rem solid var(--line); }
.record-header__actions { flex-wrap: wrap; justify-content: flex-end; }
.detail-grid { display: grid; grid-template-columns: minmax(0, 1.6fr) minmax(20rem, .75fr); gap: 1.5rem; align-items: start; }
.definition-list { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1rem; margin: 0; }
.definition-list div { display: grid; gap: .25rem; }
.definition-list dt { color: var(--muted); font-size: .8125rem; }
.definition-list dd { margin: 0; font-weight: 700; }
.description, .timeline__content p { margin-bottom: 0; white-space: pre-wrap; }
.follow-up-form form { display: grid; gap: 1rem; margin-top: 1rem; }

.timeline { display: grid; margin: 1.5rem 0 0; padding: 0; list-style: none; }
.timeline li { display: grid; grid-template-columns: 1rem minmax(0, 1fr); gap: .75rem; padding-bottom: 1.25rem; }
.timeline li:last-child { padding-bottom: 0; }
.timeline__marker { width: .75rem; height: .75rem; margin-top: .375rem; background: var(--gold); border: .1875rem solid var(--gold-soft); border-radius: 50%; }
.timeline__content { padding-bottom: 1.25rem; border-bottom: .0625rem solid var(--line); }
.timeline li:last-child .timeline__content { padding-bottom: 0; border-bottom: 0; }
.timeline__meta { display: flex; align-items: center; gap: .75rem; margin-bottom: .375rem; }

.flash-stack { display: grid; gap: .75rem; margin-bottom: 1.5rem; }
.flash { padding: .875rem 1rem; border-radius: var(--radius); font-weight: 600; }
.flash--success { color: #245335; background: #e7f4ea; border: .0625rem solid #b9d9c0; }
.flash--error { color: var(--danger); background: var(--danger-soft); border: .0625rem solid #edc5c1; }
.error-state { max-width: 36rem; margin: 4rem auto; }
.visually-hidden { position: absolute; width: .0625rem; height: .0625rem; padding: 0; margin: -.0625rem; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }

.cuadro-pdp__actions { margin: 0 0 1rem; }
.cuadro-pdp__print-note { margin: 0; }
.cuadro-report { margin-bottom: 2.5rem; padding: 1.5rem; background: var(--surface); border: .0625rem solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); }
.cuadro-report__header { margin-bottom: 1.5rem; text-align: center; }
.cuadro-report__header .eyebrow { margin-bottom: .25rem; }
.cuadro-report__header h2 { margin-bottom: 0; }
.cuadro-period { margin-top: 2rem; }
.cuadro-period > h3 { margin-bottom: 1rem; }
.cuadro-period .cuadro-section h4 { margin-top: 0; }
.cuadro-section + .cuadro-section { margin-top: 2rem; }
.cuadro-section h3 { margin-top: 0; }
.cuadro-section__description { margin: -.25rem 0 1rem; color: var(--muted); font-size: .875rem; }
.cuadro-table th, .cuadro-table td { padding: .5rem .625rem; font-size: .8125rem; }
.cuadro-table th { color: var(--ink); background: #edf1ee; letter-spacing: .02em; text-transform: none; }
.cuadro-table tbody th { background: var(--surface); font-weight: 700; }
.cuadro-table .amount { text-align: right; white-space: nowrap; }
.cuadro-table__subtotal th, .cuadro-table__subtotal td, .cuadro-table tfoot th, .cuadro-table tfoot td { background: #f5f7f5; font-weight: 700; }

.administrativas-form .panel__heading { margin-bottom: 1rem; }
.administrativas-table { min-width: 118rem; table-layout: fixed; }
.administrativas-table th, .administrativas-table td { padding: .5rem; font-size: .75rem; vertical-align: middle; }
.administrativas-table th { background: var(--green-soft); }
.administrativas-table input { min-width: 5.5rem; padding: .45rem; }
.administrativas-table th:nth-child(-n+4), .administrativas-table td:nth-child(-n+4) { width: 13rem; }
.administrativas-table output { display: block; min-width: 3rem; font-weight: 700; text-align: center; }
.administrativas-table tfoot th, .administrativas-table tfoot td { background: #f5f7f5; font-weight: 700; }
.administrativas-preview .panel__heading { margin-bottom: 1rem; }
.administrativas-preview-wrap { max-height: 72vh; border: .0625rem solid var(--line-strong); }
.administrativas-preview-wrap:focus-visible { outline: .1875rem solid #b78a2b; outline-offset: .125rem; }
.administrativas-preview-table { min-width: 112rem; table-layout: fixed; background: var(--surface); }
.administrativas-preview-table th, .administrativas-preview-table td { padding: .4rem .5rem; border: .0625rem solid #89948d; font-size: .7rem; vertical-align: middle; }
.administrativas-preview-table thead th { color: var(--ink); background: #edf1ee; overflow-wrap: anywhere; text-align: center; }
.administrativas-preview-table th:first-child { width: 4rem; text-align: center; }
.administrativas-preview-table th:nth-child(2) { width: 19rem; }
.administrativas-preview-table th:nth-child(n+3):nth-child(-n+6) { width: 9rem; }
.administrativas-preview-section th { padding: .3rem .5rem; background: #c7ccc9; text-align: left; }
.administrativas-preview-entity-start > * { border-top-width: .125rem; }
.administrativas-preview-name { font-weight: 600; }
.administrativas-preview-number { text-align: center; }
.administrativas-preview-table tfoot th, .administrativas-preview-table tfoot td { background: #dfe4e1; font-weight: 700; }

@media print {
  .site-header, .site-footer, .flash-stack, .page-heading, .panel, .cuadro-pdp__actions { display: none; }
  body { min-width: 0; background: #fff; font-size: .75rem; }
  .app-shell { display: block; min-height: 0; }
  .page-shell { padding: 0; }
  .cuadro-report { break-before: page; margin: 0; padding: 0; border: 0; border-radius: 0; box-shadow: none; }
  .cuadro-report:first-of-type { break-before: auto; }
  .cuadro-table th, .cuadro-table td { padding: .25rem .375rem; font-size: .6875rem; }
}

@media (max-width: 54rem) {
  .stats-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .detail-grid { grid-template-columns: 1fr; }
}

@media (max-width: 60rem) {
  .site-header__inner { align-items: flex-start; flex-direction: column; gap: 1rem; }
  .main-nav { width: 100%; }
}

@media (max-width: 42rem) {
  .site-header__inner, .page-heading, .record-header, .site-footer { align-items: flex-start; flex-direction: column; }
  .site-header__inner, .page-heading, .record-header { gap: 1rem; }
  .brand__institution, .brand__subtitle { display: none; }
  .record-header__actions { justify-content: flex-start; }
  .filters, .filter-actions, .form-actions { align-items: stretch; flex-direction: column; width: 100%; }
  .filters .field { flex-basis: auto; }
  .form-grid, .definition-list { grid-template-columns: 1fr; }
  .field--full { grid-column: auto; }
  .panel { padding: 1rem; }
  .panel--table .panel__heading { align-items: flex-start; padding: 1rem; }
  th, td { padding: .875rem 1rem; }
}

@media (max-width: 30rem) {
  .stats-grid { grid-template-columns: 1fr; }
  .brand__logo { width: 3rem; height: 3rem; }
  .main-nav > a:not(.button) { font-size: .875rem; }
}
