/* ==========================================================
   OCHEIRO - Estilos del frontend
   Estética: lujo minimalista. Negro carbón + dorado + crema
   ========================================================== */

:root {
    --c-bg:        #ffffff;
    --c-bg-alt:    #faf7f2;          /* crema cálido */
    --c-ink:       #15110d;          /* negro tinta */
    --c-ink-soft:  #4a443c;
    --c-muted:     #8a8278;
    --c-line:      #e9e3d8;
    --c-gold:      #b08d57;          /* dorado champagne */
    --c-gold-dark: #8c6f43;
    --c-accent:    #1a1410;
    --c-success:   #2f7a4e;
    --c-danger:    #b3311e;
    --c-warning:   #b88008;

    --radius:      4px;
    --radius-lg:   8px;
    --shadow-sm:   0 1px 2px rgba(20,17,13,.06);
    --shadow-md:   0 6px 24px rgba(20,17,13,.08);
    --shadow-lg:   0 20px 60px rgba(20,17,13,.12);

    --f-serif:    "Cormorant Garamond","Playfair Display",Georgia,"Times New Roman",serif;
    --f-sans:     "Inter","Helvetica Neue",Arial,sans-serif;
    --f-mono:     ui-monospace,"SFMono-Regular",Consolas,monospace;
}

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body {
    font-family: var(--f-sans);
    color: var(--c-ink);
    background: var(--c-bg);
    line-height: 1.55;
    font-size: 15.5px;
    -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; display: block; height: auto; }
a { color: var(--c-ink); text-decoration: none; transition: color .2s; }
a:hover { color: var(--c-gold-dark); }

h1, h2, h3, h4 { font-family: var(--f-serif); font-weight: 500; letter-spacing: .005em; line-height: 1.15; margin: 0 0 .5em; }
h1 { font-size: clamp(2rem, 4vw, 3.4rem); }
h2 { font-size: clamp(1.6rem, 3vw, 2.4rem); }
h3 { font-size: 1.4rem; }
.eyebrow {
    font-family: var(--f-sans);
    font-size: 11px;
    letter-spacing: .25em;
    text-transform: uppercase;
    color: var(--c-gold-dark);
    font-weight: 600;
    margin-bottom: .8rem;
    display: inline-block;
}

/* ----- Topbar ----- */
.topbar {
    background: var(--c-ink);
    color: #d8d2c5;
    font-size: 12px;
    letter-spacing: .15em;
    text-transform: uppercase;
    padding: 9px 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 24px;
    position: relative;
}
.topbar > span:first-child { text-align: center; }
.topbar a { color: #efe7d4; }
.topbar-msg-short { display: none; }

/* ----- Selector de idioma ----- */
.lang-switcher {
    position: absolute;
    right: 16px;
    top: 50%;
    transform: translateY(-50%);
}
[dir="rtl"] .lang-switcher { right: auto; left: 16px; }
.lang-btn {
    display: inline-flex; align-items: center; gap: 6px;
    background: transparent; color: #d8d2c5;
    border: 1px solid rgba(216,210,197,.35);
    border-radius: 999px;
    padding: 4px 10px;
    font: inherit; font-size: 11px;
    letter-spacing: .12em; text-transform: uppercase;
    cursor: pointer;
    transition: background .2s, color .2s, border-color .2s;
}
.lang-btn:hover, .lang-switcher.is-open .lang-btn {
    background: rgba(255,255,255,.08); color: #fff; border-color: rgba(216,210,197,.7);
}
.lang-flag { font-size: 14px; line-height: 1; letter-spacing: 0; }
.lang-short { font-weight: 600; }
.lang-caret { font-size: 10px; opacity: .8; }
/* ----- Modal del selector de idioma ----- */
.lang-modal {
    position: fixed;
    inset: 0;
    z-index: 99999;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    opacity: 0;
    visibility: hidden;
    transition: opacity .2s ease, visibility .2s ease;
}
.lang-modal[hidden] { display: none; }
.lang-modal.is-open { opacity: 1; visibility: visible; }
.lang-modal-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(20, 17, 13, .55);
    backdrop-filter: blur(4px);
    cursor: pointer;
}
.lang-modal-panel {
    position: relative;
    background: #fff;
    color: var(--c-ink);
    border-radius: 12px;
    box-shadow: 0 24px 80px rgba(0, 0, 0, .35);
    width: min(680px, 100%);
    max-height: calc(100vh - 40px);
    display: flex;
    flex-direction: column;
    transform: scale(.96) translateY(8px);
    transition: transform .2s ease;
}
.lang-modal.is-open .lang-modal-panel { transform: scale(1) translateY(0); }
.lang-modal-head {
    display: flex; align-items: center; justify-content: space-between;
    padding: 18px 22px;
    border-bottom: 1px solid var(--c-line);
}
.lang-modal-head h3 {
    margin: 0;
    font-family: var(--f-serif);
    font-size: 22px;
    font-weight: 500;
    letter-spacing: 0;
    text-transform: none;
    color: var(--c-ink);
}
.lang-modal-close {
    background: none; border: none;
    font-size: 28px; line-height: 1;
    color: var(--c-muted);
    cursor: pointer; padding: 4px 10px;
    border-radius: 6px;
}
.lang-modal-close:hover { background: var(--c-bg-alt); color: var(--c-ink); }
.lang-modal-grid {
    padding: 18px;
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 8px;
    overflow-y: auto;
}
.lang-modal-item {
    display: flex; align-items: center; gap: 12px;
    padding: 12px 14px;
    border: 1px solid var(--c-line);
    border-radius: 8px;
    color: var(--c-ink-soft);
    font-size: 14px;
    text-transform: none; letter-spacing: 0;
    line-height: 1.2;
    background: #fff;
    transition: background .15s, border-color .15s, color .15s, transform .15s;
}
.lang-modal-item:hover {
    background: var(--c-bg-alt);
    border-color: var(--c-gold);
    color: var(--c-ink);
    transform: translateY(-1px);
}
.lang-modal-item.is-active {
    background: var(--c-ink);
    color: #fff;
    border-color: var(--c-ink);
    font-weight: 500;
}
.lang-modal-item.is-active:hover { background: #1c1611; transform: translateY(-1px); }
.lang-modal-item .lang-flag-img,
.lang-btn .lang-flag-img {
    border-radius: 2px;
    box-shadow: 0 0 0 1px rgba(0, 0, 0, .08);
    flex-shrink: 0;
    object-fit: cover;
    display: inline-block;
    vertical-align: middle;
}
.lang-btn .lang-flag-img { width: 22px; height: 16px; }
.lang-modal-item .lang-flag-img { width: 28px; height: 21px; }
.lang-modal-item .lang-modal-name {
    font-family: var(--f-sans);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

@media (max-width: 720px) {
    .lang-modal-grid {
        grid-template-columns: repeat(2, 1fr);
        padding: 14px;
        gap: 6px;
    }
    .lang-modal-item { padding: 10px 12px; font-size: 13px; }
    .lang-modal-head { padding: 14px 18px; }
    .lang-modal-head h3 { font-size: 18px; }
}
@media (max-width: 420px) {
    .lang-modal-grid { grid-template-columns: 1fr; }
}

/* ----- Conversión de divisa ----- */
.price-eur { font-weight: inherit; color: inherit; }
.price-converted {
    display: inline-block;
    color: var(--c-muted);
    font-weight: 400;
    font-size: .78em;
    margin-left: 6px;
    white-space: nowrap;
    letter-spacing: 0;
    text-transform: none;
    cursor: help;
    opacity: .9;
}
/* Dentro del precio rebajado (rojo) la conversión se mantiene en gris para que se lea bien */
.precio-oferta .price-converted,
.product-card .pc-precio .precio-oferta .price-converted,
.product-info .precio-grande .oferta .price-converted,
.precio-grande .oferta .price-converted {
    color: var(--c-muted) !important;
    font-weight: 400;
}
.product-card .pc-precio { line-height: 1.4; }
.product-card .pc-precio .price-converted { font-size: 12px; }
.product-info .precio-grande .price-converted {
    font-size: 14px;
    color: var(--c-muted);
    margin-left: 10px;
    vertical-align: middle;
    font-weight: 400;
    display: inline-block;
}
.cart-summary .row.total .price-converted {
    font-size: 12px;
    margin-left: 6px;
    font-weight: 400;
}
.currency-note {
    margin: 10px 0 0;
    font-size: 12px;
    color: var(--c-muted);
    line-height: 1.5;
    max-width: 480px;
}
[dir="rtl"] .price-converted { margin-left: 0; margin-right: 6px; }

/* En móvil, conversión en segunda línea para que las cards respiren */
@media (max-width: 480px) {
    .pc-precio { display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 6px; }
    .pc-precio .price-converted { flex-basis: 100%; margin-left: 0; font-size: 11px; }
    .product-info .precio-grande .price-converted { display: block; margin: 4px 0 0; font-size: 13px; }
}

/* ----- Soporte RTL (árabe, urdu) ----- */
[dir="rtl"] body { text-align: right; }
[dir="rtl"] .header-actions,
[dir="rtl"] .nav-main { direction: rtl; }
[dir="rtl"] .filters,
[dir="rtl"] .footer-grid,
[dir="rtl"] .breadcrumb { direction: rtl; }
[dir="rtl"] .product-card,
[dir="rtl"] .pc-meta { text-align: right; }
[dir="rtl"] .cart-badge { margin-left: 0; margin-right: 4px; }

/* ----- Header ----- */
.header {
    position: sticky; top: 0; z-index: 100;
    background: var(--c-bg);
    border-bottom: 1px solid var(--c-line);
    backdrop-filter: blur(6px);
}
.header-inner {
    max-width: 1280px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    align-items: center;
    padding: 16px 24px;
    gap: 24px;
}
.brand {
    grid-column: 2;
    text-align: center;
    font-family: var(--f-serif);
    font-size: 26px;
    letter-spacing: .35em;
    text-transform: uppercase;
    font-weight: 500;
}
.brand .dot { color: var(--c-gold); }
.nav-main {
    display: flex; gap: 28px; align-items: center;
}
.nav-main a {
    font-size: 13px; letter-spacing: .12em; text-transform: uppercase; font-weight: 500;
}
.header-actions {
    display: flex; gap: 18px; justify-content: flex-end; align-items: center;
}
.header-actions a {
    font-size: 13px; letter-spacing: .12em; text-transform: uppercase;
    display: inline-flex; align-items: center; gap: 6px;
}
.cart-badge {
    display: inline-block; min-width: 18px; height: 18px; line-height: 18px;
    text-align: center; background: var(--c-gold); color: #fff;
    border-radius: 50%; font-size: 11px; padding: 0 5px;
}
.menu-toggle { display: none; background: none; border: 0; font-size: 20px; cursor: pointer; }

/* ----- Hero ----- */
.hero {
    background: linear-gradient(135deg, #15110d 0%, #2a221a 100%);
    color: #efe7d4;
    padding: clamp(80px, 12vw, 160px) 24px;
    text-align: center;
    position: relative;
    overflow: hidden;
}
.hero::before {
    content: '';
    position: absolute; inset: 0;
    background: radial-gradient(circle at 30% 40%, rgba(176,141,87,.15), transparent 60%);
    pointer-events: none;
}
.hero h1 {
    font-size: clamp(2.5rem, 6vw, 5rem);
    font-weight: 400; max-width: 18ch; margin: 0 auto .8rem;
}
.hero p {
    color: #c9c1b3; max-width: 520px; margin: 0 auto 2rem;
    font-size: 17px;
}
.hero .eyebrow { color: var(--c-gold); }

/* ----- Botones ----- */
.btn {
    display: inline-block; padding: 14px 32px;
    font-size: 13px; letter-spacing: .2em; text-transform: uppercase; font-weight: 600;
    border: 1px solid var(--c-ink); background: var(--c-ink); color: #fff;
    cursor: pointer; transition: all .2s; border-radius: var(--radius);
    text-decoration: none;
}
.btn:hover { background: var(--c-gold-dark); border-color: var(--c-gold-dark); color: #fff; }
.btn-outline { background: transparent; color: var(--c-ink); }
.btn-outline:hover { background: var(--c-ink); color: #fff; }
.btn-gold { background: var(--c-gold); border-color: var(--c-gold); }
.btn-gold:hover { background: var(--c-gold-dark); }
.btn-light { background: #fff; color: var(--c-ink); border-color: #fff; }
.btn-light:hover { background: var(--c-gold); color: #fff; border-color: var(--c-gold); }
.btn-sm { padding: 9px 18px; font-size: 11px; }
.btn-block { display: block; width: 100%; text-align: center; }
.btn[disabled], .btn:disabled { opacity: .5; cursor: not-allowed; }

/* ----- Container ----- */
.container { max-width: 1280px; margin: 0 auto; padding: 0 24px; }
.section { padding: clamp(60px, 9vw, 110px) 0; }
.section-title { text-align: center; margin-bottom: 60px; }
.section-title h2 { margin: 0 0 .3em; }
.section-title p { color: var(--c-muted); max-width: 540px; margin: 0 auto; }

/* ----- Grid productos ----- */
.products-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
    gap: 36px 24px;
}
.product-card {
    text-align: center;
    transition: transform .25s;
    position: relative;
}
.product-card:hover { transform: translateY(-4px); }
.product-card .pc-img-wrap {
    aspect-ratio: 4/5;
    background: var(--c-bg-alt);
    overflow: hidden;
    margin-bottom: 18px;
    position: relative;
}
.product-card img {
    width: 100%; height: 100%; object-fit: cover;
    transition: transform .6s ease;
}
.product-card:hover img { transform: scale(1.05); }
.product-card .pc-tags {
    position: absolute; top: 12px; left: 12px;
    display: flex; flex-direction: column; gap: 6px;
    z-index: 2;
}
.tag {
    font-size: 10px; letter-spacing: .2em; text-transform: uppercase;
    background: var(--c-ink); color: #fff; padding: 5px 9px; font-weight: 600;
}
.tag-gold { background: var(--c-gold); }
.tag-sale { background: var(--c-danger); }
.tag-agotado { background: #6c757d; }

.product-card.is-agotado .pc-img-wrap img { filter: grayscale(.6) brightness(.92); opacity: .75; }
.product-card.is-agotado .pc-precio { color: var(--c-muted); text-decoration: line-through; text-decoration-thickness: 1px; }
.product-card.is-agotado .pc-nombre { color: var(--c-muted); }

.agotado-box {
    background: #f7f5f1; border: 1px solid var(--c-line); padding: 18px 20px;
    border-radius: 6px; margin: 18px 0;
}
.agotado-box strong { display: block; font-family: var(--f-serif); font-size: 18px; color: var(--c-ink); margin-bottom: 4px; }
.agotado-box p { margin: 0 0 12px; font-size: 14px; color: var(--c-muted); }

/* ----------------- Pestañas de tipo en /productos.php ----------------- */
.tipo-tabs {
    display: flex; flex-wrap: wrap; gap: 6px;
    margin: 0 0 24px;
    padding: 8px;
    background: var(--c-bg-alt);
    border: 1px solid var(--c-line);
    border-radius: 6px;
}
.tipo-tab {
    display: inline-flex; align-items: center; gap: 6px;
    padding: 9px 16px;
    border-radius: 4px;
    font-size: 13px;
    font-weight: 500;
    letter-spacing: .03em;
    color: var(--c-ink-soft);
    text-decoration: none;
    transition: all .15s ease;
    border: 1px solid transparent;
}
.tipo-tab:hover {
    background: #fff;
    color: var(--c-ink);
    border-color: var(--c-line);
}
.tipo-tab.active {
    background: var(--c-ink);
    color: #fff;
    border-color: var(--c-ink);
}
.tipo-tab small {
    font-size: 11px;
    opacity: .7;
    font-weight: 400;
}
.tipo-tab.active small { opacity: .85; }

@media (max-width: 720px) {
    .tipo-tabs { padding: 6px; gap: 4px; }
    .tipo-tab  { padding: 7px 11px; font-size: 12px; }
}

/* Tag de tipo dentro de las tarjetas de cosmética */
.pc-tipo-tag {
    font-size: 10px;
    letter-spacing: .15em;
    text-transform: uppercase;
    color: var(--c-gold-dark, #b08d57);
    font-weight: 600;
}
.product-card .pc-marca {
    font-size: 11px; letter-spacing: .2em; text-transform: uppercase;
    color: var(--c-muted); margin-bottom: 4px;
}
.product-card .pc-nombre {
    font-family: var(--f-serif); font-size: 19px; margin-bottom: 6px;
    color: var(--c-ink);
}
.product-card .pc-precio {
    font-size: 15px; color: var(--c-ink); font-weight: 500;
}
.product-card .pc-precio del { color: var(--c-muted); margin-right: 8px; font-weight: 400; }
.product-card .pc-precio .precio-oferta { color: var(--c-danger); }
.product-card .stars { color: var(--c-gold); letter-spacing: 2px; font-size: 13px; }

/* ----- Page header ----- */
.page-header {
    background: var(--c-bg-alt);
    padding: 60px 24px 50px;
    text-align: center;
    border-bottom: 1px solid var(--c-line);
}
.breadcrumb {
    font-size: 12px; letter-spacing: .15em; text-transform: uppercase;
    color: var(--c-muted); margin-bottom: 12px;
}
.breadcrumb a { color: var(--c-muted); }
.breadcrumb a:hover { color: var(--c-ink); }

/* ----- Producto detalle ----- */
.product-detail { display: grid; grid-template-columns: 1fr 1fr; gap: 80px; padding: 60px 0; }
.product-gallery .main-img { aspect-ratio: 4/5; background: var(--c-bg-alt); margin-bottom: 14px; overflow: hidden; }
.product-gallery .main-img img { width: 100%; height: 100%; object-fit: cover; }
.product-thumbs { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; }
.product-thumbs img { aspect-ratio: 1; object-fit: cover; cursor: pointer; opacity: .8; }
.product-thumbs img:hover, .product-thumbs img.active { opacity: 1; outline: 2px solid var(--c-gold); }

.product-info .precio-grande { font-family: var(--f-serif); font-size: 32px; margin: 18px 0; }
.product-info .precio-grande del { color: var(--c-muted); margin-right: 14px; font-size: 22px; font-weight: 400; }
.product-info .precio-grande .oferta { color: var(--c-danger); }
.notas { display: grid; gap: 14px; margin: 20px 0; }
.nota-piramide { padding: 14px 18px; background: var(--c-bg-alt); border-left: 3px solid var(--c-gold); }
.nota-piramide strong {
    font-size: 11px; letter-spacing: .25em; text-transform: uppercase; color: var(--c-gold-dark); display: block; margin-bottom: 4px;
}
.qty-cart { display: flex; gap: 12px; margin: 26px 0; align-items: stretch; }
.qty-input {
    width: 80px; padding: 12px; border: 1px solid var(--c-line); text-align: center; font-size: 15px; font-family: inherit;
}

/* ----- Tabs ----- */
.tabs { border-top: 1px solid var(--c-line); margin-top: 40px; padding-top: 30px; }
.tab-nav { display: flex; gap: 30px; margin-bottom: 24px; flex-wrap: wrap; }
.tab-nav button {
    background: none; border: 0; padding: 8px 0;
    font-size: 12px; letter-spacing: .2em; text-transform: uppercase; font-weight: 600;
    color: var(--c-muted); cursor: pointer; border-bottom: 2px solid transparent; font-family: inherit;
}
.tab-nav button.active { color: var(--c-ink); border-color: var(--c-gold); }
.tab-content { display: none; }
.tab-content.active { display: block; }

/* ----- Reviews ----- */
.review {
    border-bottom: 1px solid var(--c-line);
    padding: 22px 0;
}
.review-head {
    display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 8px;
    margin-bottom: 8px;
}
.review-head strong { font-size: 14px; }
.review-head .stars { color: var(--c-gold); }
.review-head time { color: var(--c-muted); font-size: 12px; }
.review p { margin: 6px 0 0; color: var(--c-ink-soft); }
.review-respuesta {
    margin-top: 14px; padding: 12px 16px; background: var(--c-bg-alt);
    font-size: 14px; border-left: 3px solid var(--c-gold);
}

/* ----- Forms ----- */
.form-row { margin-bottom: 18px; }
.form-row label {
    display: block; font-size: 12px; letter-spacing: .15em; text-transform: uppercase;
    margin-bottom: 7px; color: var(--c-ink-soft); font-weight: 600;
}
.input, .select, .textarea {
    width: 100%; padding: 12px 14px;
    border: 1px solid var(--c-line); background: #fff;
    font-size: 15px; font-family: inherit; color: var(--c-ink);
    border-radius: var(--radius); transition: border-color .2s;
}
.input:focus, .select:focus, .textarea:focus { outline: none; border-color: var(--c-gold); }
.textarea { resize: vertical; min-height: 110px; }
.form-grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
.form-check { display: flex; align-items: flex-start; gap: 10px; font-size: 14px; color: var(--c-ink-soft); }
.form-check input { margin-top: 3px; }
.help-text { font-size: 12px; color: var(--c-muted); margin-top: 6px; }

/* Auth boxes */
.auth-box {
    max-width: 460px; margin: 80px auto;
    background: #fff; padding: 50px 44px; border: 1px solid var(--c-line); box-shadow: var(--shadow-md);
    border-radius: var(--radius-lg);
}
.auth-box h1 { text-align: center; font-size: 28px; margin-bottom: 8px; }
.auth-box .sub { text-align: center; color: var(--c-muted); margin-bottom: 30px; }
.auth-box .alt-link { text-align: center; margin-top: 20px; font-size: 14px; color: var(--c-muted); }

/* Alerts */
.alert {
    padding: 14px 18px; margin-bottom: 20px;
    border-radius: var(--radius); border: 1px solid;
    font-size: 14px;
}
.alert-success { background: #eef7f1; border-color: #c4e2cf; color: var(--c-success); }
.alert-error   { background: #fbeae6; border-color: #ecbcae; color: var(--c-danger); }
.alert-warning { background: #fdf3df; border-color: #ecd690; color: #7a5605; }
.alert-info    { background: #eef0f6; border-color: #cdd2e1; color: #314062; }

/* Tabla simple */
.table { width: 100%; border-collapse: collapse; }
.table th, .table td {
    padding: 12px 14px; text-align: left;
    border-bottom: 1px solid var(--c-line); vertical-align: middle;
}
.table th {
    font-size: 11px; letter-spacing: .2em; text-transform: uppercase;
    color: var(--c-ink-soft); font-weight: 600; background: var(--c-bg-alt);
}

/* Cart resumen */
.cart-summary {
    background: var(--c-bg-alt); padding: 30px;
    border-radius: var(--radius-lg);
}
.cart-summary .row { display: flex; justify-content: space-between; padding: 8px 0; }
.cart-summary .row.total { border-top: 1px solid var(--c-line); margin-top: 12px; padding-top: 18px; font-size: 17px; font-weight: 600; font-family: var(--f-serif); }

/* ----- Filtros ----- */
.shop-layout { display: grid; grid-template-columns: 260px 1fr; gap: 50px; align-items: flex-start; }
.filters { position: sticky; top: 90px; }
.filters h4 {
    font-size: 12px; letter-spacing: .2em; text-transform: uppercase;
    color: var(--c-ink); margin: 0 0 14px; padding-bottom: 8px; border-bottom: 1px solid var(--c-line); font-family: var(--f-sans); font-weight: 600;
}
.filter-section { margin-bottom: 26px; }
.filter-list { list-style: none; margin: 0; padding: 0; }
.filter-list li { padding: 5px 0; font-size: 14px; }
.filter-list li a { color: var(--c-ink-soft); display: inline-block; }
.filter-list li a:hover, .filter-list li a.active { color: var(--c-gold-dark); font-weight: 600; }
.filters ul { list-style: none; margin: 0; padding: 0; }
.filter-checks { display: flex; flex-direction: column; gap: 7px; }
.filter-checks label { display: flex; align-items: center; gap: 8px; font-size: 14px; color: var(--c-ink-soft); cursor: pointer; }
.filter-checks input[type="checkbox"] { accent-color: var(--c-gold-dark); width: 15px; height: 15px; }
.filter-checks label:hover span { color: var(--c-gold-dark); }
.btn-block { display: block; width: 100%; text-align: center; }

.results-bar { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 12px; margin-bottom: 22px; }
.results-count { color: var(--c-muted); font-size: 14px; }
.results-count strong { color: var(--c-ink); font-size: 16px; }
.orden-form { display: inline-flex; }
.orden-form .select { width: auto; min-width: 200px; }

.chips-bar { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 22px; padding-bottom: 18px; border-bottom: 1px solid var(--c-line); }
.chip {
    display: inline-flex; align-items: center; gap: 6px;
    padding: 5px 12px; background: var(--c-bg-alt); border: 1px solid var(--c-line);
    border-radius: 999px; font-size: 12px; color: var(--c-ink-soft);
    text-decoration: none; transition: all .18s;
}
.chip:hover { background: #ede4d6; border-color: var(--c-gold); color: var(--c-ink); }
.chip span { font-weight: 600; opacity: .6; font-size: 14px; }
.chip-clear { background: transparent; border-color: var(--c-line); }
.chip-clear:hover { background: var(--c-ink); color: #fff; border-color: var(--c-ink); }

.product-card .pc-meta { font-size: 12px; color: var(--c-muted); margin: 4px 0 6px; letter-spacing: .04em; }

.pagination {
    display: flex; gap: 6px; flex-wrap: wrap; justify-content: center;
    margin-top: 50px; padding-top: 30px; border-top: 1px solid var(--c-line);
}
.pagination a, .pagination span {
    min-width: 40px; height: 40px; padding: 0 12px;
    display: inline-flex; align-items: center; justify-content: center;
    border: 1px solid var(--c-line); color: var(--c-ink-soft);
    text-decoration: none; font-size: 14px; border-radius: var(--radius);
    transition: all .15s;
}
.pagination a:hover { border-color: var(--c-gold); color: var(--c-gold-dark); }
.pagination .active { background: var(--c-ink); color: #fff; border-color: var(--c-ink); font-weight: 600; }
.pagination .pag-sep { border: 0; min-width: 24px; }

/* ----- Footer ----- */
.footer {
    background: var(--c-ink); color: #c9c1b3;
    padding: 70px 24px 30px; margin-top: 80px;
    font-size: 14px;
}
.footer-grid {
    max-width: 1280px; margin: 0 auto;
    display: grid; grid-template-columns: 1.6fr 1fr 1fr 1fr; gap: 48px;
}
.footer h5 {
    font-family: var(--f-sans); font-size: 12px; letter-spacing: .25em;
    text-transform: uppercase; color: #fff; margin: 0 0 18px; font-weight: 600;
}
.footer a { color: #c9c1b3; }
.footer a:hover { color: var(--c-gold); }
.footer ul { list-style: none; padding: 0; margin: 0; }
.footer li { padding: 4px 0; }
.footer .brand-large { font-family: var(--f-serif); font-size: 28px; letter-spacing: .35em; color: #fff; margin-bottom: 14px; }
.footer-bottom {
    max-width: 1280px; margin: 50px auto 0;
    border-top: 1px solid #2c2620;
    padding-top: 24px;
    display: flex; justify-content: space-between; flex-wrap: wrap; gap: 16px;
    color: #8a8278; font-size: 12px;
}
.newsletter-form { display: flex; gap: 0; margin-top: 14px; }
.newsletter-form input {
    flex: 1; padding: 12px 14px; border: 1px solid #3a3128; background: #2a2620; color: #fff;
    border-right: 0;
}
.newsletter-form button {
    padding: 12px 18px; background: var(--c-gold); color: #fff; border: 0; cursor: pointer;
    font-size: 11px; letter-spacing: .2em; text-transform: uppercase; font-weight: 600;
}
.newsletter-form button:hover { background: var(--c-gold-dark); }

/* Cookie banner */
.cookie-banner {
    position: fixed; bottom: 16px; left: 16px; right: 16px;
    background: #fff; border: 1px solid var(--c-line); padding: 18px 24px;
    box-shadow: var(--shadow-lg); border-radius: var(--radius-lg);
    z-index: 999; max-width: 720px; margin: 0 auto;
    display: flex; gap: 18px; align-items: center; flex-wrap: wrap;
}
.cookie-banner p { margin: 0; flex: 1; min-width: 220px; font-size: 14px; }

/* ----- Menú móvil (drawer) ----- */
.nav-mobile {
    position: fixed;
    top: 0; left: 0; right: 0; bottom: 0;
    z-index: 9999;
    display: flex;
    opacity: 0;
    visibility: hidden;
    transition: opacity .2s ease, visibility .2s ease;
}
.nav-mobile[hidden] { display: none; }
.nav-mobile.is-open { opacity: 1; visibility: visible; }
.nav-mobile-backdrop {
    position: absolute;
    top: 0; left: 0; right: 0; bottom: 0;
    background: rgba(20, 17, 13, .55);
    backdrop-filter: blur(4px);
    cursor: pointer;
}
.nav-mobile-panel {
    position: relative;
    background: #fff;
    color: var(--c-ink);
    width: min(420px, 92%);
    max-width: 100%;
    height: 100%;
    margin-left: auto;
    box-shadow: -10px 0 30px rgba(0, 0, 0, .25);
    overflow-y: auto;
    transform: translateX(100%);
    transition: transform .25s ease;
    padding: 60px 22px 30px;
}
.nav-mobile.is-open .nav-mobile-panel { transform: translateX(0); }
.nav-close {
    position: absolute;
    top: 12px; right: 14px;
    background: none; border: 0;
    font-size: 32px; line-height: 1;
    color: var(--c-ink);
    cursor: pointer; padding: 6px 12px;
    border-radius: 6px;
}
.nav-close:hover { background: var(--c-bg-alt); }
.nav-mobile-list {
    list-style: none;
    margin: 0; padding: 0;
}
.nav-mobile-list li {
    border-bottom: 1px solid var(--c-line);
}
.nav-mobile-list li:last-child { border-bottom: 0; }
.nav-mobile-list a {
    display: block;
    padding: 18px 6px;
    font-size: 15px;
    letter-spacing: .15em;
    text-transform: uppercase;
    color: var(--c-ink);
    font-weight: 500;
}
.nav-mobile-list a:hover,
.nav-mobile-list a:active { color: var(--c-gold-dark); }
.nav-mobile-list a.is-deals { color: var(--c-gold-dark); font-weight: 600; }

/* Bloquear scroll del body cuando el drawer está abierto */
body.nav-open { overflow: hidden; }

/* Responsive */
@media (max-width: 900px) {
    .header-inner { grid-template-columns: auto 1fr auto; }
    /* Ocultar el menú horizontal de desktop en móvil */
    .nav-main-desktop { display: none; }
    .menu-toggle { display: block; }

    .product-detail { grid-template-columns: 1fr; gap: 40px; }
    .footer-grid { grid-template-columns: 1fr 1fr; }
    .shop-layout { grid-template-columns: 1fr; gap: 30px; }
    .filters { position: static; }
    .form-grid-2 { grid-template-columns: 1fr; }
    .results-bar { flex-direction: column; align-items: flex-start; }
    .orden-form .select { width: 100%; }
}
@media (max-width: 600px) {
    .footer-grid { grid-template-columns: 1fr; }
    .header-actions a span { display: none; }
    .auth-box { margin: 30px 16px; padding: 32px 22px; }
}

/* ==========================================================
   AJUSTES PARA MÓVIL
   - Márgenes laterales coherentes en todos los componentes
   - Topbar con selector de idioma en flujo natural (sin overlap)
   - Header sticky compacto
   - Page-header reducido para que el contenido principal sea visible
   ========================================================== */

/* Tablets y móviles grandes */
@media (max-width: 900px) {
    .container       { padding: 0 22px; }
    .section         { padding: clamp(36px, 6vw, 60px) 0; }
    .footer          { padding: 50px 22px 28px; }
    .header-inner    { padding: 12px 22px; gap: 14px; }
    .brand           { font-size: 22px; letter-spacing: .3em; }
    .header-actions  { gap: 12px; }

    /* Topbar: el selector de idioma sale del flujo absoluto y se coloca a la derecha */
    .topbar {
        flex-wrap: nowrap;
        justify-content: space-between;
        align-items: center;
        gap: 12px;
        padding: 10px 22px;
        font-size: 11px;
        line-height: 1.4;
    }
    .topbar .topbar-msg {
        flex: 1 1 auto;
        min-width: 0;
        text-align: left;
        padding: 0;
        line-height: 1.35;
        white-space: normal;
        overflow: visible;
    }
    .lang-switcher {
        position: static;
        transform: none;
        flex: 0 0 auto;
    }

    /* Cabecera de página (breadcrumb + título) */
    .page-header { padding: 30px 22px 26px; }
    .page-header h1 { font-size: clamp(1.6rem, 5vw, 2.2rem); margin: 0 0 .25em; }
    .breadcrumb { font-size: 11px; margin-bottom: 8px; }
}

/* Móviles estándar */
@media (max-width: 600px) {
    .container       { padding: 0 18px; }
    .section         { padding: clamp(28px, 5vw, 48px) 0; }
    .footer          { padding: 40px 18px 24px; }
    .header-inner    { padding: 10px 18px; gap: 10px; }
    .brand           { font-size: 19px; letter-spacing: .25em; }

    .topbar          { padding: 9px 18px; font-size: 10.5px; letter-spacing: .04em; gap: 10px; }
    .topbar-msg-full { display: none; }
    .topbar-msg-short{ display: inline; }
    .lang-btn        { padding: 4px 9px; font-size: 10.5px; gap: 5px; }
    .lang-btn .lang-flag-img { width: 18px; height: 13px; }
    .lang-caret      { display: none; }

    .page-header     { padding: 22px 18px 20px; border-bottom: 0; }
    .page-header h1  { font-size: clamp(1.4rem, 6vw, 1.9rem); }
    .page-header p   { font-size: 13px; }

    .shop-layout     { gap: 20px; }
    .filters h4      { margin-bottom: 10px; }
    .filter-section  { margin-bottom: 18px; }
    .results-bar     { margin-bottom: 14px; }
    .chips-bar       { margin-bottom: 14px; padding-bottom: 12px; gap: 6px; }
    .pagination      { margin-top: 34px; padding-top: 20px; }
    .products-grid   { gap: 22px 14px; }
    .tipo-tabs       { margin: 0 0 18px; flex-wrap: wrap; }
    .product-detail  { gap: 26px; padding: 30px 0; }
    .cart-item       { gap: 12px; padding: 14px 0; }
}

/* Móviles pequeños */
@media (max-width: 420px) {
    .container       { padding: 0 16px; }
    .footer          { padding: 36px 16px 22px; }
    .header-inner    { padding: 9px 16px; gap: 8px; }
    .topbar          { padding: 7px 16px; }
    .page-header     { padding: 18px 16px; }
    .brand           { font-size: 18px; letter-spacing: .22em; }

    .products-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 18px 12px;
    }
    .product-card .pc-nombre { font-size: 15px; }
    .product-card .pc-marca  { font-size: 10px; }
}
