/* TapReview concepts: shared structure for buttons, catalog cards, product dialog, cart drawer, FAQ,
   mobile bar, and the demo props (phone + Google review screen).
   Every concept sets its own tokens in its own stylesheet; this file only consumes them. */

/* OD-LAYOUT-PRIMITIVES v1 — structure only: display, flex/grid, overflow, wrapping, ratio, geometry.
   Put this @layer first; product CSS outside the layer wins ordinary layout rules.
   Native hidden and closed-dialog states take precedence over component display rules. */
@layer od-layout {
  [hidden]:not([hidden="until-found" i]) { display: none !important; }
  dialog:not([open]) { display: none !important; }

  :where(.od-stack,.od-row,.od-row-top,.od-cluster,.od-grid,.od-field,.od-stat,.od-cell,.od-tile) > :where(*) { min-width: 0; }

  .od-stack   { display: flex; flex-direction: column; gap: var(--od-gap, 8px); }
  .od-row     { display: flex; align-items: center; gap: var(--od-gap, 8px); }
  .od-row-top { display: flex; align-items: flex-start; gap: var(--od-gap, 8px); }
  .od-cluster { display: flex; flex-wrap: wrap; align-items: center; gap: var(--od-gap, 8px); }
  .od-fill    { flex: 1 1 0; min-width: 0; }
  .od-fixed   { flex: none; }
  .od-grid    { display: grid; gap: var(--od-gap, 12px); grid-template-columns: repeat(var(--od-cols, 3), minmax(0, 1fr)); }

  .od-stat, .od-field, .od-cell { display: grid; gap: var(--od-gap, 2px); }
  :where(.od-stat,.od-field,.od-cell) > :where(*) { display: block; }
  .od-tile { display: grid; grid-template-rows: auto 1fr; }
  :where(.od-tile) > :where(*) { display: block; }

  .od-media { display: block; width: 100%; height: auto; aspect-ratio: var(--od-ratio, auto); }
  .od-media-cover { object-fit: cover; }

  .od-icon { display: inline-block; inline-size: var(--od-icon-size, 1em); block-size: var(--od-icon-size, 1em); flex: none; }

  .od-truncate { display: block; max-width: 100%; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
  .od-clamp-2, .od-clamp-3 { display: -webkit-box; -webkit-box-orient: vertical; overflow: hidden; overflow-wrap: anywhere; }
  .od-clamp-2 { -webkit-line-clamp: 2; }
  .od-clamp-3 { -webkit-line-clamp: 3; }
  .od-lines-2 { min-height: calc(2 * 1.4em); }
  .od-nowrap  { white-space: nowrap; }
  .od-keep    { word-break: keep-all; overflow-wrap: anywhere; }

  .od-screen { display: grid; grid-template-rows: auto minmax(0, 1fr) auto; height: 100%; }
  .od-scroll { overflow-y: auto; overscroll-behavior: contain; min-height: 0; }

  .od-rail { display: flex; gap: var(--od-gap, 8px); overflow-x: auto; scroll-snap-type: x proximity; scrollbar-width: none;
             padding-inline: var(--od-rail-pad, 16px); scroll-padding-inline: var(--od-rail-pad, 16px); }
  .od-rail::-webkit-scrollbar { display: none; }
  :where(.od-rail) > :where(*) { flex: none; scroll-snap-align: start; }
  :where(.od-rail) > :where(:last-child) { margin-inline-end: var(--od-rail-pad, 16px); }

  .od-spacer { flex: none; visibility: hidden; pointer-events: none; }
  .od-touch  { min-width: 44px; min-height: 44px; }
}
:root [hidden]:where(:not([hidden="until-found" i])) { display: none; }
/* /OD-LAYOUT-PRIMITIVES v1 */

/* ─── Token defaults (each concept overrides) ─── */
:root {
  --bg: #ffffff;
  --surface: #f2f3f5;
  --surface-2: #e7e9ec;
  --media-bg: #f2f3f5;
  --ink: #101114;
  --ink-2: #565a62;
  --line: #e1e3e7;
  --accent: #101114;
  --accent-hover: #2c2f35;
  --accent-ink: #ffffff;
  --sale: #c4231b;
  --sale-ink: #ffffff;
  --star: #d99a00;
  --star-off: #dfe2e6;
  --wa: #0f7d43;
  --wa-hover: #0b6837;
  --wa-ink: #ffffff;
  --focus: #1a5cff;
  --overlay: rgba(10, 12, 16, .55);
  --dialog-bg: var(--bg);
  --radius: 16px;
  --radius-sm: 10px;
  --radius-btn: 999px;
  --font-display: system-ui, sans-serif;
  --font-body: system-ui, sans-serif;
  --shadow: 0 24px 64px rgba(10, 12, 16, .16);
  --wrap: 1200px;
  --gutter: 24px;
  --header-h: 72px;
  --mobile-bar-h: 0px;
  --dur-fast: 160ms;
  --dur: 240ms;
  --ease-out: cubic-bezier(.2, .8, .2, 1);
  --ease-in: cubic-bezier(.5, 0, .75, 0);
  --g-blue: #1a73e8;
}

/* ─── Base ─── */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: calc(var(--header-h) + 16px); }
body {
  margin: 0; background: var(--bg); color: var(--ink);
  font-family: var(--font-body); font-size: 17px; line-height: 1.6;
  -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility;
  padding-bottom: var(--mobile-bar-h);
}
img { max-width: 100%; }
h1, h2, h3, h4 { margin: 0; font-family: var(--font-display); line-height: 1.15; text-wrap: balance; }
p { margin: 0; text-wrap: pretty; }
ul, ol { margin: 0; padding: 0; list-style: none; }
figure { margin: 0; }
a { color: inherit; }
button, input, select { font: inherit; color: inherit; }
button { cursor: pointer; }
:focus-visible { outline: 3px solid var(--focus); outline-offset: 3px; border-radius: 6px; }
.wrap { width: min(var(--wrap), 100% - 2 * var(--gutter)); margin-inline: auto; }
.sr-only { position: absolute !important; width: 1px; height: 1px; margin: -1px; padding: 0; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
.skip { position: absolute; inset-inline-start: 16px; top: -64px; z-index: 100; padding: 12px 16px; border-radius: 8px; background: var(--accent); color: var(--accent-ink); text-decoration: none; font-weight: 700; }
.skip:focus { top: 12px; }
.text-link { color: var(--ink); font-weight: 700; text-decoration: underline; text-underline-offset: 4px; text-decoration-thickness: 1px; }
@media (hover: hover) { .text-link:hover { text-decoration-thickness: 2px; } }
.muted { color: var(--ink-2); }

/* ─── Buttons ─── */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 48px; padding: 12px 24px; border-radius: var(--radius-btn);
  border: 1.5px solid transparent; background: var(--surface); color: var(--ink);
  font-weight: 700; font-size: 16px; line-height: 1.2; text-decoration: none; text-align: center;
  transition: background-color var(--dur-fast) var(--ease-out), border-color var(--dur-fast) var(--ease-out), color var(--dur-fast) var(--ease-out), transform var(--dur-fast) var(--ease-out);
}
.btn:active { transform: translateY(1px); }
.btn:disabled, .btn[aria-disabled="true"] { opacity: .45; cursor: not-allowed; transform: none; }
.btn-lg { min-height: 56px; padding: 16px 32px; font-size: 17px; }
.btn-block { display: flex; width: 100%; }
.btn-primary { background: var(--accent); color: var(--accent-ink); border-color: var(--accent); }
.btn-outline { background: transparent; color: var(--ink); border-color: var(--ink); }
.btn-ghost { background: transparent; color: var(--ink); border-color: var(--line); }
.btn-wa { background: var(--wa); color: var(--wa-ink); border-color: var(--wa); }
.btn-light { background: #ffffff; color: #101114; border-color: #ffffff; }
.btn-outline-light { background: transparent; color: #ffffff; border-color: rgba(255,255,255,.6); }
@media (hover: hover) {
  .btn-primary:hover:not(:disabled) { background: var(--accent-hover); border-color: var(--accent-hover); color: var(--accent-ink); }
  .btn-outline:hover:not(:disabled) { background: var(--ink); color: var(--bg); }
  .btn-ghost:hover:not(:disabled) { border-color: var(--ink); }
  .btn-wa:hover { background: var(--wa-hover); border-color: var(--wa-hover); color: var(--wa-ink); }
  .btn-light:hover { background: #e9ebee; border-color: #e9ebee; color: #101114; }
  .btn-outline-light:hover { border-color: #ffffff; background: rgba(255,255,255,.1); color: #ffffff; }
}
.icon-btn {
  display: inline-grid; place-items: center; width: 44px; height: 44px; padding: 0;
  border-radius: 50%; border: 1px solid var(--line); background: var(--bg); color: var(--ink);
  --od-icon-size: 20px; transition: border-color var(--dur-fast) var(--ease-out), background-color var(--dur-fast) var(--ease-out);
}
.icon-btn .od-icon, .btn .od-icon, .cart-btn .od-icon { fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.icon-btn:disabled { opacity: .4; cursor: not-allowed; }
@media (hover: hover) { .icon-btn:hover:not(:disabled) { border-color: var(--ink); } }

/* ─── Cart button ─── */
.cart-btn {
  position: relative; display: inline-flex; align-items: center; gap: 8px;
  min-height: 44px; padding: 8px 16px; border-radius: var(--radius-btn);
  border: 1px solid var(--line); background: transparent; color: var(--ink);
  font-weight: 700; --od-icon-size: 20px;
}
@media (hover: hover) { .cart-btn:hover { border-color: var(--ink); } }
.cart-count {
  display: inline-grid; place-items: center; min-width: 24px; height: 24px; padding: 0 8px;
  border-radius: 999px; background: var(--surface-2); color: var(--ink); font-size: 13px; font-weight: 800; line-height: 1;
}
.cart-count.has-items { background: var(--accent); color: var(--accent-ink); }
.cart-count.bump { animation: bump 300ms var(--ease-out); }
@keyframes bump { 40% { transform: scale(1.3); } }

/* ─── Filters / sort ─── */
.shop-bar { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 16px; margin-bottom: 32px; }
.filters { display: flex; flex-wrap: wrap; gap: 8px; }
.chip {
  min-height: 44px; padding: 8px 16px; border-radius: var(--radius-btn);
  border: 1px solid var(--line); background: transparent; color: var(--ink);
  font-weight: 600; font-size: 15px;
  transition: background-color var(--dur-fast) var(--ease-out), border-color var(--dur-fast) var(--ease-out), color var(--dur-fast) var(--ease-out);
}
.chip[aria-pressed="true"] { background: var(--ink); border-color: var(--ink); color: var(--bg); }
@media (hover: hover) { .chip:hover:not([aria-pressed="true"]) { border-color: var(--ink); } }
.shop-tools { display: flex; align-items: center; gap: 16px; flex-wrap: wrap; }
.result-count { color: var(--ink-2); font-size: 15px; }
.sort { display: inline-flex; align-items: center; gap: 8px; font-size: 15px; }
.sort-label { color: var(--ink-2); }
.sort select {
  min-height: 44px; padding: 8px 40px 8px 16px; border-radius: var(--radius-sm);
  border: 1px solid var(--line); background-color: var(--bg); color: var(--ink);
  appearance: none; -webkit-appearance: none;
  background-image: linear-gradient(45deg, transparent 50%, currentColor 50%), linear-gradient(135deg, currentColor 50%, transparent 50%);
  background-position: 18px 50%, 23px 50%; background-size: 5px 5px; background-repeat: no-repeat;
}

/* ─── Product grid + cards (markup rendered by app.js) ─── */
.product-grid { display: grid; gap: 32px 24px; grid-template-columns: repeat(3, minmax(0, 1fr)); }
.card { position: relative; display: flex; flex-direction: column; min-width: 0; animation: cardIn 360ms var(--ease-out) both; animation-delay: calc(var(--i, 0) * 40ms); }
@keyframes cardIn { from { opacity: 0; transform: translateY(12px); } }
.card-media {
  position: relative; display: block; width: 100%; padding: 0; border: 0; overflow: hidden;
  background: var(--media-bg); border-radius: var(--radius); cursor: pointer;
}
.card-img { transition: transform 400ms var(--ease-out); }
.card-img-alt {
  position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain;
  background: var(--media-bg); opacity: 0; transition: opacity 300ms var(--ease-out);
}
@media (hover: hover) {
  .card.has-alt .card-media:hover .card-img-alt { opacity: 1; }
  .card:not(.has-alt) .card-media:hover .card-img { transform: scale(1.03); }
}
.sale-badge {
  position: absolute; top: 12px; inset-inline-start: 12px; z-index: 2;
  padding: 4px 12px; border-radius: var(--radius-btn);
  background: var(--sale); color: var(--sale-ink); font-size: 13px; font-weight: 800; line-height: 1.5;
}
.gallery-count {
  position: absolute; bottom: 12px; inset-inline-end: 12px; z-index: 2;
  display: inline-flex; align-items: center; gap: 4px; padding: 4px 8px; border-radius: 8px;
  background: rgba(16,17,20,.72); color: #fff; font-size: 12px; font-weight: 700; line-height: 1.4; --od-icon-size: 14px;
}
.gallery-count .od-icon { fill: none; stroke: currentColor; stroke-width: 2; }
.card-body { display: flex; flex-direction: column; gap: 4px; flex: 1; padding-top: 16px; }
.card-kind { display: block; color: var(--ink-2); font-size: 13px; font-weight: 600; letter-spacing: .02em; }
.card-name { font-size: 19px; font-weight: 700; line-height: 1.35; }
.card-prices { display: flex; flex-direction: column; gap: 2px; margin-bottom: 16px; }
.card-price { display: block; font-size: 20px; font-weight: 800; white-space: nowrap; font-variant-numeric: tabular-nums; }
.price-from { font-size: 14px; font-weight: 600; color: var(--ink-2); }
.price-was { margin-inline-end: 8px; color: var(--ink-2); font-weight: 500; font-size: 16px; }
.card-price-sub { display: block; color: var(--ink-2); font-size: 14px; }
.card-body .btn { margin-top: auto; }

/* Placeholder art (not used while every product has photos) */
.ph { display: grid; place-items: center; gap: 8px; aspect-ratio: 1; padding: 24px; background: var(--surface); color: var(--ink-2); text-align: center; }
.ph-icon { --od-icon-size: 40px; fill: none; stroke: currentColor; stroke-width: 1.5; }
.ph-name { display: block; font-weight: 700; color: var(--ink); }
.ph-sub { display: block; font-size: 14px; }
.ph-sm { padding: 8px; }
.ph-sm .ph-icon { --od-icon-size: 24px; }

/* ─── Dialog shared motion ─── */
dialog { color: var(--ink); }
dialog::backdrop { background: var(--overlay); }
dialog[open] { animation: dlgFade 240ms var(--ease-out); }
dialog[open]::backdrop { animation: dlgFade 240ms var(--ease-out); }
dialog.closing { animation: dlgFadeOut 160ms var(--ease-in) forwards; }
dialog.closing::backdrop { animation: dlgFadeOut 160ms var(--ease-in) forwards; }
@keyframes dlgFade { from { opacity: 0; } }
@keyframes dlgFadeOut { to { opacity: 0; } }

/* ─── Product dialog ─── */
.modal {
  width: min(1080px, 100% - 32px); max-width: none; max-height: calc(100% - 32px);
  padding: 0; border: 0; border-radius: calc(var(--radius) + 4px);
  background: var(--dialog-bg); box-shadow: var(--shadow); overflow: auto; overscroll-behavior: contain;
}
.modal[open] .modal-in { animation: modalIn 280ms var(--ease-out); }
.modal.closing .modal-in { animation: modalOut 160ms var(--ease-in) forwards; }
@keyframes modalIn { from { transform: translateY(16px) scale(.98); } }
@keyframes modalOut { to { transform: translateY(8px) scale(.99); } }
.modal-in { position: relative; display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr); gap: 40px; padding: 32px; }
.modal-close { position: absolute; top: 16px; inset-inline-end: 16px; z-index: 3; }
.pd-gallery { display: flex; flex-direction: column; gap: 12px; min-width: 0; }
.pd-stage { position: relative; aspect-ratio: 1; border-radius: var(--radius); background: var(--media-bg); overflow: hidden; }
.pd-main { width: 100%; height: 100%; object-fit: contain; }
.pd-nav {
  position: absolute; top: 50%; transform: translateY(-50%); z-index: 2;
  display: grid; place-items: center; width: 44px; height: 44px; padding: 0; border-radius: 50%;
  border: 0; background: rgba(255,255,255,.92); color: #101114; box-shadow: 0 4px 16px rgba(0,0,0,.14); --od-icon-size: 20px;
}
.pd-nav .od-icon { fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.pd-prev { right: 12px; }
.pd-next { left: 12px; }
.pd-counter { position: absolute; bottom: 12px; left: 50%; transform: translateX(-50%); padding: 4px 12px; border-radius: 999px; background: rgba(16,17,20,.72); color: #fff; font-size: 13px; font-weight: 700; font-variant-numeric: tabular-nums; }
.pd-thumbs { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 8px; }
.pd-thumb { padding: 0; border: 2px solid transparent; border-radius: var(--radius-sm); overflow: hidden; background: var(--media-bg); aspect-ratio: 1; }
.pd-thumb img { width: 100%; height: 100%; object-fit: contain; }
.pd-thumb[aria-pressed="true"] { border-color: var(--ink); }
.pd-note { color: var(--ink-2); font-size: 14px; }
.pd-info { display: flex; flex-direction: column; gap: 16px; min-width: 0; padding-top: 8px; }
.pd-kind { color: var(--ink-2); font-size: 14px; font-weight: 600; }
.pd-info h2 { font-size: clamp(26px, 3vw, 34px); padding-inline-end: 48px; }
.pd-price { display: flex; flex-wrap: wrap; align-items: baseline; gap: 8px 12px; }
.pd-price-now { font-size: 30px; font-weight: 800; font-variant-numeric: tabular-nums; }
.pd-unit { color: var(--ink-2); font-size: 15px; }
.pd-unit:empty { display: none; }
.pd-ship { padding: 4px 12px; border-radius: 999px; background: var(--surface); color: var(--ink); font-size: 13px; font-weight: 700; }
.pd-sum { color: var(--ink-2); font-weight: 600; }
.pd-short { color: var(--ink-2); }
.pd-option-groups { display: flex; flex-direction: column; gap: 16px; }
.pd-options { margin: 0; padding: 0; border: 0; min-width: 0; }
.pd-options legend { padding: 0; margin-bottom: 8px; font-weight: 700; font-size: 15px; }
.opt-list { display: flex; flex-wrap: wrap; gap: 8px; }
.opt { position: relative; }
.opt input { position: absolute; opacity: 0; inset: 0; margin: 0; cursor: pointer; }
.opt span {
  display: inline-flex; align-items: center; min-height: 44px; padding: 8px 16px;
  border: 1.5px solid var(--line); border-radius: var(--radius-sm); font-weight: 600; font-size: 15px;
  transition: border-color var(--dur-fast) var(--ease-out), background-color var(--dur-fast) var(--ease-out);
}
.opt input:checked + span { border-color: var(--ink); background: var(--surface); box-shadow: inset 0 0 0 1px var(--ink); }
.opt input:focus-visible + span { outline: 3px solid var(--focus); outline-offset: 2px; }
.multi-list { display: flex; flex-direction: column; gap: 8px; }
.multi-row { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 8px 8px 8px 16px; padding-inline-start: 16px; border: 1px solid var(--line); border-radius: var(--radius-sm); }
.multi-name { font-weight: 700; }
.stepper { display: inline-flex; align-items: center; gap: 8px; }
.stepper output { min-width: 28px; text-align: center; font-weight: 800; font-variant-numeric: tabular-nums; }
.pd-qty { display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.qty-label { font-weight: 700; font-size: 15px; }
.pd-help { color: var(--ink-2); font-size: 15px; text-align: center; }
.pd-needs { padding: 16px; border-radius: var(--radius-sm); background: var(--surface); }
.pd-needs h3 { font-family: var(--font-body); font-size: 15px; margin-bottom: 4px; }
.pd-needs p { font-size: 15px; }
.pd-facts { display: flex; flex-direction: column; gap: 8px; font-size: 15px; --od-icon-size: 20px; }
.pd-facts li { display: flex; align-items: center; gap: 12px; }
.pd-facts .od-icon { fill: none; stroke: var(--ink); stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }

/* ─── Cart drawer ─── */
.drawer {
  margin: 0; margin-inline-start: auto; inset-block: 0; height: 100%; max-height: none;
  width: min(440px, 100%); max-width: none; padding: 0; border: 0;
  background: var(--dialog-bg); box-shadow: var(--shadow);
}
.drawer[open] .drawer-in { animation: drawerIn 300ms var(--ease-out); }
.drawer.closing .drawer-in { animation: drawerOut 180ms var(--ease-in) forwards; }
@keyframes drawerIn { from { transform: translateX(-100%); } }
@keyframes drawerOut { to { transform: translateX(-100%); } }
.drawer-in { display: grid; grid-template-rows: auto minmax(0, 1fr) auto; height: 100%; }
.drawer-head { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 20px 24px; border-bottom: 1px solid var(--line); }
.drawer-head h2 { font-size: 22px; }
.drawer-body { overflow-y: auto; overscroll-behavior: contain; padding: 16px 24px; min-height: 0; }
.cart-empty { display: flex; flex-direction: column; align-items: flex-start; gap: 8px; padding-block: 32px; }
.cart-empty-title { font-weight: 800; font-size: 19px; }
.cart-empty .btn { margin-top: 8px; }
.cart-list { display: flex; flex-direction: column; }
.cart-item { display: grid; grid-template-columns: 80px minmax(0, 1fr); gap: 16px; padding-block: 16px; border-bottom: 1px solid var(--line); }
.ci-thumb { border-radius: var(--radius-sm); overflow: hidden; background: var(--media-bg); align-self: start; }
.ci-body { display: flex; flex-direction: column; gap: 8px; min-width: 0; }
.ci-name { display: block; font-weight: 700; line-height: 1.35; }
.ci-opt { display: block; color: var(--ink-2); font-size: 14px; }
.ci-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.ci-price { font-weight: 800; white-space: nowrap; font-variant-numeric: tabular-nums; }
.ci-remove { min-height: 32px; padding: 4px 0; border: 0; background: none; color: var(--ink-2); font-size: 14px; text-decoration: underline; text-underline-offset: 3px; }
@media (hover: hover) { .ci-remove:hover { color: var(--ink); } }
.drawer-foot { display: flex; flex-direction: column; gap: 16px; padding: 20px 24px 24px; border-top: 1px solid var(--line); }
.totals { display: flex; flex-direction: column; gap: 8px; margin: 0; }
.totals div { display: flex; justify-content: space-between; gap: 16px; }
.totals dt { color: var(--ink-2); }
.totals dd { margin: 0; font-weight: 700; font-variant-numeric: tabular-nums; }
.total-row { padding-top: 8px; border-top: 1px dashed var(--line); }
.total-row dt { color: var(--ink); font-weight: 800; }
.total-row dd { font-size: 20px; font-weight: 800; }
.foot-note { color: var(--ink-2); font-size: 13px; text-align: center; }

/* ─── FAQ ─── */
.faq { display: flex; flex-direction: column; }
.faq details { border-bottom: 1px solid var(--line); }
.faq summary {
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  min-height: 64px; padding-block: 16px; cursor: pointer; list-style: none;
  font-weight: 700; font-size: 18px;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: ""; flex: none; width: 12px; height: 12px;
  border-inline-end: 2px solid currentColor; border-bottom: 2px solid currentColor;
  transform: rotate(45deg) translateY(-3px); transition: transform var(--dur) var(--ease-out);
}
.faq details[open] summary::after { transform: rotate(-135deg) translateY(-3px); }
.faq details p { padding-bottom: 24px; color: var(--ink-2); max-width: 68ch; }

/* ─── Mobile bar ─── */
.mobile-bar { display: none; }
@media (max-width: 760px) {
  :root { --mobile-bar-h: 80px; }
  .mobile-bar {
    display: block; position: fixed; inset-inline: 0; bottom: 0; z-index: 40;
    padding: 12px 16px calc(12px + env(safe-area-inset-bottom));
    background: var(--bg); border-top: 1px solid var(--line); box-shadow: 0 -8px 24px rgba(0,0,0,.08);
  }
  .mobile-bar-in { display: grid; grid-template-columns: 1.4fr 1fr; gap: 8px; }
  .mobile-bar .btn { min-height: 52px; padding-inline: 12px; font-size: 15px; }
}

/* ─── Responsive shared ─── */
@media (max-width: 1023px) {
  .product-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 24px 16px; }
}
@media (max-width: 860px) {
  .modal-in { grid-template-columns: minmax(0, 1fr); gap: 24px; padding: 20px; }
  .modal-close { top: 12px; inset-inline-end: 12px; background: var(--dialog-bg); }
}
@media (max-width: 600px) {
  :root { --gutter: 16px; }
  body { font-size: 16px; }
  .modal { width: 100%; max-height: 100%; height: 100%; border-radius: 0; }
  .card-name { font-size: 16px; }
  .card-price { font-size: 17px; }
  .card-body .btn { min-height: 44px; padding: 8px 12px; font-size: 14px; }
  .shop-bar { align-items: stretch; }
  .filters { flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; margin-inline: calc(-1 * var(--gutter)); padding-inline: var(--gutter); }
  .filters::-webkit-scrollbar { display: none; }
  .chip { flex: none; }
}

/* ═══════════ Demo props, shared by every concept ═══════════
   Sizes inside the phone and the review screen use container units (cqw),
   so each concept only sets the outer width and choreography. */
.demo-stage { position: absolute; inset: 0; overflow: hidden; container-type: inline-size; }
.demo-toggle {
  position: absolute; z-index: 10; display: grid; place-items: center; width: 44px; height: 44px; padding: 0;
  border-radius: 50%; border: 0; background: rgba(255,255,255,.92); color: #101114;
  box-shadow: 0 4px 14px rgba(0,0,0,.18); --od-icon-size: 18px;
}
.demo-toggle .od-icon { fill: currentColor; stroke: currentColor; stroke-width: 1.5; stroke-linejoin: round; }
.demo-toggle .icon-play { display: none; }
.demo-toggle[aria-pressed="true"] .icon-play { display: inline-block; }
.demo-toggle[aria-pressed="true"] .icon-pause { display: none; }
.demo-stage.is-paused *, .demo-stage.is-paused, .demo-stage.is-offscreen *, .demo-stage.is-offscreen { animation-play-state: paused !important; }
@media (prefers-reduced-motion: reduce) { .demo-toggle { display: none; } }

/* Phone */
.dv-phone { position: absolute; aspect-ratio: 9 / 19.4; will-change: transform, opacity; }
.dv-phone-shell {
  position: absolute; inset: 0; border-radius: 16% / 7.4%;
  background: linear-gradient(150deg, #3a3e45 0%, #0b0c0e 40%, #24272c 100%);
  box-shadow: 0 6cqw 10cqw rgba(0,0,0,.35), 0 1.4cqw 3cqw rgba(0,0,0,.25), inset 0 0 0 .3cqw rgba(255,255,255,.14);
}
.dv-phone-shell::before, .dv-phone-shell::after {
  content: ""; position: absolute; width: 1.6%; border-radius: 2px; background: #2a2d33;
}
.dv-phone-shell::before { right: -1.2%; top: 20%; height: 9%; }
.dv-phone-shell::after { left: -1.2%; top: 17%; height: 14%; }
.dv-screen {
  position: absolute; inset: 2.6% 5.6%; border-radius: 12% / 5.6%; overflow: hidden;
  background: #0b0f0d; container-type: inline-size;
}
.dv-layer { position: absolute; inset: 0; }
.dv-island { position: absolute; top: 2.2%; left: 34%; width: 32%; height: 3.4%; border-radius: 999px; background: #000; z-index: 9; }
.dv-glare { position: absolute; inset: 0; z-index: 8; pointer-events: none; background: linear-gradient(115deg, rgba(255,255,255,.18) 0%, rgba(255,255,255,0) 32%); }
.dv-status {
  position: absolute; z-index: 7; top: 0; left: 0; right: 0;
  display: flex; justify-content: space-between; align-items: center; padding: 5cqw 8cqw 0;
  font-family: system-ui, sans-serif; font-size: 4.6cqw; font-weight: 700; line-height: 1; color: #fff; direction: ltr;
}
.dv-lock {
  z-index: 1; display: flex; flex-direction: column; align-items: center; padding-top: 26%;
  background: radial-gradient(120% 70% at 50% 0%, #26302c 0%, #0b0f0d 70%); color: #f3f6f4; text-align: center;
}
.dv-lock-time { display: block; font-family: system-ui, sans-serif; font-size: 20cqw; font-weight: 600; letter-spacing: -.03em; line-height: 1; direction: ltr; }
.dv-lock-hint { display: block; margin-top: 4cqw; font-size: 5.4cqw; line-height: 1.3; color: #c9d3ce; }
.dv-lock-nfc { position: relative; display: block; width: 26cqw; height: 26cqw; margin-top: 22cqw; }
.dv-lock-nfc i { position: absolute; inset: 0; border-radius: 50%; border: 1cqw solid rgba(255,255,255,.75); opacity: 0; animation: dvPulse 1.6s var(--ease-out) infinite; }
.dv-lock-nfc i:nth-child(2) { animation-delay: .4s; }
.dv-lock-nfc i:nth-child(3) { animation-delay: .8s; }
@keyframes dvPulse { 0% { opacity: .9; transform: scale(.3); } 100% { opacity: 0; transform: scale(1.15); } }

/* Google review screen: used inside the phone or as a standalone card (.rv) */
.rv {
  container-type: inline-size; display: flex; flex-direction: column;
  background: #ffffff; color: #202124; text-align: right; font-family: var(--font-body);
}
.rv-in { display: flex; flex-direction: column; gap: 3.2cqw; height: 100%; padding: 18cqw 7cqw 8cqw; }
.rv-card .rv-in { padding: 7cqw; gap: 3.6cqw; }
.rv-head { display: flex; align-items: center; gap: 2cqw; font-size: 4.8cqw; font-weight: 600; color: #3c4043; line-height: 1; }
.rv-g { width: 7.4cqw; height: 7.4cqw; flex: none; }
.rv-title { display: block; font-size: 8cqw; font-weight: 800; line-height: 1.15; color: #202124; font-family: var(--font-display); }
.rv-biz { display: flex; align-items: center; gap: 3cqw; }
.rv-avatar { display: block; flex: none; width: 11cqw; height: 11cqw; border-radius: 50%; background: #e8eaed; }
.rv-biz-text { display: grid; gap: 1cqw; }
.rv-biz-name { display: block; font-size: 5.4cqw; font-weight: 700; line-height: 1.2; }
.rv-biz-sub { display: block; font-size: 4.2cqw; color: #5f6368; line-height: 1.2; }
.rv-stars { display: flex; justify-content: center; gap: 2.2cqw; margin-block: 2cqw; direction: ltr; }
.rv-star { position: relative; display: block; width: 13cqw; height: 13cqw; }
.rv-star svg { position: absolute; inset: 0; width: 100%; height: 100%; }
.rv-star .off { fill: #dadce0; }
.rv-star .on { fill: #fbbc04; opacity: 0; transform: scale(.4); transform-origin: 50% 55%; }
.rv-lines { display: grid; gap: 2.4cqw; padding: 4cqw; border: .4cqw solid #dadce0; border-radius: 3cqw; }
.rv-line { display: block; height: 2.6cqw; border-radius: 2cqw; background: #e8eaed; transform-origin: right center; transform: scaleX(0); }
.rv-line:nth-child(2) { width: 86%; }
.rv-line:nth-child(3) { width: 58%; }
.rv-btn { position: relative; display: block; margin-top: auto; padding: 3.6cqw; border-radius: 99cqw; background: var(--g-blue); color: #fff; text-align: center; font-size: 5.2cqw; font-weight: 700; line-height: 1.2; }
.rv-done {
  position: absolute; inset: 0; z-index: 4; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3cqw;
  background: #ffffff; opacity: 0; text-align: center;
}
.rv-check { position: relative; display: grid; place-items: center; width: 24cqw; height: 24cqw; border-radius: 50%; background: #188038; }
.rv-check svg { width: 52%; height: 52%; fill: none; stroke: #fff; stroke-width: 3; stroke-linecap: round; stroke-linejoin: round; }
.rv-done-title { display: block; font-size: 7.4cqw; font-weight: 800; font-family: var(--font-display); line-height: 1.2; color: #202124; }
.rv-done-sub { display: block; font-size: 4.8cqw; color: #5f6368; line-height: 1.3; }

/* NFC rings */
.dv-rings { position: absolute; pointer-events: none; }
.dv-rings i { position: absolute; inset: 0; border-radius: 50%; opacity: 0; border: .45cqw solid var(--ring, #ffffff); }

/* Search mock (why-reviews section) */
.search-mock { background: #ffffff; color: #202124; border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow); font-family: system-ui, -apple-system, "Segoe UI", sans-serif; }
.sm-bar { display: flex; align-items: center; gap: 12px; margin: 20px; padding: 12px 20px; border-radius: 999px; border: 1px solid #dfe1e5; box-shadow: 0 1px 6px rgba(32,33,36,.18); --od-icon-size: 20px; }
.sm-bar .od-icon { fill: none; stroke: #5f6368; stroke-width: 2; stroke-linecap: round; }
.sm-query { flex: 1; font-size: 17px; color: #202124; }
.sm-caret { display: inline-block; width: 2px; height: 1.1em; margin-inline-start: 2px; vertical-align: -3px; background: #1a73e8; animation: caret 1s steps(1) infinite; }
@keyframes caret { 50% { opacity: 0; } }
.sm-tag { flex: none; padding: 2px 10px; border-radius: 999px; background: #f1f3f4; color: #5f6368; font-size: 12px; font-weight: 700; }
.sm-panel { display: grid; gap: 8px; padding: 4px 24px 24px; }
.sm-name { font-size: 22px; font-weight: 700; color: #202124; line-height: 1.3; }
.sm-rating { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; font-size: 15px; color: #4d5156; }
.sm-rating b { color: #202124; font-size: 16px; }
.sm-stars { color: #f9ab00; letter-spacing: 2px; font-size: 17px; }
.sm-type { color: #4d5156; font-size: 14px; }
.sm-actions { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 4px; }
.sm-actions span { padding: 6px 14px; border-radius: 999px; border: 1px solid #dadce0; color: #1a73e8; font-size: 14px; font-weight: 600; }
.sm-review { margin-top: 8px; padding-top: 16px; border-top: 1px solid #ebebeb; display: grid; gap: 4px; }
.sm-review-who { font-size: 14px; font-weight: 700; color: #202124; }
.sm-review-text { font-size: 15px; color: #4d5156; }
.sm-note { padding: 12px 24px; background: #f8f9fa; color: #5f6368; font-size: 13px; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: 1ms !important; animation-iteration-count: 1 !important; transition-duration: 1ms !important; }
  .sm-caret { animation: none; }
}
