/* JMZ textil — negro y dorado, como su logo.
   Dirección: "hoja de contactos". Las prendas reales del catálogo son la textura de la página;
   una sola tipografía (Bricolage Grotesque), cinco tamaños, colores planos, esquinas rectas. */

:root {
  /* Color */
  --ground: #0b0b0b;
  --surface: #151515;
  --surface-2: #202020;
  --surface-3: #2a2a2a;
  --ink: #f0efec;
  --ink-soft: #b9b4a9;
  --accent: #c6a664;
  --accent-hover: #d4b676;
  --accent-press: #b4934f;
  --bone: #ebebe8;
  --bone-2: #dfdfdb;
  --bone-3: #d1d1cc;
  --ink-dark: #121212;
  --ink-dark-soft: #4f4b45;
  --danger: #e0614f;
  --danger-dark: #a8261a;
  --success: #6fbf8a;
  --success-dark: #1d6a3a;
  --whatsapp: #25d366;

  /* Tipografía: cinco tamaños */
  --font: "Bricolage Grotesque", ui-sans-serif, system-ui, -apple-system, "Segoe UI", sans-serif;
  --step-small: 0.875rem;
  --step-body: clamp(1.0625rem, 1rem + 0.25vw, 1.1875rem);
  --step-lead: clamp(1.25rem, 1.1rem + 0.7vw, 1.625rem);
  --step-head: clamp(2rem, 1.3rem + 3.2vw, 4rem);
  --step-display: clamp(2.5rem, 0.6rem + 6.4vw, 7.25rem);
  --step-hero: clamp(2.75rem, 0.5rem + 8.6vw, 10rem);

  /* Espacio */
  --margin: clamp(16px, 2.5vw, 32px);
  --gap: 8px;
  --section-space: clamp(96px, 7vw + 48px, 176px);
  --header-height: 64px;

  /* Movimiento */
  --ease-out: cubic-bezier(0.22, 1, 0.36, 1);
  --ease-in-out: cubic-bezier(0.65, 0, 0.35, 1);
  --fast: 160ms;
  --medium: 240ms;
  --slow: 560ms;

  color-scheme: dark;
}

/* ---------- Base ---------- */

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: var(--header-height);
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  background: var(--ground);
  color: var(--ink);
  font-family: var(--font);
  font-size: var(--step-body);
  line-height: 1.5;
  font-optical-sizing: auto;
  -webkit-font-smoothing: antialiased;
  -webkit-tap-highlight-color: transparent;
}

body.no-scroll {
  overflow: hidden;
}

button,
input,
select,
textarea {
  font: inherit;
  color: inherit;
}

button {
  cursor: pointer;
}

a {
  color: inherit;
}

img,
svg {
  display: block;
  max-width: 100%;
}

h1,
h2,
h3,
p,
dl,
dd,
figure,
ol,
ul {
  margin: 0;
}

h1,
h2 {
  font-size: var(--step-head);
  font-weight: 600;
  line-height: 0.95;
  letter-spacing: -0.04em;
  text-wrap: balance;
}

h3 {
  font-size: var(--step-body);
  font-weight: 600;
  line-height: 1.3;
}

::selection {
  background: var(--accent);
  color: var(--ink-dark);
}

:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
}

.skip-link {
  position: absolute;
  left: var(--margin);
  top: -100px;
  z-index: 100;
  padding: 12px 16px;
  background: var(--accent);
  color: var(--ink-dark);
  font-weight: 600;
  text-decoration: none;
}

.skip-link:focus {
  top: 8px;
}

.hp {
  position: absolute;
  left: -9999px;
  width: 1px;
  height: 1px; /* taste-skill-ignore: campo trampa oculto, no es una línea */
  overflow: hidden;
}

.section {
  padding: var(--section-space) var(--margin);
}

.section-lead {
  max-width: 34ch;
  margin-top: 24px;
  font-size: var(--step-lead);
  line-height: 1.3;
  text-wrap: pretty;
}

/* ---------- Botones y enlaces ---------- */

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 52px;
  padding: 0 28px;
  border: 0;
  border-radius: 0;
  font-size: var(--step-body);
  font-weight: 600;
  line-height: 1.1;
  text-align: center;
  text-decoration: none;
  transition:
    background-color var(--fast) ease,
    color var(--fast) ease,
    transform var(--fast) var(--ease-out);
}

.button:active {
  transform: scale(0.97);
}

.button:disabled {
  cursor: progress;
  opacity: 0.6;
}

.button.primary {
  background: var(--accent);
  color: var(--ink-dark);
}

.button.primary:hover {
  background: var(--accent-hover);
}

.button.primary:active {
  background: var(--accent-press);
}

.button.secondary {
  background: var(--surface-2);
  color: var(--ink);
}

.button.secondary:hover {
  background: var(--surface-3);
}

.button.dark {
  background: var(--ink-dark);
  color: var(--ink);
}

.button.dark:hover {
  background: #2a2a2a;
}

.button.full {
  width: 100%;
}

.text-link {
  position: relative;
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  font-weight: 500;
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 5px;
  text-decoration-color: color-mix(in srgb, currentColor 45%, transparent);
  transition: text-decoration-color var(--fast) ease, color var(--fast) ease;
}

.text-link:hover {
  text-decoration-color: currentColor;
}

.square-button {
  display: grid;
  width: 48px;
  height: 48px;
  place-items: center;
  border: 0;
  background: var(--surface-2);
  color: var(--ink);
  transition: background-color var(--fast) ease, transform var(--fast) var(--ease-out);
}

.square-button:hover {
  background: var(--surface-3);
}

.square-button:active {
  transform: scale(0.94);
}

.square-button:disabled {
  cursor: default;
  opacity: 0.35;
}

.square-button svg,
.icon-button svg {
  width: 22px;
  height: 22px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

/* ---------- Cabecera ---------- */

.site-header {
  position: sticky;
  top: 0;
  z-index: 40;
  display: flex;
  align-items: center;
  gap: 32px;
  height: var(--header-height);
  padding: 0 var(--margin);
  background: var(--ground);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  min-width: max-content;
  text-decoration: none;
}

.brand-mark {
  width: 34px;
  height: auto;
}

.brand-text {
  font-size: var(--step-body);
  font-weight: 600;
  letter-spacing: -0.01em;
}

.main-nav {
  display: flex;
  align-items: center;
  gap: 4px;
  margin-left: auto;
}

.main-nav a {
  padding: 10px 12px;
  color: var(--ink-soft);
  font-size: var(--step-small);
  font-weight: 500;
  text-decoration: none;
  transition: color var(--fast) ease;
}

.main-nav a:hover,
.main-nav a.is-current {
  color: var(--ink);
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

.nav-cart {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-height: 40px;
  padding: 0 8px 0 16px;
  border: 0;
  background: var(--surface-2);
  font-size: var(--step-small);
  font-weight: 600;
  transition: background-color var(--fast) ease, transform var(--fast) var(--ease-out);
}

.nav-cart:hover {
  background: var(--surface-3);
}

.nav-cart:active {
  transform: scale(0.97);
}

.cart-count {
  display: inline-grid;
  min-width: 26px;
  height: 26px;
  place-items: center;
  padding: 0 6px;
  background: var(--accent);
  color: var(--ink-dark);
  font-variant-numeric: tabular-nums;
}

.cart-count.is-bumped {
  animation: bump 420ms var(--ease-out);
}

@keyframes bump {
  30% {
    transform: scale(1.25);
  }
}

.menu-toggle {
  display: none;
  width: 44px;
  height: 40px;
  padding: 0;
  border: 0;
  background: var(--surface-2);
}

.menu-toggle span {
  display: block;
  width: 18px;
  height: 2px;
  margin: 5px auto;
  background: var(--ink);
  transition: transform var(--medium) var(--ease-out);
}

.menu-toggle[aria-expanded="true"] span:first-child {
  transform: translateY(3.5px) rotate(45deg);
}

.menu-toggle[aria-expanded="true"] span:last-child {
  transform: translateY(-3.5px) rotate(-45deg);
}

/* ---------- Portada: muro de prendas ---------- */

.hero {
  position: relative;
  height: calc(100svh - var(--header-height));
  min-height: 560px;
  max-height: 1100px;
  overflow: hidden;
  background: var(--ground);
}

.wall {
  --row-gap: var(--gap);
  display: flex;
  flex-direction: column;
  gap: var(--row-gap);
  height: 100%;
  padding-top: var(--gap);
}

.wall-row {
  display: flex;
  flex: 1 1 0;
  gap: var(--gap);
  min-height: 0;
  width: max-content;
}

.wall-row:nth-child(even) {
  margin-left: calc(var(--tile-w, 140px) / -2);
}

.tile {
  flex: none;
  height: 100%;
  aspect-ratio: 3 / 4;
  padding: 0;
  border: 0;
  overflow: hidden;
  background: var(--surface);
}

.tile img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.86;
  transition:
    opacity var(--medium) ease,
    transform var(--slow) var(--ease-out);
}

.tile:hover img,
.tile:focus-visible img {
  opacity: 1;
  transform: scale(1.06);
}

.tile:focus-visible {
  outline-offset: -3px;
}

/* Velo neutro para que el titular se lea sobre las fotos */
.hero-scrim {
  position: absolute;
  inset: 0;
  z-index: 1;
  background: linear-gradient( /* taste-skill-ignore: velo neutro sobre fotos para leer el titular */
    180deg,
    rgba(11, 11, 11, 0.15) 0%,
    rgba(11, 11, 11, 0.55) 45%,
    rgba(11, 11, 11, 0.94) 100%
  );
  pointer-events: none;
}

.hero-content {
  position: absolute;
  right: var(--margin);
  bottom: clamp(24px, 4vh, 48px);
  left: var(--margin);
  z-index: 2;
  pointer-events: none;
}

.hero-content a,
.hero-content button,
.hero-content h1,
.hero-content p {
  pointer-events: auto;
}

.hero h1 {
  position: relative;
  max-width: none;
  font-size: var(--step-hero);
  line-height: 0.86;
  letter-spacing: -0.05em;
  text-wrap: initial;
  user-select: none;
}

.hero h1 em {
  display: block;
  color: var(--accent);
  font-style: normal;
}

.hero h1 .word {
  display: inline-block;
  white-space: nowrap;
}

.hero h1 .char {
  display: inline-block;
  transition: color 300ms ease;
  will-change: transform, opacity;
}

.hero h1 .char.is-hot {
  color: var(--accent);
}

.hero h1 em .char.is-hot {
  color: var(--ink);
}

.hero h1.is-split:not(.is-in) .char {
  opacity: 0;
}

.hero h1.is-in .char {
  animation: char-in 0.6s var(--ease-out) backwards;
  animation-delay: var(--char-delay, 0ms);
}

@keyframes char-in {
  from {
    opacity: 0;
    transform: translateY(40%) rotate(6deg);
    filter: blur(10px);
  }
}

.hero-bottom {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: end;
  gap: 24px 48px;
  margin-top: clamp(24px, 3vw, 40px);
  will-change: transform, opacity;
}

.hero-bottom p {
  max-width: 50ch;
}

.hero-actions {
  display: flex;
  align-items: center;
  gap: 8px 28px;
  padding-right: 72px; /* hueco para el botón de WhatsApp */
}

.hero-actions .text-link {
  font-size: var(--step-small);
}

.wall {
  will-change: transform;
}

/* ---------- Sectores: índice con vista previa ---------- */

.sectors-layout {
  display: grid;
  grid-template-columns: minmax(0, 7fr) minmax(0, 5fr);
  gap: clamp(32px, 6vw, 112px);
  align-items: start;
}

.index {
  margin-top: 56px;
  padding: 0;
  list-style: none;
}

.index-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 24px;
  width: 100%;
  padding: 18px 0;
  border: 0;
  background: none;
  text-align: left;
  transition: opacity var(--medium) ease;
}

.index:hover .index-row:not(:hover),
.index.has-focus .index-row:not(:focus-visible) {
  opacity: 0.4;
}

.index-row:focus-visible {
  outline-offset: 0;
}

.index-thumb {
  display: none;
}

.index-name {
  display: block;
  font-size: var(--step-lead);
  font-weight: 500;
  line-height: 1.15;
  letter-spacing: -0.02em;
  transition: transform var(--medium) var(--ease-out), color var(--fast) ease;
}

.index-name small {
  display: block;
  margin-top: 6px;
  color: var(--ink-soft);
  font-size: var(--step-small);
  font-weight: 400;
  letter-spacing: 0;
}

.index-row:hover .index-name,
.index-row.is-active .index-name {
  transform: translateX(8px);
}

.index-row.is-active .index-name {
  color: var(--accent);
}

.index-value {
  color: var(--ink-soft);
  font-size: var(--step-small);
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

.index-preview {
  position: sticky;
  top: calc(var(--header-height) + 32px);
  margin-top: 8px;
}

.index-preview img {
  width: 100%;
  aspect-ratio: 3 / 4;
  object-fit: cover;
  background: var(--surface);
  transition: opacity var(--medium) ease;
}

.index-preview img.is-swapping {
  opacity: 0;
}

.index-preview figcaption {
  margin-top: 12px;
  color: var(--ink-soft);
  font-size: var(--step-small);
}

/* ---------- Catálogo ---------- */

.catalog {
  background: var(--bone);
  color: var(--ink-dark);
  color-scheme: light;
}

.catalog ::selection {
  background: var(--ink-dark);
  color: var(--bone);
}

.catalog :focus-visible {
  outline-color: var(--ink-dark);
}

.catalog-head {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 32px 64px;
  align-items: end;
}

.catalog-tools {
  display: grid;
  grid-template-columns: minmax(0, 3fr) minmax(0, 2fr);
  gap: 8px;
}

.field {
  display: grid;
  gap: 8px;
  font-size: var(--step-small);
  font-weight: 500;
}

.field em {
  color: var(--ink-dark-soft);
  font-style: normal;
  font-weight: 400;
}

.field input,
.field select,
.field textarea {
  width: 100%;
  min-height: 52px;
  padding: 12px 16px;
  border: 0;
  border-radius: 0;
  background: var(--bone-2);
  color: var(--ink-dark);
  font-size: 1rem;
  font-weight: 400;
  transition: background-color var(--fast) ease;
}

.field textarea {
  min-height: 0;
  resize: vertical;
}

.field select {
  appearance: none;
  padding-right: 44px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23121212' stroke-width='2' stroke-linecap='round'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 14px center;
  background-size: 18px;
}

.field input:hover,
.field select:hover,
.field textarea:hover {
  background-color: var(--bone-3);
}

.field input:focus,
.field select:focus,
.field textarea:focus {
  outline: 2px solid var(--ink-dark);
  outline-offset: 0;
  background-color: #fff;
}

.field input::placeholder,
.field textarea::placeholder {
  color: #77726a;
}

.quick-filters {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 48px;
}

.chip {
  min-height: 44px;
  padding: 0 18px;
  border: 0;
  background: var(--bone-2);
  color: var(--ink-dark);
  font-size: var(--step-small);
  font-weight: 500;
  transition:
    background-color var(--fast) ease,
    color var(--fast) ease,
    transform var(--fast) var(--ease-out);
}

.chip:hover {
  background: var(--bone-3);
}

.chip:active {
  transform: scale(0.96);
}

.chip.is-active {
  background: var(--ink-dark);
  color: var(--bone);
}

.catalog-count {
  margin-top: 24px;
  color: var(--ink-dark-soft);
  font-size: var(--step-small);
}

.product-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(230px, 42vw), 1fr));
  gap: 40px 16px;
  margin-top: 24px;
}

.product-card {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 0;
  border: 0;
  background: none;
  color: inherit;
  text-align: left;
}

.product-card .media {
  position: relative;
  display: block;
  aspect-ratio: 3 / 4;
  margin-bottom: 12px;
  overflow: hidden;
  background: var(--bone-2);
}

.product-card .media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform var(--slow) var(--ease-out);
}

.product-card .media .swatch-fill {
  display: grid;
  width: 100%;
  height: 100%;
  place-items: center;
  background: var(--product-color, var(--bone-3));
  color: #fff;
  font-weight: 600;
}

.product-card .media .quick-add {
  position: absolute;
  right: 8px;
  bottom: 8px;
  left: 8px;
  display: grid;
  min-height: 44px;
  place-items: center;
  background: var(--ink-dark);
  color: var(--bone);
  font-size: var(--step-small);
  font-weight: 600;
  opacity: 0;
  transform: translateY(8px);
  transition:
    opacity var(--medium) ease,
    transform var(--medium) var(--ease-out);
}

.product-card:hover .media img,
.product-card:focus-visible .media img {
  transform: scale(1.04);
}

.product-card:hover .quick-add,
.product-card:focus-visible .quick-add {
  opacity: 1;
  transform: none;
}

.product-card:focus-visible {
  outline-offset: 4px;
}

.product-card .name {
  font-weight: 500;
  line-height: 1.3;
}

.product-card .meta {
  color: var(--ink-dark-soft);
  font-size: var(--step-small);
}

.product-card .price {
  margin-top: 4px;
  font-weight: 600;
  font-variant-numeric: tabular-nums;
}

.product-card .price small,
.dialog-price small {
  color: var(--ink-dark-soft);
  font-size: var(--step-small);
  font-weight: 400;
}

.load-more-wrap {
  display: flex;
  justify-content: center;
  margin-top: 64px;
}

.catalog .button.secondary {
  background: var(--ink-dark);
  color: var(--bone);
}

.catalog .button.secondary:hover {
  background: #2a2a2a;
}

.empty-state {
  grid-column: 1 / -1;
  padding: 48px 0;
  color: var(--ink-dark-soft);
}

.empty-state button {
  margin-top: 16px;
}

/* Carga: esqueleto plano mientras llegan los productos */
.skeleton {
  display: grid;
  gap: 10px;
}

.skeleton span {
  display: block;
  height: 16px;
  background: var(--bone-2);
}

.skeleton span:first-child {
  height: auto;
  aspect-ratio: 3 / 4;
}

.skeleton span:last-child {
  width: 40%;
}

/* ---------- Ficha de producto ---------- */

.product-dialog {
  width: min(1080px, calc(100% - 2 * var(--margin)));
  max-height: calc(100svh - 48px);
  padding: 0;
  border: 0;
  background: var(--bone);
  color: var(--ink-dark);
  color-scheme: light;
  box-shadow: 0 40px 120px rgba(0, 0, 0, 0.5); /* taste-skill-ignore: diálogo flotante */
  overflow: hidden;
}

.product-dialog::backdrop {
  background: rgba(0, 0, 0, 0.72);
}

.product-dialog[open] {
  animation: dialog-in var(--medium) var(--ease-out);
}

.product-dialog[open]::backdrop {
  animation: fade-in var(--medium) ease;
}

@keyframes dialog-in {
  from {
    opacity: 0;
    transform: translateY(16px) scale(0.98);
  }
}

@keyframes fade-in {
  from {
    opacity: 0;
  }
}

.product-dialog :focus-visible {
  outline-color: var(--ink-dark);
}

.dialog-inner {
  display: grid;
  grid-template-columns: minmax(0, 5fr) minmax(0, 6fr);
  grid-template-rows: minmax(0, 1fr);
  height: min(780px, calc(100svh - 48px));
}

.dialog-media {
  background: var(--bone-2);
}

.dialog-media {
  min-height: 0;
  overflow: hidden;
}

.dialog-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.dialog-body {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 20px;
  padding: 40px;
  min-height: 0;
  overflow-y: auto;
  overscroll-behavior: contain;
  scrollbar-gutter: stable;
}

.dialog-body .meta {
  color: var(--ink-dark-soft);
  font-size: var(--step-small);
}

.dialog-body h2 {
  max-width: 18ch;
  margin-top: -12px;
  font-size: clamp(1.75rem, 1.2rem + 1.6vw, 2.5rem);
  line-height: 1;
}

.dialog-desc {
  max-width: 60ch;
  color: var(--ink-dark);
}

.dialog-price {
  font-size: var(--step-lead);
  font-weight: 600;
  font-variant-numeric: tabular-nums;
}

.dialog-close {
  position: absolute;
  top: 12px;
  right: 12px;
}

.icon-button {
  display: grid;
  width: 44px;
  height: 44px;
  place-items: center;
  border: 0;
  background: var(--bone-2);
  color: var(--ink-dark);
  transition: background-color var(--fast) ease, transform var(--fast) var(--ease-out);
}

.icon-button:hover {
  background: var(--bone-3);
}

.icon-button:active {
  transform: scale(0.94);
}

.option-group {
  margin: 0;
  padding: 0;
  border: 0;
}

.option-group legend {
  margin-bottom: 10px;
  padding: 0;
  font-size: var(--step-small);
  font-weight: 500;
}

.option-group legend span {
  color: var(--ink-dark-soft);
  font-weight: 400;
}

.options {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.option {
  position: relative;
}

.option input {
  position: absolute;
  inset: 0;
  opacity: 0;
  cursor: pointer;
}

.option span {
  display: grid;
  min-width: 52px;
  min-height: 44px;
  place-items: center;
  padding: 0 14px;
  background: var(--bone-2);
  font-size: var(--step-small);
  font-weight: 500;
  transition: background-color var(--fast) ease, color var(--fast) ease;
}

.option input:hover + span {
  background: var(--bone-3);
}

.option input:checked + span {
  background: var(--ink-dark);
  color: var(--bone);
}

.option input:focus-visible + span {
  outline: 2px solid var(--ink-dark);
  outline-offset: 2px;
}

.qty {
  display: inline-grid;
  grid-template-columns: 48px 72px 48px;
  height: 48px;
  background: var(--bone-2);
}

.qty button {
  border: 0;
  background: none;
  font-size: 1.25rem;
  transition: background-color var(--fast) ease;
}

.qty button:hover {
  background: var(--bone-3);
}

.qty input {
  width: 100%;
  border: 0;
  background: none;
  font-weight: 600;
  text-align: center;
  font-variant-numeric: tabular-nums;
  -moz-appearance: textfield;
}

.qty input::-webkit-inner-spin-button,
.qty input::-webkit-outer-spin-button {
  margin: 0;
  -webkit-appearance: none;
}

.dialog-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 24px;
  margin-top: 4px;
}

.dialog-actions .button.primary {
  flex: 1 1 220px;
  background: var(--ink-dark);
  color: var(--bone);
}

.dialog-actions .button.primary:hover {
  background: #2a2a2a;
}

.min-qty {
  color: var(--ink-dark-soft);
  font-size: var(--step-small);
}

/* ---------- Personalización: pruébala con tu marca ---------- */

.custom {
  background: var(--surface);
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

.custom-head {
  display: grid;
  grid-template-columns: minmax(0, 7fr) minmax(0, 5fr);
  gap: 24px clamp(32px, 4vw, 64px);
  align-items: end;
}

.custom-head .section-lead {
  max-width: 36ch;
  margin-top: 0;
  color: var(--ink-soft);
}

.studio {
  display: grid;
  grid-template-columns: minmax(0, 7fr) minmax(0, 5fr);
  gap: 16px;
  align-items: start;
  margin-top: 56px;
}

/* Escenario con la prenda */

.stage {
  position: sticky;
  top: calc(var(--header-height) + 16px);
  display: grid;
  grid-template-rows: auto 1fr;
  min-height: min(720px, calc(100svh - var(--header-height) - 32px));
  padding: 20px;
  border-radius: 24px;
  background: #e7e5e0;
  color: var(--ink-dark);
  transition: background-color 400ms ease;
}

.stage.is-dark {
  background: #2b2b2b;
  color: var(--ink);
}

.stage-top {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.view-toggle {
  display: inline-flex;
  padding: 4px;
  border-radius: 999px;
  background: rgba(0, 0, 0, 0.07);
}

.stage.is-dark .view-toggle {
  background: rgba(255, 255, 255, 0.08);
}

.view-toggle button {
  min-height: 40px;
  padding: 0 20px;
  border: 0;
  border-radius: 999px;
  background: none;
  color: inherit;
  font-size: var(--step-small);
  font-weight: 600;
  transition:
    background-color var(--fast) ease,
    color var(--fast) ease;
}

.view-toggle button[aria-pressed="true"] {
  background: var(--ink-dark);
  color: var(--ink);
}

.stage.is-dark .view-toggle button[aria-pressed="true"] {
  background: var(--accent);
  color: var(--ink-dark);
}

.stage-chip {
  font-size: var(--step-small);
  font-weight: 500;
  opacity: 0.7;
}

.tee {
  align-self: center;
  justify-self: center;
  width: min(100%, 540px);
  height: auto;
  margin: 8px 0 -8px;
  --garment: #161616;
  --seam: rgba(255, 255, 255, 0.1);
  --guide: rgba(255, 255, 255, 0.45);
}

.tee.is-light {
  --seam: rgba(0, 0, 0, 0.22);
  --guide: rgba(0, 0, 0, 0.4);
}

/* En SVG el atributo hidden no oculta nada por sí solo */
.tee-view[hidden] {
  display: none;
}

.tee.is-flipping {
  animation: tee-flip 440ms var(--ease-in-out);
}

@keyframes tee-flip {
  50% {
    transform: scaleX(0.04);
  }
}

.tee-fill {
  fill: var(--garment);
  transition: fill 350ms ease;
}

.tee-collar {
  fill: rgba(0, 0, 0, 0.22);
}

.tee-seam {
  fill: none;
  stroke: var(--seam);
  stroke-width: 1.5;
  stroke-dasharray: 4 4;
}

.print-guide rect {
  fill: none;
  stroke: var(--guide);
  stroke-width: 1.5;
  stroke-dasharray: 6 6;
}

.print-guide text {
  fill: var(--guide);
  font-family: var(--font);
  font-size: 17px;
  font-weight: 500;
}

.tee-text {
  font-family: var(--font);
  font-weight: 600;
  letter-spacing: -0.01em;
  transition: fill 300ms ease;
}

.tee image {
  transition: opacity 300ms ease;
}

/* Panel de opciones */

.studio-panel {
  display: grid;
  gap: 12px;
}

.panel-block {
  display: grid;
  gap: 16px;
  padding: 22px;
  border-radius: 24px;
  background: var(--surface-2);
}

.block-head {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: 4px 16px;
}

.block-head h3 {
  font-size: var(--step-body);
}

.block-head span {
  color: var(--ink-soft);
  font-size: var(--step-small);
}

.dropzone {
  position: relative;
  display: grid;
  justify-items: center;
  gap: 10px;
  padding: 28px 20px;
  border: 1.5px dashed rgba(198, 166, 100, 0.5); /* taste-skill-ignore: zona para soltar el archivo */
  border-radius: 18px;
  background: rgba(198, 166, 100, 0.05);
  color: var(--ink-soft);
  font-size: var(--step-small);
  text-align: center;
  cursor: pointer;
  transition:
    background-color var(--fast) ease,
    border-color var(--fast) ease;
}

.dropzone strong {
  color: var(--accent);
  font-weight: 600;
}

.dropzone:hover,
.dropzone.is-over {
  border-color: var(--accent);
  background: rgba(198, 166, 100, 0.12);
}

.dropzone:focus-within {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
}

.dropzone-icon {
  width: 30px;
  height: 30px;
  fill: none;
  stroke: var(--accent);
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
  transition: transform var(--medium) var(--ease-out);
}

.dropzone.is-over .dropzone-icon {
  transform: translateY(-4px);
}

.logo-file {
  display: grid;
  grid-template-columns: 56px auto auto minmax(0, 1fr);
  grid-template-rows: auto auto;
  align-items: center;
  gap: 8px 12px;
}

.logo-file img {
  grid-row: span 2;
}

.logo-file-info {
  grid-column: 2 / -1;
}

.logo-file[hidden],
.logo-options[hidden],
.dropzone[hidden] {
  display: none;
}

.logo-file img {
  width: 56px;
  height: 56px;
  padding: 6px;
  border-radius: 12px;
  object-fit: contain;
  background-color: #3a3a3a;
  background-image: conic-gradient(#444 25%, #353535 0 50%, #444 0 75%, #353535 0); /* taste-skill-ignore: cuadrícula de transparencia */
  background-size: 12px 12px;
}

.logo-file-info {
  display: grid;
  min-width: 0;
}

.logo-file-info strong {
  overflow: hidden;
  font-size: var(--step-small);
  font-weight: 600;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.logo-file-info span {
  overflow: hidden;
  color: var(--ink-soft);
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: var(--step-small);
}

.chip-button {
  min-height: 36px;
  padding: 0 14px;
  border: 0;
  border-radius: 999px;
  background: var(--surface-3);
  font-size: var(--step-small);
  font-weight: 500;
  transition:
    background-color var(--fast) ease,
    color var(--fast) ease,
    transform var(--fast) var(--ease-out);
}

.chip-button:hover {
  background: #343434;
  color: var(--accent);
}

.chip-button:active {
  transform: scale(0.96);
}

.logo-options {
  display: grid;
  gap: 18px;
}

.switch {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  font-size: var(--step-small);
  font-weight: 500;
  cursor: pointer;
}

.switch {
  position: relative;
}

.switch input {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  margin: 0;
  opacity: 0;
  cursor: pointer;
}

.switch-track {
  position: relative;
  flex: none;
  width: 42px;
  height: 24px;
  border-radius: 999px;
  background: var(--surface-3);
  transition: background-color var(--fast) ease;
}

.switch-track::after {
  content: "";
  position: absolute;
  top: 3px;
  left: 3px;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: var(--ink);
  transition: transform var(--medium) var(--ease-out);
}

.switch input:checked + .switch-track {
  background: var(--accent);
}

.switch input:checked + .switch-track::after {
  background: var(--ink-dark);
  transform: translateX(18px);
}

.switch input:focus-visible + .switch-track {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

.segmented,
.dots {
  margin: 0;
  padding: 0;
  border: 0;
}

.segmented legend,
.dots legend {
  margin-bottom: 10px;
  padding: 0;
  font-size: var(--step-small);
  font-weight: 500;
}

.dots legend span[data-tinta-label],
.dots legend span[data-prenda-label] {
  color: var(--ink-soft);
  font-weight: 400;
}

.segmented-track {
  display: flex;
  padding: 4px;
  border-radius: 999px;
  background: var(--ground);
}

.segmented label {
  position: relative;
  flex: 1;
}

.segmented input {
  position: absolute;
  inset: 0;
  opacity: 0;
  cursor: pointer;
}

.segmented span {
  display: grid;
  min-height: 38px;
  place-items: center;
  padding: 0 10px;
  border-radius: 999px;
  color: var(--ink-soft);
  font-size: var(--step-small);
  font-weight: 500;
  text-align: center;
  transition:
    background-color var(--fast) ease,
    color var(--fast) ease;
}

.segmented input:hover + span {
  color: var(--ink);
}

.segmented input:checked + span {
  background: var(--accent);
  color: var(--ink-dark);
}

.segmented input:focus-visible + span {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

.range {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  align-items: center;
  gap: 16px;
  font-size: var(--step-small);
  font-weight: 500;
}

.range input {
  width: 100%;
  accent-color: var(--accent);
}

.custom .field input {
  min-height: 56px;
  border-radius: 14px;
  background: var(--ground);
  color: var(--ink);
  font-size: var(--step-body);
  font-weight: 500;
}

.custom .field input:hover {
  background: #101010;
}

.custom .field input:focus {
  outline: 2px solid var(--accent);
  background: #101010;
}

.custom .field input::placeholder {
  color: #77736b;
}

.dots {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.dots legend {
  width: 100%;
}

.dots label {
  position: relative;
}

.dots input {
  position: absolute;
  inset: 0;
  opacity: 0;
  cursor: pointer;
}

.dots label > span {
  display: block;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: var(--swatch);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.18); /* taste-skill-ignore: borde de la muestra de color */
  transition: transform var(--fast) var(--ease-out);
}

.dots-large label > span {
  width: 42px;
  height: 42px;
}

.dots input:hover + span {
  transform: scale(1.08);
}

.dots input:checked + span {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
}

.dots input:focus-visible + span {
  outline: 2px solid var(--ink);
  outline-offset: 3px;
}

.dots-large .legend-title {
  font-size: var(--step-body);
  font-weight: 600;
}

.panel-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px 24px;
  padding: 8px 4px 0;
}

.panel-actions .form-status {
  width: 100%;
}

.panel-note {
  width: 100%;
  color: var(--ink-soft);
  font-size: var(--step-small);
}

/* ---------- Cómo funciona: fila que se arrastra ---------- */

.steps-section {
  padding-right: 0;
  padding-left: 0;
}

.steps-head {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 24px;
  padding: 0 var(--margin);
}

.steps-nav {
  display: flex;
  gap: 8px;
}

.steps-progress {
  height: 6px;
  margin: 40px var(--margin) 0;
  background: var(--surface-2);
}

.steps-progress span {
  display: block;
  width: 100%;
  height: 100%;
  background: var(--ink);
  transform: scaleX(0.2);
  transform-origin: left;
  transition: transform 120ms linear;
}

.steps {
  display: flex;
  gap: 32px;
  margin-top: 48px;
  padding: 0 var(--margin) 8px;
  overflow-x: auto;
  overscroll-behavior-x: contain;
  scroll-snap-type: x mandatory;
  scroll-padding: 0 var(--margin);
  scrollbar-width: none;
  list-style: none;
}

.steps::-webkit-scrollbar {
  display: none;
}

.steps li {
  display: flex;
  flex: 0 0 300px;
  flex-direction: column;
  scroll-snap-align: start;
}

.steps h3 {
  font-size: var(--step-lead);
  font-weight: 600;
  letter-spacing: -0.02em;
}

.steps p {
  margin-top: 12px;
  color: var(--ink-soft);
}

.steps img {
  width: 100%;
  margin-top: var(--drop, 64px);
  aspect-ratio: 4 / 5;
  object-fit: cover;
  background: var(--surface);
}

/* ---------- Preguntas ---------- */

.faq {
  display: grid;
  grid-template-columns: minmax(0, 3fr) minmax(0, 9fr);
  gap: 48px clamp(32px, 4vw, 64px);
  background: var(--bone);
  color: var(--ink-dark);
}

.faq h2 {
  max-width: 8ch;
}

.faq-text {
  columns: 2;
  column-gap: 56px;
}

.faq-text p {
  margin-bottom: 24px;
  break-inside: avoid;
  line-height: 1.55;
}

.faq-text strong {
  font-weight: 600;
}

.faq ::selection {
  background: var(--ink-dark);
  color: var(--bone);
}

/* ---------- Contacto ---------- */

.contact {
  padding-top: 48px;
  overflow: hidden;
  background: var(--accent);
  color: var(--ink-dark);
  color-scheme: light;
}

.contact ::selection {
  background: var(--ink-dark);
  color: var(--accent);
}

.contact :focus-visible {
  outline-color: var(--ink-dark);
}

.strip {
  margin: 0 calc(var(--margin) * -1);
  overflow: hidden;
}

.strip-track {
  display: flex;
  gap: 8px;
  width: max-content;
}

.strip-track img {
  flex: none;
  width: auto;
  height: 150px;
  aspect-ratio: 3 / 4;
  object-fit: cover;
  background: var(--accent-press);
}

.strip-track img:nth-child(3n + 2) {
  aspect-ratio: 1;
}

.strip-track img:nth-child(3n) {
  aspect-ratio: 3 / 2;
}

.contact-layout {
  display: grid;
  grid-template-columns: minmax(0, 5fr) minmax(0, 7fr);
  gap: 48px clamp(32px, 5vw, 96px);
  margin-top: 72px;
}

.contact-copy .section-lead {
  max-width: 28ch;
}

.contact-info {
  display: grid;
  gap: 20px;
  margin-top: 48px;
}

.contact-info dt {
  font-size: var(--step-small);
}

.contact-info dd {
  font-size: var(--step-lead);
  font-weight: 500;
  line-height: 1.25;
  overflow-wrap: anywhere;
}

.contact-info a {
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 5px;
  text-decoration-color: rgba(18, 18, 18, 0.35);
  transition: text-decoration-color var(--fast) ease;
}

.contact-info a:hover {
  text-decoration-color: var(--ink-dark);
}

.cells {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.cell {
  display: grid;
  gap: 4px;
  padding: 16px 20px;
  background: #b8975a;
  font-size: var(--step-small);
  font-weight: 500;
  cursor: text;
  transition: background-color var(--fast) ease;
}

.cell:hover {
  background: #bd9d61;
}

.cell:focus-within {
  background: #e4d2a6;
}

.cell-wide {
  grid-column: 1 / -1;
}

.cell input,
.cell textarea {
  width: 100%;
  padding: 4px 0;
  border: 0;
  background: none;
  color: var(--ink-dark);
  font-size: var(--step-body);
  outline: 0;
  resize: vertical;
}

.cell textarea::placeholder {
  color: #4a3d22;
}

.contact-submit {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 16px;
  margin-top: 8px;
}

.contact-submit .button {
  min-width: 220px;
  min-height: 64px;
}

/* ---------- Estados de formulario ---------- */

.form-status {
  min-height: 1.5em;
  font-size: var(--step-small);
  font-weight: 500;
}

.form-status:empty {
  min-height: 0;
}

.form-status.error {
  color: var(--danger);
}

.form-status.success {
  color: var(--success);
}

.contact .form-status.error,
.cart-panel .form-status.error {
  color: var(--danger-dark);
}

.contact .form-status.success,
.cart-panel .form-status.success {
  color: var(--success-dark);
}

/* ---------- Pie de página en baldosas ---------- */

.site-footer {
  padding: var(--gap);
}

.tiles {
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  gap: var(--gap);
}

.tile-box {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 24px;
  min-height: 220px;
  padding: 24px;
  background: var(--surface);
}

.tile-statement {
  grid-column: span 4;
}

.tile-statement p {
  max-width: 24ch;
  font-size: var(--step-lead);
  line-height: 1.25;
}

.tile-statement small,
.tile-hours p:first-child,
.tile-mail p:first-child {
  color: var(--ink-soft);
  font-size: var(--step-small);
}

.tile-nav {
  grid-column: span 2;
  justify-content: flex-start;
  gap: 4px;
}

.tile-nav a {
  align-self: flex-start;
  padding: 2px 0;
  text-decoration: none;
  transition: color var(--fast) ease, transform var(--fast) var(--ease-out);
}

.tile-nav a:hover {
  color: var(--accent);
  transform: translateX(4px);
}

.tile-hours {
  grid-column: span 2;
}

.tile-mail {
  grid-column: span 4;
}

.tile-strong {
  font-size: var(--step-lead);
  font-weight: 500;
  line-height: 1.25;
  overflow-wrap: anywhere;
}

a.tile-strong {
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 5px;
  text-decoration-color: rgba(242, 239, 232, 0.35);
}

.tile-wordmark {
  grid-column: span 8;
  flex-direction: row;
  align-items: center;
  justify-content: center;
  gap: clamp(16px, 3vw, 48px);
  min-height: 320px;
  background: var(--ink);
  color: var(--ink-dark);
}

.tile-wordmark img {
  width: clamp(56px, 8vw, 120px);
  height: auto;
  filter: brightness(0.55) saturate(1.3);
}

.wordmark {
  font-size: var(--step-display);
  font-weight: 600;
  line-height: 0.9;
  letter-spacing: -0.05em;
  white-space: nowrap;
}

.tile-cta {
  grid-column: span 4;
  min-height: 320px;
  background: var(--accent);
  color: var(--ink-dark);
  text-decoration: none;
  transition: background-color var(--fast) ease;
}

.tile-cta span {
  max-width: 14ch;
  font-size: var(--step-lead);
  font-weight: 600;
  line-height: 1;
  letter-spacing: -0.03em;
}

.tile-cta svg {
  align-self: flex-end;
  width: 56px;
  height: 56px;
  fill: none;
  stroke: currentColor;
  stroke-width: 4;
  transition: transform var(--medium) var(--ease-out);
}

.tile-cta:hover {
  background: var(--accent-hover);
}

.tile-cta:hover svg {
  transform: translate(6px, -6px);
}

.site-footer :focus-visible {
  outline-offset: -4px;
}

/* ---------- Carrito ---------- */

.cart-panel {
  position: fixed;
  top: 0;
  right: 0;
  z-index: 60;
  display: flex;
  flex-direction: column;
  width: min(520px, 100%);
  height: 100dvh;
  background: var(--bone);
  color: var(--ink-dark);
  color-scheme: light;
  box-shadow: -30px 0 90px rgba(0, 0, 0, 0.45); /* taste-skill-ignore: panel flotante */
  transform: translateX(105%);
  visibility: hidden;
  transition:
    transform 360ms var(--ease-out),
    visibility 0s linear 360ms;
}

.cart-panel.is-open {
  transform: none;
  visibility: visible;
  transition: transform 360ms var(--ease-out);
}

.cart-panel :focus-visible {
  outline-color: var(--ink-dark);
}

.cart-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 20px 24px;
  background: var(--bone-2);
}

.cart-header h2 {
  font-size: clamp(1.75rem, 1.4rem + 1vw, 2.25rem);
}

.cart-header .icon-button {
  background: var(--bone);
}

.cart-body {
  flex: 1;
  overflow-y: auto;
  overscroll-behavior: contain;
  padding: 8px 24px 32px;
}

.cart-items .empty-state {
  padding: 32px 0;
}

.cart-item {
  display: grid;
  grid-template-columns: 72px minmax(0, 1fr);
  gap: 4px 16px;
  padding: 16px 0;
}

.cart-item + .cart-item {
  margin-top: 4px;
}

.cart-item img,
.cart-item .thumb-fill {
  grid-row: span 3;
  width: 72px;
  aspect-ratio: 3 / 4;
  object-fit: cover;
  background: var(--bone-2);
}

.cart-item-info strong {
  display: block;
  font-weight: 500;
  line-height: 1.3;
}

.cart-item-info span {
  color: var(--ink-dark-soft);
  font-size: var(--step-small);
}

.cart-item-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 8px 16px;
  margin-top: 8px;
}

.cart-item .qty {
  grid-template-columns: 40px 56px 40px;
  height: 40px;
}

.cart-item-price {
  font-weight: 600;
  font-variant-numeric: tabular-nums;
}

.remove-button {
  justify-self: start;
  padding: 4px 0;
  border: 0;
  background: none;
  color: var(--ink-dark-soft);
  font-size: var(--step-small);
  text-decoration: underline;
  text-underline-offset: 4px;
}

.remove-button:hover {
  color: var(--danger-dark);
}

.cart-totals {
  display: grid;
  gap: 8px;
  margin: 8px 0 0;
  padding: 20px;
  background: var(--bone-2);
  font-variant-numeric: tabular-nums;
}

.cart-totals:empty {
  display: none;
}

.cart-totals div {
  display: flex;
  justify-content: space-between;
  gap: 16px;
}

.cart-totals .grand-total {
  margin-top: 4px;
  font-size: var(--step-lead);
  font-weight: 600;
}

.totals-note {
  color: var(--ink-dark-soft);
  font-size: var(--step-small);
}

.totals-note.warn {
  color: var(--danger-dark);
  font-weight: 500;
}

.quote-form {
  display: grid;
  gap: 14px;
  margin-top: 32px;
}

.quote-form[hidden] {
  display: none;
}

.quote-form h3 {
  font-size: var(--step-lead);
  letter-spacing: -0.02em;
}

.form-row {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.form-note {
  color: var(--ink-dark-soft);
  font-size: var(--step-small);
}

.order-done {
  display: grid;
  align-content: center;
  justify-items: start;
  gap: 16px;
  flex: 1;
  padding: 32px 24px;
}

.order-done[hidden] {
  display: none;
}

.order-done-icon {
  width: 64px;
  height: 64px;
  padding: 12px;
  background: var(--ink-dark);
  fill: none;
  stroke: var(--accent);
  stroke-width: 4;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.order-done h3 {
  font-size: var(--step-head);
  line-height: 1;
  letter-spacing: -0.04em;
}

.cart-panel .button.primary {
  background: var(--ink-dark);
  color: var(--bone);
}

.cart-panel .button.primary:hover {
  background: #2a2a2a;
}

.cart-panel .button.secondary {
  background: var(--bone-2);
  color: var(--ink-dark);
}

.cart-panel .button.secondary:hover {
  background: var(--bone-3);
}

.panel-backdrop {
  position: fixed;
  inset: 0;
  z-index: 55;
  background: rgba(0, 0, 0, 0.6);
  opacity: 0;
  transition: opacity 300ms ease;
}

.panel-backdrop.is-visible {
  opacity: 1;
}

/* ---------- Aviso flotante y WhatsApp ---------- */

.toast {
  position: fixed;
  bottom: 24px;
  left: 50%;
  z-index: 80;
  max-width: calc(100% - 2 * var(--margin));
  padding: 14px 20px;
  background: var(--ink);
  color: var(--ink-dark);
  font-size: var(--step-small);
  font-weight: 500;
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.35); /* taste-skill-ignore: aviso flotante */
  opacity: 0;
  pointer-events: none;
  transform: translate(-50%, 16px);
  transition:
    opacity var(--medium) ease,
    transform var(--medium) var(--ease-out);
}

.toast.is-visible {
  opacity: 1;
  transform: translate(-50%, 0);
}

.whatsapp-fab {
  position: fixed;
  right: 20px;
  bottom: 20px;
  z-index: 50;
  display: grid;
  width: 56px;
  height: 56px;
  place-items: center;
  border-radius: 50%;
  background: var(--whatsapp);
  color: #fff;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.35); /* taste-skill-ignore: botón flotante */
  transition: transform var(--medium) var(--ease-out);
}

.whatsapp-fab:hover {
  transform: scale(1.08);
}

.whatsapp-fab:active {
  transform: scale(0.95);
}

.whatsapp-fab svg {
  width: 28px;
  height: 28px;
  fill: currentColor;
}

/* ---------- Apariciones al hacer scroll ---------- */

.js .reveal {
  opacity: 0;
  transform: translateY(24px);
  transition:
    opacity var(--slow) ease,
    transform var(--slow) var(--ease-out);
  transition-delay: var(--reveal-delay, 0ms);
}

.js .reveal.is-visible {
  opacity: 1;
  transform: none;
}

.product-card.is-new {
  animation: card-in 480ms var(--ease-out) both;
  animation-delay: calc(var(--i, 0) * 30ms);
}

@keyframes card-in {
  from {
    opacity: 0;
    transform: translateY(16px);
  }
}

/* ---------- Tableta ---------- */

@media (max-width: 1080px) {
  .main-nav a {
    padding: 10px 8px;
  }

  .catalog-head {
    grid-template-columns: 1fr;
  }

  .faq {
    grid-template-columns: 1fr;
  }

  .faq h2 {
    max-width: none;
  }

  .tile-statement {
    grid-column: span 6;
  }

  .tile-nav {
    grid-column: span 6;
  }

  .tile-hours {
    grid-column: span 6;
  }

  .tile-mail {
    grid-column: span 6;
  }

  .tile-wordmark,
  .tile-cta {
    grid-column: span 12;
  }

  .tile-wordmark {
    min-height: 240px;
  }

  .tile-cta {
    min-height: 200px;
  }
}

@media (max-width: 900px) {
  :root {
    --header-height: 60px;
  }

  .menu-toggle {
    display: block;
  }

  .main-nav {
    position: fixed;
    top: var(--header-height);
    right: 0;
    left: 0;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    padding: 8px var(--margin) 24px;
    background: var(--ground);
    opacity: 0;
    visibility: hidden;
    transform: translateY(-8px);
    transition:
      opacity var(--medium) ease,
      transform var(--medium) var(--ease-out),
      visibility 0s linear var(--medium);
  }

  .main-nav.is-open {
    opacity: 1;
    visibility: visible;
    transform: none;
    transition:
      opacity var(--medium) ease,
      transform var(--medium) var(--ease-out);
  }

  .main-nav a {
    padding: 14px 0;
    color: var(--ink);
    font-size: var(--step-lead);
  }

  .header-actions {
    margin-left: auto;
  }

  .hero-bottom {
    grid-template-columns: 1fr;
  }

  .hero-actions {
    flex-wrap: wrap;
  }

  .sectors-layout,
  .custom-head,
  .studio,
  .contact-layout {
    grid-template-columns: 1fr;
  }

  .index-preview {
    display: none;
  }

  .index-row {
    grid-template-columns: 48px minmax(0, 1fr) auto;
    gap: 16px;
    padding: 12px 0;
  }

  .index-thumb {
    display: block;
    width: 48px;
    height: 64px;
    object-fit: cover;
    background: var(--surface);
  }

  .index:hover .index-row:not(:hover) {
    opacity: 1;
  }

  .index-row:hover .index-name {
    transform: none;
  }

  .studio {
    margin-top: 32px;
  }

  .stage {
    position: relative;
    top: 0;
    min-height: 0;
  }

  .faq-text {
    columns: 1;
  }

  .steps-nav {
    display: none;
  }

  .steps li {
    flex-basis: 72vw;
  }

  .steps img {
    margin-top: calc(var(--drop, 64px) / 2.5);
  }
}

/* ---------- Teléfono ---------- */

@media (max-width: 640px) {
  .brand-text {
    font-size: 1rem;
  }

  .nav-cart {
    padding-left: 12px;
  }

  .hero {
    min-height: 620px;
  }

  .hero-actions {
    flex-direction: column;
    align-items: stretch;
    gap: 4px;
    padding-right: 0;
  }

  .hero-actions .text-link {
    justify-content: center;
  }

  .hero-actions .button {
    width: 100%;
  }

  .catalog-tools {
    grid-template-columns: 1fr;
  }

  .quick-filters {
    flex-wrap: nowrap;
    margin-right: calc(var(--margin) * -1);
    margin-left: calc(var(--margin) * -1);
    padding: 0 var(--margin);
    overflow-x: auto;
    scrollbar-width: none;
  }

  .quick-filters::-webkit-scrollbar {
    display: none;
  }

  .chip {
    flex: none;
  }

  .product-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 32px 8px;
  }

  .product-card .quick-add {
    display: none !important;
  }

  .product-dialog {
    width: 100%;
    max-width: 100%;
    height: 100dvh;
    max-height: 100dvh;
    margin: 0;
  }

  .dialog-inner {
    display: block;
    height: 100dvh;
    max-height: 100dvh;
    overflow-y: auto;
  }

  .dialog-media img {
    height: auto;
    max-height: 56svh;
    aspect-ratio: 3 / 4;
  }

  .dialog-body {
    padding: 28px var(--margin) 40px;
    overflow: visible;
  }

  .dialog-close {
    position: fixed;
    top: 12px;
    right: 12px;
    z-index: 2;
  }

  .panel-block {
    padding: 18px;
  }

  .logo-file img {
    width: 48px;
    height: 48px;
  }

  .logo-file {
    grid-template-columns: 48px auto auto minmax(0, 1fr);
  }

  .segmented span {
    padding: 0 6px;
  }

  .cells {
    grid-template-columns: 1fr;
  }

  .contact-submit {
    grid-template-columns: 1fr;
  }

  .contact-submit .button {
    width: 100%;
  }

  .strip-track img {
    height: 110px;
  }

  .form-row {
    grid-template-columns: 1fr;
  }

  .tile-box {
    min-height: 0;
    padding: 20px;
  }

  .tile-statement,
  .tile-hours {
    grid-column: span 12;
  }

  .tile-nav,
  .tile-mail {
    grid-column: span 12;
  }

  .tile-wordmark {
    order: -2;
    min-height: 160px;
  }

  .tile-cta {
    order: -1;
    min-height: 160px;
  }

  .whatsapp-fab {
    right: 16px;
    bottom: 16px;
    width: 52px;
    height: 52px;
  }
}

/* ---------- Pantallas con ratón: la vista previa del índice ---------- */

@media (hover: none) {
  .product-card .quick-add {
    display: none;
  }
}

/* ---------- Movimiento reducido ---------- */

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    animation-duration: 1ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 1ms !important;
    transition-delay: 0ms !important;
  }

  .js .reveal {
    opacity: 1;
    transform: none;
  }
}

/* ==========================================================
   Ficha de producto y carrito: negro con detalles dorados y esquinas redondeadas
   ========================================================== */

.product-dialog,
.cart-panel {
  --panel: #111111;
  --panel-2: #1c1c1c;
  --panel-3: #262626;
  --panel-line: rgba(198, 166, 100, 0.28);
  --round: 14px;
  background: var(--panel);
  color: var(--ink);
  color-scheme: dark;
}

.product-dialog {
  border-radius: 20px;
  outline: 1px solid var(--panel-line); /* taste-skill-ignore: filo dorado del panel flotante */
}

.product-dialog :focus-visible,
.cart-panel :focus-visible {
  outline-color: var(--accent);
}

.dialog-media {
  background: var(--panel-2);
}

.dialog-body .meta,
.dialog-body .option-group legend span,
.min-qty,
.product-dialog .field em,
.product-dialog .dialog-price small {
  color: var(--ink-soft);
}

.dialog-body .meta {
  color: var(--accent);
}

.dialog-desc {
  color: var(--ink-soft);
}

.dialog-price {
  color: var(--accent);
}

.product-dialog .icon-button,
.cart-panel .icon-button {
  border-radius: 999px;
  background: var(--panel-2);
  color: var(--ink);
}

.product-dialog .icon-button:hover,
.cart-panel .icon-button:hover {
  background: var(--panel-3);
  color: var(--accent);
}

.product-dialog .option span {
  border-radius: 999px;
  background: var(--panel-2);
  color: var(--ink);
  outline: 1px solid transparent; /* taste-skill-ignore: estado de opción */
  transition: background-color var(--fast) ease, color var(--fast) ease, outline-color var(--fast) ease;
}

.product-dialog .option input:hover + span {
  background: var(--panel-3);
  outline-color: var(--panel-line);
}

.product-dialog .option input:checked + span {
  background: var(--accent);
  color: var(--ink-dark);
}

.product-dialog .option input:focus-visible + span {
  outline: 2px solid var(--accent);
}

.product-dialog .field select,
.cart-panel .field input,
.cart-panel .field textarea {
  border-radius: var(--round);
  background-color: var(--panel-2);
  color: var(--ink);
}

.product-dialog .field select {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23c6a664' stroke-width='2' stroke-linecap='round'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E");
}

.product-dialog .field select:hover,
.cart-panel .field input:hover,
.cart-panel .field textarea:hover {
  background-color: var(--panel-3);
}

.product-dialog .field select:focus,
.cart-panel .field input:focus,
.cart-panel .field textarea:focus {
  outline: 2px solid var(--accent);
  background-color: var(--panel-3);
}

.cart-panel .field input::placeholder,
.cart-panel .field textarea::placeholder {
  color: #8d887e;
}

.product-dialog .qty,
.cart-panel .qty {
  overflow: hidden;
  border-radius: 999px;
  background: var(--panel-2);
}

.product-dialog .qty button:hover,
.cart-panel .qty button:hover {
  background: var(--panel-3);
  color: var(--accent);
}

.dialog-actions .button.primary,
.cart-panel .button.primary {
  border-radius: 999px;
  background: var(--accent);
  color: var(--ink-dark);
}

.dialog-actions .button.primary:hover,
.cart-panel .button.primary:hover {
  background: var(--accent-hover);
}

.product-dialog .text-link {
  color: var(--accent);
}

.dialog-body::-webkit-scrollbar,
.cart-body::-webkit-scrollbar {
  width: 8px;
}

.dialog-body::-webkit-scrollbar-thumb,
.cart-body::-webkit-scrollbar-thumb {
  border-radius: 999px;
  background: var(--panel-3);
}

/* Carrito */

.cart-panel {
  border-radius: 24px 0 0 24px;
  outline: 1px solid var(--panel-line); /* taste-skill-ignore: filo dorado del panel flotante */
}

.cart-header {
  background: none;
  padding: 24px 24px 12px;
}

.cart-header h2 {
  color: var(--ink);
}

.cart-header h2::after {
  content: "";
  display: block;
  width: 40px;
  height: 3px;
  margin-top: 12px;
  border-radius: 3px;
  background: var(--accent);
}

.cart-item {
  padding: 14px;
  border-radius: 18px;
  background: var(--panel-2);
}

.cart-item + .cart-item {
  margin-top: 10px;
}

.cart-item img,
.cart-item .thumb-fill {
  border-radius: 12px;
  background: var(--panel-3);
}

.cart-item-info span,
.cart-panel .totals-note,
.cart-panel .form-note,
.cart-panel .field em,
.cart-panel .empty-state {
  color: var(--ink-soft);
}

.cart-item .qty {
  background: var(--panel-3);
}

.cart-item-price {
  color: var(--accent);
}

.cart-panel .remove-button {
  color: var(--ink-soft);
}

.cart-panel .remove-button:hover {
  color: var(--danger);
}

.cart-totals {
  margin-top: 14px;
  border-radius: 18px;
  background: var(--ground);
  outline: 1px solid var(--panel-line); /* taste-skill-ignore: filo dorado del total */
  color: var(--ink-soft);
}

.cart-totals .grand-total {
  color: var(--accent);
}

.cart-panel .totals-note.warn {
  color: var(--accent);
}

.quote-form h3 {
  color: var(--ink);
}

.cart-panel .button.secondary {
  border-radius: 999px;
  background: var(--panel-2);
  color: var(--ink);
}

.cart-panel .button.secondary:hover {
  background: var(--panel-3);
}

.cart-panel .form-status.error {
  color: var(--danger);
}

.cart-panel .form-status.success {
  color: var(--success);
}

.order-done {
  justify-items: center;
  text-align: center;
}

.order-done-icon {
  border-radius: 999px;
  background: var(--panel-2);
  outline: 1px solid var(--panel-line); /* taste-skill-ignore: filo dorado del icono */
}

.order-done strong {
  color: var(--accent);
}

.cart-count {
  border-radius: 999px;
}

.nav-cart {
  border-radius: 999px;
}

@media (max-width: 640px) {
  .product-dialog {
    border-radius: 0;
    outline: 0;
  }

  .cart-panel {
    border-radius: 0;
  }

  .dialog-inner {
    height: 100dvh;
  }
}

/* ==========================================================
   Formas redondeadas en toda la web, a juego con el carrito
   ========================================================== */

.button,
.chip,
.nav-cart,
.menu-toggle,
.square-button,
.skip-link,
.toast {
  border-radius: 999px;
}

.field input,
.field select,
.field textarea,
.cell,
.cart-totals {
  border-radius: 14px;
}

.product-card .media,
.skeleton span:first-child,
.index-preview img,
.steps img,
.strip-track img,
.tile,
.index-thumb {
  border-radius: 14px;
}

.product-card .media .quick-add {
  border-radius: 999px;
}

.tile-box {
  border-radius: 20px;
}

.steps-progress,
.steps-progress span {
  border-radius: 999px;
}

.main-nav a {
  border-radius: 999px;
}

.contact-submit .button {
  min-height: 60px;
}

@media (max-width: 900px) {
  .main-nav {
    border-radius: 0 0 20px 20px;
  }
}

/* ---------- Pedido: abrir la ficha desde cada prenda ---------- */

.cart-thumb {
  grid-row: span 3;
  align-self: start;
  padding: 0;
  border: 0;
  border-radius: 12px;
  background: none;
  overflow: hidden;
}

.cart-thumb img,
.cart-thumb .thumb-fill {
  display: block;
  transition: transform var(--medium) var(--ease-out);
}

.cart-item-name {
  display: block;
  padding: 0;
  border: 0;
  background: none;
  color: var(--ink);
  font-weight: 500;
  line-height: 1.3;
  text-align: left;
  text-decoration: underline;
  text-decoration-color: transparent;
  text-underline-offset: 4px;
  transition:
    color var(--fast) ease,
    text-decoration-color var(--fast) ease;
}

.cart-item-name:hover {
  color: var(--accent);
  text-decoration-color: currentColor;
}

.cart-item-links {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 4px 20px;
}

.more-button {
  padding: 4px 0;
  border: 0;
  background: none;
  color: var(--accent);
  font-size: var(--step-small);
  font-weight: 500;
  text-decoration: underline;
  text-decoration-color: rgba(198, 166, 100, 0.4);
  text-underline-offset: 4px;
  transition: text-decoration-color var(--fast) ease;
}

.more-button:hover {
  text-decoration-color: currentColor;
}

@media (hover: hover) and (pointer: fine) {
  .cart-thumb:hover img,
  .cart-thumb:hover .thumb-fill {
    transform: scale(1.06);
  }
}

/* En la ficha: lo que ya hay de esa prenda en el pedido */

.in-cart {
  padding: 14px 16px;
  border-radius: 14px;
  background: var(--panel-2);
}

.in-cart p {
  margin-bottom: 8px;
  color: var(--accent);
  font-size: var(--step-small);
  font-weight: 600;
}

.in-cart ul {
  display: grid;
  gap: 4px;
  padding: 0;
  list-style: none;
  font-size: var(--step-small);
}

.in-cart li {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  color: var(--ink-soft);
}

.in-cart strong {
  color: var(--ink);
  font-variant-numeric: tabular-nums;
}

/* ---------- Editor de prendas: piezas del dibujo ---------- */

.tee-piece {
  fill: var(--garment);
  transition: fill 350ms ease;
}

.tee-button {
  fill: rgba(255, 255, 255, 0.32);
}

.tee.is-light .tee-button {
  fill: rgba(0, 0, 0, 0.3);
}

.tee-string {
  fill: none;
  stroke: rgba(255, 255, 255, 0.55);
  stroke-width: 4;
  stroke-linecap: round;
}

.tee.is-light .tee-string {
  stroke: rgba(0, 0, 0, 0.35);
}

/* ---------- Editor de prendas: panel ---------- */

.type-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
  margin: 0;
  padding: 0;
  border: 0;
}

.type-tile {
  position: relative;
}

.type-tile input {
  position: absolute;
  inset: 0;
  opacity: 0;
  cursor: pointer;
}

.type-tile > span {
  display: grid;
  justify-items: center;
  gap: 6px;
  padding: 12px 6px 10px;
  border-radius: 16px;
  background: var(--ground);
  color: var(--ink-soft);
  transition:
    background-color var(--fast) ease,
    color var(--fast) ease;
}

.type-tile svg {
  width: 44px;
  height: 48px;
  fill: none;
  stroke: currentColor;
  stroke-width: 14;
  stroke-linejoin: round;
  stroke-linecap: round;
}

.type-tile small {
  font-size: var(--step-small);
  font-weight: 500;
  line-height: 1.2;
  text-align: center;
}

.type-tile input:hover + span {
  color: var(--ink);
}

.type-tile input:checked + span {
  background: var(--accent);
  color: var(--ink-dark);
}

.type-tile input:focus-visible + span {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

.side-tabs {
  display: grid;
  grid-template-columns: 1fr 1fr;
  padding: 4px;
  border-radius: 999px;
  background: var(--ground);
}

.side-tabs button {
  min-height: 44px;
  border: 0;
  border-radius: 999px;
  background: none;
  color: var(--ink-soft);
  font-weight: 600;
  transition:
    background-color var(--fast) ease,
    color var(--fast) ease;
}

.side-tabs button:hover {
  color: var(--ink);
}

.side-tabs button[aria-pressed="true"] {
  background: var(--ink);
  color: var(--ink-dark);
}

.side-editor {
  display: grid;
  gap: 10px;
}

.element-card {
  display: grid;
  gap: 16px;
  padding: 18px;
  border-radius: 18px;
  background: var(--surface-3);
}

.element-card .segmented-track {
  background: var(--surface-2);
}

.element-head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 8px 16px;
}

.element-head h4 {
  margin: 0;
  font-size: var(--step-body);
  font-weight: 600;
}

.element-meta,
.element-hint {
  color: var(--ink-soft);
  font-size: var(--step-small);
}

.element-hint {
  margin: -4px 0 0;
}

.switch input:disabled + .switch-track {
  opacity: 0.4;
}

.element-card .field input {
  background: var(--surface-2);
}

.font-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 6px;
  margin: 0;
  padding: 0;
  border: 0;
}

.font-grid legend {
  margin-bottom: 10px;
  padding: 0;
  font-size: var(--step-small);
  font-weight: 500;
}

.font-grid label {
  position: relative;
}

.font-grid input {
  position: absolute;
  inset: 0;
  opacity: 0;
  cursor: pointer;
}

.font-grid span {
  display: grid;
  min-height: 46px;
  place-items: center;
  padding: 0 6px;
  border-radius: 12px;
  background: var(--surface-2);
  font-size: 1rem;
  line-height: 1.1;
  text-align: center;
  transition:
    background-color var(--fast) ease,
    color var(--fast) ease;
}

.font-grid input:hover + span {
  background: #303030;
}

.font-grid input:checked + span {
  background: var(--accent);
  color: var(--ink-dark);
}

.font-grid input:focus-visible + span {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

@media (max-width: 640px) {
  .font-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .element-card {
    padding: 14px;
  }
}

/* Los fieldset no se encogen por defecto: sin esto el panel desborda la página */
.studio-panel fieldset {
  min-width: 0;
}

.studio > * {
  min-width: 0;
}

.element-card .segmented span {
  min-height: 40px;
  padding: 0 4px;
  font-size: 0.8125rem;
  line-height: 1.15;
}

.switch[hidden] {
  display: none;
}

/* En móvil y tableta la prenda se queda fija arriba mientras se editan las opciones */
@media (max-width: 900px) {
  .stage {
    position: sticky;
    top: var(--header-height);
    z-index: 5;
    gap: 4px;
    padding: 12px;
    border-radius: 0 0 20px 20px;
  }

  .stage-chip {
    display: none;
  }

  .view-toggle button {
    min-height: 36px;
  }

  .tee {
    width: auto;
    max-width: 100%;
    height: 34svh;
    margin: 0;
  }
}

/* Visor 3D de la prenda (js/visor3d.js). Hasta que pinta su primer fotograma se ve el dibujo. */
.stage {
  position: sticky;
}

.stage-3d {
  display: none;
  position: relative;
  min-height: 0;
  margin: 0 -20px -20px;
  cursor: grab;
  touch-action: pan-y;
}

.stage-3d canvas {
  display: block;
  width: 100%;
  height: 100%;
  outline: none;
}

.stage-3d.is-dragging {
  cursor: grabbing;
}

.stage.is-3d-ready .stage-3d {
  display: block;
}

.stage.is-3d-ready .tee {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
}

.stage-loading {
  position: absolute;
  top: 50%;
  left: 50%;
  z-index: 1;
  padding: 8px 14px;
  border-radius: 999px;
  background: rgba(0, 0, 0, 0.6);
  color: var(--ink);
  font-size: var(--step-small);
  opacity: 0;
  transform: translate(-50%, -50%);
  transition: opacity var(--medium) ease;
  pointer-events: none;
}

.stage-3d.is-loading .stage-loading {
  opacity: 1;
  transition-delay: 200ms;
}

.stage-hint {
  display: none;
  position: absolute;
  bottom: 18px;
  left: 50%;
  align-items: center;
  gap: 8px;
  padding: 7px 14px;
  border-radius: 999px;
  background: rgba(0, 0, 0, 0.07);
  font-size: var(--step-small);
  font-weight: 500;
  white-space: nowrap;
  transform: translateX(-50%);
  pointer-events: none;
}

.stage.is-dark .stage-hint {
  background: rgba(255, 255, 255, 0.08);
}

.stage-hint svg {
  width: 16px;
  height: 16px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.stage.is-3d-ready .stage-hint {
  display: inline-flex;
}

@media (max-width: 900px) {
  .stage-3d {
    height: 36svh;
    margin: 0 -12px -12px;
  }

  .stage-hint {
    bottom: 10px;
    padding: 5px 12px;
  }
}

.tile-statement .credits {
  display: block;
  margin-top: 10px;
  color: var(--ink-soft);
  font-size: 0.75rem;
  line-height: 1.5;
}

.tile-statement .credits a {
  text-decoration: underline;
  text-underline-offset: 2px;
}

.stage-hint {
  transition: opacity var(--medium) ease;
}

.stage-3d.has-rotated + .stage-hint {
  opacity: 0;
}

/* Color libre: muestra arcoiris que abre el selector del sistema */
.dot-custom > span {
  background:
    radial-gradient(circle, var(--swatch) 0 46%, transparent 48%),
    conic-gradient(#e53935, #fdd835, #43a047, #1e88e5, #8e24aa, #e53935); /* taste-skill-ignore: muestra de color libre */
}

.dot-custom:not(.is-set) > span {
  background: conic-gradient(#e53935, #fdd835, #43a047, #1e88e5, #8e24aa, #e53935); /* taste-skill-ignore: muestra de color libre */
}

.dots .dot-custom input[type="color"],
.segmented-custom input[type="color"] {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  padding: 0;
  border: 0;
  opacity: 0;
  cursor: pointer;
}

.dot-custom:has(input[type="color"]:focus-visible) > span,
.segmented-custom:has(input[type="color"]:focus-visible) > span {
  outline: 2px solid var(--ink);
  outline-offset: 3px;
}

.segmented-custom span {
  gap: 6px;
  grid-auto-flow: column;
}

.segmented-custom i {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: conic-gradient(#e53935, #fdd835, #43a047, #1e88e5, #8e24aa, #e53935); /* taste-skill-ignore: muestra de color libre */
}

.segmented-custom input[type="radio"]:checked + span i {
  background: var(--swatch);
  box-shadow: 0 0 0 1.5px var(--ink-dark);
}

/* Tamaño libre y colocación */
.range {
  grid-template-columns: auto minmax(0, 1fr) 3.5em;
}

.range output {
  color: var(--ink-soft);
  font-variant-numeric: tabular-nums;
  text-align: right;
}

.place {
  display: grid;
  gap: 8px;
}

.place-title {
  font-size: var(--step-small);
  font-weight: 500;
}

.place-row {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.place .element-hint {
  margin: 0;
}

/* Lo que se puede arrastrar en el dibujo 2D */
.tee [data-print] {
  cursor: move;
}

.stage-3d,
.tee {
  touch-action: none;
}

.stage-3d.over-print {
  cursor: move;
}

.stage-3d.is-moving {
  cursor: grabbing;
}

/* ---------- Portada en móvil: titular arriba, botón grande y accesos con foto ---------- */

.hero-cta svg {
  width: 20px;
  height: 20px;
  fill: currentColor;
}

.shortcuts {
  display: none;
}

@media (max-width: 700px) {
  .hero {
    display: flex;
    flex-direction: column;
    height: auto;
    min-height: 0;
    max-height: none;
  }

  .hero-content {
    position: relative;
    inset: auto;
    order: -1;
    padding: 28px var(--margin) 20px;
    text-align: center;
  }

  .hero h1 {
    font-size: clamp(2.6rem, 12.5vw, 3.6rem);
    line-height: 0.92;
  }

  .hero-bottom {
    margin-top: 16px;
    gap: 20px;
  }

  .hero-bottom p {
    max-width: 34ch;
    margin: 0 auto;
    color: var(--ink-soft);
    font-size: 1rem;
  }

  .hero-actions {
    gap: 12px;
  }

  .hero-actions .hero-cta {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    min-height: 64px;
    font-size: 1.2rem;
    font-weight: 700;
    box-shadow: 0 10px 30px rgba(198, 166, 100, 0.28);
  }

  .hero-actions .hero-wa {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 52px;
    border: 1.5px solid rgba(255, 255, 255, 0.22);
    border-radius: 999px;
    font-size: 1rem;
    font-weight: 600;
  }

  /* Las fotos pasan debajo, en dos filas, fundidas por arriba con el fondo */
  .hero-scrim {
    display: none;
  }

  .wall {
    height: 300px;
    padding-top: 0;
    -webkit-mask-image: linear-gradient(180deg, transparent 0, #000 22%); /* taste-skill-ignore: fundido de las fotos con el fondo */
    mask-image: linear-gradient(180deg, transparent 0, #000 22%); /* taste-skill-ignore: fundido de las fotos con el fondo */
  }

  .wall-row:nth-child(n + 3) {
    display: none;
  }

  /* ¿Qué buscas? */
  .shortcuts {
    display: block;
    padding: 36px var(--margin) 12px;
    background: var(--ground);
  }

  .shortcuts h2 {
    margin-bottom: 16px;
    font-size: 1.75rem;
    text-align: center;
  }

  .shortcut-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
  }

  .shortcut {
    position: relative;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    min-height: 190px;
    padding: 14px;
    overflow: hidden;
    border: 0;
    border-radius: 20px;
    background: var(--surface-2);
    color: var(--ink);
    text-align: left;
    text-decoration: none;
    isolation: isolate;
  }

  .shortcut img {
    position: absolute;
    inset: 0;
    z-index: -2;
    width: 100%;
    height: 100%;
    object-fit: cover;
  }

  .shortcut::after {
    content: "";
    position: absolute;
    inset: 0;
    z-index: -1;
    background: linear-gradient(180deg, rgba(11, 11, 11, 0) 35%, rgba(11, 11, 11, 0.88) 100%); /* taste-skill-ignore: velo para leer el nombre sobre la foto */
  }

  .shortcut .index-name {
    font-size: 1.2rem;
    font-weight: 700;
    line-height: 1.1;
  }

  .shortcut small {
    margin-top: 4px;
    color: rgba(240, 239, 236, 0.75);
    font-size: 0.85rem;
  }

  .shortcut-custom {
    box-shadow: inset 0 0 0 2px var(--accent);
  }

  .shortcut-custom small {
    align-self: flex-start;
    margin-top: 6px;
    padding: 3px 10px;
    border-radius: 999px;
    background: var(--accent);
    color: var(--ink-dark);
    font-weight: 600;
  }

  .shortcut:active {
    transform: scale(0.98);
  }
}

/* Titular: "con tu marca" en puntos (js/efectos.js). El texto real queda debajo, transparente. */
.hero h1 em.is-dotted {
  position: relative;
  color: transparent;
}

.dot-text {
  position: absolute;
  pointer-events: none;
}

/* ---------- Catálogo compacto: al entrar desde un sector se ven las prendas enseguida ---------- */

.catalog {
  padding-top: clamp(40px, 2vw + 28px, 72px);
}

.catalog-head {
  gap: 12px 48px;
  scroll-margin-top: 12px;
}

.catalog-head h2 {
  font-size: clamp(1.75rem, 1.2rem + 1.8vw, 2.75rem);
}

.catalog-head .section-lead {
  max-width: 52ch;
  margin-top: 8px;
  font-size: var(--step-small);
}

.catalog-tools .field > span {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
}

.catalog-tools .field input,
.catalog-tools .field select {
  min-height: 46px;
  border-radius: 999px;
}

.quick-filters {
  margin-top: 16px;
}

.quick-filters .chip {
  min-height: 40px;
  padding: 0 16px;
}

.catalog-count {
  margin-top: 14px;
  font-size: 0.95rem;
}

.catalog-count strong {
  color: var(--ink-dark);
  font-weight: 700;
}

.product-grid {
  margin-top: 14px;
}

@media (max-width: 700px) {
  .catalog {
    padding-top: 24px;
  }

  .catalog-head .section-lead {
    display: none;
  }

  /* En móvil sobran el título de categoría y el desplegable: ya están los botones de abajo */
  .catalog-tools {
    grid-template-columns: 1fr;
  }

  .catalog-tools .field:not(.search-field) {
    display: none;
  }

  .quick-filters {
    margin-top: 12px;
  }

  .catalog-count {
    margin-top: 10px;
  }
}
