/* Layout: um bloco fixo no topo (identidade + demo + abas); conteúdo em cartões
     de no máximo 1040px; grades que colapsam para uma coluna no celular.
     A vaga é desenhada, não só descrita: fila de carros e lugares de moto em SVG. */

  :root {
    /* Escuro por padrão: o app é usado à noite, na garagem, no celular. */
    --bg: #0E1014;
    --surface: #161A20;
    --surface-2: #1D222A;
    --surface-3: #242A33;
    --line: #2B323C;
    --line-soft: #222831;
    --fg: #EEF1F5;
    --muted: #9AA4B2;
    --accent: #F2B544;
    --accent-soft: #3A2B0F;
    --accent-line: #6C5219;
    --accent-ink: #16110A;
    --ok: #4BD392;
    --ok-soft: #11291E;
    --warn: #F3C254;
    --warn-soft: #2E2309;
    --crit: #FF8E7E;
    --crit-soft: #351714;
    --display: 'Archivo', 'Archivo Fallback', "Helvetica Neue", Arial, sans-serif;
    --body: 'Figtree', system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
    --mono: 'JetBrains Mono', ui-monospace, SFMono-Regular, Menlo, monospace;
    --r: 11px;
    --shadow: 0 1px 2px rgba(0, 0, 0, .5), 0 10px 28px rgba(0, 0, 0, .32);
    --shadow-up: 0 2px 6px rgba(0, 0, 0, .55), 0 18px 40px rgba(0, 0, 0, .42);
    color-scheme: dark;
  }

  /* Claro para quem preferir, pelo sistema ou pelo botão do app. */
  @media (prefers-color-scheme: light) {
    :root:not([data-theme="dark"]) {
      --bg: #F2F3F5;
      --surface: #FFFFFF;
      --surface-2: #F5F7F9;
      --surface-3: #EDF0F3;
      --line: #DBDFE6;
      --line-soft: #E7EAEF;
      --fg: #12151A;
      --muted: #596273;
      --accent: #8A5500;
      --accent-soft: #FDF2DC;
      --accent-line: #DFB163;
      --accent-ink: #1A1206;
      --ok: #0F6B3F;
      --ok-soft: #E1F3E9;
      --warn: #845609;
      --warn-soft: #FDF0D5;
      --crit: #A32119;
      --crit-soft: #FAE6E4;
      --shadow: 0 1px 2px rgba(16, 20, 28, .06), 0 8px 20px rgba(16, 20, 28, .07);
      --shadow-up: 0 2px 4px rgba(16, 20, 28, .09), 0 14px 32px rgba(16, 20, 28, .11);
      color-scheme: light;
    }
  }

  :root[data-theme="light"] {
    --bg: #F2F3F5;
    --surface: #FFFFFF;
    --surface-2: #F5F7F9;
    --surface-3: #EDF0F3;
    --line: #DBDFE6;
    --line-soft: #E7EAEF;
    --fg: #12151A;
    --muted: #596273;
    --accent: #8A5500;
    --accent-soft: #FDF2DC;
    --accent-line: #DFB163;
    --accent-ink: #1A1206;
    --ok: #0F6B3F;
    --ok-soft: #E1F3E9;
    --warn: #845609;
    --warn-soft: #FDF0D5;
    --crit: #A32119;
    --crit-soft: #FAE6E4;
    --shadow: 0 1px 2px rgba(16, 20, 28, .06), 0 8px 20px rgba(16, 20, 28, .07);
    --shadow-up: 0 2px 4px rgba(16, 20, 28, .09), 0 14px 32px rgba(16, 20, 28, .11);
    color-scheme: light;
  }

  * { box-sizing: border-box; }

  /* Classes como .gate e section[role=tabpanel] definem display, e isso
     venceria a regra do navegador para [hidden]. Sem esta linha as telas
     aparecem todas empilhadas. */
  [hidden] { display: none !important; }

  body {
    margin: 0;
    background: var(--bg);
    color: var(--fg);
    font-family: var(--body);
    font-size: 15.5px;
    line-height: 1.55;
    letter-spacing: .002em;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    text-rendering: optimizeLegibility;
    font-synthesis-weight: none;
  }

  body::before {
    content: "";
    position: fixed;
    inset: 0 0 auto;
    height: env(safe-area-inset-top, 0px);
    z-index: 30;
    background: var(--surface);
  }

  h1, h2, h3, h4 {
    margin: 0;
    font-family: var(--display);
    font-weight: 600;
    letter-spacing: -.014em;
    text-wrap: balance;
  }

  button, input, select { font: inherit; color: inherit; }
  :focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; border-radius: 4px; }

  .wrap {
    max-width: 1040px;
    margin: 0 auto;
    padding-left: max(16px, env(safe-area-inset-left, 0px));
    padding-right: max(16px, env(safe-area-inset-right, 0px));
  }

  /* ---------- topo fixo ---------- */

  .sticky-top {
    position: sticky;
    top: env(safe-area-inset-top, 0px);
    z-index: 20;
    background: var(--surface);
    border-bottom: 1px solid var(--line);
  }

  .topbar .wrap {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding-block: 10px;
  }

  .brand { display: flex; align-items: center; gap: 10px; min-width: 0; }
  .brand h1 { font-size: 18px; font-weight: 700; letter-spacing: -.02em; }
  .brand .sub {
    overflow: hidden;
    color: var(--muted);
    font-size: 10.5px;
    font-weight: 500;
    letter-spacing: .13em;
    text-overflow: ellipsis;
    text-transform: uppercase;
    white-space: nowrap;
  }
  .mark { width: 32px; height: 32px; flex: none; }

  .tema {
    display: grid;
    place-items: center;
    width: 34px;
    height: 34px;
    flex: none;
    padding: 0;
    border: 1px solid var(--line);
    border-radius: 999px;
    background: var(--surface-2);
    color: var(--muted);
    cursor: pointer;
    transition: color .15s ease, background .15s ease, border-color .15s ease;
  }
  .tema:hover { background: var(--surface-3); border-color: var(--accent-line); color: var(--accent); }

  .who {
    display: flex;
    align-items: center;
    gap: 8px;
    flex: none;
    padding: 4px 12px 4px 4px;
    border: 1px solid var(--line);
    border-radius: 999px;
    background: var(--surface-2);
  }
  .who .av {
    display: grid;
    place-items: center;
    width: 26px;
    height: 26px;
    flex: none;
    border: 1px solid var(--accent-line);
    border-radius: 50%;
    background: var(--accent-soft);
    color: var(--accent);
    font-family: var(--display);
    font-size: 12px;
    font-weight: 600;
  }
  .who .nm { font-size: 13px; font-weight: 500; white-space: nowrap; }
  .who .un { color: var(--muted); font-family: var(--mono); font-size: 11.5px; }


  .tabs .wrap { display: flex; gap: 4px; overflow-x: auto; scrollbar-width: thin; }
  .tab {
    flex: none;
    padding: 11px 10px;
    border: 0;
    border-bottom: 2px solid transparent;
    background: none;
    color: var(--muted);
    font-size: 14px;
    font-weight: 500;
    white-space: nowrap;
    cursor: pointer;
    transition: color .15s ease, border-color .15s ease;
  }
  .tab:hover { color: var(--fg); }
  .tab { font-family: var(--display); letter-spacing: -.005em; }
  .tab[aria-selected="true"] { color: var(--fg); border-bottom-color: var(--accent); }
  .tab .cnt {
    display: inline-block;
    margin-left: 5px;
    padding: 0 6px;
    border: 1px solid var(--accent-line);
    border-radius: 999px;
    background: var(--accent-soft);
    color: var(--accent);
    font-family: var(--mono);
    font-size: 11px;
  }

  /* ---------- blocos ---------- */

  main { padding-block: 20px 48px; }
  section[role="tabpanel"] { display: grid; gap: 16px; align-content: start; }

  .card {
    min-width: 0;
    border: 1px solid var(--line);
    border-radius: var(--r);
    background: var(--surface);
    box-shadow: var(--shadow);
  }
  .card > .hd {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 4px 14px;
    flex-wrap: wrap;
    padding: 14px 16px 0;
  }
  .card > .hd h2 { display: flex; align-items: center; gap: 8px; font-size: 16.5px; }
  .card > .hd .note { color: var(--muted); font-size: 12.75px; }
  .card > .bd { padding: 14px 16px; }
  .card > .bd.stack { display: grid; gap: 12px; }

  .eyebrow {
    color: var(--muted);
    font-family: var(--display);
    font-size: 11px;
    font-weight: 600;
    letter-spacing: .14em;
    text-transform: uppercase;
  }

  .grid { display: grid; gap: 12px; grid-template-columns: repeat(auto-fill, minmax(258px, 1fr)); }
  .fields { display: grid; gap: 12px; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); }

  .f { display: grid; gap: 5px; align-content: start; min-width: 0; }
  .f label, .f-lab { color: var(--muted); font-size: 12px; font-weight: 500; letter-spacing: .01em; padding: 0; }
  .f .hint { color: var(--muted); font-size: 11.5px; }
  fieldset.f { margin: 0; padding: 0; border: 0; }

  input[type="date"], input[type="time"], input[type="text"], input[type="tel"],
  input[type="number"], select {
    min-width: 0;
    max-width: 100%;
    padding: 7px 9px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: var(--surface);
  }
  select { background: var(--surface-2); }
  input[readonly] { background: var(--surface-2); color: var(--muted); }

  .chks { display: flex; gap: 6px; flex-wrap: wrap; }
  .chk {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 9px;
    border: 1px solid var(--line);
    border-radius: 7px;
    background: var(--surface-2);
    font-size: 13px;
    cursor: pointer;
    transition: background .15s ease, border-color .15s ease, color .15s ease;
  }
  .chk:hover { border-color: var(--accent-line); }
  .chk input { margin: 0; }
  .chk:has(input:checked) {
    border-color: var(--accent-line);
    background: var(--accent-soft);
    color: var(--accent);
    font-weight: 500;
  }
  .chk:has(input:disabled) { opacity: .45; cursor: not-allowed; }

  /* controle segmentado */
  .seg { display: inline-flex; padding: 3px; border: 1px solid var(--line); border-radius: 9px; background: var(--surface-2); }
  .seg button {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 6px 11px;
    border: 0;
    border-radius: 6px;
    background: none;
    color: var(--muted);
    font-size: 13px;
    font-weight: 500;
    cursor: pointer;
    transition: background .15s ease, color .15s ease;
  }
  .seg button:hover { color: var(--fg); }
  .seg button[aria-pressed="true"] {
    background: var(--surface);
    color: var(--fg);
    font-weight: 600;
    box-shadow: 0 1px 2px rgba(0, 0, 0, .12);
  }

  .btn {
    padding: 9px 15px;
    border: 1px solid var(--fg);
    border-radius: 8px;
    background: var(--fg);
    color: var(--surface);
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: transform .1s ease, opacity .15s ease, background .15s ease;
  }
  .btn:hover { opacity: .92; }
  .btn:active { transform: translateY(1px); }
  .btn.alt { border-color: var(--line); background: var(--surface-2); color: var(--fg); }
  .btn.alt:hover { background: var(--surface-3); }
  .btn.key { border-color: var(--accent); background: var(--accent); color: var(--accent-ink); }
  .btn.danger { border-color: var(--line); background: none; color: var(--crit); }
  .btn.sm { padding: 6px 11px; font-size: 13px; }
  .btn.ghost { padding: 4px 9px; border-color: var(--line); background: none; color: var(--muted); font-size: 12px; font-weight: 500; }
  .btn:disabled { opacity: .45; cursor: not-allowed; }
  .row-actions { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
  .row-actions.top { margin-top: 14px; }
  a.btn { display: inline-flex; align-items: center; line-height: 1.2; text-decoration: none; }
  .linha { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; }

  /* ---------- busca ---------- */

  .search-row { display: grid; gap: 12px; grid-template-columns: 1fr 1fr; }
  .when-group {
    display: grid;
    gap: 7px;
    min-width: 0;
    padding: 9px 11px;
    border: 1px solid var(--line);
    border-radius: 9px;
    background: var(--surface-2);
  }
  .when-inputs { display: flex; gap: 7px; min-width: 0; }
  .when-inputs input { flex: 1 1 0; }
  .filtros { display: grid; gap: 10px; margin-top: 12px; }
  .filtros .linha { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; }
  .search-foot {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    flex-wrap: wrap;
    margin-top: 14px;
    padding-top: 12px;
    border-top: 1px solid var(--line);
  }
  .resumo { display: flex; gap: 8px; flex-wrap: wrap; align-items: baseline; }
  .resumo b { font-family: var(--display); font-size: 15px; }


  /* ---------- formulários longos ---------- */

  .secao {
    display: grid;
    gap: 12px;
    padding-top: 16px;
    border-top: 1px solid var(--line);
  }
  .secao:first-child { padding-top: 0; border-top: 0; }
  .secao > .eyebrow { margin-bottom: -2px; }

  .fields.larga { grid-template-columns: repeat(auto-fit, minmax(210px, 1fr)); }
  .fields.duo { grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); max-width: 440px; }

  .chks.dias { gap: 7px; }
  .chks.dias .chk {
    min-width: 58px;
    justify-content: center;
    padding: 8px 10px;
    font-size: 13.5px;
  }

  .acoes {
    margin-top: 2px;
    padding-top: 16px;
    border-top: 1px solid var(--line);
  }

  /* ---------- cartão de vaga ---------- */

  .vaga {
    display: flex;
    flex-direction: column;
    gap: 10px;
    min-width: 0;
    padding: 13px;
    border: 1px solid var(--line);
    border-radius: var(--r);
    background: var(--surface);
    transition: transform .14s ease, box-shadow .14s ease, border-color .14s ease;
  }
  .vaga:hover { transform: translateY(-2px); border-color: var(--accent-line); box-shadow: var(--shadow-up); }
  .vaga > .row-actions:last-child { margin-top: auto; padding-top: 2px; }
  .vaga .top { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; }
  .vaga .who-col { min-width: 0; }
  .loc { display: flex; align-items: center; gap: 7px; font-family: var(--display); font-size: 16.5px; font-weight: 600; letter-spacing: -.01em; }
  .loc svg { flex: none; color: var(--muted); }
  .meta { color: var(--muted); font-size: 12.75px; }
  .meta.local { display: flex; align-items: center; gap: 5px; }
  .code {
    display: inline-block;
    padding: 2px 7px;
    border: 1px solid var(--line);
    border-radius: 6px;
    background: var(--surface-2);
    font-family: var(--mono);
    font-size: 12.75px;
    font-weight: 600;
    letter-spacing: -.01em;
    white-space: nowrap;
  }
  .price { flex: none; text-align: right; font-variant-numeric: tabular-nums; }
  .price b { display: block; font-family: var(--display); font-size: 20px; font-weight: 700; letter-spacing: -.02em; }
  .price span { color: var(--muted); font-size: 11.5px; }
  .price .gratis { color: var(--ok); }

  .tagrow { display: flex; gap: 6px; flex-wrap: wrap; }
  .pill {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 2px 9px;
    border: 1px solid var(--line);
    border-radius: 999px;
    background: var(--surface-2);
    color: var(--muted);
    font-size: 11.75px;
    font-weight: 500;
    white-space: nowrap;
  }
  .pill svg { flex: none; }
  .pill.ok { border-color: transparent; background: var(--ok-soft); color: var(--ok); }
  .pill.warn { border-color: transparent; background: var(--warn-soft); color: var(--warn); }
  .pill.crit { border-color: transparent; background: var(--crit-soft); color: var(--crit); }
  .pill.acc { border-color: var(--accent-line); background: var(--accent-soft); color: var(--accent); }

  /* desenho da vaga */
  .diag {
    display: grid;
    gap: 6px;
    padding: 9px 10px;
    border: 1px solid var(--line);
    border-radius: 9px;
    background: var(--surface-2);
  }
  .diag .cap { display: flex; align-items: baseline; justify-content: space-between; gap: 8px; flex-wrap: wrap; }
  .diag .cap b { font-family: var(--display); font-size: 12.5px; }
  .diag .cap span { color: var(--muted); font-size: 11.5px; }
  .diag svg { display: block; width: 100%; height: auto; max-width: 100%; }
  .motos { display: flex; gap: 5px; flex-wrap: wrap; align-items: center; }
  .moto-slot {
    display: grid;
    place-items: center;
    width: 30px;
    height: 24px;
    border: 1px solid var(--line);
    border-radius: 5px;
    background: var(--surface);
    color: var(--muted);
  }
  .moto-slot.livre { border-color: transparent; background: var(--ok-soft); color: var(--ok); }
  .moto-slot.ocupada { background: var(--surface-2); color: var(--muted); opacity: .7; }

  .list { display: grid; gap: 10px; }
  .item {
    display: grid;
    gap: 9px;
    padding: 12px;
    border: 1px solid var(--line);
    border-radius: var(--r);
    background: var(--surface);
  }
  .item .l1 { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
  .item .l1 > div { min-width: 0; }
  .when { font-family: var(--mono); font-size: 12.25px; letter-spacing: -.01em; font-variant-numeric: tabular-nums; }
  .empty {
    padding: 20px;
    border: 1px dashed var(--line);
    border-radius: var(--r);
    background: var(--surface-2);
    color: var(--muted);
    font-size: 13.5px;
    text-align: center;
  }

  /* contato liberado */
  .contato {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
    padding: 10px 12px;
    border: 1px solid var(--ok);
    border-radius: 9px;
    background: var(--ok-soft);
  }
  .contato .zap { display: flex; align-items: center; gap: 7px; color: var(--ok); }
  .contato .num { font-family: var(--mono); font-size: 14px; font-weight: 600; letter-spacing: .02em; }
  .contato .lab { color: var(--ok); font-size: 11.5px; font-weight: 600; letter-spacing: .06em; text-transform: uppercase; }
  .contato .row-actions { margin-left: auto; }

  /* ---------- vaga rotativa ---------- */

  .rot {
    overflow: hidden;
    border: 1px solid var(--accent-line);
    border-radius: var(--r);
    background: var(--surface);
    box-shadow: var(--shadow);
  }
  .rot .stripe {
    height: 12px;
    background: repeating-linear-gradient(135deg, var(--accent) 0 12px, transparent 12px 24px);
    opacity: .85;
  }
  .rot .bd { padding: 16px; }
  .rot h2 { margin-top: 3px; font-size: 21px; font-weight: 700; }
  .statusline { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin-top: 8px; }
  .dot { width: 9px; height: 9px; flex: none; border-radius: 50%; }
  .dot.on { background: var(--ok); }
  .dot.off { background: var(--crit); }
  .dot.mid { background: var(--warn); }

  .rules {
    display: grid;
    gap: 6px;
    margin: 14px 0 0;
    padding: 12px 12px 12px 28px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: var(--surface-2);
    font-size: 13px;
  }

  .receipt {
    display: grid;
    gap: 4px;
    padding: 12px;
    border: 1px solid var(--accent-line);
    border-radius: 8px;
    background: var(--accent-soft);
    color: var(--fg);
    font-family: var(--mono);
    font-size: 13px;
  }
  .receipt b { font-size: 15px; letter-spacing: -.01em; }

  /* calendário */
  .cal { display: grid; gap: 10px; max-width: 560px; }
  .cal-nav { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
  .cal-nav h3 { font-size: 15px; }
  .cal-grid { display: grid; grid-template-columns: repeat(7, 1fr); gap: 4px; }
  .cal-dow {
    padding-bottom: 2px;
    color: var(--muted);
    font-size: 10.5px;
    font-weight: 600;
    letter-spacing: .06em;
    text-align: center;
    text-transform: uppercase;
  }
  .day {
    display: grid;
    place-content: center;
    gap: 1px;
    aspect-ratio: 1 / 1;
    min-width: 0;
    padding: 2px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: var(--surface-2);
    color: var(--muted);
    font-variant-numeric: tabular-nums;
    text-align: center;
  }
  .day .n { font-family: var(--display); font-size: 15px; font-weight: 600; line-height: 1.1; }
  .day .s { font-size: 9px; font-weight: 500; letter-spacing: .06em; line-height: 1.1; text-transform: uppercase; }
  .day.void { border-color: transparent; background: none; }
  .day.past { border-style: dashed; }
  .day.free { border-color: transparent; background: var(--ok-soft); color: var(--ok); }
  .day.block { border-color: transparent; background: var(--crit-soft); color: var(--crit); }
  .day.taken { border-color: var(--line); background: var(--surface-3); color: var(--muted); }
  .day.mine { border-color: var(--accent-line); background: var(--accent-soft); color: var(--accent); }
  .day.today { box-shadow: inset 0 0 0 2px var(--fg); }
  button.day { cursor: pointer; font-family: var(--body); transition: transform .12s ease, filter .12s ease; }
  button.day:hover { transform: scale(1.06); filter: brightness(1.04); }

  .legend { display: flex; gap: 10px 16px; flex-wrap: wrap; align-items: center; color: var(--muted); font-size: 12px; }
  .legend span { white-space: nowrap; }
  .legend i {
    display: inline-block;
    width: 10px;
    height: 10px;
    margin-right: 5px;
    border-radius: 3px;
    vertical-align: -1px;
  }
  .legend i.free { background: var(--ok); }
  .legend i.block { background: var(--crit); }
  .legend i.taken { background: var(--muted); }
  .legend i.mine { background: var(--accent); }


  /* ---------- números do relatório ---------- */

  .numeros {
    display: grid;
    gap: 10px;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  }
  .tile {
    display: grid;
    gap: 3px;
    align-content: start;
    padding: 12px 14px;
    border: 1px solid var(--line);
    border-radius: 10px;
    background: var(--surface-2);
    min-width: 0;
  }
  .tile span {
    color: var(--muted);
    font-size: 12px;
    font-weight: 500;
  }
  .tile b {
    font-family: var(--display);
    font-size: 22px;
    font-weight: 600;
    letter-spacing: -.02em;
    font-variant-numeric: tabular-nums;
    overflow-wrap: anywhere;
  }

  /* ---------- avisos ---------- */

  .aviso-linha {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px 14px;
    flex-wrap: wrap;
  }
  .aviso-hist { display: grid; gap: 6px; }
  .aviso-hist div {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 12px;
    padding-bottom: 6px;
    border-bottom: 1px solid var(--line-soft);
    font-size: 13px;
  }
  .aviso-hist div:last-child { border-bottom: 0; padding-bottom: 0; }

  /* ---------- tabelas e avisos ---------- */

  .tscroll { overflow-x: auto; }
  table { width: 100%; border-collapse: collapse; font-size: 13.5px; }
  th, td { padding: 8px 10px; border-bottom: 1px solid var(--line); text-align: left; vertical-align: top; }
  th {
    color: var(--muted);
    font-size: 11px;
    font-weight: 600;
    letter-spacing: .1em;
    text-transform: uppercase;
    white-space: nowrap;
  }
  td.num { font-family: var(--mono); font-size: 12.5px; font-variant-numeric: tabular-nums; }
  .tscroll table { min-width: 560px; }

  .banner {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    padding: 12px 14px;
    border: 1px solid var(--line);
    border-radius: var(--r);
    background: var(--surface-2);
    font-size: 13px;
  }
  .banner.acc { border-color: var(--accent-line); background: var(--accent-soft); }
  .banner svg { flex: none; margin-top: 2px; }

  /* ---------- modal, toast, rodapé ---------- */

  .scrim {
    position: fixed;
    inset: 0;
    z-index: 40;
    display: grid;
    place-items: center;
    padding: 16px;
    background: rgba(10, 12, 15, .55);
  }
  .modal {
    width: min(480px, 100%);
    max-height: 88vh;
    overflow: auto;
    border: 1px solid var(--line);
    border-radius: 12px;
    background: var(--surface);
    box-shadow: 0 20px 60px rgba(0, 0, 0, .35);
  }
  .modal .mh { padding: 16px 16px 0; }
  .modal .mh .meta { margin-top: 2px; }
  .modal .mb { display: grid; gap: 12px; padding: 14px 16px; }
  .modal .mf { display: flex; justify-content: flex-end; gap: 8px; flex-wrap: wrap; padding: 12px 16px 16px; }

  .kv { display: grid; grid-template-columns: auto 1fr; gap: 6px 14px; margin: 0; font-size: 13.5px; }
  .kv dt { color: var(--muted); }
  .kv dd { margin: 0; text-align: right; font-variant-numeric: tabular-nums; }
  .total {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    padding-top: 10px;
    border-top: 1px solid var(--line);
  }
  .total b { font-family: var(--display); font-size: 22px; font-variant-numeric: tabular-nums; }
  .err { margin: 0; color: var(--crit); font-size: 13px; }

  #toast {
    position: fixed;
    left: 50%;
    bottom: calc(18px + env(safe-area-inset-bottom, 0px));
    z-index: 60;
    max-width: calc(100% - 32px);
    padding: 10px 16px;
    border-radius: 999px;
    background: var(--fg);
    color: var(--surface);
    font-size: 13.5px;
    font-weight: 500;
    box-shadow: 0 10px 30px rgba(0, 0, 0, .3);
    transform: translateX(-50%);
  }

  footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    flex-wrap: wrap;
    margin-top: 8px;
    padding-block: 18px 28px;
    border-top: 1px solid var(--line);
    color: var(--muted);
    font-size: 12.5px;
  }

  @media (max-width: 620px) {
    .search-row { grid-template-columns: 1fr; }
    .brand .sub, .who .un { display: none; }
    .tscroll table { min-width: 480px; }
  }

  @media (max-width: 420px) {
    .vaga .top { flex-wrap: wrap; }
    .price { text-align: left; }
    .search-foot .btn, .row-actions.wide .btn { flex: 1 1 100%; }
  }

  @media (prefers-reduced-motion: reduce) {
    * { animation: none !important; transition: none !important; }
    .vaga:hover, button.day:hover { transform: none; }
  }

  /* ---------- telas de entrada ---------- */

  .gate {
    display: grid;
    place-items: center;
    min-height: 70vh;
    padding-block: 40px;
  }
  .gate-card {
    display: grid;
    gap: 16px;
    width: min(420px, 100%);
    padding: 26px 24px;
    border: 1px solid var(--line);
    border-radius: 14px;
    background: var(--surface);
    box-shadow: var(--shadow);
    text-align: center;
  }
  .gate-card h2 { font-size: 20px; }
  .gate-card p { margin: 0; color: var(--muted); font-size: 14px; }
  .gate-card .mark { width: 46px; height: 46px; margin: 0 auto; }
  .gate-card .btn { justify-content: center; }
  .gate-card .fields { text-align: left; }

  .google {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    width: 100%;
    padding: 11px 16px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: var(--surface);
    color: var(--fg);
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
  }
  .google:hover { background: var(--surface-2); }

  .carregando {
    display: grid;
    place-items: center;
    padding: 40px;
    color: var(--muted);
    font-size: 14px;
  }
  .spin {
    width: 22px;
    height: 22px;
    margin-bottom: 10px;
    border: 2px solid var(--line);
    border-top-color: var(--accent);
    border-radius: 50%;
    animation: gira .8s linear infinite;
  }
  @keyframes gira { to { transform: rotate(360deg); } }
  @media (prefers-reduced-motion: reduce) { .spin { animation: none; } }
