/* ==========================================================================
   woo-buynow: "Cumpără acum" next to "Adaugă în coș" (inc/woo-buynow.php), generic for any purchasable
   product page. Kit rule: one filled action per view, so "Cumpără acum" is the filled action and
   "Adaugă în coș" turns secondary (1 px ink outline). Same rules as the "buy now" block of
   house-mockups/pages/wine.html <style>. Also: the buy bar above the first-visit cookie bar, and the
   "Stoc epuizat" notice of a product that cannot be bought now.
   ========================================================================== */

/* buy box: stepper + "Cumpără acum · total" on one row, "Adaugă în coș" on the full row below */
.dvh-buy__form .dvh-btn--secondary { flex: 1 1 100%; }
/* WooCommerce's add class maps to the filled style in the kit: the outline wins where the add is secondary */
.dvh-btn--secondary.single_add_to_cart_button { background: transparent; color: var(--ink); border-color: var(--ink); }
.dvh-btn--secondary.single_add_to_cart_button:hover { background: var(--band); border-color: var(--ink); }

/* buy bar: both actions in the bar's action cell, the filled one last (right) */
.dvh-buybar__actions { grid-area: btn; display: flex; gap: var(--sp-2); }
.dvh-buybar__actions .dvh-btn { min-height: 44px; padding-inline: var(--sp-3); }
@media (max-width: 599.98px) {
  /* phones: name, total and stepper on top, the two actions side by side under them (bar 112 px) */
  body:has(.dvh-buybar--buynow) { --buybar-h: 112px; }
  .dvh-buybar--buynow .dvh-buybar__inner {
    grid-template-columns: auto minmax(0, 1fr) auto;
    grid-template-areas: "thumb info step" "thumb price step" "btn btn btn";
  }
  .dvh-buybar--buynow .dvh-buybar__actions { margin-top: var(--sp-2); }
  .dvh-buybar__actions .dvh-btn { flex: 1 1 0; min-width: 0; padding-inline: var(--sp-2); font-size: var(--fs-ui); }
}
@media (min-width: 900px) {
  .dvh-buybar__actions .dvh-btn { min-height: 48px; padding-inline: var(--sp-4); }
}

/* first visit: the buy bar rises above the cookie bar (fixed at the foot, kit 20) until the visitor answers
   (kit.js then sets [hidden]). inc/woo-buynow.php measures the lift into --dvh-cookie-lift; without JavaScript
   214 px = the tallest cookie bar (320 px wide, Romanian copy) and its margins. */
body:has(.dvh-cookie:not([hidden])) .dvh-buybar:not(.is-static) { bottom: var(--dvh-cookie-lift, 214px); }

/* not for sale now: the kit notice "Stoc epuizat" where the buy row would be, its action on the full row */
.dvh-soldout { flex-wrap: wrap; align-items: center; margin-top: var(--sp-5); }
.dvh-soldout__title { font-weight: var(--fw-strong); }
.dvh-soldout .dvh-notice__action { flex: 1 1 100%; }
