:root {
  --mq-blue: #0d6efd;
  --mq-navy: #07111f;
  --mq-ink: #101828;
  --mq-muted: #667085;
  --mq-line: #e6eaf0;
  --mq-soft: #f4f7fb;
}

* {
  box-sizing: border-box;
}

body {
  background: #f5f7fb;
  color: var(--mq-ink);
  font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

img {
  max-width: 100%;
}

.site-header {
  background: #ffffff;
  border-bottom: 1px solid rgba(16, 24, 40, 0.08);
  position: sticky;
  top: 0;
  z-index: 20;
}

.site-header .navbar {
  min-height: 110px;
  padding: 0;
}

.logo-publico {
  display: block;
  height: 46px;
  width: auto;
}

.navbar-toggler {
  border: 0;
  padding: 8px;
}

.navbar-toggler:focus {
  box-shadow: none;
}

.nav-link {
  color: #243044 !important;
  font-size: 0.95rem;
  font-weight: 700;
  padding: 10px 13px !important;
}

.nav-link:hover,
.nav-link.active {
  color: var(--mq-blue) !important;
}

header.bg-dark {
  background: #ffffff !important;
  border-bottom: 1px solid rgba(16, 24, 40, 0.08);
  box-shadow: 0 10px 28px rgba(16, 24, 40, 0.05);
}

header.bg-dark > .container {
  gap: 22px;
}

header.bg-dark .nav-link {
  color: #243044 !important;
}

header.bg-dark .nav-link:hover,
header.bg-dark .nav-link.active {
  color: var(--mq-blue) !important;
}

header.bg-dark .logo-publico {
  height: auto;
  max-height: 96px;
}

main.container {
  background: transparent;
}

main.container > h1,
main.container > h2 {
  color: var(--mq-ink);
  font-weight: 900;
  letter-spacing: 0;
}

.bg-light {
  background: #ffffff !important;
}

section.bg-light.border-bottom {
  background:
    linear-gradient(135deg, rgba(7, 17, 31, 0.94), rgba(13, 110, 253, 0.74)),
    url("../img/referencias/caso1-1.jpg") center / cover no-repeat !important;
  border-bottom: 0 !important;
  box-shadow: none;
  color: #ffffff;
}

section.bg-light.border-bottom .text-muted,
section.bg-light.border-bottom .lead {
  color: rgba(255, 255, 255, 0.76) !important;
}

.lead {
  color: var(--mq-muted);
  line-height: 1.7;
}

.card,
form.shadow,
.table {
  background: #ffffff;
  border: 1px solid var(--mq-line);
  border-radius: 8px !important;
  box-shadow: 0 16px 40px rgba(16, 24, 40, 0.08) !important;
  overflow: hidden;
}

.card {
  transition: transform 180ms ease, box-shadow 180ms ease;
}

.card:hover {
  box-shadow: 0 20px 48px rgba(16, 24, 40, 0.12) !important;
  transform: translateY(-2px);
}

.card-title,
.card h3,
main h2,
main h3 {
  font-weight: 900;
  letter-spacing: 0;
}

.card-img-top {
  aspect-ratio: 4 / 3;
  object-fit: cover;
}

.row.align-items-center > [class*="col-md-6"] > img.img-fluid {
  border-radius: 8px !important;
  box-shadow: 0 18px 44px rgba(16, 24, 40, 0.14) !important;
}

.table th {
  background: #f0f5ff;
  color: #1d3557;
  font-weight: 900;
  width: 38%;
}

.table td {
  background: #ffffff;
  color: var(--mq-ink);
}

.product-detail-media {
  background: #ffffff;
  border: 1px solid var(--mq-line);
  border-radius: 8px;
  box-shadow: 0 16px 40px rgba(16, 24, 40, 0.08);
  overflow: hidden;
}

.product-detail-media img {
  aspect-ratio: 4 / 3;
  display: block;
  height: 100%;
  object-fit: cover;
  width: 100%;
}

.product-description {
  background: #ffffff;
  border: 1px solid var(--mq-line);
  border-radius: 8px;
  box-shadow: 0 16px 40px rgba(16, 24, 40, 0.08);
  padding: 28px;
}

.form-control {
  border-color: #d7deea;
  border-radius: 6px;
  padding: 0.78rem 0.9rem;
}

.form-control:focus {
  border-color: var(--mq-blue);
  box-shadow: 0 0 0 0.2rem rgba(13, 110, 253, 0.14);
}

.btn-primary {
  background: var(--mq-blue);
  border-color: var(--mq-blue);
}

.btn-outline-primary {
  border-color: var(--mq-blue);
  color: var(--mq-blue);
}

.btn-outline-primary:hover {
  background: var(--mq-blue);
  border-color: var(--mq-blue);
}

.text-primary,
.bi.text-primary {
  color: var(--mq-blue) !important;
}

footer.bg-dark {
  background: #080f1c !important;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
}

footer.bg-dark a {
  color: rgba(255, 255, 255, 0.78) !important;
}

footer.bg-dark a:hover {
  color: #ffffff !important;
}

.nav-cta {
  border: 1px solid rgba(13, 110, 253, 0.24);
  border-radius: 6px;
  margin-left: 8px;
}

.language-switch {
  align-items: center;
  display: inline-flex;
  gap: 4px;
  margin-left: 10px;
  white-space: nowrap;
}

.language-switch a {
  border: 1px solid rgba(13, 110, 253, 0.22);
  border-radius: 4px;
  color: #243044;
  font-size: 0.78rem;
  font-weight: 900;
  line-height: 1;
  padding: 8px 9px;
  text-decoration: none;
}

.flag {
  display: inline-block;
  height: auto;
  margin-right: 5px;
  vertical-align: -1px;
  width: 20px;
}

.language-switch a.active {
  background: var(--mq-blue);
  border-color: var(--mq-blue);
  color: #ffffff;
}

.protected-image,
img {
  -webkit-user-drag: none;
  -webkit-touch-callout: none;
  user-select: none;
}

.hp-field {
  height: 0;
  left: -9999px;
  opacity: 0;
  overflow: hidden;
  position: absolute;
  top: auto;
  width: 0;
}

.privacy-form-note {
  background: #f6f8fc;
  border: 1px solid var(--mq-line);
  border-radius: 8px;
  color: #46556f;
  font-size: 0.88rem;
  line-height: 1.55;
  padding: 14px 16px;
}

.cookie-notice {
  align-items: center;
  background: #ffffff;
  border: 1px solid var(--mq-line);
  border-radius: 8px;
  bottom: 18px;
  box-shadow: 0 18px 44px rgba(16, 24, 40, 0.16);
  display: flex;
  gap: 18px;
  left: 18px;
  max-width: 760px;
  padding: 16px;
  position: fixed;
  right: 18px;
  z-index: 1000;
}

.cookie-notice__text {
  color: var(--mq-muted);
  display: flex;
  flex: 1;
  flex-direction: column;
  font-size: 0.92rem;
  gap: 4px;
  line-height: 1.45;
}

.cookie-notice__text strong {
  color: var(--mq-ink);
  font-size: 1rem;
  font-weight: 900;
}

.cookie-notice__text a {
  color: var(--mq-blue);
  font-weight: 800;
  text-decoration: none;
}

.cookie-notice__text a:hover {
  text-decoration: underline;
}

.cookie-notice__button {
  background: var(--mq-blue);
  border: 1px solid var(--mq-blue);
  border-radius: 4px;
  color: #ffffff;
  flex: 0 0 auto;
  font-weight: 900;
  padding: 0.75rem 1rem;
}

.cookie-notice__button:hover {
  background: #0b5ed7;
  border-color: #0b5ed7;
}

.home-page {
  background: var(--mq-navy);
}

.section-kicker {
  color: var(--mq-blue);
  display: inline-block;
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  margin-bottom: 10px;
  text-transform: uppercase;
}

.hero-industrial {
  background: #081525 url("../img/referencias/caso1-1.jpg") center / cover no-repeat;
  color: #ffffff;
  min-height: calc(100vh - 110px);
  position: relative;
}

.hero-backdrop {
  background:
    linear-gradient(180deg, rgba(7, 17, 31, 0.1) 0%, rgba(7, 17, 31, 0.44) 43%, rgba(7, 17, 31, 0.96) 100%),
    linear-gradient(90deg, rgba(7, 17, 31, 0.86) 0%, rgba(7, 17, 31, 0.42) 52%, rgba(7, 17, 31, 0.18) 100%);
  inset: 0;
  position: absolute;
}

.hero-content {
  min-height: calc(100vh - 110px);
  padding-bottom: clamp(44px, 9vh, 92px);
  padding-top: 72px;
  position: relative;
  z-index: 1;
}

.hero-industrial h1 {
  font-size: clamp(2.4rem, 7vw, 5.7rem);
  font-weight: 900;
  letter-spacing: 0;
  line-height: 0.96;
  margin: 0 0 20px;
  max-width: 850px;
}

.hero-industrial p {
  color: rgba(255, 255, 255, 0.82);
  font-size: clamp(1rem, 2vw, 1.25rem);
  line-height: 1.7;
  margin-bottom: 28px;
  max-width: 690px;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.btn {
  border-radius: 4px;
  font-weight: 800;
  padding: 0.82rem 1.12rem;
}

.hero-stat {
  border-left: 3px solid var(--mq-blue);
  color: rgba(255, 255, 255, 0.78);
  padding-left: 18px;
}

.hero-stat strong {
  color: #ffffff;
  display: block;
  font-size: 3rem;
  line-height: 1;
}

.featured-strip,
.specialties-section {
  background: var(--mq-navy);
  color: #ffffff;
  padding: clamp(44px, 8vw, 86px) 0;
}

.section-heading {
  margin-bottom: 28px;
}

.section-heading h2 {
  font-size: clamp(1.8rem, 4vw, 3.4rem);
  font-weight: 900;
  line-height: 1.02;
  margin: 0;
}

.section-heading p {
  color: var(--mq-muted);
  line-height: 1.75;
  margin: 14px auto 0;
  max-width: 720px;
}

.section-heading.dark h2 {
  color: #ffffff;
}

.product-carousel {
  padding: 0 42px;
}

.featured-product {
  background: #0d1b2f;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 8px;
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(280px, 0.85fr);
  grid-template-rows: minmax(0, 1fr);
  height: 420px;
  overflow: hidden;
}

/* Todas las fotos ocupan el mismo recuadro, sea cual sea su proporción: se ven enteras y sin deformar. */
.featured-product img {
  background: #eef1f5;
  height: 100%;
  object-fit: contain;
  width: 100%;
}

.featured-product-body {
  align-self: end;
  padding: clamp(24px, 5vw, 46px);
}

.featured-product-body span {
  color: #8dbdff;
  font-size: 0.78rem;
  font-weight: 800;
  text-transform: uppercase;
}

.featured-product-body h3 {
  font-size: clamp(1.7rem, 3vw, 3rem);
  font-weight: 900;
  margin: 10px 0 14px;
}

.featured-product-body p {
  color: rgba(255, 255, 255, 0.72);
  line-height: 1.7;
}

.featured-product-body a {
  color: #ffffff;
  font-weight: 800;
  text-decoration: none;
}

.carousel-control-prev,
.carousel-control-next {
  width: 36px;
}

.specialty-grid {
  display: grid;
  gap: 22px;
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.specialty-card {
  border-radius: 8px;
  color: #ffffff;
  display: block;
  min-height: 340px;
  overflow: hidden;
  position: relative;
  text-decoration: none;
}

.specialty-card::after {
  background: linear-gradient(180deg, rgba(7, 17, 31, 0.02) 25%, rgba(7, 17, 31, 0.94) 100%);
  content: "";
  inset: 0;
  position: absolute;
}

.specialty-card img {
  height: 100%;
  object-fit: cover;
  position: absolute;
  width: 100%;
}

.specialty-card span {
  bottom: 22px;
  font-size: 1.15rem;
  font-weight: 900;
  left: 22px;
  position: absolute;
  right: 22px;
  z-index: 1;
}

.why-section {
  background: #ffffff;
  padding: clamp(54px, 9vw, 96px) 0;
}

.why-grid {
  display: grid;
  gap: 18px;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  margin-top: 34px;
}

.why-grid article {
  background: var(--mq-soft);
  border: 1px solid var(--mq-line);
  border-radius: 8px;
  padding: 26px;
}

.why-grid i {
  align-items: center;
  background: #ffffff;
  border-radius: 6px;
  color: var(--mq-blue);
  display: inline-flex;
  font-size: 1.35rem;
  height: 46px;
  justify-content: center;
  margin-bottom: 18px;
  width: 46px;
}

.why-grid h3 {
  font-size: 1.1rem;
  font-weight: 900;
}

.why-grid p {
  color: var(--mq-muted);
  line-height: 1.65;
  margin-bottom: 0;
}

.site-footer {
  background: #080f1c;
  color: rgba(255, 255, 255, 0.72);
  padding: 48px 0 24px;
}

.site-footer .container {
  display: grid;
  gap: 26px;
  grid-template-columns: 1.5fr 0.7fr 0.7fr;
}

.site-footer img {
  filter: brightness(0) invert(1);
  height: 40px;
  margin-bottom: 14px;
  width: auto;
}

.site-footer h2 {
  color: #ffffff;
  font-size: 0.85rem;
  font-weight: 900;
  margin-bottom: 12px;
  text-transform: uppercase;
}

.site-footer a {
  color: rgba(255, 255, 255, 0.72);
  display: block;
  margin-bottom: 8px;
  text-decoration: none;
}

.site-footer small {
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  grid-column: 1 / -1;
  padding-top: 20px;
}

.logo-admin {
  max-height: 40px;
  width: auto;
}

.logo-login {
  max-height: 80px;
  width: auto;
  margin-bottom: 10px;
}

.admin-page {
  background: #f6f8fb;
  min-height: 100vh;
}

.admin-login-page {
  align-items: center;
  background: #f6f8fb;
  display: flex;
  min-height: 100vh;
  padding: 24px;
}

.admin-login-card {
  background: #ffffff;
  border: 1px solid var(--mq-line);
  border-radius: 8px;
  box-shadow: 0 18px 44px rgba(16, 24, 40, 0.08);
  margin: 0 auto;
  max-width: 420px;
  padding: 28px;
  width: 100%;
}

.admin-login-card:hover {
  box-shadow: 0 18px 44px rgba(16, 24, 40, 0.08) !important;
  transform: none;
}

.admin-login-card h1 {
  color: var(--mq-ink);
  font-size: 1.45rem;
  font-weight: 900;
  margin: 0 0 6px;
  text-align: center;
}

.admin-login-card p {
  color: var(--mq-muted);
  margin: 0 0 22px;
  text-align: center;
}

.admin-login-card .form-label {
  color: #344054;
  font-size: 0.86rem;
  font-weight: 900;
}

.admin-topbar {
  background: #ffffff;
  border-bottom: 1px solid rgba(16, 24, 40, 0.08);
  box-shadow: 0 8px 22px rgba(16, 24, 40, 0.04);
  position: sticky;
  top: 0;
  z-index: 10;
}

.admin-topbar-inner {
  align-items: center;
  display: flex;
  justify-content: space-between;
  min-height: 62px;
  padding-left: clamp(16px, 2vw, 28px);
  padding-right: clamp(16px, 2vw, 28px);
}

.admin-brand {
  align-items: center;
  display: inline-flex;
}

.admin-topbar-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  justify-content: flex-end;
}

.admin-topbar-actions .btn {
  padding: 0.55rem 0.78rem;
}

.admin-primary-action {
  padding: 0.68rem 0.95rem;
}

.admin-topbar-actions .btn,
.admin-primary-action,
.admin-actions .btn {
  align-items: center;
  display: inline-flex;
  gap: 8px;
  justify-content: center;
}

.admin-shell {
  max-width: 1380px;
  padding: clamp(16px, 2vw, 28px);
}

.admin-page-head {
  align-items: flex-end;
  display: flex;
  gap: 18px;
  justify-content: space-between;
  margin-bottom: 14px;
}

.admin-title-block h1 {
  color: var(--mq-ink);
  font-size: clamp(1.75rem, 3vw, 2.35rem);
  font-weight: 900;
  line-height: 1.05;
  margin: 0 0 6px;
}

.admin-title-block p {
  color: var(--mq-muted);
  margin: 0;
}

.admin-summary {
  display: grid;
  gap: 10px;
  grid-template-columns: 150px 150px minmax(0, 1fr);
  margin-bottom: 14px;
}

.admin-summary-item {
  background: #ffffff;
  border: 1px solid var(--mq-line);
  border-radius: 8px;
  min-width: 0;
  padding: 12px 14px;
}

.admin-summary-item span {
  color: var(--mq-muted);
  display: block;
  font-size: 0.72rem;
  font-weight: 900;
  margin-bottom: 4px;
  text-transform: uppercase;
}

.admin-summary-item strong {
  color: var(--mq-ink);
  display: block;
  font-size: 1.2rem;
  font-weight: 900;
  line-height: 1.15;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.admin-kicker {
  color: var(--mq-blue);
  display: inline-block;
  font-size: 0.76rem;
  font-weight: 900;
  letter-spacing: 0.08em;
  margin-bottom: 10px;
  text-transform: uppercase;
}

.admin-panel {
  background: #ffffff;
  border: 1px solid var(--mq-line);
  border-radius: 8px;
  box-shadow: 0 12px 30px rgba(16, 24, 40, 0.06);
  overflow: hidden;
}

.admin-panel-header {
  align-items: center;
  border-bottom: 1px solid var(--mq-line);
  display: flex;
  gap: 18px;
  justify-content: space-between;
  padding: 16px;
}

.admin-panel-header h2 {
  font-size: 1.08rem;
  font-weight: 900;
  margin: 0 0 4px;
}

.admin-panel-header p {
  color: var(--mq-muted);
  font-size: 0.92rem;
  margin: 0;
}

.admin-search {
  align-items: center;
  display: grid;
  gap: 10px;
  grid-template-columns: auto minmax(220px, 360px) auto auto;
}

.admin-search i {
  color: var(--mq-muted);
}

.admin-table-wrap {
  margin: 0;
}

.admin-table {
  box-shadow: none !important;
  margin: 0;
}

.admin-table th {
  background: #f7f9fc;
  border-bottom: 1px solid var(--mq-line);
  color: #46556f;
  font-size: 0.72rem;
  letter-spacing: 0.08em;
  padding: 12px 14px;
  text-transform: uppercase;
  width: auto;
}

.admin-table td {
  border-bottom: 1px solid #eef2f7;
  padding: 12px 14px;
  vertical-align: middle;
}

.admin-table tbody tr:hover td {
  background: #f9fbff;
}

.admin-table td strong {
  display: block;
  font-weight: 900;
}

.admin-table td small {
  color: var(--mq-muted);
  display: block;
  margin-top: 3px;
}

.admin-id,
.admin-badge {
  background: #f1f5f9;
  border: 1px solid #e2e8f0;
  border-radius: 6px;
  color: #475569;
  display: inline-flex;
  font-size: 0.78rem;
  font-weight: 900;
  line-height: 1;
  padding: 7px 9px;
  white-space: nowrap;
}

.admin-badge-offer {
  background: #e9f7ef;
  border-color: #cdeedc;
  color: #167346;
}

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

.admin-actions form {
  margin: 0;
}

.admin-actions .btn {
  border-radius: 6px;
  height: 34px;
  padding: 0;
  width: 34px;
}

.admin-empty {
  align-items: center;
  color: var(--mq-muted);
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 40px 16px;
  text-align: center;
}

.admin-empty i {
  color: var(--mq-blue);
  font-size: 2rem;
}

.admin-empty strong {
  color: var(--mq-ink);
  font-size: 1.1rem;
}

.admin-alert {
  align-items: center;
  border-radius: 8px;
  display: flex;
  gap: 10px;
  margin-bottom: 18px;
}

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

.admin-form-narrow {
  max-width: 760px;
}

.admin-form-card {
  background: #ffffff;
  border: 1px solid var(--mq-line);
  border-radius: 8px;
  box-shadow: 0 12px 30px rgba(16, 24, 40, 0.06);
  padding: clamp(18px, 2vw, 24px);
}

.admin-form-heading {
  align-items: flex-start;
  border-bottom: 1px solid var(--mq-line);
  display: flex;
  gap: 14px;
  margin-bottom: 22px;
  padding-bottom: 18px;
}

.admin-form-heading > span {
  align-items: center;
  background: #eef5ff;
  border: 1px solid #d9e9ff;
  border-radius: 8px;
  color: var(--mq-blue);
  display: inline-flex;
  flex: 0 0 auto;
  font-size: 1.2rem;
  height: 42px;
  justify-content: center;
  width: 42px;
}

.admin-form-heading h2 {
  font-size: 1.18rem;
  font-weight: 900;
  margin: 0 0 4px;
}

.admin-form-heading p {
  color: var(--mq-muted);
  line-height: 1.55;
  margin: 0;
}

.admin-form .form-label {
  color: #344054;
  font-size: 0.86rem;
  font-weight: 900;
  margin-bottom: 8px;
}

.admin-form textarea.form-control {
  min-height: 160px;
  resize: vertical;
}

.admin-upload {
  align-items: center;
  background: #f8fbff;
  border: 1px dashed #b9cce8;
  border-radius: 8px;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  gap: 8px;
  justify-content: center;
  min-height: 190px;
  padding: 24px;
  text-align: center;
  transition: border-color 180ms ease, background-color 180ms ease;
}

.admin-upload:hover {
  background: #f1f7ff;
  border-color: var(--mq-blue);
}

.admin-upload i {
  color: var(--mq-blue);
  font-size: 2rem;
}

.admin-upload strong {
  color: var(--mq-ink);
  font-weight: 900;
}

.admin-upload span {
  color: var(--mq-muted);
  font-size: 0.9rem;
}

.admin-upload input {
  max-width: 320px;
}

.admin-media-grid {
  display: grid;
  gap: 18px;
  grid-template-columns: minmax(0, 1fr) 260px;
}

.admin-current-image {
  background: #f8fafc;
  border: 1px solid var(--mq-line);
  border-radius: 8px;
  padding: 14px;
}

.admin-current-image > span {
  color: var(--mq-muted);
  display: block;
  font-size: 0.78rem;
  font-weight: 900;
  margin-bottom: 10px;
  text-transform: uppercase;
}

.admin-current-image img {
  aspect-ratio: 4 / 3;
  background: #ffffff;
  border-radius: 6px;
  display: block;
  object-fit: cover;
  width: 100%;
}

.admin-image-placeholder {
  align-items: center;
  aspect-ratio: 4 / 3;
  background: #ffffff;
  border: 1px dashed #cbd5e1;
  border-radius: 6px;
  color: var(--mq-muted);
  display: flex;
  flex-direction: column;
  font-weight: 800;
  gap: 8px;
  justify-content: center;
}

.admin-image-placeholder i {
  color: var(--mq-blue);
  font-size: 1.6rem;
}

.admin-form-actions {
  background: #ffffff;
  border: 1px solid var(--mq-line);
  border-radius: 8px;
  box-shadow: 0 12px 30px rgba(16, 24, 40, 0.06);
  display: flex;
  gap: 10px;
  justify-content: flex-end;
  padding: 16px;
}

.admin-form-actions .btn {
  align-items: center;
  display: inline-flex;
  gap: 8px;
  justify-content: center;
}

@media (max-width: 991.98px) {
  .site-header .navbar-collapse {
    border-top: 1px solid var(--mq-line);
    padding: 10px 0 16px;
  }

  header.bg-dark > .container {
    flex-direction: column;
    height: auto !important;
    padding-bottom: 18px;
    padding-top: 18px;
  }

  header.bg-dark .nav {
    gap: 4px 10px;
  }

  .nav-cta {
    margin-left: 0;
  }

  .language-switch {
    justify-content: center;
    margin-left: 0;
    width: 100%;
  }

  .featured-product,
  .specialty-grid,
  .why-grid,
  .admin-summary,
  .site-footer .container {
    grid-template-columns: 1fr;
  }

  .admin-page-head {
    align-items: stretch;
    flex-direction: column;
  }

  .admin-panel-header {
    align-items: stretch;
    flex-direction: column;
  }

  .admin-search {
    grid-template-columns: auto 1fr;
  }

  .admin-search .btn {
    grid-column: span 2;
  }

  .admin-form-actions {
    flex-direction: column-reverse;
  }

  .admin-form-actions .btn {
    width: 100%;
  }

  .admin-media-grid {
    grid-template-columns: 1fr;
  }

  .featured-product {
    grid-template-rows: auto;
    height: auto;
  }

  .featured-product img {
    height: 300px;
  }

  .specialty-card {
    min-height: 290px;
  }
}

@media (max-width: 575.98px) {
  .logo-publico {
    height: 36px;
  }

  .bg-dark .logo-publico {
    max-height: 76px;
  }

  .hero-industrial,
  .hero-content {
    min-height: 720px;
  }

  .hero-content {
    padding-bottom: 42px;
  }

  .hero-actions .btn {
    width: 100%;
  }

  .product-carousel {
    padding: 0;
  }

  .featured-product {
    height: auto;
  }

  .featured-product img {
    height: 260px;
  }

  .carousel-control-prev,
  .carousel-control-next {
    display: none;
  }

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

  .cookie-notice__button {
    width: 100%;
  }

  .admin-topbar-inner {
    align-items: stretch;
    flex-direction: column;
    gap: 12px;
    padding-bottom: 14px;
    padding-top: 14px;
  }

  .admin-topbar-actions .btn,
  .admin-primary-action {
    width: 100%;
  }

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

/* Sustituyen estilos en línea (bloqueados por la CSP style-src 'self') */
.product-brand {
  font-size: .72rem;
  letter-spacing: .06em;
}

.contact-form-narrow {
  max-width: 600px;
}

/* Código QR del 2FA (SVG en línea generado en el servidor) */
.qr-code svg {
  height: auto;
  max-width: 220px;
  width: 100%;
}

/* Aviso legal (HTML heredado): antes iba en un <style> en línea, bloqueado por la CSP */
.legacy-legal * {
  max-width: 100% !important;
}

.legacy-legal table {
  height: auto !important;
  width: 100% !important;
}

.legacy-legal img {
  height: auto;
}

/* Las imágenes con width/height (evitan saltos de maquetación) conservan su proporción;
   :where() deja la especificidad en 0 para que cualquier clase con height propio siga mandando. */
:where(img[width][height]) {
  height: auto;
}

/* Mientras el aviso de cookies está visible se reserva su altura al final de la página */
body.has-cookie-notice {
  padding-bottom: 120px;
}

@media (max-width: 575.98px) {
  body.has-cookie-notice {
    padding-bottom: 230px;
  }
}
