/* ==========================================================================
   STM PRO Portal — Rediseño de las páginas interiores
   Mismo lenguaje visual que la portada: bandas a todo el ancho, cabecera
   oscura con retícula, tipografía Archivo / IBM Plex y acento por sección.
   Todo está acotado a body.stm-portal:not(.home):not(#stm-x) para no afectar a la portada
   ni al panel de administración.
   ========================================================================== */

body.stm-portal:not(.home):not(#stm-x) {
  --ink: var(--stm-ink, #121214);
  --paper: var(--stm-paper, #f6f5f3);
  --white: #fff;
  --signal: var(--stm-signal, #c8102e);
  --steel: var(--stm-steel, #55565c);
  --line: rgba(18, 18, 20, .1);
  --line-2: rgba(18, 18, 20, .16);
  --line-dark: rgba(255, 255, 255, .1);
  --ease-out: cubic-bezier(.22, 1, .36, 1);
  --display: "Archivo", system-ui, sans-serif;
  --body: "IBM Plex Sans", system-ui, sans-serif;
  --mono: "IBM Plex Mono", ui-monospace, monospace;
  --container: min(1290px, 90vw);
  --c-averia: #c8102e;
  --c-repuesto: #e0a100;
  --c-descarga: #3d8bfd;
  --c-registro: #2ecc71;
  --c-ia: #9b6bff;
  --c-pedido: #14b8a6;
  background: var(--paper);
}
html:has(body.stm-portal:not(.home)) { overflow-x: clip; }

/* acento por página (lo fija el JS en data-stm-section) */
body.stm-portal { --accent: var(--stm-signal, #c8102e); }
body[data-stm-section="averias"]   { --accent: var(--c-averia); }
body[data-stm-section="repuestos"] { --accent: var(--c-repuesto); }
body[data-stm-section="descargas"] { --accent: var(--c-descarga); }
body[data-stm-section="informe"]   { --accent: var(--c-repuesto); }
body[data-stm-section="pedidos"]   { --accent: var(--c-pedido); }
body[data-stm-section="ia"]        { --accent: var(--c-ia); }
body[data-stm-section="registro"]  { --accent: var(--c-registro); }
body[data-stm-section="maquina"]   { --accent: var(--signal); }

/* ---------- CABECERA DE PÁGINA (la genera el JS) ---------- */
.stm-portal .stm-page-hero {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  color: var(--white);
  background: var(--ink);
  padding: clamp(48px, 7vw, 96px) 0 clamp(52px, 7vw, 96px);
  font-family: var(--body);
}
.stm-portal .stm-page-hero::before {
  content: "";
  position: absolute;
  inset: -64px;
  z-index: -2;
  background-image:
    linear-gradient(var(--line-dark) 1px, transparent 1px),
    linear-gradient(90deg, var(--line-dark) 1px, transparent 1px);
  background-size: 64px 64px;
  mask-image: radial-gradient(ellipse 70% 90% at 75% 30%, #000 15%, transparent 75%);
  opacity: .5;
  animation: stm-p-grid 28s linear infinite;
}
.stm-portal .stm-page-hero::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background:
    radial-gradient(560px circle at 85% 20%, color-mix(in srgb, var(--accent) 32%, transparent), transparent 62%),
    radial-gradient(700px circle at 0% 120%, rgba(200, 16, 46, .14), transparent 60%);
}
@keyframes stm-p-grid { to { transform: translate3d(64px, 64px, 0); } }

.stm-portal .stm-page-hero__inner {
  width: var(--container);
  margin-inline: auto;
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: clamp(28px, 4vw, 56px);
  align-items: center;
}
.stm-portal .stm-page-hero--media .stm-page-hero__inner { grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr); }

.stm-portal .stm-crumbs {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin: 0 0 22px;
  font-family: var(--mono);
  font-size: 12px;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, .5);
}
.stm-portal .stm-crumbs a { color: rgba(255, 255, 255, .75) !important; text-decoration: none !important; transition: color .2s; }
.stm-portal .stm-crumbs a:hover { color: #fff !important; }
.stm-portal .stm-crumbs span[aria-hidden] { opacity: .4; }

.stm-portal .stm-page-hero__kicker {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 7px 14px 7px 12px;
  font-family: var(--mono);
  font-size: 12px;
  font-weight: 500;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, .88);
  background: rgba(255, 255, 255, .05);
  border: 1px solid var(--line-dark);
  border-radius: 999px;
}
.stm-portal .stm-page-hero__kicker::before {
  content: "";
  width: 8px; height: 8px;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 0 0 color-mix(in srgb, var(--accent) 60%, transparent);
  animation: stm-p-pulse 2.4s ease-out infinite;
}
@keyframes stm-p-pulse { 70%, 100% { box-shadow: 0 0 0 10px transparent; } }

.stm-portal .stm-page-hero h1 {
  margin: 22px 0 0;
  font-family: var(--display);
  font-weight: 900;
  font-size: clamp(34px, 4.6vw, 64px);
  line-height: 1;
  letter-spacing: -.035em;
  color: var(--white);
  text-wrap: balance;
}
.stm-portal .stm-page-hero h1::after {
  content: "";
  display: block;
  width: 56px;
  height: 3px;
  margin-top: 22px;
  background: var(--accent);
  transform-origin: left;
  animation: stm-p-draw .9s var(--ease-out) .35s both;
}
@keyframes stm-p-draw { from { transform: scaleX(0); } }
.stm-portal .stm-page-hero__lead {
  max-width: 62ch;
  margin: 20px 0 0;
  font-size: clamp(15px, 1.25vw, 18px);
  line-height: 1.65;
  color: rgba(255, 255, 255, .68);
}
.stm-portal .stm-page-hero__meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 24px;
}
.stm-portal .stm-page-hero__meta > * {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin: 0;
  padding: 7px 12px;
  font-family: var(--mono);
  font-size: 12.5px;
  color: rgba(255, 255, 255, .82);
  background: rgba(255, 255, 255, .05);
  border: 1px solid var(--line-dark);
  border-radius: 8px;
}
.stm-portal .stm-page-hero__meta a { color: #fff !important; text-decoration: underline; text-decoration-color: color-mix(in srgb, var(--accent) 70%, transparent); text-underline-offset: 3px; }
.stm-portal .stm-page-hero__meta strong { color: #fff; font-weight: 600; }

.stm-portal .stm-page-hero__media {
  position: relative;
  margin: 0;
  border-radius: 18px;
  overflow: hidden;
  background: linear-gradient(145deg, #1f1f24, #0c0c0e);
  border: 1px solid var(--line-dark);
  box-shadow: 0 40px 80px -40px rgba(0, 0, 0, .8);
  aspect-ratio: 4 / 3;
  display: grid;
  place-items: center;
  animation: stm-p-rise 1s var(--ease-out) .2s both;
}
.stm-portal .stm-page-hero__media img { width: 88%; height: 88%; object-fit: contain; filter: drop-shadow(0 24px 30px rgba(0, 0, 0, .55)); }

/* icono decorativo de sección */
.stm-portal .stm-page-hero__icon {
  position: absolute;
  right: max(5vw, calc((100% - 1290px) / 2));
  top: 50%;
  width: clamp(120px, 16vw, 220px);
  aspect-ratio: 1;
  translate: 0 -50%;
  color: var(--accent);
  opacity: .16;
  background: currentColor;
  -webkit-mask: var(--ico) center / contain no-repeat;
  mask: var(--ico) center / contain no-repeat;
  pointer-events: none;
  animation: stm-p-float 8s ease-in-out infinite;
}
@keyframes stm-p-float { 50% { transform: translateY(-10px) rotate(-3deg); } }

.stm-portal .stm-page-hero__inner > div > * { animation: stm-p-rise .9s var(--ease-out) both; }
.stm-portal .stm-page-hero__inner > div > :nth-child(2) { animation-delay: .08s; }
.stm-portal .stm-page-hero__inner > div > :nth-child(3) { animation-delay: .16s; }
.stm-portal .stm-page-hero__inner > div > :nth-child(4) { animation-delay: .24s; }
.stm-portal .stm-page-hero__inner > div > :nth-child(5) { animation-delay: .32s; }
@keyframes stm-p-rise { from { opacity: 0; transform: translateY(18px); } to { opacity: 1; transform: none; } }

/* títulos originales que sustituye la cabecera nueva */
body.stm-has-hero .stm-portal-hide,
body.stm-has-hero .hero-section { display: none !important; }

/* ---------- CONTENEDORES: todo el ancho, alineado con la cabecera ---------- */
body.stm-portal:not(.home):not(#stm-x) .site-main { font-family: var(--body); }
body.stm-portal:not(.home):not(#stm-x) .stm-band { padding: 0; }
body.stm-portal:not(.home):not(#stm-x) .stm-band__inner {
  width: var(--container);
  max-width: none;
  padding: clamp(36px, 5vw, 72px) 0 clamp(56px, 7vw, 104px);
  gap: 28px;
}
body.stm-portal:not(.home):not(#stm-x) .stm-band:empty { display: none; }
body.stm-portal:not(.home):not(#stm-x) .ct-container-full { padding-top: 0 !important; }
body.stm-portal:not(.home):not(#stm-x) .ct-container-full > article > .entry-content {
  width: var(--container);
  margin-inline: auto;
  padding: clamp(36px, 5vw, 72px) 0 clamp(56px, 7vw, 104px);
}
body.stm-portal:not(.home):not(#stm-x) .entry-content.is-layout-constrained > * { max-width: none !important; margin-left: 0 !important; margin-right: 0 !important; }
body.stm-portal:not(.home):not(#stm-x) .stm-averia-pro,
body.stm-portal:not(.home):not(#stm-x) .stm-repuesto-pro {
  width: var(--container);
  max-width: none !important;
  margin: 0 auto !important;
  padding: clamp(36px, 5vw, 72px) 0 clamp(56px, 7vw, 104px) !important;
}
body.stm-portal:not(.home):not(#stm-x) .stm-text { text-align: left !important; }

/* ---------- BARRA DE FILTROS ---------- */
body.stm-portal:not(.home):not(#stm-x) :is(.stm-buscador__filtros, .stm-buscador-pedido__filtros) {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: stretch;
  justify-content: flex-start;
  margin: 0 0 8px;
  padding: 12px;
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: 16px;
  box-shadow: 0 24px 48px -36px rgba(18, 18, 20, .35);
}
body.stm-portal:not(.home):not(#stm-x) :is(.stm-buscador__filtros, .stm-buscador-pedido__filtros) :is(input, select) {
  flex: 1 1 200px;
  min-width: 0;
  height: 50px;
  padding: 0 16px !important;
  font: 500 15px/1 var(--body);
  color: var(--ink);
  background-color: var(--paper);
  border: 1px solid transparent !important;
  border-radius: 10px !important;
  box-shadow: none;
  transition: border-color .2s, background-color .2s, box-shadow .2s;
}
body.stm-portal:not(.home):not(#stm-x) :is(.stm-buscador__filtros, .stm-buscador-pedido__filtros) input[type="text"] {
  flex: 2 1 280px;
  padding-left: 44px !important;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%2355565c' stroke-width='2' stroke-linecap='round'%3E%3Ccircle cx='11' cy='11' r='7'/%3E%3Cpath d='m20 20-3.5-3.5'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: 16px 50%;
  background-size: 18px;
}
body.stm-portal:not(.home):not(#stm-x) :is(.stm-buscador__filtros, .stm-buscador-pedido__filtros) :is(input, select):hover { background-color: #efeee9; }
body.stm-portal:not(.home):not(#stm-x) :is(.stm-buscador__filtros, .stm-buscador-pedido__filtros) :is(input, select):focus {
  outline: none;
  background-color: var(--white);
  border-color: var(--accent) !important;
  box-shadow: 0 0 0 4px color-mix(in srgb, var(--accent) 16%, transparent);
}
body.stm-portal:not(.home):not(#stm-x) .stm-btn-reset {
  flex: 0 0 auto;
  height: 50px;
  padding: 0 18px;
  font: 600 13px/1 var(--mono);
  letter-spacing: .04em;
  color: var(--steel);
  background: transparent;
  border: 1px dashed var(--line-2);
  border-radius: 10px;
  transition: color .2s, border-color .2s, background .2s;
}
body.stm-portal:not(.home):not(#stm-x) .stm-btn-reset:hover { color: var(--ink); background: var(--paper); border-color: var(--ink); }

/* mensajes vacíos / cargando */
body.stm-portal:not(.home):not(#stm-x) :is(.stm-grid, .stm-buscador-pedido__resultados) > :is(p, div):only-child:not(.stm-card):not(.stm-pedido-buscar-row),
body.stm-portal:not(.home):not(#stm-x) :is(.stm-informe-vacio, .stm-pedido-vacio, .stm-buscador-pedido__vacio) {
  grid-column: 1 / -1;
  margin: 0;
  padding: 40px 24px;
  text-align: center;
  font-size: 15px;
  color: var(--steel);
  background: repeating-linear-gradient(135deg, transparent 0 10px, rgba(18, 18, 20, .025) 10px 20px), var(--white);
  border: 1px dashed var(--line-2);
  border-radius: 16px;
}

/* ---------- REJILLA Y TARJETAS DE RESULTADOS ---------- */
body.stm-portal:not(.home):not(#stm-x) .stm-grid {
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 300px), 1fr));
  gap: 16px;
  margin: 24px 0 0;
  justify-content: stretch;
}
body.stm-portal:not(.home):not(#stm-x) :is(.stm-card--averia, .stm-card--repuesto, .stm-card--descarga, .stm-card--video) {
  --c: var(--c-averia);
  position: relative;
  display: flex;
  flex-direction: column;
  height: 100%;
  padding: 0;
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: 16px;
  box-shadow: 0 1px 0 rgba(18, 18, 20, .03);
  overflow: hidden;
  transition: transform .45s var(--ease-out), box-shadow .45s var(--ease-out), border-color .3s;
  animation: stm-p-card .7s var(--ease-out) both;
}
body.stm-portal:not(.home):not(#stm-x) .stm-card--repuesto { --c: var(--c-repuesto); }
body.stm-portal:not(.home):not(#stm-x) .stm-card--descarga { --c: var(--c-descarga); }
body.stm-portal:not(.home):not(#stm-x) .stm-card--video    { --c: #ec4899; }
body.stm-portal:not(.home):not(#stm-x) :is(.stm-card--averia, .stm-card--repuesto, .stm-card--descarga, .stm-card--video)::before {
  content: "";
  position: absolute;
  inset: 0 0 auto 0;
  height: 3px;
  background: var(--c);
  transform-origin: left;
  transform: scaleX(.18);
  transition: transform .6s var(--ease-out);
}
body.stm-portal:not(.home):not(#stm-x) :is(.stm-card--averia, .stm-card--repuesto, .stm-card--descarga, .stm-card--video):hover {
  transform: translateY(-4px);
  border-color: color-mix(in srgb, var(--c) 35%, var(--line));
  box-shadow: 0 28px 50px -30px rgba(18, 18, 20, .45);
}
body.stm-portal:not(.home):not(#stm-x) :is(.stm-card--averia, .stm-card--repuesto, .stm-card--descarga, .stm-card--video):hover::before { transform: scaleX(1); }
@keyframes stm-p-card { from { opacity: 0; transform: translateY(16px) scale(.985); } }
body.stm-portal:not(.home):not(#stm-x) .stm-grid > .stm-card:nth-child(2) { animation-delay: 50ms; }
body.stm-portal:not(.home):not(#stm-x) .stm-grid > .stm-card:nth-child(3) { animation-delay: 100ms; }
body.stm-portal:not(.home):not(#stm-x) .stm-grid > .stm-card:nth-child(4) { animation-delay: 150ms; }
body.stm-portal:not(.home):not(#stm-x) .stm-grid > .stm-card:nth-child(5) { animation-delay: 200ms; }
body.stm-portal:not(.home):not(#stm-x) .stm-grid > .stm-card:nth-child(6) { animation-delay: 250ms; }
body.stm-portal:not(.home):not(#stm-x) .stm-grid > .stm-card:nth-child(n+7) { animation-delay: 300ms; }

body.stm-portal:not(.home):not(#stm-x) .stm-card-body { padding: 24px 24px 22px; gap: 0; text-align: left; align-items: stretch; }
body.stm-portal:not(.home):not(#stm-x) .stm-card-body .stm-badge-categoria {
  align-self: flex-start;
  margin: 0 0 16px;
  padding: 5px 10px;
  font: 600 11px/1.2 var(--mono);
  letter-spacing: .08em;
  text-transform: uppercase;
  color: color-mix(in srgb, var(--c) 80%, #000);
  background: color-mix(in srgb, var(--c) 12%, transparent);
  border: 1px solid color-mix(in srgb, var(--c) 28%, transparent);
  border-radius: 999px;
}
body.stm-portal:not(.home):not(#stm-x) .stm-card-body h3 {
  margin: 0 0 10px;
  font: 700 19px/1.25 var(--display);
  letter-spacing: -.012em;
  color: var(--ink);
}
body.stm-portal:not(.home):not(#stm-x) .stm-card-body h3 a { color: var(--ink) !important; }
body.stm-portal:not(.home):not(#stm-x) .stm-card-body h3 a::after { content: ""; position: absolute; inset: 0; z-index: 0; }
body.stm-portal:not(.home):not(#stm-x) .stm-card-body :is(.stm-meta, .stm-meta p) {
  margin: 0 0 12px;
  font-size: 13.5px;
  line-height: 1.55;
  color: var(--steel);
}
body.stm-portal:not(.home):not(#stm-x) .stm-card-body .stm-meta strong { font: 600 11px/1 var(--mono); letter-spacing: .06em; text-transform: uppercase; color: var(--ink); }
body.stm-portal:not(.home):not(#stm-x) .stm-card-body > p { font-size: 14.5px; margin: 0 0 16px; }
body.stm-portal:not(.home):not(#stm-x) .stm-card-body .stm-precio {
  margin: 4px 0 0;
  font: 600 24px/1 var(--mono);
  letter-spacing: -.02em;
  color: var(--ink);
}
/* precio e IVA en el buscador de repuestos (vienen con estilos en línea) */
body.stm-portal:not(.home):not(#stm-x) .stm-card-body .stm-meta p[style*="stm-signal"] {
  margin: 14px 0 0 !important;
  font: 600 24px/1 var(--mono) !important;
  letter-spacing: -.02em;
  color: var(--ink) !important;
}
body.stm-portal:not(.home):not(#stm-x) .stm-card-body .stm-meta p[style*="#767676"] { margin: 6px 0 4px !important; font: 500 10.5px/1 var(--mono) !important; letter-spacing: .1em; color: var(--steel) !important; }
body.stm-portal:not(.home):not(#stm-x) .stm-card-body .stm-btn[style] { margin-top: auto !important; }
body.stm-portal:not(.home):not(#stm-x) .stm-card-body .stm-btn + .stm-btn-anadir-pedido { margin-top: 8px; }

/* miniatura de repuesto */
body.stm-portal:not(.home):not(#stm-x) .stm-card__thumbnail {
  position: relative;
  aspect-ratio: 16 / 10;
  margin: 0;
  padding: 18px;
  display: grid;
  place-items: center;
  overflow: hidden;
  background: radial-gradient(circle at 50% 40%, #fff, #f1f0ec);
  border: 0 !important;
  border-bottom: 1px solid var(--line) !important;
}
body.stm-portal:not(.home):not(#stm-x) .stm-card__thumbnail img {
  position: absolute;
  inset: 18px;
  width: calc(100% - 36px) !important;
  height: calc(100% - 36px) !important;
  object-fit: contain !important;
  mix-blend-mode: multiply;
  transition: transform .6s var(--ease-out);
}
body.stm-portal:not(.home):not(#stm-x) .stm-card:hover .stm-card__thumbnail img { transform: scale(1.05); }

body.stm-portal:not(.home):not(#stm-x) .stm-card-body .stm-iva-nota { margin: 6px 0 16px; font: 500 10.5px/1 var(--mono); letter-spacing: .1em; color: var(--steel); }

/* botones dentro de tarjetas */
body.stm-portal:not(.home):not(#stm-x) .stm-card-body :is(.stm-btn, .stm-boton) {
  position: relative;
  z-index: 1;
  margin-top: auto !important;
  width: 100%;
  height: 46px;
  padding: 0 16px;
  gap: 10px;
  font: 600 14px/1 var(--body);
  color: var(--white) !important;
  background: var(--ink) !important;
  border: 0 !important;
  border-radius: 10px;
  transition: background .25s, transform .25s var(--ease-out) !important;
}
body.stm-portal:not(.home):not(#stm-x) .stm-card-body :is(.stm-btn, .stm-boton):hover { background: var(--c) !important; }
body.stm-portal:not(.home):not(#stm-x) .stm-card-body .stm-boton + .stm-btn-anadir-pedido { margin-top: 8px; }

/* añadir a pedido (en tarjetas, fichas y búsqueda de pedidos) */
body.stm-portal:not(.home):not(#stm-x) :is(.stm-btn-anadir-pedido, .stm-btn-anadir-rapido) {
  position: relative;
  z-index: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  width: 100%;
  height: 46px;
  padding: 0 16px;
  font: 600 14px/1 var(--body);
  color: #0f766e !important;
  background: rgba(20, 184, 166, .08) !important;
  border: 1px solid rgba(20, 184, 166, .45) !important;
  border-radius: 10px !important;
  box-shadow: none !important;
  cursor: pointer;
  transition: background .25s, color .25s, transform .25s var(--ease-out) !important;
}
body.stm-portal:not(.home):not(#stm-x) :is(.stm-btn-anadir-pedido, .stm-btn-anadir-rapido):hover { color: #fff !important; background: var(--c-pedido) !important; transform: none !important; }
body.stm-portal:not(.home):not(#stm-x) :is(.stm-btn-anadir-pedido, .stm-btn-anadir-rapido):active { transform: scale(.98) !important; }

/* botón principal genérico */
body.stm-portal:not(.home):not(#stm-x) :is(#stm-informe-descargar, #stm-pedido-enviar, .ff-btn-submit, .wpdm-download-link, .stm-imprimir-wrapper button) {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  width: auto;
  min-height: 50px;
  padding: 0 26px;
  font: 700 15px/1 var(--display) !important;
  color: #fff !important;
  background: var(--signal) !important;
  border: 0 !important;
  border-radius: 10px !important;
  box-shadow: 0 12px 28px -12px rgba(200, 16, 46, .8) !important;
  cursor: pointer;
  transition: transform .3s var(--ease-out), box-shadow .3s, background .3s !important;
}
body.stm-portal:not(.home):not(#stm-x) :is(#stm-informe-descargar, #stm-pedido-enviar, .ff-btn-submit, .wpdm-download-link, .stm-imprimir-wrapper button):hover {
  transform: translateY(-2px) !important;
  background: #d91633 !important;
  box-shadow: 0 18px 36px -14px rgba(200, 16, 46, .9) !important;
}
body.stm-portal:not(.home):not(#stm-x) #stm-pedido-enviar:disabled { opacity: .45; cursor: not-allowed; transform: none !important; box-shadow: none !important; }
body.stm-portal:not(.home):not(#stm-x) .stm-imprimir-wrapper button:not(#stm-y) { color: var(--ink) !important; background: var(--white) !important; border: 1px solid var(--line-2) !important; box-shadow: none !important; }
body.stm-portal:not(.home):not(#stm-x) .stm-imprimir-wrapper button:not(#stm-y):hover { background: var(--ink) !important; color: #fff !important; box-shadow: none !important; }

/* ---------- INFORME DE REPUESTOS (tabla) ---------- */
body.stm-portal:not(.home):not(#stm-x) .stm-informe-repuestos { max-width: none; margin: 0; padding: 0; text-align: left; }
body.stm-portal:not(.home):not(#stm-x) .stm-text:has(.stm-informe-repuestos) { padding: 0; }
body.stm-portal:not(.home):not(#stm-x) .stm-informe-repuestos .stm-buscador__filtros select { flex: 1 1 320px; }
body.stm-portal:not(.home):not(#stm-x) .stm-informe-tabla :is(th, td) { vertical-align: middle; line-height: 1.4 !important; }
body.stm-portal:not(.home):not(#stm-x) .stm-informe-repuestos__resumen {
  margin: 18px 0 12px;
  font: 500 13px/1 var(--mono);
  letter-spacing: .06em;
  text-transform: uppercase;
  color: var(--steel);
}
body.stm-portal:not(.home):not(#stm-x) .stm-informe-repuestos__tabla-wrap {
  overflow: auto;
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: 16px;
  box-shadow: 0 24px 48px -40px rgba(18, 18, 20, .4);
}
body.stm-portal:not(.home):not(#stm-x) .stm-informe-tabla { width: 100%; margin: 0; border: 0; border-collapse: separate; border-spacing: 0; font-size: 14.5px; }
body.stm-portal:not(.home):not(#stm-x) .stm-informe-tabla th {
  position: sticky;
  top: 0;
  padding: 14px 18px;
  text-align: left;
  font: 600 11px/1 var(--mono);
  letter-spacing: .1em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, .85);
  background: var(--ink);
  border: 0;
}
body.stm-portal:not(.home):not(#stm-x) .stm-informe-tabla td {
  padding: 14px 18px;
  text-align: left;
  color: var(--ink);
  background: transparent;
  border: 0;
  border-top: 1px solid var(--line);
  transition: background .2s;
}
body.stm-portal:not(.home):not(#stm-x) .stm-informe-tabla td:first-child { font: 500 13px/1.3 var(--mono); color: var(--steel); }
body.stm-portal:not(.home):not(#stm-x) .stm-informe-tabla :is(th, td):nth-child(n+3) { text-align: right; font-variant-numeric: tabular-nums; }
body.stm-portal:not(.home):not(#stm-x) .stm-informe-tabla td:nth-child(3) { font: 600 14px/1 var(--mono); }
body.stm-portal:not(.home):not(#stm-x) .stm-informe-tabla tbody tr:nth-child(even) td { background: #fbfaf8; }
body.stm-portal:not(.home):not(#stm-x) .stm-informe-tabla tbody tr:hover td { background: color-mix(in srgb, var(--c-repuesto) 9%, #fff); }
body.stm-portal:not(.home):not(#stm-x) .stm-informe-fila-clicable { cursor: pointer; }

/* ---------- PEDIDOS ---------- */
body.stm-portal:not(.home):not(#stm-x) .stm-buscador-pedido {
  padding: 0;
  background: none;
  border: 0;
  box-shadow: none;
}
body.stm-portal:not(.home):not(#stm-x) .stm-buscador-pedido__cabecera {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px 16px;
  margin: 0 0 16px;
  padding: 0 !important;
  background: none !important;
  border: 0 !important;
  box-shadow: none !important;
}
body.stm-portal:not(.home):not(#stm-x) .stm-buscador-pedido__cabecera p { margin: 0; color: var(--steel); text-align: left; }
body.stm-portal:not(.home):not(#stm-x) .stm-buscador-pedido__badge {
  padding: 6px 12px;
  font: 600 11px/1.2 var(--mono);
  letter-spacing: .1em;
  text-transform: uppercase;
  color: #0f766e;
  background: rgba(20, 184, 166, .1);
  border: 1px solid rgba(20, 184, 166, .35);
  border-radius: 999px;
}
body.stm-portal:not(.home):not(#stm-x) .stm-buscador-pedido__resultados { display: grid; gap: 10px; margin-top: 16px; }
body.stm-portal:not(.home):not(#stm-x) .stm-pedido-buscar-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 16px 18px;
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: 14px;
  transition: border-color .25s, box-shadow .35s var(--ease-out);
  animation: stm-p-card .6s var(--ease-out) both;
}
body.stm-portal:not(.home):not(#stm-x) .stm-pedido-buscar-row:hover { border-color: rgba(20, 184, 166, .45); box-shadow: 0 18px 36px -28px rgba(18, 18, 20, .45); }
body.stm-portal:not(.home):not(#stm-x) .stm-pedido-buscar-info h4 { margin: 0 0 6px; font: 700 17px/1.25 var(--display); color: var(--ink); }
body.stm-portal:not(.home):not(#stm-x) .stm-pedido-buscar-meta { font-size: 13.5px; color: var(--steel); }
body.stm-portal:not(.home):not(#stm-x) .stm-pedido-buscar-meta code { padding: 2px 6px; font: 500 12px var(--mono); color: var(--ink); background: var(--paper); border-radius: 5px; }
body.stm-portal:not(.home):not(#stm-x) .stm-pedido-buscar-precio { font-family: var(--mono); color: var(--ink); }
body.stm-portal:not(.home):not(#stm-x) .stm-pedido-buscar-ficha { display: inline-block; margin-top: 8px; font: 600 12px var(--mono); letter-spacing: .04em; color: var(--steel) !important; text-decoration: none !important; }
body.stm-portal:not(.home):not(#stm-x) .stm-pedido-buscar-ficha:hover { color: var(--ink) !important; }
body.stm-portal:not(.home):not(#stm-x) .stm-pedido-buscar-accion { display: flex; align-items: center; gap: 10px; }
body.stm-portal:not(.home):not(#stm-x) .stm-pedido-buscar-accion .stm-btn-anadir-rapido { width: auto; padding: 0 18px; }
body.stm-portal:not(.home):not(#stm-x) :is(.stm-pedido-buscar-stepper, .stm-pedido-stepper, [class*="stepper"]) {
  display: inline-flex;
  align-items: center;
  height: 46px;
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 10px;
  overflow: hidden;
}
body.stm-portal:not(.home):not(#stm-x) .stm-cantidad-btn {
  width: 40px;
  height: 100%;
  padding: 0;
  font: 500 18px/1 var(--mono);
  color: var(--ink);
  background: transparent !important;
  border: 0 !important;
  box-shadow: none !important;
  transition: background .2s !important;
}
body.stm-portal:not(.home):not(#stm-x) .stm-cantidad-btn:hover { background: rgba(18, 18, 20, .06) !important; transform: none !important; }
body.stm-portal:not(.home):not(#stm-x) .stm-pedido-cantidad {
  width: 48px;
  height: 100%;
  padding: 0 !important;
  text-align: center;
  font: 600 15px var(--mono);
  background: transparent;
  border: 0 !important;
  border-radius: 0 !important;
  -moz-appearance: textfield;
}
body.stm-portal:not(.home):not(#stm-x) .stm-pedido-cantidad::-webkit-inner-spin-button { -webkit-appearance: none; }
body.stm-portal:not(.home):not(#stm-x) .stm-pedidos-separador { margin: clamp(40px, 5vw, 64px) 0; border: 0; border-top: 1px solid var(--line-2); }

body.stm-portal:not(.home):not(#stm-x) .stm-pedido-wrap {
  position: relative;
  padding: clamp(24px, 4vw, 48px);
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: 20px;
  box-shadow: 0 30px 60px -48px rgba(18, 18, 20, .5);
  overflow: hidden;
}
body.stm-portal:not(.home):not(#stm-x) .stm-pedido-wrap::before {
  content: "";
  position: absolute;
  inset: 0 0 auto 0;
  height: 4px;
  background: linear-gradient(90deg, var(--c-pedido), var(--signal));
}
/* líneas del pedido */
body.stm-portal:not(.home):not(#stm-x) .stm-pedido-items { display: grid; gap: 8px; }
body.stm-portal:not(.home):not(#stm-x) .stm-pedido-item {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 12px 12px 12px 18px;
  background: var(--paper);
  border: 1px solid transparent;
  border-radius: 12px;
  animation: stm-p-card .5s var(--ease-out) both;
}
body.stm-portal:not(.home):not(#stm-x) .stm-pedido-item-info { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 4px; }
body.stm-portal:not(.home):not(#stm-x) .stm-pedido-item-info a { font: 700 16px/1.25 var(--display); color: var(--ink) !important; text-decoration: none !important; }
body.stm-portal:not(.home):not(#stm-x) .stm-pedido-item-ref { font: 500 12px var(--mono); color: var(--steel); }
body.stm-portal:not(.home):not(#stm-x) .stm-pedido-item-cantidad { display: inline-flex; align-items: center; height: 44px; background: var(--white); border: 1px solid var(--line); border-radius: 10px; overflow: hidden; }
body.stm-portal:not(.home):not(#stm-x) .stm-pedido-quitar {
  flex: none;
  width: 40px;
  height: 40px;
  padding: 0 !important;
  font-size: 14px;
  color: var(--steel);
  background: transparent !important;
  border: 1px solid var(--line-2) !important;
  border-radius: 50% !important;
  box-shadow: none !important;
  transition: color .2s, background .2s, border-color .2s !important;
}
body.stm-portal:not(.home):not(#stm-x) .stm-pedido-quitar:hover { color: #fff; background: var(--signal) !important; border-color: var(--signal) !important; transform: none !important; }

body.stm-portal:not(.home):not(#stm-x) .stm-pedido-wrap > h2 { margin: 0 0 20px; font: 800 clamp(24px, 2.4vw, 32px)/1.1 var(--display); letter-spacing: -.02em; color: var(--ink); }
body.stm-portal:not(.home):not(#stm-x) #stm-pedido-form {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 20px 28px;
  margin-top: 28px;
  padding-top: 28px;
  border-top: 1px solid var(--line);
}
body.stm-portal:not(.home):not(#stm-x) #stm-pedido-form > :is(#stm-bloque-cliente, .stm-campo:has(textarea#stm-nota), button, input[type="hidden"]) { grid-column: 1 / -1; }
body.stm-portal:not(.home):not(#stm-x) #stm-pedido-form > button { justify-self: start; }

/* campos de formulario (pedidos y registro de avería) */
body.stm-portal:not(.home):not(#stm-x) .stm-campo { display: flex; flex-direction: column; gap: 8px; margin: 0; }
body.stm-portal:not(.home):not(#stm-x) :is(.stm-campo > label, .stm-campo > label[for], .ff-el-input--label label) {
  margin: 0;
  font: 600 11.5px/1.3 var(--mono) !important;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--ink) !important;
}
body.stm-portal:not(.home):not(#stm-x) .stm-campo > label:not(:first-child) { margin-top: 10px; }
body.stm-portal:not(.home):not(#stm-x) :is(.stm-campo input[type="text"], .stm-campo select, .stm-campo textarea, .ff-el-form-control) {
  width: 100%;
  min-height: 50px;
  padding: 12px 16px !important;
  font: 500 15px/1.4 var(--body) !important;
  color: var(--ink) !important;
  background: var(--paper) !important;
  border: 1px solid transparent !important;
  border-radius: 10px !important;
  box-shadow: none !important;
  transition: border-color .2s, background .2s, box-shadow .2s !important;
}
body.stm-portal:not(.home):not(#stm-x) :is(.stm-campo textarea, textarea.ff-el-form-control) { min-height: 110px; resize: vertical; }
body.stm-portal:not(.home):not(#stm-x) :is(.stm-campo input[type="text"], .stm-campo select, .stm-campo textarea, .ff-el-form-control):hover { background: #efeee9 !important; }
body.stm-portal:not(.home):not(#stm-x) :is(.stm-campo input[type="text"], .stm-campo select, .stm-campo textarea, .ff-el-form-control):focus {
  outline: none;
  background: var(--white) !important;
  border-color: var(--accent) !important;
  box-shadow: 0 0 0 4px color-mix(in srgb, var(--accent) 16%, transparent) !important;
}

/* grupos de opciones como botones segmentados */
body.stm-portal:not(.home):not(#stm-x) .stm-radio-grupo { display: flex; flex-wrap: wrap; gap: 8px; }
body.stm-portal:not(.home):not(#stm-x) .stm-radio-grupo > label {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-height: 46px;
  margin: 0;
  padding: 0 16px 0 14px;
  font: 500 14.5px/1.2 var(--body) !important;
  letter-spacing: 0;
  text-transform: none;
  color: var(--ink) !important;
  background: var(--paper);
  border: 1px solid transparent;
  border-radius: 10px;
  cursor: pointer;
  transition: background .2s, border-color .2s, color .2s;
}
body.stm-portal:not(.home):not(#stm-x) .stm-radio-grupo > label:hover { background: #efeee9; }
body.stm-portal:not(.home):not(#stm-x) .stm-radio-grupo input[type="radio"] {
  appearance: none;
  -webkit-appearance: none;
  flex: none;
  width: 18px;
  height: 18px;
  margin: 0;
  border: 1.5px solid var(--line-2);
  border-radius: 50%;
  background: var(--white);
  transition: border-color .2s, box-shadow .2s;
}
body.stm-portal:not(.home):not(#stm-x) .stm-radio-grupo > label:has(input:checked) {
  color: var(--ink) !important;
  background: var(--white);
  border-color: var(--accent);
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--accent) 14%, transparent);
}
body.stm-portal:not(.home):not(#stm-x) .stm-radio-grupo input[type="radio"]:checked { border-color: var(--accent); box-shadow: inset 0 0 0 4px var(--white), inset 0 0 0 9px var(--accent); }
body.stm-portal:not(.home):not(#stm-x) .stm-radio-grupo input[type="radio"]:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }

/* ---------- REGISTRO DE AVERÍA (Fluent Forms) ---------- */
body.stm-portal:not(.home):not(#stm-x) .fluentform {
  max-width: 880px;
  padding: clamp(24px, 4vw, 48px);
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: 20px;
  box-shadow: 0 30px 60px -48px rgba(18, 18, 20, .5);
  position: relative;
  overflow: hidden;
}
body.stm-portal:not(.home):not(#stm-x) .fluentform::before {
  content: "";
  position: absolute;
  inset: 0 0 auto 0;
  height: 4px;
  background: linear-gradient(90deg, var(--c-registro), var(--signal));
}
body.stm-portal:not(.home):not(#stm-x) .fluentform .ff-el-group { margin-bottom: 20px; }
body.stm-portal:not(.home):not(#stm-x) .fluentform .ff-el-input--label { margin-bottom: 8px; }
body.stm-portal:not(.home):not(#stm-x) .fluentform .ff-el-is-required.asterisk-right label::after { color: var(--signal); }
body.stm-portal:not(.home):not(#stm-x) .fluentform .ff-t-container { gap: 20px; }
body.stm-portal:not(.home):not(#stm-x) .fluentform .ff_submit_btn_wrapper { margin-top: 8px; }

/* ---------- ASISTENTE IA ---------- */
body.stm-portal:not(.home):not(#stm-x) .mwai-chatbot-container {
  max-width: 980px;
  margin-inline: auto;
  --mwai-accentColor: var(--c-ia);
  --mwai-fontSize: 15px;
  --mwai-borderRadius: 14px;
}
body.stm-portal:not(.home):not(#stm-x) .mwai-chatbot-container .mwai-chat:not(.mwai-window) .mwai-window-box,
body.stm-portal:not(.home):not(#stm-x) .mwai-chatbot-container .mwai-chat:not(.mwai-window) {
  border-radius: 20px;
  overflow: hidden;
  box-shadow: 0 40px 80px -50px rgba(18, 18, 20, .6);
  border: 1px solid var(--line);
}
body.stm-portal:not(.home):not(#stm-x) .mwai-chatbot-container .mwai-conversation { min-height: 360px; }
body.stm-portal:not(.home):not(#stm-x) .mwai-chatbot-container .mwai-gdpr-buttons button {
  min-height: 44px;
  font: 600 14px/1 var(--body);
  color: #fff !important;
  background: var(--c-ia) !important;
  border: 0 !important;
  border-radius: 10px !important;
  transition: filter .2s !important;
}
body.stm-portal:not(.home):not(#stm-x) .mwai-chatbot-container .mwai-gdpr-buttons button:hover { filter: brightness(1.12); transform: none !important; box-shadow: none !important; }

/* ---------- FICHAS DE AVERÍA Y REPUESTO ---------- */
body.stm-portal:not(.home):not(#stm-x) :is(.stm-averia-article, .stm-repuesto-article) { background: none; border: 0; box-shadow: none; padding: 0; }
body.stm-portal:not(.home):not(#stm-x) :is(.stm-averia-body, .stm-repuesto-body) {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
  align-items: start;
  padding: 0 !important;
  background: none !important;
  border: 0 !important;
  box-shadow: none !important;
}
body.stm-portal:not(.home):not(#stm-x) :is(.stm-averia-body, .stm-repuesto-body) > :is(.stm-averia-row:empty) { display: none; }
body.stm-portal:not(.home):not(#stm-x) :is(.stm-averia-body, .stm-repuesto-body) > :is(.stm-averia-row, .stm-imprimir-wrapper) { grid-column: 1 / -1; }
body.stm-portal:not(.home):not(#stm-x) :is(.stm-avcard, .stm-repcard) {
  --c: var(--accent);
  position: relative;
  margin: 0;
  padding: clamp(22px, 3vw, 34px);
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: 18px;
  box-shadow: 0 24px 48px -40px rgba(18, 18, 20, .45);
  overflow: hidden;
  animation: stm-p-card .7s var(--ease-out) both;
}
body.stm-portal:not(.home):not(#stm-x) :is(.stm-avcard, .stm-repcard)::before {
  content: "";
  position: absolute;
  inset: 0 auto 0 0;
  width: 4px;
  background: var(--c);
}
body.stm-portal:not(.home):not(#stm-x) .stm-avcard--solucion { --c: #16a34a; animation-delay: .08s; }
body.stm-portal:not(.home):not(#stm-x) .stm-repcard--notas { animation-delay: .08s; }
body.stm-portal:not(.home):not(#stm-x) :is(.stm-avcard, .stm-repcard) h3 {
  margin: 0 0 14px;
  font: 700 12px/1.2 var(--mono);
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--steel);
}
body.stm-portal:not(.home):not(#stm-x) :is(.stm-avcard, .stm-repcard) p { font-size: 16px; line-height: 1.7; color: var(--ink); }
body.stm-portal:not(.home):not(#stm-x) .stm-avcard--solucion p:first-of-type { font-size: 17px; }
body.stm-portal:not(.home):not(#stm-x) .stm-repuesto-imagen { margin: 0 0 20px; padding: 16px; background: var(--paper); border: 0 !important; border-radius: 12px; text-align: center; }
body.stm-portal:not(.home):not(#stm-x) .stm-repuesto-imagen img { max-height: 260px; width: auto; object-fit: contain; }
body.stm-portal:not(.home):not(#stm-x) .stm-repuesto-datos p { display: flex; justify-content: space-between; gap: 16px; margin: 0; padding: 10px 0; border-bottom: 1px solid var(--line); font-size: 14.5px; }
body.stm-portal:not(.home):not(#stm-x) .stm-repuesto-datos p strong { font: 600 11px/1.6 var(--mono); letter-spacing: .08em; text-transform: uppercase; color: var(--steel); }
body.stm-portal:not(.home):not(#stm-x) .stm-repuesto-ref { font-family: var(--mono); }
body.stm-portal:not(.home):not(#stm-x) .stm-repuesto-datos .stm-repuesto-precio { justify-content: flex-start; padding-top: 18px; border: 0; font: 600 30px/1 var(--mono); letter-spacing: -.02em; color: var(--ink); }
body.stm-portal:not(.home):not(#stm-x) .stm-repuesto-datos .stm-repuesto-iva-nota { justify-content: flex-start; padding: 6px 0 18px; border: 0; font: 500 10.5px/1 var(--mono); letter-spacing: .1em; color: var(--steel); }
body.stm-portal:not(.home):not(#stm-x) .stm-imprimir-wrapper { margin-top: 8px; text-align: left; }

/* ---------- FICHA DE DESCARGA (WP Download Manager) ---------- */
body.stm-portal.single-wpdmpro:not(#stm-x) .w3eden .row { display: grid; grid-template-columns: minmax(0, 380px) minmax(0, 1fr); gap: 24px; margin: 0; }
body.stm-portal.single-wpdmpro:not(#stm-x) .w3eden .row > [class*="col-"] { width: auto; max-width: none; padding: 0; flex: none; }
body.stm-portal.single-wpdmpro:not(#stm-x) .w3eden .row > .col-md-12:not(:has(*)) { display: none; }
body.stm-portal.single-wpdmpro:not(#stm-x) .w3eden .row > .col-md-5:only-of-type,
body.stm-portal.single-wpdmpro:not(#stm-x) .w3eden .row:not(:has(.col-md-7 *)) { grid-template-columns: minmax(0, 480px); }
body.stm-portal.single-wpdmpro:not(#stm-x) .w3eden .row > .col-md-7:not(:has(*)) { display: none; }
body.stm-portal.single-wpdmpro:not(#stm-x) .w3eden .list-group {
  overflow: hidden;
  background: var(--white) !important;
  border: 1px solid var(--line) !important;
  border-radius: 16px !important;
}
body.stm-portal.single-wpdmpro:not(#stm-x) .w3eden .list-group-item {
  padding: 14px 18px;
  font-size: 14px;
  color: var(--steel);
  background: transparent !important;
  border: 0 !important;
  border-top: 1px solid var(--line) !important;
  border-radius: 0 !important;
}
body.stm-portal.single-wpdmpro:not(#stm-x) .w3eden .list-group-item:first-child { border-top: 0 !important; }
body.stm-portal.single-wpdmpro:not(#stm-x) .w3eden .list-group-item .badge { font: 600 12.5px var(--mono); color: var(--ink) !important; background: var(--paper) !important; border-radius: 6px !important; padding: 5px 8px; }
body.stm-portal.single-wpdmpro:not(#stm-x) .w3eden .wpdm-button-area .wpdm-download-link { width: 100%; min-height: 56px; font-size: 16px !important; letter-spacing: .02em; }
body.stm-portal.single-wpdmpro:not(#stm-x) .w3eden .wpdm-button-area { margin-bottom: 16px !important; }
body.stm-portal.single-wpdmpro:not(#stm-x) .w3eden .wpdm-button-area .wpdm-download-link { display: flex !important; width: 100% !important; }
body.stm-portal.single-wpdmpro:not(#stm-x) .w3eden .col-md-7 { align-self: start; padding: clamp(22px, 3vw, 34px) !important; font-size: 16px; line-height: 1.7; color: var(--ink); background: var(--white); border: 1px solid var(--line); border-radius: 16px; }
body.stm-portal.single-wpdmpro:not(#stm-x) .w3eden .col-md-7 > :is(h1, h2, h3):first-child { display: none; }
body.stm-portal.single-wpdmpro:not(#stm-x) .w3eden .col-md-7::before { content: "Descripción"; display: block; margin-bottom: 12px; font: 600 12px/1 var(--mono); letter-spacing: .1em; text-transform: uppercase; color: var(--steel); }

/* ---------- FICHA DE MÁQUINA ---------- */
body.stm-portal.single-maquinas:not(#stm-x) .stm-single > .stm-band { padding: 0; }
body.stm-portal.single-maquinas:not(#stm-x) .stm-ficha-pro {
  width: var(--container);
  max-width: none;
  margin: 0 auto;
  padding: clamp(36px, 5vw, 64px) 0 clamp(56px, 7vw, 104px);
  background: none !important;
  border: 0 !important;
  border-radius: 0 !important;
  box-shadow: none !important;
}
body.stm-portal.single-maquinas:not(#stm-x) .stm-ficha-pro__grain { display: none; }
body.stm-portal.single-maquinas.stm-has-hero .stm-ficha-pro > .stm-hero { display: none; }
body.stm-portal.single-maquinas:not(#stm-x) .stm-summary {
  position: sticky;
  top: calc(var(--admin-bar, 0px) + 12px);
  z-index: 5;
  margin: 0 0 28px;
  padding: 10px;
  background: rgba(255, 255, 255, .86);
  backdrop-filter: blur(12px);
  border: 1px solid var(--line);
  border-radius: 16px;
  box-shadow: 0 20px 40px -32px rgba(18, 18, 20, .5);
}
body.stm-portal.single-maquinas:not(#stm-x) .stm-summary__item { border-radius: 10px !important; }
body.stm-portal.single-maquinas:not(#stm-x) .stm-sections > .stm-card {
  border-radius: 18px;
  border: 1px solid var(--line);
  box-shadow: 0 24px 48px -40px rgba(18, 18, 20, .45);
}
body.stm-portal.single-maquinas:not(#stm-x) .stm-card__body .stm-grid { grid-template-columns: 1fr; gap: 10px; margin-top: 4px; }
body.stm-portal.single-maquinas:not(#stm-x) .stm-card__body .stm-grid > .stm-card {
  padding: 0 !important;
  background: var(--white) !important;
  border: 1px solid var(--line) !important;
  border-radius: 14px !important;
  box-shadow: none !important;
}
body.stm-portal.single-maquinas:not(#stm-x) .stm-card__body .stm-grid > .stm-card::after { display: none; }
body.stm-portal.single-maquinas:not(#stm-x) .stm-card__body .stm-grid > .stm-card::before { inset: 0 0 auto 0 !important; width: auto !important; height: 3px !important; border-radius: 0 !important; }
body.stm-portal.single-maquinas:not(#stm-x) .stm-card__body .stm-card-body { padding: 18px 20px !important; }
body.stm-portal.single-maquinas:not(#stm-x) .stm-card__body .stm-card-body :is(.stm-btn, .stm-boton) { height: 42px; }
body.stm-portal.single-maquinas:not(#stm-x) .stm-card__title { font-family: var(--display); font-weight: 800; }
body.stm-portal.single-maquinas:not(#stm-x) .stm-card__count { font-family: var(--mono); }

/* ---------- PIE DE PÁGINA ---------- */
body.stm-portal .ct-footer { position: relative; }
body.stm-portal .ct-footer::before {
  content: "";
  position: absolute;
  inset: 0 0 auto 0;
  height: 2px;
  background: linear-gradient(90deg, transparent, var(--signal) 30%, var(--signal) 70%, transparent);
  opacity: .8;
}
body.stm-portal .ct-footer-copyright { font-family: var(--mono); font-size: 12px; letter-spacing: .08em; text-transform: uppercase; opacity: .7; }

/* ---------- Aparición al hacer scroll ---------- */
body.stm-portal:not(.home):not(#stm-x) [data-stm-reveal] { opacity: 0; transform: translateY(24px); transition: opacity .8s var(--ease-out), transform .8s var(--ease-out); }
body.stm-portal:not(.home):not(#stm-x) [data-stm-reveal].is-in { opacity: 1; transform: none; }

/* ---------- Responsive ---------- */
@media (max-width: 900px) {
  .stm-portal .stm-page-hero--media .stm-page-hero__inner { grid-template-columns: 1fr; }
  .stm-portal .stm-page-hero__media { max-width: 520px; }
  .stm-portal .stm-page-hero__icon { opacity: .08; top: 24px; translate: 0; }
  body.stm-portal:not(.home):not(#stm-x) :is(.stm-averia-body, .stm-repuesto-body) { grid-template-columns: 1fr; }
  body.stm-portal.single-wpdmpro:not(#stm-x) .w3eden .row { grid-template-columns: 1fr; }
}
@media (max-width: 720px) {
  .stm-portal .stm-page-hero { padding: 36px 0 44px; }
  .stm-portal .stm-page-hero h1 { margin-top: 18px; }
  .stm-portal .stm-page-hero__meta > * { font-size: 12px; }
  body.stm-portal:not(.home):not(#stm-x) :is(.stm-buscador__filtros, .stm-buscador-pedido__filtros) { padding: 10px; border-radius: 14px; }
  body.stm-portal:not(.home):not(#stm-x) :is(.stm-buscador__filtros, .stm-buscador-pedido__filtros) :is(input, select, .stm-btn-reset) { flex: 1 1 100%; }
  body.stm-portal:not(.home):not(#stm-x) #stm-pedido-form { grid-template-columns: 1fr; }
  body.stm-portal:not(.home):not(#stm-x) #stm-pedido-form > button { justify-self: stretch; }
  body.stm-portal:not(.home):not(#stm-x) .stm-pedido-buscar-accion { width: 100%; }
  body.stm-portal:not(.home):not(#stm-x) .stm-pedido-buscar-accion .stm-btn-anadir-rapido { flex: 1; }
  body.stm-portal:not(.home):not(#stm-x) .stm-radio-grupo > label { flex: 1 1 100%; }
  body.stm-portal:not(.home):not(#stm-x) #stm-informe-descargar { width: 100%; }
  body.stm-portal:not(.home):not(#stm-x) .stm-informe-tabla { font-size: 13.5px; }
  body.stm-portal:not(.home):not(#stm-x) .stm-informe-tabla :is(th, td) { padding: 12px; }
  body.stm-portal.single-maquinas:not(#stm-x) .stm-summary { position: static; }
}
@media (prefers-reduced-motion: reduce) {
  body.stm-portal:not(.home):not(#stm-x) *, body.stm-portal:not(.home):not(#stm-x) *::before, body.stm-portal:not(.home):not(#stm-x) *::after { animation: none !important; transition-duration: .01ms !important; }
  body.stm-portal:not(.home):not(#stm-x) [data-stm-reveal] { opacity: 1; transform: none; }
}

/* ---------- Impresión (fichas de avería/repuesto) ---------- */
@media print {
  .stm-portal .stm-page-hero { color: #000; background: none; padding: 0 0 16px; }
  .stm-portal .stm-page-hero::before, .stm-portal .stm-page-hero::after, .stm-portal .stm-page-hero__icon, .stm-portal .stm-crumbs { display: none; }
  .stm-portal .stm-page-hero h1, .stm-portal .stm-page-hero__lead, .stm-portal .stm-page-hero__meta > * { color: #000 !important; }
}
