:root {
    --bg: #FAF7F2;
    --surface: #FFFFFF;
    --ink: #2B2118;
    --muted: #6E6257;
    --terracotta: #C85A32;
    --ochre: #D99B26;
    --forest: #2F5233;
    --border: #E6DFD3;
    --radius: 14px;
}

* { box-sizing: border-box; margin: 0; padding: 0; }
body { font-family: system-ui, -apple-system, sans-serif; background: var(--bg); color: var(--ink); line-height: 1.6; }
a { text-decoration: none; color: inherit; }

header.topbar {
    background: var(--surface);
    border-bottom: 1px solid var(--border);
    position: sticky;
    top: 0;
    z-index: 100;
    padding: 0.8rem 5%;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.brand-trigger { display: flex; align-items: center; gap: 12px; cursor: pointer; user-select: none; }
.brand-logo-img {
    height: 48px;
    width: auto;
    max-width: 140px;
    object-fit: contain;
    border-radius: 8px;
}
.brand-title { font-family: Georgia, serif; font-size: 1.25rem; font-weight: bold; }

.header-actions { display: flex; align-items: center; gap: 12px; }
.cart-pill { background: var(--ink); color: #fff; padding: 0.45rem 0.9rem; border-radius: 99px; font-size: 0.9rem; font-weight: 600; }
.menu-toggle { background: var(--bg); border: 1px solid var(--border); padding: 0.5rem 0.9rem; border-radius: 10px; font-size: 0.95rem; cursor: pointer; font-weight: 600; }

.drawer-menu {
    display: none; background: var(--surface); border-bottom: 1px solid var(--border);
    padding: 1rem 5%; flex-direction: column; gap: 0.5rem;
}
.drawer-menu.open { display: flex; }
.drawer-menu a { padding: 0.65rem 1rem; border-radius: 8px; font-weight: 600; }
.drawer-menu a:hover, .drawer-menu a.active { background: var(--bg); color: var(--terracotta); }

.container { max-width: 1120px; margin: 0 auto; padding: 2rem 5%; }

.hero-editorial {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 22px;
    padding: 2.2rem;
    text-align: center;
    margin-bottom: 2.5rem;
}
.hero-bw-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 1.2rem;
    margin-bottom: 1.5rem;
    align-items: center;
}
.hero-bw-grid img {
    width: 100%;
    max-height: 240px;
    object-fit: contain;
    border-radius: 14px;
    border: 1px solid var(--border);
    background: #fff;
    padding: 0.5rem;
}
.hero-editorial h1 { font-family: Georgia, serif; font-size: clamp(1.7rem, 3.5vw, 2.6rem); line-height: 1.2; margin-bottom: 0.8rem; }
.hero-editorial p { max-width: 660px; margin: 0 auto 1.4rem; color: var(--muted); font-size: 1.02rem; }

.btn { display: inline-block; background: var(--terracotta); color: #fff; padding: 0.7rem 1.4rem; border-radius: 99px; font-weight: 600; border: none; cursor: pointer; }
.btn-forest { background: var(--forest); }
.btn-outline { background: transparent; border: 1px solid var(--ink); color: var(--ink); }

.cat-bar { display: flex; flex-wrap: wrap; gap: 10px; margin-bottom: 2rem; justify-content: center; }
.cat-chip { padding: 0.45rem 1.1rem; border-radius: 99px; border: 1px solid var(--border); background: var(--surface); font-weight: 600; font-size: 0.9rem; }
.cat-chip.active { background: var(--ink); color: #fff; border-color: var(--ink); }

.grid-productos { display: grid; grid-template-columns: repeat(auto-fill, minmax(255px, 1fr)); gap: 1.6rem; }
.card-prod { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); overflow: hidden; display: flex; flex-direction: column; }
.card-prod img { width: 100%; height: 245px; object-fit: cover; background: #EFEAE1; }
.card-body { padding: 1.15rem; flex: 1; display: flex; flex-direction: column; }
.card-cat { font-size: 0.75rem; text-transform: uppercase; color: var(--terracotta); font-weight: 700; }
.card-title { font-family: Georgia, serif; font-size: 1.15rem; margin: 0.3rem 0; }
.card-desc { font-size: 0.9rem; color: var(--muted); margin-bottom: 1rem; flex: 1; }
.card-footer { display: flex; justify-content: space-between; align-items: center; padding-top: 0.75rem; border-top: 1px solid var(--border); }
.price { font-weight: 800; font-size: 1.1rem; color: var(--forest); }

footer { text-align: center; padding: 2.5rem 5%; border-top: 1px solid var(--border); margin-top: 4rem; color: var(--muted); font-size: 0.9rem; }

@media print {
    body { background: #fff !important; color: #000 !important; }
    .no-print { display: none !important; }
    .factura-box { border: 1px solid #000 !important; box-shadow: none !important; width: 100% !important; max-width: 100% !important; }
}