/* Eemhuus & Co webshop: winkelmand-drawer, winkelwagen, afrekenen.
   Kleuren en knoppen komen uit het bestaande thema (wp-element-button, --wp--preset--*). */
:root {
  --eh-amber: var(--wp--preset--color--luminous-vivid-amber, #fcb900);
  --eh-panel: var(--wp--preset--color--custom-color-7, #383838);
  --eh-panel-dark: var(--wp--preset--color--ti-bg-inv, #1a1919);
  --eh-panel-mid: #2a2a2a;
  --eh-line: #4a4a4a;
  --eh-text: #f7f7f7;
  --eh-muted: var(--wp--preset--color--custom-color-8, #b0b0b0);
  --eh-green: var(--wp--preset--color--custom-color-3, #5a9d56);
  --eh-red: #ff6b6b;
}
html.eh-no-scroll { overflow: hidden; }

.eh-btn { background: radial-gradient(rgb(255, 105, 0) 0%, rgb(207, 46, 46) 100%); color: #fff; padding: calc(.667em + 2px) calc(1.333em + 2px); text-decoration: none; font: inherit; font-weight: 600; display: inline-block; text-align: center; border-radius: 8px; cursor: pointer; border: 0; font-weight: 600; }
.eh-btn--block { display: block; width: 100%; box-sizing: border-box; margin-top: 16px; }
.eh-btn--outline { background: transparent !important; box-shadow: inset 0 0 0 2px var(--eh-amber); color: var(--eh-amber) !important; }
.eh-btn[disabled] { opacity: .6; cursor: progress; }

/* ---------- drawer: zie het blok "winkelwagen-zijbalk" in layout.css ---------- */
@keyframes eh-fade { from { opacity: 0; } to { opacity: 1; } }

/* ---------- regels (drawer + winkelwagen) ---------- */
.eh-lines { width: 100%; border-collapse: collapse; }
.eh-lines th { text-align: left; font-size: .75rem; text-transform: uppercase; letter-spacing: .05em; color: var(--eh-muted); padding: 0 8px 10px; border-bottom: 1px solid var(--eh-line); font-weight: 600; }
.eh-lines th:last-child, .eh-lines td.wc-block-cart-item__total { text-align: right; }
.eh-lines td { padding: 14px 8px; border-bottom: 1px solid var(--eh-line); vertical-align: top; }
.eh-lines .wc-block-cart-item__image { width: 72px; }
.eh-lines .wc-block-cart-item__image img { width: 72px; height: 72px; object-fit: cover; border-radius: 8px; display: block; }
.eh-lines .wc-block-components-product-name { color: var(--eh-amber); font-weight: 600; text-decoration: none; display: block; margin-bottom: 4px; }
.eh-lines .wc-block-components-product-metadata { color: var(--eh-muted); font-size: .85rem; margin: 2px 0 6px; }
.eh-lines .wc-block-cart-item__prices { font-size: .9rem; }
.wc-block-cart-item__quantity { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; margin-top: 8px; }
.eh-lines .wc-block-components-quantity-selector, .eh-page .wc-block-components-quantity-selector {
  display: inline-flex; align-items: stretch; border: 1px solid var(--eh-line); border-radius: 6px; overflow: hidden; width: auto;
}
.eh-lines .wc-block-components-quantity-selector input {
  order: 2; width: 40px; text-align: center; background: transparent; color: var(--eh-text); border: 0; -moz-appearance: textfield; font: inherit; padding: 4px 0;
}
.eh-lines .wc-block-components-quantity-selector input::-webkit-inner-spin-button { -webkit-appearance: none; }
.eh-lines .wc-block-components-quantity-selector__button { background: transparent; color: var(--eh-text); border: 0; width: 30px; cursor: pointer; font-size: 1rem; }
.eh-lines .wc-block-components-quantity-selector__button--minus { order: 1; }
.eh-lines .wc-block-components-quantity-selector__button--plus { order: 3; }
.eh-lines .wc-block-components-quantity-selector__button:disabled { opacity: .35; cursor: default; }
.wc-block-cart-item__remove-link { background: none; border: 0; color: var(--eh-muted); text-decoration: underline; cursor: pointer; font-size: .8rem; padding: 0; }
.wc-block-cart-item__remove-link:hover { color: var(--eh-text); }

/* ---------- winkelwagen / afrekenen ---------- */
.eh-page { margin-top: 16px; color: var(--eh-text); }
.eh-cart { display: grid; grid-template-columns: minmax(0, 1fr) 340px; gap: 32px; align-items: start; }
.eh-cart__side { background: var(--eh-panel-mid); border-radius: 12px; padding: 20px; position: sticky; top: 16px; }
.wc-block-cart__totals-title { font-size: .8rem !important; text-transform: uppercase; letter-spacing: .06em; color: var(--eh-muted); margin: 0 0 12px !important; font-weight: 600; }
.wc-block-components-totals-wrapper { border-top: 1px solid var(--eh-line); padding: 12px 0; }
.wc-block-components-totals-item { display: flex; justify-content: space-between; gap: 12px; padding: 4px 0; }
.wc-block-components-totals-footer-item { font-size: 1.15rem; font-weight: 700; }
.wc-block-components-totals-footer-item .wc-block-components-totals-item__value { color: var(--eh-amber); }
.wc-block-components-totals-item__description { color: var(--eh-muted); font-size: .8rem; margin: 2px 0 0; }

.eh-empty { text-align: center; padding: 40px 16px; }
.eh-empty__title, .eh-thanks__title { color: var(--eh-amber); font-size: 1.5rem; font-weight: 700; margin: 0 0 12px; }
.eh-empty .eh-btn { margin-top: 12px; }

.eh-step { border: 0; padding: 0; margin: 0 0 28px; display: flex; flex-wrap: wrap; gap: 12px; }
.eh-step legend { color: var(--eh-amber); font-size: 1.2rem; font-weight: 700; margin-bottom: 10px; padding: 0; }
.eh-step__hint { flex-basis: 100%; margin: -4px 0 0; color: var(--eh-muted); font-size: .85rem; }
.eh-field { flex: 1 1 100%; display: flex; flex-direction: column; gap: 4px; }
.eh-field--half { flex: 1 1 calc(50% - 6px); min-width: 180px; }
.eh-field label { font-size: .85rem; color: var(--eh-text); }
.eh-optional { color: var(--eh-muted); }
.eh-field input, .eh-field select, .eh-field textarea {
  background: var(--eh-panel-dark); color: var(--eh-text); border: 1px solid var(--eh-line); border-radius: 6px;
  padding: 12px; font: inherit; width: 100%; box-sizing: border-box;
}
.eh-field input:focus, .eh-field select:focus, .eh-field textarea:focus { outline: 2px solid var(--eh-amber); outline-offset: 0; border-color: transparent; }
.eh-field.has-error input, .eh-field.has-error select { border-color: var(--eh-red); }
.eh-pay { flex-basis: 100%; background: var(--eh-panel-dark); border: 1px solid var(--eh-line); border-radius: 8px; padding: 14px 16px; display: flex; flex-direction: column; gap: 4px; }
.eh-pay span { color: var(--eh-muted); font-size: .85rem; }
.eh-check { display: flex; gap: 10px; align-items: flex-start; font-size: .9rem; margin: 8px 0 16px; }
.eh-check input { margin-top: 3px; accent-color: var(--eh-amber); }
.eh-check a, .eh-page a:not(.eh-btn) { color: var(--eh-amber); }
.eh-error { color: var(--eh-red); font-weight: 600; margin: 0 0 12px; }
.eh-actions { display: flex; justify-content: space-between; align-items: center; gap: 16px; flex-wrap: wrap; margin-top: 8px; }
.eh-thanks .eh-actions, .eh-empty .eh-actions { justify-content: center; }
.eh-back { text-decoration: none; }
.eh-summary { list-style: none; margin: 0 0 8px; padding: 0; }
.eh-summary li { display: flex; align-items: center; gap: 12px; padding: 8px 0; }
.eh-summary__img { position: relative; flex: 0 0 48px; }
.eh-summary__img img { width: 48px; height: 48px; object-fit: cover; border-radius: 6px; display: block; }
.eh-summary__qty { position: absolute; top: -6px; right: -6px; background: var(--eh-green); color: #fff; font-size: .7rem; font-weight: 700; border-radius: 999px; min-width: 18px; height: 18px; display: grid; place-items: center; }
.eh-summary__name { flex: 1; font-size: .9rem; }
.eh-summary__name small { display: block; color: var(--eh-muted); }
.eh-summary__price { font-size: .9rem; white-space: nowrap; }

.eh-thanks { max-width: 620px; margin: 0 auto; text-align: center; padding: 24px 8px; }
.eh-thanks--demo .eh-thanks__title::before { content: 'TESTMODUS'; display: block; width: max-content; margin: 0 auto 10px; font-size: .7rem; letter-spacing: .1em; background: var(--eh-amber); color: #111; padding: 3px 10px; border-radius: 999px; }
.eh-thanks__meta { list-style: none; padding: 0; margin: 20px 0; display: flex; flex-wrap: wrap; justify-content: center; gap: 8px 24px; font-size: .9rem; color: var(--eh-muted); }
.eh-thanks__meta strong { color: var(--eh-text); }
.eh-thanks__lines { width: 100%; border-collapse: collapse; text-align: left; margin-bottom: 16px; }
.eh-thanks__lines td { border-top: 1px solid var(--eh-line); padding: 8px 4px; }
.eh-thanks__lines td:last-child { text-align: right; white-space: nowrap; }
.eh-loading { text-align: center; padding: 40px; color: var(--eh-muted); }

.eh-search { display: flex; gap: 8px; max-width: 560px; margin: 0 auto 20px; }
.eh-search input { flex: 1; padding: 12px; border-radius: 6px; border: 1px solid var(--eh-line); background: var(--eh-panel-dark); color: var(--eh-text); font: inherit; }
.eh-results { list-style: none; padding: 0; max-width: 760px; margin: 0 auto; }
.eh-results li { padding: 12px 0; border-bottom: 1px solid var(--eh-line); }
.eh-results a { font-weight: 700; font-size: 1.1rem; }
.eh-results p { margin: 4px 0 0; color: var(--eh-muted); font-size: .9rem; }

.eh-toast {
  position: fixed; left: 50%; bottom: 24px; transform: translateX(-50%); z-index: 100000;
  background: var(--eh-green); color: #fff; padding: 12px 18px; border-radius: 8px; font-weight: 600;
  box-shadow: 0 8px 30px rgba(0, 0, 0, .4); max-width: calc(100% - 32px); transition: opacity .4s ease;
  animation: eh-toast-in .3s cubic-bezier(.23, 1, .32, 1);
}
@keyframes eh-toast-in { from { opacity: 0; transform: translate(-50%, 8px) scale(.98); } }
.eh-toast.is-hiding { opacity: 0; }
@media (max-width: 781px) { .eh-toast { bottom: auto; top: calc(12px + env(safe-area-inset-top)); } }
.eh-dialog { background: var(--eh-panel-dark); color: var(--eh-text); border: 1px solid var(--eh-line); border-radius: 12px; max-width: 420px; padding: 24px; }
.eh-dialog::backdrop { background: rgba(0, 0, 0, .6); }
.eh-dialog a { color: var(--eh-amber); }

/* Productpagina: Woo-blokken die zonder WordPress-JS niet goed tonen */
.wc-block-add-to-cart-with-options.is-invalid .single_add_to_cart_button { opacity: .5; }
.wc-block-product-filter-chips__item { cursor: pointer; }
.eh-added-button { margin-top: 12px; }
.wc-block-mini-cart__button { cursor: pointer; }

@media (max-width: 781px) {
  .eh-cart { grid-template-columns: 1fr; gap: 20px; }
  .eh-cart__side { position: static; }
  .eh-lines thead { display: none; }
  .eh-lines td.wc-block-cart-item__total { display: none; }
  .eh-field--half { flex-basis: 100%; }
  .eh-actions { flex-direction: column-reverse; align-items: stretch; }
  .eh-actions .eh-btn { width: 100%; }
}

/* De ingebouwde WooCommerce-drawer werkt alleen met WordPress-JS; wij gebruiken .eh-drawer */
.wc-block-components-drawer__screen-overlay { display: none !important; }

/* De oude site schuift op mobiel zijwaarts (te brede blokken); afknippen voorkomt dat */
html, body { overflow-x: clip; }
/* Contactformulier 7: lege meldingsbalk verbergen */
.wpcf7-response-output:empty, .wpcf7 form.init .wpcf7-response-output { display: none; }

/* Mobiel menu: deze WordPress-regels ontbraken in de geoptimaliseerde CSS van de oude site */
.wp-block-navigation__responsive-container.is-menu-open {
  display: flex; flex-direction: column; position: fixed; inset: 0; z-index: 100000;
  overflow: auto; padding: clamp(1rem, var(--wp--style--root--padding-top, 1rem), 20rem) clamp(1rem, var(--wp--style--root--padding-right, 1rem), 20rem) clamp(1rem, var(--wp--style--root--padding-bottom, 1rem), 20rem) clamp(1rem, var(--wp--style--root--padding-left, 1rem), 20rem);
  animation: eh-fade .15s ease;
}
.wp-block-navigation__responsive-container.is-menu-open .wp-block-navigation__responsive-container-content {
  display: flex; flex-direction: column; align-items: flex-start; flex-wrap: nowrap; overflow: visible; padding-top: calc(2rem + 24px);
}
.wp-block-navigation__responsive-container.is-menu-open .wp-block-navigation__container,
.wp-block-navigation__responsive-container.is-menu-open .wp-block-navigation-item { display: flex; flex-direction: column; align-items: flex-start; gap: .75rem; font-size: 1.25rem; }
.wp-block-navigation__responsive-container.is-menu-open .wp-block-navigation__submenu-container {
  position: static; display: flex; flex-direction: column; visibility: visible; opacity: 1; width: auto; height: auto; min-width: 0;
  border: 0; background: transparent !important; padding: .5rem 0 0 1rem; gap: .75rem;
}
.wp-block-navigation__responsive-container.is-menu-open .wp-block-navigation__submenu-icon { display: none; }
.wp-block-navigation__responsive-container.is-menu-open .wp-block-navigation__responsive-container-close {
  display: block; position: absolute; top: 1rem; right: 1rem; background: transparent; border: 0; color: currentColor; cursor: pointer; padding: 0; z-index: 2;
}
html.has-modal-open { overflow: hidden; }

/* Instellingen uit het beheerportaal: mededelingsbalk, webshop dicht, uitverkocht */
.eh-announce { position: relative; z-index: 50; padding: 9px 16px; text-align: center; font: 600 14px/1.4 Figtree, Inter, system-ui, sans-serif; }
.eh-announce a, .eh-announce span { color: inherit; text-decoration: none; }
.eh-announce a:hover { text-decoration: underline; text-underline-offset: 3px; }
.eh-announce--amber { background: #fcc400; color: #1c1600; }
.eh-announce--green { background: #3f7a3c; color: #fff; }
.eh-announce--red { background: #bb2330; color: #fff; }
.eh-closed { background: rgba(252, 196, 0, .14); border: 1px solid rgba(252, 196, 0, .45); color: inherit; border-radius: 10px; padding: 12px 16px; margin: 0 0 16px; font-weight: 600; }
.eh-soldout, .eh-soldout:hover { opacity: .55; cursor: not-allowed; }
.eh-chip-out { opacity: .45; text-decoration: line-through; }
