:root {
    --black: #000000;
    --carbon: #101010;
    --slate: #1a1a1a;
    --line: #262626;
    --line-strong: #3d3d3d;

    --white: #fafafa;
    --muted: #8f8f8f;

    --red: #e31b23;
    --red-bright: #ff3038;
    --green: #13b03a;
    --green-bright: #2fd456;

    --display: 'Saira Condensed', 'Arial Narrow', sans-serif;
    --body: 'Saira', system-ui, sans-serif;

    --calle: 7vw;

    color-scheme: dark;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
    background: var(--black);
    color: var(--white);
    font-family: var(--body);
    font-size: 15px;
    line-height: 1.6;
    margin: 0;
    overflow-x: hidden;
}
a { color: inherit; text-decoration: none; }
button, input, select { font: inherit; }
img { display: block; }
::placeholder { color: var(--muted); opacity: 1; }

:focus-visible { outline: 2px solid var(--green-bright); outline-offset: 3px; }

h1, h2, h3 {
    font-family: var(--display);
    font-weight: 800;
    letter-spacing: .005em;
    line-height: .92;
    margin: 0;
}
h1 { font-size: clamp(46px, 5.4vw, 86px); }
h2 { font-size: clamp(34px, 4.2vw, 56px); }
h3 { font-size: 21px; font-weight: 700; line-height: 1.1; }

.button {
    align-items: center;
    display: inline-flex;
    font-family: var(--display);
    font-size: 17px;
    font-weight: 700;
    justify-content: center;
    letter-spacing: .04em;
    padding: 15px 30px;
    text-transform: uppercase;
    transition: background .18s, color .18s, border-color .18s;
}
.button-primary { background: var(--red); color: #fff; }
.button-primary:hover { background: var(--red-bright); }
.button-ghost { border: 1px solid var(--line-strong); color: var(--white); }
.button-ghost:hover { border-color: var(--green); color: var(--green-bright); }

.text-link {
    font-size: 14px;
    font-weight: 600;
    text-decoration: underline;
    text-decoration-color: var(--line-strong);
    text-underline-offset: 6px;
    transition: color .18s, text-decoration-color .18s;
}
.text-link:hover { color: var(--green-bright); text-decoration-color: var(--green); }

.section-intro, .section-heading {
    align-items: baseline;
    display: flex;
    flex-wrap: wrap;
    gap: 16px 32px;
    justify-content: space-between;
    margin-bottom: 40px;
}

.utility-bar {
    align-items: center;
    background: var(--carbon);
    color: var(--muted);
    display: flex;
    font-size: 13px;
    gap: 20px;
    justify-content: space-between;
    padding: 10px 5.5vw;
}
.utility-bar p { margin: 0; }
.utility-bar a { color: var(--white); text-decoration: underline; text-underline-offset: 4px; }
.utility-bar a:hover { color: var(--green-bright); }

.session-label { color: var(--muted); font-size: 12px; }
.menu-toggle { background: transparent; border: 0; color: var(--white); cursor: pointer; display: none; font-size: 22px; }

.hero {
    background: var(--black);
    display: grid;
    grid-template-columns: minmax(320px, 46%) 1fr;
}
.hero-copy {
    align-self: center;
    padding: clamp(40px, 4.4vw, 76px) 6vw clamp(40px, 4.4vw, 76px) var(--calle);
    position: relative;
    z-index: 1;
}
.hero-copy h1 { text-transform: uppercase; }
.hero-text { color: var(--muted); font-size: 16px; margin: 26px 0 38px; max-width: 44ch; }
.hero-art {
    align-self: center;
    aspect-ratio: 4 / 3;
    background: linear-gradient(to bottom, var(--green) 0%, #ffffff 46%, var(--red) 100%);
    clip-path: polygon(15% 0, 100% 0, 100% 100%, 0 100%);
    overflow: hidden;
    position: relative;
}

@media (min-width: 901px) and (max-width: 1260px) {
    .hero-art { align-self: stretch; aspect-ratio: auto; }
}
.hero-image {
    background: linear-gradient(90deg, rgba(0,0,0,.85), rgba(0,0,0,.25) 55%, rgba(0,0,0,.45)),
                var(--hero-img, url('https://images.unsplash.com/photo-1558981806-ec527fa84c39?auto=format&fit=crop&w=1600&q=90')) center 35% / cover;
    clip-path: polygon(calc(15% + 5px) 0, 100% 0, 100% 100%, 5px 100%);
    filter: contrast(1.05) brightness(.85);
    inset: 0;
    position: absolute;
}

.hero-slide { opacity: 0; transition: opacity .8s ease; }
.hero-slide.is-active { opacity: 1; }
.hero-dots {
    align-items: center;
    bottom: 14px;
    display: flex;
    gap: 2px;
    position: absolute;
    right: 24px;
    z-index: 2;
}
.hero-dot { background: none; border: 0; cursor: pointer; height: 28px; padding: 0; width: 28px; }
.hero-dot::after {
    background: rgba(255, 255, 255, .45);
    border-radius: 50%;
    content: "";
    display: block;
    height: 10px;
    margin: auto;
    transition: background .2s, transform .2s;
    width: 10px;
}
.hero-dot:hover::after { background: rgba(255, 255, 255, .8); }
.hero-dot[aria-current="true"]::after { background: var(--red-bright); transform: scale(1.2); }

.category-strip, .catalog-section, .buying { padding: 96px var(--calle); }
.category-strip { background: var(--carbon); }
.buying { background: var(--carbon); border-top: 1px solid var(--line); }

.category-card {
    align-items: flex-start;
    color: var(--white);
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    min-height: 260px;
    overflow: hidden;
    padding: 22px;
    position: relative;
}
.category-card:before {
    background: linear-gradient(rgba(0,0,0,.35), rgba(0,0,0,.9));
    content: '';
    inset: 0;
    position: absolute;
    transition: background .25s;
    z-index: 1;
}
.category-card:hover:before { background: linear-gradient(rgba(0,0,0,.2), rgba(0,0,0,.85)); }
.category-card .category-bg {
    filter: saturate(.85) brightness(.9);
    height: 100%;
    inset: 0;
    object-fit: cover;
    position: absolute;
    width: 100%;
    z-index: 0;
}
.category-card:after {
    border: 1px solid transparent;
    content: '';
    inset: 0;
    pointer-events: none;
    position: absolute;
    transition: border-color .25s;
    z-index: 2;
}
.category-card:hover:after { border-color: var(--green); }
.category-card > * { position: relative; z-index: 1; }
.category-name {
    font-family: var(--display);
    font-size: 30px;
    font-weight: 700;
    line-height: 1;
    text-transform: uppercase;
}
.category-count { color: var(--green-bright); font-size: 13px; font-weight: 500; margin-top: 6px; }

.product-grid { display: grid; gap: 20px; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); }
.product-card { display: flex; flex-direction: column; min-width: 0; }

.destacados-grid { display: flex; flex-wrap: wrap; gap: 20px; }
.destacados-grid > .product-card { flex: 0 0 calc(25% - 15px); }
@media (max-width: 1099px) {
    .destacados-grid > .product-card { flex-basis: calc(33.333% - 14px); }
}
@media (max-width: 899px) {
    .destacados-grid > .product-card { flex-basis: calc(50% - 10px); }
}
@media (max-width: 480px) {
    .destacados-grid > .product-card { flex-basis: 100%; }
}
.product-image { aspect-ratio: 4 / 5; background: var(--slate); display: block; overflow: hidden; position: relative; }
.product-image img { height: 100%; object-fit: cover; width: 100%; }
.product-image:after {
    background: linear-gradient(rgba(0,0,0,.08), rgba(0,0,0,.34));
    content: '';
    inset: 0;
    pointer-events: none;
    position: absolute;
    transition: opacity .3s;
    z-index: 1;
}
.product-image:hover:after { opacity: 0; }
.product-flag {
    background: var(--red);
    color: #fff;
    font-size: 12px;
    font-weight: 600;
    left: 0;
    padding: 5px 12px;
    position: absolute;
    top: 14px;
    z-index: 2;
}
.product-flag-out { background: #2b2b2b; left: auto; right: 0; }
.product-info { display: flex; flex: 1; flex-direction: column; padding: 16px 2px 0; }
.product-brand {
    align-items: center;
    color: var(--muted);
    display: flex;
    font-size: 13px;
    height: 32px;
    margin: 0 0 4px;
}
.product-brand-logo { max-height: 32px; max-width: 96px; object-fit: contain; width: auto; }
.product-info h3 { text-transform: uppercase; }
.product-description {
    color: var(--muted);
    font-size: 14px;
    margin: 8px 0 14px;
    max-width: 42ch;
}
.product-variantes { display: flex; flex-direction: column; gap: 6px; margin: 0 0 14px; }
.option-row { display: flex; flex-wrap: wrap; gap: 6px; }
.size-chip {
    background: none;
    border: 1px solid var(--line-strong);
    color: var(--muted);
    cursor: pointer;
    font-family: var(--display);
    font-size: 14px;
    font-weight: 700;
    letter-spacing: .04em;
    min-height: 28px;
    min-width: 34px;
    padding: 2px 10px;
    text-transform: uppercase;
    transition: border-color .18s, color .18s;
}
.size-chip:hover { border-color: var(--green); color: var(--white); }
.size-chip.is-active { border-color: var(--green-bright); color: var(--green-bright); }
.product-colors { display: flex; flex-wrap: wrap; gap: 2px; }
.color-swatch {
    align-items: center;
    background: none;
    border: 0;
    cursor: pointer;
    display: inline-flex;
    justify-content: center;
    min-height: 28px;
    min-width: 28px;
    padding: 0 2px;
}
.color-swatch::before {
    background: var(--muestra, var(--slate));
    border: 1px solid var(--line-strong);
    border-radius: 50%;
    content: "";
    height: 16px;
    transition: box-shadow .18s, border-color .18s;
    width: 16px;
}
.color-swatch:has(.color-nombre)::before { content: none; }
.color-nombre {
    border: 1px solid var(--line-strong);
    color: var(--muted);
    font-size: 12px;
    padding: 3px 9px;
    transition: border-color .18s, color .18s;
    white-space: nowrap;
}
.color-swatch:hover::before { border-color: var(--green); }
.color-swatch:hover .color-nombre { border-color: var(--green); color: var(--white); }
.color-swatch.is-active::before { border-color: var(--white); box-shadow: 0 0 0 2px var(--black), 0 0 0 3px var(--green-bright); }
.color-swatch.is-active .color-nombre { border-color: var(--green-bright); color: var(--green-bright); }
.color-swatch.is-out::before { opacity: .4; }
.color-swatch.is-out .color-nombre { opacity: .5; }
.size-chip.is-out { opacity: .5; }

.size-chip.no-disponible, .color-swatch.no-disponible { opacity: .45; }
.size-chip.no-disponible { text-decoration: line-through; }
.color-swatch.no-disponible::before { border-style: dashed; }

.oculto { display: none; }

.sr-only {
    clip-path: inset(50%);
    height: 1px;
    overflow: hidden;
    position: absolute;
    white-space: nowrap;
    width: 1px;
}

.product-bottom { align-items: baseline; display: flex; gap: 12px; justify-content: space-between; }
.product-price { font-family: var(--display); font-size: 24px; font-weight: 700; }
.price-from { color: var(--muted); font-family: var(--body); font-size: 12px; font-weight: 500; }
.product-stock { color: var(--green-bright); font-size: 13px; }
.product-stock.is-out { color: var(--red-bright); }

.product-info .product-bottom { padding-bottom: 14px; }
.card-add { background: transparent; cursor: pointer; font-size: 14px; gap: 8px; margin-top: auto; padding: 11px 14px; width: 100%; }
.card-add .btn-icon { height: 18px; width: 18px; }
.card-message { color: var(--red-bright); display: block; font-size: 13px; font-weight: 500; margin-top: 8px; }
.card-message[hidden] { display: none; }

.catalog-cta { display: flex; justify-content: center; margin-top: 52px; }
.empty-state { color: var(--muted); padding: 48px 0; text-align: center; }
.empty-state a { color: var(--green-bright); text-decoration: underline; text-underline-offset: 4px; }

.buying h2 { margin-bottom: 44px; }
.buying-list { display: grid; gap: 36px; grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); margin: 0; }
.buying-item { border-top: 2px solid var(--line-strong); padding-top: 18px; }
.buying-item dt { font-family: var(--display); font-size: 24px; font-weight: 700; text-transform: uppercase; }
.buying-item dd { color: var(--muted); font-size: 14px; margin: 10px 0 0; max-width: 34ch; }

.site-footer { background: var(--black); border-top: 1px solid var(--line); padding: 56px var(--calle) 24px; }
.footer-top { align-items: center; display: flex; flex-wrap: wrap; gap: 28px; justify-content: space-between; padding-bottom: 44px; }
.footer-line { color: var(--muted); margin: 0; max-width: 40ch; }
.footer-social { align-items: center; display: flex; gap: 18px; }
.footer-social a { align-items: center; color: var(--white); display: inline-flex; transition: color .18s; }
.footer-social a:hover { color: var(--green-bright); }
.footer-social-icon { height: 22px; width: 22px; }
.footer-bottom {
    border-top: 1px solid var(--line);
    color: var(--muted);
    display: flex;
    flex-wrap: wrap;
    font-size: 13px;
    gap: 12px;
    justify-content: space-between;
    padding-top: 22px;
}
.footer-bottom a { text-decoration: underline; text-underline-offset: 4px; }
.footer-bottom a:hover { color: var(--green-bright); }

.rail-wrap { min-width: 0; position: relative; }
.rail-controls { display: flex; gap: 8px; justify-content: flex-end; margin-bottom: 14px; }
.rail-controls[hidden] { display: none; }
.rail-button {
    background: transparent;
    border: 1px solid var(--line-strong);
    color: var(--white);
    cursor: pointer;
    font-size: 16px;
    height: 40px;
    line-height: 1;
    transition: background .18s, border-color .18s, color .18s;
    width: 40px;
}
.rail-button:hover:not(:disabled) { background: var(--green); border-color: var(--green); color: #000; }
.rail-button:disabled { cursor: default; opacity: .3; }
.category-rail {
    display: flex;
    gap: 14px;
    overflow-x: auto;
    overscroll-behavior-x: contain;
    padding-bottom: 6px;
    scroll-behavior: smooth;
    scroll-snap-type: x mandatory;
    scrollbar-width: none;
}
.category-rail::-webkit-scrollbar { display: none; }
.category-rail .category-card { flex: 0 0 calc((100% - 28px) / 3); scroll-snap-align: start; }

.catalog-hero { background: var(--carbon); border-bottom: 1px solid var(--line); padding: 48px var(--calle) 44px; }
.catalog-hero h1 { font-size: clamp(38px, 5vw, 72px); text-transform: uppercase; }
.breadcrumb { color: var(--muted); display: flex; flex-wrap: wrap; font-size: 14px; gap: 8px; margin-bottom: 22px; }
.breadcrumb a { text-decoration: underline; text-underline-offset: 4px; }
.breadcrumb a:hover { color: var(--green-bright); }
.breadcrumb strong { color: var(--white); font-weight: 600; }
.catalog-count { color: var(--muted); font-size: 15px; margin: 0; }
.catalog-toolbar { align-items: baseline; border-bottom: 1px solid var(--line); display: flex; flex-wrap: wrap; gap: 16px 24px; justify-content: space-between; margin-bottom: 34px; padding-bottom: 16px; }
.sort-form { align-items: center; display: flex; gap: 10px; }
.sort-form label { color: var(--muted); font-size: 14px; }
.sort-form select {
    background: var(--slate);
    border: 1px solid var(--line-strong);
    color: var(--white);
    cursor: pointer;
    font-size: 14px;
    padding: 8px 12px;
    transition: border-color .18s;
}
.sort-form select:hover, .sort-form select:focus { border-color: var(--green); outline: 0; }

.pagination { align-items: center; display: flex; flex-wrap: wrap; gap: 6px; justify-content: center; margin-top: 56px; }
.page-number, .page-step {
    align-items: center;
    border: 1px solid var(--line-strong);
    display: inline-flex;
    font-size: 14px;
    font-weight: 500;
    justify-content: center;
    min-width: 42px;
    padding: 9px 14px;
    transition: background .18s, border-color .18s, color .18s;
}
.page-number:hover, .page-step:hover { border-color: var(--green); color: var(--green-bright); }
.page-number.is-active { background: var(--red); border-color: var(--red); color: #fff; }
.page-step.is-disabled { color: var(--muted); opacity: .45; }
.page-step.is-disabled:hover { border-color: var(--line-strong); color: var(--muted); }

.catalog-results { scroll-margin-top: 24px; }
.catalog-results:focus { outline: none; }
.catalog-results[aria-busy="true"] { opacity: .5; transition: opacity .15s; }

.login-page { background: var(--black); min-height: 100vh; }
.login-layout { display: grid; grid-template-columns: 1fr 1fr; min-height: 100vh; }
.login-brand-panel {
    background: var(--carbon);
    border-right: 1px solid var(--line);
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    padding: 44px 6vw;
}
.login-brand-panel h1 { font-size: clamp(56px, 7vw, 104px); margin-bottom: 10vh; text-transform: uppercase; }
.login-form-panel { display: flex; flex-direction: column; justify-content: center; padding: 44px 7vw; }
.back-link { align-self: flex-start; font-size: 14px; font-weight: 600; margin-bottom: auto; text-decoration: underline; text-underline-offset: 5px; }
.back-link:hover { color: var(--green-bright); }
.login-form-copy { max-width: 42ch; }
.login-form-copy h2 { text-transform: uppercase; }
.login-form-copy > p:not(.eyebrow) { color: var(--muted); margin: 18px 0 32px; }
.login-alert, .login-success { border-left: 2px solid; font-size: 14px; margin-bottom: 18px; max-width: 390px; padding: 12px 14px; }
.login-alert { background: rgba(227,27,35,.12); border-color: var(--red); color: var(--red-bright); }
.login-success { background: rgba(19,176,58,.12); border-color: var(--green); color: var(--green-bright); }
.login-form { display: flex; flex-direction: column; gap: 6px; max-width: 390px; }
.login-form label { font-size: 14px; font-weight: 600; margin-top: 14px; }
.login-form input {
    background: transparent;
    border: 0;
    border-bottom: 1px solid var(--line-strong);
    color: var(--white);
    outline: 0;
    padding: 11px 0;
    transition: border-color .18s;
}
.login-form input:focus { border-color: var(--green); }
.login-form .button { border: 0; cursor: pointer; margin-top: 30px; width: fit-content; }
.login-note { color: var(--muted); font-size: 14px; margin-top: 26px; }
.login-note a { color: var(--green-bright); text-decoration: underline; text-underline-offset: 4px; }
.eyebrow { color: var(--muted); font-size: 14px; margin: 0 0 10px; }

@media (max-width: 900px) {
    .menu-toggle { display: block; }
    .nav-wrap { flex-wrap: wrap; gap: 14px; position: relative; }
    .hero { grid-template-columns: 1fr; }
    .hero-copy { padding: 72px var(--calle) 56px; }
    .hero-art {
        background: linear-gradient(to right, var(--green), #ffffff 46%, var(--red));
        clip-path: polygon(0 7%, 100% 0, 100% 100%, 0 100%);
    }
    .hero-image { clip-path: polygon(0 calc(7% + 5px), 100% 5px, 100% 100%, 0 100%); }
    .category-strip, .catalog-section, .buying { padding: 68px var(--calle); }
    .category-rail .category-card { flex: 0 0 calc((100% - 14px) / 2); }
    .catalog-hero { padding: 38px var(--calle) 34px; }
}

@media (max-width: 600px) {
    :root { --calle: 6vw; }
    .utility-bar { font-size: 12px; padding: 9px 5vw; }
    .utility-bar a { display: none; }
    .nav-wrap { padding: 10px 5vw; }
    .hero-copy { padding: 56px var(--calle) 48px; }
    .category-rail .category-card { flex: 0 0 84%; }
    .rail-controls { justify-content: flex-start; }
    .category-strip, .catalog-section, .buying { padding: 56px var(--calle); }

    .catalog-toolbar { align-items: flex-start; flex-direction: column; }
    .login-layout { grid-template-columns: 1fr; }
    .login-brand-panel { border-bottom: 1px solid var(--line); border-right: 0; min-height: 320px; padding: 28px 7vw; }
    .login-brand-panel h1 { margin-bottom: 24px; }
    .login-form-panel { padding: 32px 7vw 56px; }
    .back-link { margin-bottom: 56px; }
}

@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after {
        animation-duration: .01ms !important;
        animation-iteration-count: 1 !important;
        scroll-behavior: auto !important;
        transition-duration: .01ms !important;
    }
    .category-rail { scroll-behavior: auto; }
}

.section-tools { align-items: center; display: flex; gap: 20px; }
.section-tools .rail-controls { margin-bottom: 0; }

.brand { display: inline-flex; flex: none; }
.brand picture { display: block; }
.brand img { height: 78px; width: auto; }

.brand-full { display: inline-block; }
.brand-full picture { display: block; }
.brand-full img { height: 124px; width: auto; }
.brand-full-lg img { height: 190px; }

.login-brand-panel { background: var(--black); }
.login-form-panel { background: var(--carbon); }

@media (max-width: 600px) {
    .brand img { height: 58px; }
}

.utility-links { display: flex; gap: 20px; }
.utility-links a { color: var(--white); text-decoration: underline; text-underline-offset: 4px; }
.utility-links a:hover { color: var(--green-bright); }

@media (max-width: 900px) {
    .utility-links {
        background: var(--carbon);
        border: 1px solid var(--line);
        display: none;
        flex-direction: column;
        gap: 16px;
        left: 0;
        padding: 20px 5.5vw;
        position: absolute;
        right: 0;
        top: 100%;
        z-index: 5;
    }
    .site-header.is-menu-open .utility-links { display: flex; }
    .nav-wrap { position: relative; }
    .menu-toggle { display: block; }
}

.catalog-hero + .catalog-section { padding-top: 44px; }

.nav-wrap {
    align-items: center;
    background: var(--black);
    border-bottom: 1px solid var(--line);
    display: flex;
    gap: 22px;
    padding: 10px 5.5vw;
}
.brand { flex: none; }
.brand img { height: 62px; width: auto; }

.category-nav { align-items: center; display: flex; flex: 1 1 auto; min-width: 0; }
.category-list { align-items: center; display: flex; flex: 1 1 auto; gap: 2px; min-width: 0; overflow: hidden; }
.category-link {
    text-transform: uppercase;
    border-bottom: 2px solid transparent;
    flex: none;
    font-size: 14px;
    font-weight: 500;
    padding: 16px 14px;
    transition: border-color .18s, color .18s;
    white-space: nowrap;
}
.category-link:hover { color: var(--green-bright); }
.category-link.is-active { border-bottom-color: var(--red); }

.category-more { flex: none; position: relative; }
.category-more[hidden] { display: none; }
.category-more-toggle {
    text-transform: uppercase;
    background: none;
    border: 0;
    border-bottom: 2px solid transparent;
    color: var(--muted);
    cursor: pointer;
    font-size: 14px;
    font-weight: 500;
    padding: 16px 14px;
    transition: color .18s;
    white-space: nowrap;
}
.category-more-toggle:hover, .category-more.is-open .category-more-toggle { color: var(--white); }
.category-more-toggle:after { content: ' ▾'; }
.category-more-menu {
    background: var(--carbon);
    border: 1px solid var(--line-strong);
    display: none;
    max-height: 60vh;
    min-width: 210px;
    overflow-y: auto;
    padding: 6px;
    position: absolute;
    right: 0;
    top: calc(100% + 6px);
    z-index: 20;
}
.category-more.is-open .category-more-menu { display: block; }
.category-more-menu .category-link {
    border-bottom: 0;
    border-left: 2px solid transparent;
    display: block;
    padding: 10px 12px;
}
.category-more-menu .category-link.is-active { border-left-color: var(--red); }

.nav-right { align-items: center; display: flex; flex: none; gap: 14px; }

@media (max-width: 1100px) {
    .nav-wrap { gap: 16px; }
}

@media (max-width: 900px) {
    .nav-wrap { flex-wrap: wrap; }
    .brand img { height: 54px; }
    .category-nav { flex: 1 0 100%; order: 3; }
    .category-list { overflow-x: auto; scrollbar-width: none; }
    .category-list::-webkit-scrollbar { display: none; }
    .category-more { display: none; }
    .nav-right { margin-left: auto; }
}

@media (max-width: 600px) {
    .brand img { height: 48px; }
}

.search-toggle {
    background: none;
    border: 0;
    color: var(--white);
    cursor: pointer;
    font-size: 24px;
    line-height: 1;
    padding: 6px 8px;
    transition: color .18s;
}
.search-toggle:hover, .search-toggle[aria-expanded="true"] { color: var(--green-bright); }

.search-panel { background: var(--carbon); border-bottom: 1px solid var(--line); }
.search-panel[hidden] { display: none; }
.search-panel form { align-items: center; display: flex; gap: 18px; margin: 0; padding: 24px 5.5vw; }
.search-panel label { height: 1px; overflow: hidden; position: absolute; width: 1px; }
.search-panel input {
    background: transparent;
    border: 0;
    border-bottom: 1px solid var(--line-strong);
    color: var(--white);
    flex: 1 1 auto;
    font-family: var(--display);
    font-size: 26px;
    font-weight: 600;
    min-width: 0;
    outline: 0;
    padding: 10px 0;
    transition: border-color .18s;
}
.search-panel input:focus { border-color: var(--green); }
.search-panel .button { flex: none; }
.search-close {
    background: none;
    border: 0;
    color: var(--muted);
    cursor: pointer;
    flex: none;
    font-size: 18px;
    padding: 8px;
}
.search-close:hover { color: var(--white); }

@media (max-width: 600px) {
    .search-panel form { flex-wrap: wrap; gap: 12px; padding: 18px 5vw; }
    .search-panel input { flex: 1 0 100%; font-size: 20px; order: 1; }
    .search-panel .button { order: 2; }
    .search-close { margin-left: auto; order: 3; }
}

.catalog-section, .bag, .toast, .terms-modal {
    --black: #ffffff;
    --slate: #f2f2f2;
    --line: #e3e3e3;
    --line-strong: #cbcbcb;
    --white: #111111;
    --muted: #595959;
    --green-bright: #0b7d27;
    --red-bright: #d0141c;

    background: #ffffff;
    color: var(--white);
    color-scheme: light;
}
.catalog-section .product-image:after { display: none; }

.product-detail { padding-bottom: 56px; padding-top: 32px; }
.product-detail .breadcrumb { margin-bottom: 28px; }
.detail-layout {
    align-items: start;
    display: grid;
    gap: 56px;
    grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr);
}

.gallery { display: flex; flex-direction: column; gap: 14px; max-width: 640px; width: 100%; }
.gallery-main {
    aspect-ratio: 4 / 5;
    background: var(--slate);
    border: 1px solid var(--line);
    cursor: zoom-in;
    display: block;
    overflow: hidden;
    padding: 0;
    position: relative;
    width: 100%;
}
.gallery-main:disabled { cursor: default; }
.gallery-main img { display: block; height: 100%; object-fit: cover; width: 100%; }
.gallery-empty { color: var(--muted); display: grid; height: 100%; place-items: center; }
.gallery-zoom {
    background: rgba(17, 17, 17, .78);
    bottom: 12px;
    color: #fff;
    font-size: 12px;
    font-weight: 600;
    padding: 6px 12px;
    position: absolute;
    right: 12px;
}
.gallery-thumbs { display: flex; flex-wrap: wrap; gap: 10px; list-style: none; margin: 0; padding: 0; }
.gallery-thumbs button {
    aspect-ratio: 4 / 5;
    background: var(--slate);
    border: 2px solid var(--line);
    cursor: pointer;
    overflow: hidden;
    padding: 0;
    transition: border-color .18s;
    width: 72px;
}
.gallery-thumbs button:hover { border-color: var(--line-strong); }
.gallery-thumbs button.is-active { border-color: var(--red); }
.gallery-thumbs img { display: block; height: 100%; object-fit: cover; width: 100%; }

.detail-info { min-width: 0; }
.detail-title { font-size: clamp(30px, 3.6vw, 48px); line-height: 1; margin: 4px 0 18px; text-transform: uppercase; }
.detail-price { font-family: var(--display); font-size: 36px; font-weight: 700; margin: 0 0 6px; }
.detail-price .price-from { margin-right: 8px; }
.detail-stock { font-size: 14px; font-weight: 600; margin: 0 0 24px; }
.detail-stock.is-ok { color: var(--green-bright); }
.detail-stock.is-out { color: var(--red-bright); }
.detail-options { display: grid; gap: 20px; margin-bottom: 20px; }
.detail-option-label {
    color: var(--muted);
    display: block;
    font-size: 13px;
    font-weight: 600;
    letter-spacing: .06em;
    margin-bottom: 8px;
    text-transform: uppercase;
}
.detail-option-elegido { color: var(--white); letter-spacing: 0; text-transform: none; }
.detail-options .size-chip { font-size: 16px; min-height: 42px; min-width: 52px; }
.detail-options .color-swatch { min-height: 42px; min-width: 42px; }
.detail-options .color-swatch::before { height: 28px; width: 28px; }
.detail-options .color-nombre { font-size: 14px; padding: 8px 14px; }
.detail-options .color-swatch:disabled { cursor: not-allowed; }
.detail-options .color-swatch[hidden] { display: none; }
.detail-options .color-swatch:disabled:hover::before { border-color: var(--line-strong); }
.detail-options .color-swatch:disabled:hover .color-nombre { border-color: var(--line-strong); color: var(--muted); }
.detail-sku { color: var(--muted); font-size: 13px; margin: 0 0 16px; }
.detail-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 6px; }
.detail-buy, .detail-cart { flex: 1 1 100%; gap: 10px; }
.detail-actions button.button { border: 1px solid transparent; cursor: pointer; }
.detail-actions button.detail-buy { border-color: var(--red); }
.detail-actions button.detail-cart { background: transparent; border-color: var(--white); }
.detail-actions button.detail-cart:hover { background: var(--white); color: #fff; }
.btn-icon { flex: none; height: 20px; width: 20px; }
.detail-buy:disabled { background: var(--line-strong); color: var(--muted); cursor: not-allowed; }
.detail-message { color: var(--red-bright); font-size: 14px; font-weight: 500; margin: 14px 0 0; }
.detail-description { border-top: 1px solid var(--line); margin-top: 34px; padding-top: 26px; }
.detail-description h2 { font-size: 26px; margin-bottom: 12px; text-transform: uppercase; }
.detail-description p { color: var(--muted); line-height: 1.7; margin: 0; max-width: 62ch; white-space: pre-line; }

.related { border-top: 1px solid var(--line); padding-top: 56px; }
.related .section-heading { margin-bottom: 28px; }
.related .rail-controls { margin-bottom: 0; }
.product-rail {
    display: flex;
    gap: 20px;
    overflow-x: auto;
    overscroll-behavior-x: contain;
    padding-bottom: 6px;
    position: relative;
    scroll-behavior: smooth;
    scroll-snap-type: x mandatory;
    scrollbar-width: none;
}
.product-rail::-webkit-scrollbar { display: none; }
.product-rail > .product-card { flex: 0 0 calc((100% - 60px) / 4); scroll-snap-align: start; }

html.visor-abierto { overflow: hidden; }
.viewer {
    -webkit-backdrop-filter: blur(6px);
    backdrop-filter: blur(6px);
    background: rgba(255, 255, 255, .82);
    border: 0;
    color: #111;
    height: 100dvh;
    max-height: none;
    max-width: none;
    padding: 0;
    width: 100vw;
}
.viewer[open] { align-items: center; display: flex; justify-content: center; }
.viewer::backdrop { background: transparent; }
.viewer-img {
    border: 1px solid #e3e3e3;
    box-shadow: 0 10px 40px rgba(0, 0, 0, .12);
    max-height: 90dvh;
    max-width: min(92vw, 1100px);
    object-fit: contain;
}
.viewer-close, .viewer-step {
    background: #fff;
    border: 1px solid #cbcbcb;
    color: #111;
    cursor: pointer;
    font-size: 24px;
    height: 48px;
    line-height: 1;
    position: absolute;
    transition: background .18s;
    width: 48px;
}
.viewer-close:hover, .viewer-step:hover { background: #111; border-color: #111; color: #fff; }
.viewer-close { font-size: 18px; right: 16px; top: 16px; }
.viewer-step { top: 50%; transform: translateY(-50%); }
.viewer-prev { left: 16px; }
.viewer-next { right: 16px; }
.viewer-count { bottom: 16px; color: #595959; font-size: 14px; left: 0; margin: 0; position: absolute; right: 0; text-align: center; }

@media (max-width: 1100px) {
    .product-rail > .product-card { flex-basis: calc((100% - 40px) / 3); }
}
@media (max-width: 900px) {
    .detail-layout { gap: 30px; grid-template-columns: minmax(0, 1fr); }
    .gallery { max-width: none; }
}
@media (max-width: 800px) {
    .product-rail > .product-card { flex-basis: calc((100% - 20px) / 2); }
}
@media (max-width: 560px) {
    .product-rail > .product-card { flex-basis: 78%; }
    .viewer-step { height: 42px; width: 42px; }
}

.icon { flex: none; height: 24px; width: 24px; }
.icon-button {
    align-items: center;
    background: none;
    border: 0;
    color: var(--white);
    cursor: pointer;
    display: inline-flex;
    height: 40px;
    justify-content: center;
    list-style: none;
    position: relative;
    transition: color .18s;
    width: 40px;
}
.icon-button::-webkit-details-marker { display: none; }
.icon-button:hover, .user-menu[open] > .icon-button { color: var(--green-bright); }

.cart-count {
    background: var(--red);
    border-radius: 999px;
    color: #fff;
    font-size: 11px;
    font-weight: 700;
    height: 18px;
    line-height: 18px;
    min-width: 18px;
    padding: 0 5px;
    position: absolute;
    right: -2px;
    text-align: center;
    top: 0;
}

.user-menu { position: relative; }
.user-menu-panel {
    background: var(--carbon);
    border: 1px solid var(--line-strong);
    box-shadow: 0 14px 36px rgba(0, 0, 0, .55);
    min-width: 230px;
    padding: 6px;
    position: absolute;
    right: 0;
    top: calc(100% + 10px);
    z-index: 40;
}
.user-menu-panel form { margin: 0; }
.user-menu-name { border-bottom: 1px solid var(--line); display: flex; flex-direction: column; line-height: 1.3; padding: 10px 12px 12px; }
.user-menu-name strong { font-size: 14px; max-width: 220px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.user-menu-item {
    background: none;
    border: 0;
    color: var(--white);
    cursor: pointer;
    display: block;
    font-family: var(--body);
    font-size: 14px;
    font-weight: 600;
    padding: 12px;
    text-align: left;
    width: 100%;
}
.user-menu-item:hover { background: var(--slate); color: var(--green-bright); }

html.bolsa-abierta { overflow: hidden; }
.bag-overlay {
    background: rgba(0, 0, 0, .5);
    inset: 0;
    opacity: 0;
    pointer-events: none;
    position: fixed;
    transition: opacity .25s;
    z-index: 90;
}
.bag-overlay.is-open { opacity: 1; pointer-events: auto; }
.bag {
    bottom: 0;
    box-shadow: -14px 0 40px rgba(0, 0, 0, .3);
    display: flex;
    flex-direction: column;
    max-width: 100vw;
    position: fixed;
    right: 0;
    top: 0;
    transform: translateX(100%);
    transition: transform .3s ease, visibility 0s .3s;
    visibility: hidden;
    width: 440px;
    z-index: 100;
}
.bag.is-open { transform: none; transition: transform .3s ease; visibility: visible; }
.bag-head { align-items: center; border-bottom: 1px solid var(--line); display: flex; justify-content: space-between; padding: 16px 20px; }
.bag-head h2 { font-size: 28px; margin: 0; text-transform: uppercase; }
.bag-units { color: var(--muted); font-size: 20px; }
.bag-close {
    background: none;
    border: 1px solid var(--line-strong);
    color: var(--white);
    cursor: pointer;
    font-size: 16px;
    height: 40px;
    width: 40px;
}
.bag-close:hover { background: var(--slate); }
.bag-body { flex: 1; overflow-y: auto; padding: 4px 20px; }
.bag-foot { border-top: 1px solid var(--line); display: grid; gap: 10px; padding: 16px 20px 20px; }
.bag-foot[hidden] { display: none; }
.bag-total { align-items: baseline; display: flex; justify-content: space-between; margin: 0 0 4px; }
.bag-total strong { font-family: var(--display); font-size: 28px; }
.bag-foot .button, .cart-summary .button { gap: 10px; width: 100%; }
.bag-foot button.button, .cart-summary button.button { border: 1px solid transparent; cursor: pointer; }
.bag-foot button.button-primary, .cart-summary button.button-primary { border-color: var(--red); }
.bag-foot button.button-ghost, .cart-summary button.button-ghost { background: transparent; border-color: var(--line-strong); }
.bag-foot button.button-ghost:hover, .cart-summary button.button-ghost:hover { background: var(--slate); }
.bag-foot button.button:disabled, .cart-summary button.button:disabled {
    background: var(--line-strong);
    border-color: var(--line-strong);
    color: var(--muted);
    cursor: not-allowed;
}

.cart-lines { list-style: none; margin: 0; padding: 0; }
.cart-line {
    border-bottom: 1px solid var(--line);
    display: grid;
    gap: 14px;
    grid-template-columns: 72px minmax(0, 1fr) auto;
    padding: 16px 0;
}
.cart-line-img { aspect-ratio: 4 / 5; background: var(--slate); display: block; overflow: hidden; }
.cart-line-img img { display: block; height: 100%; object-fit: cover; width: 100%; }
.cart-line-name {
    display: block;
    font-family: var(--display);
    font-size: 18px;
    font-weight: 700;
    line-height: 1.15;
    margin: 0;
    text-transform: uppercase;
}
a.cart-line-name:hover { color: var(--green-bright); }
.cart-line-meta { color: var(--muted); font-size: 13px; margin: 4px 0 0; }
.cart-line-sku { color: var(--muted); font-size: 12px; margin: 2px 0 0; }
.cart-line-actions { align-items: center; display: flex; flex-wrap: wrap; gap: 10px 16px; margin-top: 12px; }
.qty { align-items: center; border: 1px solid var(--line-strong); display: inline-flex; }
.qty-btn { background: none; border: 0; color: var(--white); cursor: pointer; font-size: 18px; height: 34px; line-height: 1; width: 34px; }
.qty-btn:hover:not(:disabled) { background: var(--slate); }
.qty-btn:disabled { cursor: not-allowed; opacity: .35; }
.qty-n { font-size: 15px; font-weight: 600; min-width: 34px; text-align: center; }
.cart-line-remove {
    align-items: center;
    background: none;
    border: 1px solid var(--line-strong);
    color: var(--muted);
    cursor: pointer;
    display: inline-flex;
    height: 34px;
    justify-content: center;
    padding: 0;
    transition: color .18s, border-color .18s;
    width: 34px;
}
.cart-line-remove:hover { border-color: var(--red-bright); color: var(--red-bright); }
.icon-sm { height: 18px; width: 18px; }
.cart-line-price { align-self: start; display: flex; flex-direction: column; gap: 2px; margin: 0; text-align: right; }
.cart-line-price strong { font-family: var(--display); font-size: 20px; }
.cart-line-unit { color: var(--muted); font-size: 12px; }
.cart-empty { display: grid; gap: 10px; justify-items: start; padding: 32px 0; }
.cart-empty-title { font-family: var(--display); font-size: 26px; font-weight: 700; margin: 0; text-transform: uppercase; }
.cart-empty-text { color: var(--muted); margin: 0 0 8px; }

.cart-page { padding-top: 32px; }
.cart-page .breadcrumb { margin-bottom: 20px; }
.cart-title { font-size: clamp(34px, 4.5vw, 56px); margin: 0 0 28px; text-transform: uppercase; }
.cart-layout { align-items: start; display: grid; gap: 40px; grid-template-columns: minmax(0, 1fr) 430px; }
.cart-layout[hidden] { display: none; }
.cart-layout .cart-lines { border-top: 1px solid var(--line); }
.cart-page .cart-line { grid-template-columns: 110px minmax(0, 1fr) auto; }
.cart-summary { border: 1px solid var(--line); display: grid; gap: 12px; padding: 24px; position: sticky; top: 24px; }
.cart-summary h2 { font-size: 26px; margin: 0 0 4px; text-transform: uppercase; }
.cart-summary-list { display: grid; gap: 8px; margin: 0; }
.cart-summary-list div { display: flex; justify-content: space-between; }
.cart-summary-list dt { color: var(--muted); }
.cart-summary-list dd { margin: 0; }
.cart-summary-total { align-items: baseline; border-top: 1px solid var(--line); padding-top: 12px; }
.cart-summary-total dd { font-family: var(--display); font-size: 32px; font-weight: 700; }
.cart-note { color: var(--muted); font-size: 13px; margin: 0; }
.cart-clear {
    background: none;
    border: 0;
    color: var(--muted);
    cursor: pointer;
    font-size: 13px;
    justify-self: center;
    text-decoration: underline;
    text-underline-offset: 4px;
}
.cart-clear:hover { color: var(--red-bright); }

.toasts {
    bottom: 24px;
    display: grid;
    gap: 10px;
    left: 24px;
    pointer-events: none;
    position: fixed;
    width: min(360px, calc(100vw - 32px));
    z-index: 120;
}
.toast {
    align-items: center;
    border: 1px solid var(--line-strong);
    border-left: 4px solid var(--green);
    box-shadow: 0 10px 30px rgba(0, 0, 0, .28);
    display: flex;
    gap: 12px;
    opacity: 0;
    padding: 12px 14px;
    pointer-events: auto;
    transform: translateY(12px);
    transition: opacity .25s, transform .25s;
}
.toast.is-visible { opacity: 1; transform: none; }
.toast-img { aspect-ratio: 4 / 5; background: var(--slate); height: 52px; object-fit: cover; }
.toast-text { display: grid; flex: 1; font-size: 14px; gap: 2px; min-width: 0; }
.toast-text strong { font-size: 15px; }
.toast-text span { color: var(--muted); font-size: 13px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.toast-close { background: none; border: 0; color: var(--muted); cursor: pointer; font-size: 14px; padding: 6px; }
.toast-close:hover { color: var(--white); }

@media (max-width: 900px) {
    .cart-layout { gap: 28px; grid-template-columns: minmax(0, 1fr); }
    .cart-summary { position: static; }
}
@media (max-width: 600px) {
    .bag { width: 100vw; }
    .cart-page .cart-line { grid-template-columns: 84px minmax(0, 1fr); }
    .cart-summary { padding: 16px; }
    .cart-summary .terms-row { font-size: 13px; }
    .cart-page .cart-line-price { grid-column: 2; text-align: left; }
    .toasts { bottom: auto; left: 50%; top: 12px; transform: translateX(-50%); }
}

.terms-check { flex: 1 1 100%; }
.terms-row { align-items: flex-start; display: flex; font-size: 14px; gap: 10px; line-height: 1.4; }
.terms-row input { accent-color: var(--red); cursor: pointer; flex: none; height: 18px; margin: 1px 0 0; width: 18px; }
.terms-row label { cursor: pointer; }
.terms-row a { text-decoration: underline; text-underline-offset: 3px; }
.terms-row a:hover { color: var(--green-bright); }
.terms-error { color: var(--red-bright); font-size: 13px; font-weight: 500; margin: 6px 0 0; }
.terms-error[hidden] { display: none; }

.legal-text, .legal-draft { max-width: 78ch; }
.legal-text h2 { font-size: 26px; margin: 36px 0 12px; text-transform: uppercase; }
.legal-text h2:first-child { margin-top: 0; }
.legal-text p, .legal-text li { line-height: 1.7; }
.legal-text p { margin: 0 0 12px; }
.legal-text ul, .legal-text ol { margin: 0 0 12px; padding-left: 22px; }
.legal-text li { margin-bottom: 6px; }
.pendiente { background: #fff1a8; color: #111; padding: 0 4px; }
.legal-multilinea { white-space: pre-line; }
.legal-text a { text-decoration: underline; }
.legal-draft { background: #fffbe6; border: 1px solid #f0d96a; border-left: 4px solid #d4a500; margin-bottom: 32px; padding: 14px 18px; }
.nota-revision { border-left: 3px solid #d4a500; color: var(--muted); font-size: 13px; font-style: italic; padding-left: 12px; }

.link-button { background: none; border: 0; color: inherit; cursor: pointer; font: inherit; padding: 0; text-decoration: underline; text-underline-offset: 3px; }
.link-button:hover { color: var(--green-bright); }

html.terminos-abierto { overflow: hidden; }
.terms-modal {
    border: 0;
    box-shadow: 0 24px 80px rgba(0, 0, 0, .45);
    max-height: min(88dvh, 920px);
    max-width: none;
    padding: 0;
    width: min(760px, calc(100vw - 24px));
}
.terms-modal[open] { display: flex; flex-direction: column; }
.terms-modal::backdrop { background: rgba(0, 0, 0, .6); }
.terms-modal-head { align-items: flex-start; border-bottom: 1px solid var(--line); display: flex; flex: none; gap: 16px; justify-content: space-between; padding: 18px 24px; }
.terms-modal-head h2 { font-size: 28px; margin: 0; text-transform: uppercase; }
.terms-modal-version { color: var(--muted); font-size: 13px; margin: 4px 0 0; }
.terms-modal-body { flex: 1; overflow-y: auto; overscroll-behavior: contain; padding: 20px 24px 8px; }
.terms-modal-foot { border-top: 1px solid var(--line); display: flex; flex: none; justify-content: flex-end; padding: 14px 24px; }
.terms-modal-foot button.button { background: transparent; border: 1px solid var(--line-strong); cursor: pointer; }
@media (max-width: 600px) {
    .terms-modal-head, .terms-modal-body, .terms-modal-foot { padding-left: 16px; padding-right: 16px; }
    .terms-modal-head h2 { font-size: 24px; }
}

.catalog-main { min-width: 0; }

.product-grid {
    --orilla: clamp(12px, 1.6vw, 28px);
    margin-left: calc(var(--orilla) - var(--calle));
    margin-right: calc(var(--orilla) - var(--calle));
}

html.filtros-abierto { overflow: hidden; }
.filters-overlay {
    background: rgba(0, 0, 0, .5);
    inset: 0;
    opacity: 0;
    pointer-events: none;
    position: fixed;
    transition: opacity .25s;
    z-index: 90;
}
.filters-overlay.is-open { opacity: 1; pointer-events: auto; }
.filters {
    background: #ffffff;
    bottom: 0;
    box-shadow: 14px 0 40px rgba(0, 0, 0, .3);
    left: 0;
    max-width: 88vw;
    overflow-y: auto;
    overscroll-behavior: contain;
    padding: 0 20px 20px;
    position: fixed;
    scrollbar-width: thin;
    top: 0;
    transform: translateX(-100%);
    transition: transform .3s ease, visibility 0s .3s;
    visibility: hidden;
    width: 340px;
    z-index: 100;
}
.filters.is-open { transform: none; transition: transform .3s ease; visibility: visible; }
.filters-head {
    align-items: baseline;
    background: #ffffff;
    border-bottom: 1px solid var(--line);
    display: flex;
    justify-content: space-between;
    padding: 20px 0 12px;
    position: sticky;
    top: 0;
    z-index: 1;
}
.filters-head h2 { font-size: 26px; margin: 0; text-transform: uppercase; }
.filters-head-acciones { align-items: center; display: flex; gap: 14px; }
.filters-clear { color: var(--muted); font-size: 13px; font-weight: 600; text-decoration: underline; text-underline-offset: 3px; }
.filters-clear:hover { color: var(--red-bright); }
.filters-clear[hidden] { display: none; }
.filters-close { background: none; border: 1px solid var(--line-strong); color: var(--white); cursor: pointer; flex: none; font-size: 15px; height: 34px; line-height: 1; width: 34px; }
.filters-close:hover { background: var(--slate); }

.filter-group { border-bottom: 1px solid var(--line); padding: 14px 0; }
.filter-group > summary {
    align-items: center;
    cursor: pointer;
    display: flex;
    font-family: var(--display);
    font-size: 18px;
    font-weight: 700;
    justify-content: space-between;
    letter-spacing: .03em;
    list-style: none;
    text-transform: uppercase;
}
.filter-group > summary::-webkit-details-marker { display: none; }
.filter-group > summary::after { color: var(--muted); content: "+"; font-size: 20px; line-height: 1; }
.filter-group[open] > summary::after { content: "−"; }
.filter-list { display: grid; gap: 2px; list-style: none; margin: 10px 0 0; padding: 0; }
.filter-scroll { max-height: 220px; overflow-y: auto; scrollbar-width: thin; }

.filter-link { align-items: center; display: flex; font-size: 14px; justify-content: space-between; padding: 4px 0; }
.filter-link:hover { color: var(--green-bright); }
.filter-link.is-active { color: var(--red); font-weight: 700; }
.filter-count { color: var(--muted); font-size: 12px; }

.filter-option { align-items: center; cursor: pointer; display: flex; font-size: 14px; gap: 10px; padding: 5px 0; }
.filter-option input { accent-color: var(--red); flex: none; height: 16px; margin: 0; width: 16px; }
.filter-swatch { background: var(--muestra, var(--slate)); border: 1px solid var(--line-strong); border-radius: 50%; flex: none; height: 16px; width: 16px; }

.filter-chips { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 12px; }
.filter-chip { position: relative; }
.filter-chip input { cursor: pointer; inset: 0; margin: 0; opacity: 0; position: absolute; }
.filter-chip span {
    align-items: center;
    border: 1px solid var(--line-strong);
    display: inline-flex;
    font-family: var(--display);
    font-size: 14px;
    font-weight: 700;
    justify-content: center;
    min-height: 34px;
    min-width: 42px;
    padding: 0 10px;
    text-transform: uppercase;
    transition: background .18s, border-color .18s, color .18s;
}
.filter-chip:hover span { border-color: var(--green); }
.filter-chip:has(input:checked) span { background: var(--white); border-color: var(--white); color: var(--black); }
.filter-chip:has(input:focus-visible) span { outline: 2px solid var(--green-bright); outline-offset: 2px; }

.filter-text:focus { border-color: var(--green); }
.filter-text { background: transparent; border: 1px solid var(--line-strong); color: inherit; font: inherit; margin-top: 12px; outline: 0; padding: 9px 12px; width: 100%; }
.filters-apply { border: 1px solid var(--red); cursor: pointer; margin-top: 18px; width: 100%; }

.filters-toggle {
    align-items: center;
    background: transparent;
    border: 1px solid var(--line-strong);
    color: var(--white);
    cursor: pointer;
    display: inline-flex;
    font-family: var(--display);
    font-size: 15px;
    font-weight: 700;
    gap: 9px;
    letter-spacing: .04em;
    margin-bottom: 24px;
    min-height: 42px;
    padding: 0 18px;
    text-transform: uppercase;
    transition: background .18s, border-color .18s;
}
.filters-toggle:hover { border-color: var(--green); }
.filters-toggle[aria-expanded="true"] { background: var(--slate); border-color: var(--green); }
.filters-toggle-icon { flex: none; height: 18px; width: 18px; }
.filters-toggle-count { background: var(--red); border-radius: 999px; color: #fff; font-size: 12px; line-height: 20px; min-width: 20px; padding: 0 6px; text-align: center; }
.filters-toggle-count[hidden] { display: none; }

.active-filters { align-items: center; display: flex; flex-wrap: wrap; gap: 8px; margin: 0 0 24px; }
.active-filter { align-items: center; background: var(--slate); border: 1px solid var(--line-strong); display: inline-flex; font-size: 13px; font-weight: 600; gap: 8px; padding: 6px 10px; transition: border-color .18s, color .18s; }
.active-filter:hover { border-color: var(--red-bright); color: var(--red-bright); }

.catalog-main .product-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
@media (min-width: 1100px) {
    .catalog-main .product-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); }
}

@media (max-width: 899px) {
    .catalog-main .product-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 480px) {
    .filters { max-width: 100vw; width: 100vw; }
    .catalog-main .product-grid { grid-template-columns: minmax(0, 1fr); }
}

.range { margin-top: 14px; }
.range-values { display: flex; font-family: var(--display); font-size: 17px; font-weight: 700; justify-content: space-between; margin: 0 0 8px; }
.range-track { height: 24px; position: relative; }
.range-track::before { background: var(--line-strong); border-radius: 2px; content: ""; height: 4px; left: 0; position: absolute; right: 0; top: 10px; }
.range-fill {
    background: var(--red);
    border-radius: 2px;
    height: 4px;
    left: calc(10px + (100% - 20px) * var(--desde, 0));
    position: absolute;
    right: calc(10px + (100% - 20px) * (1 - var(--hasta, 1)));
    top: 10px;
}
.range-input { -webkit-appearance: none; appearance: none; background: none; height: 24px; left: 0; margin: 0; outline: 0; pointer-events: none; position: absolute; top: 0; width: 100%; }
.range-input::-webkit-slider-runnable-track { background: transparent; height: 24px; }
.range-input::-moz-range-track { background: transparent; height: 24px; }
.range-input::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    background: #fff;
    border: 2px solid var(--red);
    border-radius: 50%;
    box-shadow: 0 1px 4px rgba(0, 0, 0, .25);
    cursor: grab;
    height: 20px;
    margin-top: 2px;
    pointer-events: auto;
    width: 20px;
}
.range-input::-moz-range-thumb {
    background: #fff;
    border: 2px solid var(--red);
    border-radius: 50%;
    box-shadow: 0 1px 4px rgba(0, 0, 0, .25);
    box-sizing: border-box;
    cursor: grab;
    height: 20px;
    pointer-events: auto;
    width: 20px;
}
.range-input:active::-webkit-slider-thumb { cursor: grabbing; }
.range-input:active::-moz-range-thumb { cursor: grabbing; }
.range-input:focus-visible::-webkit-slider-thumb { outline: 2px solid var(--green-bright); outline-offset: 2px; }
.range-input:focus-visible::-moz-range-thumb { outline: 2px solid var(--green-bright); outline-offset: 2px; }

.pedido-modal {
    border: 0;
    box-shadow: 0 24px 80px rgba(0, 0, 0, .45);
    max-width: none;
    padding: 0;
    width: min(440px, calc(100vw - 24px));
}
.pedido-modal[open] { display: flex; flex-direction: column; }
.pedido-modal::backdrop { background: rgba(0, 0, 0, .6); }
.pedido-modal-head { align-items: flex-start; border-bottom: 1px solid var(--line); display: flex; gap: 16px; justify-content: space-between; padding: 18px 24px; }
.pedido-modal-head h2 { font-size: 24px; margin: 0; text-transform: uppercase; }
.pedido-modal-body { display: grid; gap: 14px; padding: 18px 24px; }
.pedido-modal-intro { color: var(--muted); font-size: 13px; margin: 0; }
.pedido-modal-foot { border-top: 1px solid var(--line); display: flex; gap: 10px; justify-content: flex-end; padding: 14px 24px; }
.pedido-modal-foot button.button { cursor: pointer; }
.pedido-modal-foot button.button-ghost { background: transparent; border: 1px solid var(--line-strong); }
.pedido-modal-foot button.button-primary { background: var(--red); border: 1px solid var(--red); }
.pedido-modal-foot button.button-primary:hover { background: var(--red-bright); border-color: var(--red-bright); }
.pedido-modal-foot button.button-primary:disabled { background: var(--line-strong); border-color: var(--line-strong); color: var(--muted); cursor: not-allowed; }

.campo-fila { display: grid; gap: 14px; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); }
.campo-pedido { display: grid; font-size: 13px; font-weight: 600; gap: 6px; }
.campo-pedido input, .campo-pedido select {
    background: var(--slate);
    border: 1px solid var(--line-strong);
    color: var(--white);
    font-family: var(--body);
    font-size: 15px;
    font-weight: 400;
    padding: 9px 12px;
    width: 100%;
}
.campo-pedido input:focus, .campo-pedido select:focus { border-color: var(--green); outline: 0; }
.pedido-modal-error { background: rgba(227, 27, 35, .12); border-left: 3px solid var(--red); color: var(--red-bright); font-size: 13px; margin: 0; padding: 10px 12px; }
.pedido-modal-error[hidden] { display: none; }

@media (max-width: 480px) {
    .pedido-modal .campo-fila { grid-template-columns: minmax(0, 1fr); }
}

.pedido-seguimiento { max-width: 720px; padding-top: 32px; }
.pedido-seguimiento .breadcrumb { margin-bottom: 20px; }
.pedido-cabecera { align-items: flex-start; display: flex; flex-wrap: wrap; gap: 14px; justify-content: space-between; margin-bottom: 6px; }
.pedido-eyebrow { color: var(--muted); font-size: 13px; font-weight: 600; letter-spacing: .06em; margin: 0 0 4px; text-transform: uppercase; }
.pedido-cabecera h1 { font-size: clamp(26px, 3.4vw, 38px); margin: 0; }
.pedido-estado { border: 1px solid; font-size: 13px; font-weight: 600; padding: 6px 12px; white-space: nowrap; }
.pedido-estado.is-pendiente { border-color: #d4a500; color: #a97600; }
.pedido-estado.is-procesado { border-color: var(--green); color: #0b7d27; }
.pedido-estado.is-anulado { border-color: var(--line-strong); color: var(--muted); }
.pedido-nota { color: var(--muted); font-size: 14px; margin: 14px 0 0; }
.pedido-items { border-top: 1px solid var(--line); list-style: none; margin: 24px 0 0; padding: 0; }
.pedido-item { align-items: flex-start; border-bottom: 1px solid var(--line); display: flex; gap: 16px; justify-content: space-between; padding: 16px 0; }
.pedido-total { align-items: baseline; display: flex; gap: 12px; justify-content: flex-end; margin: 16px 0 0; }
.pedido-total strong { font-family: var(--display); font-size: 26px; }
.pedido-seguimiento-acciones { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 32px; }
.pedido-seguimiento-acciones .button { gap: 10px; }
