/* Mobile fixes (24.11). Loaded after main.css and overrides.css. */

/* ── Mobile menu (drawer) ── */
.m-menu { position: fixed; inset: 0; z-index: 10050; visibility: hidden; pointer-events: none; overflow: hidden; }
.m-menu.open { visibility: visible; pointer-events: auto; }
.m-menu-backdrop { position: absolute; inset: 0; background: rgba(12, 12, 14, .55); opacity: 0; transition: opacity .25s; }
.m-menu.open .m-menu-backdrop { opacity: 1; }
.m-menu-panel {
  position: absolute; top: 0; bottom: 0; right: 0; width: min(86vw, 360px);
  background: var(--bg, #fff); color: var(--text, #111);
  transform: translateX(100%); transition: transform .28s ease;
  display: flex; flex-direction: column; box-shadow: -8px 0 32px rgba(0, 0, 0, .25);
}
.m-menu.open .m-menu-panel { transform: none; }
.m-menu-head { display: flex; align-items: center; justify-content: space-between; padding: 1rem 1.25rem; border-bottom: 1px solid var(--border, #e5e5e5); }
.m-menu-head strong { font-size: 1.05rem; }
.m-menu-close { border: 0; background: none; font-size: 1.8rem; line-height: 1; cursor: pointer; color: inherit; padding: .25rem .5rem; }
.m-menu-body { overflow-y: auto; -webkit-overflow-scrolling: touch; padding: .5rem 0 1.5rem; flex: 1; }
.m-menu-body ul { list-style: none; margin: 0; padding: 0; }
.m-menu-body a, .m-menu-body summary { display: flex; align-items: center; justify-content: space-between; gap: .5rem; padding: .85rem 1.25rem; color: inherit; text-decoration: none; font-size: 1rem; font-weight: 500; cursor: pointer; }
.m-menu-body summary { list-style: none; }
.m-menu-body summary::-webkit-details-marker { display: none; }
.m-menu-body summary::after { content: '▾'; font-size: .8rem; color: var(--text-dim, #777); transition: transform .2s; }
.m-menu-body details[open] > summary::after { transform: rotate(180deg); }
.m-menu-body details details summary, .m-menu-body details li a { padding-block: .6rem; padding-inline-start: 2rem; font-size: .93rem; font-weight: 400; }
.m-menu-body details details li a { padding-inline-start: 2.75rem; color: var(--text-mid, #555); }
.m-menu-body > ul > li + li, .m-menu-body > ul > li > details > ul > li { border-top: 1px solid var(--border, #eee); }
.m-menu-cta { margin: 1rem 1.25rem 0; display: flex !important; justify-content: center !important; }
body.m-menu-lock { overflow: hidden; }
.nav-toggle:focus-visible, .m-menu-close:focus-visible { outline: 2px solid var(--accent, #E8611A); outline-offset: 2px; }

/* ── Price calculator: nothing wider than its box ── */
.pcalc { grid-template-columns: minmax(0, 1fr); }
.pcalc > *, .pcalc-field, .pcalc-result > * { min-width: 0; max-width: 100%; }
.pcalc-head { flex-wrap: wrap; row-gap: .25rem; }
.pcalc-fine, .pcalc-note, .pcalc-logo-note, .pcalc-total, .pcalc-vat, .pcalc-per, .pcalc-quote-note, .pcalc-added { overflow-wrap: anywhere; }
.pcalc-logo input[type=file] { width: 100%; max-width: 100%; box-sizing: border-box; }
.pcalc-result > div { display: flex; flex-wrap: wrap; align-items: baseline; column-gap: .35rem; }
.pcalc-actions > * { min-width: 0; }

/* ── Category filters (bottom sheet on mobile) ── */
.filters-open, .filters-sheet-head, .filters-backdrop { display: none; }

@media (max-width: 767px) {
  /* Never wider than the screen. */
  .split { grid-template-columns: minmax(0, 1fr) !important; }
  .split > * { min-width: 0; max-width: 100%; }
  .split-content, .split-visual { width: auto !important; }
  .post-body .alignwide, .post-body .alignfull, .page-body .alignwide { margin-inline: 0 !important; width: auto !important; max-width: 100% !important; }
  .split-content h1, .split-content h2, .split-content p, .breadcrumbs, .woocommerce-breadcrumb { overflow-wrap: anywhere; }

  /* 1 · Homepage hero: the last frame (open card) and one heading, no scroll effect. */
  .hero-scroll { height: auto !important; }
  .hero-sticky { position: relative !important; height: auto !important; display: flex; flex-direction: column; padding-top: 72px; }
  .hero-video { position: relative !important; inset: auto; height: auto !important; aspect-ratio: 4 / 3; object-position: center 68%; }
  .hero-overlay, .hero-scroll-indicator { display: none !important; }
  .hero-phase { display: none !important; }
  .hero-sticky > .hero-phase:nth-last-child(2) { display: flex !important; position: relative !important; inset: auto; opacity: 1 !important; padding: 1.25rem 1.25rem 2.25rem !important; pointer-events: auto; }
  .hero-sticky > .hero-phase:nth-last-child(2) h1 { font-size: clamp(1.6rem, 7.5vw, 2.1rem); margin-bottom: .5rem; }
  .hero-sticky > .hero-phase:nth-last-child(2) p { font-size: 1rem; line-height: 1.6; }

  /* 3 · Counters: one line each. */
  .stat-number { font-size: clamp(1.35rem, 6.4vw, 1.7rem) !important; white-space: nowrap; line-height: 1.2; }
  .stat-label { font-size: .8rem !important; }

  /* 4 · Featured products: two columns. */
  .products-grid { grid-template-columns: repeat(2, minmax(0, 1fr)) !important; gap: .75rem !important; }
  .products-grid .product-card { min-width: 0; }
  .products-grid .product-card h3, .products-grid .product-card h4, .products-grid .product-card [class*=title], .products-grid .product-card [class*=name] { font-size: .88rem !important; line-height: 1.35; }
  .products-grid .product-card [class*=price] { font-size: .85rem !important; }
  .products-grid .product-card [class*=btn], .products-grid .product-card .btn-primary { font-size: .8rem !important; padding: .45rem .6rem !important; }

  /* 5 · Featured filter: one scrolling row. */
  .products-categories { flex-wrap: nowrap !important; overflow-x: auto; -webkit-overflow-scrolling: touch; scroll-snap-type: x proximity; scrollbar-width: none; justify-content: flex-start !important; padding-bottom: .25rem; margin-inline: -1.5rem; padding-inline: 1.5rem; width: calc(100% + 3rem); max-width: 100vw; box-sizing: border-box; flex: none; align-self: stretch; }
  .products-categories::-webkit-scrollbar { display: none; }
  .products-categories .cat-btn { flex: none; white-space: nowrap; scroll-snap-align: start; }

  /* 6 · Category filters: a button opens a bottom sheet. */
  .filters-open { display: inline-flex; align-items: center; gap: .5rem; margin: 1rem 1.25rem 0; padding: .55rem 1rem; border: 1.5px solid var(--border, #ddd); border-radius: 999px; background: var(--bg, #fff); color: var(--text, #111); font: inherit; font-size: .92rem; font-weight: 600; cursor: pointer; }
  .filters-open svg { width: 18px; height: 18px; }
  .filters-open .filters-count { font-weight: 400; color: var(--text-dim, #777); }
  form.filters-bar { position: fixed !important; inset: auto 0 0 0 !important; z-index: 10040; max-height: 78vh; overflow-y: auto; margin: 0 !important; padding: 1rem 1.25rem 1.5rem !important; background: var(--bg, #fff); border-radius: 18px 18px 0 0; box-shadow: 0 -10px 40px rgba(0, 0, 0, .25); transform: translateY(105%); transition: transform .28s ease; display: flex !important; flex-wrap: wrap; gap: .5rem; align-content: flex-start; }
  form.filters-bar.open { transform: none; }
  form.filters-bar .filters-sheet-head { flex: 1 0 100%; display: flex; justify-content: space-between; align-items: center; margin-bottom: .25rem; }
  form.filters-bar .filters-sheet-head strong { font-size: 1.05rem; }
  form.filters-bar .filters-sheet-close { border: 0; background: none; font-size: 1.7rem; line-height: 1; cursor: pointer; color: inherit; }
  form.filters-bar .filters-right { flex: 1 0 100%; margin: .5rem 0 0 !important; }
  form.filters-bar .filter-sort { width: 100%; }
  .filters-backdrop { display: block; position: fixed; inset: 0; z-index: 10030; background: rgba(12, 12, 14, .5); opacity: 0; visibility: hidden; transition: opacity .25s; }
  .filters-backdrop.open { opacity: 1; visibility: visible; }

  /* 7 · Product photos: whole product, never cropped. */
  .cat-card-img img, .product-card img, .products-grid img, .related img { object-fit: contain !important; background: #fff; }
}

@media (prefers-reduced-motion: reduce) {
  .m-menu-panel, .m-menu-backdrop, form.filters-bar, .filters-backdrop { transition: none !important; }
}

/* ── Textile builder: choice captions wrap inside their button ── */
.tx-grid2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.tx-choice { min-width: 0; }
.tx-choice small { white-space: normal; overflow-wrap: anywhere; }

/* ── Textile builder on phones (Oz, 25.11): big colours, one size a row, a bottom bar ── */
.tx-bar { display: none; }
/* A size the colour is not made in is left out; there is no stock feed (Oz, 25.11). */
body .tx .tx-size.is-off { display: none; }
@media (max-width: 767px) {
  body .tx .tx-colors { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: .5rem; }
  body .tx .tx-color { padding: .75rem .35rem; font-size: .88rem; min-height: 5.5rem; }
  body .tx .tx-dot { width: 2.75rem; height: 2.75rem; }

  body .tx .tx-sizes { grid-template-columns: minmax(0, 1fr); gap: .45rem; }
  body .tx .tx-size { flex-direction: row; justify-content: space-between; padding: .55rem .9rem; border-radius: 12px; transition: background .15s, border-color .15s; }
  body .tx .tx-size.has-qty { border-color: var(--accent); background: var(--accent-glow); }
  body .tx .tx-size-name { font-size: 1.05rem; }
  body .tx .tx-stepper { gap: .5rem; }
  body .tx .tx-stepper button { width: 2.75rem; height: 2.75rem; }
  body .tx .tx-stepper button::before, .tx .tx-stepper button[data-act="inc"]::after { width: .9rem; }
  body .tx .tx-stepper button[data-act="inc"]::after { width: 2px; height: .9rem; }
  body .tx .tx-stepper input { width: 3.6rem; height: 2.75rem; font-size: 1.05rem; }

  body .tx .tx-choice { min-height: 3.5rem; }

  body.tx-in-view:not(.tx-sum-visible) .tx-bar {
    display: block; position: fixed; inset: auto 0 0 0; z-index: 10020;
    background: var(--bg, #fff); color: var(--text, #111);
    border-top: 1px solid var(--border, #ddd); box-shadow: 0 -8px 24px rgba(0, 0, 0, .12);
    padding: .6rem 1rem calc(.6rem + env(safe-area-inset-bottom));
  }
  .tx-bar-miss { margin: 0 0 .5rem; padding: .4rem .7rem; border-radius: 8px; background: #FFF4C2; color: #5C4A00; font-size: .85rem; font-weight: 600; }
  /* Room on the left for the privacy button, which sits in its own shadow root. */
  .tx-bar-row { display: flex; align-items: center; justify-content: space-between; gap: .75rem; padding-left: 3.75rem; }
  .tx-bar-sum { display: flex; flex-direction: column; min-width: 0; line-height: 1.25; }
  .tx-bar-sum small { font-size: .75rem; color: var(--text-dim, #666); }
  .tx-bar-sum b { font-size: 1.25rem; font-variant-numeric: tabular-nums; }
  .tx-bar .btn-primary { flex: none; padding: .75rem 1.25rem; }
  .tx-bar .btn-primary:disabled { opacity: .45; }
  /* The chat, accessibility and assistant buttons move up while the bar is showing. */
  body.tx-in-view:not(.tx-sum-visible) .wa-float,
  body.tx-in-view:not(.tx-sum-visible) #bda11y-toolbar-host,
  body.tx-in-view:not(.tx-sum-visible) #bd-assistant-launch { transform: translateY(-6.75rem); transition: transform .2s; }
}

/* ── Textile summary: price-list quote and a special request (25.11) ── */
.tx-summary .tx-offer { width: 100%; justify-content: center; }
.tx-summary .tx-special { background: none; border: 0; padding: .3rem; color: var(--text-mid, #555); font: inherit; font-size: .92rem; text-decoration: underline; text-underline-offset: 3px; cursor: pointer; }
.tx-summary .tx-special:hover, .tx-summary .tx-special:focus-visible { color: var(--accent, #E8611A); }

/* ── Text on dark backgrounds is white, not grey (Asher, 25.11) ── */
html body .nav-links a,
html body .nav.scrolled .nav-links a,
html body .nav.nav--solid.scrolled .nav-links a,
html body .nav.scrolled .nav-logo-text,
html body .nav.nav--solid.scrolled .nav-logo-text { color: #fff; }
html body .nav-links a:hover,
html body .nav.scrolled .nav-links a:hover,
html body .nav.nav--solid.scrolled .nav-links a:hover { color: var(--accent, #E8611A); }
html body .nav-icon-btn svg,
html body .nav.scrolled .nav-icon-btn svg,
html body .nav.nav--solid.scrolled .nav-icon-btn svg { stroke: #fff; }
html body .nav.scrolled .nav-toggle span,
html body .nav.nav--solid.scrolled .nav-toggle span { background: #fff; }
html body .hero-phase h1,
html body .hero-phase p,
html body .hero-scroll-indicator span { color: #fff; }
html body .footer,
html body .footer .footer-col h4,
html body .footer .footer-brand p,
html body .footer .footer-col a,
html body .footer .footer-contact-item,
html body .footer .footer-bottom p,
html body .footer .footer-bottom a,
html body .demo-strip-head span:last-child,
html body .demo-col h5,
html body .demo-col a,
html body .demo-col a b { color: #fff; }
html body .footer .footer-col a:hover,
html body .footer .footer-bottom a:hover,
html body .demo-col a:hover { color: var(--accent, #E8611A); }

/* ── Textile builder: a logo per side and background removal (25.11) ── */
.tx-side-title { margin: 0; font-weight: 700; font-size: .95rem; color: var(--text, #1A1A1E); }
.tx-copy { align-self: flex-start; background: none; border: 0; padding: .2rem 0; color: var(--accent, #E8611A); font: inherit; font-size: .9rem; font-weight: 600; text-decoration: underline; text-underline-offset: 3px; cursor: pointer; }
.tx-check { display: flex; align-items: center; gap: .5rem; font-weight: 600; font-size: .95rem; cursor: pointer; }
.tx-check input { width: 1.15rem; height: 1.15rem; accent-color: var(--accent, #E8611A); }

/* ── Textile: where each print goes, and the silk inks (Oz, 25.11) ── */
.tx-where { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .75rem; margin-bottom: 1rem; }
.tx-where figure { margin: 0; display: flex; align-items: center; gap: .75rem; padding: .75rem; border: 1.5px solid var(--border, #ddd); border-radius: 14px; background: var(--bg, #fff); }
.tx-where figure.is-on { border-color: var(--accent, #E8611A); background: var(--accent-glow, rgba(232,97,26,.1)); }
.tx-where svg { flex: none; width: 64px; height: 64px; }
.tx-where .tx-shirt { fill: #fff; stroke: var(--text-mid, #4A4550); stroke-width: 2; stroke-linejoin: round; }
.tx-where .tx-a4, .tx-where .tx-a3 { fill: none; stroke: var(--accent, #E8611A); stroke-width: 1.6; stroke-dasharray: 3 2.5; }
.tx-where .tx-a3 { stroke-opacity: .5; }
.tx-where figcaption { display: flex; flex-direction: column; gap: .15rem; min-width: 0; }
.tx-where figcaption small { color: var(--text-mid, #4A4550); font-size: .82rem; }
.tx-inks { display: grid; grid-template-columns: repeat(auto-fill, minmax(72px, 1fr)); gap: .4rem; }
.tx-ink { display: flex; flex-direction: column; align-items: center; gap: .3rem; padding: .45rem .2rem; background: var(--bg, #fff); border: 1.5px solid var(--border, #ddd); border-radius: 12px; font: inherit; cursor: pointer; color: var(--text, #1A1A1E); }
.tx-ink span { width: 1.9rem; height: 1.9rem; border-radius: 50%; border: 1px solid rgba(0, 0, 0, .2); }
.tx-ink small { font-size: .74rem; line-height: 1.2; text-align: center; }
.tx-ink.is-on { border-color: var(--accent, #E8611A); background: var(--accent-glow, rgba(232,97,26,.1)); }
@media (max-width: 767px) {
  .tx-where { grid-template-columns: minmax(0, 1fr); }
  .tx-inks { grid-template-columns: repeat(4, minmax(0, 1fr)); }
}

/* ── Cart: shipping is settled at checkout (Oz, 25.11) ── */
.woocommerce-cart .wc-block-components-totals-shipping { display: none !important; }
.woocommerce-cart .wp-block-woocommerce-cart-order-summary-shipping-block::after {
  content: "דמי המשלוח יחושבו בקופה (משלוח רגיל 50 ₪, איסוף עצמי חינם)";
  display: block; padding: 12px 16px; font-size: .9rem; line-height: 1.5; color: var(--text-mid, #4A4550);
}
