/* Atelier Prisma: utiliza las variables de identidad y los controles existentes de la tienda. */
body[data-storefront-template="master_05"] {
    --m5-header-offset: calc(var(--store-custom-logo-size, 52px) + 95px);
    background: var(--store-custom-bg);
}


body[data-storefront-template="master_05"] header { background: var(--store-custom-bg); }
body[data-storefront-template="master_05"] .container.nav {
    border: 1px solid var(--store-custom-border);
    border-radius: 999px;
    background: var(--store-custom-surface);
    box-shadow: none;
}
body[data-storefront-template="master_05"] .mark:not(.has-logo) {
    border-radius: 50%;
    color: var(--store-custom-hero-text);
    background: var(--orange);
}
body[data-storefront-template="master_05"] .hero {
    display: grid;
    grid-template-columns: minmax(0, .9fr) minmax(0, 1.1fr);
    align-items: stretch;
    gap: clamp(14px, 2vw, 28px);
    padding-top: 24px;
}
body[data-storefront-template="master_05"][data-store-hero="equilibrada"] .hero { grid-template-columns: repeat(2, minmax(0, 1fr)); }
body[data-storefront-template="master_05"] .hero-copy {
    min-width: 0;
    min-height: var(--store-custom-hero-height);
    padding: clamp(28px, 4vw, 54px);
    border-radius: var(--store-custom-radius);
    background: var(--orange);
    color: var(--store-custom-hero-text);
    box-shadow: none;
}
body[data-storefront-template="master_05"] .hero-copy h1 {
    max-width: 15ch;
    color: var(--store-custom-hero-text);
    font-size: clamp(2.1rem, 4vw, 4.2rem);
    line-height: 1.06;
    letter-spacing: -.035em;
}
body[data-storefront-template="master_05"] .hero-copy > p { color: var(--store-custom-hero-muted); text-align: left; }
body[data-storefront-template="master_05"][data-store-hero-align="centrada"] .hero-copy > p { text-align: center; }
body[data-storefront-template="master_05"] .hero-photo {
    min-width: 0;
    min-height: var(--store-custom-hero-height);
    height: var(--store-custom-hero-height);
    border-radius: 46% 46% var(--store-custom-radius) var(--store-custom-radius);
    background: var(--store-custom-surface);
}
body[data-storefront-template="master_05"] .hero-photo > img { height: 100%; min-height: 0; }
body[data-storefront-template="master_05"] .hero-photo .local {
    left: auto;
    width: min(74%, 310px);
    grid-template-columns: minmax(0, 1fr);
}
body[data-storefront-template="master_05"] .hero-photo .local .local-state { grid-column: auto; grid-row: auto; justify-self: start; }
body[data-storefront-template="master_05"] .hero-actions .btn,
body[data-storefront-template="master_05"] .card-actions .btn { letter-spacing: .02em; box-shadow: none; }
body[data-storefront-template="master_05"] section.container { scroll-margin-top: var(--m5-header-offset); }
body[data-storefront-template="master_05"] .section-head { align-items: end; border-bottom: 1px solid var(--store-custom-border); padding-bottom: 20px; }
body[data-storefront-template="master_05"] .section-head h2 { letter-spacing: -.03em; }
body[data-storefront-template="master_05"] .card { overflow: hidden; border-radius: var(--store-custom-radius); background: var(--store-custom-surface); }
body[data-storefront-template="master_05"] .card .photo { border-radius: 0 0 34% 0; }
body[data-storefront-template="master_05"] .catalog-filters { box-shadow: none; }
body[data-storefront-template="master_05"] .footer { border-top: 1px solid var(--store-custom-border); }
@media (max-width: 860px) {
    body[data-storefront-template="master_05"] { --m5-header-offset: calc(var(--store-custom-logo-size, 52px) + 150px); }
    body[data-storefront-template="master_05"] .container.nav { border-radius: var(--store-custom-radius); }
    body[data-storefront-template="master_05"] .hero,
    body[data-storefront-template="master_05"][data-store-hero="equilibrada"] .hero { grid-template-columns: minmax(0, 1fr); }
    body[data-storefront-template="master_05"][data-store-hero] .hero-copy { order: 1; min-height: 0; }
    body[data-storefront-template="master_05"][data-store-hero] .hero-photo { order: 2; height: 340px; min-height: 0; }
    body[data-storefront-template="master_05"] .hero-photo > img { min-height: 0; }
}
@media (max-width: 600px) {
    body[data-storefront-template="master_05"] .hero { gap: 14px; padding-top: 12px; }
    body[data-storefront-template="master_05"] .hero-copy { padding: 28px 22px; }
    body[data-storefront-template="master_05"] .hero-photo .local { width: min(76%, 280px); }
    body[data-storefront-template="master_05"] .section-head { align-items: start; }
}

/* Atelier Prisma: imágenes enmarcadas y piezas de catálogo con ritmo suave. */
body[data-storefront-template="master_05"] .card .photo { margin: 10px 10px 0; border-radius: min(var(--store-custom-radius), 18px) min(var(--store-custom-radius), 18px) min(var(--store-custom-radius), 18px) 3px; }
body[data-storefront-template="master_05"] .card-body { padding: 19px 20px 24px; }
body[data-storefront-template="master_05"] .card h3 { letter-spacing: -.025em; }
body[data-storefront-template="master_05"] .section-head { border-bottom: 1px solid var(--store-custom-border); padding-bottom: 20px; }
body[data-storefront-template="master_05"] .catalog-filters { border-radius: var(--store-custom-radius); }

/* Atelier Prisma: composición editorial, aislada de las demás plantillas. */
body[data-storefront-template="master_05"] {
    --atelier-surface: var(--store-custom-surface);
    --atelier-alt: var(--store-custom-surface-alt);
    --atelier-ink: var(--store-custom-text);
    --atelier-muted: var(--store-custom-muted);
    --atelier-line: var(--store-custom-border);
    --m5-header-offset: calc(var(--store-custom-logo-size, 52px) + 155px);
}
body[data-storefront-template="master_05"] .container.nav {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 8px 16px;
    padding: 12px 20px 0;
    border-radius: var(--store-custom-radius);
}
body[data-storefront-template="master_05"] .nav .brand { grid-column: 1; grid-row: 1; }
body[data-storefront-template="master_05"] .nav .store-status { grid-column: 2; grid-row: 1; }
body[data-storefront-template="master_05"] .nav nav {
    grid-column: 1 / -1;
    grid-row: 2;
    width: 100%;
    justify-content: center;
    margin: 0;
    padding: 4px 0;
    border-top: 1px solid var(--atelier-line);
}
body[data-storefront-template="master_05"] .nav nav a { border-radius: 0; border-bottom: 2px solid transparent; }
body[data-storefront-template="master_05"] .nav nav a:hover,
body[data-storefront-template="master_05"] .nav nav a:focus-visible { border-bottom-color: currentColor; }
body[data-storefront-template="master_05"] .hero { grid-template-columns: minmax(0, 1fr) minmax(0, .93fr); gap: 0; }
body[data-storefront-template="master_05"] .hero-copy {
    position: relative;
    border: 1px solid var(--atelier-line);
    border-right: 0;
    border-radius: var(--store-custom-radius) 0 0 var(--store-custom-radius);
    padding: clamp(28px, 4vw, 60px);
}
body[data-storefront-template="master_05"] .hero-copy::before,
body[data-storefront-template="master_05"] .hero-copy::after { display: none; }
body[data-storefront-template="master_05"] .hero-copy h1 { max-width: 100%; font-size: clamp(2rem, 3.45vw, 3.6rem); line-height: 1.05; letter-spacing: -.045em; overflow-wrap: anywhere; }
body[data-storefront-template="master_05"] .hero-copy .eyebrow,
body[data-storefront-template="master_05"] .hero-copy .badges span { color: var(--store-custom-hero-text); }
body[data-storefront-template="master_05"] .hero-copy .badges span { background: transparent; border-color: color-mix(in srgb, var(--store-custom-hero-text) 45%, transparent); }
body[data-storefront-template="master_05"] .hero-photo { border-radius: 0 var(--store-custom-radius) var(--store-custom-radius) 0; }
body[data-storefront-template="master_05"][data-store-hero="imagen-izquierda"] .hero-copy { border-right: 1px solid var(--atelier-line); border-left: 0; border-radius: 0 var(--store-custom-radius) var(--store-custom-radius) 0; }
body[data-storefront-template="master_05"][data-store-hero="imagen-izquierda"] .hero-photo { border-radius: var(--store-custom-radius) 0 0 var(--store-custom-radius); }
body[data-storefront-template="master_05"] .hero-photo .local { border-radius: 0 var(--store-custom-radius) 0 var(--store-custom-radius); }
body[data-storefront-template="master_05"] .section-head { gap: 24px; border-bottom: 1px solid var(--atelier-line); padding-bottom: 18px; }
body[data-storefront-template="master_05"] .section-head .tag,
body[data-storefront-template="master_05"] .card .tag { color: var(--atelier-ink); }
body[data-storefront-template="master_05"] .section-head h2 { letter-spacing: -.04em; }
body[data-storefront-template="master_05"] .catalog-filters { border-radius: var(--store-custom-radius); box-shadow: none; }
body[data-storefront-template="master_05"] .card { border: 1px solid var(--atelier-line); box-shadow: none; }
body[data-storefront-template="master_05"] .card:hover { transform: translateY(-3px); box-shadow: 0 14px 30px #0002; }
body[data-storefront-template="master_05"] .card .photo { margin: 0; border-radius: 0; }
body[data-storefront-template="master_05"] .card .stock { color: var(--atelier-ink); background: var(--atelier-surface); border: 1px solid var(--atelier-line); }
body[data-storefront-template="master_05"] .card-body { padding: 22px; }
body[data-storefront-template="master_05"] .card-actions { padding-top: 12px; border-top: 1px solid var(--atelier-line); }
body[data-storefront-template="master_05"] #storeServiceGrid .card { border-top: 3px solid var(--atelier-line); }
body[data-storefront-template="master_05"] .contact-main { color: var(--atelier-ink); background: var(--atelier-surface); border: 1px solid var(--atelier-line); box-shadow: none; }
body[data-storefront-template="master_05"] .contact-main :is(h3, .eyebrow, .contact-main-social > strong),
body[data-storefront-template="master_05"] .contact-info-card strong { color: var(--atelier-ink); }
body[data-storefront-template="master_05"] .contact-main p { color: var(--atelier-muted); }
body[data-storefront-template="master_05"] .contact-main-social { border-color: var(--atelier-line); }
body[data-storefront-template="master_05"] .contact-info-card { box-shadow: none; }
body[data-storefront-template="master_05"] .footer { border-top: 1px solid var(--atelier-line); }
body[data-storefront-template="master_05"] .drawer-head { border-bottom: 1px solid var(--atelier-line); }
body[data-storefront-template="master_05"].drawer-visible .storefront-demo-banner { z-index: 48; }
body[data-storefront-template="master_05"] :is(a, button, input, select, textarea):focus-visible { outline: 3px solid var(--store-custom-link); outline-offset: 3px; }
@media (max-width: 860px) {
    body[data-storefront-template="master_05"] { --m5-header-offset: calc(var(--store-custom-logo-size, 52px) + 155px); }
    body[data-storefront-template="master_05"] .container.nav { grid-template-columns: minmax(0, 1fr); padding: 12px 14px 0; }
    body[data-storefront-template="master_05"] .nav .brand { grid-column: 1; grid-row: 1; }
    body[data-storefront-template="master_05"] .nav .store-status { grid-column: 1; grid-row: 2; justify-self: start; }
    body[data-storefront-template="master_05"] .nav nav { grid-column: 1; grid-row: 3; justify-content: flex-start; overflow-x: auto; }
    body[data-storefront-template="master_05"][data-store-hero] .hero { grid-template-columns: minmax(0, 1fr); gap: 0; }
    body[data-storefront-template="master_05"][data-store-hero] .hero-copy { border: 1px solid var(--atelier-line); border-bottom: 0; border-radius: var(--store-custom-radius) var(--store-custom-radius) 0 0; }
    body[data-storefront-template="master_05"][data-store-hero] .hero-photo { border-radius: 0 0 var(--store-custom-radius) var(--store-custom-radius); }
}
@media (max-width: 600px) {
    body[data-storefront-template="master_05"] .hero-copy h1 { font-size: clamp(1.8rem, 7.8vw, 2.3rem); }
    body[data-storefront-template="master_05"] .catalog-filters { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    body[data-storefront-template="master_05"] .catalog-filters label:first-child,
    body[data-storefront-template="master_05"] .catalog-filters .clear-filter { grid-column: 1 / -1; }
    body[data-storefront-template="master_05"] .catalog-filters label { min-width: 0; }
}
@media (prefers-reduced-motion: reduce) {
    body[data-storefront-template="master_05"] .card,
    body[data-storefront-template="master_05"] .card .photo img { transition: none; }
    body[data-storefront-template="master_05"] .card:hover { transform: none; }
}

/* Atelier Prisma: navegación de estudio y superficies editoriales. */
body[data-storefront-template="master_05"] {
    --m5-rail: clamp(190px, 15vw, 224px);
    --m5-visible-header: 0px;
    color: var(--store-custom-text);
    background: var(--store-custom-bg);
}
body[data-storefront-template="master_05"] > header {
    z-index: 50;
    background: var(--store-custom-surface);
}
body[data-storefront-template="master_05"] .container.nav {
    color: var(--store-custom-text);
    background: var(--store-custom-surface);
}
body[data-storefront-template="master_05"] .m5-menu-toggle { display: none; }
body[data-storefront-template="master_05"] .container.nav > nav :is(a, .nav-action) {
    color: var(--store-custom-text);
    border: 0;
    border-radius: min(var(--store-custom-radius), 12px);
    background: transparent;
    text-align: left;
}
body[data-storefront-template="master_05"] .container.nav > nav :is(a, .nav-action):is(:hover, :focus-visible),
body[data-storefront-template="master_05"] .container.nav > nav a[aria-current="location"] {
    color: var(--store-custom-button-secondary-text);
    background: var(--store-custom-button-secondary);
    box-shadow: inset 3px 0 var(--store-custom-button-secondary-text);
}
body[data-storefront-template="master_05"] .container.nav .nav-count {
    color: var(--store-custom-button-text);
    background: var(--store-custom-button);
}
@media (min-width: 1001px) {
    body[data-storefront-template="master_05"] { padding-left: var(--m5-rail); }
    body[data-storefront-template="master_05"] > header {
        position: fixed;
        inset: 0 auto 0 0;
        width: var(--m5-rail);
        padding: 24px 16px;
        border-right: 1px solid var(--store-custom-border);
        overflow-y: auto;
    }
    body[data-storefront-template="master_05"] .container.nav {
        display: flex;
        flex-direction: column;
        align-items: stretch;
        width: 100%;
        min-height: 100%;
        padding: 0;
        margin: 0;
        border: 0;
        border-radius: 0;
        box-shadow: none;
    }
    body[data-storefront-template="master_05"] .container.nav .brand {
        min-width: 0;
        align-items: flex-start;
        flex-direction: column;
        padding: 0 4px 24px;
        border-bottom: 1px solid var(--store-custom-border);
    }
    body[data-storefront-template="master_05"] .container.nav .brand > span:last-child { min-width: 0; overflow-wrap: anywhere; }
    body[data-storefront-template="master_05"] .container.nav .brand :is(strong, small) { max-width: 100%; white-space: normal; overflow: visible; text-overflow: clip; overflow-wrap: anywhere; }
    body[data-storefront-template="master_05"] .container.nav .store-status { align-self: flex-start; margin: 20px 0 18px; white-space: normal; }
    body[data-storefront-template="master_05"] .container.nav > nav {
        display: flex;
        flex-direction: column;
        align-items: stretch;
        justify-content: flex-start;
        gap: 5px;
        width: 100%;
        margin: 0;
        padding: 0;
        border: 0;
        overflow: visible;
    }
    body[data-storefront-template="master_05"] .container.nav > nav :is(a, .nav-action) {
        display: flex;
        align-items: center;
        width: 100%;
        min-height: 44px;
        margin: 0;
        padding: 10px 12px;
    }
    body[data-storefront-template="master_05"] .container.nav > nav .nav-action { margin-top: 12px; border: 1px solid var(--store-custom-border); }
}
body[data-storefront-template="master_05"] main > section.container { scroll-margin-top: calc(var(--m5-visible-header) + 12px); }
body[data-storefront-template="master_05"] #inicio { scroll-margin-top: var(--m5-visible-header); }
/* Give the selected section the available viewport without clipping long content. */
body[data-storefront-template="master_05"] main > section.container:target {
    min-height: max(0px, calc(100svh - var(--m5-visible-header) - 12px));
}
body[data-storefront-template="master_05"] .hero:target {
    min-height: max(0px, calc(100svh - var(--m5-visible-header)));
    align-content: center;
}
/* Keep the next section below the initial viewport before an anchor is selected. */
body[data-storefront-template="master_05"] .hero:not(:target) {
    min-height: max(0px, calc(100svh - var(--m5-visible-header)));
    align-content: start;
}
@media (min-width: 1001px) {
    /* The navigation occupies a side rail, so its anchors need no top clearance. */
    body[data-storefront-template="master_05"] main > section.container { scroll-margin-top: -28px; }
    body[data-storefront-template="master_05"] main > section.container:target { min-height: calc(100svh + 28px); }
}
body[data-storefront-template="master_05"] .hero {
    grid-template-columns: minmax(0, 1fr) minmax(0, 1.02fr);
    gap: clamp(16px, 2vw, 28px);
    padding-block: clamp(20px, 3vw, 36px);
}
body[data-storefront-template="master_05"][data-store-hero="equilibrada"] .hero { grid-template-columns: repeat(2, minmax(0, 1fr)); }
body[data-storefront-template="master_05"] .hero-copy {
    position: relative;
    justify-content: center;
    min-height: var(--store-custom-hero-height);
    padding: clamp(26px, 3.2vw, 52px);
    border: 1px solid var(--store-custom-border);
    border-radius: var(--store-custom-radius);
    background: var(--orange);
}
body[data-storefront-template="master_05"] .hero-copy .eyebrow { color: var(--store-custom-hero-text); }
body[data-storefront-template="master_05"] .hero-copy h1 { font-size: clamp(2.2rem, 3.5vw, 4.2rem); line-height: 1.05; }
body[data-storefront-template="master_05"] .hero-photo,
body[data-storefront-template="master_05"][data-store-hero="imagen-izquierda"] .hero-photo {
    min-height: var(--store-custom-hero-height);
    height: auto;
    border: 1px solid var(--store-custom-border);
    border-radius: var(--store-custom-radius);
    background: var(--store-custom-surface-alt);
}
body[data-storefront-template="master_05"] .hero-photo > img { height: 100%; min-height: 0; }
body[data-storefront-template="master_05"][data-store-hero="imagen-izquierda"] .hero-copy { border: 1px solid var(--store-custom-border); border-radius: var(--store-custom-radius); }
body[data-storefront-template="master_05"] .hero-photo .local { border-radius: var(--store-custom-radius); }
body[data-storefront-template="master_05"] .section-head { border-color: var(--store-custom-border); }
body[data-storefront-template="master_05"] .card { border-radius: var(--store-custom-radius); }
body[data-storefront-template="master_05"] .card .photo { aspect-ratio: var(--store-custom-image-ratio); }
body[data-storefront-template="master_05"][data-store-cards="elevadas"] .card { box-shadow: 0 12px 30px color-mix(in srgb, var(--store-custom-text) 10%, transparent); }
body[data-storefront-template="master_05"][data-store-cards="borde"] .card { border-width: 2px; box-shadow: none; }
body[data-storefront-template="master_05"][data-store-cards="planas"] .card { border-color: transparent; box-shadow: none; }
body[data-storefront-template="master_05"] .m5-catalog-toolbar {
    display: flex; align-items: center; flex-wrap: wrap; gap: 12px 16px;
    padding: 12px 16px; border: 1px solid var(--store-custom-border);
    border-radius: var(--store-custom-radius); background: var(--store-custom-surface);
}
body[data-storefront-template="master_05"] .m5-filter-summary { flex: 1 1 150px; min-width: 0; color: var(--store-custom-muted); font-size: .82rem; }
body[data-storefront-template="master_05"] .m5-filter-summary .catalog-results { margin: 0; color: var(--store-custom-text); font-weight: 800; }
body[data-storefront-template="master_05"] .m5-filter-summary > span { display: block; overflow-wrap: anywhere; }
body[data-storefront-template="master_05"] .m5-catalog-toolbar .catalog-pagination-top { margin: 0 0 0 auto; }
body[data-storefront-template="master_05"] .m5-filter-panel { margin-top: 10px; }
body[data-storefront-template="master_05"] .m5-filter-panel[hidden] { display: none !important; }
@media (min-width: 1001px) {
    body[data-storefront-template="master_05"][data-store-hero] .hero {
        grid-template-columns: minmax(0, 1fr);
        gap: 0;
        padding-block: clamp(10px, 1vw, 16px);
    }
    body[data-storefront-template="master_05"][data-store-hero] .hero { align-content: stretch; }
    body[data-storefront-template="master_05"][data-store-hero] .hero-copy {
        grid-area: 1 / 1;
        z-index: 2;
        align-self: center;
        justify-self: start;
        width: min(49%, 540px);
        min-height: 0;
        margin: clamp(18px, 2.5vw, 36px);
        padding: clamp(24px, 2.5vw, 38px);
    }
    body[data-storefront-template="master_05"][data-store-hero="imagen-izquierda"] .hero-copy { justify-self: end; }
    body[data-storefront-template="master_05"][data-store-hero] .hero-photo {
        position: relative;
        grid-area: 1 / 1;
        min-height: var(--store-custom-hero-height);
        height: 100%;
    }
    body[data-storefront-template="master_05"][data-store-hero] .hero-photo > img { position: absolute; inset: 0; width: 100%; height: 100%; }
    body[data-storefront-template="master_05"][data-store-hero="imagen-izquierda"] .hero-photo .local { left: 16px; right: auto; }
}
body[data-storefront-template="master_05"] .hero-copy { display: flex; flex-direction: column; }
body[data-storefront-template="master_05"] .hero-copy .eyebrow { order: 1; }
body[data-storefront-template="master_05"] .hero-copy h1 { order: 2; }
body[data-storefront-template="master_05"] .hero-copy > p { order: 3; }
body[data-storefront-template="master_05"] .hero-copy .hero-actions { order: 4; }
body[data-storefront-template="master_05"] .hero-copy .badges { order: 5; margin-top: 16px; }
@media (max-width: 1000px) {
    body[data-storefront-template="master_05"] > header { position: sticky; top: 0; z-index: 50; }
    body[data-storefront-template="master_05"] .container.nav {
        display: grid; position: relative; grid-template-columns: minmax(0, 1fr) auto;
        gap: 8px; width: min(var(--store-custom-width), calc(100% - 24px));
        min-height: 0; padding: 10px 12px; border: 1px solid var(--store-custom-border);
        border-radius: var(--store-custom-radius);
    }
    body[data-storefront-template="master_05"] .container.nav .brand { grid-column: 1; grid-row: 1; min-width: 0; }
    body[data-storefront-template="master_05"] .container.nav .brand > span:last-child { min-width: 0; }
    body[data-storefront-template="master_05"] .container.nav .brand :is(strong, small) { max-width: 100%; white-space: normal; overflow: visible; text-overflow: clip; overflow-wrap: anywhere; }
    body[data-storefront-template="master_05"] .container.nav .store-status { grid-column: 1 / -1; grid-row: 2; justify-self: start; }
    body[data-storefront-template="master_05"].m5-menu-ready .m5-menu-toggle {
        display: inline-flex; align-items: center; justify-content: center; grid-column: 2; grid-row: 1;
        min-height: 44px; padding: 0 16px; border: 1px solid var(--store-custom-border);
        border-radius: var(--store-custom-radius); color: var(--store-custom-button-secondary-text);
        background: var(--store-custom-button-secondary); font: inherit; font-weight: 800;
    }
    body[data-storefront-template="master_05"].m5-menu-ready .container.nav > nav { display: none; }
    body[data-storefront-template="master_05"].m5-menu-ready.m5-menu-open .container.nav > nav {
        display: flex; position: absolute; top: calc(100% + 6px); right: 0; left: 0;
        flex-direction: column; align-items: stretch; gap: 3px; width: auto; max-height: min(65vh, 440px);
        overflow-y: auto; padding: 10px; margin: 0; border: 1px solid var(--store-custom-border);
        border-radius: var(--store-custom-radius); background: var(--store-custom-surface);
        box-shadow: 0 14px 34px color-mix(in srgb, var(--store-custom-text) 16%, transparent);
    }
    body[data-storefront-template="master_05"].m5-menu-ready .container.nav > nav :is(a, .nav-action) { min-height: 44px; padding: 10px 12px; }
    body[data-storefront-template="master_05"][data-store-hero] .hero { grid-template-columns: minmax(0, 1fr); gap: 12px; }
    body[data-storefront-template="master_05"][data-store-hero] .hero-copy { order: 1; min-height: 0; border: 1px solid var(--store-custom-border); border-radius: var(--store-custom-radius); }
    body[data-storefront-template="master_05"][data-store-hero] .hero-photo { order: 2; min-height: clamp(220px, calc(var(--store-custom-hero-height) * .65), 370px); height: auto; border-radius: var(--store-custom-radius); }
    body[data-storefront-template="master_05"] .hero-photo > img { position: absolute; inset: 0; width: 100%; height: 100%; }
    body[data-storefront-template="master_05"] .m5-catalog-toolbar .catalog-pagination-top { flex: 1 1 100%; margin: 0; }
}
@media (max-width: 1000px) {
    body[data-storefront-template="master_05"][data-store-hero] .hero { gap: 0; }
    body[data-storefront-template="master_05"][data-store-hero] .hero-copy { border-radius: var(--store-custom-radius, 18px) var(--store-custom-radius, 18px) 0 0; }
    body[data-storefront-template="master_05"][data-store-hero] .hero-photo { border-radius: 0 0 var(--store-custom-radius, 18px) var(--store-custom-radius, 18px); }
}

/* Apply the selected non-default settings without changing the approved default. */
body[data-storefront-template="master_05"][data-store-density="compacta"] .card-body { padding: 15px; }
body[data-storefront-template="master_05"][data-store-density="aireada"] .card-body { padding: 24px; }
body[data-storefront-template="master_05"][data-store-cards="borde"] #storeServiceGrid .card { border-top-width: 2px; }
body[data-storefront-template="master_05"][data-store-cards="planas"] #storeServiceGrid .card { border-top-color: transparent; }

/* Compact mobile navigation, scoped to Atelier Prisma. */
@media (max-width: 1000px) {
    body[data-storefront-template="master_05"].m5-menu-ready .container.nav {
        gap: 10px 12px;
        padding: 12px 14px;
        box-shadow: 0 8px 24px color-mix(in srgb, var(--store-custom-text) 9%, transparent);
    }
    body[data-storefront-template="master_05"].m5-menu-ready .m5-menu-toggle {
        display: inline-flex;
        align-items: center;
        gap: 9px;
        min-height: 44px;
        padding: 0 15px;
        border-radius: min(var(--store-custom-radius), 14px);
    }
    body[data-storefront-template="master_05"] .m5-menu-icon {
        display: grid;
        align-content: center;
        gap: 4px;
        width: 18px;
        height: 20px;
    }
    body[data-storefront-template="master_05"] .m5-menu-icon span {
        display: block;
        width: 18px;
        height: 2px;
        border-radius: 2px;
        background: currentColor;
        transition: transform .2s ease, opacity .2s ease;
    }
    body[data-storefront-template="master_05"].m5-menu-open .m5-menu-icon span:first-child { transform: translateY(6px) rotate(45deg); }
    body[data-storefront-template="master_05"].m5-menu-open .m5-menu-icon span:nth-child(2) { opacity: 0; }
    body[data-storefront-template="master_05"].m5-menu-open .m5-menu-icon span:last-child { transform: translateY(-6px) rotate(-45deg); }
    body[data-storefront-template="master_05"] .m5-menu-toggle:focus-visible {
        outline: 3px solid var(--store-custom-link);
        outline-offset: 3px;
    }
    body[data-storefront-template="master_05"].m5-menu-ready.m5-menu-open .container.nav > nav {
        gap: 5px;
        max-height: min(65dvh, 440px);
        padding: 10px;
        overscroll-behavior: contain;
    }
    body[data-storefront-template="master_05"].m5-menu-ready .container.nav > nav :is(a, .nav-action) {
        display: flex;
        align-items: center;
        width: 100%;
        min-height: 46px;
        padding: 10px 14px;
        border-radius: min(var(--store-custom-radius), 12px);
    }
    body[data-storefront-template="master_05"].m5-menu-ready .container.nav > nav .nav-action {
        gap: 8px;
        margin-top: 5px;
        border: 1px solid var(--store-custom-border);
    }
    @media (prefers-reduced-motion: reduce) {
        body[data-storefront-template="master_05"] .m5-menu-icon span { transition: none; }
    }
}

/* Contact information stays readable while the map shares the desktop viewport. */
body[data-storefront-template="master_05"] #contacto .contact-info-card {
    min-width: 0;
    overflow-wrap: anywhere;
}
@media (min-width: 1100px) {
    body[data-storefront-template="master_05"] #contacto { padding-block: 30px; }
    body[data-storefront-template="master_05"] #contacto .section-head { margin-bottom: 18px; padding-bottom: 14px; }
    body[data-storefront-template="master_05"] #contacto .contact-layout:has(.contact-map) {
        grid-template-columns: minmax(235px, .6fr) minmax(0, 1.8fr);
    }
    body[data-storefront-template="master_05"] #contacto .contact-main { padding: clamp(24px, 2.2vw, 32px); }
    body[data-storefront-template="master_05"] #contacto .contact-main h3 { font-size: clamp(1.65rem, 2.15vw, 2.1rem); line-height: 1.15; }
    body[data-storefront-template="master_05"] #contacto .contact-main-social { margin-top: 18px; padding-top: 16px; }
    body[data-storefront-template="master_05"] #contacto .contact-info:has(.contact-map) {
        grid-template-columns: repeat(2, minmax(0, 1fr)) minmax(0, 1.15fr);
        align-content: start;
    }
    body[data-storefront-template="master_05"] #contacto .contact-info-card { padding: 16px; }
    body[data-storefront-template="master_05"] #contacto .contact-map { grid-column: 3; grid-row: 1 / span 2; padding: 0; }
    body[data-storefront-template="master_05"] #contacto .contact-map-copy { padding: 16px 16px 12px; }
    body[data-storefront-template="master_05"] #contacto .contact-map iframe { height: clamp(140px, calc(100vh - 440px), 190px); }

}

/* Maestra 5: escaparate de catálogo con luz y paneles configurables. */
body[data-storefront-template="master_05"] .hero-actions .btn { transition: transform .2s ease, box-shadow .2s ease; }
body[data-storefront-template="master_05"] .m5-product-collage { display: none; }
body[data-storefront-template="master_05"] .hero-actions .btn:hover { transform: translateY(-2px); }
body[data-storefront-template="master_05"] .hero-actions .btn.light { color: var(--store-custom-button-text); background: var(--store-custom-button); border-color: var(--store-custom-button); box-shadow: 0 8px 24px color-mix(in srgb,var(--store-custom-button) 38%,transparent); }
body[data-storefront-template="master_05"] .hero-actions .btn.secondary { color: var(--store-custom-button-secondary-text); background: var(--store-custom-button-secondary); border-color: var(--store-custom-border); }
body[data-storefront-template="master_05"] :is(.section-head .tag,.card .tag) { color: var(--store-custom-link); }
body[data-storefront-template="master_05"] .m5-category-strip { display: flex; gap: 10px; overflow-x: auto; padding: 10px 2px 14px; margin-bottom: 12px; scrollbar-width: thin; }
body[data-storefront-template="master_05"] .m5-category-strip button { flex: 0 0 auto; min-height: 44px; padding: 10px 18px; border: 1px solid var(--store-custom-border); border-radius: var(--store-custom-radius); color: var(--store-custom-text); background: linear-gradient(145deg,var(--store-custom-surface),var(--store-custom-surface-alt)); font: inherit; font-weight: 700; cursor: pointer; }
body[data-storefront-template="master_05"] .m5-category-strip button:is(:hover,:focus-visible,[aria-pressed="true"]) { color: var(--store-custom-button-text); background: var(--store-custom-button); }
body[data-storefront-template="master_05"] :is(#storeProductGrid,#storeServiceGrid) .card .photo:has(img) { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; height: auto; aspect-ratio: auto; padding: 0 6px 6px; background: var(--store-custom-surface); }
body[data-storefront-template="master_05"] :is(#storeProductGrid,#storeServiceGrid) .card .photo > img { position: static; display: block; flex: 0 0 calc(100% + 12px); width: calc(100% + 12px); height: auto; aspect-ratio: var(--store-custom-image-ratio); margin: 0 -6px; }
body[data-storefront-template="master_05"] :is(#storeProductGrid,#storeServiceGrid) .card .photo:has(img) > :is(.featured-badge,.stock,.zaida-visualizable-badge,small) { position: static; inset: auto; display: inline-flex; flex: 0 1 auto; min-width: 0; max-width: 100%; margin: 0; padding: 4px 8px; border: 1px solid var(--store-custom-border); border-radius: 999px; font-size: .7rem; line-height: 1.25; white-space: normal; overflow-wrap: anywhere; }
body[data-storefront-template="master_05"] :is(#storeProductGrid,#storeServiceGrid) .card .photo > .stock { color: var(--store-custom-stock-text); background: #fff9e9; }
@media (min-width: 1001px) {
    body[data-storefront-template="master_05"] { padding-left: 0; }
    body[data-storefront-template="master_05"] > header { position: sticky; inset: 0 auto auto; width: 100%; height: auto; padding: 0; overflow: visible; border: 0; }
    body[data-storefront-template="master_05"] .container.nav { display: flex; flex-direction: row; flex-wrap: nowrap; align-items: center; gap: 12px; width: min(100% - 32px,var(--store-custom-width,1440px)); min-height: 76px; padding: 8px 0; margin: auto; }
    body[data-storefront-template="master_05"] .container.nav .brand { flex: 1 1 160px; min-width: 0; flex-direction: row; align-items: center; padding: 0; border: 0; }
    body[data-storefront-template="master_05"] .container.nav .store-status { order: 2; flex: 0 0 auto; align-self: center; margin: 0; }
    body[data-storefront-template="master_05"] .container.nav > nav { order: 1; display: flex; flex-direction: row; align-items: center; width: auto; gap: 4px; margin: 0; padding: 0; }
    body[data-storefront-template="master_05"] .container.nav > nav :is(a,.nav-action) { width: auto; min-height: 44px; margin: 0; }
    body[data-storefront-template="master_05"] .container.nav > nav :is(a,.nav-action) { padding-inline: clamp(6px,.75vw,12px); }
    body[data-storefront-template="master_05"] .container.nav > nav .nav-action { margin: 0 0 0 8px; color: var(--store-custom-button-text); background: var(--store-custom-button); border: 1px solid var(--store-custom-border); }
    body[data-storefront-template="master_05"] main > section.container { scroll-margin-top: calc(var(--m5-visible-header) + 12px); }
    body[data-storefront-template="master_05"] main > section.container:target { min-height: max(0px,calc(100svh - var(--m5-visible-header))); }
    body[data-storefront-template="master_05"] :is(#productos,#servicios).container { padding-block: 24px 32px; }
    body[data-storefront-template="master_05"] :is(#productos,#servicios) .section-head { margin-bottom: 12px; }
    body[data-storefront-template="master_05"] :is(#productos,#servicios) .section-head h2 { font-size: clamp(1.8rem,2.6vw,2.5rem); }
    body[data-storefront-template="master_05"][data-store-density="comoda"] :is(#productos,#servicios) .card-body { padding: 14px; }
    body[data-storefront-template="master_05"] :is(#productos,#servicios) .card-actions { display: flex; flex-wrap: wrap; gap: 6px; padding-top: 8px; }
    body[data-storefront-template="master_05"] :is(#productos,#servicios) .card-actions .btn { flex: 1 1 95px; min-width: 0; padding-inline: 8px; }
    body[data-storefront-template="master_05"][data-store-hero] .hero {
        position: relative; isolation: isolate; display: grid; align-content: center; align-items: center;
        grid-template-columns: minmax(0,1.05fr) minmax(0,1.15fr) minmax(220px,.8fr);
        grid-template-areas: 'copy photo info'; gap: clamp(16px,2vw,32px);
        width: min(100% - 32px,var(--store-custom-width,1440px)); min-height: var(--store-custom-hero-height);
        margin: 0 auto; padding: 36px clamp(22px,3vw,48px) 110px; border: 1px solid var(--store-custom-border); border-radius: var(--store-custom-radius);
        background: radial-gradient(ellipse at 50% 5%,color-mix(in srgb,var(--orange2) 23%,transparent),transparent 45%),radial-gradient(ellipse at 15% 95%,color-mix(in srgb,var(--store-custom-hero-text) 10%,transparent),transparent 45%),linear-gradient(135deg,var(--orange),color-mix(in srgb,var(--orange) 88%,var(--store-custom-bg)));
        box-shadow: inset 0 1px color-mix(in srgb,var(--store-custom-hero-text) 18%,transparent),0 18px 48px color-mix(in srgb,var(--store-custom-text) 15%,transparent);
    }
    body[data-storefront-template="master_05"][data-store-hero="imagen-izquierda"] .hero { grid-template-areas: 'photo copy info'; }
    body[data-storefront-template="master_05"][data-store-hero] .hero-copy { position: static; grid-area: copy; justify-self: stretch; align-self: center; width: auto; min-width: 0; min-height: 0; margin: 0; padding: 0; border: 0; border-radius: 0; background: transparent; box-shadow: none; }
    body[data-storefront-template="master_05"] .hero-copy h1 { font-family: var(--store-custom-font); max-width: 14ch; font-size: clamp(2.3rem,3.5vw,4rem); line-height: 1.05; color: var(--orange2); }
    body[data-storefront-template="master_05"] .hero-copy h1::first-line { color: var(--store-custom-hero-text); }
    body[data-storefront-template="master_05"] .hero-copy .hero-actions { align-self: flex-start; justify-content: flex-start; }
    body[data-storefront-template="master_05"] .hero-copy .badges { position: absolute; left: clamp(22px,3vw,48px); right: clamp(22px,3vw,48px); bottom: 25px; display: flex; justify-content: space-around; align-items: center; gap: 8px; margin: 0; padding: 12px; border: 1px solid color-mix(in srgb,var(--store-custom-hero-text) 32%,transparent); border-radius: var(--store-custom-radius); background: color-mix(in srgb,var(--orange) 90%,transparent); backdrop-filter: blur(16px); box-shadow: 0 0 24px color-mix(in srgb,var(--orange2) 22%,transparent); }
    body[data-storefront-template="master_05"] .hero-copy .badges span { flex: 1 1 0; text-align: center; white-space: normal; color: var(--store-custom-hero-text); background: transparent; border: 0; border-radius: 0; }
    body[data-storefront-template="master_05"] .hero-copy .badges span + span { border-left: 1px solid color-mix(in srgb,var(--store-custom-hero-text) 35%,transparent); }
    body[data-storefront-template="master_05"][data-store-hero] .hero-photo { display: contents; }
    body[data-storefront-template="master_05"] .hero-photo::after { display: none; }
    body[data-storefront-template="master_05"][data-store-hero] .hero-photo > :is(img,.hero-fallback) { position: relative; z-index: 1; grid-area: photo; width: 100%; height: clamp(220px,33vh,360px); min-height: 0; border: 1px solid var(--store-custom-border); border-radius: var(--store-custom-radius); box-shadow: 0 0 32px color-mix(in srgb,var(--orange2) 32%,transparent),0 20px 42px #0005; }
    body[data-storefront-template="master_05"] .m5-product-collage { position: absolute; z-index: 0; inset: 12% 28% 20% 32%; display: flex; justify-content: space-between; align-items: center; gap: 8px; pointer-events: none; }
    body[data-storefront-template="master_05"] .m5-product-collage img { width: 26%; height: 72%; object-fit: cover; border: 1px solid var(--orange2); border-radius: var(--store-custom-radius); opacity: .65; box-shadow: 0 0 25px color-mix(in srgb,var(--orange2) 45%,transparent); transform: rotate(-9deg); }
    body[data-storefront-template="master_05"] .m5-product-collage img:nth-child(2) { transform: rotate(8deg); }
    body[data-storefront-template="master_05"] .m5-product-collage img:nth-child(3) { transform: rotate(13deg); }
    body[data-storefront-template="master_05"] .hero-photo .local { position: static; grid-area: info; inset: auto; width: 100%; padding: 22px; color: var(--store-custom-text); background: color-mix(in srgb,var(--store-custom-surface) 95%,transparent); border: 1px solid var(--store-custom-border); border-radius: var(--store-custom-radius); backdrop-filter: blur(18px); box-shadow: 0 0 26px color-mix(in srgb,var(--orange2) 30%,transparent); }
    body[data-storefront-template="master_05"] .hero-photo .local :is(b,span:not(.local-state)) { color: var(--store-custom-text); }
    body[data-storefront-template="master_05"] :is(#productos,#servicios).container:has(.m5-filter-panel:not([hidden])) { display: grid; grid-template-columns: minmax(200px,250px) minmax(0,1fr); column-gap: 22px; align-content: start; }
    body[data-storefront-template="master_05"] :is(#productos,#servicios):has(.m5-filter-panel:not([hidden])) > .section-head { grid-column: 1 / -1; }
    body[data-storefront-template="master_05"] :is(#productos,#servicios):has(.m5-filter-panel:not([hidden])) > .m5-category-strip { grid-column: 1 / -1; grid-row: 2; min-width: 0; }
    body[data-storefront-template="master_05"] :is(#productos,#servicios):has(.m5-filter-panel:not([hidden])) > .m5-catalog-toolbar { grid-column: 2; grid-row: 3; }
    body[data-storefront-template="master_05"] :is(#productos,#servicios):has(.m5-filter-panel:not([hidden])) > .m5-filter-panel { display: grid; grid-column: 1; grid-row: 3 / span 3; align-content: start; align-self: start; grid-template-columns: minmax(0,1fr); margin: 0; }
    body[data-storefront-template="master_05"] .m5-filter-panel .catalog-price-filter-fields { display: grid; grid-template-columns: minmax(0,1fr); gap: 10px; }
    body[data-storefront-template="master_05"] .m5-filter-panel .catalog-price-filter-fields label { min-width: 0; }
    body[data-storefront-template="master_05"] :is(#productos,#servicios):has(.m5-filter-panel:not([hidden])) > :is(.products,.catalog-pagination:not(.catalog-pagination-top)) { grid-column: 2; min-width: 0; }
}
@media (prefers-reduced-motion: reduce) { body[data-storefront-template="master_05"] .hero-actions .btn { transition: none; } body[data-storefront-template="master_05"] .hero-actions .btn:hover { transform: none; } }
@media (max-width: 1000px) {
    body[data-storefront-template="master_05"] .hero-copy { background-image: radial-gradient(ellipse at 5% 0,color-mix(in srgb,var(--orange2) 23%,transparent),transparent 55%),linear-gradient(145deg,var(--orange),color-mix(in srgb,var(--orange) 94%,var(--store-custom-bg))); }
    body[data-storefront-template="master_05"] .hero-photo { box-shadow: 0 14px 35px color-mix(in srgb,var(--orange2) 18%,transparent); }
    body[data-storefront-template="master_05"] .hero-copy .hero-actions { flex-wrap: wrap; }
    body[data-storefront-template="master_05"] .hero-copy .hero-actions .btn { padding-inline: 12px; }
}
@media (min-width: 1001px) and (max-width: 1100px) {
    body[data-storefront-template="master_05"] .container.nav { display: grid; grid-template-columns: minmax(0,1fr) auto; gap: 6px 12px; }
    body[data-storefront-template="master_05"] .container.nav .brand { grid-column: 1; grid-row: 1; }
    body[data-storefront-template="master_05"] .container.nav .store-status { grid-column: 2; grid-row: 1; }
    body[data-storefront-template="master_05"] .container.nav > nav { grid-column: 1 / -1; grid-row: 2; justify-content: center; }
}
