/* המשמח — one winery / distillery / brand (brand.html). Owner: BRANDS builder. Prefix .bd- (tiles: .bl- in brands.css) */

/* ---------- hero ---------- */
.bd-hero{position:relative;display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1fr);align-items:stretch;min-height:420px;margin-top:6px;background:var(--tile);border-radius:var(--r3);overflow:hidden;isolation:isolate}
.bd-hero-tx{position:relative;z-index:3;display:flex;flex-direction:column;align-items:flex-start;justify-content:center;padding:40px 48px 40px 20px}
.bd-hero-tx.nf{grid-column:1/-1;padding:56px 48px}
.bd-hero h1{font-size:clamp(52px,5.4vw,86px);margin:8px 0 0;line-height:.9}
.bd-hero-tx>p{font-size:17px;line-height:1.55;color:var(--muted);max-width:52ch;margin:14px 0 0}
.bd-facts{display:flex;flex-wrap:wrap;gap:8px;list-style:none;margin:20px 0 0;padding:0}
.bd-facts li{display:flex;align-items:baseline;gap:7px;background:#fff;border-radius:999px;padding:8px 16px 6px;box-shadow:0 6px 16px rgba(26,23,21,.05)}
.bd-facts b{font-family:var(--disp);font-weight:900;font-size:22px;line-height:1;color:var(--ink)}
.bd-facts span{font-size:13.5px;font-weight:700;color:var(--muted)}
.bd-facts li.cols{align-items:center}
.bd-facts .sw{display:inline-flex}
.bd-facts .sw i{width:14px;height:14px;border-radius:50%;background:var(--c);box-shadow:0 0 0 2px #fff;margin-inline-start:-4px}
.bd-facts .sw i:first-child{margin-inline-start:0}
.bd-acts{display:flex;flex-wrap:wrap;align-items:center;gap:10px;margin-top:24px}
.bd-flag{font-size:14px;font-weight:700;color:var(--muted);margin-inline-start:6px}
.bd-flag img{width:20px;border-radius:3px;box-shadow:0 0 0 1px rgba(0,0,0,.08)}
.bd-vis{position:relative;display:flex;align-items:flex-end;justify-content:center;padding:0 24px 34px;min-height:100%}
/* bottles on the smile (no photo) */
.bd-ride{position:relative;width:min(520px,100%);aspect-ratio:1000/420}
.bd-ride .shelf{position:absolute;inset:0;display:block}
.bd-ride .shelf svg{width:100%;height:100%;display:block}
.bd-ride a{position:absolute;translate:-50% -100%;display:block;transition:transform .5s var(--out)}
.bd-ride img{display:block;height:var(--h,220px);width:auto;max-width:150px;object-fit:contain;filter:drop-shadow(0 16px 12px rgba(40,28,16,.24))}
.bd-ride img.wb{mix-blend-mode:multiply;filter:none;height:calc(var(--h,220px) * .8)}
.bd-ride a:hover{transform:translateY(-8px)}
/* bottles in front of the brand photo */
.bd-vis.has-ph{padding:0;align-items:stretch}
.bd-ph{position:absolute;inset:0;margin:0}
.bd-ph img{width:100%;height:100%;object-fit:cover;-webkit-mask-image:linear-gradient(to left,transparent 0,#000 30%);mask-image:linear-gradient(to left,transparent 0,#000 30%)}
.bd-ph::after{content:"";position:absolute;inset:auto 0 0 0;height:46%;background:linear-gradient(to top,rgba(246,241,233,.96) 0,rgba(246,241,233,.6) 45%,transparent);pointer-events:none}
.bd-ph figcaption{position:absolute;z-index:2;top:12px;left:14px;max-width:70%;font-size:11px;line-height:1.3;color:rgba(255,255,255,.92);background:rgba(20,20,20,.42);padding:4px 9px;border-radius:999px;backdrop-filter:blur(4px);-webkit-backdrop-filter:blur(4px);direction:ltr;unicode-bidi:plaintext;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.bd-line{position:relative;z-index:2;align-self:flex-end;display:flex;align-items:flex-end;justify-content:center;width:100%;padding:0 20px 26px}
.bd-line::after{content:"";position:absolute;left:18%;right:18%;bottom:22px;height:16px;border-radius:50%;background:radial-gradient(closest-side,rgba(60,40,20,.28),transparent);z-index:-1}
.bd-line a{display:block;margin:0 -10px;transition:transform .5s var(--out)}
.bd-line img{display:block;height:250px;width:auto;max-width:140px;object-fit:contain;filter:drop-shadow(0 18px 14px rgba(30,20,10,.32))}
.bd-line a:nth-child(1) img,.bd-line a:nth-child(3) img{height:214px}
.bd-line a:nth-child(2){z-index:2}
.bd-line img.wb{mix-blend-mode:multiply;filter:none}
.bd-line a:hover{transform:translateY(-8px)}
@media (prefers-reduced-motion:no-preference){
 .bd-ride a,.bd-line a{animation:bdRise .9s var(--out) both;animation-delay:calc(var(--i) * 90ms + 100ms)}
 @keyframes bdRise{from{opacity:0;translate:-50% calc(-100% + 24px)}to{opacity:1}}
 .bd-line a{animation-name:bdRise2}
 @keyframes bdRise2{from{opacity:0;transform:translateY(24px)}to{opacity:1;transform:none}}
}

/* ---------- about ---------- */
.bd-about{padding:56px 0 18px}
.bd-about-in{display:grid;grid-template-columns:minmax(0,1fr) 360px;gap:56px;align-items:start}
.bd-story h2{font-family:var(--disp);font-weight:900;font-size:clamp(34px,3.2vw,48px);line-height:.95;margin:8px 0 18px}
.bd-story h2 em{font-style:normal;color:var(--red)}
.bd-story p{font-size:17.5px;line-height:1.8;color:#3d3936;margin:0 0 14px;max-width:68ch}
.bd-story p.mut{color:var(--muted);font-size:16px}
.bd-types{display:flex;flex-wrap:wrap;align-items:center;gap:8px;margin-top:22px}
.bd-types>span{font-weight:900;font-size:14px;margin-inline-end:4px}
.bd-types a{display:inline-flex;align-items:center;gap:7px;height:38px;padding:0 15px;border-radius:999px;background:#fff;box-shadow:inset 0 0 0 1.5px var(--line);font-weight:700;font-size:15px;transition:box-shadow .2s,color .2s}
.bd-types a small{font-size:12.5px;color:var(--muted2,#8b8580);font-weight:700}
.bd-types a:hover{color:var(--red);box-shadow:inset 0 0 0 1.5px var(--red)}
.bd-card{position:sticky;top:calc(var(--hm-hdr,0px) + 20px);background:#fff;border-radius:24px;padding:22px 22px 20px;box-shadow:0 0 0 1px var(--line),0 18px 40px rgba(26,23,21,.06)}
.bd-card dl{margin:0 0 18px;display:grid;gap:0}
.bd-card dl>div{display:grid;grid-template-columns:110px 1fr;gap:12px;padding:11px 0;border-bottom:1px dashed var(--line)}
.bd-card dl>div:last-child{border-bottom:0}
.bd-card dt{font-size:13.5px;font-weight:700;color:var(--muted)}
.bd-card dd{margin:0;font-weight:900;font-size:15.5px}
.bd-card dd img{width:18px;border-radius:3px}

/* ---------- deals ---------- */
.bd-deals{padding:40px 0 10px}
.bd-deals[hidden],.bd-best[hidden],.bd-sim[hidden]{display:none}
.bd-dl{display:grid;grid-template-columns:repeat(auto-fit,minmax(420px,1fr));gap:16px}
.bd-deal{display:grid;grid-template-columns:minmax(220px,36%) 1fr;border-radius:24px;overflow:hidden;background:#fff;box-shadow:0 0 0 1px var(--line),0 12px 30px rgba(26,23,21,.05)}
.bd-deal .ph{position:relative;display:block;min-height:100%}
.bd-deal .ph img{position:absolute;inset:0;width:100%;height:100%;object-fit:cover;transition:transform .8s var(--ease)}
.bd-deal:hover .ph img{transform:scale(1.05)}
.bd-deal .tx{padding:20px 22px;display:flex;flex-direction:column;align-items:flex-start;gap:6px}
.bd-deal .tx>b{font-family:var(--disp);font-weight:900;font-size:26px;line-height:1;margin-top:6px}
.bd-deal .tx p{margin:0;color:var(--muted);font-size:15px;line-height:1.5}
.bd-deal .th{display:flex;align-items:flex-end;gap:4px;margin:8px 0 4px;min-height:86px}
.bd-deal .th a{display:block;width:52px;height:86px;transition:transform .3s var(--out)}
.bd-deal .th a:hover{transform:translateY(-4px)}
.bd-deal .th img{width:100%;height:100%;object-fit:contain;filter:drop-shadow(0 6px 4px rgba(25,23,22,.16))}
.bd-deal .th img.wb{mix-blend-mode:multiply;filter:none}
.bd-deal .th span{align-self:center;font-weight:900;font-size:14px;color:var(--muted);margin-inline-start:6px}
.bd-deal .acts{display:flex;flex-wrap:wrap;align-items:center;gap:14px;margin-top:6px}

.bd-dl+.bd-dg{margin-top:22px}
.bd-dg{grid-template-columns:repeat(4,minmax(0,1fr))}
/* the brand is the page: no brand line on its own cards */
.pg-bd :is(.pg-cat-grid,.bd-best-g,.bd-dg) .hm-bline{display:none}

/* ---------- best sellers ---------- */
.bd-best{padding:44px 0 6px}
.bd-best-g{grid-template-columns:repeat(4,minmax(0,1fr))}
.bd-best-g .hm-card{position:relative}
.bd-best-g .hm-card::after{content:attr(data-rank);position:absolute;top:10px;left:12px;font-family:var(--disp);font-weight:900;font-size:44px;line-height:1;color:var(--stone);opacity:.9;pointer-events:none;z-index:1}
.bd-best-g .hm-card .hm-fav{left:auto;right:10px}

/* ---------- all products (category block) ---------- */
.bd-all-h{padding:48px 0 0;scroll-margin-top:calc(var(--hm-hdr,0px) + 10px)}
.bd-all-h .hm-sec-h{margin-bottom:0}
.pg-bd .pg-cat-body{margin-top:14px}
.bd-sim{padding:56px 0 56px}
.pg-bd .bl-seo{margin-top:0}

/* ---------- responsive ---------- */
@media(max-width:1100px){
 .bd-hero{grid-template-columns:1fr .85fr;min-height:380px}
 .bd-hero-tx{padding:32px 32px 32px 12px}
 .bd-about-in{grid-template-columns:1fr 300px;gap:32px}
 .bd-best-g{grid-template-columns:repeat(4,minmax(0,1fr))}
}
@media(max-width:860px){
 .bd-hero{grid-template-columns:1fr;min-height:0;border-radius:24px}
 .bd-hero-tx{padding:26px 20px 8px;order:1}
 .bd-hero h1{font-size:48px}
 .bd-hero-tx>p{font-size:15.5px}
 .bd-facts{gap:6px;margin-top:16px}
 .bd-facts li{padding:6px 12px 4px}
 .bd-facts b{font-size:19px}.bd-facts span{font-size:12.5px}
 .bd-acts{margin-top:18px;gap:8px}
 .bd-acts .hm-btn{flex:1 1 auto;justify-content:center}
 .bd-flag{display:none}
 .bd-vis{order:2;padding:118px 12px 18px;min-height:0}
 .bd-ride{width:min(320px,90%)}
 .bd-ride img{height:calc(var(--h,220px) * .6);max-width:90px}
 .bd-vis.has-ph{height:300px;padding:0}
 .bd-ph img{-webkit-mask-image:none;mask-image:none}
 .bd-ph::after{height:60%}
 .bd-line{padding:0 12px 16px}
 .bd-line img{height:190px;max-width:100px}
 .bd-line a:nth-child(1) img,.bd-line a:nth-child(3) img{height:160px}
 .bd-about{padding:38px 0 6px}
 .bd-about-in{grid-template-columns:1fr;gap:22px}
 .bd-story p{font-size:16.5px;line-height:1.75}
 .bd-card{position:static}
 .bd-card dl>div{grid-template-columns:100px 1fr}
 .bd-dl{grid-template-columns:1fr}
 .bd-deal{grid-template-columns:1fr}
 .bd-deal .ph{height:150px}
 .bd-deal .tx{padding:16px 16px 18px}
 .bd-best-g,.bd-dg{grid-template-columns:repeat(2,minmax(0,1fr))}
 .bd-best-g .hm-card::after{font-size:34px}
 .bd-all-h{padding-top:36px}
 .bd-sim{padding:40px 0}
}
/* design pass: slimmer smile; square cut-outs anchored to their base so every bottle stands ON the curve */
.bd-ride .shelf path{stroke-width:56}
.bd-ride .shelf circle{r:40px}
.bd-ride a{pointer-events:none}.bd-ride a img{pointer-events:auto}
.bd-ride img{object-position:50% 100%;max-width:none;height:calc(var(--h,220px) * .82)}
.bd-ride img.wb{height:calc(var(--h,220px) * .7)}
@media(max-width:860px){.bd-ride img{height:calc(var(--h,220px) * .56)}.bd-ride img.wb{height:calc(var(--h,220px) * .5)}.bd-ride .shelf path{stroke-width:64}}

/* phones: the bottles come first — a 3-line story excerpt that opens in place, the type chips, then the shelf.
   The facts card repeats the hero facts, so on phones it is left out (fix-category 2026-12-04) */
.bd-story-more{display:none}
@media(max-width:860px){
  .bd-about{padding:22px 0 0}
  .bd-story h2{font-size:30px;margin:6px 0 10px}
  .bd-story-tx:not(.open){display:-webkit-box;-webkit-line-clamp:3;-webkit-box-orient:vertical;overflow:hidden}
  .bd-story-tx:not(.open) p{margin:0;display:inline}
  .bd-story-tx:not(.open) p+p::before{content:" "}
  .bd-story-more{display:inline-flex;align-items:center;gap:6px;margin-top:6px;padding:8px 2px;border:0;background:none;font:inherit;font-weight:900;font-size:15px;color:var(--red);cursor:pointer;text-decoration:underline;text-underline-offset:4px}
  .bd-types{margin-top:12px}
  .bd-about .bd-card{display:none}
}
/* layout-shift guards: hero and story keep their room until the data arrives */
.pg-bd #crumbs:empty{min-height:45px}
.bd-hero:empty{min-height:420px}
.bd-about:empty{min-height:480px}
@media(max-width:860px){ .bd-hero:empty{min-height:620px} .bd-about:empty{min-height:300px} }
