/* Guia One · Global One. Carrega depois de global.css (navegação, rodapé e fontes).
   Recomendador para o cliente: fundo cinza-claro, cartões brancos sem borda, botões em pílula, controle segmentado.
   Títulos em Jost (a letra da logo), texto em Inter; a navegação e o rodapé escuros vêm de global.css.
   Tema automático / claro / escuro (botão na barra do Guia One). Azul da logo só em ação, seleção e links. */
:root {
  --font: var(--g-font);
  --font-titulo: var(--g-font-display);
  --radius: 18px;               /* cartões, painéis e janelas */
  --radius-md: 12px;            /* campos, miniaturas e tabelas */
  --radius-sm: 8px;
  --pill: 980px;

  /* claro */
  --bg: #f5f5f7;
  --surface: #ffffff;
  --surface-2: #f5f5f7;
  --fill: #e8e8ed;              /* fundo do controle segmentado */
  --aba-sel: #ffffff;
  --line: #d2d2d7;
  --line-2: #e8e8ed;
  --ink: #1d1d1f;
  --ink-2: #6e6e73;             /* 5,1:1 sobre branco */
  --accent: #3274cf;            /* o "1" do G1 */
  --accent-fill: #3274cf;       /* botões: texto branco 4,6:1 */
  --accent-hover: #2a63b8;
  --accent-text: #1f5fae;       /* links e seleção sobre claro: 6,3:1 */
  --accent-ink: #ffffff;
  --accent-soft: rgba(50, 116, 207, .09);
  --foco: rgba(50, 116, 207, .34);
  --stage: transparent;
  --sombra: 2px 4px 12px rgba(0, 0, 0, .08);
  --sombra-hover: 2px 4px 16px rgba(0, 0, 0, .16);
  --sombra-flutuante: 0 10px 30px rgba(0, 0, 0, .12);
  --ok: #0b7547;
  --warn: #8a5000;
  --warn-bg: rgba(217, 119, 6, .10);
  --danger: #c62828;
  --danger-bg: rgba(220, 38, 38, .08);
  color-scheme: light;
}
:root[data-theme="dark"] {
  --bg: #000000;
  --surface: #1c1c1e;
  --surface-2: #2c2c2e;
  --fill: #2c2c2e;
  --aba-sel: #5a5a5e;
  --line: #424245;
  --line-2: #2c2c2e;
  --ink: #f5f5f7;
  --ink-2: #a1a1a6;             /* 6,6:1 sobre #1c1c1e */
  --accent: #4d8fe6;
  --accent-fill: #3274cf;
  --accent-hover: #3477cf;
  --accent-text: #6aa5f5;       /* 6,7:1 sobre #1c1c1e */
  --accent-ink: #ffffff;
  --accent-soft: rgba(77, 143, 230, .16);
  --foco: rgba(106, 165, 245, .45);
  --stage: rgba(255, 255, 255, .07);  /* palco claro atrás do recorte, para produtos escuros */
  --sombra: none;
  --sombra-hover: none;
  --sombra-flutuante: 0 10px 30px rgba(0, 0, 0, .6);
  --ok: #34d399;
  --warn: #fbbf24;
  --warn-bg: rgba(251, 191, 36, .10);
  --danger: #f87171;
  --danger-bg: rgba(239, 68, 68, .10);
  color-scheme: dark;
}

body { font: .9375rem/1.47 var(--font); background: var(--bg); color: var(--ink); transition: background-color .2s, color .2s; }
button, input, select { font: inherit; color: inherit; }
:focus-visible { outline-color: var(--accent); }
.rotulo { font-size: .75rem; color: var(--ink-2); font-weight: 500; }

/* ---------- barras: a global rola junto; a do Guia One fica presa no topo ---------- */
.pagina-guia .nav-global { position: relative; background: #000; -webkit-backdrop-filter: none; backdrop-filter: none; }   /* sobre fundo claro, a translucidez deixaria a barra cinza */
.nav-local { position: sticky; top: 0; z-index: 40; background: color-mix(in srgb, var(--bg) 82%, transparent);
  -webkit-backdrop-filter: saturate(180%) blur(20px); backdrop-filter: saturate(180%) blur(20px);
  border-bottom: 1px solid color-mix(in srgb, var(--ink) 14%, transparent); }
.nav-local__in { max-width: 1280px; height: 52px; margin: 0 auto; padding: 0 24px; display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.nav-local__titulo { display: flex; align-items: center; gap: 10px; font-family: var(--font-titulo); font-size: 1.3125rem; font-weight: 500; letter-spacing: .005em; white-space: nowrap; }
.nav-local__titulo img { width: 28px; height: 28px; border-radius: 22.5%; display: block; }
.nav-local__acoes { display: flex; align-items: center; gap: 8px; min-width: 0; }

.nichos { display: flex; gap: 6px; overflow-x: auto; scrollbar-width: none; }
.nichos::-webkit-scrollbar { display: none; }
.nicho {
  border: 1px solid var(--line); background: transparent; color: var(--ink); padding: 5px 14px; white-space: nowrap;
  border-radius: var(--pill); cursor: pointer; font-size: .8125rem;
}
.nicho:hover { border-color: var(--ink-2); }
.nicho[aria-pressed="true"] { background: var(--accent-fill); border-color: var(--accent-fill); color: var(--accent-ink); }
.nicho[disabled] { opacity: .5; cursor: not-allowed; }
.nicho small { font-size: .75rem; margin-left: 6px; opacity: .8; }
.nicho__ic { display: inline-grid; place-items: center; vertical-align: -3px; margin-right: 2px; }
.nicho__ic svg { width: 16px; height: 16px; fill: currentColor; }

.icone-btn {
  width: 36px; height: 36px; border-radius: 50%; border: 0; flex: none;
  background: transparent; cursor: pointer; display: grid; place-items: center; color: var(--ink);
}
.icone-btn:hover { background: var(--fill); }
.ico { width: 18px; height: 18px; display: none; }
:root[data-pref="light"] .ico--sol, :root[data-pref="dark"] .ico--lua, :root:not([data-pref="light"]):not([data-pref="dark"]) .ico--auto { display: block; }

/* ---------- abertura ---------- */
.abertura-guia { padding: 48px 24px 4px; }
.abertura-guia__in { max-width: 1232px; margin: 0 auto; }   /* alinha com o conteúdo de .layout (1280 − 2 × 24) */
.abertura-guia h1 { font-family: var(--font-titulo); font-size: 2.5rem; line-height: 1.1; font-weight: 500; letter-spacing: -.015em; }
.abertura-guia p { color: var(--ink-2); font-size: 1.1875rem; line-height: 1.4; max-width: 40em; margin-top: 8px; }

/* ---------- layout ---------- */
.layout { display: grid; grid-template-columns: 340px minmax(0, 1fr); gap: 28px; max-width: 1280px; margin: 0 auto; padding: 28px 24px 88px; }
.atendimento {
  display: flex; flex-direction: column; gap: 12px; align-self: start; position: sticky; top: 68px;
  max-height: calc(100vh - 84px); max-height: calc(100dvh - 84px);
  overflow-y: auto; overscroll-behavior: contain; padding-right: 4px; margin-right: -4px;
  scrollbar-width: thin; scrollbar-color: var(--line) transparent;
}
.atendimento__cab { display: flex; align-items: center; justify-content: space-between; gap: 8px;
  position: sticky; top: 0; z-index: 2; background: var(--bg); padding: 2px 0 8px; }
.atendimento__cab h2 { font-family: var(--font-titulo); font-size: 1.1875rem; font-weight: 500; }

.bloco { background: var(--surface); border-radius: var(--radius); padding: 18px; }
.bloco__titulo { display: block; font-size: .875rem; font-weight: 600; color: var(--ink); margin-bottom: 12px; }
.dica { font-weight: 400; color: var(--ink-2); }

input[type="search"] {
  width: 100%; height: 44px; padding: 0 14px; border: 1px solid var(--line); border-radius: var(--radius-md);
  background: var(--surface); color: var(--ink); font-size: .9375rem;
}
input[type="search"]:focus-visible { outline: none; border-color: var(--accent); box-shadow: 0 0 0 4px var(--foco); }
input::placeholder { color: var(--ink-2); }

.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip {
  border: 1px solid var(--line); background: var(--surface); padding: 8px 14px; border-radius: var(--pill);
  cursor: pointer; font-size: .8125rem; line-height: 1.2; color: var(--ink);
}
.chip:hover { border-color: var(--ink-2); }
.chip[aria-pressed="true"] { background: var(--accent-soft); border-color: var(--accent); box-shadow: inset 0 0 0 1px var(--accent); color: var(--accent-text); }

.btn {
  border: 1px solid var(--accent-fill); background: var(--accent-fill); color: var(--accent-ink);
  padding: 9px 18px; border-radius: var(--pill); cursor: pointer; font-size: .875rem; line-height: 1.2;
}
.btn:hover { background: var(--accent-hover); border-color: var(--accent-hover); }
.btn--ghost { background: transparent; color: var(--accent-text); border-color: var(--accent); }
.btn--ghost:hover { background: var(--accent-soft); border-color: var(--accent); }
.btn--sm { padding: 7px 14px; font-size: .8125rem; }
a.btn { text-decoration: none; display: inline-flex; align-items: center; justify-content: center; }

.guia summary { cursor: pointer; font-weight: 600; font-size: .9375rem; }
.guia__dica { font-size: .8125rem; color: var(--ink-2); margin: 8px 0 4px; }
.guia__q { margin-top: 16px; }
.guia__q > p { font-size: .875rem; font-weight: 600; margin-bottom: 8px; }
.guia__q > p small { font-weight: 400; color: var(--ink-2); margin-left: 6px; font-size: .75rem; }
.guia ul { margin: 10px 0 0; padding-left: 18px; color: var(--ink-2); font-size: .875rem; }
.guia li + li { margin-top: 6px; }

/* ---------- abas: controle segmentado ---------- */
.abas { display: flex; gap: 2px; margin-bottom: 16px; padding: 3px; border-radius: var(--pill); background: var(--fill);
  width: fit-content; max-width: 100%; overflow-x: auto; scrollbar-width: none; }
.abas::-webkit-scrollbar { display: none; }
.aba { border: 0; background: transparent; padding: 7px 16px; border-radius: var(--pill); cursor: pointer; font-size: .8125rem;
  color: var(--ink); white-space: nowrap; flex: none; }
.aba b { font-weight: 400; color: var(--ink-2); margin-left: 6px; }
.aba:hover { background: color-mix(in srgb, var(--aba-sel) 50%, transparent); }
.aba[aria-selected="true"] { background: var(--aba-sel); font-weight: 600; box-shadow: 0 1px 3px rgba(0, 0, 0, .12), 0 0 0 .5px rgba(0, 0, 0, .04); }
.abas--cat { margin-bottom: 12px; }
.abas[hidden], .bandeja[hidden] { display: none; }
.tipos-linha { font-size: .8125rem; color: var(--ink-2); }
.tipos-linha b { color: var(--ink); font-weight: 600; }

/* ---------- comparativo e especificações ---------- */
.mini-specs { margin: 0; display: grid; gap: 6px; font-size: .8125rem; }
.mini-specs div { display: grid; grid-template-columns: 92px minmax(0, 1fr); gap: 8px; }
.mini-specs dt { color: var(--ink-2); }
.mini-specs dd { margin: 0; font-weight: 500; }
.btn[disabled] { opacity: .5; cursor: not-allowed; }
.btn-comp[aria-pressed="true"] { border-color: var(--accent); color: var(--accent-text); background: var(--accent-soft); }

.bandeja {
  position: sticky; top: 64px; z-index: 4; display: flex; flex-wrap: wrap; align-items: center; gap: 8px 12px;
  padding: 10px 12px 10px 18px; margin-bottom: 16px; border-radius: var(--radius);
  background: var(--surface); box-shadow: var(--sombra-flutuante); border: 1px solid var(--line-2);
}
.bandeja__t { font-size: .875rem; }
.bandeja__itens { display: flex; flex-wrap: wrap; gap: 6px; flex: 1 1 200px; }
.bandeja__itens .chip { padding: 4px 10px; font-size: .8125rem; }
.bandeja__acoes { display: flex; gap: 8px; margin-left: auto; }

dialog.detalhe--larga { width: min(1100px, calc(100vw - 24px)); }
.comp-barra { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; }
.comp-dif { display: inline-flex; align-items: center; gap: 8px; font-size: .875rem; cursor: pointer; }
.comp-dif input { width: 18px; height: 18px; accent-color: var(--accent-fill); }
.comp-wrap { overflow: auto; border: 1px solid var(--line-2); border-radius: var(--radius-md); }
table.comp { border-collapse: separate; border-spacing: 0; width: 100%; min-width: 560px; font-size: .875rem; }
table.comp th, table.comp td { padding: 12px 14px; text-align: left; vertical-align: top; border-bottom: 1px solid var(--line-2); border-left: 1px solid var(--line-2); }
table.comp tr > :first-child { border-left: 0; }
table.comp thead th { position: sticky; top: 0; background: var(--surface); z-index: 2; }
table.comp tbody th { position: sticky; left: 0; background: var(--surface); z-index: 1; width: 150px; min-width: 130px; font-weight: 500; color: var(--ink-2); }
table.comp thead th:first-child { left: 0; z-index: 3; }
table.comp tr.dif td { background: var(--accent-soft); }
table.comp td { min-width: 170px; }
.comp-cab { display: flex; gap: 10px; align-items: center; }
.comp-cab small { display: block; color: var(--ink-2); font-weight: 400; }
.comp-cab .mini { width: 44px; height: 44px; border-radius: 10px; background: var(--surface-2); flex: none; overflow: hidden; display: grid; place-items: center; }
.comp-cab .mini img { width: 100%; height: 100%; object-fit: contain; }
.comp-cab .mini--ph svg { width: 24px; height: 24px; color: var(--ink-2); }
.comp-nota { font-size: .8125rem; color: var(--ink-2); }
table.specs { border-collapse: collapse; width: 100%; font-size: .875rem; }
table.specs th, table.specs td { text-align: left; padding: 9px 0; border-top: 1px solid var(--line-2); vertical-align: top; }
table.specs tr:first-child th, table.specs tr:first-child td { border-top: 0; }
table.specs th { width: 38%; color: var(--ink-2); font-weight: 400; padding-right: 12px; }

.comp-slots { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px; }
.slot { display: grid; gap: 6px; font-size: .8125rem; color: var(--ink-2); font-weight: 500; }
.slot select {
  width: 100%; min-height: 44px; padding: 8px 12px; border: 1px solid var(--line); border-radius: var(--radius-md);
  background: var(--surface); color: var(--ink); font-size: .875rem;
}
.slot select:focus-visible { outline: none; border-color: var(--accent); box-shadow: 0 0 0 4px var(--foco); }
.comp-acoes { display: inline-flex; gap: 8px; flex-wrap: wrap; }

/* ---------- resultados ---------- */
.aviso { font-size: .8125rem; color: var(--ink-2); margin-bottom: 20px; max-width: 70em; }
.aviso:empty { display: none; }
.alerta {
  display: flex; gap: 10px; align-items: flex-start; border-radius: var(--radius-md); padding: 12px 14px;
  margin-bottom: 14px; font-size: .875rem; background: var(--warn-bg); color: var(--warn);
}
.alerta::before { content: "⚠"; flex: none; }
.vazio { text-align: center; padding: 48px 20px; color: var(--ink-2); border-radius: var(--radius); background: var(--surface); }
.vazio h2 { color: var(--ink); font-family: var(--font-titulo); font-size: 1.3125rem; font-weight: 500; margin-bottom: 6px; }

.secao { margin-bottom: 44px; }
.secao__cab { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; margin-bottom: 16px; flex-wrap: wrap; }
.secao__cab h2 { font-family: var(--font-titulo); font-size: 1.75rem; line-height: 1.15; font-weight: 500; letter-spacing: -.01em; }
.secao__cab span { color: var(--ink-2); font-size: .875rem; }
.sub { font-family: var(--font-titulo); font-size: 1.3125rem; line-height: 1.2; font-weight: 500; color: var(--ink); margin: 20px 0 4px; }

.grade { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 20px; }

.card { background: var(--surface); border-radius: var(--radius); display: flex; flex-direction: column; overflow: hidden;
  box-shadow: var(--sombra); transition: box-shadow .3s cubic-bezier(0, 0, .5, 1); }
.card:hover { box-shadow: var(--sombra-hover); }
.card--top { box-shadow: 0 0 0 2px var(--accent), var(--sombra); }
.card--top:hover { box-shadow: 0 0 0 2px var(--accent), var(--sombra-hover); }
.card__corpo { padding: 4px 20px 20px; display: flex; flex-direction: column; gap: 12px; flex: 1; }

/* palco da foto: produto sobre o próprio cartão; no escuro, um brilho suave atrás do recorte */
.thumb { position: relative; height: 210px; overflow: hidden;
  background: radial-gradient(ellipse 60% 58% at 50% 54%, var(--stage) 0%, transparent 100%); }
.thumb img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; padding: 22px; display: block; }
.thumb--ph { background: var(--surface-2); color: var(--ink-2); display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 6px; }
.thumb--ph svg { width: 54px; height: 54px; opacity: .8; }
.thumb--ph span { font-size: .75rem; }
.selo {
  position: absolute; top: 14px; left: 14px; font-size: .75rem; font-weight: 600; padding: 4px 10px; border-radius: var(--pill);
  background: var(--accent-fill); color: var(--accent-ink);
}

.card h3 { font-family: var(--font-titulo); font-size: 1.1875rem; line-height: 1.25; font-weight: 500; letter-spacing: -.005em; }
.card__meta { color: var(--ink-2); font-size: .8125rem; margin-top: 2px; }
.tags { display: flex; flex-wrap: wrap; gap: 6px; }
.tags:empty { display: none; }
.tag { font-size: .75rem; padding: 2px 9px; border-radius: var(--pill); border: 1px solid var(--line); color: var(--ink-2); }
.tag--forte { color: var(--danger); background: var(--danger-bg); border-color: transparent; }
.tag--media { color: var(--warn); background: var(--warn-bg); border-color: transparent; }
.tag--ok { color: var(--ok); }

.barra { height: 6px; border-radius: 999px; background: var(--fill); overflow: hidden; }
.barra > i { display: block; height: 100%; background: var(--accent); border-radius: 999px; }
.match { font-size: .8125rem; color: var(--ink-2); display: flex; justify-content: space-between; margin-bottom: 5px; }
.match b { color: var(--ink); }

.motivos { margin: 0; padding-left: 18px; font-size: .8125rem; }
.motivos--alerta { color: var(--warn); }
.card p.resumo-txt { font-size: .8125rem; line-height: 1.45; color: var(--ink-2); }
.card__acoes { display: flex; gap: 8px; margin-top: auto; flex-wrap: wrap; padding-top: 6px; }

/* rotina */
.rotina { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 20px; }
.rotina__col { background: var(--surface); border-radius: var(--radius); padding: 16px 18px; box-shadow: var(--sombra); }
.rotina__col h3 { font-size: .9375rem; font-weight: 600; margin-bottom: 8px; }
.rotina ol { list-style: none; margin: 0; padding: 0; counter-reset: p; }
.rotina li { counter-increment: p; display: flex; gap: 12px; padding: 10px 0; border-top: 1px solid var(--line-2); align-items: center; }
.rotina li:first-child { border-top: 0; }
.rotina li::before {
  content: counter(p); flex: none; width: 24px; height: 24px; border-radius: 50%;
  background: var(--accent-soft); color: var(--accent-text); display: grid; place-items: center; font-size: .75rem; font-weight: 600;
}
.rotina .mini { width: 44px; height: 44px; border-radius: 10px; background: var(--surface-2); flex: none; overflow: hidden; display: grid; place-items: center; }
.rotina .mini img { width: 100%; height: 100%; object-fit: contain; padding: 3px; }
.rotina .mini--ph { background: var(--surface-2); color: var(--ink-2); }
.rotina .mini--ph svg { width: 22px; height: 22px; }
.rotina li button { all: unset; cursor: pointer; font-weight: 600; font-size: .875rem; display: inline-flex; align-items: center; min-height: 28px; }
.rotina li button:hover { color: var(--accent-text); text-decoration: underline; }
.rotina li small { display: block; color: var(--ink-2); font-size: .75rem; }

/* ---------- janela de detalhe ---------- */
dialog.detalhe {
  width: min(780px, calc(100vw - 24px)); max-height: calc(100vh - 32px);
  border: 0; border-radius: var(--radius); padding: 0; background: var(--surface); color: var(--ink);
  box-shadow: 0 30px 90px rgba(0, 0, 0, .35);
}
dialog.detalhe::backdrop { background: rgba(0, 0, 0, .42); -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px); }
.det__cab {
  position: sticky; top: 0; background: var(--surface); padding: 20px 20px 14px 24px;
  border-bottom: 1px solid var(--line-2); display: flex; gap: 12px; justify-content: space-between; align-items: flex-start; z-index: 1;
}
.det__cab h2 { font-family: var(--font-titulo); font-size: 1.3125rem; line-height: 1.25; font-weight: 500; }
.det__fechar { all: unset; cursor: pointer; flex: none; width: 32px; height: 32px; border-radius: 50%; display: grid; place-items: center;
  font-size: 1.25rem; line-height: 1; background: var(--fill); color: var(--ink-2); box-sizing: border-box; }
.det__fechar:hover { color: var(--ink); }
.det__fechar:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.det__corpo { padding: 18px 24px 26px; display: grid; grid-template-columns: minmax(0, 1fr); gap: 20px; overflow: auto; max-height: calc(100vh - 110px); }
.det__topo { display: grid; grid-template-columns: 170px minmax(0, 1fr); gap: 18px; align-items: start; }
.det__topo .thumb { height: 190px; border-radius: var(--radius-md); background-color: var(--surface-2); }
.det__corpo h3 { font-size: .9375rem; color: var(--ink); margin-bottom: 6px; font-weight: 600; }
.det__corpo ul, .det__corpo ol { margin: 0; padding-left: 20px; }
.det__corpo li + li { margin-top: 4px; }
.fontes { font-size: .8125rem; color: var(--ink-2); }
.fontes a { color: var(--accent-text); word-break: break-all; }
.confianca { font-size: .8125rem; padding: 10px 12px; border-radius: var(--radius-md); background: var(--surface-2); color: var(--ink-2); }
.det__acoes { display: flex; gap: 8px; flex-wrap: wrap; }

.toast {
  position: fixed; left: 50%; bottom: 24px; transform: translate(-50%, 20px); opacity: 0; pointer-events: none;
  background: var(--ink); color: var(--bg); padding: 12px 20px; border-radius: var(--pill); transition: .25s; z-index: 60;
  font-size: .875rem; box-shadow: var(--sombra-flutuante);
}
.toast.on { opacity: 1; transform: translate(-50%, 0); }

/* ---------- barra fixa de indicações (só celular) ---------- */
.acao-fixa, .acao-fixa[hidden] { display: none; }

/* ---------- responsivo ---------- */
@media (max-width: 880px) {
  .layout { grid-template-columns: minmax(0, 1fr); padding: 20px 16px 48px; gap: 24px; }   /* minmax: as abas roláveis não alargam a página */
  .atendimento { position: static; max-height: none; overflow: visible; padding-right: 0; margin-right: 0; }
  .nav-local__in { padding: 0 16px; }
  .abertura-guia { padding: 32px 16px 0; }
  .abertura-guia h1 { font-size: 2rem; }
  .abertura-guia p { font-size: 1.0625rem; }
  .bandeja { top: 60px; }
  .det__topo { grid-template-columns: 1fr; }
  .det__topo .thumb { height: 200px; }
  .det__cab { padding: 16px 16px 12px 20px; }
  .det__corpo { padding: 16px 20px 22px; }
  .comp-slots { grid-template-columns: repeat(2, minmax(0, 1fr)); }

  body { padding-bottom: 76px; }
  .acao-fixa:not([hidden]) {
    display: flex; align-items: center; justify-content: space-between; gap: 12px;
    position: fixed; left: 0; right: 0; bottom: 0; z-index: 30;
    padding: 10px 16px calc(10px + env(safe-area-inset-bottom));
    background: color-mix(in srgb, var(--surface) 86%, transparent); border-top: 1px solid var(--line-2);
    -webkit-backdrop-filter: saturate(180%) blur(20px); backdrop-filter: saturate(180%) blur(20px);
  }
  .acao-fixa span { font-size: .875rem; color: var(--ink-2); min-width: 0; }
  .acao-fixa b { color: var(--ink); }
  .acao-fixa .btn { flex: none; }
  .toast { bottom: 88px; }

  /* ao rolar até os resultados ou filtros, o título não fica atrás da barra presa no topo */
  #resultado, .atendimento { scroll-margin-top: 64px; }

  /* 16 px nos campos: abaixo disso o iPhone dá zoom ao tocar */
  input[type="search"], .slot select, .campo { font-size: 1rem; }

  .atendimento { gap: 10px; }
  .atendimento__cab { position: static; }
  .bloco { padding: 16px; }

  /* janelas de detalhe e comparativo: painel por baixo, largura toda */
  dialog.detalhe, dialog.detalhe--larga {
    width: 100%; max-width: 100%; margin: auto 0 0; max-height: 92vh; max-height: 92dvh;
    border-radius: var(--radius) var(--radius) 0 0;
  }
  .det__corpo { max-height: calc(92vh - 70px); max-height: calc(92dvh - 70px); padding-bottom: calc(22px + env(safe-area-inset-bottom)); }
  table.comp tbody th { width: 112px; min-width: 112px; }
  table.comp td { min-width: 150px; }
  table.comp th, table.comp td { padding: 10px 12px; }
}
@media (max-width: 600px) {
  .nav-local__titulo { font-size: 1.1875rem; }
  .secao__cab h2 { font-size: 1.5rem; }
  .secao { margin-bottom: 36px; }
  .abertura-guia { padding-top: 24px; }
  .abertura-guia h1 { font-size: 1.75rem; }
  .abertura-guia p { font-size: 1rem; }

  /* cartões mais baixos: foto menor e botões dividindo a linha */
  .grade { gap: 14px; }
  .thumb { height: 170px; }
  .thumb img { padding: 16px; }
  .card__corpo { padding: 2px 16px 16px; gap: 10px; }
  .card__acoes .btn { flex: 1 1 0; }
  .card__acoes .btn:last-child:nth-child(3) { flex-basis: 100%; }
  .det__topo .thumb { height: 180px; }
}
/* tela estreita: só o ícone do Guia One, para os nichos caberem inteiros */
@media (max-width: 480px) {
  .nav-local__in { gap: 10px; padding: 0 12px; }
  .nav-local__titulo { font-size: 0; gap: 0; }
  .nichos { gap: 4px; }
  .nicho { padding: 5px 12px; }
}

/* toque: alvo de 44 pt */
@media (pointer: coarse) {
  .aba { min-height: 40px; }
  .chip, .nicho, .btn, .btn--sm, .icone-btn { min-height: 44px; }
  .icone-btn { min-width: 44px; }
  .rotina li button { min-height: 44px; }
  .det__fechar { width: 44px; height: 44px; }
  .guia summary { min-height: 44px; display: flex; align-items: center; }
  .chips { gap: 10px; }
}

@media print {
  .atendimento, .nav-global, .nav-local, .rodape, .toast, .acao-fixa { display: none; }
  .layout { display: block; padding: 0; }
}

/* ---------- abas de categoria no topo (cada aba tem as próprias perguntas) ---------- */
.abas--topo { grid-column: 1 / -1; margin-bottom: 0; }

/* ---------- perguntas: lista e campo de texto ---------- */
select.campo, input.campo {
  width: 100%; min-height: 44px; padding: 8px 12px; border: 1px solid var(--line); border-radius: var(--radius-md);
  background: var(--surface); color: var(--ink); font-size: .875rem;
}
select.campo:focus-visible, input.campo:focus-visible { outline: none; border-color: var(--accent); box-shadow: 0 0 0 4px var(--foco); }
.ref-escolhida { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 8px 8px 8px 14px;
  border-radius: var(--radius-md); background: var(--accent-soft); color: var(--accent-text); font-weight: 600; font-size: .875rem; }
.ref-escolhida small { font-weight: 400; color: var(--ink-2); margin-left: 4px; }
.recurso summary { cursor: pointer; font-weight: 600; font-size: .875rem; }
.recurso .chips { margin-top: 12px; }

/* ---------- dica do especialista, compatibilidade e "em relação ao seu" ---------- */
.dica-esp { border-radius: var(--radius-md); padding: 14px 16px; margin-bottom: 16px; background: var(--accent-soft); font-size: .875rem; }
.dica-esp b { display: block; color: var(--accent-text); margin-bottom: 4px; }
.dica-esp p + p { margin-top: 6px; }
.compat { font-size: .8125rem; padding: 8px 12px; border-radius: var(--radius-sm); background: var(--warn-bg); color: var(--ink); }
.compat--det { padding: 12px 14px; border-radius: var(--radius-md); font-size: .875rem; }
.compat--det h3 { color: var(--warn); }
.melhora { font-size: .8125rem; padding: 10px 12px; border-radius: var(--radius-sm); background: var(--surface-2); }
.melhora b { display: block; margin-bottom: 4px; }
.melhora ul { margin: 0; padding: 0; list-style: none; display: grid; gap: 3px; }
.melhora li span { color: var(--ink-2); }
.melhora li span::after { content: ":"; }
.melhora small { color: var(--ink-2); }
.tag--cond { color: var(--accent-text); border-color: color-mix(in srgb, var(--accent) 45%, transparent); }
.secao__resumo { cursor: pointer; font-family: var(--font-titulo); font-size: 1.3125rem; font-weight: 500; }

/* ---------- guia de termos (uvas e palavras do rótulo) ---------- */
.glossario__sub { color: var(--ink-2); font-size: .875rem; margin-top: 6px; }
.glossario__lista { margin: 10px 0 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 12px; }
.glossario__lista div { background: var(--surface); border-radius: var(--radius-md); padding: 14px 16px; box-shadow: var(--sombra); }
.glossario__lista dt { font-weight: 600; margin-bottom: 4px; }
.glossario__lista dd { margin: 0; font-size: .8125rem; line-height: 1.5; color: var(--ink-2); }

/* ---------- kits de presente ---------- */
.kits { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 20px; }
.kit { background: var(--surface); border-radius: var(--radius); padding: 18px 20px 20px; box-shadow: var(--sombra); display: flex; flex-direction: column; gap: 10px; }
.kit h3 { font-family: var(--font-titulo); font-size: 1.1875rem; font-weight: 500; }
.kit p { font-size: .8125rem; color: var(--ink-2); }
.kit ul { margin: 0; padding-left: 18px; font-size: .875rem; }
.kit li button { all: unset; cursor: pointer; }
.kit li button:hover { color: var(--accent-text); text-decoration: underline; }
.kit__minis { display: flex; gap: 8px; }
.kit .mini { width: 52px; height: 52px; border-radius: 12px; background: var(--surface-2); overflow: hidden; display: grid; place-items: center; color: var(--ink-2); }
.kit .mini img { width: 100%; height: 100%; object-fit: contain; padding: 4px; }
.kit .mini svg { width: 26px; height: 26px; }

/* ---------- retorno ao toque (150 ms) ---------- */
.btn, .chip, .nicho, .aba, .icone-btn { transition: background-color .15s, border-color .15s, color .15s, box-shadow .15s, transform .1s; }
.btn:active, .chip:active, .nicho:active, .aba:active { transform: scale(.98); }

/* texto só para leitores de tela */
.sr-only { position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
