/* Precium · the shopping assistant's phase 2 (asistente-fase2-2111; spec post0212-2111/asistente-fase2/ESPEC.md §3, §4 and §8).
   Its own sheet, linked by the shell after phase 1's ONLY with the phase 2 on the page (`ai.asistente2111` on, or in shadow an
   administrator's preview) and by the bench: phase 1's sheet keeps its name. Every rule scoped to the redesign; colours only with
   the --sd-* variables of the two themes; the panel's surfaces with --sd-asis-sup (phase 1's alias); no shadow of its own. */

/* ---------- 1. The product page's doors (P3 the index, P4 the phone's chips, P5 the foot of «Preguntas») ---------- */
/* ficha-0412 (the owner, 04-12-2026): the index's door is a button that looks like one — a border that is seen in both themes, the
   soft accent under it, the index's own 14 px on one line and room around its words (its height its own if they ever wrap). */
[data-site-design="nuevo"] .sd-asis-door--indice {
  display: flex; align-items: center; justify-content: center; gap: var(--sd-s-8);
  width: 100%; height: auto; min-height: var(--sd-h-42); margin-top: var(--sd-s-10); padding: var(--sd-s-8) var(--sd-s-12);
  /* the border's width and style on their own line: where color-mix() is not understood only its colour is lost, never the border */
  border: 1px solid var(--sd-accent-soft-ink); border-color: color-mix(in srgb, var(--sd-accent-soft-ink) 65%, transparent); border-radius: var(--sd-r-12);
  background: var(--sd-accent-soft); color: var(--sd-accent-soft-ink);
  font-size: var(--sd-t-14); line-height: 18px; font-weight: var(--sd-w-550);
  white-space: normal; text-align: center;
}
[data-site-design="nuevo"] .sd-asis-door--indice:hover { border-color: var(--sd-accent-soft-ink); background: var(--sd-accent-soft-2); color: var(--sd-accent-soft-ink); }
[data-site-design="nuevo"] .sd-asis-door--chip-ficha { display: inline-flex; align-items: center; gap: var(--sd-s-6); }
[data-site-design="nuevo"] .sd-asis-door-line--ficha { margin-top: var(--sd-s-16); padding-top: var(--sd-s-16); border-top: 1px solid var(--sd-line); }
@media (min-width: 1024px) {
  /* the index's door is the computer's; the phone has its chip */
  [data-site-design="nuevo"] .sd-asis-door--chip-ficha { display: none; }
}
@media (max-width: 1023.98px) {
  [data-site-design="nuevo"] .sd-asis-door--indice { display: none; }
  [data-site-design="nuevo"] .sd-asis-door-line--ficha .sd-chip { min-height: 44px; }
}

/* ---------- 2. The coupon and shop cards in the chat: flat, like the product's; their height their own ---------- */
[data-site-design="nuevo"] .sd-asis-f2card { display: flex; align-items: flex-start; gap: var(--sd-s-12); padding: var(--sd-s-10) var(--sd-s-12); border-radius: var(--sd-r-20); background: var(--sd-asis-sup); }
[data-site-design="nuevo"] .sd-asis-f2card__icon { display: grid; flex: none; place-items: center; width: 44px; height: 44px; border-radius: var(--sd-r-16); background: var(--sd-accent-soft); color: var(--sd-accent-soft-ink); }
[data-site-design="nuevo"] .sd-asis-f2card__body { display: flex; flex: 1 1 auto; flex-direction: column; gap: 2px; min-width: 0; }
[data-site-design="nuevo"] .sd-asis-f2card__eyebrow { margin: 0; color: var(--sd-ink-2); font-size: var(--sd-t-13); line-height: var(--sd-l-13); }
[data-site-design="nuevo"] .sd-asis-f2card__title {
  display: -webkit-box; margin: 0; overflow: hidden; color: var(--sd-ink); font-size: var(--sd-t-14); line-height: var(--sd-l-14); font-weight: var(--sd-w-550);
  -webkit-box-orient: vertical; -webkit-line-clamp: 2;
}
[data-site-design="nuevo"] .sd-asis-f2card__facts { display: flex; flex-wrap: wrap; gap: 2px var(--sd-s-10); margin: var(--sd-s-2) 0 0; color: var(--sd-ink-soft); font-size: var(--sd-t-13); line-height: var(--sd-l-13); }
[data-site-design="nuevo"] .sd-asis-f2card__value { color: var(--sd-ink); font-weight: var(--sd-w-700); }
[data-site-design="nuevo"] .sd-asis-f2card__soon { color: var(--sd-warn); font-weight: var(--sd-w-700); }
[data-site-design="nuevo"] .sd-asis-f2card__cta { flex: none; align-self: center; }
[data-site-design="nuevo"] .sd-asis-f2card--tienda .sd-asis-f2card__cta { border: 1px solid var(--sd-line); }
@media (max-width: 420px) {
  /* the icon and the words on one row, the button the whole width under them */
  [data-site-design="nuevo"] .sd-asis-f2card { flex-wrap: wrap; }
  [data-site-design="nuevo"] .sd-asis-f2card__body { flex-basis: 0; }
  [data-site-design="nuevo"] .sd-asis-f2card__cta { flex: 1 1 100%; justify-content: center; min-height: 44px; }
}

/* ---------- 3. «Dónde comprar»: a box with its head, up to three shops, each with «Ir ↗» ---------- */
[data-site-design="nuevo"] .sd-asis-donde { display: flex; flex-direction: column; gap: var(--sd-s-8); margin-top: var(--sd-s-12); padding: var(--sd-s-12); border: 1px solid var(--sd-line); border-radius: var(--sd-r-20); background: var(--sd-asis-sup); }
[data-site-design="nuevo"] .sd-asis-donde__title { display: flex; align-items: center; gap: var(--sd-s-8); margin: 0; color: var(--sd-ink); font-size: var(--sd-t-15); line-height: var(--sd-l-15); font-weight: var(--sd-w-700); }
[data-site-design="nuevo"] .sd-asis-donde__list { display: flex; flex-direction: column; gap: var(--sd-s-6); margin: 0; padding: 0; list-style: none; }
[data-site-design="nuevo"] .sd-asis-donde__row { display: flex; align-items: center; gap: var(--sd-s-10); padding: var(--sd-s-8) var(--sd-s-10); border-radius: var(--sd-r-12); background: var(--sd-paper); }
[data-site-design="nuevo"] .sd-asis-donde__shop { display: flex; flex: 1 1 auto; flex-direction: column; gap: 2px; min-width: 0; }
[data-site-design="nuevo"] .sd-asis-donde__name { overflow: hidden; color: var(--sd-ink); font-size: var(--sd-t-14); line-height: var(--sd-l-14); font-weight: var(--sd-w-550); text-overflow: ellipsis; white-space: nowrap; }
[data-site-design="nuevo"] .sd-asis-donde__marks,
[data-site-design="nuevo"] .sd-asis-donde__note { color: var(--sd-ink-2); font-size: var(--sd-t-12); line-height: var(--sd-l-12); }
[data-site-design="nuevo"] .sd-asis-donde__price { display: flex; flex: none; flex-direction: column; align-items: flex-end; gap: 2px; text-align: right; }
[data-site-design="nuevo"] .sd-asis-donde__price b { color: var(--sd-ink); font-size: var(--sd-t-15); line-height: var(--sd-l-15); font-weight: var(--sd-w-700); }
[data-site-design="nuevo"] .sd-asis-donde__ship { color: var(--sd-ink-soft); font-size: var(--sd-t-12); line-height: var(--sd-l-12); }
[data-site-design="nuevo"] .sd-asis-donde__go { flex: none; gap: var(--sd-s-4); }
[data-site-design="nuevo"] .sd-asis-donde__foot { margin: 0; color: var(--sd-ink-2); font-size: var(--sd-t-12); line-height: var(--sd-l-12); }
/* «Ver todas las tiendas» and «Avisarme si baja» side by side, wrapping when they do not fit */
[data-site-design="nuevo"] .sd-asis-donde__links { display: flex; flex-wrap: wrap; align-items: center; gap: var(--sd-s-4) var(--sd-s-16); }
[data-site-design="nuevo"] .sd-asis-donde__aviso { gap: var(--sd-s-6); }
@media (max-width: 420px) {
  /* each shop on one row (no gap under it): its name in two lines if it needs them, the button of 44; the links of 44 too */
  [data-site-design="nuevo"] .sd-asis-donde__row { gap: var(--sd-s-8); padding: var(--sd-s-8); }
  [data-site-design="nuevo"] .sd-asis-donde__name { white-space: normal; }
  [data-site-design="nuevo"] .sd-asis-donde__go { min-height: 44px; }
  [data-site-design="nuevo"] .sd-asis-donde__links .sd-more-link { min-height: 44px; }
}

/* ---------- 4. P8 · «✦ ¿Cuál me conviene? Pregunta a la IA» over the tray and on /comparar (phase 1's pill, its own words) ---------- */
[data-site-design="nuevo"] .sd-asis-seguir--comparar .sd-asis-seguir__text { white-space: normal; }
@media (max-width: 1023.98px) {
  [data-site-design="nuevo"] .sd-asis-seguir--comparar { right: var(--sd-s-16); bottom: calc(var(--floating-bottom-offset, 0px) + var(--sd-s-16)); max-width: calc(100vw - 2 * var(--sd-s-16)); }
}
