* { box-sizing: border-box; }
html, body {
  margin: 0;
  padding: 0;
  min-height: 100%;
}
body {
  min-height: 100vh;
  font-family: var(--font-family);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
.page {
  width: 100%;
  min-height: 100vh;
  padding: 0 0 64px;
}
.page-wrapper { background: transparent; }
.shell-navbar {
  position: sticky;
  top: 0;
  z-index: 100;
  backdrop-filter: blur(20px) saturate(180%);
  -webkit-backdrop-filter: blur(20px) saturate(180%);
  width: 100%;
  min-height: 56px;
}
.page-body {
  padding: 1.5rem 0 0;
}
.shell-row { row-gap: 1.25rem; }
.shell-toolbar .card-body {
  padding: 1.1rem 1.35rem;
}
.brand-stack {
  display: grid;
  gap: 2px;
}
.brand-kicker {
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: .12em;
}
.brand-title {
  font-size: 17px;
  font-weight: 700;
  letter-spacing: -0.01em;
}
h1, h2, h3, p {
  margin: 0;
}
.toolbar-form {
  display: grid;
  grid-template-columns: minmax(260px, 340px) minmax(160px, 180px) minmax(260px, 1fr) auto;
  gap: 14px;
  align-items: end;
}
.toolbar-group {
  min-width: 0;
}
.toolbar-period {
  min-width: 0;
}
.toolbar-actions {
  display: flex;
  align-items: end;
  flex-wrap: wrap;
  min-width: 0;
  gap: 12px;
}
.period-nav {
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 10px;
  align-items: end;
  width: 100%;
}
.period-input-wrap {
  min-width: 0;
  position: relative;
}
.period-picker-input {
  position: absolute;
  inset: 0;
  opacity: 0;
  pointer-events: none;
}
.period-display-input[readonly] {
  cursor: pointer;
}
.nav-arrow {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border-radius: var(--radius-md);
  text-decoration: none;
  font-size: 18px;
  line-height: 1;
  font-weight: 600;
  transition: transform .15s ease, background-color .15s ease, opacity .15s ease;
}
.nav-arrow:active {
  transform: scale(0.92);
}
.form-label {
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: .07em;
  font-weight: 600;
}
.form-control,
.form-select {
  min-height: 44px;
  transition: border-color .15s ease, box-shadow .15s ease;
}
.btn {
  min-height: 44px;
  transition: transform .12s ease, filter .12s ease, opacity .12s ease;
}
.btn:active {
  transform: scale(0.97);
}
.store-grid { row-gap: 1.25rem; }
.view-toggle-row {
  margin: -.35rem 0 .15rem;
}
.view-toggle {
  display: inline-flex;
  align-items: center;
  gap: 2px;
  padding: 3px;
  border-radius: 999px;
  background: var(--control-bg);
  border: 1px solid var(--control-border);
  width: fit-content;
}
.view-toggle-input {
  position: absolute;
  width: 0;
  height: 0;
  opacity: 0;
  pointer-events: none;
}
.view-toggle-option {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  padding: 7px 15px;
  min-width: 104px;
  border-radius: 999px;
  font-size: 13px;
  line-height: 1;
  font-weight: 600;
  cursor: pointer;
  color: var(--text-secondary);
  transition: background-color .15s ease, color .15s ease;
  user-select: none;
}
.view-toggle-input:checked + .view-toggle-option {
  background: var(--accent);
  color: #ffffff;
}
.view-toggle-input:focus-visible + .view-toggle-option {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}
.view-toggle-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: none;
  width: 14px;
  height: 14px;
  position: relative;
}
.view-toggle-icon-grid {
  width: 14px;
  height: 14px;
  margin-right: 0;
  background:
    linear-gradient(currentColor 0 0) left top / 5px 5px no-repeat,
    linear-gradient(currentColor 0 0) right top / 5px 5px no-repeat,
    linear-gradient(currentColor 0 0) left bottom / 5px 5px no-repeat,
    linear-gradient(currentColor 0 0) right bottom / 5px 5px no-repeat;
}
.view-toggle-icon-list {
  width: 14px;
  height: 2px;
  background: currentColor;
  border-radius: 1px;
  box-shadow:
    0 -5px 0 currentColor,
    0 5px 0 currentColor;
}
.home-page .page-wrapper,
.home-page .page-body,
.home-page .container-xl {
  min-height: 100vh;
}
.login-page .page-wrapper,
.login-page .page-body,
.login-page .container-xl {
  min-height: 100vh;
}
.home-page .page-body {
  display: flex;
  align-items: center;
}
.login-page .page-body {
  display: flex;
  align-items: center;
}
.home-page .container-xl {
  display: flex;
  align-items: center;
  justify-content: center;
}
.login-page .container-xl {
  display: flex;
  align-items: center;
  justify-content: center;
}
.home-selector {
  width: min(100%, 980px);
  padding: 1.5rem 0;
}
@media (min-width: 992px) {
  .home-page {
    overflow: hidden;
  }
  .home-page .page-wrapper {
    min-height: 100vh;
    overflow: hidden;
  }
  .home-page .page-body {
    min-height: calc(100vh - 72px);
    overflow: hidden;
  }
  .home-page .container-xl {
    min-height: calc(100vh - 72px);
    padding-top: 0;
    padding-bottom: 0;
  }
  .home-selector {
    padding: 0;
  }
}
.login-shell {
  width: min(100%, 440px);
}
.login-card {
  padding: .35rem;
}
.login-intro {
  margin-bottom: .9rem;
}
.login-fields {
  display: grid;
  gap: 14px;
}
.login-actions {
  padding: 0 1rem 1rem;
}
.home-module-list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(130px, 1fr));
  justify-items: center;
  gap: 1.55rem 1.25rem;
}
.home-module-card {
  width: 100%;
  max-width: 140px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: .7rem;
  padding: 0;
  text-decoration: none;
  border: 0;
  background: transparent;
  box-shadow: none;
  text-align: center;
}
.home-module-card-active {
  color: inherit;
  transition: transform .18s ease, opacity .18s ease;
}
.home-module-card-active:hover {
  transform: translateY(-4px);
}
.home-module-card-active:hover .home-module-icon {
  box-shadow: 0 18px 28px -20px rgba(15, 23, 42, 0.42);
}
.home-module-card-locked {
  opacity: .78;
  cursor: default;
}
.home-module-icon {
  width: 68px;
  height: 68px;
  border-radius: 12px;
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: none;
  background: rgba(255, 255, 255, 0.88);
  border: 1px solid rgba(60, 60, 67, 0.10);
  box-shadow: 0 10px 20px -16px rgba(15, 23, 42, 0.28);
}
.home-module-icon::before,
.home-module-icon::after {
  content: "";
  position: absolute;
}
.module-icon-losses::before {
  width: 26px;
  height: 26px;
  border-radius: 9px;
  background: linear-gradient(135deg, #36b0ff 0%, #1d6fff 55%, #ff9f7a 100%);
  transform: rotate(-10deg);
}
.module-icon-losses::after {
  width: 14px;
  height: 24px;
  border-radius: 6px;
  background: rgba(11, 47, 118, 0.28);
  transform: translateX(-8px) rotate(10deg);
}
.module-icon-audits::before {
  width: 28px;
  height: 18px;
  border-radius: 10px 10px 8px 8px;
  background: linear-gradient(135deg, #b7beca, #8d97a8);
  box-shadow: 0 -10px 0 -4px rgba(141, 151, 168, 0.9);
}
.module-icon-costs::before {
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: linear-gradient(135deg, #d2d8e1, #9fa9ba);
}
.module-icon-costs::after {
  width: 18px;
  height: 6px;
  border-radius: 999px;
  background: rgba(121, 130, 144, 0.95);
  transform: rotate(-45deg);
}
.module-icon-supply::before {
  width: 28px;
  height: 20px;
  border-radius: 7px;
  background: linear-gradient(180deg, #c3cad5 0 35%, #919cac 35% 65%, #d7dde6 65% 100%);
}
.module-icon-purchases::before {
  width: 24px;
  height: 24px;
  border-radius: 8px;
  background: linear-gradient(135deg, #d6dde6, #9aa5b6);
  clip-path: polygon(20% 12%, 78% 12%, 92% 30%, 92% 88%, 20% 88%, 8% 70%, 8% 26%);
}
.home-module-lock {
  position: absolute;
  right: -6px;
  top: -6px;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  background: rgba(60, 60, 67, 0.82);
  color: #ffffff;
  box-shadow: 0 8px 16px -12px rgba(15, 23, 42, 0.5);
}
.home-module-title {
  font-size: .98rem;
  line-height: 1.2;
  font-weight: 600;
  color: var(--text-primary);
  text-wrap: balance;
}
.ingredient-dashboard-section {
  display: grid;
  gap: 1rem;
}
.ingredient-dashboard-section + .ingredient-dashboard-section {
  margin-top: .5rem;
}
.ingredient-section-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}
.ingredient-section-title {
  font-size: 1.35rem;
  font-weight: 700;
  letter-spacing: -0.01em;
}
.store-grid > [class*="col-"] {
  align-self: flex-start;
}
.store-card {
  transition: transform .18s ease, box-shadow .18s ease;
}
.store-card .card-header {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 4px;
}
.store-heading {
  min-width: 0;
  width: 100%;
}
.store-card .card-title {
  font-size: 1.15rem;
  margin: 0;
  line-height: 1.2;
}
.store-date {
  margin-top: 0;
  margin-left: 0;
  text-align: left;
  white-space: normal;
  flex: 0 0 auto;
  max-width: 100%;
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: .04em;
  line-height: 1.2;
}
.store-date-line {
  display: block;
}
.loss-spotlight {
  display: grid;
  gap: .8rem;
  padding: 1rem 1.1rem;
  border-radius: var(--radius-md);
  margin-bottom: 1rem;
}
.loss-breakdown {
  display: grid;
  gap: .3rem;
}
.loss-breakdown-row {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: .75rem;
  font-size: .92rem;
  font-weight: 500;
  line-height: 1.35;
}
.loss-breakdown-row span:last-child {
  text-align: right;
  font-variant-numeric: tabular-nums;
}
.loss-breakdown-row-main {
  font-weight: 700;
}
.loss-breakdown-row-strong {
  font-weight: 700;
}
.loss-breakdown-row-divider {
  padding-top: .2rem;
  border-top: 1px solid rgba(15, 23, 42, 0.08);
}
.pending-value {
  font-style: normal;
  font-variant-numeric: tabular-nums;
}
.loss-alerts {
  display: flex;
  align-items: flex-start;
  gap: .55rem;
  margin-top: .8rem;
  padding: .6rem .75rem;
  border-radius: var(--radius-sm);
  font-size: .82rem;
  line-height: 1.4;
}
.loss-alerts-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: none;
  width: 18px;
  height: 18px;
  border-radius: 999px;
  font-size: .72rem;
  font-weight: 700;
  line-height: 1;
}
.loss-alerts-list {
  margin: 0;
  padding-left: 1rem;
}
.loss-alerts-list li + li {
  margin-top: .25rem;
}
.metrics-table {
  margin: 0;
}
.metrics-table td {
  padding-top: .8rem;
  padding-bottom: .8rem;
  padding-left: 1.35rem;
  padding-right: .8rem;
  font-size: .95rem;
}
.metrics-table td:last-child {
  font-weight: 600;
  font-variant-numeric: tabular-nums;
}
.metrics-table .consumption-row td {
  padding: 0 !important;
  border-bottom: 0;
}
.metrics-table .sales-row td {
  padding: 0 !important;
}
.sales-panel,
.consumption-panel {
  width: 100%;
  display: block;
  border-radius: inherit;
  overflow: hidden;
}
.sales-panel summary,
.consumption-panel summary {
  list-style: none;
}
.sales-panel summary::-webkit-details-marker,
.consumption-panel summary::-webkit-details-marker {
  display: none;
}
.sales-summary,
.consumption-summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: .85rem 1.35rem;
  cursor: pointer;
  font-size: .95rem;
  position: relative;
}
.sales-label,
.consumption-label {
  display: inline-flex;
  align-items: center;
  gap: .55rem;
}
.sales-label::after,
.consumption-label::after {
  content: "";
  width: 8px;
  height: 8px;
  border-right: 2px solid currentColor;
  border-bottom: 2px solid currentColor;
  opacity: .38;
  transform: rotate(-45deg);
  transition: transform .2s ease;
  flex: none;
}
.sales-panel[open] .sales-label::after,
.consumption-panel[open] .consumption-label::after {
  transform: rotate(45deg);
}
.sales-summary .pending-value,
.consumption-summary .pending-value {
  margin-left: auto;
  margin-right: .35rem;
  text-align: right;
}
.sales-block,
.odoo-block {
  padding: .85rem 1.35rem .7rem;
  border-radius: 0 0 var(--radius-md) var(--radius-md);
}
.consumption-details {
  border-radius: 0 0 var(--radius-md) var(--radius-md);
}
.sales-item + .sales-item {
  margin-top: .8rem;
  padding-top: .8rem;
  border-top: 1px solid rgba(15, 23, 42, 0.08);
}
.sales-item-total .sales-item-main {
  font-weight: 700;
}
.sales-item-adjustment .sales-item-main {
  color: var(--tblr-secondary, #667085);
}
.sales-item-main,
.sales-meta-line {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: .75rem;
}
.sales-item-main {
  font-size: .84rem;
  font-weight: 600;
  line-height: 1.35;
}
.sales-meta-line {
  margin-top: .22rem;
  font-size: .74rem;
  line-height: 1.3;
}
.sales-modifiers {
  margin: .4rem 0 0;
  padding-left: 1rem;
  font-size: .74rem;
  line-height: 1.35;
}
.consumption-main-line {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: .75rem;
  font-size: .92rem;
  font-weight: 600;
  line-height: 1.3;
}
.consumption-main-line .pending-value {
  font-style: normal;
}
.consumption-divider {
  width: calc(100% - 0.5rem);
  height: 1px;
  margin: .5rem auto;
}
.odoo-block-line {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: .6rem;
}
.odoo-block-sub {
  font-size: .74rem;
  line-height: 1.3;
  padding-top: .12rem;
  padding-bottom: .12rem;
}
.sales-modifiers li + li {
  margin-top: .1rem;
}
.footer-note {
  margin-top: 22px;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  font-size: 13px;
}
.footer-sep {
  opacity: 0.5;
}
.error-panel pre {
  overflow-x: auto;
  white-space: pre-wrap;
}

/* Navbar hamburger menu */
.shell-navbar .container-xl {
  display: flex;
  align-items: center;
  gap: 12px;
}
.brand-home-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  flex: none;
}
.navbar-brand {
  display: inline-flex;
  align-items: center;
  text-decoration: none;
}
.brand-home-arrow {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 30px;
  height: 30px;
  border-radius: 999px;
  font-size: 16px;
  font-weight: 700;
  color: var(--accent);
  background: rgba(10, 132, 255, 0.10);
  flex: none;
  transition: transform .15s ease, background-color .15s ease;
}
.brand-home-link:hover .brand-home-arrow {
  transform: translateX(-2px);
  background: rgba(10, 132, 255, 0.16);
}
.nav-menu-toggle {
  position: absolute;
  width: 0;
  height: 0;
  opacity: 0;
  pointer-events: none;
}
.nav-menu-button {
  display: inline-flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 4px;
  width: 40px;
  height: 40px;
  border-radius: var(--radius-sm);
  cursor: pointer;
  margin-left: auto;
  flex: none;
}
.nav-menu-button span {
  display: block;
  width: 18px;
  height: 2px;
  border-radius: 2px;
  background: currentColor;
}
.nav-menu-backdrop {
  position: fixed;
  inset: 0;
  opacity: 0;
  pointer-events: none;
  transition: opacity .25s ease;
  z-index: 199;
}
.nav-menu-panel {
  position: fixed;
  top: 0;
  right: 0;
  height: 100%;
  width: min(320px, 86vw);
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding: 1.25rem 1.1rem;
  transform: translateX(100%);
  transition: transform .28s cubic-bezier(.32, .72, 0, 1);
  z-index: 200;
  overflow-y: auto;
}
.nav-menu-toggle:checked ~ .nav-menu-backdrop {
  opacity: 1;
  pointer-events: auto;
}
.nav-menu-toggle:checked ~ .nav-menu-panel {
  transform: translateX(0);
}
.nav-menu-panel-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: .5rem;
}
.nav-menu-panel-title {
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .08em;
}
.nav-menu-user {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: .42rem;
  padding: .35rem 0 1rem;
}
.nav-menu-user-avatar {
  width: 56px;
  height: 56px;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: rgba(255, 255, 255, 0.94);
  color: rgba(107, 114, 128, 0.96);
  border: 1px solid rgba(148, 163, 184, 0.22);
  box-shadow: 0 12px 24px -20px rgba(15, 23, 42, 0.28);
}
.nav-menu-user-avatar svg {
  width: 24px;
  height: 24px;
}
.nav-menu-user-name {
  font-size: .98rem;
  font-weight: 700;
  text-align: center;
}
.nav-menu-user-logout {
  font-size: .9rem;
  font-weight: 700;
  color: #ef4444;
  text-decoration: none;
}
.nav-menu-user-logout:hover {
  color: #dc2626;
}
.nav-menu-close {
  font-size: 22px;
  line-height: 1;
  cursor: pointer;
  width: 32px;
  height: 32px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  flex: none;
}
.nav-menu-link {
  display: block;
  padding: .85rem .9rem;
  border-radius: var(--radius-sm);
  font-weight: 600;
  text-decoration: none;
  font-size: .95rem;
}

/* Editar ingredientes */
.settings-intro {
  margin-bottom: .25rem;
}
.settings-title {
  font-size: 1.6rem;
  font-weight: 700;
  letter-spacing: -0.01em;
}
.settings-subtitle {
  margin-top: .4rem;
  font-size: .92rem;
  max-width: 640px;
  line-height: 1.5;
}
.settings-card {
  padding: 1.1rem 1.25rem 1.35rem;
}
.settings-table {
  margin: 0;
}
.settings-table th {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: .06em;
  font-weight: 700;
  text-align: left;
  padding: 0 .6rem .6rem 0;
}
.settings-table td {
  padding: .75rem .85rem .75rem 0;
  vertical-align: middle;
}
.settings-table input.form-control {
  min-height: 40px;
}
.settings-table th:last-child,
.settings-table td:last-child {
  min-width: 170px;
}
.settings-table-wrap {
  padding: .15rem 1rem 1rem;
}
.sync-ingredient-list {
  min-height: auto;
  gap: 10px;
}
.sync-summary-card {
  min-height: 100%;
  align-content: start;
}
.sync-selected-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.btn-download {
  min-width: 132px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--accent);
  background: rgba(255, 255, 255, 0.72);
  color: var(--accent);
  font-weight: 600;
}
.btn-download:hover {
  background: var(--accent-tint);
  color: var(--accent);
}
.waste-period-display-input[readonly] {
  cursor: pointer;
}
.ingredient-name {
  font-weight: 600;
}
.ingredient-target-unit {
  font-variant-numeric: tabular-nums;
}

/* Guia y mapeo */
.guide-intro {
  display: grid;
  gap: .45rem;
}
.guide-card .card-header {
  align-items: center;
}
.guide-card .card-title {
  font-size: 1.05rem;
}
.guide-card .card-body {
  display: grid;
  gap: 1rem;
}
.guide-block {
  display: grid;
  gap: .3rem;
}
.guide-block h3 {
  font-size: .95rem;
  margin: 0;
}
.guide-block p {
  font-size: .92rem;
  line-height: 1.5;
}
.guide-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 14px;
}
.guide-rule-card {
  border: 1px solid rgba(15, 23, 42, 0.08);
  border-radius: 18px;
  padding: 14px 16px;
  background: rgba(255, 255, 255, 0.55);
}
.guide-rule-card h3 {
  margin: 0 0 .35rem;
  font-size: .95rem;
}
.guide-rule-card p {
  margin: 0;
  font-size: .9rem;
  line-height: 1.45;
}
.guide-table {
  margin: 0;
}
.guide-table th,
.guide-table td {
  vertical-align: top;
  font-size: .92rem;
}
.guide-status {
  display: inline-flex;
  align-items: center;
  padding: .2rem .55rem;
  border-radius: 999px;
  font-size: .75rem;
  font-weight: 700;
  letter-spacing: .02em;
}
.guide-status-ok {
  background: rgba(48, 209, 88, 0.12);
  color: #1f8f4d;
}
.guide-status-pending {
  background: rgba(255, 159, 10, 0.12);
  color: #b36a00;
}
.settings-actions {
  margin-top: 1rem;
  display: flex;
  justify-content: flex-end;
}
.settings-banner {
  margin-bottom: 1rem;
  padding: .75rem 1rem;
  border-radius: var(--radius-sm);
  font-size: .9rem;
  font-weight: 600;
}
.dashboard-banner {
  margin-bottom: 0;
}

/* Ver graficos */
.graph-filters {
  display: grid;
  grid-template-columns: minmax(150px, 170px) minmax(150px, 170px) minmax(240px, 1fr) auto;
  gap: 14px;
  align-items: end;
}
.ingredient-check-list {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  min-height: 44px;
  align-items: center;
}
.ingredient-check {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 12px;
  border-radius: 999px;
  overflow: hidden;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  user-select: none;
}
.export-modal[hidden] {
  display: none;
}
.export-modal {
  position: fixed;
  inset: 0;
  z-index: 300;
}
.export-modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(15, 23, 42, 0.32);
  backdrop-filter: blur(4px);
}
.export-modal-dialog {
  position: relative;
  width: min(560px, calc(100vw - 2rem));
  margin: 10vh auto 0;
  padding: 1.15rem 1.2rem 1.2rem;
  border-radius: calc(var(--radius-lg, 24px) - 4px);
}
.export-modal-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 1rem;
}
.export-modal-title {
  font-size: 1.1rem;
  font-weight: 700;
}
.export-modal-subtitle {
  margin-top: .35rem;
  font-size: .9rem;
  line-height: 1.45;
}
.export-modal-close {
  min-width: 40px;
  min-height: 40px;
  font-size: 20px;
  padding: 0;
  border: 0;
  background: transparent;
  box-shadow: none;
  color: var(--text-secondary);
  border-radius: 999px;
}
.export-modal-close:hover {
  background: var(--control-bg);
  color: var(--text-primary);
}
.export-modal-close:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}
.export-modal-form {
  display: grid;
  gap: 1rem;
}
.export-ingredient-list {
  align-items: flex-start;
}
.export-ingredient-check {
  min-height: 44px;
}
.export-modal-actions {
  display: flex;
  justify-content: flex-end;
  gap: .75rem;
}
body.modal-open {
  overflow: hidden;
}
.graph-range-note {
  margin: .7rem 0 0;
  font-size: 12px;
}
.graph-card canvas {
  max-width: 100%;
}
.graph-empty {
  padding: 2rem;
  text-align: center;
}

/* Vista de lista */
body:has(#view-list:checked) .store-grid > [class*="col-"] {
  flex: 0 0 100%;
  max-width: 100%;
}
body:has(#view-list:checked) .store-card {
  display: flex;
  flex-direction: row;
  align-items: stretch;
  flex-wrap: wrap;
}
body:has(#view-list:checked) .store-card .card-header {
  flex: 0 0 190px;
  padding: 1rem 1.1rem;
  justify-content: center;
  border-right: 1px solid var(--separator);
}
body:has(#view-list:checked) .store-card .card-body {
  flex: 1 1 320px;
  display: flex;
  flex-direction: column;
  align-items: stretch;
  justify-content: center;
  gap: .6rem;
  padding: .75rem 1.1rem;
  border-right: 1px solid var(--separator);
}
body:has(#view-list:checked) .loss-spotlight {
  flex-direction: row;
  align-items: center;
  flex-wrap: wrap;
  gap: 1.4rem;
  padding: 0;
  margin-bottom: 0;
  background: none;
  border: 0;
}
body:has(#view-list:checked) .loss-breakdown {
  display: flex;
  flex-direction: row;
  flex-wrap: wrap;
  gap: 1.4rem;
}
body:has(#view-list:checked) .loss-breakdown-row {
  flex-direction: column;
  align-items: flex-start;
  gap: .1rem;
}
body:has(#view-list:checked) .loss-breakdown-row span:first-child {
  font-size: .66rem;
  text-transform: uppercase;
  letter-spacing: .05em;
  font-weight: 700;
  opacity: .6;
}
body:has(#view-list:checked) .loss-breakdown-row span:last-child {
  text-align: left;
  font-size: .95rem;
}
body:has(#view-list:checked) .loss-breakdown-row-divider {
  border-top: 0;
  padding-top: 0;
}
body:has(#view-list:checked) .loss-alerts {
  flex: 0 0 auto;
  margin-top: 0;
  max-width: 100%;
}
body:has(#view-list:checked) .store-card .table-responsive {
  flex: 0 0 340px;
  padding: .35rem 1.1rem;
}
body:has(#view-list:checked) .metrics-table td {
  padding-top: .55rem;
  padding-bottom: .55rem;
}

@media (max-width: 980px) {
  .toolbar-form,
  .graph-filters {
    grid-template-columns: 1fr 1fr;
  }
  .toolbar-period,
  .toolbar-ingredients {
    grid-column: 1 / -1;
  }
  .toolbar-actions {
    grid-column: 1 / -1;
  }
}
@media (max-width: 760px) {
  .toolbar-form,
  .graph-filters {
    grid-template-columns: 1fr;
  }
  .home-page .page-body {
    display: block;
  }
  .home-page .container-xl {
    display: block;
  }
  .home-selector {
    width: 100%;
    padding: 1.15rem 0 1.5rem;
  }
  .home-module-list {
    grid-template-columns: 1fr;
    gap: .95rem;
    justify-items: stretch;
  }
  .home-module-card {
    max-width: none;
    display: grid;
    grid-template-columns: 54px minmax(0, 1fr);
    align-items: center;
    justify-items: start;
    gap: .85rem;
    padding: .9rem 1rem;
    border-radius: 18px;
    background: rgba(255, 255, 255, 0.35);
    border: 1px solid var(--card-border);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.5);
    text-align: left;
  }
  .home-module-icon {
    width: 54px;
    height: 54px;
    border-radius: 14px;
  }
  .home-module-title {
    font-size: 1rem;
  }
  .toolbar-actions {
    flex-direction: column;
    align-items: stretch;
  }
  .toolbar-actions .btn {
    width: 100%;
  }
  .store-card .card-header {
    align-items: flex-start;
    flex-direction: row;
    flex-wrap: wrap;
  }
  .store-date {
    width: 100%;
    text-align: left;
  }
  body:has(#view-list:checked) .store-card {
    flex-direction: column;
  }
  body:has(#view-list:checked) .store-card .card-header,
  body:has(#view-list:checked) .store-card .card-body,
  body:has(#view-list:checked) .store-card .table-responsive {
    flex: 1 1 auto;
    width: 100%;
    border-right: 0;
    border-bottom: 1px solid var(--separator);
  }
  body:has(#view-list:checked) .store-card .table-responsive {
    border-bottom: 0;
  }
}
