/* PAD portal · diseño flat (indigo + esmeralda). Contrastes verificados >= 4.5:1. */
:root {
  --primary: #4f46e5;
  --primary-dark: #3730a3;
  --primary-soft: #eef2ff;
  --cta: #047857;
  --cta-dark: #065f46;
  --ink: #1e1b4b;
  --muted: #4b5563;
  --bg: #f5f3ff;
  --surface: #ffffff;
  --border: #c7d2fe;
  --border-strong: #818cf8;
  --danger: #b91c1c;
  --danger-soft: #fef2f2;
  --ok: #047857;
  --ok-soft: #ecfdf5;
  --warn: #92400e;
  --warn-soft: #fffbeb;
  --radius: 12px;
  --font: "Nunito Sans", "Segoe UI", system-ui, -apple-system, Roboto, "Helvetica Neue", Arial, sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font-family: var(--font);
  font-size: 1rem;
  line-height: 1.6;
  color: var(--ink);
  background: var(--bg);
}
h1, h2, h3, p { margin: 0; }
h1, h2, h3 { line-height: 1.2; letter-spacing: -0.01em; }
a { color: var(--primary-dark); text-underline-offset: 3px; }
a:hover { color: var(--primary); }
img { max-width: 100%; }
[hidden] { display: none !important; }

.sr-only {
  position: absolute; 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(--ink); color: #fff; padding: .6rem 1rem; border-radius: 8px;
}
.skip-link:focus { top: 1rem; }
.boot { padding: 3rem 1.5rem; text-align: center; color: var(--muted); }

:focus-visible { outline: 3px solid var(--primary); outline-offset: 2px; }
h1:focus, h2:focus { outline: none; }
main:focus { outline: none; }

.icon { display: inline-flex; flex: none; vertical-align: middle; }

/* ---------- Botones ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .5rem;
  min-height: 44px; padding: .6rem 1.25rem;
  font: inherit; font-weight: 700; text-decoration: none; cursor: pointer;
  border: 2px solid transparent; border-radius: 10px;
  transition: background-color .18s ease, color .18s ease, border-color .18s ease;
}
.btn:disabled { cursor: not-allowed; opacity: .75; }
.btn-full { width: 100%; }
.btn-lg { min-height: 52px; padding: .8rem 1.6rem; font-size: 1.05rem; }
.btn-primary { background: var(--primary); color: #fff; }
.btn-primary:hover:not(:disabled) { background: var(--primary-dark); color: #fff; }
.btn-cta { background: var(--cta); color: #fff; }
.btn-cta:hover:not(:disabled) { background: var(--cta-dark); color: #fff; }
.btn-outline { background: transparent; color: var(--primary-dark); border-color: var(--border-strong); }
.btn-outline:hover:not(:disabled) { background: var(--primary-soft); color: var(--primary-dark); }
.btn-ghost { background: transparent; color: var(--primary-dark); }
.btn-ghost:hover:not(:disabled) { background: var(--primary-soft); color: var(--primary-dark); }
.btn-danger { background: var(--danger); color: #fff; }
.btn-danger:hover:not(:disabled) { background: #991b1b; }
.btn-sm { min-height: 40px; padding: .4rem .9rem; font-size: .92rem; }
.btn-danger-ghost { background: transparent; color: var(--danger); border-color: #fecaca; }
.btn-danger-ghost:hover:not(:disabled) { background: var(--danger-soft); color: #991b1b; }

.icon-button {
  display: inline-flex; align-items: center; justify-content: center;
  width: 44px; height: 44px; padding: 0; cursor: pointer;
  background: transparent; border: 0; border-radius: 10px; color: var(--muted);
}
.icon-button:hover { color: var(--primary-dark); background: var(--primary-soft); }
.link-button {
  background: none; border: 0; padding: .25rem 0; cursor: pointer;
  font: inherit; font-weight: 700; color: var(--primary-dark); text-decoration: underline; text-underline-offset: 3px;
}
.link-button:hover { color: var(--primary); }

.spinner {
  width: 16px; height: 16px; border-radius: 50%;
  border: 2px solid rgba(255, 255, 255, .4); border-top-color: #fff;
  animation: spin .8s linear infinite;
}
.btn-outline .spinner, .btn-ghost .spinner, .btn-danger-ghost .spinner { border-color: rgba(79, 70, 229, .3); border-top-color: var(--primary); }
@keyframes spin { to { transform: rotate(360deg); } }

/* ---------- Formularios ---------- */
.form { display: grid; gap: 1.1rem; }
.form-narrow { max-width: 440px; }
.form-actions { display: flex; gap: .75rem; align-items: center; }
.form-links { display: flex; justify-content: flex-end; margin-top: -.25rem; }
.grid-2 { display: grid; gap: 1.1rem; grid-template-columns: repeat(2, minmax(0, 1fr)); }

.field { display: grid; gap: .35rem; }
.field label { font-weight: 700; font-size: .95rem; }
.optional { font-weight: 400; color: var(--muted); }
input[type="text"], input[type="email"], input[type="password"], input[type="url"], select {
  width: 100%; min-height: 46px; padding: .6rem .85rem;
  font: inherit; color: var(--ink); background: var(--surface);
  border: 2px solid var(--border); border-radius: 10px;
  transition: border-color .18s ease;
}
input:hover, select:hover { border-color: var(--border-strong); }
input:focus, select:focus { outline: none; border-color: var(--primary); box-shadow: 0 0 0 3px rgba(79, 70, 229, .25); }
input[aria-invalid="true"] { border-color: var(--danger); }
input::placeholder { color: #6b7280; }
.field-hint { font-size: .85rem; color: var(--muted); }
.field-error { font-size: .875rem; font-weight: 600; color: var(--danger); }
.password-control { position: relative; }
.password-control input { padding-right: 52px; }
.password-control .reveal { position: absolute; right: 1px; top: 1px; height: 44px; }

.rules { list-style: none; margin: .25rem 0 0; padding: 0; display: grid; gap: .2rem; font-size: .85rem; color: var(--muted); }
.rules li { display: flex; align-items: center; gap: .4rem; }
.rules .rule-mark { display: inline-flex; width: 18px; height: 18px; align-items: center; justify-content: center; border-radius: 50%; background: #e5e7eb; color: #374151; }
.rules li.ok { color: var(--ok); font-weight: 600; }
.rules li.ok .rule-mark { background: var(--ok); color: #fff; }

.alert {
  display: flex; align-items: flex-start; gap: .6rem;
  padding: .75rem .9rem; border-radius: 10px; font-size: .95rem; font-weight: 600;
}
.alert .icon { margin-top: 2px; }
.alert-error { background: var(--danger-soft); color: #7f1d1d; border: 1px solid #fecaca; }
.alert-success { background: var(--ok-soft); color: #064e3b; border: 1px solid #a7f3d0; }

/* ---------- Cabeceras y marca ---------- */
.brand { display: inline-flex; align-items: center; gap: .55rem; font-weight: 800; font-size: 1.35rem; color: var(--ink); text-decoration: none; }
.brand:hover { color: var(--primary-dark); }
.logo { display: inline-flex; color: var(--primary); }
.brand-light, .brand-light:hover { color: #fff; }
.brand-light .logo { color: #fff; }

.site-header, .app-header {
  display: flex; align-items: center; justify-content: space-between; gap: 1rem;
  max-width: 1160px; margin: 0 auto; padding: 1rem 1.25rem;
}
.site-nav { display: flex; gap: .5rem; align-items: center; }

/* ---------- Bienvenida ---------- */
.eyebrow { font-size: .8rem; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; color: var(--primary-dark); }
.hero {
  display: grid; grid-template-columns: 1.05fr .95fr; gap: 3rem; align-items: center;
  max-width: 1160px; margin: 0 auto; padding: 3rem 1.25rem 4rem;
}
.hero h1 { font-size: clamp(2.1rem, 4.6vw, 3.4rem); margin: .6rem 0 1rem; }
.lead { font-size: 1.15rem; color: var(--muted); max-width: 34rem; }
.hero-actions { display: flex; flex-wrap: wrap; gap: .8rem; margin: 1.75rem 0 1rem; }
.hero-note { display: flex; align-items: center; gap: .45rem; font-size: .92rem; color: var(--muted); }

.mock { background: var(--surface); border: 2px solid var(--border); border-radius: 18px; padding: 1.1rem; position: relative; }
.mock-bar { display: flex; justify-content: space-between; align-items: center; margin-bottom: .8rem; }
.mock-title { font-weight: 800; }
.mock-pill { display: inline-flex; align-items: center; gap: .3rem; font-size: .78rem; font-weight: 700; padding: .2rem .6rem; border-radius: 999px; background: var(--primary-soft); color: var(--primary-dark); }
.mock-list { list-style: none; margin: 0; padding: 0; display: grid; gap: .6rem; }
.mock-row { display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: .75rem; padding: .7rem; border: 1px solid var(--border); border-radius: 12px; }
.mock-thumb { display: inline-flex; width: 40px; height: 40px; align-items: center; justify-content: center; border-radius: 10px; background: var(--primary-soft); color: var(--primary-dark); }
.mock-info { display: grid; line-height: 1.3; min-width: 0; }
.mock-info span { font-size: .8rem; color: var(--muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.mock-toast { display: flex; align-items: center; gap: .5rem; margin-top: .9rem; padding: .7rem .9rem; border-radius: 12px; background: var(--ink); color: #fff; font-size: .9rem; font-weight: 600; }

.badge { display: inline-flex; align-items: center; gap: .3rem; padding: .2rem .65rem; border-radius: 999px; font-size: .8rem; font-weight: 800; white-space: nowrap; }
.badge-available { background: var(--ok-soft); color: #065f46; border: 1px solid #6ee7b7; }
.badge-unavailable { background: var(--danger-soft); color: #991b1b; border: 1px solid #fca5a5; }
.badge-pending { background: var(--warn-soft); color: var(--warn); border: 1px solid #fcd34d; }

.section { max-width: 1160px; margin: 0 auto; padding: 3rem 1.25rem; }
.section h2 { font-size: clamp(1.6rem, 3vw, 2.1rem); margin-bottom: 1.75rem; }
.section-tint { background: var(--surface); max-width: none; border-block: 1px solid var(--border); }
.section.section-tint > * { max-width: 1160px; margin-inline: auto; }
.steps, .features { list-style: none; margin: 0; padding: 0; display: grid; gap: 1.25rem; }
.steps { grid-template-columns: repeat(3, 1fr); }
.step { display: flex; gap: 1rem; align-items: flex-start; }
.step h3, .feature h3 { font-size: 1.1rem; margin-bottom: .25rem; }
.step p, .feature p { color: var(--muted); }
.step-number { flex: none; display: inline-flex; width: 40px; height: 40px; align-items: center; justify-content: center; border-radius: 50%; background: var(--primary); color: #fff; font-weight: 800; }
.features { grid-template-columns: repeat(4, 1fr); }
.feature { padding: 1.25rem; border: 2px solid var(--border); border-radius: var(--radius); background: var(--bg); }
.feature-icon { display: inline-flex; width: 44px; height: 44px; align-items: center; justify-content: center; margin-bottom: .75rem; border-radius: 12px; background: var(--primary-soft); color: var(--primary-dark); }
.cta-band { text-align: center; padding: 4rem 1.25rem; display: grid; gap: .8rem; justify-items: center; }
.cta-band h2 { font-size: clamp(1.6rem, 3vw, 2.1rem); }
.cta-band p { color: var(--muted); margin-bottom: .6rem; }

.site-footer { max-width: 1160px; margin: 0 auto; padding: 1.5rem 1.25rem 2.5rem; display: flex; flex-wrap: wrap; justify-content: space-between; gap: .75rem; font-size: .9rem; color: var(--muted); border-top: 1px solid var(--border); }
.site-footer nav { display: flex; gap: 1.25rem; }

/* ---------- Ingreso / registro ---------- */
.auth-layout { display: grid; grid-template-columns: minmax(300px, 5fr) 7fr; min-height: 100vh; }
.auth-aside { background: var(--primary); color: #fff; padding: 2rem 2.5rem; display: flex; flex-direction: column; justify-content: space-between; gap: 2rem; }
.aside-copy h2 { font-size: clamp(1.7rem, 2.6vw, 2.3rem); margin-bottom: 1.5rem; }
.aside-points { list-style: none; margin: 0; padding: 0; display: grid; gap: 1rem; }
.aside-points li { display: flex; align-items: center; gap: .75rem; font-weight: 600; }
.aside-foot { font-size: .85rem; opacity: .9; }
.auth-main { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 1rem; padding: 2rem 1.25rem; }
.back-link { align-self: flex-start; display: inline-flex; align-items: center; gap: .4rem; font-weight: 700; text-decoration: none; }
.back-link .icon { transform: rotate(180deg); }
.auth-card { width: 100%; max-width: 460px; background: var(--surface); border: 2px solid var(--border); border-radius: 18px; padding: 2rem; display: grid; gap: 1.25rem; }
.auth-heading h1 { font-size: 1.65rem; }
.auth-heading p { color: var(--muted); margin-top: .35rem; }
.switch { text-align: center; color: var(--muted); }
.legal { font-size: .85rem; color: var(--muted); }
.mfa-steps { margin: 0; padding-left: 1.25rem; color: var(--muted); display: grid; gap: .25rem; }
.qr-box { display: flex; flex-wrap: wrap; gap: 1rem; align-items: center; padding: 1rem; border: 2px dashed var(--border-strong); border-radius: var(--radius); background: var(--bg); }
.qr { width: 160px; height: 160px; border-radius: 8px; background: #fff; image-rendering: pixelated; }
.secret { display: grid; gap: .35rem; min-width: 0; flex: 1 1 180px; }
.secret span { font-size: .8rem; font-weight: 700; color: var(--muted); }
.secret code { display: block; overflow-wrap: anywhere; padding: .5rem .65rem; border-radius: 8px; background: var(--surface); border: 1px solid var(--border); font-size: .95rem; letter-spacing: .06em; }

/* ---------- App autenticada ---------- */
.app-header { flex-wrap: wrap; border-bottom: 1px solid var(--border); max-width: none; background: var(--surface); padding-inline: max(1.25rem, calc((100vw - 1160px) / 2)); }
.app-nav { display: flex; gap: .35rem; flex: 1; justify-content: center; }
.app-nav a { display: inline-flex; align-items: center; gap: .45rem; min-height: 44px; padding: .5rem 1rem; border-radius: 10px; font-weight: 700; text-decoration: none; color: var(--muted); }
.app-nav a:hover { background: var(--primary-soft); color: var(--primary-dark); }
.app-nav a.active { background: var(--primary-soft); color: var(--primary-dark); box-shadow: inset 0 -3px 0 var(--primary); }
.user-box { display: flex; align-items: center; gap: .5rem; color: var(--muted); font-weight: 600; min-width: 0; }
.user-name { max-width: 200px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.app-content > *, .card, .card > * { min-width: 0; }
.app-content { max-width: 960px; margin: 0 auto; padding: 2rem 1.25rem 3rem; display: grid; gap: 1.5rem; }
.page-head h1 { font-size: clamp(1.7rem, 3vw, 2.2rem); }
.page-head p { color: var(--muted); margin-top: .35rem; }
.card { background: var(--surface); border: 2px solid var(--border); border-radius: 16px; padding: 1.5rem; display: grid; gap: 1rem; align-content: start; }
.card h2 { font-size: 1.25rem; }
.card-sub { color: var(--muted); margin-top: -.5rem; }
.card-head { display: flex; justify-content: space-between; align-items: baseline; gap: 1rem; flex-wrap: wrap; }
.card-inline { grid-auto-flow: column; grid-template-columns: auto 1fr; align-items: center; gap: 1rem; }
.card-inline .feature-icon { margin: 0; }
.card-inline .card-sub { margin-top: .25rem; }
.hint { font-size: .85rem; color: var(--muted); }
.loading { color: var(--muted); padding: 1rem 0; }

.product-list { display: grid; gap: .75rem; }
.product {
  display: grid; align-items: center; gap: .75rem 1rem; padding: 1rem;
  grid-template-columns: minmax(0, 1fr) auto auto;
  grid-template-areas: "main state remove" "times times times";
  border: 1px solid var(--border); border-radius: var(--radius); min-width: 0;
  transition: background-color .4s ease, border-color .4s ease;
}
.product.just-saved { background: var(--ok-soft); border-color: #34d399; }
.product-main { grid-area: main; min-width: 0; display: grid; gap: .15rem; }
.product-main > * { min-width: 0; }
.product-main h3 { font-size: 1.05rem; overflow-wrap: anywhere; }
.product-url { display: flex; align-items: center; gap: .35rem; font-size: .88rem; min-width: 0; max-width: 100%; }
.product-url span { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.product-url .icon { flex: none; }
.product-state { grid-area: state; }
.product-actions { grid-area: remove; display: flex; gap: .5rem; flex-wrap: wrap; justify-content: flex-end; }
.product-times { grid-area: times; margin: 0; display: flex; flex-wrap: wrap; gap: .25rem 1.75rem; font-size: .8rem; padding-top: .6rem; border-top: 1px dashed var(--border); }
.product-times div { display: flex; gap: .4rem; }
.product-times dt { color: var(--muted); }
.product-times dd { margin: 0; font-weight: 700; }
.empty { display: grid; justify-items: center; gap: .4rem; padding: 2rem 1rem; text-align: center; color: var(--muted); }
.empty h3 { color: var(--ink); }

.dialog { border: 2px solid var(--border-strong); border-radius: 16px; padding: 1.5rem; max-width: 420px; width: calc(100% - 2rem); color: var(--ink); }
.dialog::backdrop { background: rgba(30, 27, 75, .55); }
.dialog h2 { font-size: 1.2rem; margin-bottom: .5rem; }
.dialog p { color: var(--muted); overflow-wrap: anywhere; margin-bottom: 1rem; }
.dialog-actions { display: flex; justify-content: flex-end; gap: .6rem; margin-top: 1rem; }

/* ---------- Preferencias ---------- */
.pref-block { display: grid; gap: .85rem; padding: 1.1rem; border: 1px solid var(--border); border-radius: var(--radius); background: var(--bg); }
.pref-title { display: flex; align-items: center; gap: .55rem; color: var(--primary-dark); }
.pref-title h3 { font-size: 1.05rem; color: var(--ink); }
.pref-note { margin-left: auto; font-size: .8rem; font-weight: 700; color: var(--muted); }
fieldset { border: 0; margin: 0; padding: 0; min-width: 0; }
.segmented { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .6rem; }
.segment input, .chip input, .color-chip input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.segment, .chip, .color-chip { position: relative; }
.segment label { display: grid; gap: .1rem; padding: .65rem .9rem; cursor: pointer; border: 2px solid var(--border); border-radius: 10px; background: var(--surface); transition: border-color .18s ease, background-color .18s ease; }
.segment label small { color: var(--muted); }
.segment label:hover { border-color: var(--border-strong); }
.segment input:checked + label { border-color: var(--primary); background: var(--primary-soft); }
.segment input:focus-visible + label, .chip input:focus-visible + label, .color-chip input:focus-visible + label { outline: 3px solid var(--primary); outline-offset: 2px; }
.chip-group { display: flex; flex-wrap: wrap; gap: .5rem; }
.chip label { display: inline-flex; align-items: center; min-height: 44px; min-width: 52px; justify-content: center; padding: .4rem .9rem; cursor: pointer; font-weight: 700; border: 2px solid var(--border); border-radius: 999px; background: var(--surface); transition: border-color .18s ease, background-color .18s ease, color .18s ease; }
.chip label:hover { border-color: var(--border-strong); }
.chip input:checked + label { background: var(--primary); border-color: var(--primary); color: #fff; }
.color-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(130px, 1fr)); gap: .5rem; }
.color-chip label { display: flex; align-items: center; gap: .55rem; min-height: 44px; padding: .4rem .75rem; cursor: pointer; font-weight: 700; border: 2px solid var(--border); border-radius: 10px; background: var(--surface); transition: border-color .18s ease, background-color .18s ease; }
.color-chip label:hover { border-color: var(--border-strong); }
.color-chip input:checked + label { border-color: var(--primary); background: var(--primary-soft); }
.color-chip input:disabled + label { opacity: .5; cursor: not-allowed; }
.swatch { flex: none; width: 22px; height: 22px; border-radius: 50%; border: 2px solid #9ca3af; }
.swatch-multi { background: conic-gradient(#dc2626, #facc15, #16a34a, #38bdf8, #7c3aed, #dc2626); }
.color-chip input:checked + label::after { content: ""; margin-left: auto; width: 10px; height: 10px; border-radius: 50%; background: var(--primary); }

.notfound { min-height: 100vh; display: grid; place-content: center; justify-items: center; gap: 1rem; text-align: center; padding: 2rem; }
.notfound p { color: var(--muted); }

/* ---------- Responsive ---------- */
@media (max-width: 960px) {
  .hero { grid-template-columns: 1fr; gap: 2rem; padding-top: 1.5rem; }
  .steps { grid-template-columns: 1fr; }
  .features { grid-template-columns: repeat(2, 1fr); }
  .auth-layout { grid-template-columns: 1fr; }
  .auth-aside { display: none; }
  .auth-main { justify-content: flex-start; padding-top: 1.5rem; }
}
@media (max-width: 640px) {
  .grid-2 { grid-template-columns: 1fr; }
  .features { grid-template-columns: 1fr; }
  .color-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .color-chip label { padding-inline: .5rem; gap: .4rem; }
  .app-header { gap: .5rem; }
  .app-nav { order: 3; flex-basis: 100%; justify-content: space-between; }
  .app-nav a { flex: 1; justify-content: center; padding-inline: .5rem; }
  .user-name { display: none; }
  .auth-card { padding: 1.4rem; }
  .card { padding: 1.1rem; }
  .product {
    grid-template-columns: minmax(0, 1fr);
    grid-template-areas: "main" "state" "times" "remove";
  }
  .product-times { flex-direction: column; }
  .product-actions .btn { flex: 1; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
}

/* Campo de solo lectura */
input.readonly, input[readonly] { background: #f3f4f6; color: #374151; border-color: #d1d5db; cursor: default; }
input[readonly]:hover { border-color: #d1d5db; }
input[readonly]:focus { box-shadow: 0 0 0 3px rgba(79, 70, 229, .25); border-color: var(--primary); }
.alert-status { display: grid; gap: .6rem; justify-items: start; }
.card h2 .icon { margin-right: .25rem; color: var(--primary-dark); }

/* Avisos de confirmacion */
.toast-region { position: fixed; z-index: 200; left: 50%; bottom: 1.25rem; transform: translateX(-50%); width: min(92vw, 460px); pointer-events: none; }
.toast { display: flex; align-items: center; gap: .6rem; padding: .85rem 1.1rem; border-radius: 12px; font-weight: 700; color: #fff; pointer-events: none; animation: toast-in .25s ease-out; }
.toast-success { background: var(--cta-dark); }
.toast-error { background: #991b1b; }
@keyframes toast-in { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }

/* Miniaturas y notas de la lista */
.product.has-thumb { grid-template-columns: 56px minmax(0, 1fr) auto auto; grid-template-areas: "thumb main state remove" "times times times times"; }
.thumb-wrap { grid-area: thumb; width: 56px; height: 56px; border-radius: 10px; overflow: hidden; background: var(--primary-soft); border: 1px solid var(--border); }
.thumb { display: block; width: 56px; height: 56px; object-fit: cover; }
.product-price { font-weight: 700; font-size: .92rem; }
.check-note { display: flex; gap: .35rem; align-items: flex-start; font-size: .82rem; color: var(--warn); }
.check-note .icon { margin-top: 2px; }

/* Interruptor accesible */
.switch-row { display: flex; align-items: center; justify-content: space-between; gap: 1rem; flex-wrap: wrap; }
.switch { position: relative; display: inline-flex; align-items: center; gap: .75rem; min-height: 44px; font-weight: 700; cursor: pointer; }
.switch input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.switch-track { position: relative; flex: none; width: 48px; height: 28px; border-radius: 999px; background: #6b7280; transition: background-color .18s ease; }
.switch-track::after { content: ""; position: absolute; top: 3px; left: 3px; width: 22px; height: 22px; border-radius: 50%; background: #fff; transition: transform .18s ease; }
.switch input:checked ~ .switch-track { background: var(--cta); }
.switch input:checked ~ .switch-track::after { transform: translateX(20px); }
.switch input:focus-visible ~ .switch-track { outline: 3px solid var(--primary); outline-offset: 2px; }
.switch input:disabled ~ .switch-track { opacity: .5; }
.switch-state { font-weight: 700; color: var(--muted); }
@media (max-width: 960px) {
  .product.has-thumb { grid-template-columns: 56px minmax(0, 1fr) auto; grid-template-areas: "thumb main main" "state state remove" "times times times"; }
}
@media (max-width: 640px) {
  .product.has-thumb { grid-template-columns: 56px minmax(0, 1fr); grid-template-areas: "thumb main" "state state" "times times" "remove remove"; }
}

/* Selector de talla y color */
.variant-box { border: 1px dashed var(--border-strong); border-radius: var(--radius); padding: .9rem 1rem 1rem; display: grid; gap: .75rem; min-width: 0; }
.variant-box legend { padding: 0 .4rem; font-weight: 700; font-size: .95rem; }
.variant-picker { display: grid; gap: .6rem; }
.variant-head { display: flex; flex-wrap: wrap; gap: .5rem 1rem; align-items: center; }
.variant-options { display: grid; grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); gap: .75rem; }
.watch-note { display: flex; gap: .35rem; align-items: center; font-size: .82rem; font-weight: 700; color: var(--primary-dark); }
.dialog .variant-box { margin: 0; }
.dialog { max-width: 520px; }
