@import url("https://fonts.googleapis.com/css2?family=Bricolage+Grotesque:opsz,wght@12..96,500..800&family=Instrument+Sans:wght@400..700&family=Barlow+Condensed:wght@600;700&family=Barlow:wght@400;500;600;700&family=Fredoka:wght@500..700&family=Figtree:wght@400..700&family=Instrument+Serif&family=Fraunces:opsz,wght@9..144,600..800&display=swap");

/* =====================================================================
   CutCode Cardápio — estilos dos componentes (HTML/CSS sem framework)
   Todos os valores vêm dos tokens (tokens.css). Prefixo: cd-
   ===================================================================== */

:root { --display-weight: 700; --display-tracking: -0.01em; --tabbar-space: calc(var(--tabbar-h) + var(--tabbar-inset) + env(safe-area-inset-bottom, 0px)); }

/* ---------- Base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html, body { margin: 0; }
body { font-family: var(--font-text); color: var(--text); background: var(--bg); -webkit-font-smoothing: antialiased; -webkit-tap-highlight-color: transparent; }
.cd-root { font-family: var(--font-text); color: var(--text); background: var(--bg); font-size: 15px; line-height: 21px; }
h1, h2, h3, h4 { text-wrap: balance; margin: 0; }
p { text-wrap: pretty; margin: 0; }
button, input, textarea, select { font: inherit; color: inherit; }
button { cursor: pointer; }
img, video, svg { display: block; }
.num, .t-price, .t-metric, .t-metric-sm, .t-display { font-variant-numeric: tabular-nums; }
.t-display, .t-title-lg, .t-title-md { font-family: var(--font-display); font-weight: var(--display-weight); letter-spacing: var(--display-tracking); }
.t-display { font-size: var(--fs-display); line-height: 1.1; }
.t-title-lg { font-size: var(--fs-title-lg); line-height: 1.15; }
.t-title-md { font-size: var(--fs-title-md); line-height: 1.22; }
.t-title-sm { font-size: var(--fs-title-sm); }
.t-body, .t-body-strong { font-size: var(--fs-body); }
.muted { color: var(--text-muted); }
.sr-only { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* Foco: anel neutro de 2 px com 2 px de folga; sobre mídia, branco com halo escuro */
:focus { outline: none; }
:focus-visible { outline: 2px solid var(--focus-ring); outline-offset: 2px; }
.on-media :focus-visible, .cd-media :focus-visible { outline-color: var(--focus-ring-media); box-shadow: 0 0 0 4px rgba(0, 0, 0, 0.55); }

/* Ícones: um conjunto, traço 2 px, cantos redondos */
.cd-i { width: var(--icon); height: var(--icon); flex: none; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.cd-i--lg { width: var(--icon-lg); height: var(--icon-lg); }
.cd-i--sm { width: 18px; height: 18px; }
.cd-i--xs { width: 14px; height: 14px; }

/* Toque: tudo que é botão encolhe a 96% */
.cd-press { transition: transform var(--dur-press) var(--ease-standard), background-color var(--dur-fast) var(--ease-standard), color var(--dur-fast); }
.cd-press:active:not(:disabled):not([aria-disabled="true"]) { transform: scale(0.96); }

/* ---------- Botões ---------- */
.cd-btn { display: inline-flex; align-items: center; justify-content: center; gap: var(--space-2); min-height: var(--tap-comfort); padding: 0 var(--space-5); border: 0; border-radius: var(--radius-pill); background: var(--accent); color: var(--on-accent); font-weight: 600; font-size: 15px; line-height: 20px; text-decoration: none; white-space: nowrap; transition: transform var(--dur-press) var(--ease-standard), background-color var(--dur-fast) var(--ease-standard); }
.cd-btn:hover { background: var(--accent-hover); }
.cd-btn:active:not(:disabled):not([aria-disabled="true"]) { transform: scale(0.96); background: var(--accent-pressed); }
.cd-btn--secondary { background: var(--surface-sunken); color: var(--text); }
.cd-btn--secondary:hover { background: var(--border); }
.cd-btn--secondary:active:not(:disabled) { background: var(--border); }
.cd-btn--ghost { background: transparent; color: var(--text); }
.cd-btn--ghost:hover, .cd-btn--ghost:active:not(:disabled) { background: var(--surface-sunken); }
.cd-btn--sm { min-height: var(--tap-min); padding: 0 var(--space-4); font-size: 14px; }
.cd-btn--block { width: 100%; }
.cd-btn--rect { border-radius: var(--radius-md); }
.cd-btn:disabled, .cd-btn[aria-disabled="true"] { opacity: var(--opacity-disabled); cursor: not-allowed; }
.cd-btn[aria-busy="true"] { pointer-events: none; }
.cd-btn[aria-busy="true"] .cd-btn__label { opacity: 0.0; }
.cd-btn[aria-busy="true"]::after { content: ""; position: absolute; width: 18px; height: 18px; border-radius: 50%; border: 2px solid currentColor; border-right-color: transparent; animation: cd-spin 700ms linear infinite; }
.cd-btn { position: relative; }
.cd-btn--onmedia { background: var(--accent); color: var(--on-accent); box-shadow: 0 2px 10px rgba(0, 0, 0, 0.25); }
.cd-iconbtn { display: inline-grid; place-items: center; width: var(--tap-min); height: var(--tap-min); padding: 0; border: 0; border-radius: var(--radius-pill); background: transparent; color: inherit; transition: transform var(--dur-press) var(--ease-standard), background-color var(--dur-fast); }
.cd-iconbtn:hover { background: color-mix(in srgb, currentColor 8%, transparent); }
.cd-iconbtn:active:not(:disabled) { transform: scale(0.96); }
.cd-iconbtn:disabled { opacity: var(--opacity-disabled); }
.cd-spinner { width: 18px; height: 18px; border-radius: 50%; border: 2px solid currentColor; border-right-color: transparent; animation: cd-spin 700ms linear infinite; flex: none; }
@keyframes cd-spin { to { transform: rotate(360deg); } }

/* ---------- Mídia (foto, carrossel, vídeo) ---------- */
.cd-media { position: relative; overflow: hidden; background: var(--media-empty); border-radius: var(--radius-media); }
.cd-media--45 { aspect-ratio: 4 / 5; }
.cd-media--916 { aspect-ratio: 9 / 16; }
.cd-media--11 { aspect-ratio: 1 / 1; }
.cd-media > img, .cd-media > video, .cd-media__fill { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.cd-media--loading::after { content: ""; position: absolute; inset: 0; background: linear-gradient(100deg, transparent 30%, rgba(255, 255, 255, 0.18) 50%, transparent 70%) var(--media-empty); background-size: 200% 100%; animation: cd-shimmer 1.4s linear infinite; }
@keyframes cd-shimmer { from { background-position: 150% 0; } to { background-position: -50% 0; } }
.cd-shade { position: absolute; inset: auto 0 0 0; height: 45%; background: linear-gradient(to bottom, rgba(0, 0, 0, 0), var(--media-shade)); pointer-events: none; }
.cd-media__error { position: absolute; inset: 0; display: grid; place-content: center; justify-items: center; gap: var(--space-2); color: var(--text-muted); text-align: center; padding: var(--space-4); }
.cd-soldout .cd-media > img, .cd-soldout .cd-media > video, .cd-soldout .cd-media__fill { filter: grayscale(1); opacity: var(--opacity-soldout); }

/* Carrossel 4:5 com snap */
.cd-carousel { display: flex; overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none; height: 100%; }
.cd-carousel::-webkit-scrollbar { display: none; }
.cd-carousel > * { flex: 0 0 100%; scroll-snap-align: start; position: relative; height: 100%; }
.cd-carousel img { width: 100%; height: 100%; object-fit: cover; }
.cd-count { position: absolute; top: var(--space-3); right: var(--space-3); padding: 2px var(--space-2); border-radius: var(--radius-pill); background: rgba(0, 0, 0, 0.6); color: var(--on-media); font-size: 12px; line-height: 18px; font-weight: 600; font-variant-numeric: tabular-nums; }
.cd-dots { display: flex; gap: 4px; justify-content: center; }
.cd-dots span { width: 6px; height: 6px; border-radius: 50%; background: var(--border-strong); opacity: 0.45; transition: opacity var(--dur-fast), transform var(--dur-fast); }
.cd-dots span[aria-current="true"] { background: var(--accent-text); opacity: 1; transform: scale(1.15); }
.cd-videoflag { position: absolute; top: var(--space-3); right: var(--space-3); color: var(--on-media); filter: drop-shadow(0 1px 2px rgba(0, 0, 0, 0.6)); }
.cd-mute { position: absolute; right: var(--space-2); bottom: var(--space-2); width: var(--tap-min); height: var(--tap-min); display: grid; place-items: center; border: 0; border-radius: 50%; background: rgba(0, 0, 0, 0.55); color: var(--on-media); }

/* ---------- Selo (Mais pedido / Novo) ---------- */
.cd-badge { display: inline-flex; align-items: center; gap: var(--space-1); height: 24px; padding: 0 var(--space-2); border-radius: var(--radius-pill); font-size: 12px; line-height: 16px; font-weight: 600; white-space: nowrap; }
.cd-badge--top { background: var(--accent-soft); color: var(--accent-on-soft); }
.cd-badge--new { background: var(--surface-sunken); color: var(--text); }
.cd-badge--soldout { background: var(--surface-sunken); color: var(--text-muted); }
.cd-badge--veg { background: var(--success-soft); color: var(--success); }
.cd-badge--demo { background: var(--warning-soft); color: var(--warning); }
.cd-media .cd-badge { position: absolute; top: var(--space-3); left: var(--space-3); background: rgba(0, 0, 0, 0.62); color: var(--on-media); }

/* ---------- Chip de filtro ---------- */
.cd-chips { display: flex; gap: var(--space-2); overflow-x: auto; scrollbar-width: none; padding: 0 var(--space-4); }
.cd-chips::-webkit-scrollbar { display: none; }
.cd-chip { display: inline-flex; align-items: center; gap: var(--space-1); min-height: 36px; padding: 0 var(--space-3); border: 1px solid transparent; border-radius: var(--radius-pill); background: var(--surface-sunken); color: var(--text); font-size: 14px; font-weight: 500; white-space: nowrap; position: relative; transition: background-color var(--dur-fast), color var(--dur-fast), transform var(--dur-press) var(--ease-standard); }
.cd-chip::before { content: ""; position: absolute; inset: -4px 0; }
.cd-chip[aria-pressed="true"] { background: var(--accent-soft); color: var(--accent-on-soft); border-color: currentColor; }
.cd-chip:active { transform: scale(0.96); }

/* =========================== CLIENTE =========================== */

/* ---------- Tela do app (moldura de 390 px usada nas telas montadas) ---------- */
.cd-app { position: relative; height: 100%; overflow: hidden; background: var(--bg); color: var(--text); font-family: var(--font-text); }
.cd-scroll { height: 100%; overflow-y: auto; scrollbar-width: none; padding-bottom: calc(var(--tabbar-space) + var(--space-10)); }
.cd-scroll::-webkit-scrollbar { display: none; }
.cd-topbar { position: sticky; top: 0; z-index: var(--z-sticky); display: flex; align-items: center; gap: var(--space-2); height: 52px; padding: 0 var(--space-2) 0 var(--space-4); background: var(--bg); }
.cd-topbar__title { flex: 1; font-family: var(--font-display); font-weight: var(--display-weight); font-size: 20px; letter-spacing: var(--display-tracking); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.cd-topbar__mesa { display: inline-flex; align-items: center; gap: var(--space-1); padding: 0 var(--space-3); height: 32px; border-radius: var(--radius-pill); background: var(--surface-sunken); font-size: 13px; font-weight: 600; }

/* ---------- Barra de abas flutuante em pílula ---------- */
.cd-tabbar { position: absolute; left: var(--tabbar-inset); right: var(--tabbar-inset); bottom: calc(var(--tabbar-inset) + env(safe-area-inset-bottom, 0px)); z-index: var(--z-tabbar); height: var(--tabbar-h); display: grid; grid-template-columns: repeat(5, 1fr); padding: 5px; border-radius: var(--radius-pill); background: var(--tabbar-bg); -webkit-backdrop-filter: blur(var(--blur-tabbar)) saturate(1.5); backdrop-filter: blur(var(--blur-tabbar)) saturate(1.5); border: 1px solid var(--tabbar-line); box-shadow: var(--shadow-tabbar); color: var(--tabbar-icon); max-width: 420px; margin: 0 auto; }
.cd-tabbar--fixed { position: fixed; }
@supports not ((backdrop-filter: blur(1px)) or (-webkit-backdrop-filter: blur(1px))) { .cd-tabbar { background: var(--tabbar-solid); } }
.cd-economy .cd-tabbar { background: var(--tabbar-solid); backdrop-filter: none; -webkit-backdrop-filter: none; }
.cd-tabbar__pill { position: absolute; top: 5px; bottom: 5px; left: 5px; width: calc((100% - 10px) / 5); border-radius: var(--radius-pill); background: var(--tabbar-active); transform: translateX(calc(var(--tab, 0) * 100%)); transition: transform var(--dur-slide) var(--ease-standard); pointer-events: none; }
.cd-tab { position: relative; z-index: 1; display: grid; place-items: center; min-width: var(--tap-min); border: 0; background: none; color: inherit; border-radius: var(--radius-pill); padding: 0; }
.cd-tab:focus-visible { outline: 2px solid var(--tabbar-icon); outline-offset: -3px; }
.cd-tab .cd-i { width: 27px; height: 27px; }
.cd-tab .is-on { display: none; }
.cd-tab[aria-current="page"] .is-off { display: none; }
.cd-tab[aria-current="page"] .is-on { display: block; }
.cd-tab:active .cd-i, .cd-tab:active .cd-tab__avatar { transform: scale(0.9); transition: transform var(--dur-press); }
.cd-tab__avatar { width: 30px; height: 30px; border-radius: 50%; object-fit: cover; background: var(--media-empty); box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.24); }
.cd-tab[aria-current="page"] .cd-tab__avatar { box-shadow: 0 0 0 2px var(--tabbar-icon); }
.cd-cartcount { position: absolute; top: 9px; left: calc(50% + 5px); min-width: 18px; height: 18px; padding: 0 5px; border-radius: var(--radius-pill); background: var(--cart-badge); color: var(--on-cart-badge); box-shadow: 0 0 0 2px var(--tabbar-solid); font-size: 11px; line-height: 18px; font-weight: 700; text-align: center; font-variant-numeric: tabular-nums; }
.cd-cartcount[hidden] { display: none; }
.cd-cartcount.is-bump { animation: cd-bump 640ms var(--ease-elastic); }
@keyframes cd-bump { 0% { transform: scale(1); } 30% { transform: scale(1.35); filter: brightness(1.25); } 55% { filter: brightness(1); } 100% { transform: scale(1); } }
/* Variante vertical: computador, lateral esquerda */
.cd-tabbar--vertical { position: absolute; left: var(--space-6); top: 50%; bottom: auto; right: auto; transform: translateY(-50%); width: var(--tabbar-h); height: auto; grid-template-columns: 1fr; grid-template-rows: repeat(5, 56px); }
.cd-tabbar--vertical .cd-tabbar__pill { left: 5px; right: 5px; top: 5px; bottom: auto; width: auto; height: 56px; transform: translateY(calc(var(--tab, 0) * 100%)); }

/* ---------- Fileira de stories ---------- */
.cd-stories { display: flex; gap: var(--space-3); overflow-x: auto; padding: var(--space-2) var(--space-4) var(--space-3); scroll-snap-type: x proximity; scrollbar-width: none; }
.cd-stories::-webkit-scrollbar { display: none; }
.cd-story { flex: none; width: 72px; display: grid; justify-items: center; gap: 6px; padding: 0; border: 0; background: none; color: var(--text); scroll-snap-align: start; }
.cd-story__ring { width: calc(var(--story) + 8px); height: calc(var(--story) + 8px); border-radius: 50%; padding: 2px; border: 2px solid var(--accent); display: grid; place-items: center; transition: transform var(--dur-press) var(--ease-standard); }
.cd-story[data-seen="true"] .cd-story__ring { border-color: var(--border); }
.cd-story__img { width: var(--story); height: var(--story); border-radius: 50%; object-fit: cover; background: var(--media-empty); }
.cd-story__icon { width: var(--story); height: var(--story); border-radius: 50%; display: grid; place-items: center; background: var(--surface-sunken); color: var(--text); }
.cd-story__label { max-width: 72px; font-size: 12px; line-height: 15px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.cd-story:active .cd-story__ring { transform: scale(0.96); }
.cd-story--skeleton .cd-story__ring { border-color: transparent; }
.cd-story--skeleton .cd-story__img, .cd-skel { background: var(--surface-sunken); animation: cd-pulse 1.2s ease-in-out infinite alternate; }
@keyframes cd-pulse { from { opacity: 1; } to { opacity: 0.55; } }

/* ---------- Visualizador de story ---------- */
.cd-storyview { position: absolute; inset: 0; z-index: var(--z-story); background: #000; color: var(--on-media); overflow: hidden; touch-action: none; user-select: none; }
.cd-storyview__media { position: absolute; inset: 0; }
.cd-storyview__media img, .cd-storyview__media .cd-media__fill { width: 100%; height: 100%; object-fit: cover; }
.cd-storyview__top { position: absolute; inset: 0 0 auto 0; padding: calc(var(--space-2) + env(safe-area-inset-top, 0px)) var(--space-3) var(--space-6); background: linear-gradient(to top, rgba(0, 0, 0, 0), rgba(0, 0, 0, 0.45)); z-index: 2; }
.cd-progress { display: flex; gap: 4px; }
.cd-progress span { flex: 1; height: 2px; border-radius: 2px; background: rgba(255, 255, 255, 0.35); overflow: hidden; }
.cd-progress span::after { content: ""; display: block; height: 100%; width: 100%; background: #fff; transform: scaleX(var(--p, 0)); transform-origin: left; }
.cd-progress span[data-done="true"] { --p: 1; }
.cd-storyview__head { display: flex; align-items: center; gap: var(--space-2); margin-top: var(--space-3); }
.cd-storyview__head img { width: 32px; height: 32px; border-radius: 50%; object-fit: cover; }
.cd-storyview__head .cd-iconbtn { margin-left: auto; color: var(--on-media); }
.cd-storyview__zones { position: absolute; inset: 0; display: grid; grid-template-columns: 1fr 2fr; z-index: 1; }
.cd-storyview__zones button { border: 0; background: none; padding: 0; }
.cd-storyview__foot { position: absolute; inset: auto 0 0 0; z-index: 2; padding: var(--space-16) var(--space-4) calc(var(--space-6) + env(safe-area-inset-bottom, 0px)); background: linear-gradient(to bottom, rgba(0, 0, 0, 0), var(--media-shade)); display: grid; gap: var(--space-3); }
.cd-storyview__foot .row { display: flex; align-items: end; gap: var(--space-3); }
.cd-storyview__paused { position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%); z-index: 2; opacity: 0; transition: opacity var(--dur-fast); }
.cd-storyview[data-paused="true"] .cd-storyview__paused { opacity: 1; }
.txt-shadow { text-shadow: 0 1px 2px rgba(0, 0, 0, 0.6); }

/* ---------- Post do Início ---------- */
.cd-post { padding-bottom: var(--space-5); }
.cd-post__head { display: flex; align-items: center; gap: var(--space-3); height: 56px; padding: 0 var(--space-2) 0 var(--space-4); }
.cd-avatar { width: var(--avatar); height: var(--avatar); border-radius: 50%; object-fit: cover; background: var(--media-empty); flex: none; box-shadow: 0 0 0 1px var(--border); }
.cd-post__who { flex: 1; min-width: 0; display: grid; }
.cd-post__who b { font-size: 14px; line-height: 18px; font-weight: 600; }
.cd-post__who span { font-size: 12px; line-height: 16px; color: var(--text-muted); }
.cd-post__media { width: 100%; }
.cd-post__actions { display: flex; align-items: center; gap: 0; padding: var(--space-1) var(--space-2) 0 var(--space-1); position: relative; }
.cd-post__actions .cd-dots { position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%); }
.cd-post__actions .cd-add { margin-left: auto; }
.cd-post__body { padding: 0 var(--space-4); display: grid; gap: 2px; }
.cd-post__likes { font-size: 14px; line-height: 20px; font-weight: 600; font-variant-numeric: tabular-nums; }
.cd-post__line { display: flex; align-items: baseline; gap: var(--space-2); }
.cd-post__name { font-size: 15px; line-height: 21px; font-weight: 600; }
.cd-post__price { margin-left: auto; font-size: 15px; font-weight: 650; font-variant-numeric: tabular-nums; white-space: nowrap; }
.cd-post__desc { font-size: 14px; line-height: 20px; color: var(--text-muted); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.cd-post__meta { font-size: 13px; line-height: 18px; color: var(--text-muted); margin-top: 2px; }
.cd-post:focus-within { }
.cd-post--skeleton .cd-post__media { background: var(--surface-sunken); }

/* ---------- Curtir (3 estados) ---------- */
.cd-like { position: relative; display: inline-flex; align-items: center; gap: 2px; min-width: var(--tap-min); height: var(--tap-min); padding: 0 var(--space-2); border: 0; background: none; color: inherit; border-radius: var(--radius-pill); }
.cd-like__icon { position: relative; width: 26px; height: 26px; }
.cd-like__icon .cd-i { position: absolute; inset: 0; width: 26px; height: 26px; }
.cd-like .is-on { color: var(--accent-text); opacity: 0; transform: scale(0.6); }
.cd-like[aria-pressed="true"] .is-on { opacity: 1; transform: scale(1); }
.cd-like[aria-pressed="true"] .is-off { opacity: 0; }
.cd-like.is-liking .cd-like__icon { animation: cd-like-pop var(--dur-like) var(--ease-elastic); }
.cd-like.is-unliking .is-on { transition: opacity var(--dur-fast), transform var(--dur-fast) var(--ease-exit); }
@keyframes cd-like-pop { 0% { transform: scale(1); } 45% { transform: scale(1.25); } 100% { transform: scale(1); } }
.cd-like__count { font-size: 13px; font-weight: 600; font-variant-numeric: tabular-nums; }
.cd-burst { position: absolute; left: 50%; top: 50%; width: 0; height: 0; pointer-events: none; }
.cd-burst i { position: absolute; left: -3px; top: -3px; width: 6px; height: 6px; border-radius: 50%; background: var(--accent-text); animation: cd-particle 520ms var(--ease-standard) forwards; }
@keyframes cd-particle { 0% { transform: rotate(var(--a)) translateY(-6px) scale(1); opacity: 1; } 100% { transform: rotate(var(--a)) translateY(-26px) scale(0.3); opacity: 0; } }
.cd-bigheart { position: absolute; z-index: 3; width: 96px; height: 96px; margin: -48px 0 0 -48px; color: var(--on-media); pointer-events: none; filter: drop-shadow(0 4px 14px rgba(0, 0, 0, 0.35)); animation: cd-bigheart var(--dur-bigheart) var(--ease-standard) forwards; }
.cd-bigheart .cd-i { width: 96px; height: 96px; }
@keyframes cd-bigheart { 0% { transform: scale(0) rotate(-14deg); opacity: 0; } 18% { transform: scale(1.15) rotate(-6deg); opacity: 1; } 32% { transform: scale(0.95) rotate(4deg); } 46% { transform: scale(1) rotate(0deg); } 80% { opacity: 1; transform: scale(1) translateY(-6px); } 100% { opacity: 0; transform: scale(0.85) translateY(-24px); } }
.cd-actbtn { display: inline-flex; align-items: center; gap: 4px; min-width: var(--tap-min); height: var(--tap-min); padding: 0 var(--space-2); border: 0; background: none; color: inherit; border-radius: var(--radius-pill); font-size: 13px; font-weight: 600; font-variant-numeric: tabular-nums; }
.cd-actbtn .cd-i { width: 26px; height: 26px; }
.cd-actbtn .is-on { display: none; }
.cd-actbtn[aria-pressed="true"] .is-on { display: block; }
.cd-actbtn[aria-pressed="true"] .is-off { display: none; }
.cd-actbtn:active { transform: scale(0.96); }

/* ---------- Botão de adicionar com contador ---------- */
.cd-add { display: inline-flex; align-items: center; height: var(--tap-min); border-radius: var(--radius-pill); }
.cd-add__btn { display: inline-flex; align-items: center; gap: 6px; height: 40px; padding: 0 var(--space-4) 0 var(--space-3); border: 0; border-radius: var(--radius-pill); background: var(--accent); color: var(--on-accent); font-weight: 600; font-size: 14px; position: relative; transition: transform var(--dur-press) var(--ease-standard), background-color var(--dur-fast); }
.cd-add__btn::before { content: ""; position: absolute; inset: -2px; }
.cd-add__btn:hover { background: var(--accent-hover); }
.cd-add__btn:active:not(:disabled) { transform: scale(0.96); background: var(--accent-pressed); }
.cd-add__btn:disabled { background: var(--surface-sunken); color: var(--text-muted); cursor: not-allowed; }
.cd-add__btn[aria-busy="true"] .cd-i { display: none; }
.cd-stepper { display: inline-flex; align-items: center; height: 40px; border-radius: var(--radius-pill); background: var(--surface-sunken); color: var(--text); }
.cd-stepper button { width: var(--tap-min); height: var(--tap-min); margin: -2px 0; display: grid; place-items: center; border: 0; background: none; color: inherit; border-radius: 50%; }
.cd-stepper button:active { transform: scale(0.9); }
.cd-stepper button:disabled { opacity: var(--opacity-disabled); }
.cd-stepper output { min-width: 22px; text-align: center; font-weight: 650; font-variant-numeric: tabular-nums; }
.cd-stepper--accent { background: var(--accent); color: var(--on-accent); }
.cd-add__err { display: inline-flex; align-items: center; gap: 4px; font-size: 13px; color: var(--danger); }

/* ---------- Reels ---------- */
.cd-reels { position: absolute; inset: 0; overflow-y: auto; scroll-snap-type: y mandatory; overscroll-behavior: contain; scrollbar-width: none; background: #000; }
.cd-reels::-webkit-scrollbar { display: none; }
.cd-reel { position: relative; height: 100%; scroll-snap-align: start; scroll-snap-stop: always; overflow: hidden; background: #000; color: var(--on-media); }
.cd-reel__media { position: absolute; inset: 0; }
.cd-reel__media img, .cd-reel__media .cd-media__fill, .cd-reel__media video { width: 100%; height: 100%; object-fit: cover; }
.cd-reel.is-playing .cd-reel__media .cd-media__fill { animation: cd-kenburns 9s linear infinite alternate; }
@keyframes cd-kenburns { from { transform: scale(1.02) translateY(0); } to { transform: scale(1.12) translateY(-2%); } }
.cd-reel .cd-shade { height: 55%; }
.cd-reel__top { position: absolute; top: calc(var(--space-3) + env(safe-area-inset-top, 0px)); left: var(--space-4); right: var(--space-2); display: flex; align-items: center; justify-content: space-between; z-index: var(--z-media-ui); }
.cd-reel__top b { font-family: var(--font-display); font-weight: var(--display-weight); font-size: 20px; }
.cd-reel__info { position: absolute; left: var(--space-4); right: 76px; bottom: calc(var(--tabbar-space) + 22px); z-index: var(--z-media-ui); display: grid; gap: var(--space-2); }
.cd-reel__resto { display: flex; align-items: center; gap: var(--space-2); font-size: 14px; font-weight: 600; }
.cd-reel__resto img { width: 28px; height: 28px; border-radius: 50%; object-fit: cover; box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.5); }
.cd-reel__desc { font-size: 14px; line-height: 19px; display: -webkit-box; -webkit-line-clamp: 1; -webkit-box-orient: vertical; overflow: hidden; }
.cd-reel__buy { display: flex; align-items: center; gap: var(--space-3); margin-top: var(--space-1); }
.cd-reel__price { font-size: 17px; font-weight: 700; font-variant-numeric: tabular-nums; }
.cd-reel__rail { position: absolute; right: var(--space-2); bottom: calc(var(--tabbar-space) + 22px); z-index: var(--z-media-ui); display: grid; justify-items: center; gap: var(--space-3); }
.cd-rail { display: grid; justify-items: center; gap: 2px; min-width: 52px; padding: 4px 0; border: 0; background: none; color: var(--on-media); font-size: 12px; font-weight: 600; font-variant-numeric: tabular-nums; border-radius: var(--radius-md); filter: drop-shadow(0 1px 2px rgba(0, 0, 0, 0.55)); }
.cd-rail .cd-i { width: 30px; height: 30px; }
.cd-rail.cd-like { height: auto; min-height: var(--tap-min); flex-direction: column; padding: 4px 0; display: grid; }
.cd-rail.cd-like .cd-like__icon { width: 30px; height: 30px; }
.cd-rail.cd-like .cd-like__icon .cd-i { width: 30px; height: 30px; }
.cd-reel .cd-like .is-on { color: var(--accent); }
.cd-reel .cd-burst i { background: var(--accent); }
.cd-reel__progress { position: absolute; left: calc(var(--tabbar-inset) + 14px); right: calc(var(--tabbar-inset) + 14px); bottom: calc(var(--tabbar-space) + 10px); height: 3px; border-radius: 2px; background: rgba(255, 255, 255, 0.3); z-index: var(--z-media-ui); overflow: hidden; }
.cd-reel__progress span { display: block; height: 100%; width: 100%; background: #fff; transform: scaleX(var(--p, 0)); transform-origin: left; }
.cd-reel__state { position: absolute; top: 50%; left: 50%; width: 72px; height: 72px; margin: -36px 0 0 -36px; display: grid; place-items: center; border-radius: 50%; background: rgba(0, 0, 0, 0.5); opacity: 0; transition: opacity var(--dur-base); pointer-events: none; z-index: var(--z-media-ui); }
.cd-reel.is-paused .cd-reel__state { opacity: 1; }
.cd-reel__tap { position: absolute; inset: 0; z-index: 1; border: 0; background: none; padding: 0; }

/* ---------- Busca ---------- */
.cd-search { position: relative; display: flex; align-items: center; height: var(--tap-min); margin: 0 var(--space-4); border-radius: var(--radius-md); background: var(--surface-sunken); color: var(--text-muted); }
.cd-search > .cd-i { position: absolute; left: var(--space-3); pointer-events: none; }
.cd-search input { flex: 1; height: 100%; min-width: 0; padding: 0 var(--tap-min) 0 44px; border: 0; background: none; color: var(--text); font-size: 16px; border-radius: var(--radius-md); }
.cd-search input::placeholder { color: var(--text-muted); }
.cd-search input:focus-visible { outline: 2px solid var(--focus-ring); outline-offset: 2px; }
.cd-search input::-webkit-search-cancel-button { display: none; }
.cd-search .cd-iconbtn { position: absolute; right: 0; color: var(--text-muted); }
.cd-search[data-state="loading"] .cd-search__clear { display: none; }
.cd-search .cd-spinner { position: absolute; right: 13px; color: var(--text-muted); }
.cd-list { list-style: none; margin: 0; padding: 0; }
.cd-list__title { display: flex; justify-content: space-between; align-items: center; padding: var(--space-4) var(--space-4) var(--space-1); font-size: 15px; font-weight: 650; }
.cd-list__title button { border: 0; background: none; color: var(--accent-text); font-weight: 600; font-size: 14px; min-height: var(--tap-min); padding: 0 var(--space-1); }
.cd-row { display: flex; align-items: center; gap: var(--space-3); width: 100%; min-height: 56px; padding: var(--space-2) var(--space-2) var(--space-2) var(--space-4); border: 0; background: none; color: var(--text); text-align: left; }
.cd-row:hover { background: var(--surface-sunken); }
.cd-row__icon { width: 44px; height: 44px; border-radius: 50%; display: grid; place-items: center; background: var(--surface-sunken); color: var(--text); flex: none; }
.cd-row__thumb { width: 44px; height: 44px; border-radius: var(--radius-sm); object-fit: cover; flex: none; background: var(--media-empty); }
.cd-row__main { flex: 1; min-width: 0; display: grid; }
.cd-row__main b { font-weight: 600; font-size: 15px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.cd-row__main b mark { background: none; color: inherit; font-weight: 800; }
.cd-row__main span { font-size: 13px; color: var(--text-muted); }
.cd-row__end { font-weight: 650; font-variant-numeric: tabular-nums; }
.cd-empty { display: grid; justify-items: center; gap: var(--space-3); padding: var(--space-12) var(--space-6); text-align: center; }
.cd-empty__icon { width: 64px; height: 64px; border-radius: 50%; display: grid; place-items: center; background: var(--surface-sunken); color: var(--text-muted); }
.cd-empty h2 { font-size: 18px; line-height: 24px; font-weight: 650; }
.cd-empty p { color: var(--text-muted); max-width: 30ch; }

/* ---------- Grade de explorar ---------- */
.cd-explore { display: grid; grid-template-columns: repeat(3, 1fr); grid-auto-rows: var(--explore-row, 160px); grid-auto-flow: dense; gap: 2px; }
.cd-tile { position: relative; overflow: hidden; border: 0; padding: 0; background: var(--media-empty); }
.cd-tile--tall { grid-row: span 2; }
.cd-tile img, .cd-tile .cd-media__fill { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; transition: transform var(--dur-base) var(--ease-standard); }
.cd-tile:hover img, .cd-tile:hover .cd-media__fill { transform: scale(1.03); }
.cd-tile .cd-videoflag { top: var(--space-2); right: var(--space-2); }
.cd-tile__price { position: absolute; left: var(--space-2); bottom: var(--space-2); color: var(--on-media); font-size: 12px; font-weight: 700; font-variant-numeric: tabular-nums; text-shadow: 0 1px 3px rgba(0, 0, 0, 0.8); }
.cd-tile .cd-shade { height: 40%; }
.cd-tile.cd-soldout .cd-tile__price { opacity: 0.9; }

/* ---------- Perfil do estabelecimento ---------- */
.cd-profile__top { display: flex; align-items: center; gap: var(--space-5); padding: var(--space-2) var(--space-4) 0; }
.cd-profile__photo { width: 86px; height: 86px; border-radius: 50%; object-fit: cover; flex: none; box-shadow: 0 0 0 1px var(--border); background: var(--media-empty); }
.cd-profile__stats { flex: 1; display: grid; grid-template-columns: repeat(3, 1fr); text-align: left; }
.cd-profile__stats b { display: block; font-size: 17px; font-weight: 700; font-variant-numeric: tabular-nums; }
.cd-profile__stats span { font-size: 13px; color: var(--text-muted); }
.cd-profile__bio { padding: var(--space-3) var(--space-4) 0; display: grid; gap: 2px; font-size: 14px; line-height: 20px; }
.cd-profile__bio h1 { font-size: 15px; font-weight: 700; font-family: var(--font-text); }
.cd-open { display: inline-flex; align-items: center; gap: 4px; font-weight: 600; color: var(--success); }
.cd-open--closed { color: var(--danger); }
.cd-profile__btns { display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--space-2); padding: var(--space-3) var(--space-4) 0; }
.cd-profile__btns .cd-btn { min-height: 40px; padding: 0 var(--space-2); font-size: 14px; border-radius: var(--radius-md); position: relative; }
.cd-profile__btns .cd-btn::before { content: ""; position: absolute; inset: -2px 0; }
.cd-highlights { display: flex; gap: var(--space-3); overflow-x: auto; padding: var(--space-4) var(--space-4) var(--space-2); scrollbar-width: none; }
.cd-highlights::-webkit-scrollbar { display: none; }
.cd-highlights .cd-story__ring { border: 1px solid var(--border); padding: 3px; }
.cd-ptabs { display: grid; grid-template-columns: 1fr 1fr; border-bottom: 1px solid var(--border); position: relative; margin-top: var(--space-2); }
.cd-ptab { height: var(--tap-min); display: grid; place-items: center; border: 0; background: none; color: var(--text-muted); }
.cd-ptab[aria-selected="true"] { color: var(--text); }
.cd-ptabs__bar { position: absolute; bottom: -1px; left: 0; width: 50%; height: 2px; background: var(--text); transform: translateX(calc(var(--tab, 0) * 100%)); transition: transform var(--dur-slide) var(--ease-standard); }
.cd-pgrid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 2px; }
.cd-pgrid .cd-tile { aspect-ratio: 4 / 5; }
.cd-pgrid--reels .cd-tile { aspect-ratio: 9 / 16; }
.cd-tile__views { position: absolute; left: var(--space-2); bottom: var(--space-2); display: flex; align-items: center; gap: 2px; color: var(--on-media); font-size: 12px; font-weight: 600; text-shadow: 0 1px 3px rgba(0, 0, 0, 0.8); }

/* ---------- Folha (bottom sheet) ---------- */
.cd-scrim { position: absolute; inset: 0; z-index: var(--z-scrim); background: var(--scrim); animation: cd-fade var(--dur-base) var(--ease-standard); }
@keyframes cd-fade { from { opacity: 0; } }
.cd-sheet { position: absolute; left: 0; right: 0; bottom: 0; z-index: var(--z-sheet); max-height: 92%; display: flex; flex-direction: column; background: var(--surface-raised); color: var(--text); border-radius: var(--radius-xl) var(--radius-xl) 0 0; box-shadow: var(--shadow-3); animation: cd-sheet-in var(--dur-slide) var(--ease-standard); transform: translateY(var(--drag, 0px)); touch-action: pan-x; }
.cd-sheet.is-dragging { transition: none; }
.cd-sheet.is-settling { transition: transform var(--dur-base) var(--ease-standard); }
.cd-sheet.is-closing { transform: translateY(100%); transition: transform var(--dur-base) var(--ease-exit); }
@keyframes cd-sheet-in { from { transform: translateY(100%); } }
.cd-sheet__grab { flex: none; display: grid; place-items: center; height: 24px; cursor: grab; touch-action: none; }
.cd-sheet__grab::before { content: ""; width: 36px; height: 4px; border-radius: 2px; background: var(--border-strong); opacity: 0.6; }
.cd-sheet__head { flex: none; display: flex; align-items: center; gap: var(--space-2); padding: 0 var(--space-2) var(--space-2) var(--space-4); touch-action: none; }
.cd-sheet__head h2 { flex: 1; }
.cd-sheet__body { flex: 1; overflow-y: auto; overscroll-behavior: contain; padding: 0 var(--space-4) var(--space-4); }
.cd-sheet__foot { flex: none; display: flex; align-items: center; gap: var(--space-3); padding: var(--space-3) var(--space-4) calc(var(--space-3) + env(safe-area-inset-bottom, 0px)); border-top: 1px solid var(--border); background: var(--surface-raised); }
.cd-sheet__foot .cd-btn { flex: 1; }
.cd-dish__media { margin: 0 calc(-1 * var(--space-4)); aspect-ratio: 16 / 11; }
.cd-dish__title { display: flex; align-items: baseline; gap: var(--space-3); margin-top: var(--space-4); }
.cd-dish__title h2 { flex: 1; }
.cd-dish__price { font-size: 18px; font-weight: 700; font-variant-numeric: tabular-nums; }
.cd-dish__desc { margin-top: var(--space-2); color: var(--text-muted); }
.cd-dish__facts { display: flex; flex-wrap: wrap; gap: var(--space-2); margin-top: var(--space-3); }
.cd-fact { display: inline-flex; align-items: center; gap: 4px; height: 28px; padding: 0 var(--space-2); border-radius: var(--radius-pill); background: var(--surface-sunken); font-size: 13px; font-variant-numeric: tabular-nums; }
.cd-group { margin-top: var(--space-6); border: 0; padding: 0; min-width: 0; }
.cd-group legend { width: 100%; padding: 0; display: flex; align-items: baseline; justify-content: space-between; gap: var(--space-2); }
.cd-group__rule { font-size: 13px; color: var(--text-muted); font-weight: 400; }
.cd-group__req { font-size: 12px; font-weight: 600; padding: 2px var(--space-2); border-radius: var(--radius-pill); background: var(--surface-sunken); }
.cd-group[data-invalid="true"] .cd-group__req { background: var(--danger-soft); color: var(--danger); }
.cd-opt { display: flex; align-items: center; gap: var(--space-3); min-height: 52px; border-bottom: 1px solid var(--border); cursor: pointer; }
.cd-opt:last-child { border-bottom: 0; }
.cd-opt span { flex: 1; }
.cd-opt small { color: var(--text-muted); font-size: 14px; font-variant-numeric: tabular-nums; }
.cd-opt input { appearance: none; width: 22px; height: 22px; margin: 0; flex: none; border: 2px solid var(--border-strong); border-radius: 6px; display: grid; place-items: center; background: var(--surface-raised); transition: background-color var(--dur-fast), border-color var(--dur-fast); }
.cd-opt input[type="radio"] { border-radius: 50%; }
.cd-opt input:checked { background: var(--accent); border-color: var(--accent); }
.cd-opt input:checked::after { content: ""; width: 10px; height: 6px; border: 2px solid var(--on-accent); border-top: 0; border-right: 0; transform: translateY(-1px) rotate(-45deg); }
.cd-opt input[type="radio"]:checked::after { width: 8px; height: 8px; border: 0; border-radius: 50%; background: var(--on-accent); transform: none; }
.cd-opt input:disabled { opacity: var(--opacity-disabled); }
.cd-opt:has(input:disabled) { color: var(--text-disabled); cursor: not-allowed; }
.cd-field { display: grid; gap: 6px; margin-top: var(--space-4); }
.cd-field label { font-size: 13px; font-weight: 600; }
.cd-field__hint { font-size: 13px; color: var(--text-muted); }
.cd-input, .cd-textarea { width: 100%; min-height: 48px; padding: 12px var(--space-3); border: 1px solid var(--border-strong); border-radius: var(--radius-md); background: var(--surface); color: var(--text); font-size: 16px; line-height: 22px; }
.cd-textarea { min-height: 88px; resize: vertical; }
.cd-input::placeholder, .cd-textarea::placeholder { color: var(--text-muted); }
.cd-input:focus-visible, .cd-textarea:focus-visible { outline: 2px solid var(--focus-ring); outline-offset: 1px; border-color: var(--focus-ring); }
.cd-input[aria-invalid="true"], .cd-textarea[aria-invalid="true"] { border-color: var(--danger); border-width: 2px; padding: 11px calc(var(--space-3) - 1px); }
.cd-input:disabled { background: var(--surface-sunken); color: var(--text-muted); }
.cd-field__err { display: flex; align-items: center; gap: 6px; font-size: 13px; color: var(--danger); font-weight: 500; }
.cd-field__count { justify-self: end; font-size: 12px; color: var(--text-muted); font-variant-numeric: tabular-nums; }
.cd-row2 { display: grid; grid-template-columns: 1fr 1fr; gap: var(--space-3); }

/* ---------- Aviso curto acima da barra ---------- */
.cd-toast { position: absolute; left: var(--tabbar-inset); right: var(--tabbar-inset); bottom: calc(var(--tabbar-space) + var(--space-2)); z-index: var(--z-toast); display: flex; align-items: center; gap: var(--space-3); min-height: 56px; padding: var(--space-2) var(--space-2) var(--space-2) var(--space-2); border-radius: var(--radius-lg); background: var(--text); color: var(--bg); box-shadow: var(--shadow-2); animation: cd-toast-in var(--dur-base) var(--ease-standard); max-width: 420px; margin: 0 auto; }
.cd-toast.is-leaving { animation: cd-toast-out var(--dur-fast) var(--ease-exit) forwards; }
@keyframes cd-toast-in { from { transform: translateY(12px); opacity: 0; } }
@keyframes cd-toast-out { to { transform: translateY(8px); opacity: 0; } }
.cd-toast img { width: 40px; height: 40px; border-radius: var(--radius-sm); object-fit: cover; flex: none; }
.cd-toast__icon { width: 40px; height: 40px; display: grid; place-items: center; flex: none; }
.cd-toast p { flex: 1; font-size: 14px; line-height: 19px; }
.cd-toast p b { font-weight: 650; }
.cd-toast button { flex: none; min-height: var(--tap-min); padding: 0 var(--space-3); border: 0; border-radius: var(--radius-md); background: none; color: inherit; font-weight: 700; text-decoration: underline; text-underline-offset: 3px; }
.cd-toast button:focus-visible { outline-color: var(--bg); }
.cd-toast--error { background: var(--danger-soft); color: var(--danger); box-shadow: var(--shadow-2), inset 0 0 0 1px var(--danger); }
.cd-fly { position: absolute; z-index: var(--z-fly); width: 56px; height: 56px; border-radius: 50%; object-fit: cover; pointer-events: none; box-shadow: var(--shadow-2); transition: transform var(--dur-fly) cubic-bezier(.5, 0, .75, 0), opacity var(--dur-fly) var(--ease-exit); }

/* ---------- Sacola e pedido ---------- */
.cd-page { padding: 0 var(--space-4); }
.cd-section-title { padding: var(--space-5) 0 var(--space-2); }
.cd-bagitem { display: grid; grid-template-columns: 64px 1fr; gap: var(--space-3); padding: var(--space-3) 0; border-bottom: 1px solid var(--border); }
.cd-bagitem img { width: 64px; height: 64px; border-radius: var(--radius-sm); object-fit: cover; background: var(--media-empty); }
.cd-bagitem__top { display: flex; gap: var(--space-2); align-items: baseline; }
.cd-bagitem__top b { flex: 1; font-weight: 600; }
.cd-bagitem__top span { font-weight: 650; font-variant-numeric: tabular-nums; }
.cd-bagitem__extra { font-size: 13px; line-height: 18px; color: var(--text-muted); margin-top: 2px; }
.cd-bagitem__ctrl { display: flex; align-items: center; justify-content: space-between; margin-top: var(--space-2); }
.cd-bagitem__ctrl .cd-btn--ghost { color: var(--text-muted); font-weight: 500; padding: 0 var(--space-2); }
.cd-summary { display: grid; gap: var(--space-2); padding: var(--space-4) 0; font-variant-numeric: tabular-nums; }
.cd-summary div { display: flex; justify-content: space-between; }
.cd-summary .total { font-weight: 700; font-size: 17px; padding-top: var(--space-2); border-top: 1px solid var(--border); }
.cd-stickycta { position: sticky; bottom: calc(var(--tabbar-space) + var(--space-3)); z-index: var(--z-sticky); padding: var(--space-3) 0 0; background: linear-gradient(to bottom, transparent, var(--bg) 30%); }
.cd-steps { display: flex; gap: var(--space-1); padding: var(--space-2) 0 0; font-size: 12px; color: var(--text-muted); font-weight: 600; }
.cd-steps span[aria-current="step"] { color: var(--text); }
.cd-seg { display: grid; grid-auto-flow: column; grid-auto-columns: 1fr; gap: 4px; padding: 4px; border-radius: var(--radius-md); background: var(--surface-sunken); }
.cd-seg button { min-height: 40px; border: 0; border-radius: 9px; background: none; color: var(--text-muted); font-weight: 600; font-size: 14px; position: relative; }
.cd-seg button::before { content: ""; position: absolute; inset: -2px 0; }
.cd-seg button[aria-pressed="true"] { background: var(--surface); color: var(--text); box-shadow: var(--shadow-1); }
.cd-note { display: flex; gap: var(--space-2); align-items: flex-start; padding: var(--space-3); border-radius: var(--radius-md); background: var(--surface-sunken); font-size: 13px; line-height: 18px; color: var(--text-muted); }
.cd-note .cd-i { color: var(--text); margin-top: -1px; }
.cd-alert { display: flex; gap: var(--space-2); align-items: flex-start; padding: var(--space-3); border-radius: var(--radius-md); font-size: 14px; line-height: 20px; }
.cd-alert--error { background: var(--danger-soft); color: var(--danger); }
.cd-alert--warning { background: var(--warning-soft); color: var(--warning); }
.cd-alert--success { background: var(--success-soft); color: var(--success); }
.cd-alert b { display: block; }

/* Pix */
.cd-pix { display: grid; justify-items: center; gap: var(--space-4); padding-top: var(--space-4); text-align: center; }
.cd-pix__amount { font-size: 30px; font-weight: 700; font-variant-numeric: tabular-nums; font-family: var(--font-text); }
.cd-qr { width: 216px; height: 216px; padding: 12px; border-radius: var(--radius-lg); background: #fff; box-shadow: 0 0 0 1px var(--border); }
.cd-qr svg { width: 100%; height: 100%; }
.cd-qr[data-expired="true"] { filter: blur(4px); opacity: 0.35; }
.cd-timer { width: 100%; display: grid; gap: 6px; }
.cd-timer__row { display: flex; justify-content: space-between; font-size: 14px; }
.cd-timer__row b { font-variant-numeric: tabular-nums; }
.cd-timer__bar { height: 4px; border-radius: 2px; background: var(--surface-sunken); overflow: hidden; }
.cd-timer__bar span { display: block; height: 100%; background: var(--text); transform-origin: left; transform: scaleX(var(--p, 1)); transition: transform 1s linear; }
.cd-timer[data-low="true"] .cd-timer__row b { color: var(--warning); }
.cd-timer[data-low="true"] .cd-timer__bar span { background: var(--warning); }
.cd-copy { width: 100%; display: flex; align-items: center; gap: var(--space-2); padding: var(--space-2) var(--space-2) var(--space-2) var(--space-3); border-radius: var(--radius-md); background: var(--surface-sunken); text-align: left; }
.cd-copy code { flex: 1; min-width: 0; font-family: ui-monospace, "SF Mono", Menlo, monospace; font-size: 13px; color: var(--text-muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.cd-waiting { display: flex; align-items: center; gap: var(--space-2); font-size: 14px; color: var(--text-muted); }

/* Cartão */
.cd-cardpreview { display: flex; align-items: center; gap: var(--space-2); font-size: 13px; color: var(--text-muted); }
.cd-input--icon { padding-right: 48px; }
.cd-inputwrap { position: relative; }
.cd-inputwrap .cd-i { position: absolute; right: 14px; top: 50%; transform: translateY(-50%); color: var(--text-muted); pointer-events: none; }

/* Pedido confirmado e acompanhamento */
.cd-done { display: grid; justify-items: center; gap: var(--space-2); text-align: center; padding: var(--space-8) 0 var(--space-4); }
.cd-done__check { width: 72px; height: 72px; border-radius: 50%; display: grid; place-items: center; background: var(--success-soft); color: var(--success); animation: cd-pop-in var(--dur-like) var(--ease-elastic); }
.cd-done__check .cd-i { width: 36px; height: 36px; stroke-width: 2.4; }
@keyframes cd-pop-in { from { transform: scale(0.4); opacity: 0; } }
.cd-track { list-style: none; margin: 0; padding: var(--space-2) 0; display: grid; }
.cd-track li { display: grid; grid-template-columns: 28px 1fr auto; gap: var(--space-3); align-items: start; padding-bottom: var(--space-5); position: relative; }
.cd-track li::before { content: ""; position: absolute; left: 13px; top: 28px; bottom: 0; width: 2px; background: var(--border); }
.cd-track li:last-child::before { display: none; }
.cd-track li[data-state="done"]::before { background: var(--text); }
.cd-track__dot { width: 28px; height: 28px; border-radius: 50%; display: grid; place-items: center; border: 2px solid var(--border-strong); background: var(--surface); color: var(--text-muted); }
.cd-track li[data-state="done"] .cd-track__dot { background: var(--text); border-color: var(--text); color: var(--bg); }
.cd-track li[data-state="current"] .cd-track__dot { border-color: var(--accent); background: var(--accent); color: var(--on-accent); }
.cd-track li[data-state="current"] .cd-track__dot::after { content: ""; position: absolute; width: 28px; height: 28px; border-radius: 50%; }
.cd-track b { display: block; font-weight: 600; }
.cd-track span { font-size: 13px; color: var(--text-muted); }
.cd-track time { font-size: 13px; color: var(--text-muted); font-variant-numeric: tabular-nums; }
.cd-track li[data-state="todo"] b { color: var(--text-muted); font-weight: 500; }
.cd-eta { display: flex; align-items: center; gap: var(--space-3); padding: var(--space-4); border-radius: var(--radius-lg); background: var(--surface); box-shadow: 0 0 0 1px var(--border); }
.cd-eta b { font-size: 22px; font-variant-numeric: tabular-nums; }

/* Aviso de privacidade das métricas */
.cd-privacy { display: grid; gap: var(--space-3); margin: var(--space-2) var(--space-4) var(--space-4); padding: var(--space-4); border-radius: var(--radius-lg); background: var(--surface-raised); box-shadow: 0 0 0 1px var(--border); }
.cd-privacy__head { display: flex; gap: var(--space-3); align-items: flex-start; }
.cd-privacy__head .cd-i { flex: none; margin-top: 1px; }
.cd-privacy p { font-size: 14px; line-height: 20px; color: var(--text-muted); }
.cd-privacy p b { color: var(--text); font-weight: 600; }
.cd-privacy__actions { display: flex; gap: var(--space-2); justify-content: flex-end; }
.cd-switch { display: flex; align-items: center; justify-content: space-between; gap: var(--space-3); min-height: var(--tap-min); font-size: 14px; }
.cd-switch input { appearance: none; width: 44px; height: 26px; margin: 0; border-radius: var(--radius-pill); background: var(--border-strong); position: relative; flex: none; transition: background-color var(--dur-fast); }
.cd-switch input::after { content: ""; position: absolute; top: 3px; left: 3px; width: 20px; height: 20px; border-radius: 50%; background: #fff; transition: transform var(--dur-fast) var(--ease-standard); box-shadow: 0 1px 2px rgba(0, 0, 0, 0.3); }
.cd-switch input:checked { background: var(--accent); }
.cd-switch input:checked::after { transform: translateX(18px); }

/* Mais informações (ingredientes, alérgenos) */
.cd-info dl { display: grid; grid-template-columns: auto 1fr; gap: var(--space-3) var(--space-4); margin: var(--space-2) 0 0; }
.cd-info dt { color: var(--text-muted); font-size: 14px; }
.cd-info dd { margin: 0; font-size: 15px; font-variant-numeric: tabular-nums; }
.cd-allergen { display: inline-flex; align-items: center; gap: 4px; margin: 0 4px 4px 0; padding: 2px var(--space-2); border-radius: var(--radius-pill); background: var(--warning-soft); color: var(--warning); font-size: 13px; font-weight: 600; }
.cd-review { padding: var(--space-3) 0; border-bottom: 1px solid var(--border); }
.cd-review__head { display: flex; justify-content: space-between; font-size: 13px; color: var(--text-muted); }
.cd-stars { display: inline-flex; gap: 1px; color: var(--text); }
.cd-stars .cd-i { width: 14px; height: 14px; }
.cd-verified { display: inline-flex; align-items: center; gap: 4px; font-size: 12px; color: var(--success); font-weight: 600; }

/* =========================== PAINEL DO DONO =========================== */
.cd-panel { display: grid; grid-template-columns: var(--panel-nav) 1fr; min-height: 100%; background: var(--bg); color: var(--text); font-family: var(--font-text); font-size: 14px; line-height: 20px; }
.cd-pnav { position: sticky; top: 0; height: 100%; min-height: 100%; display: flex; flex-direction: column; gap: 2px; padding: var(--space-5) var(--space-3); border-right: 1px solid var(--border); background: var(--surface); }
.cd-pnav__brand { display: flex; align-items: center; gap: var(--space-3); padding: 0 var(--space-2) var(--space-5); }
.cd-pnav__brand img { width: 36px; height: 36px; border-radius: 50%; object-fit: cover; }
.cd-pnav__brand b { display: block; font-weight: 700; }
.cd-pnav__brand span { font-size: 12px; color: var(--text-muted); }
.cd-pnav a { display: flex; align-items: center; gap: var(--space-3); min-height: 40px; padding: 0 var(--space-3); border-radius: var(--radius-md); color: var(--text-muted); text-decoration: none; font-weight: 500; }
.cd-pnav a:hover { background: var(--surface-sunken); color: var(--text); }
.cd-pnav a[aria-current="page"] { background: var(--surface-sunken); color: var(--text); font-weight: 650; }
.cd-pnav__foot { margin-top: auto; padding: var(--space-3); font-size: 12px; color: var(--text-muted); }
.cd-pmain { min-width: 0; padding: var(--space-6) var(--space-8) var(--space-12); display: grid; gap: var(--space-6); align-content: start; }
.cd-phead { display: flex; flex-wrap: wrap; align-items: center; gap: var(--space-3) var(--space-4); }
.cd-phead h1 { flex: 1 1 auto; }
.cd-phead__sub { flex-basis: 100%; color: var(--text-muted); margin-top: -8px; }
.cd-grid { display: grid; gap: var(--space-4); }
.cd-grid--4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.cd-grid--2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.cd-grid--21 { grid-template-columns: 2fr 1fr; }
.cd-card { min-width: 0; padding: var(--space-5); border-radius: var(--radius-md); background: var(--surface); box-shadow: var(--shadow-1), 0 0 0 1px var(--border); }
.cd-card__head { display: flex; align-items: baseline; justify-content: space-between; gap: var(--space-3); margin-bottom: var(--space-4); }
.cd-card__head h2 { font-size: 15px; line-height: 20px; font-weight: 650; }
.cd-card__head span { font-size: 13px; color: var(--text-muted); }

/* Período */
.cd-period { display: inline-flex; align-items: center; gap: var(--space-3); flex-wrap: wrap; }
.cd-period .cd-seg { display: inline-grid; max-width: 100%; overflow-x: auto; scrollbar-width: none; }
.cd-period .cd-seg button { padding: 0 var(--space-3); min-height: 36px; white-space: nowrap; }
.cd-period__range { font-size: 13px; color: var(--text-muted); font-variant-numeric: tabular-nums; }

/* Cartão de número */
.cd-stat { display: grid; gap: var(--space-1); }
.cd-stat__label { font-size: 13px; color: var(--text-muted); font-weight: 500; }
.cd-stat .cd-badge--demo { justify-self: start; margin-top: var(--space-1); }
.cd-stat__value { font-size: 28px; line-height: 34px; font-weight: 650; font-variant-numeric: tabular-nums; letter-spacing: -0.01em; }
.cd-stat__unit { font-size: 15px; font-weight: 500; color: var(--text-muted); margin-left: 2px; }
.cd-delta { display: inline-flex; align-items: center; gap: 4px; font-size: 13px; font-weight: 600; font-variant-numeric: tabular-nums; }
.cd-delta--up { color: var(--success); }
.cd-delta--down { color: var(--danger); }
.cd-delta--flat, .cd-delta--none { color: var(--text-muted); font-weight: 500; }
.cd-delta small { font-weight: 400; color: var(--text-muted); }
.cd-stat--loading .cd-stat__value { width: 60%; height: 34px; border-radius: var(--radius-sm); }

/* Barras (ranking, funil) — escala começa no zero */
.cd-bars { list-style: none; margin: 0; padding: 0; display: grid; gap: var(--space-3); }
.cd-bar { display: grid; grid-template-columns: 24px 40px minmax(0, 1fr); gap: var(--space-3); align-items: center; }
.cd-bar__rank { font-weight: 650; color: var(--text-muted); font-variant-numeric: tabular-nums; text-align: right; }
.cd-bar img { width: 40px; height: 40px; border-radius: var(--radius-sm); object-fit: cover; background: var(--media-empty); }
.cd-bar__main { display: grid; gap: 4px; min-width: 0; }
.cd-bar__top { display: flex; justify-content: space-between; gap: var(--space-2); }
.cd-bar__top b { font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.cd-bar__top span { font-weight: 650; font-variant-numeric: tabular-nums; white-space: nowrap; }
.cd-bar__track { height: 8px; border-radius: 4px; background: var(--surface-sunken); overflow: hidden; }
.cd-bar__fill { height: 100%; width: calc(var(--v) * 100%); background: var(--chart-1); border-radius: 4px; }
.cd-bar__sub { font-size: 12px; color: var(--text-muted); font-variant-numeric: tabular-nums; }

.cd-funnel { display: grid; gap: 0; }
.cd-funnel__step { display: grid; grid-template-columns: 96px minmax(0, 1fr) 64px; gap: var(--space-3); align-items: center; min-height: 40px; }
.cd-funnel__step dt { font-weight: 600; }
.cd-funnel__step dd { margin: 0; }
.cd-funnel__bar { height: 28px; border-radius: 6px; width: calc(var(--v) * 100%); min-width: 2px; }
.cd-funnel__step:nth-of-type(1) .cd-funnel__bar { background: var(--chart-seq-5); }
.cd-funnel__step:nth-of-type(2) .cd-funnel__bar { background: var(--chart-seq-4); }
.cd-funnel__step:nth-of-type(3) .cd-funnel__bar { background: var(--chart-seq-3); }
.cd-funnel__step:nth-of-type(4) .cd-funnel__bar { background: var(--chart-seq-2); box-shadow: inset 0 0 0 1px var(--chart-seq-4); }
.cd-funnel__val { text-align: right; font-weight: 650; font-variant-numeric: tabular-nums; }
.cd-funnel__conv { grid-column: 2 / 4; font-size: 12px; color: var(--text-muted); padding: 2px 0 6px; display: flex; align-items: center; gap: 4px; font-variant-numeric: tabular-nums; }
.cd-funnel__conv b { color: var(--text); font-weight: 600; }

/* Quase pediu */
.cd-almost { list-style: none; margin: 0; padding: 0; }
.cd-almost li { display: grid; grid-template-columns: 40px minmax(0, 1fr) auto; gap: var(--space-3); align-items: center; padding: var(--space-3) 0; border-bottom: 1px solid var(--border); }
.cd-almost li:last-child { border-bottom: 0; }
.cd-almost img { width: 40px; height: 40px; border-radius: var(--radius-sm); object-fit: cover; background: var(--media-empty); }
.cd-almost b { font-weight: 600; display: block; }
.cd-reason { display: inline-flex; align-items: center; gap: 4px; font-size: 13px; color: var(--text-muted); }
.cd-almost__n { text-align: right; font-variant-numeric: tabular-nums; }
.cd-almost__n b { font-size: 17px; }
.cd-almost__n span { font-size: 12px; color: var(--text-muted); }

/* Mapa de calor do feed */
.cd-heat { display: grid; grid-template-columns: 72px repeat(var(--cols, 12), minmax(0, 1fr)); gap: 3px; font-size: 12px; font-variant-numeric: tabular-nums; }
.cd-heat__y { color: var(--text-muted); display: flex; align-items: center; justify-content: flex-end; padding-right: var(--space-2); white-space: nowrap; }
.cd-heat__x { color: var(--text-muted); text-align: center; padding-top: 4px; }
.cd-heat__cell { aspect-ratio: 1.4; min-height: 26px; border-radius: 4px; display: grid; place-items: center; font-weight: 600; color: var(--text); }
.cd-heat__cell[data-l="0"] { background: var(--surface-sunken); color: var(--text-muted); }
.cd-heat__cell[data-l="1"] { background: var(--chart-seq-1); }
.cd-heat__cell[data-l="2"] { background: var(--chart-seq-2); }
.cd-heat__cell[data-l="3"] { background: var(--chart-seq-3); }
.cd-heat__cell[data-l="4"] { background: var(--chart-seq-4); color: #fff; }
.cd-heat__cell[data-l="5"] { background: var(--chart-seq-5); color: #fff; }
[data-theme="dark"] .cd-heat__cell[data-l="1"], [data-theme="dark"] .cd-heat__cell[data-l="2"], [data-theme="dark"] .cd-heat__cell[data-l="3"] { color: #fff; }
[data-theme="dark"] .cd-heat__cell[data-l="4"], [data-theme="dark"] .cd-heat__cell[data-l="5"] { color: #16161a; }
.cd-heat__legend { display: flex; align-items: center; gap: var(--space-2); margin-top: var(--space-3); font-size: 12px; color: var(--text-muted); }
.cd-heat__legend i { width: 20px; height: 10px; border-radius: 2px; display: inline-block; }

/* Linha (tendência) */
.cd-line > svg { width: 100%; height: auto; overflow: visible; }
.cd-line .grid { stroke: var(--chart-grid); stroke-width: 1; }
.cd-line .base { stroke: var(--border-strong); stroke-width: 1; }
.cd-line .s1 { fill: none; stroke: var(--chart-1); stroke-width: 2.5; stroke-linejoin: round; stroke-linecap: round; }
.cd-line .s2 { fill: none; stroke: var(--chart-2); stroke-width: 2.5; stroke-dasharray: 6 4; stroke-linejoin: round; }
.cd-line text { fill: var(--text-muted); font-size: 12px; font-family: var(--font-text); font-variant-numeric: tabular-nums; }
.cd-line .lab1 { fill: var(--chart-1); font-weight: 650; }
.cd-line .lab2 { fill: var(--chart-2); font-weight: 650; }
.cd-line .dot1 { fill: var(--chart-1); }
.cd-line .dot2 { fill: var(--chart-2); }

/* Sugestão com evidência */
.cd-sugg { display: grid; gap: var(--space-3); padding: var(--space-5); border-radius: var(--radius-lg); background: var(--surface); box-shadow: var(--shadow-1), 0 0 0 1px var(--border); }
.cd-sugg__top { display: flex; gap: var(--space-3); align-items: flex-start; }
.cd-sugg__top img { width: 48px; height: 48px; border-radius: var(--radius-sm); object-fit: cover; flex: none; }
.cd-sugg h3 { font-size: 16px; line-height: 22px; font-weight: 650; }
.cd-sugg p { color: var(--text-muted); }
.cd-evidence { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1px; border-radius: var(--radius-md); overflow: hidden; background: var(--border); }
.cd-evidence div { background: var(--surface-sunken); padding: var(--space-2) var(--space-3); display: grid; }
.cd-evidence b { font-size: 17px; font-variant-numeric: tabular-nums; }
.cd-evidence span { font-size: 12px; color: var(--text-muted); }
.cd-sugg__src { font-size: 12px; color: var(--text-muted); display: flex; flex-wrap: wrap; align-items: center; gap: 4px 6px; }
.cd-sugg__actions { display: flex; gap: var(--space-2); }

/* Tabela de pedidos */
.cd-table-wrap { overflow-x: auto; }
.cd-table { width: 100%; border-collapse: collapse; font-variant-numeric: tabular-nums; }
.cd-table th { text-align: left; font-size: 12px; font-weight: 600; color: var(--text-muted); padding: var(--space-2) var(--space-3); border-bottom: 1px solid var(--border); white-space: nowrap; }
.cd-table th button { border: 0; background: none; padding: 0; color: inherit; font: inherit; display: inline-flex; align-items: center; gap: 2px; min-height: 32px; }
.cd-table th[aria-sort] { color: var(--text); }
.cd-table td { padding: var(--space-3); border-bottom: 1px solid var(--border); vertical-align: middle; }
.cd-table td.n, .cd-table th.n { text-align: right; }
.cd-table tbody tr:hover { background: var(--surface-sunken); }
.cd-status { display: inline-flex; align-items: center; gap: 4px; height: 24px; padding: 0 var(--space-2); border-radius: var(--radius-pill); font-size: 12px; font-weight: 600; white-space: nowrap; }
.cd-status--paid { background: var(--success-soft); color: var(--success); }
.cd-status--prep { background: var(--surface-sunken); color: var(--text); }
.cd-status--wait { background: var(--warning-soft); color: var(--warning); }
.cd-status--fail { background: var(--danger-soft); color: var(--danger); }

/* Painel em 390 px */
.cd-panel--mobile { grid-template-columns: 1fr; }
.cd-panel--mobile .cd-pnav { display: none; }
.cd-panel--mobile .cd-pmain { padding: var(--space-4) var(--space-4) var(--space-12); gap: var(--space-4); }
.cd-panel--mobile .cd-grid--4 { grid-template-columns: 1fr 1fr; }
.cd-panel--mobile .cd-grid--2, .cd-panel--mobile .cd-grid--21 { grid-template-columns: 1fr; }
.cd-panel--mobile .cd-card { padding: var(--space-4); }
.cd-panel--mobile .cd-heat { grid-template-columns: 56px repeat(var(--cols, 12), minmax(0, 1fr)); gap: 2px; font-size: 10px; }
.cd-panel--mobile .cd-heat__cell { min-height: 18px; font-size: 0; }
.cd-panel--mobile .cd-funnel__step { grid-template-columns: 72px minmax(0, 1fr) 52px; }
.cd-pmobilebar { display: none; }
.cd-panel--mobile .cd-pmobilebar { display: flex; gap: var(--space-2); overflow-x: auto; padding: var(--space-3) var(--space-4) 0; scrollbar-width: none; }

@media (max-width: 720px) {
  .cd-panel { grid-template-columns: 1fr; }
  .cd-pnav { display: none; }
  .cd-pmain { padding: var(--space-4); }
  .cd-grid--4 { grid-template-columns: 1fr 1fr; }
  .cd-grid--2, .cd-grid--21 { grid-template-columns: 1fr; }
}

/* =========================== MOVIMENTO REDUZIDO ===========================
   Com prefers-reduced-motion: nada escala, gira, voa ou desliza.
   O estado final aparece direto ou com troca de opacidade de até dur-fast. */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 1ms !important; animation-iteration-count: 1 !important; scroll-behavior: auto !important; }
  .cd-press:active, .cd-btn:active, .cd-add__btn:active, .cd-chip:active, .cd-iconbtn:active, .cd-actbtn:active, .cd-story:active .cd-story__ring, .cd-stepper button:active, .cd-tab:active .cd-i { transform: none !important; }
  .cd-tabbar__pill, .cd-ptabs__bar { transition: none; }
  .cd-like.is-liking .cd-like__icon { animation: none; }
  .cd-like .is-on { transition: opacity var(--dur-fast) linear; transform: none !important; }
  .cd-burst { display: none; }
  .cd-bigheart { animation: cd-fade-only var(--dur-bigheart) linear forwards !important; animation-duration: var(--dur-bigheart) !important; }
  .cd-cartcount.is-bump { animation: none; }
  .cd-sheet { animation: cd-fade var(--dur-fast) linear !important; animation-duration: var(--dur-fast) !important; }
  .cd-sheet.is-closing { transform: none; opacity: 0; transition: opacity var(--dur-fast) linear; }
  .cd-toast { animation: cd-fade var(--dur-fast) linear !important; animation-duration: var(--dur-fast) !important; }
  .cd-fly { display: none; }
  .cd-reel.is-playing .cd-reel__media .cd-media__fill { animation: none; }
  .cd-reels { scroll-snap-type: y mandatory; }
  .cd-media--loading::after { animation: none; }
  .cd-done__check { animation: none; }
  .cd-tile img, .cd-tile .cd-media__fill { transition: none; }
}
@keyframes cd-fade-only { 0% { opacity: 0; } 15% { opacity: 1; } 75% { opacity: 1; } 100% { opacity: 0; } }

/* Mesmas regras, ligadas pela classe .cd-reduced (laboratório de movimento) */
.cd-reduced *, .cd-reduced *::before, .cd-reduced *::after { animation-duration: 1ms !important; animation-iteration-count: 1 !important; scroll-behavior: auto !important; }
.cd-reduced .cd-press:active, .cd-reduced .cd-btn:active, .cd-reduced .cd-add__btn:active, .cd-reduced .cd-chip:active, .cd-reduced .cd-iconbtn:active, .cd-reduced .cd-actbtn:active, .cd-reduced .cd-story:active .cd-story__ring, .cd-reduced .cd-stepper button:active, .cd-reduced .cd-tab:active .cd-i { transform: none !important; }
.cd-reduced .cd-tabbar__pill, .cd-reduced .cd-ptabs__bar { transition: none; }
.cd-reduced .cd-like.is-liking .cd-like__icon { animation: none; }
.cd-reduced .cd-like .is-on { transition: opacity var(--dur-fast) linear; transform: none !important; }
.cd-reduced .cd-burst { display: none; }
.cd-reduced .cd-bigheart { animation: cd-fade-only var(--dur-bigheart) linear forwards !important; animation-duration: var(--dur-bigheart) !important; }
.cd-reduced .cd-cartcount.is-bump { animation: none; }
.cd-reduced .cd-sheet { animation: cd-fade var(--dur-fast) linear !important; animation-duration: var(--dur-fast) !important; }
.cd-reduced .cd-sheet.is-closing { transform: none; opacity: 0; transition: opacity var(--dur-fast) linear; }
.cd-reduced .cd-toast { animation: cd-fade var(--dur-fast) linear !important; animation-duration: var(--dur-fast) !important; }
.cd-reduced .cd-fly { display: none; }
.cd-reduced .cd-reel.is-playing .cd-reel__media .cd-media__fill { animation: none; }
.cd-reduced .cd-reels { scroll-snap-type: y mandatory; }
.cd-reduced .cd-media--loading::after { animation: none; }
.cd-reduced .cd-done__check { animation: none; }
.cd-reduced .cd-tile img, .cd-reduced .cd-tile .cd-media__fill { transition: none; }

/* =========================== TEMAS =========================== */
/* Pares de fontes da lista curta */
[data-fontpair="padrao"] { --font-display: "Bricolage Grotesque", "Instrument Sans", system-ui, sans-serif; --font-text: "Instrument Sans", system-ui, -apple-system, "Segoe UI", sans-serif; --display-weight: 700; --display-tracking: -0.01em; }
[data-fontpair="rua"] { --font-display: "Barlow Condensed", "Arial Narrow", system-ui, sans-serif; --font-text: "Barlow", system-ui, sans-serif; --display-weight: 700; --display-tracking: 0; }
[data-fontpair="redondo"] { --font-display: "Fredoka", system-ui, sans-serif; --font-text: "Figtree", system-ui, sans-serif; --display-weight: 600; --display-tracking: 0; }
[data-fontpair="editorial"] { --font-display: "Instrument Serif", Georgia, serif; --font-text: "Instrument Sans", system-ui, sans-serif; --display-weight: 400; --display-tracking: 0; }
[data-fontpair="classico"] { --font-display: "Fraunces", Georgia, serif; --font-text: "Figtree", system-ui, sans-serif; --display-weight: 700; --display-tracking: -0.01em; }
/* Restaurantes de exemplo: destaque derivado por Cardapio.theme.derive() */
[data-restaurant="brasa"], [data-restaurant="brasa"] [data-theme="light"] { --accent: #e2531f; --accent-hover: #f46433; --accent-pressed: #fe7b51; --on-accent: #16161a; --accent-text: #c9430d; --accent-soft: #feece6; --accent-on-soft: #c23c00; }
[data-restaurant="brasa"][data-theme="dark"], [data-restaurant="brasa"] [data-theme="dark"], [data-theme="dark"] [data-restaurant="brasa"] { --accent: #e95a27; --accent-hover: #fb6a3a; --accent-pressed: #fd8762; --on-accent: #16161a; --accent-text: #e95a27; --accent-soft: #3b1d14; --accent-on-soft: #ed5d2b; }
[data-restaurant="mare"], [data-restaurant="mare"] [data-theme="light"] { --accent: #2bb3a3; --accent-hover: #04a394; --accent-pressed: #109284; --on-accent: #16161a; --accent-text: #128175; --accent-soft: #d8f8f2; --accent-on-soft: #017b6f; }
[data-restaurant="mare"][data-theme="dark"], [data-restaurant="mare"] [data-theme="dark"], [data-theme="dark"] [data-restaurant="mare"] { --accent: #2bb3a3; --accent-hover: #04a394; --accent-pressed: #109284; --on-accent: #16161a; --accent-text: #2bb3a3; --accent-soft: #012e29; --accent-on-soft: #2bb3a3; }
[data-restaurant="grao"], [data-restaurant="grao"] [data-theme="light"] { --accent: #5a3a24; --accent-hover: #4c2d17; --accent-pressed: #3e200a; --on-accent: #ffffff; --accent-text: #5a3a24; --accent-soft: #ffece0; --accent-on-soft: #5a3a24; }
[data-restaurant="grao"][data-theme="dark"], [data-restaurant="grao"] [data-theme="dark"], [data-theme="dark"] [data-restaurant="grao"] { --accent: #a58169; --accent-hover: #b59078; --accent-pressed: #c59f87; --on-accent: #16161a; --accent-text: #a58169; --accent-soft: #391f0c; --accent-on-soft: #ab876f; }
[data-restaurant="nuvem"], [data-restaurant="nuvem"] [data-theme="light"] { --accent: #ffd23f; --accent-hover: #eec225; --accent-pressed: #dcb21c; --on-accent: #16161a; --accent-text: #896e10; --accent-soft: #f9f0d6; --accent-on-soft: #836803; }
[data-restaurant="nuvem"][data-theme="dark"], [data-restaurant="nuvem"] [data-theme="dark"], [data-theme="dark"] [data-restaurant="nuvem"] { --accent: #ffd23f; --accent-hover: #eec225; --accent-pressed: #dcb21c; --on-accent: #16161a; --accent-text: #ffd23f; --accent-soft: #302504; --accent-on-soft: #ffd23f; }
[data-restaurant="lenha"], [data-restaurant="lenha"] [data-theme="light"] { --accent: #141414; --accent-hover: #090909; --accent-pressed: #030303; --on-accent: #ffffff; --accent-text: #141414; --accent-soft: #f0f0f0; --accent-on-soft: #141414; }
[data-restaurant="lenha"][data-theme="dark"], [data-restaurant="lenha"] [data-theme="dark"], [data-theme="dark"] [data-restaurant="lenha"] { --accent: #f3f2ef; --accent-hover: #e2e1df; --accent-pressed: #d2d1ce; --on-accent: #16161a; --accent-text: #f3f2ef; --accent-soft: #262626; --accent-on-soft: #f3f2ef; }

/* =========================== MOLDURAS DE DEMONSTRAÇÃO ===========================
   Só para as prévias deste sistema: aparelho de 390 px e tela de 1440 px. */
.demo { padding: var(--space-4); font-family: var(--font-text); color: var(--text); background: var(--bg); }
.demo-row { display: flex; flex-wrap: wrap; gap: var(--space-6); align-items: flex-start; }
.demo-col { display: grid; gap: var(--space-2); align-content: start; }
.demo-label { max-width: 390px; font-size: 12px; line-height: 16px; color: var(--text-muted); font-weight: 500; }
.demo-box { position: relative; border-radius: var(--radius-md); box-shadow: 0 0 0 1px var(--border); background: var(--bg); overflow: hidden; }
.demo-dark { background: #0e0e10; }
.demo-phone { position: relative; width: 390px; height: 844px; border-radius: 44px; overflow: hidden; background: var(--bg); box-shadow: 0 0 0 1px var(--border), 0 0 0 10px #0d0d0f, 0 20px 50px rgba(0, 0, 0, 0.18); flex: none; }
.demo-phone--short { height: 720px; }
.demo-phone::before { content: ""; position: absolute; top: 10px; left: 50%; width: 110px; height: 32px; margin-left: -55px; border-radius: 20px; background: #0d0d0f; z-index: 200; }
.demo-phone .cd-app { padding-top: 0; }
.demo-phone .cd-app > .cd-scroll, .demo-phone .cd-app > .cd-reels { padding-top: 54px; }
.demo-phone .cd-app > .cd-reels { padding-top: 0; }
.demo-phone .cd-reel__top { top: 56px; }
.demo-phone .cd-storyview__top { padding-top: 54px; }
.demo-phone .cd-tabbar { bottom: 24px; }
.demo-phone { --tabbar-space: calc(var(--tabbar-h) + 24px); }
.demo-pair { display: flex; gap: 40px; align-items: flex-start; padding: 24px 24px 24px 34px; background: var(--bg); }
.demo-pair__label { font-size: 13px; color: var(--text-muted); margin: 0 0 14px; font-weight: 500; font-variant-numeric: tabular-nums; }
.demo-desk { width: 720px; height: 450px; overflow: hidden; border-radius: 12px; box-shadow: 0 0 0 1px var(--border), 0 20px 50px rgba(0, 0, 0, 0.12); flex: none; position: relative; }
.demo-desk__inner { width: 1440px; height: 900px; transform: scale(0.5); transform-origin: 0 0; position: relative; overflow: hidden; background: var(--bg); }
.demo-desk--tall { height: 600px; }
.demo-desk--tall .demo-desk__inner { height: 1200px; }

/* Cardápio no computador: coluna central como o Instagram web, abas na lateral esquerda */
.cd-web { position: relative; height: 100%; display: grid; grid-template-columns: 1fr var(--feed-col) 1fr; background: var(--bg); }
.cd-web__side { position: relative; }
.cd-web__brand { position: absolute; top: var(--space-6); left: var(--space-6); display: flex; align-items: center; gap: var(--space-3); }
.cd-web__brand img { width: 40px; height: 40px; border-radius: 50%; object-fit: cover; }
.cd-web__brand b { font-family: var(--font-display); font-weight: var(--display-weight); font-size: 20px; }
.cd-web__col { position: relative; height: 100%; overflow: hidden; border-left: 1px solid var(--border); border-right: 1px solid var(--border); }
.cd-web__col > .cd-app { height: 100%; }
.cd-web__col .cd-app > .cd-scroll { padding-bottom: var(--space-10); }
.cd-web__right { padding: var(--space-8) var(--space-6); display: grid; gap: var(--space-4); align-content: start; max-width: 340px; }
.cd-web .cd-tabbar--vertical { left: var(--space-6); }
.cd-web .cd-toast { bottom: var(--space-6); }
.cd-web .cd-stickycta { bottom: var(--space-3); }
.cd-web .cd-reel__info, .cd-web .cd-reel__rail { bottom: 40px; }
.cd-web .cd-reel__progress { bottom: 18px; }
.cd-web .cd-sheet { left: 50%; right: auto; width: 520px; margin-left: -260px; bottom: auto; top: 50%; transform: translateY(-50%); border-radius: var(--radius-xl); max-height: 86%; animation: cd-fade var(--dur-base) var(--ease-standard); }
.cd-web .cd-sheet__grab { visibility: hidden; height: 12px; }
.cd-web .cd-storyview { left: 50%; right: auto; width: 480px; margin-left: -240px; }
.cd-web__storybg { position: absolute; inset: 0; background: #0b0b0d; z-index: 79; }
/* Estados simulados nas prévias (pressionado e foco aparecem sem interação) */
.is-pressed { transform: scale(0.96); }
.cd-btn.is-pressed, .cd-add__btn.is-pressed { background: var(--accent-pressed); }
.cd-btn--secondary.is-pressed { background: var(--border); }
.is-focus { outline: 2px solid var(--focus-ring); outline-offset: 2px; }
.on-media .is-focus, .cd-tabbar .is-focus { outline-color: #fff; box-shadow: 0 0 0 4px rgba(0, 0, 0, 0.55); }
.cd-tabbar .cd-tab.is-focus { outline-offset: -3px; box-shadow: none; }
.demo-surface { padding: var(--space-4); border-radius: var(--radius-md); background: var(--bg); color: var(--text); box-shadow: 0 0 0 1px var(--border); }
.demo-stage { position: relative; border-radius: var(--radius-md); overflow: hidden; box-shadow: 0 0 0 1px var(--border); }

