
/* =====================================================
   RESERVA FAMILIAR FERNÁNDEZ · VALVERDE
   Identidad visual v0.4
   ===================================================== */

:root {
  --primary: #173d35;
  --primary-dark: #0d2d26;
  --primary-light: #e7efe5;
  --primary-soft: #f0f4ed;
  --gold: #bd9145;
  --gold-light: #f5ecd9;
  --background: #f3f0e6;
  --surface: #fffefa;
  --surface-alt: #f7f6f0;
  --text: #26332f;
  --muted: #78847f;
  --border: #e5e2d8;
  --warning: #bd801d;
  --warning-light: #fff2d9;
  --danger: #b9433e;
  --danger-light: #fae9e6;
  --success: #28815e;
  --success-light: #e6f2e9;
  --shadow: 0 5px 18px rgba(28,48,38,.07);
  --shadow-hover: 0 9px 24px rgba(28,48,38,.12);

  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  background:
    radial-gradient(ellipse at top left, rgba(189,145,69,.07), transparent 40%),
    var(--background);
  color: var(--text);
}

button, input, select, textarea {
  font: inherit;
}

button {
  cursor: pointer;
  transition: background .2s, border-color .2s, transform .2s, box-shadow .2s;
}

button:active {
  transform: translateY(1px);
}

/* CABECERA */

.topbar {
  position: relative;
  overflow: hidden;
  background:
    radial-gradient(ellipse at 85% 15%, rgba(189,145,69,.18), transparent 35%),
    linear-gradient(115deg, var(--primary-dark), var(--primary) 65%, #285648);
  color: #fff;
  padding: 22px max(22px, calc((100% - 1440px) / 2));
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  border-bottom: 4px solid var(--gold);
}

.topbar::after {
  content: "";
  position: absolute;
  width: 300px;
  height: 300px;
  border: 1px solid rgba(255,255,255,.06);
  border-radius: 50%;
  right: 7%;
  top: -220px;
  pointer-events: none;
}

.brand {
  display: flex;
  align-items: center;
  gap: 17px;
  position: relative;
  z-index: 1;
}

.brand-icon {
  width: 66px;
  height: 66px;
  display: grid;
  place-items: center;
  flex-shrink: 0;
  overflow: hidden;
  background: rgba(255,255,255,.07);
  border: 2px solid var(--gold);
  border-radius: 17px 17px 23px 23px;
  box-shadow: inset 0 0 0 4px rgba(255,255,255,.04);
  padding: 4px;
}

.brand-logo {
  display: block;
  width: 100%;
  height: 100%;
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
  border-radius: 9px;
}

.brand-copy h1 {
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(19px, 3vw, 27px);
  letter-spacing: 2px;
  margin: 0;
  font-weight: 800;
}

.brand-copy .family-name {
  color: #f1d49a;
  font-family: Georgia, serif;
  font-size: 18px;
  font-weight: 700;
  letter-spacing: .7px;
  margin: 4px 0 2px;
}

.brand-motto {
  display: block;
  color: #d5e4dc;
  font-family: Georgia, serif;
  font-size: 12px;
  font-style: italic;
  letter-spacing: .4px;
}

.offline-status {
  position: relative;
  z-index: 1;
  font-size: 12px;
  color: #c5e9d0;
  white-space: nowrap;
  background: rgba(255,255,255,.08);
  border: 1px solid rgba(255,255,255,.12);
  padding: 9px 13px;
  border-radius: 30px;
}

/* CONTENEDOR Y BIENVENIDA */

.container {
  max-width: 1440px;
  margin: 28px auto;
  padding: 0 24px;
}

.welcome {
  position: relative;
  overflow: hidden;
  background:
    radial-gradient(circle at 90% 20%, rgba(189,145,69,.22), transparent 28%),
    linear-gradient(115deg, var(--primary-dark), var(--primary));
  color: #fff;
  padding: 28px 34px;
  border-radius: 17px;
  margin-bottom: 20px;
  box-shadow: var(--shadow);
  border: 1px solid rgba(255,255,255,.1);
}

.welcome::after {
  content: "";
  position: absolute;
  width: 230px;
  height: 230px;
  border: 1px solid rgba(255,255,255,.1);
  border-radius: 50%;
  right: 5%;
  top: -100px;
}

.eyebrow {
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 1.6px;
  color: var(--muted);
  margin: 0 0 8px;
}

.welcome .eyebrow {
  color: #e2c58c;
}

.welcome h2 {
  font-family: Georgia, serif;
  font-size: clamp(25px, 4vw, 36px);
  margin: 0 0 9px;
  position: relative;
  z-index: 1;
}

.welcome p:last-child {
  color: #d5e4dc;
  margin-bottom: 0;
  position: relative;
  z-index: 1;
}

.welcome-emblem {
  position: absolute;
  right: 9%;
  top: 50%;
  transform: translateY(-50%);
  color: rgba(242,213,151,.22);
  font-family: Georgia, serif;
  font-size: 105px;
  line-height: 1;
  pointer-events: none;
}

/* ESTADÍSTICAS */

.stats-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
  margin-bottom: 8px;
}

.stat-card {
  position: relative;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  gap: 6px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 13px;
  padding: 18px;
  box-shadow: var(--shadow);
  border-top: 3px solid var(--primary);
}

.stat-card::after {
  content: "";
  position: absolute;
  width: 90px;
  height: 90px;
  border: 1px solid rgba(23,61,53,.06);
  border-radius: 50%;
  right: -32px;
  bottom: -40px;
  pointer-events: none;
}

.stat-card span {
  font-size: 13px;
  color: var(--muted);
  font-weight: 600;
}

.stat-card strong {
  font-family: Georgia, serif;
  font-size: 32px;
  line-height: 1.1;
  color: var(--primary);
}

.stat-card small {
  color: var(--muted);
  font-size: 11px;
}

.stat-icon {
  color: var(--gold);
  font-size: 23px;
  font-weight: 800;
  margin-bottom: 2px;
}

.warning-card {
  border-top-color: var(--warning);
}

.warning-card strong,
.warning-card .stat-icon {
  color: var(--warning);
}

.danger-card {
  border-top-color: var(--danger);
}

.danger-card strong,
.danger-card .stat-icon {
  color: var(--danger);
}

.stats-note {
  font-size: 11px;
  color: var(--muted);
  margin: 0 0 20px 3px;
}

/* DISTRIBUCIÓN PRINCIPAL */

.dashboard-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.8fr) minmax(280px, .82fr);
  gap: 20px;
  align-items: start;
}

.side-column {
  display: flex;
  flex-direction: column;
  gap: 18px;
  min-width: 0;
}

.side-column .panel {
  margin-bottom: 0;
}

/* PANELES */

.panel {
  min-width: 0;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 15px;
  padding: 22px;
  margin-bottom: 20px;
  box-shadow: var(--shadow);
}

.section-heading {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 15px;
  margin-bottom: 18px;
}

.section-heading h2 {
  margin: 0;
  font-family: Georgia, serif;
  font-size: 23px;
  color: var(--primary-dark);
}

.section-heading .eyebrow {
  margin-bottom: 5px;
  color: var(--gold);
}

.section-subtitle {
  margin: 6px 0 0;
  color: var(--muted);
  font-size: 12px;
}

/* BOTONES */

.primary-button,
.secondary-button {
  border-radius: 9px;
  padding: 11px 15px;
  font-weight: 700;
  border: 1px solid transparent;
}

.primary-button {
  background: linear-gradient(135deg, var(--primary), #285849);
  color: #fff;
  box-shadow: 0 3px 8px rgba(23,61,53,.14);
}

.primary-button:hover {
  background: var(--primary-dark);
  box-shadow: 0 5px 12px rgba(23,61,53,.2);
}

.secondary-button {
  color: var(--primary);
  background: var(--primary-light);
  border-color: #d5e2d4;
}

.secondary-button:hover {
  background: #dce9dc;
  border-color: #b8cdbb;
}

.small-button {
  background: #edf2ec;
  border: 1px solid #dfe8dd;
  border-radius: 7px;
  padding: 7px 9px;
  color: var(--primary);
  font-size: 11px;
  font-weight: 650;
}

.small-button:hover {
  background: #dce9dc;
}

.small-button.delete {
  color: var(--danger);
  background: var(--danger-light);
  border-color: #f0d4d0;
}

.small-button.delete:hover {
  background: #f4d9d5;
}

/* FILTROS Y CAMPOS */

.filters {
  display: flex;
  gap: 10px;
  margin-bottom: 16px;
}

.filters input {
  flex: 1.5;
}

.filters select {
  flex: 1;
}

input, select, textarea {
  width: 100%;
  padding: 11px;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: #fff;
  color: var(--text);
  min-width: 0;
}

input:focus, select:focus, textarea:focus {
  outline: 2px solid rgba(189,145,69,.35);
  border-color: var(--gold);
}

/* TABLA DE INVENTARIO */

.inventory-table-wrap {
  width: 100%;
  min-width: 0;
}

.inventory-table-heading {
  display: grid;
  grid-template-columns: minmax(130px, 1.5fr) minmax(100px, 1fr) minmax(95px, .9fr) minmax(100px, .9fr) minmax(105px, auto);
  gap: 10px;
  align-items: center;
  padding: 10px 12px;
  background: var(--primary-dark);
  color: #f4ead4;
  border-radius: 8px 8px 0 0;
  font-size: 9px;
  font-weight: 800;
  letter-spacing: .8px;
}

.inventory-list {
  display: flex;
  flex-direction: column;
}

.product-card {
  display: grid;
  grid-template-columns: minmax(130px, 1.5fr) minmax(100px, 1fr) minmax(95px, .9fr) minmax(100px, .9fr) minmax(105px, auto);
  gap: 10px;
  align-items: center;
  padding: 14px 12px;
  background: #fff;
  border: 1px solid var(--border);
  border-top: 0;
  transition: background .2s;
}

.product-card:last-child {
  border-radius: 0 0 9px 9px;
}

.product-card:hover {
  background: #fbfcf8;
}

.product-main {
  min-width: 0;
}

.product-info h3 {
  font-family: Georgia, serif;
  font-size: 15px;
  color: var(--primary-dark);
  margin: 0 0 4px;
  overflow-wrap: anywhere;
}

.product-meta {
  font-size: 10px;
  color: var(--muted);
  line-height: 1.5;
}

.product-category {
  font-size: 11px;
  color: var(--muted);
  overflow-wrap: anywhere;
}

.product-quantity {
  font-family: Georgia, serif;
  font-size: 18px;
  font-weight: 800;
  color: var(--primary);
  white-space: nowrap;
}

.product-minimum {
  font-size: 10px;
  color: var(--muted);
  margin-top: 3px;
}

.product-status {
  min-width: 0;
}

.status {
  display: inline-block;
  font-size: 10px;
  font-weight: 750;
  border-radius: 20px;
  padding: 5px 8px;
  background: var(--success-light);
  color: var(--success);
  white-space: normal;
}

.status.warning {
  background: var(--warning-light);
  color: var(--warning);
}

.status.danger {
  background: var(--danger-light);
  color: var(--danger);
}

.product-actions {
  display: flex;
  gap: 5px;
  flex-wrap: wrap;
  justify-content: flex-end;
  align-items: center;
}

.product-actions .small-button {
  padding: 6px 8px;
}

/* LOTES DESPLEGABLES */

.batches-details {
  grid-column: 1 / -1;
  border-top: 1px solid var(--border);
  padding-top: 9px;
  margin-top: 2px;
  min-width: 0;
}

.batches-details summary {
  font-size: 11px;
  font-weight: 750;
  color: var(--primary);
  cursor: pointer;
  padding: 4px 0;
  list-style-position: inside;
}

.batches-details summary:hover {
  color: var(--gold);
}

.batch-list {
  display: flex;
  flex-direction: column;
  gap: 7px;
  margin-top: 9px;
}

.batch-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  padding: 11px 12px;
  background: var(--surface-alt);
  border: 1px solid var(--border);
  border-radius: 8px;
}

.batch-data {
  display: flex;
  flex-direction: column;
  gap: 4px;
  min-width: 0;
}

.batch-data strong {
  font-size: 12px;
  color: var(--text);
}

.batch-data span {
  font-size: 10px;
  color: var(--muted);
  overflow-wrap: anywhere;
}

.batch-actions {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
  justify-content: flex-end;
}

/* ESTADOS VACÍOS Y ALERTAS */

.empty-state {
  text-align: center;
  padding: 38px 15px;
  color: var(--muted);
  background: var(--surface-alt);
  border: 1px dashed #d8d9ca;
  border-radius: 11px;
  margin-top: 10px;
}

.empty-state span {
  font-size: 34px;
  color: var(--gold);
}

.empty-state h3 {
  color: var(--primary);
  font-family: Georgia, serif;
}

.alert-item {
  padding: 12px 13px;
  margin-bottom: 8px;
  border-radius: 8px;
  background: var(--warning-light);
  color: #805719;
  font-size: 12px;
  line-height: 1.5;
  border-left: 4px solid var(--warning);
}

.alert-item.danger {
  background: var(--danger-light);
  color: #a13b3b;
  border-left-color: var(--danger);
}

.alerts-panel {
  border-left: 3px solid var(--gold);
}

/* COPIAS DE SEGURIDAD */

.backup-actions {
  display: flex;
  flex-direction: column;
  gap: 9px;
  margin-top: 15px;
}

.backup-actions button {
  width: 100%;
}

/* HISTORIAL */

.movement-history,
.history-panel {
  margin-top: 14px;
}

.movement-item,
.history-item,
.movement-row {
  padding: 12px 14px;
  border: 1px solid var(--border);
  border-radius: 9px;
  background: var(--surface-alt);
  margin-bottom: 8px;
  font-size: 12px;
}

.movement-item strong,
.history-item strong,
.movement-row strong {
  color: var(--primary);
}

.movement-item small,
.history-item small,
.movement-row small {
  color: var(--muted);
}

/* PIE DE PÁGINA */

footer {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 13px;
  flex-wrap: wrap;
  text-align: center;
  color: #d7e4dc;
  background: var(--primary-dark);
  border-top: 3px solid var(--gold);
  border-radius: 12px;
  padding: 18px;
  margin-top: 28px;
}

.footer-crest {
  font-family: Georgia, serif;
  font-size: 30px;
  color: #f0d18e;
}

footer strong {
  display: block;
  font-family: Georgia, serif;
  letter-spacing: .7px;
  font-size: 12px;
  color: #fff;
}

footer span {
  display: block;
  font-size: 11px;
  color: #e6c98f;
  margin-top: 3px;
}

.footer-motto {
  font-family: Georgia, serif;
  font-style: italic;
  font-size: 12px;
  margin: 0 12px;
}

.footer-version {
  font-size: 10px;
  color: #b9cec3;
  margin: 0;
}

/* VENTANAS Y FORMULARIOS */

dialog {
  width: min(550px, calc(100% - 24px));
  max-height: 90vh;
  overflow-y: auto;
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 25px;
  box-shadow: 0 20px 70px rgba(0,0,0,.25);
  background: var(--surface);
  color: var(--text);
}

dialog::backdrop {
  background: rgba(13,32,25,.76);
  backdrop-filter: blur(3px);
}

.dialog-heading {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 20px;
}

.dialog-heading h2 {
  margin: 0;
  font-family: Georgia, serif;
  color: var(--primary-dark);
}

.close-button {
  border: 0;
  background: transparent;
  font-size: 28px;
  color: var(--muted);
  line-height: 1;
}

.close-button:hover {
  color: var(--danger);
}

form label {
  display: block;
  font-size: 12px;
  font-weight: 700;
  margin: 13px 0 6px;
  color: var(--primary-dark);
}

.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.initial-batch-fields {
  margin-top: 20px;
  padding: 15px;
  background: var(--surface-alt);
  border: 1px solid var(--border);
  border-radius: 10px;
}

.initial-batch-fields h3 {
  font-size: 14px;
  margin: 0 0 8px;
  color: var(--primary);
}

[hidden] {
  display: none !important;
}

.dialog-actions {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  margin-top: 22px;
}

/* TABLET */

@media (max-width: 1100px) {
  .dashboard-grid {
    grid-template-columns: minmax(0, 1.5fr) minmax(250px, .8fr);
    gap: 14px;
  }

  .panel {
    padding: 17px;
  }

  .inventory-table-heading,
  .product-card {
    grid-template-columns: minmax(110px, 1.3fr) minmax(85px, .9fr) minmax(85px, .8fr) minmax(90px, .8fr);
  }

  .inventory-table-heading span:last-child {
    display: none;
  }

  .product-actions {
    grid-column: 1 / -1;
    justify-content: flex-start;
  }
}

/* TABLETA ESTRECHA Y MÓVIL */

@media (max-width: 760px) {
  .container {
    margin: 18px auto;
    padding: 0 12px;
  }

  .topbar {
    padding: 15px 13px;
    align-items: center;
  }

  .brand {
    gap: 10px;
  }

  .brand-icon {
  width: 49px;
  height: 49px;
  padding: 3px;
  border-radius: 13px 13px 17px 17px;
    }

  .brand-copy h1 {
    font-size: 16px;
    letter-spacing: 1px;
  }

  .brand-copy .family-name {
    font-size: 15px;
  }

  .brand-motto {
    font-size: 10px;
  }

  .offline-status {
    font-size: 10px;
    padding: 7px 9px;
  }

  .welcome {
    padding: 23px;
  }

  .welcome h2 {
    font-size: 26px;
    max-width: 80%;
  }

  .welcome-emblem {
    right: 3%;
    font-size: 66px;
  }

  .stats-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 9px;
  }

  .stat-card {
    padding: 14px;
  }

  .stat-card strong {
    font-size: 26px;
  }

  .stat-card span {
    font-size: 12px;
  }

  .stat-icon {
    font-size: 19px;
  }

  .dashboard-grid {
    grid-template-columns: 1fr;
  }

  .side-column {
    display: grid;
    grid-template-columns: 1fr 1fr;
    align-items: start;
  }

  .section-heading {
    align-items: flex-start;
    flex-direction: column;
  }

  .section-heading h2 {
    font-size: 21px;
  }

  .section-heading button {
    width: 100%;
  }

  .filters {
    flex-direction: column;
  }

  .inventory-table-heading {
    display: none;
  }

  .product-card {
    grid-template-columns: 1fr 1fr;
    gap: 11px;
    border: 1px solid var(--border);
    border-radius: 10px;
    margin-bottom: 9px;
    padding: 13px;
  }

  .product-main {
    grid-column: 1 / -1;
  }

  .product-category::before {
    content: "Categoría";
    display: block;
    color: var(--muted);
    font-size: 9px;
    text-transform: uppercase;
    letter-spacing: .5px;
    margin-bottom: 3px;
  }

  .product-quantity::before {
    content: "Existencias";
    display: block;
    font-family: inherit;
    font-size: 9px;
    font-weight: 600;
    color: var(--muted);
    text-transform: uppercase;
    letter-spacing: .5px;
    margin-bottom: 3px;
  }

  .product-status::before {
    content: "Estado";
    display: block;
    font-size: 9px;
    font-weight: 600;
    color: var(--muted);
    text-transform: uppercase;
    letter-spacing: .5px;
    margin-bottom: 4px;
  }

  .product-actions {
    grid-column: 1 / -1;
    justify-content: flex-start;
  }

  .batches-details {
    grid-column: 1 / -1;
  }

  .batch-row {
    align-items: flex-start;
    flex-direction: column;
  }

  .batch-actions {
    justify-content: flex-start;
  }

  .side-column {
    grid-template-columns: 1fr;
  }

  .backup-actions {
    flex-direction: column;
  }

  .backup-actions button {
    width: 100%;
  }

  footer {
    flex-direction: column;
    gap: 7px;
  }

  .footer-motto {
    margin: 5px 0;
  }
}

@media (max-width: 380px) {
  .offline-status {
    max-width: 90px;
    white-space: normal;
    text-align: center;
  }

  .brand-copy h1 {
    font-size: 14px;
  }

  .brand-copy .family-name {
    font-size: 13px;
  }

  .stats-grid {
    gap: 7px;
  }

  .stat-card {
    padding: 11px;
  }

  .product-actions .small-button {
    font-size: 10px;
  }
}

/* =====================================================
   AJUSTE DE INVENTARIO · DISEÑO DE ACCIONES COMPACTAS
   ===================================================== */

/* El inventario utiliza todo el ancho disponible */
.dashboard-grid {
  grid-template-columns: minmax(0, 1fr);
}

/* Alertas y copias quedan debajo del inventario */
.side-column {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  align-items: start;
}

/* Cabecera y productos comparten exactamente las columnas */
.inventory-table-heading,
.product-card {
  grid-template-columns:
    minmax(170px, 1.6fr)
    minmax(100px, .8fr)
    minmax(115px, .85fr)
    minmax(150px, 1fr)
    minmax(205px, 1.35fr);
  gap: 12px;
}

/* La cabecera de acciones vuelve a estar visible */
.inventory-table-heading span:last-child {
  display: block;
}

/* Acciones discretas, sin apariencia de botones */
.product-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-start;
  align-items: center;
  gap: 5px 12px;
  min-width: 0;
}

.action-link {
  appearance: none;
  border: 0;
  background: transparent;
  box-shadow: none;
  color: var(--primary);
  padding: 3px 0;
  margin: 0;
  border-radius: 0;
  font-size: 10px;
  font-weight: 650;
  white-space: nowrap;
  text-align: left;
  cursor: pointer;
  transition: color .15s;
}

.action-link:hover {
  color: var(--gold);
  background: transparent;
  text-decoration: underline;
}

.action-link.danger {
  color: var(--danger);
}

.action-link.danger:hover {
  color: #8e2828;
  background: transparent;
}

/* Acciones de lote también más discretas */
.batch-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  align-items: center;
  gap: 6px 12px;
}

.batch-action-link {
  appearance: none;
  border: 0;
  background: transparent;
  box-shadow: none;
  color: var(--primary);
  padding: 3px 0;
  border-radius: 0;
  font-size: 10px;
  font-weight: 650;
  cursor: pointer;
}

.batch-action-link:hover {
  color: var(--gold);
  background: transparent;
  text-decoration: underline;
}

.batch-action-link.danger {
  color: var(--danger);
}

/* Observaciones dentro de la información principal */
.product-notes {
  margin-top: 4px;
  font-size: 10px;
  line-height: 1.4;
  color: var(--muted);
}

/* Evitar que los textos largos deformen las columnas */
.product-card > *,
.inventory-table-heading > * {
  min-width: 0;
}

/* Tablet: conservamos las cinco columnas al tener el inventario
   todo el ancho. Reducimos espacios y tamaños. */
@media (max-width: 1100px) and (min-width: 761px) {
  .inventory-table-heading,
  .product-card {
    grid-template-columns:
      minmax(125px, 1.4fr)
      minmax(75px, .75fr)
      minmax(90px, .85fr)
      minmax(115px, 1fr)
      minmax(165px, 1.3fr);
    gap: 8px;
  }

  .product-card {
    padding: 12px 9px;
  }

  .product-actions {
    gap: 4px 9px;
  }

  .action-link {
    font-size: 9px;
  }
}

/* Móvil: tarjetas independientes */
@media (max-width: 760px) {
  .dashboard-grid {
    grid-template-columns: 1fr;
  }

  .side-column {
    display: grid;
    grid-template-columns: 1fr;
  }

  .inventory-table-heading {
    display: none;
  }

  .product-card {
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    gap: 11px;
    border: 1px solid var(--border);
    border-radius: 10px;
    margin-bottom: 9px;
    padding: 13px;
  }

  .product-main {
    grid-column: 1 / -1;
  }

  .product-actions {
    grid-column: 1 / -1;
    gap: 8px 15px;
    padding-top: 5px;
    border-top: 1px solid var(--border);
  }

  .action-link {
    font-size: 11px;
  }

  .batches-details {
    grid-column: 1 / -1;
  }

  .batch-actions {
    justify-content: flex-start;
  }
}
