/* Tienda (carrito, pago, cuenta, ficha) con la imagen de lafactorie.es. Sirve para los bloques de WooCommerce y para el pago clásico. */
@font-face {
  font-family: 'Bricolage Grotesque Variable';
  font-style: normal;
  font-display: swap;
  font-weight: 200 800;
  font-stretch: 75% 100%;
  src: url(fonts/bricolage-grotesque-latin-ext-standard-normal.woff2) format('woff2-variations');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: 'Bricolage Grotesque Variable';
  font-style: normal;
  font-display: swap;
  font-weight: 200 800;
  font-stretch: 75% 100%;
  src: url(fonts/bricolage-grotesque-latin-standard-normal.woff2) format('woff2-variations');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

body.lfh-shop {
  --sand: #c1ae89;
  --ink: #16130e;
  --bg: #f4efe6;
  --bg-2: #ebe3d4;
  --fg-2: #4d4334;
  --line: rgb(22 19 14 / 0.16);
  --font: 'Bricolage Grotesque Variable', system-ui, sans-serif;
  --gutter: clamp(16px, 4vw, 56px);
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font);
  font-size: 17px;
  line-height: 1.5;
  letter-spacing: -0.006em;
  -webkit-font-smoothing: antialiased;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}
.lfh-shop *, .lfh-shop *::before, .lfh-shop *::after { box-sizing: border-box; }
.lfh-shop :where(input, select, textarea, button, h1, h2, h3, h4, .wc-block-components-title) { font-family: inherit; letter-spacing: inherit; }
.lfh-shop a { color: inherit; text-underline-offset: 3px; }

.lfh-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 20px var(--gutter);
  border-bottom: 1px solid var(--line);
}
.lfh-logo img { display: block; height: 26px; width: auto; }
.lfh-nav { display: flex; gap: 6px; flex-wrap: wrap; }
.lfh-nav a {
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  text-decoration: none;
  padding: 9px 16px;
  border: 1px solid var(--line);
  border-radius: 999px;
  transition: background 0.3s, color 0.3s, border-color 0.3s;
}
.lfh-nav a:hover, .lfh-nav a[aria-current='page'] { background: var(--ink); color: var(--bg); border-color: var(--ink); }
.lfh-count { display: inline-grid; place-items: center; min-width: 1.6em; height: 1.6em; margin-left: 4px; border-radius: 999px; background: var(--sand); color: var(--ink); font-size: 0.85em; }

.lfh-main { flex: 1; width: 100%; max-width: 1240px; margin: 0 auto; padding: clamp(40px, 7vw, 96px) var(--gutter) clamp(64px, 8vw, 120px); }
.lfh-kicker { margin: 0 0 12px; font-size: 0.72rem; font-weight: 600; letter-spacing: 0.14em; text-transform: uppercase; color: var(--fg-2); }
.lfh-title, .lfh-shop .product_title {
  margin: 0 0 clamp(32px, 4vw, 56px);
  font-size: clamp(2.6rem, 7vw, 5.6rem);
  font-weight: 800;
  font-stretch: 75%;
  line-height: 0.92;
  letter-spacing: -0.035em;
  text-transform: uppercase;
}
.lfh-shop h2, .lfh-shop h3 { font-weight: 700; letter-spacing: -0.015em; line-height: 1.1; }

/* Campos */
.lfh-shop :is(input[type='text'], input[type='email'], input[type='tel'], input[type='password'], input[type='number'], select, textarea),
.lfh-shop .wc-block-components-text-input input,
.lfh-shop .wc-blocks-components-select__select {
  background: #fffdf8 !important;
  border: 1px solid var(--line) !important;
  border-radius: 14px !important;
  color: var(--ink) !important;
  font-size: 16px;
}
.lfh-shop :is(input, select, textarea):focus { outline: 2px solid var(--sand) !important; outline-offset: 1px; box-shadow: none !important; }
.lfh-shop .wc-block-components-text-input label { color: var(--fg-2); }

/* Botones como las píldoras de la web */
.lfh-shop :is(.button, button.button, .wc-block-components-button, .wp-element-button, .checkout-button, #place_order, .single_add_to_cart_button) {
  background: var(--ink) !important;
  color: var(--bg) !important;
  border: 1px solid var(--ink) !important;
  border-radius: 999px !important;
  padding: 14px 26px !important;
  font-size: 0.8rem !important;
  font-weight: 600 !important;
  letter-spacing: 0.12em !important;
  text-transform: uppercase;
  text-decoration: none !important;
  transition: background 0.35s cubic-bezier(0.19, 1, 0.22, 1), color 0.35s, transform 0.35s cubic-bezier(0.19, 1, 0.22, 1);
  box-shadow: none !important;
}
.lfh-shop :is(.button, .wc-block-components-button, .wp-element-button, #place_order, .single_add_to_cart_button):hover { background: var(--sand) !important; border-color: var(--sand) !important; color: var(--ink) !important; transform: translateY(-1px); }
.lfh-shop .wc-block-components-button.outlined { background: transparent !important; color: var(--ink) !important; }

/* Tarjetas: resumen del pedido, métodos de pago, avisos */
.lfh-shop :is(.wc-block-components-sidebar .wc-block-components-totals-wrapper, .wc-block-checkout__sidebar, .woocommerce-checkout-review-order, #payment, .cart_totals, .woocommerce-MyAccount-navigation) {
  border-color: var(--line) !important;
}
.lfh-shop :is(.wc-block-checkout__sidebar, .wc-block-cart__sidebar, #order_review, .cart_totals) { background: var(--bg-2); border-radius: 24px; padding: clamp(16px, 2.4vw, 32px); }
.lfh-shop #payment { background: transparent !important; }
.lfh-shop .wc-block-components-radio-control__option, .lfh-shop .wc-block-components-radio-control-accordion-option { border-color: var(--line) !important; border-radius: 14px; }
.lfh-shop :is(.woocommerce-message, .woocommerce-info, .woocommerce-error, .wc-block-components-notice-banner) { background: #fffdf8 !important; border: 1px solid var(--line) !important; border-left: 4px solid var(--sand) !important; border-radius: 14px; color: var(--ink) !important; }
.lfh-shop table { border-collapse: collapse; width: 100%; }
.lfh-shop :is(th, td) { border-color: var(--line) !important; }
.lfh-shop .woocommerce-MyAccount-navigation ul { list-style: none; padding: 0; display: flex; flex-wrap: wrap; gap: 6px; }
.lfh-shop .woocommerce-MyAccount-navigation a { display: block; padding: 8px 16px; border: 1px solid var(--line); border-radius: 999px; text-decoration: none; font-size: 0.85rem; }
.lfh-shop .woocommerce-MyAccount-navigation .is-active a { background: var(--ink); color: var(--bg); }

/* Ficha de producto con opciones */
.lfh-shop div.product { display: grid; grid-template-columns: minmax(0, 1fr); gap: clamp(24px, 4vw, 64px); align-items: start; }
@media (min-width: 900px) { .lfh-shop div.product { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); } }
.lfh-shop div.product > * { min-width: 0; }
/* WooCommerce les da 48 % y float; en la rejilla ocupan su columna entera. */
.lfh-shop div.product :is(div.images, div.summary) { width: 100% !important; float: none !important; margin: 0 !important; }
.lfh-shop .woocommerce-product-gallery { opacity: 1 !important; }
.lfh-shop .woocommerce-product-gallery img { border-radius: 24px; width: 100%; height: auto; }
.lfh-shop div.product .product_title { font-size: clamp(2rem, 6vw, 4rem); overflow-wrap: anywhere; }
.lfh-shop div.product form.cart { display: grid; gap: 16px; }
.lfh-shop img { max-width: 100%; height: auto; }
.lfh-shop .price { font-size: 1.6rem; font-weight: 700; }

.lfh-foot {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 8px 24px;
  padding: 24px var(--gutter);
  border-top: 1px solid var(--line);
  font-size: 0.76rem;
  color: var(--fg-2);
}
.lfh-foot nav { display: flex; flex-wrap: wrap; gap: 6px 18px; }

@media (max-width: 560px) {
  .lfh-bar { padding-block: 14px; gap: 10px; }
  .lfh-logo img { height: 18px; }
  .lfh-nav { gap: 4px; flex-wrap: nowrap; }
  .lfh-nav a { padding: 7px 9px; font-size: 0.58rem; letter-spacing: 0.06em; white-space: nowrap; }
}

@media (prefers-reduced-motion: reduce) {
  .lfh-shop * { transition: none !important; }
}

/* Carrito clásico: cupón y cantidad a un tamaño cómodo */
.lfh-shop table.cart .coupon { display: flex; flex-wrap: wrap; gap: 8px; }
.lfh-shop table.cart .coupon #coupon_code { width: auto; min-width: 180px; padding: 12px 16px; }
.lfh-shop table.cart .quantity .qty { width: 4em; padding: 8px; }
