/* Directorio de proveedores: iconos de aplicación, búsqueda y navegación. */
@font-face {
    font-family: 'Plus Jakarta Sans';
    src: url('/fonts/plus-jakarta-sans-latin.woff2') format('woff2');
    font-style: normal;
    font-weight: 200 800;
    font-display: swap;
}

body.exploring-providers,
body.exploring-providers *,
body.in-provider-store,
body.in-provider-store * {
    font-family: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, sans-serif;
}
body.exploring-providers {
    background: #f8fafc;
    color: #0f172a;
    letter-spacing: 0;
}
body.exploring-providers ::selection { background: #0066ff; color: #fff; }
body.exploring-providers .app-container { padding-bottom: 0; }

/* El fondo de la cabecera ocupa la pantalla; su contenido sigue la rejilla. */
.marketplace-search, .marketplace-brand { display: none; }
body.exploring-providers .main-header {
    height: 64px;
    gap: 24px;
    padding: 10px max(24px, calc((100vw - 1152px) / 2 + 32px));
    border-bottom: 1px solid rgba(226, 232, 240, .8);
    background: #fff;
    box-shadow: none;
}
body.exploring-providers .main-header.es-desplazada { background: #fff; }
body.exploring-providers .main-header .logo {
    gap: 6px;
    padding: 0;
    font-size: 24px;
    font-weight: 800;
    letter-spacing: -1px;
    line-height: 32px;
}
body.exploring-providers .main-header .logo-com { color: #0f172a; }
body.exploring-providers .main-header .logo-pro {
    margin: 0;
    padding: 3px 8px;
    border-radius: 6px;
    font-size: 12px;
    font-weight: 800;
    line-height: 18px;
    letter-spacing: 1px;
    background: #0066ff;
}
body.exploring-providers .main-header .marketplace-brand {
    display: block;
    width: auto;
    height: 48px;
    object-fit: contain;
    background: transparent;
    mix-blend-mode: multiply;
}
body.exploring-providers .main-header .logo:has(.marketplace-brand) .logo-com,
body.exploring-providers .main-header .logo:has(.marketplace-brand) .logo-pro { display: none; }
body.exploring-providers #distributor-indicator { display: none !important; }
body.exploring-providers .marketplace-search {
    display: block;
    position: relative;
    flex: 1 1 448px;
    min-width: 0;
    max-width: 448px;
    margin-inline: auto;
}
body.exploring-providers .marketplace-search > svg {
    position: absolute;
    left: 14px;
    top: 50%;
    width: 16px;
    height: 16px;
    transform: translateY(-50%);
    color: #64748b;
    pointer-events: none;
}
body.exploring-providers #provider-search-input {
    display: block;
    width: 100%;
    min-height: 36px;
    padding: 9px 16px 9px 38px;
    border: 1px solid #e2e8f0;
    border-radius: 999px;
    background: #fff;
    box-shadow: 0 1px 2px rgba(15, 23, 42, .05);
    color: #0f172a;
    font-size: 12px;
    font-weight: 500;
    line-height: 18px;
    letter-spacing: 0;
    transition: background-color 150ms ease, box-shadow 150ms ease;
}
body.exploring-providers #provider-search-input::placeholder { color: #64748b; opacity: 1; }
body.exploring-providers #provider-search-input:focus { background: #fff; box-shadow: 0 0 0 2px #0066ff; }
body.exploring-providers .main-header .btn-header-register {
    flex-shrink: 0;
    min-height: 36px;
    padding: 9px 16px;
    border-radius: 999px;
    color: #fff;
    background: #0066ff;
    font-size: 12px;
    font-weight: 700;
    line-height: 18px;
    letter-spacing: 0;
}
body.exploring-providers .main-header .btn-header-register:hover { background: #0052cc; }
body.exploring-providers .main-header .sn-header { margin-left: 0; }

/* Abajo deja sitio al dock (78px a 24px del borde) para que no tape nada. */
body.exploring-providers #provider-modal.provider-explorer {
    padding: 26px 24px calc(120px + env(safe-area-inset-bottom));
}
body.exploring-providers .provider-explorer-content {
    max-width: 1104px;
    margin-inline: auto;
}
body.exploring-providers .provider-heading {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    width: 100%;
    max-width: 896px;
    gap: 8px;
    margin: 0 auto;
    padding: 2px 0 24px;
    border: 0;
    border-bottom: 1px solid rgba(226, 232, 240, .6);
}
body.exploring-providers .provider-heading-summary { flex-shrink: 0; }
body.exploring-providers .provider-title { align-items: center; justify-content: center; gap: 10px; }
body.exploring-providers #provider-modal.provider-explorer h1 {
    margin: 0;
    padding: 0;
    color: #0f172a;
    font-size: 30px;
    font-weight: 800;
    line-height: 38px;
    letter-spacing: -1px;
}
body.exploring-providers #provider-results {
    margin: 0;
    padding: 2px 8px;
    border: 1px solid rgba(0, 102, 255, .1);
    border-radius: 999px;
    background: #eff6ff;
    color: #0066ff;
    font-size: 12px;
    font-weight: 700;
    line-height: 16px;
}
body.exploring-providers #provider-results:empty { display: none; }
body.exploring-providers .provider-heading-context {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    column-gap: 12px;
    row-gap: 0;
    max-width: 100%;
    padding-top: 0;
    color: #64748b;
    font-size: 12px;
    font-weight: 500;
    text-align: center;
}
body.exploring-providers .provider-market-label { display: none; }
body.exploring-providers #provider-modal #provider-zone {
    width: auto;
    margin: 0;
    padding: 0;
    border: 0;
    color: #64748b;
    font-size: 12px;
    font-weight: 500;
    line-height: 22px;
    text-align: center;
}
body.exploring-providers #provider-zone:empty { display: none; }
body.exploring-providers #cp-publico-cambiar {
    min-height: 44px;
    margin: 0;
    padding: 0;
    color: #0066ff;
    font-size: 12px;
    font-weight: 600;
    line-height: 22px;
}
body.exploring-providers .provider-tools {
    padding: 0;
    border: 0;
    border-radius: 0;
    background: none;
    box-shadow: none;
}
body.exploring-providers .provider-tools label { gap: 6px; min-height: 44px; font-size: 12px; font-weight: 500; }
body.exploring-providers .provider-tools input { width: 14px; height: 14px; accent-color: #0066ff; }

/* Solo el icono tiene superficie: nombre y controles flotan en el lienzo. */
body.exploring-providers #provider-list {
    display: grid;
    width: 100%;
    max-width: 896px;
    margin: 0 auto;
    padding: 64px 0 80px;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    column-gap: 32px;
    row-gap: 40px;
    justify-items: center;
    overflow: visible;
}
body.exploring-providers #provider-list .provider-choice {
    position: relative;
    display: block;
    width: 112px;
    min-width: 0;
    height: auto;
    padding: 0;
    border: 0;
    border-radius: 0;
    background: none;
    box-shadow: none;
    overflow: visible;
    cursor: default;
    transform: none;
    opacity: 1;
}
body.exploring-providers #provider-list .provider-choice[hidden] { display: none; }
body.exploring-providers #provider-list .provider-filter-empty[hidden] { display: none !important; }
body.exploring-providers #provider-list .provider-choice:hover,
body.exploring-providers #provider-list .provider-choice:active { border: 0; background: none; box-shadow: none; transform: none; opacity: 1; }
body.exploring-providers #provider-list .provider-choice:has(.provider-options[open]) { z-index: 20; }
body.exploring-providers #provider-list .provider-enter,
body.exploring-providers #provider-list .provider-enter.provider-catalog {
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 100%;
    min-height: 0;
    margin: 0;
    padding: 0;
    border: 0;
    border-radius: 8px;
    background: none;
    box-shadow: none;
    color: #0f172a;
    font-weight: 600;
    text-align: center;
    cursor: pointer;
    transform-origin: center;
    transition: transform 180ms cubic-bezier(.34, 1.56, .64, 1), opacity 150ms ease, filter 150ms ease;
}
body.exploring-providers #provider-list .provider-enter:active { transform: scale(.93); filter: brightness(.96); }
body.exploring-providers #provider-list .provider-catalog:not(.provider-enter) { display: none; }
body.exploring-providers #provider-list .card-img-wrapper {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 96px;
    height: 96px;
    max-width: none;
    margin: 0 0 12px;
    padding: 12px;
    border: 1px solid #e2e8f0;
    border-radius: 24px;
    background: #fff;
    box-shadow: 0 8px 24px -4px rgba(15, 23, 42, .08), 0 2px 6px -1px rgba(15, 23, 42, .04);
    overflow: hidden;
    animation: none;
    transition: box-shadow 300ms ease;
}
body.exploring-providers #provider-list .provider-enter img {
    width: 100% !important;
    height: 100% !important;
    max-width: 100%;
    max-height: 100%;
    padding: 0;
    border-radius: 0;
    background: none;
    object-fit: contain;
}
body.exploring-providers #provider-list .card-img-wrapper:has(img[src*="logo_avicola"]) { padding: 8px; background: #fff; box-shadow: 0 16px 32px -4px rgba(220, 140, 40, .28), 0 4px 14px -2px rgba(15, 23, 42, .06); }
body.exploring-providers #provider-list .card-img-wrapper:has(img[src*="logo_moncarnes"]) { padding: 0; border: 0; background: #00965e; box-shadow: 0 16px 32px -4px rgba(0, 155, 104, .42), 0 6px 14px -2px rgba(0, 155, 104, .25); }
body.exploring-providers #provider-list .provider-enter img[src*="logo_moncarnes"] { object-fit: cover; }
body.exploring-providers #provider-list .card-img-wrapper:has(img[src*="logo_eiriz"], img[src*="marketplace-eiriz"]) { padding: 0; border: 0; background: #000; box-shadow: 0 16px 34px -4px rgba(0, 0, 0, .55), 0 6px 16px -2px rgba(0, 0, 0, .35); }
body.exploring-providers #provider-list .provider-enter img[src*="logo_eiriz"],
body.exploring-providers #provider-list .provider-enter img[src*="marketplace-eiriz"] { object-fit: cover; }
body.exploring-providers #provider-list .card-img-wrapper:has(img[src*="logo_navarro"]) { padding: 8px; background: #fff; box-shadow: 0 16px 32px -4px rgba(140, 20, 40, .28), 0 4px 14px -2px rgba(15, 23, 42, .06); }
body.exploring-providers #provider-list .card-img-wrapper:has(img[src*="logo_CW"]) { background: #edf6f3; box-shadow: 0 10px 25px -5px rgba(0, 88, 72, .22); }
body.exploring-providers #provider-list .provider-logo-fallback {
    width: 100% !important;
    height: 100% !important;
    border-radius: 14px;
    font-size: 26px !important;
    font-weight: 800;
}
body.exploring-providers #provider-list .card-name {
    display: block;
    width: 100%;
    min-height: 18px;
    height: auto;
    max-height: none;
    margin: 0;
    padding: 0;
    color: #0f172a;
    font-size: 14px;
    font-weight: 600;
    line-height: 18px;
    letter-spacing: 0;
    text-overflow: clip;
    white-space: normal;
    overflow: visible;
    overflow-wrap: anywhere;
    -webkit-line-clamp: unset;
    transition: color 150ms ease;
}
body.exploring-providers #provider-list .provider-description {
    position: absolute;
    width: 1px;
    height: 1px;
    margin: -1px;
    padding: 0;
    border: 0;
    overflow: hidden;
    clip-path: inset(50%);
    white-space: nowrap;
}
body.exploring-providers #provider-list .provider-favorite {
    top: -8px;
    right: -4px;
    width: 40px;
    height: 40px;
    color: #64748b;
    background: rgba(255, 255, 255, .96);
    box-shadow: 0 2px 7px rgba(15, 23, 42, .09);
    opacity: 0;
    z-index: 3;
    transition: opacity 150ms ease, color 150ms ease;
}
body.exploring-providers #provider-list .provider-favorite svg { width: 15px; height: 15px; }
body.exploring-providers #provider-list .provider-favorite.active { color: #0066ff; background: #fff; opacity: 1; }
body.exploring-providers #provider-list .provider-choice:focus-within .provider-favorite { opacity: 1; }

/* Los permisos originales determinan qué acciones contiene este desplegable. */
body.exploring-providers #provider-list .provider-options { position: absolute; top: 80px; right: -10px; z-index: 4; }
body.exploring-providers #provider-list .provider-options > summary {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    border: 0;
    border-radius: 50%;
    background: rgba(248, 250, 252, .92);
    color: #64748b;
    cursor: pointer;
    list-style: none;
}
body.exploring-providers #provider-list .provider-options > summary::-webkit-details-marker { display: none; }
body.exploring-providers #provider-list .provider-options > summary svg { width: 18px; height: 18px; }
body.exploring-providers #provider-list .provider-options[open] > summary { color: #0066ff; background: #eff6ff; }
body.exploring-providers #provider-list .provider-options:not([open]) > .provider-actions { display: none; }
body.exploring-providers #provider-list .provider-options .provider-actions {
    position: absolute;
    top: calc(100% + 6px);
    right: 0;
    display: grid;
    grid-template-columns: 1fr;
    width: 190px;
    margin: 0;
    padding: 6px;
    gap: 2px;
    border: 1px solid #e2e8f0;
    border-radius: 14px;
    background: #fff;
    box-shadow: 0 12px 32px rgba(15, 23, 42, .14);
    z-index: 20;
}
body.exploring-providers #provider-list .provider-options .provider-actions button {
    display: flex !important;
    align-items: center;
    justify-content: flex-start;
    gap: 8px;
    width: 100% !important;
    min-width: 0;
    min-height: 44px;
    padding: 10px 12px;
    border: 0;
    border-radius: 8px !important;
    background: #fff;
    color: #475569;
    font-size: 12px !important;
    font-weight: 600;
    line-height: 18px;
    text-align: left;
    cursor: pointer;
}
body.exploring-providers #provider-list .provider-options .provider-actions button:hover { background: #f1f5f9; color: #0066ff; }
body.exploring-providers #provider-list .provider-options .provider-actions button[data-csp-click="164"] { color: #dc2626; }
body.exploring-providers #provider-list .provider-options .provider-actions button[data-csp-click="164"]:hover { background: #fff1f2; }
body.exploring-providers #provider-list .provider-empty { width: 100%; }
body.exploring-providers #provider-list > button { grid-column: 1 / -1; }

/* El dock conserva destinos, visibilidad por rol y su capa de navegación. */
.bottom-nav {
    width: min(560px, calc(100% - 32px));
    height: 78px;
    bottom: calc(24px + env(safe-area-inset-bottom));
    left: 50%;
    transform: translateX(-50%);
    padding: 10px 24px;
    border: 1px solid rgba(226, 232, 240, .8);
    border-radius: 999px;
    background: rgba(255, 255, 255, .85);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    box-shadow: 0 20px 40px -10px rgba(15, 23, 42, .12), 0 0 1px 1px rgba(255, 255, 255, .9) inset;
}
.bottom-nav .nav-item {
    min-width: 44px;
    min-height: 56px;
    gap: 4px;
    padding: 0;
    border-radius: 12px;
    background: none;
    color: #64748b;
    font-family: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, sans-serif;
    font-size: 12px;
    font-weight: 500;
    letter-spacing: 0;
}
.bottom-nav .nav-item span { font-family: inherit; }
.bottom-nav .nav-item svg { width: 24px; height: 24px; stroke-width: 2; }
.bottom-nav .nav-item.active { background: none; color: #0066ff; font-weight: 600; }
.bottom-nav .nav-item[hidden] { display: none !important; }

body.in-provider-store {
    --store-accent: #0066ff;
    --store-soft: #eff6ff;
    --store-glow: 0, 102, 255;
    --store-banner: linear-gradient(110deg, #003d99, #0066ff, #3b82f6);
}
body[data-storefront-provider="moncarnes"] {
    --store-accent: #00965e;
    --store-soft: #ecfdf5;
    --store-glow: 0, 155, 104;
    --store-banner: linear-gradient(110deg, #006640, #00965e, #10b981);
}
body[data-storefront-provider="avicola"] {
    --store-accent: #d97706;
    --store-soft: #fff7ed;
    --store-glow: 220, 140, 40;
    --store-banner: linear-gradient(110deg, #b45309, #d97706, #f59e0b);
}
body[data-storefront-provider="eiriz"] {
    --store-accent: #18181b;
    --store-soft: #f4f4f5;
    --store-glow: 0, 0, 0;
    --store-banner: linear-gradient(110deg, #000, #1c1917, #44403c);
}
body[data-storefront-provider="navarro"] {
    --store-accent: #881337;
    --store-soft: #fff1f2;
    --store-glow: 140, 20, 40;
    --store-banner: linear-gradient(110deg, #4c0519, #881337, #be123c);
}

/* Una transición breve conserva el contexto del proveedor al abrir su tienda. */
body.in-provider-store { background: #f8fafc; color: #0f172a; letter-spacing: 0; }
body.in-provider-store .app-container { padding-bottom: 0; }
body.in-provider-store .main-header {
    height: 64px;
    padding-inline: max(24px, calc((100vw - 1152px) / 2 + 32px));
    background: #fff;
    border-bottom: 1px solid #e2e8f0;
    box-shadow: none;
}
body.in-provider-store .main-header .logo { padding: 0; }
body.in-provider-store .main-header .marketplace-brand { display: block; width: auto; height: 48px; object-fit: contain; background: transparent; mix-blend-mode: multiply; }
body.in-provider-store .main-header .logo:has(.marketplace-brand) .logo-com,
body.in-provider-store .main-header .logo:has(.marketplace-brand) .logo-pro { display: none; }
body.in-provider-store #distributor-indicator { display: none !important; }
body.in-provider-store .storefront-header {
    position: sticky;
    top: 64px;
    z-index: 900;
    display: block;
    width: 100%;
    border-bottom: 1px solid #e2e8f0;
    background: rgba(255, 255, 255, .95);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    box-shadow: 0 1px 2px rgba(15, 23, 42, .04);
}
.storefront-header-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    max-width: 1152px;
    margin: 0 auto;
    padding: 14px 32px;
    gap: 16px;
}
.storefront-identity { display: flex; align-items: center; min-width: 0; gap: 8px; }
#storefront-back,
#storefront-conditions {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    min-height: 44px;
    padding: 8px 12px;
    border: 1px solid #e2e8f0;
    border-radius: 999px;
    background: #f1f5f9;
    color: #334155;
    font-size: 12px;
    font-weight: 700;
    line-height: 18px;
    gap: 6px;
    cursor: pointer;
    transition: background-color 150ms ease, color 150ms ease;
}
#storefront-back svg,
#storefront-conditions svg { width: 16px; height: 16px; flex-shrink: 0; }
#storefront-back:hover { background: #eff6ff; color: #0066ff; }
#storefront-conditions { border-color: transparent; background: var(--store-soft); color: var(--store-accent); }
#storefront-conditions:hover { filter: brightness(.97); }
#storefront-logo { width: 28px; height: 28px; padding: 0; border-radius: 8px; background: #fff; object-fit: contain; flex-shrink: 0; }
body[data-storefront-provider="moncarnes"] #storefront-logo,
body[data-storefront-provider="eiriz"] #storefront-logo { object-fit: cover; }
#storefront-name { min-width: 0; color: #0f172a; font-size: 14px; font-weight: 700; line-height: 20px; overflow-wrap: anywhere; }
body.in-provider-store .storefront-hero { display: block; width: 100%; max-width: 1152px; margin: 24px auto 0; padding: 0 32px; }
#storefront-hero-banner {
    position: relative;
    padding: 40px;
    border-radius: 24px;
    background: var(--store-banner);
    color: #fff;
    overflow: hidden;
    transition: background-color 300ms ease;
}
#storefront-hero-banner > * { position: relative; z-index: 1; }
#storefront-hero-banner::after { content: ''; position: absolute; right: -32px; bottom: -48px; width: 256px; height: 256px; border-radius: 50%; background: rgba(255, 255, 255, .1); filter: blur(40px); pointer-events: none; }
.storefront-channel {
    display: inline-flex;
    align-items: center;
    min-height: 28px;
    margin-bottom: 12px;
    padding: 4px 12px;
    border: 1px solid rgba(255, 255, 255, .3);
    border-radius: 999px;
    background: rgba(255, 255, 255, .2);
    color: #fff;
    font-size: 12px;
    font-weight: 600;
    line-height: 18px;
    gap: 6px;
}
.storefront-channel svg { width: 14px; height: 14px; }
#storefront-title { max-width: 672px; margin: 0 0 8px; color: #fff; font-size: 40px; font-weight: 800; line-height: 48px; letter-spacing: -.9px; overflow-wrap: anywhere; }
#storefront-description { max-width: 672px; margin: 0 0 24px; color: rgba(255, 255, 255, .95); font-size: 16px; font-weight: 500; line-height: 24px; }
#storefront-description:empty { display: none; }
#storefront-terms { display: flex; align-items: center; flex-wrap: wrap; gap: 12px; color: #fff; font-size: 12px; font-weight: 700; line-height: 18px; }
#storefront-terms:empty { display: none; }
#storefront-terms > span { display: inline-flex; align-items: center; gap: 6px; padding: 6px 12px; border: 1px solid rgba(255, 255, 255, .1); border-radius: 12px; background: rgba(0, 0, 0, .25); }
#storefront-terms svg { width: 15px; height: 15px; flex-shrink: 0; }
body.in-provider-store #view-tienda > .storefront-filters {
    display: flex;
    align-items: center;
    position: static;
    width: calc(100% - 64px);
    max-width: 1088px;
    margin: 32px auto 0;
    padding: 0 0 16px;
    gap: 16px;
    border: 0;
    border-bottom: 1px solid #e2e8f0;
    border-radius: 0;
    background: none;
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
    box-shadow: none;
}
body.in-provider-store .storefront-filters #category-scroll { flex: 1 1 auto; min-width: 0; max-width: none; margin: 0; padding: 0; gap: 8px; }
body.in-provider-store .storefront-filters .sort-filter-bar { display: flex; align-items: center; min-width: 0; padding: 0; gap: 12px; }
body.in-provider-store .storefront-filters .sort-dropdown { margin: 0; padding: 0; border: 0; background: none; box-shadow: none; }
body.in-provider-store .storefront-filters #sort-select { min-height: 44px; max-width: 132px; padding: 8px 10px; border: 1px solid #e2e8f0; border-radius: 999px; background: #fff; color: #475569; font-size: 12px; font-weight: 600; }
body.in-provider-store .storefront-filters .chip { min-height: 36px; padding: 8px 14px; border-color: #e2e8f0; border-radius: 999px; background: #fff; color: #475569; font-size: 12px; font-weight: 600; line-height: 18px; }
body.in-provider-store .storefront-filters .chip.active { background: #0f172a; border-color: #0f172a; color: #fff; }
body.in-provider-store .storefront-filters .chip-marca.active { background: var(--store-accent); border-color: var(--store-accent); color: #fff; }
body.in-provider-store .storefront-search { display: block; position: relative; width: 288px; min-width: 0; max-width: 100%; }
.storefront-search > svg { position: absolute; left: 12px; top: 50%; width: 16px; height: 16px; transform: translateY(-50%); color: #64748b; pointer-events: none; }
#storefront-search { width: 100%; min-width: 0; min-height: 44px; padding: 10px 14px 10px 36px; border: 1px solid #e2e8f0; border-radius: 999px; background: #fff; color: #1e293b; font-size: 12px; line-height: 18px; }
#storefront-search::placeholder { color: #64748b; opacity: 1; }
#storefront-search:focus { border-color: #0066ff; box-shadow: 0 0 0 2px rgba(0, 102, 255, .12); }
body.in-provider-store #view-tienda #grid {
    display: grid;
    width: calc(100% - 64px);
    max-width: 1088px;
    margin: 24px auto 0;
    padding: 0 0 calc(180px + env(safe-area-inset-bottom));
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 24px;
}
body.in-provider-store #grid .product-card { min-width: 0; padding: 20px; border: 1px solid #e2e8f0; border-radius: 16px; background: #fff; box-shadow: 0 1px 2px rgba(15, 23, 42, .05); transition: box-shadow 150ms ease; }
body.in-provider-store #grid .product-card:hover { box-shadow: 0 4px 12px rgba(15, 23, 42, .08); }
body.in-provider-store #grid .product-card:active { transform: none; opacity: 1; background: #fff; }
body.in-provider-store #grid .card-img-wrapper { height: 160px; margin-bottom: 14px; padding: 12px; border: 1px solid #f1f5f9; border-radius: 12px; background: #f8fafc; }
body.in-provider-store #grid .card-img-wrapper:has(img.loaded) { background: #fff; }
body.in-provider-store #grid .card-brand { margin-bottom: 6px; color: #64748b; font-size: 12px; font-weight: 700; line-height: 16px; letter-spacing: .6px; }
body.in-provider-store #grid .card-name { display: block; min-height: 40px; height: auto; max-height: none; margin-bottom: 6px; color: #0f172a; font-size: 14px; font-weight: 700; line-height: 20px; overflow: visible; overflow-wrap: anywhere; -webkit-line-clamp: unset; }
body.in-provider-store #grid .card-desc { min-height: 36px; height: auto; margin-bottom: 16px; color: #64748b; font-size: 12px; line-height: 18px; }
body.in-provider-store #grid .card-footer { margin-top: auto; padding-top: 12px; border-top: 1px solid #f1f5f9; gap: 8px; }
body.in-provider-store #grid .card-price { color: #0f172a; font-size: 16px; font-weight: 800; }
body.in-provider-store #grid .card-actions { flex-direction: column; align-items: stretch; gap: 8px; }
body.in-provider-store #grid .qty-control { width: 100%; min-width: 0; height: 44px; border: 0; border-radius: 12px; background: #f8fafc; box-shadow: inset 0 0 0 1px #e2e8f0; }
body.in-provider-store #grid .qty-btn { width: 44px; min-width: 44px; height: 44px; min-height: 44px; background: none; color: #334155; font-size: 18px; }
body.in-provider-store #grid .qty-input { flex: 1; width: 24px; min-width: 24px; color: #0f172a; font-size: 16px; }
body.in-provider-store #grid .btn-add-card { width: 100%; min-height: 44px; height: 44px; padding-inline: 8px; border-radius: 12px; background: #0066ff; border-color: #0066ff; color: #fff; font-size: 12px; font-weight: 700; }
body.in-provider-store #grid .btn-add-card.btn-added { background: #dcfce7; border-color: #bbf7d0; color: #166534; }
body.in-provider-store #grid .btn-add-card.btn-agotado { background: #f1f5f9; border-color: #e2e8f0; color: #64748b; }

.storefront-conditions-detail { margin-top: 24px; padding: 20px; border: 1px solid #e2e8f0; border-radius: 16px; background: #f8fafc; color: #475569; text-align: left; }
.storefront-conditions-detail[hidden] { display: none !important; }
.storefront-conditions-detail h2,
.storefront-conditions-detail h3 { margin: 0 0 12px; color: #0f172a; font-size: 16px; font-weight: 700; line-height: 22px; }
.storefront-conditions-detail p,
.storefront-conditions-detail dl { margin: 0; font-size: 13px; line-height: 20px; }
.storefront-conditions-detail dl { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 10px 16px; }
.storefront-conditions-detail dd { color: #0f172a; font-weight: 600; text-align: right; }
.storefront-empty { grid-column: 1 / -1; width: 100%; padding: 64px 24px; color: #64748b; font-size: 14px; line-height: 22px; text-align: center; }

@media (hover: hover) and (pointer: fine) {
    body.exploring-providers #provider-list .provider-enter:hover .card-name { color: #0052cc; }
    body.exploring-providers #provider-list .provider-choice:hover .provider-favorite { opacity: 1; }
    body.exploring-providers #provider-list .provider-options > summary:hover { color: #475569; background: #fff; }
    .bottom-nav .nav-item:not(.active):hover { color: #0066ff; background: none; }
}
@media (min-width: 640px) {
    body.exploring-providers #provider-list { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 48px; }
    body.exploring-providers #provider-list .provider-choice { width: 128px; }
    body.exploring-providers #provider-list .card-img-wrapper { width: 112px; height: 112px; padding: 16px; }
    body.exploring-providers #provider-list .provider-options { top: 96px; }
    body.exploring-providers #provider-list .provider-choice:nth-child(4n + 1) .provider-actions { left: 0; right: auto; }
}
@media (min-width: 1024px) {
    body.exploring-providers .main-header { padding-inline: max(32px, calc((100vw - 1152px) / 2 + 32px)); }
    body.exploring-providers #provider-modal.provider-explorer { padding-inline: 32px; }
    body.exploring-providers .provider-explorer-content { max-width: 1088px; }
}
@media (max-width: 1023px) {
    body.in-provider-store #view-tienda #grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 767px) {
    .storefront-header-inner { padding-inline: 24px; }
    body.in-provider-store .storefront-hero { padding-inline: 24px; }
    body.in-provider-store #view-tienda > .storefront-filters { width: calc(100% - 48px); flex-direction: column; align-items: stretch; gap: 12px; }
    body.in-provider-store .storefront-filters #category-scroll { width: 100%; flex: none; }
    body.in-provider-store .storefront-filters .sort-filter-bar { width: 100%; flex-wrap: wrap; gap: 12px; }
    body.in-provider-store .storefront-search { flex: 1 1 220px; width: auto; max-width: none; }
    body.in-provider-store #view-tienda #grid { width: calc(100% - 48px); gap: 16px; }
    body.in-provider-store #grid .product-card { padding: 16px; }
}
@media (max-width: 639px) {
    body.exploring-providers .main-header { height: auto; min-height: 64px; flex-wrap: wrap; gap: 10px 16px; padding: 10px 24px 12px; }
    body.exploring-providers .main-header .logo { order: 0; }
    body.exploring-providers .main-header .marketplace-brand { height: 44px; }
    body.exploring-providers .main-header .btn-header-register { order: 1; margin-left: auto; min-height: 44px; }
    body.exploring-providers .main-header .sn-header { order: 1; margin-left: auto; }
    body.exploring-providers .marketplace-search { order: 2; flex-basis: 100%; max-width: none; margin: 0; }
    body.exploring-providers #provider-search-input { min-height: 44px; font-size: 16px; line-height: 22px; }
    body.exploring-providers #provider-modal.provider-explorer { padding-top: 24px; }
    body.exploring-providers .provider-heading { gap: 8px; padding-bottom: 16px; }
    body.exploring-providers #provider-modal.provider-explorer h1 { font-size: 24px !important; line-height: 32px; }
    body.exploring-providers .provider-heading-context { width: 100%; }
    body.exploring-providers #provider-list { padding-top: 48px; }
    body.exploring-providers #provider-list .provider-favorite { width: 44px; height: 44px; top: -12px; right: -12px; opacity: 1; }
    body.exploring-providers #provider-list .provider-options { right: -16px; top: 70px; }
    body.exploring-providers #provider-list .provider-options > summary { width: 44px; height: 44px; }
    body.exploring-providers #provider-list .provider-choice:nth-child(2n + 1) .provider-actions { left: 0; right: auto; }
    body.in-provider-store .main-header { padding-inline: 16px; }
    body.in-provider-store .main-header .marketplace-brand { height: 44px; }
    .storefront-header-inner { padding: 12px 16px; flex-wrap: wrap; gap: 8px; }
    #storefront-name { display: none; }
    #storefront-back { padding-inline: 10px; font-size: 12px; }
    #storefront-conditions { padding-inline: 10px; font-size: 12px; }
    body.in-provider-store .storefront-hero { margin-top: 16px; padding-inline: 16px; }
    #storefront-hero-banner { padding: 24px; }
    #storefront-title { font-size: 28px; line-height: 34px; letter-spacing: -.6px; }
    #storefront-description { font-size: 14px; line-height: 22px; }
    #storefront-terms { gap: 8px; }
    body.in-provider-store #view-tienda > .storefront-filters { width: calc(100% - 32px); margin-top: 24px; }
    #storefront-search { font-size: 16px; line-height: 22px; }
    body.in-provider-store #view-tienda #grid { width: calc(100% - 32px); }
    body.in-provider-store #grid .product-card { padding: 12px; }
    body.in-provider-store #grid .card-img-wrapper { height: 112px; padding: 10px; }
    body.in-provider-store #grid .card-name { font-size: 13px; line-height: 19px; min-height: 38px; }
    body.in-provider-store #grid .card-price { font-size: 14px; }
    .bottom-nav { padding: 10px 14px; }
    .bottom-nav .nav-item { font-size: 12px; }
    .bottom-nav .nav-item svg { width: 24px; height: 24px; }
}
@media (hover: none), (pointer: coarse) {
    body.exploring-providers #provider-search-input { min-height: 44px; font-size: 16px; }
    body.exploring-providers .main-header .btn-header-register { min-height: 44px; }
    body.exploring-providers #provider-list .provider-favorite { width: 44px; height: 44px; opacity: 1; }
    body.exploring-providers #provider-list .provider-options > summary { width: 44px; height: 44px; }
    body.in-provider-store .storefront-filters .chip { min-height: 44px; }
    #storefront-search { font-size: 16px; }
}
@media (max-width: 359px) {
    body.exploring-providers .main-header { padding-inline: 16px; }
    body.exploring-providers #provider-modal.provider-explorer { padding-inline: 16px; }
    body.exploring-providers #provider-list { column-gap: 20px; }
    body.in-provider-store #view-tienda #grid { gap: 12px; }
    body.in-provider-store #grid .product-card { padding: 10px; }
    .bottom-nav { width: calc(100% - 16px); padding-inline: 8px; }
}
@media (prefers-reduced-motion: reduce) {
    body.exploring-providers #provider-list .provider-enter,
    body.exploring-providers #provider-list .card-img-wrapper,
    body.exploring-providers #provider-list .provider-favorite { transition: none; }
    body.exploring-providers #provider-list .provider-enter:active { transform: none; }
    #storefront-hero-banner { transition: none; }
}
@supports not ((backdrop-filter: blur(1px)) or (-webkit-backdrop-filter: blur(1px))) {
    body.exploring-providers .main-header,
    .bottom-nav { background: #fff; }
    body.in-provider-store .storefront-header { background: #fff; }
}

/* Visitante sin sesión ni código postal (05/11): la tienda pide entrar; el CP
   se pone en la portada. Letra ≥ 15 px y botones de 52 px: el listón es un
   comprador de 60 años (reunión del 30/09). */
body.exploring-providers #provider-list .tienda-entrar {
    grid-column: 1 / -1;
    justify-self: stretch;
    width: 100%;
    max-width: 560px;
    margin: 0 auto;
    padding: 28px;
    background: #fff;
    border: 1px solid var(--compro-borde);
    border-radius: 24px;
    box-shadow: var(--compro-sombra);
    text-align: center;
}
.tienda-entrar-titulo { margin: 0 0 8px; color: var(--apple-black); font-size: 24px; font-weight: 800; letter-spacing: -.01em; }
.tienda-entrar-texto { margin: 0 0 22px; color: var(--apple-text-sec); font-size: 16px; line-height: 1.5; }
.tienda-entrar-botones { display: flex; justify-content: center; gap: 12px; }
#provider-modal .tienda-entrar-botones button {
    flex: 1 1 0;
    max-width: 240px;
    min-height: 52px;
    margin: 0;
    padding: 0 20px;
    border-radius: 14px;
    font: inherit;
    font-size: 16px;
    font-weight: 700;
    cursor: pointer;
    box-shadow: none;
    -webkit-backdrop-filter: none;
    backdrop-filter: none;
}
#provider-modal .tienda-entrar-login { border: 0; background: var(--apple-blue); color: #fff; }
#provider-modal .tienda-entrar-login:hover { background: #0052cc; }
#provider-modal .tienda-entrar-crear { border: 1.5px solid var(--apple-blue); background: #fff; color: var(--apple-blue); }
#provider-modal .tienda-entrar-crear:hover { background: #eef4ff; }
.tienda-entrar-error { margin: 18px 0 0; color: #b91c1c; font-size: 15px; font-weight: 600; }
.tienda-entrar-mirar { margin: 22px 0 0; color: var(--apple-text-sec); font-size: 15px; line-height: 1.5; }
.tienda-entrar-mirar a { color: var(--apple-blue); font-weight: 700; }
/* Lo de arriba del directorio repetía lo mismo que el recuadro: fuera. */
#provider-modal.pide-cp .provider-heading { display: none; }

@media (max-width: 639px) {
    body.exploring-providers #provider-list .tienda-entrar { padding: 22px 18px; border-radius: 20px; }
    .tienda-entrar-botones { flex-direction: column; align-items: stretch; }
    #provider-modal .tienda-entrar-botones button { max-width: none; }
}

/* «Entrar» y «Regístrate» en la cabecera del invitado (05/11): «Entrar» es el
   principal, en azul; «Regístrate» va al lado, con borde. El id gana a las
   reglas de clase que colocan los dos. */
.main-header #header-entrar { margin-left: auto; }
.main-header #btn-header-register { margin-left: 8px; background: #fff; color: #0066ff; box-shadow: inset 0 0 0 1.5px #0066ff; }
.main-header #btn-header-register:hover { background: #eef4ff; }

/* ── Directorio de proveedores: tarjeta del diseño de alex (01/11) ──────────
   1 columna en móvil, 2 desde 640 px y 4 desde 1024 px. Fila de arriba con el
   «…» y el corazón, logo 16:10 con el color de la marca, nombre con la
   insignia de verificado, población, portes y mínimo, y los dos botones.
   Solo cuando hay proveedores: el mismo contenedor lleva el formulario del CP. */
/* Desde 640 px (tablet y escritorio). En el móvil se quedan los iconos de app de
   antes (alex, 01/11): ver «En el móvil, iconos de app» más abajo. */
@media (min-width: 640px) {
body.exploring-providers #provider-list:has(.provider-choice) {
    width: calc(100% - 32px);
    max-width: 1088px;
    padding: 8px 0 calc(180px + env(safe-area-inset-bottom));
    grid-template-columns: minmax(0, 1fr);
    gap: 24px;
    justify-items: stretch;
    align-items: stretch;
}
body.exploring-providers #provider-list .provider-choice {
    display: flex;
    flex-direction: column;
    width: auto;
    padding: 20px;
    border: 1px solid #e2e8f0;
    border-radius: 16px;
    background: #fff;
    box-shadow: 0 1px 2px rgba(15, 23, 42, .05);
    cursor: pointer;
    transition: box-shadow 200ms ease, border-color 200ms ease;
}
body.exploring-providers #provider-list .provider-choice:hover,
body.exploring-providers #provider-list .provider-choice:active {
    border: 1px solid #b3c5ff;
    background: #fff;
    box-shadow: 0 10px 15px -3px rgba(15, 23, 42, .1), 0 4px 6px -4px rgba(15, 23, 42, .1);
}
body.exploring-providers #provider-list .provider-top { display: flex; align-items: center; justify-content: space-between; margin-bottom: 16px; }
body.exploring-providers #provider-list .provider-choice .provider-options { position: relative; top: auto; left: auto; right: auto; }
body.exploring-providers #provider-list .provider-choice .provider-options > summary,
body.exploring-providers #provider-list .provider-choice .provider-favorite {
    position: static;
    width: 36px;
    height: 36px;
    margin: -6px;
    border-radius: 50%;
    background: none;
    box-shadow: none;
    color: #475569;
    opacity: 1;
}
body.exploring-providers #provider-list .provider-choice .provider-options > summary svg,
body.exploring-providers #provider-list .provider-choice .provider-favorite svg { width: 20px; height: 20px; }
body.exploring-providers #provider-list .provider-choice .provider-options > summary:hover,
body.exploring-providers #provider-list .provider-choice .provider-favorite:hover { background: #f1f5f9; color: #0b1c30; }
body.exploring-providers #provider-list .provider-choice .provider-favorite.active { color: #ba1a1a; background: none; }
body.exploring-providers #provider-list .provider-choice .provider-options .provider-actions { left: 0; right: auto; }
body.exploring-providers #provider-list .provider-choice .provider-enter { align-items: stretch; text-align: left; transition: none; }
body.exploring-providers #provider-list .provider-choice .provider-enter:active { transform: none; filter: none; }
body.exploring-providers #provider-list .provider-choice .provider-enter .card-img-wrapper {
    width: 100%;
    height: auto;
    aspect-ratio: 16 / 10;
    margin: 0 0 20px;
    padding: 16px;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    background: #fff;
    box-shadow: 0 1px 2px rgba(15, 23, 42, .05);
    transition: transform 200ms ease;
}
body.exploring-providers #provider-list .provider-choice:hover .card-img-wrapper { transform: scale(1.01); }
body.exploring-providers #provider-list .provider-choice .provider-enter .card-img-wrapper:has(img[src*="logo_moncarnes"]) { padding: 0; border-color: transparent; background: #00956f; }
body.exploring-providers #provider-list .provider-choice .provider-enter .card-img-wrapper:has(img[src*="logo_eiriz"], img[src*="marketplace-eiriz"]) { padding: 0; border-color: transparent; background: #111; }
body.exploring-providers #provider-list .provider-choice .provider-enter img { object-fit: contain; }
/* El logo de Eiriz es un cuadrado negro con las esquinas blancas: llenando el 16:10 se recortan.
   !important porque logoProveedorHtml escribe object-fit: contain en línea. */
body.exploring-providers #provider-list .provider-choice .provider-enter img[src*="logo_eiriz"],
body.exploring-providers #provider-list .provider-choice .provider-enter img[src*="marketplace-eiriz"] { object-fit: cover !important; }
body.exploring-providers #provider-list .provider-nombre { display: flex; align-items: flex-start; justify-content: space-between; gap: 4px; margin-bottom: 8px; }
body.exploring-providers #provider-list .provider-choice .card-name {
    display: -webkit-box;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
    overflow: hidden;
    min-height: 0;
    margin: 0;
    color: #0b1c30;
    font-size: 20px;
    font-weight: 700;
    line-height: 28px;
    letter-spacing: -.015em;
    text-align: left;
    overflow-wrap: anywhere;
    transition: color 150ms ease;
}
body.exploring-providers #provider-list .provider-choice:hover .card-name { color: #0050cb; }
body.exploring-providers #provider-list .provider-verificado { flex: none; width: 18px; height: 18px; margin-top: 5px; color: #0050cb; }
body.exploring-providers #provider-list .provider-lugar { display: flex; align-items: center; gap: 6px; color: #565e74; font-size: 13px; font-weight: 400; line-height: 18px; }
body.exploring-providers #provider-list .provider-lugar svg { flex: none; width: 16px; height: 16px; }
body.exploring-providers #provider-list .provider-datos {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    margin-top: 12px;
    padding: 12px 0 4px;
    border-top: 1px solid #e2e8f0;
    color: #565e74;
    font-size: 13px;
    line-height: 18px;
}
body.exploring-providers #provider-list .provider-portes { display: flex; align-items: center; gap: 4px; }
body.exploring-providers #provider-list .provider-portes svg { flex: none; width: 16px; height: 16px; color: #006645; }
body.exploring-providers #provider-list .provider-portes.sin-dato { color: #64748b; }
body.exploring-providers #provider-list .provider-portes.sin-dato svg { color: #cbd5e1; }
body.exploring-providers #provider-list .provider-minimo { flex: none; color: #0b1c30; font-size: 14px; font-weight: 700; letter-spacing: -.01em; }
body.exploring-providers #provider-list .provider-pie { display: flex; flex-direction: column; gap: 8px; margin-top: auto; padding-top: 20px; }
body.exploring-providers #provider-list .provider-ver {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    width: 100%;
    min-height: 44px;
    padding: 10px 16px;
    border: 0;
    border-radius: 12px;
    background: #0066ff;
    box-shadow: 0 1px 2px rgba(15, 23, 42, .05);
    color: #fff;
    font-size: 16px;
    font-weight: 600;
    line-height: 22px;
    letter-spacing: -.01em;
    cursor: pointer;
    transition: background 150ms ease, transform 150ms ease;
}
body.exploring-providers #provider-list .provider-ver svg { width: 18px; height: 18px; transition: transform 150ms ease; }
body.exploring-providers #provider-list .provider-ver:hover { background: #0050cb; }
body.exploring-providers #provider-list .provider-ver:hover svg { transform: translateX(2px); }
body.exploring-providers #provider-list .provider-ver:active { transform: scale(.98); }
body.exploring-providers #provider-list .provider-ficha {
    min-height: 32px;
    padding: 6px 8px;
    border: 0;
    background: none;
    color: #565e74;
    font-size: 13px;
    line-height: 18px;
    cursor: pointer;
}
body.exploring-providers #provider-list .provider-ficha:hover { color: #0050cb; }
}
/* En el móvil, iconos de app como antes (alex, 01/11): mandan las reglas de
   icono de más arriba y se quitan las piezas que solo lleva la tarjeta. */
@media (max-width: 639px) {
    body.exploring-providers #provider-list .provider-top,
    body.exploring-providers #provider-list .provider-nombre { display: contents; }
    body.exploring-providers #provider-list .provider-lugar,
    body.exploring-providers #provider-list .provider-verificado,
    body.exploring-providers #provider-list .provider-datos,
    body.exploring-providers #provider-list .provider-pie { display: none; }
}
@media (min-width: 640px) {
    body.exploring-providers #provider-list:has(.provider-choice) { width: calc(100% - 48px); grid-template-columns: repeat(2, minmax(0, 1fr)); }
    body.exploring-providers #provider-list .provider-choice { padding: 24px; border-radius: 24px; }
    body.exploring-providers #provider-list .provider-choice .provider-enter .card-img-wrapper { border-radius: 16px; }
}
@media (min-width: 1024px) {
    body.exploring-providers #provider-list:has(.provider-choice) { width: calc(100% - 64px); grid-template-columns: repeat(4, minmax(0, 1fr)); }
}
@media (min-width: 1280px) {
    body.exploring-providers #provider-list:has(.provider-choice) { gap: 28px; }
    /* En pantalla grande, el ancho del diseño (1280 con 48 de margen): tarjetas
       de unos 275 px en vez de 235 y sin tanto blanco a los lados. */
    body.exploring-providers .provider-explorer-content:has(#provider-list .provider-choice) { max-width: 1184px; }
    body.exploring-providers #provider-list:has(.provider-choice) { width: 100%; max-width: none; }
    body.exploring-providers .provider-explorer-content:has(#provider-list .provider-choice) .provider-heading { max-width: none; }
}


/* La cabecera del directorio como el diseño: contador en pastilla y la
   ubicación y Favoritos como pastillas blancas. */
body.exploring-providers #provider-results { background: #dce9ff; color: #0050cb; }
body.exploring-providers #provider-modal #provider-zone,
body.exploring-providers #provider-modal .provider-tools label {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    min-height: 34px;
    padding: 6px 14px;
    border: 1px solid #e2e8f0;
    border-radius: 999px;
    background: #fff;
    box-shadow: 0 1px 2px rgba(15, 23, 42, .05);
    color: #0b1c30;
    font-size: 13px;
    font-weight: 500;
}
body.exploring-providers #provider-modal #provider-zone:empty { display: none; }
body.exploring-providers #provider-modal .provider-tools label:hover { border-color: #cbd5e1; }
body.exploring-providers #cp-publico-cambiar { font-size: 13px; }

/* El alfiler de la ubicación, dibujado y en azul como en las tarjetas (no el emoji). */
body.exploring-providers #provider-modal #provider-zone.con-lugar::before {
    content: '';
    flex: none;
    width: 15px;
    height: 15px;
    background: #0066ff;
    -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M12 2a7 7 0 0 0-7 7c0 5.25 7 13 7 13s7-7.75 7-13a7 7 0 0 0-7-7zm0 9.5A2.5 2.5 0 1 1 12 6.5a2.5 2.5 0 0 1 0 5z'/%3E%3C/svg%3E") center / contain no-repeat;
            mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M12 2a7 7 0 0 0-7 7c0 5.25 7 13 7 13s7-7.75 7-13a7 7 0 0 0-7-7zm0 9.5A2.5 2.5 0 1 1 12 6.5a2.5 2.5 0 0 1 0 5z'/%3E%3C/svg%3E") center / contain no-repeat;
}

/* Producto sin foto (01/11): el logo del proveedor, pequeño y suave, como
   marcador; no a todo el recuadro como si fuera la foto del producto. */
.product-card .card-img-wrapper.sin-foto { background: #f8fafc; }
.product-card .card-img-wrapper.sin-foto img {
    width: 52% !important;
    height: 52% !important;
    margin: auto;
    object-fit: contain;
    opacity: .4;
    filter: grayscale(.35);
}

/* «Entrar» y «Regístrate» al final de la cabecera en todas las vistas, como en el
   directorio y en el móvil; en Pedidos, Buscar o Favoritos seguían pegados al logo (07/11). */
@media (min-width: 768px) {
    body .main-header .btn-header-register { order: 5; margin-left: 12px; }
}

/* ── Ficha del proveedor: diseño de alex (01/11) ─────────────────────────── */
:is(#info-proveedor-modal, #empresa-proveedor-modal).modal-overlay {
    /* Por encima de la barra de abajo (6000), como la ficha de producto (6500). */
    z-index: 6500;
    background: radial-gradient(circle at center, rgba(15, 23, 42, .45) 0%, rgba(15, 23, 42, .65) 100%);
    -webkit-backdrop-filter: blur(12px);
    backdrop-filter: blur(12px);
}
:is(#info-proveedor-modal, #empresa-proveedor-modal) .modal-wrapper.ficha-prov {
    width: min(540px, calc(100vw - 24px));
    height: auto;
    max-width: 540px;
    max-height: 90dvh;
    padding: 0;
    overflow: hidden auto;
    border: 1px solid rgba(241, 245, 249, .8);
    border-radius: 32px;
    background: #fff;
    box-shadow: 0 25px 60px -15px rgba(0, 0, 0, .25);
    text-align: left;
    font-family: 'Plus Jakarta Sans', system-ui, sans-serif;
}
.ficha-prov-barra {
    position: sticky;
    top: 0;
    z-index: 2;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 20px 24px 16px;
    border-bottom: 1px solid #f1f5f9;
    background: linear-gradient(to bottom, rgba(248, 250, 252, .95), rgba(255, 255, 255, .95));
}
.ficha-prov-sello {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 4px 12px;
    border: 1px solid #dbeafe;
    border-radius: 999px;
    background: #eff6ff;
    color: #0066ff;
    font-size: 12px;
    font-weight: 700;
}
.ficha-prov-sello[hidden] { display: none; }
.ficha-prov-sello svg { width: 16px; height: 16px; }
:is(#info-proveedor-modal, #empresa-proveedor-modal) .ficha-prov-cerrar {
    position: static;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    margin-left: auto;
    padding: 0;
    border: 0;
    border-radius: 50%;
    background: #f1f5f9;
    color: #64748b;
    cursor: pointer;
    transition: background 150ms ease, color 150ms ease, transform 150ms ease;
}
:is(#info-proveedor-modal, #empresa-proveedor-modal) .ficha-prov-cerrar:hover { background: #e2e8f0; color: #1e293b; }
:is(#info-proveedor-modal, #empresa-proveedor-modal) .ficha-prov-cerrar:active { transform: scale(.95); }
:is(#info-proveedor-modal, #empresa-proveedor-modal) .ficha-prov-cerrar svg { width: 18px; height: 18px; }
.ficha-prov-cuerpo { display: flex; flex-direction: column; gap: 24px; padding: 20px 24px 24px; }
.ficha-prov-hero { display: flex; flex-direction: column; align-items: center; text-align: center; }
.ficha-prov-logo {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 112px;
    height: 112px;
    margin-bottom: 12px;
    padding: 12px;
    overflow: hidden;
    border: 2px solid #fff;
    border-radius: 24px;
    background: #fff;
    box-shadow: 0 10px 24px -6px rgba(15, 23, 42, .18), 0 0 0 1px #e2e8f0;
}
.ficha-prov-logo img { width: 100% !important; height: 100% !important; object-fit: contain; }
.ficha-prov-logo[data-tono="moncarnes"] { padding: 0; background: #00956f; box-shadow: 0 10px 24px -6px rgba(0, 149, 111, .35); }
.ficha-prov-logo[data-tono="eiriz"] { padding: 0; background: #000; box-shadow: 0 10px 24px -6px rgba(0, 0, 0, .35); }
.ficha-prov-logo[data-tono="eiriz"] img { object-fit: cover !important; }
:is(#info-proveedor-modal, #empresa-proveedor-modal) .ficha-prov-nombre {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    margin: 8px 0 0;
    color: #0f172a;
    font-size: 26px;
    font-weight: 800;
    line-height: 32px;
    letter-spacing: -.02em;
}
.ficha-prov-insignia { flex: none; width: 24px; height: 24px; color: #0066ff; }
:is(#info-proveedor-modal, #empresa-proveedor-modal) .ficha-prov-desc { max-width: 380px; margin: 6px 0 0; color: #475569; font-size: 15px; font-weight: 500; line-height: 22px; }
.ficha-prov-chip {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    margin-top: 12px;
    padding: 4px 10px;
    border-radius: 8px;
    background: #f1f5f9;
    color: #475569;
    font-size: 12px;
    font-weight: 600;
}
.ficha-prov-chip[hidden] { display: none; }
.ficha-prov-chip svg { width: 14px; height: 14px; color: #0066ff; }

/* Condiciones para tu local */
:is(#info-proveedor-modal, #empresa-proveedor-modal) .storefront-conditions-detail.ficha-prov-condiciones {
    display: flex;
    flex-direction: column;
    gap: 14px;
    margin: 0;
    padding: 18px;
    border: 1px solid rgba(226, 232, 240, .8);
    border-radius: 16px;
    background: rgba(248, 250, 252, .9);
}
:is(#info-proveedor-modal, #empresa-proveedor-modal) .ficha-prov-condiciones[hidden] { display: none !important; }
.fpc-cab { display: flex; align-items: center; gap: 10px; padding-bottom: 10px; border-bottom: 1px solid rgba(226, 232, 240, .6); }
.fpc-icono { display: flex; flex: none; align-items: center; justify-content: center; width: 30px; height: 30px; border-radius: 8px; background: rgba(219, 234, 254, .7); color: #0066ff; }
.fpc-icono svg { width: 17px; height: 17px; }
.fpc-quien { flex: 1; min-width: 0; }
:is(#info-proveedor-modal, #empresa-proveedor-modal) .fpc-sub { margin: 0; color: #64748b; font-size: 12px; font-weight: 600; line-height: 14px; letter-spacing: .05em; text-transform: uppercase; }
:is(#info-proveedor-modal, #empresa-proveedor-modal) .ficha-prov-condiciones h2 { margin: 1px 0 0; color: #0f172a; font-size: 14px; font-weight: 700; line-height: 18px; }
.fpc-cp { flex: none; padding: 2px 8px; border: 1px solid #e2e8f0; border-radius: 6px; background: #fff; color: #64748b; font-size: 12px; font-weight: 700; }
:is(#info-proveedor-modal, #empresa-proveedor-modal) .fpc-aviso { margin: 0; color: #64748b; font-size: 13px; line-height: 18px; }
.fpc-metricas { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.fpc-metrica { display: flex; flex-direction: column; gap: 6px; padding: 12px; border: 1px solid #f1f5f9; border-radius: 12px; background: #fff; box-shadow: 0 1px 2px rgba(15, 23, 42, .05); }
.fpc-et { display: flex; align-items: center; gap: 6px; color: #64748b; font-size: 12px; font-weight: 600; }
.fpc-et svg { width: 15px; height: 15px; color: #64748b; }
.fpc-metrica strong { color: #0f172a; font-size: 17px; font-weight: 700; line-height: 22px; }
.fpc-verde { color: #059669; font-size: 12px; font-weight: 600; }

/* Contacto */
.ficha-prov-contacto { overflow: hidden; border: 1px solid #e2e8f0; border-radius: 16px; background: #fff; box-shadow: 0 1px 2px rgba(15, 23, 42, .05); }
.ficha-prov-fila { display: flex; align-items: center; gap: 12px; padding: 12px 14px; }
.ficha-prov-fila + .ficha-prov-fila { border-top: 1px solid #f1f5f9; }
.ficha-prov-icono {
    display: flex;
    flex: none;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    border-radius: 12px;
    background: #eff6ff;
    color: #0066ff;
    text-decoration: none;
}
.ficha-prov-icono svg { width: 20px; height: 20px; }
.ficha-prov-icono.es-apagado { background: #f1f5f9; color: #64748b; pointer-events: none; }
.ficha-prov-texto { display: flex; flex-direction: column; min-width: 0; }
.ficha-prov-etiqueta { color: #64748b; font-size: 12px; font-weight: 600; }
:is(#info-proveedor-modal, #empresa-proveedor-modal) .ficha-prov-valor { color: #1e293b; font-size: 14px; font-weight: 700; overflow-wrap: anywhere; }
:is(#info-proveedor-modal, #empresa-proveedor-modal) .ficha-prov-enlace { color: #0066ff; text-decoration: none; }
:is(#info-proveedor-modal, #empresa-proveedor-modal) .ficha-prov-valor.es-pastilla {
    align-self: flex-start;
    margin-top: 2px;
    padding: 1px 8px;
    border: 1px solid #fde68a;
    border-radius: 999px;
    background: #fffbeb;
    color: #b45309;
    font-size: 12px;
    font-weight: 600;
}

/* Acciones */
.ficha-prov-acciones { display: flex; flex-direction: column; gap: 10px; }
.ficha-prov-ver,
:is(#info-proveedor-modal, #empresa-proveedor-modal) .ficha-prov-chat {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    width: 100%;
    min-height: 50px;
    margin: 0;
    padding: 0 16px;
    border: 0;
    border-radius: 16px;
    font-family: inherit;
    font-size: 15px;
    font-weight: 700;
    cursor: pointer;
    transition: background 150ms ease, transform 150ms ease;
}
.ficha-prov-ver { background: #0066ff; box-shadow: 0 10px 15px -3px rgba(59, 130, 246, .25); color: #fff; }
.ficha-prov-ver:hover { background: #0052cc; }
:is(#info-proveedor-modal, #empresa-proveedor-modal) .ficha-prov-chat { background: #0f172a; box-shadow: 0 4px 6px -1px rgba(15, 23, 42, .15); color: #fff; }
:is(#info-proveedor-modal, #empresa-proveedor-modal) .ficha-prov-chat:hover { background: #1e293b; }
.ficha-prov-ver:active,
:is(#info-proveedor-modal, #empresa-proveedor-modal) .ficha-prov-chat:active { transform: scale(.99); }
.ficha-prov-ver svg,
:is(#info-proveedor-modal, #empresa-proveedor-modal) .ficha-prov-chat svg { flex: none; width: 18px; height: 18px; }
:is(#info-proveedor-modal, #empresa-proveedor-modal) .info-prov-mapa,
:is(#info-proveedor-modal, #empresa-proveedor-modal) .info-prov-resenas { margin: 0; }
@media (max-width: 480px) {
    :is(#info-proveedor-modal, #empresa-proveedor-modal) .modal-wrapper.ficha-prov { border-radius: 24px; }
    .ficha-prov-barra { padding: 16px 18px 12px; }
    .ficha-prov-cuerpo { gap: 20px; padding: 16px 18px 20px; }
    .ficha-prov-logo { width: 96px; height: 96px; }
    :is(#info-proveedor-modal, #empresa-proveedor-modal) .ficha-prov-nombre { font-size: 22px; line-height: 28px; }
    .fpc-metricas { gap: 8px; }
    .fpc-metrica strong { font-size: 15px; }
}

/* «Ver información» (01/11): los bloques de datos de la empresa. */
.empresa-prov-bloque { display: flex; flex-direction: column; gap: 8px; }
.empresa-prov-bloque[hidden] { display: none; }
#empresa-proveedor-modal .empresa-prov-bloque h2 { margin: 0; color: #64748b; font-size: 12px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; }
#empresa-proveedor-modal .empresa-prov-bloque p { margin: 0; color: #334155; font-size: 15px; line-height: 23px; }
#empresa-proveedor-modal .empresa-prov-nota { color: #64748b !important; font-size: 13px !important; }
.empresa-prov-mapa { overflow: hidden; border: 1px solid #e2e8f0; border-radius: 16px; }
.empresa-prov-mapa[hidden] { display: none; }
.empresa-prov-mapa .cp-mapa-lienzo { height: 220px; }
.empresa-prov-web {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    min-height: 48px;
    border: 1px solid #e2e8f0;
    border-radius: 16px;
    color: #0066ff;
    font-size: 15px;
    font-weight: 700;
    text-decoration: none;
}
.empresa-prov-web[hidden] { display: none; }
.empresa-prov-web:hover { background: #eff6ff; }
.empresa-prov-web svg { width: 18px; height: 18px; }

/* «Ver ficha» (azul) y «Ver información» (verde), en color y con icono, uno al
   lado del otro bajo «Ver catálogo»; si no caben, uno debajo del otro. */
body.exploring-providers #provider-list .provider-enlaces { display: flex; flex-wrap: wrap; gap: 6px; }
body.exploring-providers #provider-list .provider-enlaces .provider-ficha {
    display: inline-flex;
    flex: 1 1 auto;
    align-items: center;
    justify-content: center;
    gap: 5px;
    min-height: 36px;
    padding: 6px 8px;
    border-radius: 10px;
    font-size: 12.5px;
    font-weight: 600;
    white-space: nowrap;
    transition: background 150ms ease, color 150ms ease;
}
body.exploring-providers #provider-list .provider-enlaces .provider-ficha svg,
body.exploring-providers #provider-list .provider-options .provider-actions :is(.es-ficha, .es-empresa) svg { width: 15px; height: 15px; flex-shrink: 0; }
body.exploring-providers #provider-list .provider-ficha.es-ficha,
body.exploring-providers #provider-list .provider-options .provider-actions button.es-ficha { background: #dce9ff; color: #0050cb; }
body.exploring-providers #provider-list .provider-ficha.es-ficha:hover,
body.exploring-providers #provider-list .provider-options .provider-actions button.es-ficha:hover { background: #c6dbff; color: #003f9e; }
body.exploring-providers #provider-list .provider-ficha.es-empresa,
body.exploring-providers #provider-list .provider-options .provider-actions button.es-empresa { background: #d3f0e4; color: #00795c; }
body.exploring-providers #provider-list .provider-ficha.es-empresa:hover,
body.exploring-providers #provider-list .provider-options .provider-actions button.es-empresa:hover { background: #bce8d6; color: #005c46; }
body.exploring-providers #provider-list .provider-options .provider-actions button:is(.es-ficha, .es-empresa) + button:is(.es-ficha, .es-empresa) { margin-top: 4px; }

/* ── Directorio con el diseño de alex (02/11) ──────────────────────────────
   Tarjeta más compacta que se eleva al pasar el ratón, la especialidad en una
   línea, «Ver ficha» y «Ver información» en tonos claros, la ubicación como
   una sola pastilla con flecha y Favoritos con estrella. Los reclamos del
   diseño sin dato detrás (cadena de frío, soporte 24 h, «sin comisiones»…) no
   se ponen. */
body.exploring-providers .provider-tools .provider-estrella { flex: none; width: 15px; height: 15px; color: #f59e0b; }
body.exploring-providers #provider-modal #provider-zone.es-cambiable { cursor: pointer; }
body.exploring-providers #provider-modal #provider-zone.es-cambiable:hover { border-color: #cbd5e1; background: #f8fafc; }
/* La flecha va pegada a la pastilla; el texto «Cambiar ubicación» queda para los lectores de pantalla. */
body.exploring-providers .provider-heading-context:has(#cp-publico-cambiar:not([hidden])) #provider-zone {
    padding-right: 40px;
}
body.exploring-providers #provider-modal #cp-publico-cambiar:not([hidden]) {
    position: relative;
    width: 44px;
    min-height: 34px;
    margin-left: -56px;
    padding: 0;
    overflow: hidden;
    color: transparent;
    font-size: 0;
}
body.exploring-providers #provider-modal #cp-publico-cambiar:not([hidden])::after {
    content: '';
    position: absolute;
    inset: 0;
    margin: auto;
    width: 14px;
    height: 14px;
    background: #94a3b8;
    -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M19 9l-7 7-7-7'/%3E%3C/svg%3E") center / contain no-repeat;
            mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M19 9l-7 7-7-7'/%3E%3C/svg%3E") center / contain no-repeat;
}
body.exploring-providers #provider-modal #cp-publico-cambiar:not([hidden]):hover::after { background: #475569; }

@media (min-width: 640px) {
    body.exploring-providers #provider-list .provider-choice {
        /* Sin el wrap heredado de la tarjeta de producto: con él, la línea se ensanchaba con el texto más largo. */
        flex-wrap: nowrap;
        padding: 20px;
        border: 1px solid rgba(226, 232, 240, .9);
        border-radius: 16px;
        box-shadow: 0 2px 10px rgba(15, 23, 42, .04), 0 1px 3px rgba(15, 23, 42, .02);
        transition: transform 200ms ease, box-shadow 200ms ease, border-color 200ms ease;
    }
    body.exploring-providers #provider-list .provider-choice:hover {
        border-color: rgba(226, 232, 240, .9);
        box-shadow: 0 12px 28px -6px rgba(0, 102, 255, .12), 0 8px 16px -4px rgba(15, 23, 42, .06);
        transform: translateY(-4px);
    }
    body.exploring-providers #provider-list .provider-choice:hover .card-img-wrapper { transform: none; }
    body.exploring-providers #provider-list .provider-choice .provider-enter .card-img-wrapper {
        aspect-ratio: auto;
        height: 128px;
        margin-bottom: 16px;
        border-radius: 12px;
    }
    body.exploring-providers #provider-list .provider-choice .card-name { font-size: 18px; line-height: 26px; }
    body.exploring-providers #provider-list .provider-choice .provider-options > summary {
        width: 32px;
        height: 32px;
        margin: 0;
        border: 1px solid #e2e8f0;
        color: #64748b;
    }
    body.exploring-providers #provider-list .provider-choice .provider-options > summary:hover,
    body.exploring-providers #provider-list .provider-choice .provider-options[open] > summary {
        border-color: rgba(0, 102, 255, .3);
        background: #eff6ff;
        color: #0066ff;
    }
    body.exploring-providers #provider-list .provider-choice .provider-options > summary svg { width: 16px; height: 16px; }
    body.exploring-providers #provider-list .provider-choice .provider-favorite { width: 40px; height: 40px; margin: 0; color: #64748b; }
    body.exploring-providers #provider-list .provider-choice .provider-favorite:hover { background: #fff1f2; color: #f43f5e; }

    /* Que una presentación larga se corte con «…» en vez de ensanchar la tarjeta. */
    body.exploring-providers #provider-list .provider-choice > .provider-datos,
    body.exploring-providers #provider-list .provider-choice > .provider-pie { align-self: stretch; width: auto; min-width: 0; }
    /* Especialidad arriba y condiciones debajo, separadas del nombre por la raya. */
    body.exploring-providers #provider-list .provider-datos {
        flex-direction: column;
        align-items: stretch;
        gap: 6px;
        padding-top: 10px;
        border-top-color: #f1f5f9;
        font-size: 12px;
        line-height: 16px;
    }
    body.exploring-providers #provider-list .provider-especialidad {
        display: flex;
        align-items: center;
        gap: 6px;
        min-width: 0;
        overflow: hidden;
        color: #475569;
        font-weight: 500;
    }
    body.exploring-providers #provider-list .provider-especialidad span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
    body.exploring-providers #provider-list .provider-especialidad svg { flex: none; width: 14px; height: 14px; color: #0066ff; }
    body.exploring-providers #provider-list .provider-condiciones { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
    body.exploring-providers #provider-list .provider-portes svg { width: 14px; height: 14px; color: #10b981; }
    body.exploring-providers #provider-list .provider-portes:not(.sin-dato) { color: #059669; font-weight: 600; }
    body.exploring-providers #provider-list .provider-minimo { font-size: 12px; }
    body.exploring-providers #provider-list .provider-pie { padding-top: 16px; }

    /* Los dos botones del pie a partes iguales; si no caben, uno debajo del otro. */
    body.exploring-providers #provider-list .provider-enlaces { gap: 8px; }
    body.exploring-providers #provider-list .provider-enlaces .provider-ficha {
        flex: 1 1 0;
        min-width: max-content;
        min-height: 40px;   /* 32 px se quedaba corto para el dedo (05/11) */
        padding: 6px 8px;
        border-radius: 8px;
        font-size: 13px;
    }
    body.exploring-providers #provider-list .provider-enlaces .provider-ficha svg { width: 14px; height: 14px; }
    body.exploring-providers #provider-list .provider-ficha.es-ficha { background: #eff6ff; color: #0052cc; }
    body.exploring-providers #provider-list .provider-ficha.es-ficha:hover { background: #dbeafe; color: #0052cc; }
    body.exploring-providers #provider-list .provider-ficha.es-empresa { background: #ecfdf5; color: #047857; }
    body.exploring-providers #provider-list .provider-ficha.es-empresa:hover { background: #d1fae5; color: #065f46; }
}
@media (prefers-reduced-motion: reduce) {
    body.exploring-providers #provider-list .provider-choice:hover { transform: none; }
}
