/* =====================================================================
   ESTILOS DE LA WEB — D'Detalles Studio
   Mobile-first: los estilos base son para celular; los @media agregan
   ajustes para pantallas más grandes. Colores/fuentes: tokens.css
   ===================================================================== */

/* ===== BASE ===== */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: calc(var(--header-h) + 1rem); }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: 0.01ms !important; transition-duration: 0.01ms !important; }
}
body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 1rem;
  line-height: 1.6;
  color: var(--color-text);
  background: var(--color-bg);
  overflow-x: hidden;
}
img, canvas, svg { display: block; max-width: 100%; }
img { height: auto; }
h1, h2, h3 { font-family: var(--font-display); color: var(--color-burgundy); line-height: 1.2; margin: 0 0 0.5em; }
h1 { font-size: clamp(2rem, 6vw, 3.25rem); font-weight: 700; letter-spacing: -0.01em; }
h2 { font-size: clamp(1.6rem, 4.5vw, 2.25rem); font-weight: 600; }
h3 { font-size: 1.25rem; font-weight: 600; }
p { margin: 0 0 1em; }
a { color: var(--color-burgundy); text-underline-offset: 0.18em; }
a:hover { color: var(--color-burgundy-hover); }
button, input, select, textarea { font: inherit; color: inherit; }
:focus-visible { outline: 3px solid var(--color-focus); outline-offset: 3px; border-radius: 4px; }
[hidden] { display: none !important; }

.visually-hidden {
  position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}
.skip-link {
  position: absolute; left: 1rem; top: -4rem; z-index: 100;
  background: var(--color-burgundy); color: #fff; padding: 0.75rem 1rem; border-radius: var(--radius-sm);
}
.skip-link:focus { top: 1rem; color: #fff; }

.container { width: 100%; max-width: var(--container); margin-inline: auto; padding-inline: var(--gutter); }
.section { padding-block: clamp(3rem, 8vw, 5.5rem); }
.section--alt { background: var(--color-bg-alt); }
.section__head { text-align: center; max-width: 42rem; margin: 0 auto 2.5rem; }
.section__head p { color: var(--color-text-muted); }
.eyebrow {
  display: inline-block; font-size: 0.75rem; font-weight: 700; letter-spacing: 0.12em; text-transform: uppercase;
  color: var(--color-gold-text); margin-bottom: 0.5rem;
}
.lead { font-size: 1.125rem; color: var(--color-text-muted); }

/* ===== AVISO DE NÚMERO NO CONFIGURADO ===== */
.config-banner {
  background: var(--color-warning-bg); color: var(--color-warning); border-bottom: 1px solid #f0d58a;
  font-size: 0.875rem; padding: 0.5rem var(--gutter); text-align: center;
}
.config-banner strong { font-weight: 700; }

/* ===== BOTONES ===== */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 0.5rem;
  min-height: 2.75rem; padding: 0.7rem 1.25rem; border-radius: var(--radius-sm);
  border: 1.5px solid transparent; font-weight: 600; font-size: 0.95rem; line-height: 1.2;
  text-decoration: none; cursor: pointer; transition: background-color 0.2s, box-shadow 0.2s, transform 0.1s;
}
.btn:active { transform: translateY(1px); }
.btn svg { width: 1.25rem; height: 1.25rem; flex-shrink: 0; }
.btn--primary { background: var(--color-burgundy); color: #fff; border-color: #731a2d; }
.btn--primary:hover { background: var(--color-burgundy-hover); color: #fff; box-shadow: var(--glow-gold); }
.btn--whatsapp { background: var(--color-pine); color: #fff; }
.btn--whatsapp:hover { background: var(--color-pine-hover); color: #fff; }
.btn--outline { background: transparent; color: var(--color-burgundy); border-color: var(--color-gold); }
.btn--outline:hover { background: var(--color-gold-wash); color: var(--color-burgundy); }
.btn--ghost { background: transparent; color: var(--color-text-muted); }
.btn--ghost:hover { background: var(--color-bg-alt); color: var(--color-text); }
.btn--block { width: 100%; }
.btn--lg { min-height: 3.25rem; font-size: 1.05rem; padding-inline: 1.5rem; }
.btn[disabled], .btn[aria-disabled='true'] { opacity: 0.55; cursor: not-allowed; box-shadow: none; }

/* ===== ENCABEZADO ===== */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(251, 249, 245, 0.92); backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--color-border);
}
.site-header__inner { display: flex; align-items: center; justify-content: space-between; gap: 1rem; min-height: var(--header-h); }
.brand { display: inline-flex; align-items: center; text-decoration: none; }
.brand img { height: 2.75rem; width: auto; }
.nav-toggle {
  display: inline-flex; align-items: center; justify-content: center; width: 2.75rem; height: 2.75rem;
  border: 1px solid var(--color-border-strong); background: var(--color-surface); border-radius: var(--radius-sm); cursor: pointer;
}
.nav-toggle svg { width: 1.5rem; height: 1.5rem; }
.header-actions { display: flex; align-items: center; gap: 0.5rem; }
.order-link {
  position: relative; display: inline-flex; align-items: center; gap: 0.4rem; min-height: 2.75rem; padding: 0.5rem 0.75rem;
  border-radius: var(--radius-sm); text-decoration: none; font-weight: 600; color: var(--color-burgundy);
}
.order-link:hover { background: var(--color-bg-alt); }
.order-link svg { width: 1.4rem; height: 1.4rem; }
.order-badge {
  min-width: 1.35rem; height: 1.35rem; padding: 0 0.35rem; border-radius: var(--radius-full);
  background: var(--color-burgundy); color: #fff; font-size: 0.75rem; font-weight: 700;
  display: inline-flex; align-items: center; justify-content: center;
}
.order-badge[data-count="0"] { background: #e9dfcf; color: var(--color-text); }
.order-link__label { display: none; }

.main-nav { display: none; }
.main-nav.is-open {
  display: block; position: absolute; top: 100%; left: 0; right: 0;
  background: var(--color-bg); border-bottom: 1px solid var(--color-border); box-shadow: var(--shadow-float);
}
.main-nav ul { list-style: none; margin: 0; padding: 0.5rem var(--gutter) 1rem; }
.main-nav a {
  display: block; padding: 0.85rem 0.5rem; text-decoration: none; font-weight: 600; color: var(--color-text);
  border-bottom: 1px solid var(--color-border);
}
.main-nav a:hover, .main-nav a[aria-current='page'] { color: var(--color-burgundy); }
.main-nav a[aria-current='page'] { text-decoration: underline; text-decoration-color: var(--color-gold); text-decoration-thickness: 2px; }

@media (min-width: 960px) {
  .nav-toggle { display: none; }
  .main-nav, .main-nav.is-open { display: block; position: static; box-shadow: none; border: 0; background: none; }
  .main-nav ul { display: flex; gap: 0.25rem; padding: 0; }
  .main-nav a { border: 0; padding: 0.5rem 0.75rem; border-radius: var(--radius-sm); font-size: 0.95rem; }
  .main-nav a:hover { background: var(--color-bg-alt); }
  .order-link__label { display: inline; }
}

/* ===== HERO ===== */
.hero { position: relative; overflow: hidden; padding-block: clamp(2.5rem, 7vw, 5rem); background:
  radial-gradient(ellipse at 85% 10%, rgba(229, 195, 120, 0.28), transparent 55%),
  radial-gradient(ellipse at 0% 100%, rgba(91, 14, 30, 0.07), transparent 50%), var(--color-bg); }
.hero__grid { display: grid; gap: 2.5rem; align-items: center; }
.hero__text .lead { max-width: 36rem; }
.hero__badges { display: flex; flex-wrap: wrap; gap: 0.5rem; margin: 1.25rem 0 1.75rem; padding: 0; list-style: none; }
.hero__badges li {
  display: inline-flex; align-items: center; gap: 0.4rem; padding: 0.35rem 0.8rem; border-radius: var(--radius-full);
  background: var(--color-surface); border: 1px solid var(--color-border); font-size: 0.85rem; font-weight: 600;
}
.hero__badges svg { width: 1rem; height: 1rem; color: var(--color-gold-text); }
.hero__ctas { display: flex; flex-wrap: wrap; gap: 0.75rem; }
/* Foto principal a la izquierda y dos apiladas a la derecha */
.hero__gallery { display: grid; grid-template-columns: 2fr 1fr; align-items: stretch; gap: 0.75rem; max-width: 34rem; margin-inline: auto; }
.hero__gallery picture:first-child { grid-row: span 2; }
.hero__gallery img { border-radius: var(--radius-lg); box-shadow: var(--shadow-float); aspect-ratio: 4 / 5; object-fit: cover; width: 100%; height: 100%; }
@media (min-width: 900px) {
  .hero__grid { grid-template-columns: 1.1fr 1fr; }
}

/* ===== TARJETAS DE MODELO ===== */
.model-grid { display: grid; gap: 1.25rem; grid-template-columns: 1fr; }
@media (min-width: 600px) { .model-grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1100px) { .model-grid { grid-template-columns: repeat(4, 1fr); } }
.model-card {
  display: flex; flex-direction: column; background: var(--color-surface); border: 1px solid var(--color-border);
  border-radius: var(--radius-lg); overflow: hidden; box-shadow: var(--shadow-card);
}
.model-card__media img { aspect-ratio: 4 / 5; object-fit: cover; width: 100%; }
.model-card__body { display: flex; flex-direction: column; gap: 0.6rem; padding: 1.1rem 1.1rem 1.25rem; flex: 1; }
.model-card__body h3 { margin: 0; }
.model-card__body p { font-size: 0.925rem; color: var(--color-text-muted); margin: 0; flex: 1; }
.price-list { list-style: none; margin: 0; padding: 0.6rem 0.8rem; background: var(--color-gold-wash); border-radius: var(--radius-md); font-size: 0.9rem; }
.price-list li { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 0 0.75rem; padding-block: 0.15rem; }
.price-list strong { white-space: nowrap; }
.model-card__actions { display: grid; gap: 0.5rem; margin-top: 0.4rem; }

/* ===== LAZOS (inicio) ===== */
.ribbon-showcase { display: grid; gap: 1.25rem; grid-template-columns: 1fr; max-width: 52rem; margin-inline: auto; }
@media (min-width: 640px) { .ribbon-showcase { grid-template-columns: 1fr 1fr; } }
.ribbon-tile { margin: 0; background: var(--color-surface); border: 1px solid var(--color-border); border-radius: var(--radius-lg); padding: 1rem; text-align: center; box-shadow: var(--shadow-card); }
.ribbon-tile img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; border-radius: var(--radius-md); }
.ribbon-tile h3 { font-size: 1.1rem; margin: 0.5rem 0 0; }

/* ===== INICIO EN ESCRITORIO: contenido más ancho y fotos más grandes ===== */
@media (min-width: 1100px) {
  .page-home { --container: min(95vw, 1760px); }
  .page-home .hero { padding-block: clamp(2rem, 3.5vw, 4rem); }
  .page-home .hero__grid { grid-template-columns: 1fr 1.25fr; gap: 3.5rem; }
  .page-home .hero h1 { font-size: clamp(2.75rem, 3.6vw, 4.25rem); }
  .page-home .hero .lead { font-size: clamp(1.125rem, 1.15vw, 1.35rem); }
  /* También limitado por el alto, para que la galería entre completa en pantalla */
  .page-home .hero__gallery { width: 100%; max-width: min(60rem, calc(115vh - 12rem)); }
  .page-home .section { padding-block: clamp(3rem, 4vw, 4.5rem); }
  .page-home .ribbon-showcase { max-width: 72rem; }
}

/* ===== PASOS: CÓMO PEDIR ===== */
.steps { list-style: none; margin: 0; padding: 0; display: grid; gap: 1.25rem; counter-reset: step; }
@media (min-width: 900px) { .steps { grid-template-columns: repeat(3, 1fr); } }
.step { background: var(--color-surface); border: 1px solid var(--color-border); border-radius: var(--radius-lg); padding: 1.5rem; box-shadow: var(--shadow-card); }
.step__num {
  display: inline-flex; align-items: center; justify-content: center; width: 2.5rem; height: 2.5rem; border-radius: var(--radius-full);
  background: var(--color-burgundy); color: #fff; font-family: var(--font-display); font-weight: 700; font-size: 1.15rem; margin-bottom: 0.75rem;
}
.step h3 { font-size: 1.15rem; }
.step p { color: var(--color-text-muted); font-size: 0.95rem; margin: 0; }
.step p + p { margin-top: 0.6rem; }
.step a { white-space: nowrap; }

/* ===== POLÍTICA DE ADELANTO ===== */
.policy {
  max-width: 60rem; margin: 1.5rem auto 0; padding: 1.5rem; scroll-margin-top: calc(var(--header-h) + 1rem);
  background: var(--color-gold-wash); border-radius: var(--radius-lg);
}
.policy h3 { font-size: 1.15rem; }
.policy ul { margin: 0; padding-left: 1.2rem; display: grid; gap: 0.5rem; font-size: 0.95rem; }

/* ===== PREGUNTAS FRECUENTES ===== */
.faq { max-width: 48rem; margin-inline: auto; display: grid; gap: 0.75rem; }
.faq details { background: var(--color-surface); border: 1px solid var(--color-border); border-radius: var(--radius-md); }
.faq summary {
  list-style: none; cursor: pointer; padding: 1rem 3rem 1rem 1.25rem; font-weight: 600; position: relative; min-height: 2.75rem;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: ''; position: absolute; right: 1.25rem; top: 50%; width: 0.6rem; height: 0.6rem; margin-top: -0.4rem;
  border-right: 2px solid var(--color-burgundy); border-bottom: 2px solid var(--color-burgundy); transform: rotate(45deg); transition: transform 0.2s;
}
.faq details[open] summary::after { transform: rotate(-135deg); margin-top: -0.1rem; }
.faq details > div { padding: 0 1.25rem 1.1rem; color: var(--color-text-muted); }
.faq details > div p:last-child { margin: 0; }

/* ===== BANDA CTA ===== */
.cta-band {
  background: linear-gradient(135deg, var(--color-burgundy) 0%, var(--color-burgundy-deep) 100%); color: #fff;
  border-radius: var(--radius-xl); padding: clamp(1.75rem, 5vw, 3rem); display: grid; gap: 1.5rem; align-items: center;
}
.cta-band h2 { color: #fff; margin: 0 0 0.4rem; }
.cta-band p { color: #f3e6e8; margin: 0; }
.cta-band .eyebrow { color: var(--color-gold-soft); }
.cta-band__actions { display: flex; flex-wrap: wrap; gap: 0.75rem; }
.cta-band .btn--outline { color: #fff; border-color: var(--color-gold-soft); }
.cta-band .btn--outline:hover { background: rgba(255, 255, 255, 0.1); color: #fff; }
.cta-band .btn--whatsapp { background: #fff; color: var(--color-pine); }
.cta-band .btn--whatsapp:hover { background: var(--color-gold-wash); color: var(--color-pine); }
@media (min-width: 860px) { .cta-band { grid-template-columns: 1.4fr 1fr; } .cta-band__actions { justify-content: flex-end; } }

/* ===== PIE DE PÁGINA ===== */
.site-footer { background: #24130d; color: #eadfd6; padding-block: 3rem 1.5rem; margin-top: 0; }
.site-footer a { color: #f4e3c0; }
.site-footer a:hover { color: #fff; }
.footer-grid { display: grid; gap: 2rem; }
@media (min-width: 760px) { .footer-grid { grid-template-columns: 1.4fr 1fr 1fr; } }
.footer-logo { background: var(--color-bg); border-radius: var(--radius-md); padding: 0.6rem 0.9rem; display: inline-block; }
.footer-logo img { height: 3rem; width: auto; }
.site-footer h2 { font-size: 1rem; font-family: var(--font-body); font-weight: 700; color: #fff; letter-spacing: 0.08em; text-transform: uppercase; }
.site-footer ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 0.5rem; }
.footer-bottom { border-top: 1px solid rgba(255, 255, 255, 0.12); margin-top: 2.5rem; padding-top: 1.25rem; font-size: 0.85rem; color: #cbb9ad; }

/* ===== AVISOS / TOAST / DIÁLOGO ===== */
.notice { border-radius: var(--radius-md); padding: 0.75rem 1rem; font-size: 0.9rem; display: flex; gap: 0.6rem; align-items: flex-start; }
.notice svg { width: 1.2rem; height: 1.2rem; flex-shrink: 0; margin-top: 0.1rem; }
.notice--info { background: var(--color-gold-wash); color: #4d3806; }
.notice--error { background: var(--color-error-bg); color: var(--color-error); }
.notice--success { background: var(--color-success-bg); color: var(--color-success); }
.notice--warning { background: var(--color-warning-bg); color: var(--color-warning); }
.notice p { margin: 0; }

.toast-region { position: fixed; z-index: 90; left: 50%; bottom: 1rem; transform: translateX(-50%); width: min(92vw, 26rem); display: grid; gap: 0.5rem; pointer-events: none; }
.toast {
  pointer-events: auto; background: #2a1810; color: #fff; border-radius: var(--radius-md); padding: 0.85rem 1rem; box-shadow: var(--shadow-float);
  font-size: 0.925rem; display: flex; gap: 0.75rem; align-items: center; justify-content: space-between; animation: toast-in 0.25s ease-out;
}
.toast--success { background: var(--color-success); }
.toast--error { background: var(--color-error); }
.toast a, .toast button { color: #fff; font-weight: 700; background: none; border: 0; cursor: pointer; text-decoration: underline; padding: 0.25rem; }
@keyframes toast-in { from { opacity: 0; transform: translateY(0.5rem); } to { opacity: 1; transform: none; } }

.dialog { border: 0; border-radius: var(--radius-lg); padding: 0; max-width: min(92vw, 28rem); box-shadow: var(--shadow-float); color: var(--color-text); }
.dialog::backdrop { background: rgba(42, 24, 16, 0.55); }
.dialog__body { padding: 1.5rem; }
.dialog__body h2 { font-size: 1.35rem; }
.dialog__actions { display: flex; flex-wrap: wrap; gap: 0.5rem; justify-content: flex-end; padding: 0 1.5rem 1.5rem; }
/* Con tres botones (aviso de la foto) se apilan: primero la acción principal */
.dialog__actions:has(> :nth-child(3)) { flex-direction: column-reverse; flex-wrap: nowrap; }
.dialog__actions:has(> :nth-child(3)) > .btn { width: 100%; }

/* ===== FORMULARIOS (comunes) ===== */
.field { display: grid; gap: 0.4rem; }
.field label, .field .label { font-weight: 600; font-size: 0.95rem; }
.field__hint { font-size: 0.85rem; color: var(--color-text-muted); margin: 0; }
.input, .textarea {
  width: 100%; min-height: 2.75rem; padding: 0.65rem 0.9rem; border-radius: var(--radius-sm);
  border: 1.5px solid var(--color-border-strong); background: var(--color-surface);
}
.input:focus, .textarea:focus { outline: none; border-color: var(--color-gold); box-shadow: 0 0 0 3px rgba(122, 88, 14, 0.35); }
.input[aria-invalid='true'] { border-color: var(--color-error); }
.textarea { min-height: 6rem; resize: vertical; }

/* ===== PERSONALIZADOR ===== */
.customizer { display: grid; gap: 1.5rem; padding-bottom: 2rem; }
.customizer__head { padding-top: 1.5rem; }
.customizer__head h1 { font-size: clamp(1.75rem, 5vw, 2.5rem); margin-bottom: 0.25rem; }
.customizer__head p { color: var(--color-text-muted); margin: 0; }

/* Vista previa: en móvil queda fija arriba mientras se personaliza */
.preview-panel {
  position: sticky; top: var(--header-h); z-index: 20; margin-inline: calc(var(--gutter) * -1);
  background: radial-gradient(ellipse at 50% 35%, #fffaf0 0%, #f3e9d8 70%, #eadcc4 100%);
  border-bottom: 1px solid var(--color-border);
}
.preview-stage { position: relative; height: min(38vh, 22rem); display: flex; align-items: center; justify-content: center; padding: 0.25rem; }
.preview-stage canvas { height: 100%; width: auto; max-width: 100%; object-fit: contain; }
.preview-status {
  position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; font-weight: 600; color: var(--color-text-muted);
}
.preview-caption { font-size: 0.75rem; color: var(--color-text-muted); text-align: center; padding: 0 0.75rem 0.5rem; margin: 0; }
.preview-summary { display: none; }

.controls { display: grid; gap: 1rem; min-width: 0; }
.control-card { background: var(--color-surface); border: 1px solid var(--color-border); border-radius: var(--radius-lg); padding: 1.1rem; box-shadow: var(--shadow-card); }
fieldset.control-card { margin: 0; min-width: 0; }
.control-card legend, .control-card__title {
  font-family: var(--font-display); font-weight: 600; font-size: 1.15rem; color: var(--color-burgundy); padding: 0; margin-bottom: 0.75rem;
  display: flex; align-items: center; gap: 0.6rem;
}
fieldset.control-card legend { float: left; width: 100%; }
fieldset.control-card legend + * { clear: both; }
.step-dot {
  display: inline-flex; align-items: center; justify-content: center; width: 1.7rem; height: 1.7rem; border-radius: var(--radius-full);
  background: var(--color-burgundy); color: #fff; font-family: var(--font-body); font-size: 0.8rem; font-weight: 700; flex-shrink: 0;
}
.control-card .sub { margin-top: 1rem; padding-top: 1rem; border-top: 1px dashed var(--color-border); }
.control-card .sub-title { font-weight: 600; font-size: 0.95rem; margin: 0 0 0.5rem; display: block; }

/* Opciones tipo tarjeta (radio) */
.choice-grid { display: grid; gap: 0.6rem; grid-template-columns: repeat(2, 1fr); }
.choice-grid--3 { grid-template-columns: repeat(3, 1fr); }
.decoration-rows { display: grid; gap: 0.75rem; }
.decoration-row { display: grid; gap: 0.35rem; }
.decoration-row__label { font-size: 0.85rem; font-weight: 600; color: var(--color-text-muted); }
.choice { position: relative; }
.choice input { position: absolute; opacity: 0; inset: 0; width: 100%; height: 100%; margin: 0; cursor: pointer; }
.choice__box {
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 0.35rem; text-align: center; height: 100%;
  min-height: 2.75rem; padding: 0.6rem; border-radius: var(--radius-md); border: 1.5px solid var(--color-border-strong); background: var(--color-bg);
  font-weight: 600; font-size: 0.875rem; line-height: 1.25; transition: border-color 0.15s, background-color 0.15s, box-shadow 0.15s;
}
.choice__box small { font-weight: 400; color: var(--color-text-muted); font-size: 0.78rem; }
.choice__box img { width: 100%; max-width: 7rem; aspect-ratio: 16 / 10; object-fit: cover; border-radius: var(--radius-sm); }
.choice input:hover + .choice__box { border-color: var(--color-gold); }
.choice input:checked + .choice__box {
  border-color: var(--color-burgundy); background: var(--color-gold-wash); box-shadow: inset 0 0 0 1px var(--color-burgundy);
}
.choice input:checked + .choice__box::after {
  /* Sobre la esquina: dentro de la tarjeta taparía el texto en pantallas angostas */
  content: '✓'; position: absolute; top: -0.5rem; right: -0.4rem; width: 1.2rem; height: 1.2rem; border-radius: 50%;
  background: var(--color-burgundy); color: #fff; font-size: 0.75rem; display: flex; align-items: center; justify-content: center;
}
.choice input:focus-visible + .choice__box { outline: 3px solid var(--color-focus); outline-offset: 2px; }
.choice input:disabled + .choice__box { opacity: 0.5; cursor: not-allowed; }

/* Muestras de color circulares */
.swatches { display: flex; flex-wrap: wrap; gap: 0.75rem; }
.swatch { position: relative; display: inline-flex; flex-direction: column; align-items: center; gap: 0.3rem; font-size: 0.8rem; font-weight: 600; }
.swatch input { position: absolute; opacity: 0; width: 2.75rem; height: 2.75rem; margin: 0; cursor: pointer; }
.swatch__dot {
  width: 2.75rem; height: 2.75rem; border-radius: 50%; border: 1px solid rgba(0, 0, 0, 0.2);
  box-shadow: inset -4px -6px 10px rgba(0, 0, 0, 0.18), inset 4px 4px 8px rgba(255, 255, 255, 0.55);
}
.swatch input:checked + .swatch__dot { box-shadow: 0 0 0 3px #fff, 0 0 0 5px var(--color-burgundy); }
.swatch input:focus-visible + .swatch__dot { outline: 3px solid var(--color-focus); outline-offset: 5px; }

/* Nombre + contador */
.name-row { display: flex; justify-content: space-between; align-items: baseline; gap: 0.5rem; }
.counter { font-size: 0.8rem; font-weight: 600; color: var(--color-text-muted); }
.counter.is-limit { color: var(--color-error); }
.field__error { color: var(--color-error); font-size: 0.85rem; font-weight: 600; margin: 0; }

/* Interruptor (copos) */
.switch { display: flex; align-items: center; justify-content: space-between; gap: 1rem; cursor: pointer; }
.switch input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.switch__track { position: relative; flex-shrink: 0; width: 3.25rem; height: 1.9rem; border-radius: var(--radius-full); background: #8a7560; transition: background-color 0.2s; }
.switch__track::after {
  content: ''; position: absolute; top: 0.2rem; left: 0.2rem; width: 1.5rem; height: 1.5rem; border-radius: 50%; background: #fff;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.3); transition: transform 0.2s;
}
.switch input:checked + .switch__track { background: var(--color-pine); }
.switch input:checked + .switch__track::after { transform: translateX(1.35rem); }
.switch input:focus-visible + .switch__track { outline: 3px solid var(--color-focus); outline-offset: 3px; }

/* Foto */
.upload {
  display: grid; gap: 0.5rem; place-items: center; text-align: center; padding: 1.25rem; border: 2px dashed var(--color-gold);
  border-radius: var(--radius-md); background: var(--color-gold-wash); cursor: pointer;
}
.upload svg { width: 2rem; height: 2rem; color: var(--color-gold-text); }
.upload strong { color: var(--color-burgundy); }
.upload small { color: var(--color-text-muted); }
.upload:focus-within { outline: 3px solid var(--color-focus); outline-offset: 2px; }
.upload input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.upload.is-loading { opacity: 0.7; cursor: progress; }
.photo-file { display: flex; align-items: center; gap: 0.75rem; justify-content: space-between; flex-wrap: wrap; }
.photo-file__name { font-size: 0.875rem; font-weight: 600; overflow-wrap: anywhere; }
.sliders { display: grid; gap: 0.9rem; margin-top: 1rem; }
.slider { display: grid; gap: 0.25rem; }
.slider label { display: flex; justify-content: space-between; font-size: 0.875rem; font-weight: 600; }
.slider output { color: var(--color-text-muted); font-weight: 600; }
input[type='range'] { width: 100%; height: 2.75rem; accent-color: var(--color-burgundy); cursor: pointer; background: transparent; }

/* Acciones del personalizador */
.actions-card { display: grid; gap: 0.6rem; }

@media (min-width: 960px) {
  .customizer { grid-template-columns: minmax(0, 1fr) minmax(0, 1.05fr); gap: 2.5rem; align-items: start; }
  .customizer__head { grid-column: 1 / -1; padding-top: 2.5rem; }
  .preview-panel {
    position: sticky; top: calc(var(--header-h) + 1rem); margin: 0; border-radius: var(--radius-xl);
    border: 1px solid var(--color-border); box-shadow: var(--shadow-card); overflow: hidden;
  }
  .preview-stage { height: min(72vh, 40rem); padding: 1rem; }
  .preview-caption { padding-bottom: 1rem; font-size: 0.8rem; }
}

/* ===== MI PEDIDO ===== */
.order-page { padding-block: 1.5rem 3rem; }
.order-layout { display: grid; gap: 1.5rem; }
@media (min-width: 960px) { .order-layout { grid-template-columns: minmax(0, 1.6fr) minmax(0, 1fr); align-items: start; } }
.order-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 1rem; }
.order-item {
  display: grid; grid-template-columns: 6rem 1fr; gap: 1rem; background: var(--color-surface); border: 1px solid var(--color-border);
  border-radius: var(--radius-lg); padding: 1rem; box-shadow: var(--shadow-card);
}
@media (min-width: 600px) { .order-item { grid-template-columns: 8rem 1fr; } }
.order-item__thumb { border-radius: var(--radius-md); background: radial-gradient(ellipse at 50% 35%, #fffaf0, #eadcc4); aspect-ratio: 11 / 13; width: 100%; object-fit: contain; }
.order-item h3 { font-size: 1.15rem; margin: 0 0 0.25rem; }
.order-item__name { font-weight: 700; color: var(--color-gold-text); margin: 0 0 0.4rem; overflow-wrap: anywhere; }
.order-item__specs { margin: 0 0 0.75rem; padding: 0; list-style: none; display: flex; flex-wrap: wrap; gap: 0.35rem; }
.order-item__specs li { font-size: 0.78rem; background: var(--color-bg-alt); border-radius: var(--radius-full); padding: 0.15rem 0.6rem; color: var(--color-text-muted); }
.order-item__row { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 0.75rem; }
.order-item__links { display: flex; flex-wrap: wrap; gap: 0.25rem; }
.qty { display: inline-flex; align-items: center; border: 1.5px solid var(--color-border-strong); border-radius: var(--radius-sm); background: var(--color-bg); }
.qty button { width: 2.75rem; height: 2.75rem; border: 0; background: none; font-size: 1.25rem; font-weight: 700; cursor: pointer; color: var(--color-burgundy); border-radius: var(--radius-sm); }
.qty button:hover { background: var(--color-bg-alt); }
.qty button:disabled { color: #b5a99c; cursor: not-allowed; }
.qty output { min-width: 2.25rem; text-align: center; font-weight: 700; }
.order-summary { background: var(--color-surface); border: 1px solid var(--color-border); border-radius: var(--radius-lg); padding: 1.25rem; box-shadow: var(--shadow-card); display: grid; gap: 1rem; }
@media (min-width: 960px) { .order-summary { position: sticky; top: calc(var(--header-h) + 1rem); } }
.order-summary h2 { font-size: 1.4rem; margin: 0; }
.summary-row { display: flex; justify-content: space-between; gap: 1rem; font-weight: 600; }
.summary-row span:last-child { white-space: nowrap; }
.summary-prices { display: grid; gap: 0.5rem; }
.summary-row--line { font-weight: 400; font-size: 0.925rem; }
.summary-row--total { font-size: 1.15rem; padding-top: 0.5rem; border-top: 1px solid var(--color-border); }
.empty-state { text-align: center; background: var(--color-surface); border: 1px dashed var(--color-border-strong); border-radius: var(--radius-lg); padding: 2.5rem 1.25rem; }
.empty-state svg { width: 3.5rem; height: 3.5rem; margin: 0 auto 1rem; color: var(--color-gold); }
.empty-state p { color: var(--color-text-muted); }
.message-preview { white-space: pre-wrap; font-size: 0.85rem; background: var(--color-bg-alt); border-radius: var(--radius-md); padding: 1rem; max-height: 18rem; overflow: auto; margin: 0.75rem 0 0; font-family: var(--font-body); }
.order-summary details summary { cursor: pointer; font-weight: 600; color: var(--color-burgundy); min-height: 2.75rem; display: flex; align-items: center; }

/* ===== 404 ===== */
.not-found { text-align: center; padding-block: 5rem; }
