@import url('https://fonts.googleapis.com/css2?family=DM+Sans:wght@400;500;600;700&family=Playfair+Display:wght@500;600;700&display=swap');
:root {
    --wine:#522337;
    --deep:#291923;
    --gold:#b18b60;
    --cream:#f8f5ef;
    --ink:#302a2c;
    --muted:#756b6d;
    --line:#e9e1dc;
    font-family:'DM Sans',Arial,sans-serif;
    color:var(--ink);
    background:var(--cream)
}

* {
    box-sizing:border-box
}

html {
    scroll-behavior:smooth
}

body {
    margin:0
}

button,input,select,textarea {
    font:inherit
}

button,.btn {
    transition:background .2s,transform .2s,box-shadow .2s
}

button:focus-visible,a:focus-visible,input:focus-visible,select:focus-visible,textarea:focus-visible {
    outline:3px solid #c69b68;
    outline-offset:2px
}

header {
    background:#fffdfbf5;
    backdrop-filter:blur(12px);
    display:flex;
    align-items:center;
    justify-content:space-between;
    gap:22px;
    padding:18px max(5%,calc((100% - 1200px)/2));
    position:sticky;
    top:0;
    z-index:3;
    box-shadow:0 2px 16px #2e18200d;
    border-bottom:1px solid var(--line)
}

.brand {
    font-size:29px;
    font-weight:700;
    letter-spacing:-1.4px;
    color:var(--deep);
    text-decoration:none;
    line-height:1
}

.brand span {
    color:#a4775b
}

.brand small {
    display:block;
    font-size:9px;
    letter-spacing:2.9px;
    margin-top:6px;
    font-weight:700;
    color:#8c7479
}

nav {
    display:flex;
    align-items:center;
    gap:28px
}

nav a {
    color:#49353d;
    text-decoration:none;
    font-size:14px;
    font-weight:600
}

nav a:hover {
    color:#a4775b
}

button,.btn {
    background:var(--wine);
    color:white;
    border:1px solid var(--wine);
    border-radius:8px;
    padding:13px 19px;
    cursor:pointer;
    text-decoration:none;
    display:inline-block;
    font-weight:700;
    font-size:14px
}

button:hover,.btn:hover {
    background:#71374c;
    box-shadow:0 6px 18px #52233725
}

button:disabled {
    opacity:.5;
    cursor:not-allowed;
    box-shadow:none
}

#cartBtn {
    white-space:nowrap;
    border-radius:100px;
    padding:12px 19px
}

#count {
    display:inline-grid;
    place-items:center;
    margin-left:8px;
    border-radius:50%;
    background:#fff3e6;
    color:var(--wine);
    min-width:24px;
    height:24px;
    font-size:12px
}

.hero {
    background:linear-gradient(90deg,#22151de8 0%,#35202cbd 54%,#2919233d 100%),url('https://images.unsplash.com/photo-1510812431401-41d2bd2722f3?w=1800&q=85') center/cover;
    min-height:455px;
    color:white;
    display:flex;
    align-items:center;
    padding:75px max(5%,calc((100% - 1200px)/2))
}

.hero>div {
    max-width:660px
}

.hero p:first-child {
    letter-spacing:3px;
    font-size:11px;
    font-weight:700;
    color:#e9c6a5
}

.hero h1 {
    font-family:'Playfair Display',Georgia,serif;
    font-weight:600;
    line-height:1.13;
    font-size:clamp(39px,5vw,65px);
    margin:16px 0 20px
}

.hero p {
    line-height:1.8;
    max-width:480px;
    color:#f2e9e7
}

.hero .btn {
    margin-top:15px;
    background:#f1dfc8;
    color:#35212a;
    border-color:#f1dfc8;
    border-radius:6px;
    padding:15px 25px
}

.hero .btn:hover {
    background:white
}

main {
    max-width:1240px;
    margin:0 auto;
    padding:65px 20px 80px;
    min-height:50vh
}

main h2 {
    font-family:'Playfair Display',Georgia,serif;
    font-weight:600;
    font-size:clamp(30px,3vw,40px);
    color:var(--deep);
    margin:0 0 24px
}

#catalogo {
    scroll-margin-top:105px
}

.filters {
    display:flex;
    gap:14px;
    margin:22px 0 30px;
    padding:18px;
    background:white;
    border:1px solid var(--line);
    border-radius:12px;
    box-shadow:0 4px 18px #2e182007
}

input,select,textarea {
    padding:13px 14px;
    border:1px solid #dcd2cf;
    border-radius:8px;
    max-width:100%;
    background:#fff;
    color:var(--ink)
}

.filters input {
    flex:1;
    min-width:0
}

.filters select {
    min-width:210px
}

.grid {
    display:grid;
    grid-template-columns:repeat(auto-fill,minmax(245px,1fr));
    gap:22px
}

.product {
    background:white;
    border:1px solid var(--line);
    border-radius:13px;
    overflow:hidden;
    padding:15px;
    display:flex;
    flex-direction:column;
    gap:10px;
    box-shadow:0 3px 15px #2e182008;
    transition:transform .2s,box-shadow .2s
}

.product:hover {
    transform:translateY(-4px);
    box-shadow:0 15px 35px #2e18201c
}

.bottle {
    height:225px;
    background:linear-gradient(140deg,#faf7f1,#eee6e0);
    display:grid;
    place-items:center;
    font-size:68px;
    border-radius:9px;
    overflow:hidden
}

.bottle img {
    max-height:205px!important;
    height:205px!important;
    max-width:100%;
    object-fit:contain;
    transition:transform .3s
}

.product:hover .bottle img {
    transform:scale(1.045)
}

.product h3 {
    font-family:'Playfair Display',Georgia,serif;
    font-size:21px;
    font-weight:600;
    margin:8px 0 0;
    line-height:1.25;
    min-height:26px
}

.product p {
    margin:0;
    color:var(--muted);
    font-size:13px
}

.product small {
    color:#9c7d67;
    min-height:17px;
    font-size:12px
}

.product strong {
    font-size:23px;
    letter-spacing:-.5px;
    color:var(--wine);
    margin-top:4px
}

.product button {
    margin-top:auto;
    width:100%;
    border-radius:7px
}

.drawer {
    position:fixed;
    z-index:10;
    right:0;
    top:0;
    height:100dvh;
    width:min(475px,100%);
    background:#fffdfa;
    box-shadow:0 0 0 100vw #140a1099;
    padding:28px;
    overflow:auto
}

.drawer[hidden] {
    display:none
}

.drawer h2 {
    font-family:'Playfair Display',Georgia,serif;
    font-size:30px;
    margin:18px 0
}

.drawer h3 {
    color:var(--wine);
    padding:14px 0;
    border-top:1px solid var(--line)
}

#closeCart {
    background:transparent;
    color:var(--wine);
    border-color:var(--line);
    padding:9px 13px
}

#checkout {
    display:grid;
    gap:11px
}

#checkout input,#checkout select,#checkout textarea {
    width:100%
}

#checkout label {
    display:flex;
    align-items:flex-start;
    gap:8px;
    font-size:13px;
    color:#62545a
}

#checkout label input {
    width:auto;
    margin-top:2px
}

#checkout button[type=submit] {
    background:#276a4d;
    border-color:#276a4d;
    padding:15px
}

#checkout button[type=submit]:hover {
    background:#1d573e
}

.cartline {
    display:flex;
    justify-content:space-between;
    align-items:center;
    gap:12px;
    border-bottom:1px solid var(--line);
    padding:14px 0;
    font-size:14px
}

.cartline button {
    padding:6px 11px;
    flex-shrink:0
}

#result {
    font-size:13px;
    line-height:1.6
}

#result a {
    color:#176b4b;
    font-weight:700
}

footer {
    text-align:center;
    background:var(--deep);
    color:#e7d8d6;
    padding:35px 20px;
    margin-top:0;
    font-size:13px;
    letter-spacing:.3px
}

.adminform {
    display:flex;
    gap:8px;
    flex-wrap:wrap;
    padding:10px 0;
    border-bottom:1px solid var(--line)
}

.adminform input {
    max-width:180px
}

.order {
    display:flex;
    flex-wrap:wrap;
    align-items:center;
    gap:12px;
    padding:12px 0;
    border-bottom:1px solid var(--line)
}

@media(max-width:760px) {
    header {
        flex-wrap:wrap;
        padding:14px 18px;
        gap:12px
    }
    .brand {
        font-size:26px
    }
    nav {
        order:3;
        width:100%;
        justify-content:space-between;
        gap:8px;
        overflow-x:auto
    }
    nav a {
        font-size:12px;
        white-space:nowrap
    }
    #cartBtn {
        padding:9px 12px;
        font-size:12px
    }
    .hero {
        min-height:390px;
        padding:60px 22px
    }
    .hero h1 {
        font-size:42px
    }
    main {
        padding:45px 16px 65px
    }
    .filters {
        flex-direction:column;
        padding:12px
    }
    .filters select {
        min-width:0;
        width:100%
    }
    .grid {
        grid-template-columns:repeat(2,minmax(0,1fr));
        gap:12px
    }
    .product {
        padding:10px;
        gap:8px
    }
    .bottle {
        height:170px
    }
    .bottle img {
        height:155px!important;
        max-height:155px!important
    }
    .product h3 {
        font-size:17px
    }
    .product strong {
        font-size:19px
    }
    .product button {
        font-size:12px;
        padding:11px 6px
    }
    .drawer {
        padding:18px
    }
}

@media(max-width:390px) {
    .grid {
        grid-template-columns:1fr
    }
    .bottle {
        height:220px
    }
}

/* BodegAR — mejora visual 2: sin cambios al checkout ni a la administración */
.top-strip {
    background:#2d1923;
    color:#eee2d6;
    text-align:center;
    font-size:10px;
    letter-spacing:1.5px;
    padding:10px 14px;
    font-weight:700
}

.brand-logo {
    display:block;
    max-height:58px;
    max-width:190px;
    width:auto;
    object-fit:contain
}

.hero {
    min-height:510px
}

.hero h1 {
    font-size:clamp(42px,5.5vw,75px)
}

.hero-actions {
    display:flex;
    gap:13px;
    flex-wrap:wrap;
    align-items:center
}

.hero .btn-outline {
    background:transparent;
    color:white;
    border:1px solid #e4c7a9
}

.hero .btn-outline:hover {
    background:#ffffff25
}

.trust-bar {
    display:flex;
    justify-content:center;
    flex-wrap:wrap;
    gap:20px 48px;
    background:#f0e9e0;
    border-bottom:1px solid #e3d7cb;
    padding:20px 18px;
    color:#604751;
    font-size:12px;
    font-weight:700;
    letter-spacing:.2px
}

.promo-section {
    max-width:1240px;
    margin:70px auto 0;
    padding:0 20px;
    display:grid;
    grid-template-columns:1.2fr 1fr;
    min-height:330px
}

.promo-copy {
    padding:50px clamp(22px,5vw,65px);
    background:#321d28;
    color:white;
    border-radius:16px 0 0 16px
}

.eyebrow {
    font-size:11px;
    letter-spacing:2px;
    color:#b88d6b;
    font-weight:700
}

.promo-copy h2,.combos-section h2 {
    font-family:'Playfair Display',Georgia,serif;
    font-size:clamp(29px,3.5vw,46px);
    line-height:1.18;
    margin:14px 0
}

.promo-copy p {
    color:#e4d6d9;
    line-height:1.7;
    max-width:480px
}

.promo-copy .btn {
    background:#ead7bb;
    color:#35212a;
    border-color:#ead7bb;
    margin-top:12px
}

.promo-art {
    border-radius:0 16px 16px 0;
    background:radial-gradient(circle at 60% 45%,#9d6d66,#5b303b 54%,#291821);
    display:flex;
    justify-content:center;
    align-items:center;
    position:relative;
    overflow:hidden;
    min-height:310px
}

.promo-bottle {
    font-size:115px;
    filter:drop-shadow(12px 18px 12px #150b0f60);
    transform:rotate(-12deg)
}

.promo-stamp {
    position:absolute;
    bottom:24px;
    right:24px;
    color:#f3dfc7;
    text-align:center;
    font-family:Georgia,serif;
    font-size:30px;
    line-height:1
}

.promo-stamp small {
    font-family:Arial,sans-serif;
    font-size:9px;
    letter-spacing:2px
}

.combos-section {
    max-width:1200px;
    margin:65px auto 10px;
    padding:0 20px;
    scroll-margin-top:120px
}

.combos-section p {
    color:var(--muted)
}

.combo-links {
    display:flex;
    gap:10px;
    flex-wrap:wrap;
    margin-top:22px
}

.combo-chip {
    background:#fff;
    border:1px solid #dfc7bc;
    color:#552b3c;
    border-radius:999px;
    padding:13px 19px;
    text-decoration:none;
    font-size:13px;
    font-weight:700;
    transition:.2s
}

.combo-chip:hover {
    background:#522337;
    color:white
}

.combo-empty {
    background:#fff;
    border:1px dashed #d6bdb5;
    border-radius:12px;
    padding:18px
}

.catalog-head p {
    color:var(--muted);
    margin:-10px 0 25px
}

.catalog-head h2 {
    margin-top:10px
}

footer {
    display:flex;
    flex-direction:column;
    gap:8px
}

footer strong {
    font-family:Georgia,serif;
    font-size:27px;
    color:#f0dbc5
}

#promociones {
    scroll-margin-top:100px
}

@media(max-width:760px) {
    .top-strip {
        font-size:8px;
        letter-spacing:.7px
    }
    .promo-section {
        grid-template-columns:1fr;
        margin-top:38px;
        padding:0 15px
    }
    .promo-copy {
        border-radius:14px 14px 0 0;
        padding:32px 25px
    }
    .promo-art {
        border-radius:0 0 14px 14px;
        min-height:190px
    }
    .promo-bottle {
        font-size:90px
    }
    .promo-stamp {
        font-size:23px
    }
    .trust-bar {
        gap:9px 20px;
        padding:14px
    }
    .trust-bar span {
        font-size:10px
    }
    .combos-section {
        margin-top:40px
    }
    .hero {
        min-height:440px
    }
    .hero h1 {
        font-size:43px
    }
    .hero-actions .btn {
        font-size:12px;
        padding:12px 16px
    }
}

/* ==========================================================
   BODEGAR | LOGO AMPLIADO
   Compatible con assets/logo-bodegar.png y logo-bodegar.jpg
   ========================================================== */
header .brand {
    display: inline-flex;
    align-items: center;
    flex-shrink: 1;
    min-width: 0;
}

header .brand-logo {
    width: 340px;
    max-width: 100%;
    max-height: none;
    height: auto;
    object-fit: contain;
}

@media (max-width: 760px) {
    header .brand-logo {
        width: 220px;
    }
}

@media (max-width: 390px) {
    header .brand-logo {
        width: 185px;
    }
}

/* BodegAR v5: logo recortado y visible, sin límite de alto anterior */
header .brand { width: auto !important; min-width: 0; flex: 0 1 340px; display: flex; align-items: center; }
header .brand img.brand-logo { width: 340px !important; height: auto !important; max-width: 100% !important; max-height: none !important; object-fit: contain; }
@media (max-width: 900px) {
  header { flex-wrap: wrap; }
  header .brand { flex-basis: 270px; }
  header .brand img.brand-logo { width: 270px !important; }
  header nav { order: 3; width: 100%; justify-content: center; flex-wrap: wrap; }
}
@media (max-width: 600px) {
  header .brand { flex: 0 1 200px; }
  header .brand img.brand-logo { width: 200px !important; }
  header nav { justify-content: space-between; }
}


/* BodegAR V6 - encabezado compacto sin reducir legibilidad */
@media (min-width: 901px) {
    body > header {
        padding-top: 9px !important;
        padding-bottom: 9px !important;
        min-height: 0 !important;
        gap: 22px;
    }
    body > header > a.brand {
        flex: 0 0 275px !important;
        width: 275px !important;
        min-width: 0;
    }
    body > header > a.brand > img.brand-logo {
        width: 275px !important;
        max-width: 275px !important;
        max-height: none !important;
        height: auto !important;
    }
    body > header nav {
        flex: 1 1 auto;
        justify-content: center;
        gap: clamp(12px, 2vw, 28px);
    }
    body > header #cartBtn { flex: 0 0 auto; }
}
@media (min-width: 601px) and (max-width: 900px) {
    body > header { padding-top: 10px !important; padding-bottom: 10px !important; }
}
@media (max-width: 600px) {
    body > header { padding-top: 10px !important; padding-bottom: 10px !important; gap: 12px; }
}

/* BodegAR V9 — Tarjetas de vinos premium */
.grid{grid-template-columns:repeat(auto-fill,minmax(255px,1fr));gap:26px;align-items:stretch}
.product{border:1px solid #e9deda;border-radius:17px;padding:16px 16px 18px;gap:9px;box-shadow:0 6px 22px rgba(42,20,29,.045);transition:transform .22s ease,box-shadow .22s ease,border-color .22s ease}
.product:hover{transform:translateY(-5px);border-color:#d7c3c6;box-shadow:0 16px 34px rgba(42,20,29,.105)}
.product .bottle{height:290px;background:linear-gradient(155deg,#faf8f5 0%,#f0eae6 100%);border-radius:12px;margin-bottom:7px}
.product .bottle img{height:265px!important;max-height:265px!important;max-width:90%;width:auto;object-fit:contain;filter:drop-shadow(0 8px 8px rgba(33,19,20,.11))}
.product h3{font-family:'Playfair Display',Georgia,serif;font-size:23px;line-height:1.2;min-height:0;margin:4px 0 0;color:#34202a}
.product p{font-size:13px;line-height:1.45;color:#77656a}
.product small{font-size:12px;line-height:1.4;color:#9b7463;min-height:0}
.product strong{font-size:25px;letter-spacing:-.65px;margin:9px 0 7px;color:#542238}
.product button{margin-top:auto;min-height:49px;border-radius:9px;font-weight:750;letter-spacing:.01em;transition:filter .2s ease,transform .2s ease}
.product button:hover:not(:disabled){filter:brightness(1.12)}
.product button:disabled{opacity:.55;cursor:not-allowed}
@media(max-width:600px){.grid{gap:14px;grid-template-columns:repeat(auto-fill,minmax(min(100%,175px),1fr))}.product{padding:11px;gap:7px}.product .bottle{height:205px}.product .bottle img{height:185px!important;max-height:185px!important}.product h3{font-size:19px}.product strong{font-size:22px}.product button{font-size:13px;min-height:44px}}

/* BodegAR V10 — Descripción breve en tarjetas de producto */
.product .wine-description{font-size:13px;line-height:1.55;color:#70636a;margin:4px 0 0;display:-webkit-box;-webkit-box-orient:vertical;-webkit-line-clamp:2;line-clamp:2;overflow:hidden;min-height:calc(1.55em * 2);overflow-wrap:anywhere}
.product .wine-description.is-empty{visibility:hidden}
.product strong{margin-top:auto}
.product button{margin-top:0}
@media(max-width:600px){.product .wine-description{font-size:12px;line-height:1.45;min-height:calc(1.45em * 2)}}

/* V12: secciones separadas y navegación por categorías */
.store-sections{display:block}.store-catalog-section{padding:55px max(22px,calc((100vw - 1280px)/2));scroll-margin-top:24px}.store-catalog-section.alternate-section{background:#f1eae5}.store-catalog-section .catalog-head{margin-bottom:25px}.store-catalog-section .grid{margin-top:22px}.category-shortcuts{display:flex;flex-wrap:wrap;gap:10px;margin-top:16px}.category-pill{border:1px solid #d9c9c8;background:#fff;color:#542238;padding:10px 17px;border-radius:30px;font:inherit;font-weight:600;cursor:pointer;transition:background .2s,color .2s}.category-pill:hover,.category-pill.is-active{background:#542238;color:white;border-color:#542238}.catalog-empty{padding:28px 0;color:#75656a}.store-catalog-section .product{background:white}.store-catalog-section .filters{margin-bottom:0}@media(max-width:600px){.store-catalog-section{padding:34px 16px}.category-shortcuts{gap:7px}.category-pill{font-size:13px;padding:9px 13px}}
