@layer nearbycheck-brand {
  .device-location { display:none!important; }
  .quick-starts-heading { display:flex; align-items:center; gap:12px; min-height:44px; cursor:pointer; list-style:none; }
  .quick-starts-heading::-webkit-details-marker { display:none; }
  .quick-starts-heading strong { margin-right:auto; }
  .quick-starts-heading::after { content:'+'; font-size:20px; width:16px; text-align:center; }
  .quick-starts-block[open] > .quick-starts-heading::after { content:'−'; }
  .quick-starts-block:not([open]) > :not(summary) { display:none!important; }
  .query-action { display:grid; gap:8px; min-width:0; }
  .query-action .primary-button { margin-top:0!important; }
  .quick-starts-block { padding-top:8px!important; }
  .query-action-hint { display:none; margin:0; font-size:13px; line-height:1.45; color:var(--brand-muted); }
  .query-action-hint:empty { display:none; }
  #timeRangeSummary { overflow-wrap:anywhere; }

  @media (max-width:760px) {
    html:has(body:not(.has-query-response):not(.query-keyboard-open)), html:has(body.decision-controls-editing:not(.query-keyboard-open)) { scroll-padding-bottom:calc(var(--query-action-height, 96px) + 16px); }
    .query-action-hint:not(:empty) { display:block; }
    .field-hero-copy { display:none!important; }
    .field-control-deck { margin-top:0!important; gap:16px!important; }
    /* Legacy landing isolation must not trap the fixed action behind an
       empty/error result when reopening the editor. */
    .field-hero { padding:16px 0!important; isolation:auto!important; }
    .quick-starts-block { margin-top:12px!important; padding-top:4px!important; }
    .quick-starts-heading { margin-bottom:0!important; font-size:13px!important; }
    .quick-starts-block[open] > .quick-intents { margin-top:8px!important; }
    .location-compact .field-step-copy > p { display:none!important; }
    [data-device-summary="true"] .device-location { display:flex!important; flex-wrap:wrap; align-items:center; justify-content:space-between; gap:0 12px; }
    .device-location strong { font-size:16px; font-weight:500; }
    .device-location button { min-height:44px!important; font-size:14px!important; }
    [data-device-summary="true"] .search-field-wrap { display:none!important; }
    .location-compact .anchor-status-row { margin-top:0!important; }
    .field-fine-tune > summary { min-height:44px!important; height:auto!important; padding:10px 0!important; gap:16px; }
    .field-submit-row { padding-top:0!important; border-top:0!important; }
    /* The visible controls carry the summary; retain its live text for AT. */
    #querySummary { position:absolute!important; width:1px!important; height:1px!important; padding:0!important; margin:-1px!important; overflow:hidden!important; clip-path:inset(50%); white-space:nowrap!important; }
    body:not(.has-query-response):not(.query-keyboard-open), body.decision-controls-editing:not(.query-keyboard-open) { padding-bottom:calc(var(--query-action-height, 96px) + 16px)!important; }
    body:not(.has-query-response) .query-action, body.decision-controls-editing .query-action {
      position:fixed; inset:auto 0 0; z-index:45; padding:12px 14px calc(12px + env(safe-area-inset-bottom, 0px));
      background:var(--brand-canvas); border-top:1px solid var(--brand-line); box-shadow:none;
    }
    body.query-keyboard-open .query-action { position:static; padding:12px 0; border-top:0; }
    .query-action .primary-button { width:100%!important; min-height:48px!important; }
    body.has-query-response:not(.decision-controls-editing) .query-action { display:none!important; }
  }
}
