.at-ficha {
  --at-ficha-margen: var(--at-margen-pagina, 16px);
  --at-ficha-columna: min(1440px, calc(100% - var(--at-ficha-margen) * 2));
  position: relative;
  display: grid;
  grid-template-columns: minmax(var(--at-ficha-margen), 1fr) var(--at-ficha-columna) minmax(var(--at-ficha-margen), 1fr);
  width: 100%;
  color: #000;
  font-family: var(--at-fuente-cuerpo, Inter, sans-serif);
  font-size: 14px;
  font-weight: 400;
  line-height: 1.6;
}
@media (min-width: 750px) {
  .at-ficha { --at-ficha-margen: var(--at-margen-pagina, 40px); }
}

.at-ficha__saltar {
  position: absolute;
  left: -99999px;
  top: 0;
  z-index: 10;
  padding: 16px 24px;
  border-radius: 14px;
  background: #fff;
  color: #000;
}
.at-ficha__saltar:focus { left: var(--at-ficha-margen); }

.at-ficha__rejilla {
  display: grid;
  grid-template-columns: subgrid;
  grid-column: 1 / -1;
}
.at-ficha__medios { order: 0; grid-column: 1 / -1; width: 0; min-width: 100%; }
.at-ficha__detalles { order: 1; grid-column: 2 / 3; display: flex; align-self: start; justify-content: center; }

@media (min-width: 750px) {
  .at-ficha__rejilla { grid-column: 2; grid-template-columns: 1fr min(50vw, 25rem); }
  .at-ficha__medios { grid-column: auto; padding-right: calc(var(--at-ficha-hueco, 48px) / 2); }
  .at-ficha__detalles {
    grid-column: auto;
    padding-left: calc(var(--at-ficha-hueco, 48px) / 2);
    position: sticky;
    top: 0;
    z-index: 1;
  }
}
@media (min-width: 1200px) {
  .at-ficha__rejilla { grid-template-columns: 2fr 1fr; }
}

.at-ficha__columna {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: var(--at-ficha-hueco-detalles, 24px);
  width: 100%;
  padding-block: 20px;
}
@media (min-width: 990px) {
  .at-ficha__columna { gap: var(--at-ficha-hueco-detalles, 28px); padding-block: 24px; }
}

.at-ficha__titulo { display: flex; flex-direction: column; width: 100%; }
.at-ficha__titulo h1 {
  width: 100%;
  max-inline-size: min(100%, 32.5em);
  margin: 0;
  color: #000;
  font-family: var(--at-fuente-titulo, Inter, sans-serif);
  font-size: 32px;
  font-weight: 700;
  font-style: normal;
  line-height: 1.1;
  letter-spacing: 0;
  text-transform: none;
  text-align: left;
  text-wrap: balance;
  overflow-wrap: break-word;
}

.at-ficha__divisor { width: 100%; height: 1px; background: var(--at-borde, #dfdfdf); }

:where(.at-ficha__columna) a {
  color: currentColor;
  text-decoration-color: transparent;
  text-decoration-thickness: .075em;
  text-underline-offset: .125em;
  transition: text-decoration-color .125s ease-in-out, color .125s ease-in-out;
}
:where(.at-ficha__columna) summary {
  display: flex;
  align-items: center;
  padding-block: 11.2px;
  list-style: none;
  cursor: pointer;
}
:where(.at-ficha__columna) summary::-webkit-details-marker { display: none; }
:where(.at-ficha__columna) img { width: 100%; height: auto; }
:where(.at-ficha__columna, #nct-sticky-atc, #nct-toast) button { font: revert; color: revert; }
:where(.at-ficha__columna) p:empty { display: none; }
:where(.at-ficha__columna) :is(p, h1, h2, h3, h4, h5, h6) { overflow-wrap: break-word; }
:where(.at-ficha__columna) :is(p, h1, h2, h3, h4, h5, h6):first-child { margin-block-start: 0; }
:where(.at-ficha__columna) :is(p, h1, h2, h3, h4, h5, h6):last-child { margin-block-end: 0; }
:where(.at-ficha__columna) p:not(.h1, .h2, .h3, .h4, .h5, .h6) a:where(:not(.at-boton)) { text-decoration-color: currentColor; }

.at-compra { display: block; }
.at-compra__formulario { display: block; margin: 0; }
.at-compra__botones { display: flex; flex-direction: column; gap: 5.6px; }
@media (min-width: 750px) { .at-compra__botones { gap: 11.2px; } }
.at-compra__cantidad { display: flex; gap: 11.2px; }
.at-compra__boton {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 4.8px;
  width: 100%;
  height: 52px;
  padding: 16px 24px;
  border: 0;
  border-radius: var(--at-boton-radio, 14px);
  background: #000;
  color: #fff;
  font-family: var(--at-fuente-cuerpo, Inter, sans-serif);
  font-size: 14px;
  font-weight: 400;
  line-height: 1.6;
  text-align: center;
  text-decoration: none;
  cursor: pointer;
  transition: background-color .125s ease-in-out, color .125s ease-in-out;
}
.at-compra__boton[aria-busy="true"] { cursor: progress; }
.at-compra__acelerado { display: block; }
.at-compra__acelerado:empty { display: block; }

.at-cantidad {
  display: flex;
  align-items: center;
  height: 52px;
  border: 1px solid var(--at-borde, #dfdfdf);
  border-radius: 14px;
  background: #fff;
  color: #333;
}
.at-cantidad__boton {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  padding: 0;
  border: 0;
  background: none;
  color: inherit;
  cursor: pointer;
}
.at-cantidad__boton[disabled] { opacity: .5; cursor: not-allowed; }
.at-cantidad__campo {
  width: 3ch;
  padding: 1px 2px;
  border: 0;
  background: none;
  color: inherit;
  font: inherit;
  text-align: center;
  -moz-appearance: textfield;
  appearance: textfield;
}
.at-cantidad__campo::-webkit-inner-spin-button,
.at-cantidad__campo::-webkit-outer-spin-button { -webkit-appearance: none; margin: 0; }

.at-ficha__descripcion {
  display: flex;
  flex-direction: column;
  width: 100%;
  max-width: 100%;
  color: #000;
  text-wrap: pretty;
}
.at-ficha__descripcion > * {
  width: 100%;
  max-inline-size: min(100%, 32.5em);
  text-align: left;
}
.at-ficha__descripcion :is(ul, ol) { margin-block-start: 0; padding-inline-start: 1.5em; }
.at-ficha__descripcion ul:not(li ul),
.at-ficha__descripcion ol:not(li ol) { margin-block-end: 1em; }
.at-ficha__descripcion :is(p, h1, h2, h3, h4, h5, h6):first-child,
.at-ficha__descripcion :empty:first-child + :is(p, h1, h2, h3, h4, h5, h6) { margin-block-start: 0; }
.at-ficha__descripcion :is(p, ul, ol, table):not(.h1, .h2, .h3, .h4, .h5, .h6) a:where(:not(.at-boton)) { text-decoration-color: currentColor; }
.at-ficha__descripcion :is(h1, h2, h3, h4, h5, h6) { margin-block: .25em; }
.at-ficha__descripcion p { margin-block: .5em; }
.at-ficha__descripcion.at-ficha__descripcion > :last-child { margin-block-end: 0; }
.at-ficha__descripcion.at-ficha__descripcion > style + *,
.at-ficha__descripcion.at-ficha__descripcion > :first-child { margin-block-start: 0; }

.at-galeria { position: sticky; top: 0; z-index: 1; display: block; }
.at-galeria__carrusel { position: relative; display: flex; flex-direction: column; }
.at-galeria__marco { position: relative; display: block; overflow: hidden; background: #fff; }
.at-galeria__pista {
  position: relative;
  display: flex;
  overflow-x: auto;
  overflow-y: hidden;
  scroll-snap-type: x mandatory;
  scrollbar-width: none;
  overscroll-behavior-x: contain;
}
/* Drip: como su carrusel de Horizon con «proporción: adaptar», todas las fotos toman el alto de la más alta (la tabla
   de talles es 4:5) y quedan centradas, sin tope por el alto de la pantalla; en el celular, puntos sobre el pie de la
   foto en vez de miniaturas. */
.at-galeria__foto, .at-galeria__foto img { aspect-ratio: var(--at-galeria-proporcion, 1) !important; }
.at-galeria .at-galeria__foto { max-height: none; }
@media (min-width: 750px) { .at-galeria__puntos { display: none; } }
@media (max-width: 749px) {
  .at-galeria .at-galeria__controles { display: none; }
  .at-galeria__puntos { position: absolute; left: 0; right: 0; bottom: 14px; display: flex; justify-content: center; gap: 2px; }
}
.at-galeria__punto { width: 18px; height: 18px; padding: 0; border: 0; background: none; cursor: pointer; display: inline-flex; align-items: center; justify-content: center; }
.at-galeria__punto span { display: block; width: 8px; height: 8px; border-radius: 50%; background: rgb(0 0 0 / .2); font-size: 0; color: transparent; overflow: hidden; }
.at-galeria__punto[aria-selected="true"] span { background: #000; }
.at-galeria__pista::-webkit-scrollbar { display: none; }
.at-galeria__foto {
  position: relative;
  display: flex;
  flex: 0 0 auto;
  width: 100%;
  width: round(up, 100%, 1px);
  aspect-ratio: 1;
  margin-inline: auto;
  overflow: hidden;
  scroll-snap-align: start;
  scroll-snap-stop: always;
  cursor: zoom-in;
}
.at-galeria__foto img {
  display: block;
  width: 100%;
  height: 100%;
  aspect-ratio: 1;
  object-fit: contain;
  object-position: center center;
  background: #fff;
}
@media (min-width: 750px) {
  .at-galeria__foto { max-height: max(500px, calc(100vh - var(--at-alto-encabezado, 66px))); }
}

.at-galeria__flechas {
  position: absolute;
  inset: 0;
  z-index: 4;
  display: none;
  align-items: center;
  justify-content: space-between;
  pointer-events: none;
  mix-blend-mode: difference;
}
@media (min-width: 750px) { .at-galeria__flechas { display: flex; } }
.at-galeria__flecha {
  position: relative;
  display: block;
  width: 44px;
  height: 44px;
  padding: 0;
  border: 0;
  background: none;
  color: #fff;
  cursor: pointer;
  pointer-events: auto;
}
.at-galeria__flecha--anterior { transform: scaleX(-1); }
.at-galeria__flecha .at-icono { position: absolute; top: 8.8px; left: 5.6px; width: 20px; height: 20px; }

.at-galeria__controles {
  display: flex;
  flex-shrink: 0;
  width: 100%;
  min-height: 44px;
  overflow-x: auto;
  overflow-y: hidden;
  scrollbar-width: none;
}
.at-galeria__controles::-webkit-scrollbar { display: none; }
.at-galeria__controles[data-at-desborda] {
  --at-bb-mascara: linear-gradient(to right,
    transparent min(var(--at-bb-avance, 0%) * 100, 1%),
    #000 min(var(--at-bb-avance, 0%), 10%),
    #000 max(var(--at-bb-avance, 0%), 90%),
    transparent 100%);
  -webkit-mask-image: var(--at-bb-mascara);
  mask-image: var(--at-bb-mascara);
}
.at-galeria__miniaturas {
  display: flex;
  flex-shrink: 0;
  gap: 8px;
  height: fit-content;
  margin-inline: auto;
  padding: 11.2px;
}
.at-galeria__miniatura {
  position: relative;
  display: block;
  flex: 0 0 auto;
  width: 44px;
  height: 44px;
  padding: 0;
  overflow: hidden;
  border: 0;
  border-radius: 0;
  background: none;
  color: #000;
  cursor: pointer;
}
.at-galeria__miniatura img { display: block; width: 100%; height: 100%; object-fit: cover; object-position: 50% 50%; }
.at-galeria__miniatura[aria-selected="true"] { outline: 1.5px solid currentColor; outline-offset: 1.4px; }

.at-zoom {
  position: fixed;
  inset: 0;
  width: 100vw;
  max-width: 100vw;
  height: 100dvh;
  max-height: 100dvh;
  margin: 0;
  padding: 0;
  border: 0;
  background: #fff;
  color: #000;
  overflow: hidden;
}
.at-zoom::backdrop { background: rgb(0 0 0 / .15); }
.at-zoom[open] { display: block; }
.at-zoom__lista {
  height: 100%;
  margin: 0;
  padding: 0;
  overflow-y: auto;
  list-style: none;
  scrollbar-width: none;
}
.at-zoom__lista::-webkit-scrollbar { display: none; }
.at-zoom__foto { display: block; width: 100%; cursor: zoom-out; }
.at-zoom__foto img { display: block; width: 100%; height: auto; }
.at-zoom__cerrar {
  position: absolute;
  top: 13px;
  right: 13px;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 50px;
  height: 50px;
  padding: 0;
  border: 1px solid #000;
  border-radius: 50%;
  background: #fff;
  color: #000;
  cursor: pointer;
}
.at-zoom__cerrar .at-icono { width: 13.6px; height: 13.6px; }
.at-zoom__miniaturas {
  position: fixed;
  top: 50%;
  right: 0;
  z-index: 2;
  display: flex;
  flex-direction: column;
  gap: 8px;
  width: 76px;
  max-height: 80vh;
  padding: 16px;
  overflow-y: auto;
  transform: translateY(-50%);
  scrollbar-width: none;
}
.at-zoom__miniatura {
  display: block;
  flex: 0 0 auto;
  width: 44px;
  height: 44px;
  padding: 0;
  border: 0;
  background: none;
  color: #000;
  cursor: pointer;
}
.at-zoom__miniatura img { display: block; width: 100%; height: 100%; object-fit: cover; }
.at-zoom__miniatura[aria-selected="true"] { outline: 1.5px solid currentColor; outline-offset: 1.4px; }
@media (max-width: 749px) {
  .at-zoom__lista { display: flex; overflow-x: auto; overflow-y: hidden; scroll-snap-type: x mandatory; }
  .at-zoom__foto { flex: 0 0 100%; display: flex; align-items: center; scroll-snap-align: start; }
  .at-zoom__miniaturas { top: auto; bottom: 0; right: auto; left: 0; flex-direction: row; width: 100%; max-height: none; transform: none; overflow-x: auto; }
}

.at-barra { display: contents; }
.at-barra__caja {
  position: fixed;
  left: 50%;
  bottom: 20px;
  z-index: 7;
  display: flex;
  align-items: center;
  gap: 14.4px;
  width: 600px;
  padding: 11.2px;
  border-radius: 25.2px;
  background: #fff;
  box-shadow: 0 4px 20px rgb(0 0 0 / .15);
  opacity: 0;
  transform: translate(-50%) translateY(calc(100% + 40px));
  transition-property: transform, opacity;
  transition-duration: .3s;
  transition-timing-function: cubic-bezier(.32, .72, 0, 1);
  pointer-events: none;
}
.at-barra__caja::before {
  content: "";
  position: absolute;
  inset: -2px;
  z-index: -1;
  border: 2px solid transparent;
  border-radius: inherit;
  background: linear-gradient(#fff 0 100%) padding-box, linear-gradient(rgb(0 0 0 / .15) 0 100%) border-box;
  -webkit-backdrop-filter: blur(20px) saturate(180%) brightness(1.5);
  backdrop-filter: blur(20px) saturate(180%) brightness(1.5);
}
.at-barra__caja[data-pegada="true"] { opacity: 1; transform: translate(-50%) translateY(0); pointer-events: auto; }
.at-barra__foto { flex-shrink: 0; width: 52px; height: 52px; aspect-ratio: 1; overflow: hidden; border-radius: 14px; background: #f5f5f5; }
.at-barra__foto img { display: block; width: 100%; height: 100%; object-fit: cover; }
.at-barra__info { flex: 1; min-width: 0; }
.at-barra__titulo { margin: 0; overflow: hidden; font-size: 14px; line-height: 1.6; text-overflow: ellipsis; white-space: nowrap; }
.at-barra__variante { margin-top: 2px; color: rgb(0 0 0 / .8); font-size: 14px; }
.at-barra__precio { flex-shrink: 0; font-size: 14px; }
.at-barra__importe, .at-barra__tachado { display: inline-block; }
.at-barra__tachado { color: rgb(0 0 0 / .8); white-space: nowrap; text-decoration-line: line-through; text-decoration-thickness: 1.5px; text-decoration-color: rgb(0 0 0 / .3); }
.at-barra__boton {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 4.8px;
  height: 52px;
  padding: 16px 24px;
  border: 0;
  border-radius: 14px;
  background: #000;
  color: #fff;
  font-family: var(--at-fuente-cuerpo, Inter, sans-serif);
  font-size: 14px;
  line-height: 1.6;
  cursor: pointer;
}
.at-barra__boton .add-to-cart-text { display: flex; align-items: center; gap: 4.8px; }
@media (max-width: 749px) {
  .at-barra__caja { bottom: 0; width: 100%; border-radius: 0; }
  .at-barra__caja::before { inset: -1px; border-width: 1px; }
  .at-barra__tachado { display: none; }
  .at-barra__variante { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
  .at-barra__boton { width: 52px; padding: 16px; overflow: hidden; }
}

:where(.at-ficha, .at-barra, .at-zoom) .at-icono { display: inline-flex; flex-shrink: 0; width: 20px; height: 20px; background: currentColor; -webkit-mask: var(--at-icono) center / contain no-repeat; mask: var(--at-icono) center / contain no-repeat; }
.at-icono--flecha { --at-icono: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20' fill='none' stroke='%23000' stroke-width='1.4' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M3.7 10H16M11.7 5.6L16.1 10L11.7 14.4'/%3E%3C/svg%3E"); }
.at-icono--mas { --at-icono: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 14 14' fill='none' stroke='%23000'%3E%3Cpath d='M7 2.6V11.4M2.6 7.2H11.4' stroke-width='1.3' stroke-linecap='round'/%3E%3C/svg%3E"); width: 13.6px; height: 13.6px; }
.at-icono--menos { --at-icono: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 14 14' fill='none' stroke='%23000'%3E%3Cpath d='M2.2 7.2H11.8' stroke-width='1.2' stroke-linecap='round'/%3E%3C/svg%3E"); width: 13.6px; height: 13.6px; }
.at-icono--cruz { --at-icono: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='none' stroke='%23000' stroke-width='1.5' stroke-linecap='round'%3E%3Cpath d='M3 3l10 10M13 3L3 13'/%3E%3C/svg%3E"); }
.at-icono--bolsa { --at-icono: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20' fill='none' stroke='%23000' stroke-width='1.4' stroke-linejoin='round'%3E%3Cpath d='M4 6.5h12l-1 10H5z'/%3E%3Cpath d='M7.5 8V5.5a2.5 2.5 0 0 1 5 0V8' stroke-linecap='round'/%3E%3C/svg%3E"); }

.at-ficha .at-oculto,
.at-barra .at-oculto,
.at-zoom .at-oculto {
  position: absolute !important;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

.at-compra__error { display: flex; align-items: center; gap: 8px; margin-bottom: 8px; color: #e00; font-size: 14px; }
.at-compra__error[hidden] { display: none; }
.at-compra__error .at-icono { width: 20px; height: 20px; }
.at-compra__listo { position: absolute; display: none; }
.at-icono--listo { --at-icono: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20' fill='none' stroke='%23000' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 10.5l3.2 3.2L15 7'/%3E%3C/svg%3E"); }
.at-icono--alerta { --at-icono: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 14 14'%3E%3Ccircle cx='7' cy='7' r='6.5' fill='%23000'/%3E%3Cpath d='M7 3.6v4.2' stroke='%23fff' stroke-width='1.5' stroke-linecap='round'/%3E%3Ccircle cx='7' cy='10.2' r='.9' fill='%23fff'/%3E%3C/svg%3E"); }

/* Drip: los detalles sin relleno arriba (en su Horizon el bloque de detalles va con relleno 0; el aire lo pone la
   píldora de reseñas de la marca). */
.at-ficha .at-ficha__columna { padding-block-start: 0; }
