/* Results reference: compact candidate list and an adjacent dossier. */
html:has(body[data-active-view="results"] #view-results.is-active) { height: 100%; overflow: hidden; scrollbar-gutter: auto; background: var(--white); }
html body[data-active-view="results"] { --header-height: 64px; height: 100dvh; min-height: 0; overflow: hidden; background: var(--white); }
html body[data-active-view="results"] .app-header { height: 64px; min-height: 64px; padding: 0 var(--page-gutter); background: var(--white); border-bottom: 0; }
html body[data-active-view="results"] .app-content { display: flex; flex-direction: column; width: 100%; height: 100dvh; min-height: 0; margin: 0; padding: 64px 0 0; overflow: hidden; background: var(--white); }
html body[data-active-view="results"] .app-main { display: flex; flex: 1; width: 100%; height: auto; min-height: 0; max-height: none; margin: 0; padding: 24px var(--page-gutter) 0; overflow: hidden; background: var(--white); }
html body[data-active-view="results"] > .sidebar-footer { display: none; }
html body[data-active-view="results"] #view-results.is-active { display: flex; flex-direction: column; flex: 1; width: 100%; max-width: none; height: 100%; min-height: 0; margin: 0; gap: 16px; overflow: visible; }
/* Intestazione come Impostazioni: titolo e sintesi a sinistra, l'analisi
   scelta e le sue azioni a destra, tutte alla stessa altezza. */
html body[data-active-view="results"] #view-results .results-page-intro { display: flex; flex-direction: row; flex: none; align-items: center; justify-content: space-between; gap: 16px 24px; min-height: 42px; margin: 0; padding: 0; border: 0; }
html body[data-active-view="results"] #view-results .results-page-title { display: flex; flex-direction: column; min-width: 0; gap: 6px; }
html body[data-active-view="results"] #view-results .results-page-intro h1 { flex: none; margin: 0; color: #0b1f3a; -webkit-text-fill-color: currentColor; font: 500 28px/1.2 var(--font-display); letter-spacing: -.04em; }
html body[data-active-view="results"] #view-results .results-summary { min-width: 0; margin: 0; color: #607596; font: 400 14px/1.5 var(--font-sans); }
html body[data-active-view="results"] #view-results .results-header-actions { display: flex; flex: 0 1 auto; align-items: center; justify-content: flex-end; gap: 10px; min-width: 0; margin-left: auto; }
html body[data-active-view="results"] #view-results .results-run-bar { display: flex; flex: 0 1 auto; align-items: center; gap: 6px; min-width: 0; }
html body[data-active-view="results"] #view-results .results-icon-button { width: 42px; min-width: 42px; height: 42px; min-height: 42px; padding: 0; color: #52647f; }
html body[data-active-view="results"] #view-results .results-icon-button:hover:not(:disabled) { color: #0b1f3a; }
html body[data-active-view="results"] #view-results #run-delete:hover:not(:disabled) { color: #a0443a; background: #fff5f3; border-color: #efcdc7; }
html body[data-active-view="results"] #view-results #refresh-runs.is-busy .ui-icon { animation: results-spin .8s linear infinite; }
@keyframes results-spin { to { transform: rotate(360deg); } }
/* Qualifica tutte le attivita': l'azione principale dei risultati, piena e verde. */
html body[data-active-view="results"] #view-results #client-qualify { display: inline-flex; align-items: center; justify-content: center; height: 42px; min-height: 42px; padding: 0 18px; color: #fff; background: #488868; border: 1px solid #488868; border-radius: 12px; font: 600 13px/1 var(--font-sans); white-space: nowrap; cursor: pointer; box-shadow: 0 1px 2px #0b1f3a14; transition: background .15s, border-color .15s; }
html body[data-active-view="results"] #view-results #client-qualify:hover:not(:disabled) { background: #3a7157; border-color: #3a7157; }
html body[data-active-view="results"] #view-results #client-qualify:focus-visible { outline: 3px solid #a5dec2; outline-offset: 2px; }
html body[data-active-view="results"] #view-results #client-qualify:disabled { opacity: .55; cursor: not-allowed; }
html body[data-active-view="results"] #view-results #client-qualify.is-hidden { display: none !important; }
html body[data-active-view="results"] #view-results .run-picker { flex: 0 1 300px; min-width: 180px; width: 300px; margin: 0; }
html body[data-active-view="results"] #view-results .run-picker-control { display: block; width: 100%; }
html body[data-active-view="results"] #view-results .results-control-with-icon { position: relative; display: flex; align-items: center; width: 100%; min-width: 0; }
html body[data-active-view="results"] #view-results .run-picker .site-select { width: 100%; min-width: 0; }
html body[data-active-view="results"] #view-results .run-picker .site-select-trigger { height: 42px; min-height: 42px; padding: 0 12px 0 38px; color: #0b1f3a; background: #fff; border: 1px solid #dce2ec; border-radius: 12px; font-size: 13px; box-shadow: none; }
html body[data-active-view="results"] #view-results .run-picker .results-control-with-icon > .ui-icon { position: absolute; z-index: 1; left: 14px; width: 15px; height: 15px; color: #4a986c; pointer-events: none; }
html body[data-active-view="results"] #view-results .run-picker .site-select-menu { z-index: 80; min-width: min(360px, 85vw); max-width: 85vw; }
html body[data-active-view="results"] #view-results .button { display: inline-flex; align-items: center; justify-content: center; flex: none; gap: 9px; width: auto; height: auto; min-height: 42px; margin: 0; padding: 10px 16px; color: #0b1f3a; background: #fff; border: 1px solid #dce2ec; border-radius: 12px; box-shadow: none; font: 500 13px/1.4 var(--font-sans); text-decoration: none; white-space: normal; }
html body[data-active-view="results"] #view-results .button > .ui-icon { flex: none; width: 15px; height: 15px; padding: 0; color: currentColor; background: none; border: 0; border-radius: 0; }
html body[data-active-view="results"] #view-results .button:hover:not(:disabled) { background: #f5f7fa; transform: none; }
html body[data-active-view="results"] #view-results .button:disabled { opacity: .48; cursor: not-allowed; }
html body[data-active-view="results"] #view-results .workspace-new-analysis.button { min-height: 42px; padding: 11px 17px; color: white; background: #152039; border: 1px solid #152039; font-weight: 600; }
html body[data-active-view="results"] #view-results .workspace-new-analysis > .ui-icon,
html body[data-active-view="results"] #view-results .export-menu-caret { display: none; }
html body[data-active-view="results"] #view-results .export-menu { position: relative; }
html body[data-active-view="results"] #view-results .export-menu-panel { z-index: 90; min-width: 240px; }
/* CSV: una voce per parte, col numero di righe che escono. */
html body #view-results .export-menu-heading { margin: 4px 10px 4px; color: #8290a6; font-size: 10px; font-weight: 400; letter-spacing: .08em; line-height: 1.5; text-transform: uppercase; }
html body #view-results .export-csv-options { display: grid; }
html body #view-results .export-csv-option { justify-content: space-between; gap: 16px; }
html body #view-results .export-csv-option b { min-width: 22px; padding: 1px 7px; color: #607596; background: #eef1f5; border-radius: 999px; font-size: 11px; font-weight: 600; line-height: 1.5; text-align: center; }
html body #view-results .export-csv-option:hover:not(:disabled) b { color: #2b6b49; background: #eaf6f1; }
html body #view-results .export-menu-separator { height: 1px; margin: 6px 4px; background: #eef1f5; border: 0; }
html body[data-active-view="results"] #view-results .result-metrics,
html body[data-active-view="results"] #view-results .result-panel .table-heading { display: none !important; }

/* Due card gemelle, stesso bordo e stessa ombra delle card di Impostazioni:
   a sinistra l'elenco con i suoi strumenti, a destra la scheda. Entrambe
   arrivano in fondo alla pagina e scorrono all'interno: alte quanto il
   contenuto lasciavano mezzo schermo bianco sotto. */
html body[data-active-view="results"] #view-results .results-workbench { display: grid; grid-template-columns: minmax(320px, .62fr) minmax(0, 1fr); grid-template-rows: minmax(0, 1fr); flex: 1; align-items: stretch; min-height: 0; gap: 20px; padding-bottom: 24px; }
html body[data-active-view="results"] #view-results .results-browser { display: flex; flex-direction: column; align-self: stretch; min-width: 0; min-height: 0; gap: 14px; padding: 18px 18px 14px; background: #fff; border: 1px solid #e9edf2; border-radius: 16px; box-shadow: 0 14px 34px rgba(20, 38, 64, .05), 0 2px 3px rgba(20, 38, 64, .025); }
html body[data-active-view="results"] #view-results .results-toolbar { flex: none; margin: 0; padding: 0; border: 0; background: none; }
html body[data-active-view="results"] #view-results .results-search-row { display: grid; grid-template-columns: minmax(0, 1fr) auto auto; gap: 8px; }
/* «Salvati» accanto a «Filtri», stessa forma: acceso mostra solo i salvati. */
html body[data-active-view="results"] #view-results .results-saved-toggle { display: inline-flex; align-items: center; justify-content: center; gap: 7px; height: 42px; padding: 9px 12px; color: #4d8867; background: #fff; border: 1px solid #a5dec2; border-radius: 12px; font: 500 13px/1.4 var(--font-sans); cursor: pointer; }
html body[data-active-view="results"] #view-results .results-saved-toggle .ui-icon { width: 15px; height: 15px; }
html body[data-active-view="results"] #view-results .results-saved-toggle b { min-width: 20px; padding: 1px 6px; color: #2b6b49; background: #eaf6f1; border-radius: 999px; font-size: 11px; font-weight: 600; line-height: 1.5; }
html body[data-active-view="results"] #view-results .results-saved-toggle:hover:not(:disabled) { background: #f4faf6; }
html body[data-active-view="results"] #view-results .results-saved-toggle.is-active { color: #fff; background: #488868; border-color: #488868; }
html body[data-active-view="results"] #view-results .results-saved-toggle.is-active:hover { background: #367351; }
html body[data-active-view="results"] #view-results .results-saved-toggle.is-active .ui-icon { fill: currentColor; }
html body[data-active-view="results"] #view-results .results-saved-toggle.is-active b { color: #488868; background: #fff; }
html body[data-active-view="results"] #view-results .results-saved-toggle:disabled { color: #9aa6b8; border-color: #e1e6ee; cursor: default; }
html body[data-active-view="results"] #view-results .results-saved-toggle:disabled b { color: #9aa6b8; background: #f0f3f7; }
@media (max-width: 420px) {
  html body[data-active-view="results"] #view-results .results-saved-toggle strong { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
}
html body[data-active-view="results"] #view-results .search-field { width: auto; min-width: 0; margin: 0; }
html body[data-active-view="results"] #view-results .search-field .results-control-with-icon > .ui-icon { position: absolute; z-index: 1; left: 15px; width: 16px; height: 16px; color: #8693a8; }
html body[data-active-view="results"] #view-results #hotel-search { width: 100%; height: 42px; min-height: 42px; padding: 10px 14px 10px 40px; color: #0b1f3a; background: white; border: 1px solid #e1e6ee; border-radius: 12px; box-shadow: none; font-size: 14px; }
html body[data-active-view="results"] #view-results #hotel-search::placeholder { color: #8b96a8; }
html body[data-active-view="results"] #view-results #result-filters { position: relative; display: block !important; width: auto; margin: 0; padding: 0; border: 0; }
html body[data-active-view="results"] #view-results #result-filters > summary { display: flex; align-items: center; justify-content: center; min-width: 78px; height: 42px; min-height: 42px; gap: 8px; padding: 9px 14px; color: #4d8867; background: white; border: 1px solid #a5dec2; border-radius: 12px; list-style: none; cursor: pointer; }
html body[data-active-view="results"] #view-results #result-filters > summary::-webkit-details-marker { display: none; }
html body[data-active-view="results"] #view-results #result-filters > summary::after { display: none; }
html body[data-active-view="results"] #view-results #result-filters > summary strong { font: 500 13px/1.4 var(--font-sans); }
html body[data-active-view="results"] #view-results #result-filters > summary .ui-icon { width: 15px; height: 15px; }
html body[data-active-view="results"] #view-results .result-filter-panel { position: absolute; z-index: 70; top: calc(100% + 8px); right: 0; left: auto; display: flex; flex-direction: column; width: min(340px, calc(100vw - 40px)); max-height: calc(100dvh - 190px); margin: 0; padding: 20px 20px 14px; gap: 0; overflow: auto; color: #0b1f3a; background: #fff; border: 1px solid #e1e6ee; border-radius: 16px; box-shadow: 0 12px 36px #0b1f3a18; }
html body[data-active-view="results"] #view-results .result-filter-panel .field { margin: 0 0 18px; }
html body[data-active-view="results"] #view-results .result-filter-panel label { font-size: 13px; line-height: 1.5; }
html body[data-active-view="results"] #view-results .result-filter-panel .field :is(select, .site-select-trigger) { width: 100%; height: auto; min-height: 44px; border-radius: 10px; padding: 10px 12px; }

/* Il conteggio della run e' figlio degli strumenti clienti perche' `is-hidden`
   lo spenga insieme a loro, ma a video va in fondo, sotto le due spunte:
   il contenitore sparisce con display:contents e l'ordine si decide qui. */
html body[data-active-view="results"] #view-results .client-results-tools { display: contents; }

html body[data-active-view="results"] #view-results .client-results-tools > .field { order: 2; margin: 0 0 14px; }
html body[data-active-view="results"] #view-results .client-check-label { order: 3; }
html body[data-active-view="results"] #view-results .results-saved-filter { order: 4; }
html body[data-active-view="results"] #view-results #client-run-metrics { order: 5; }
html body[data-active-view="results"] #view-results .client-results-tools > .field label { display: block; margin-bottom: 7px; color: #52647f; font: 500 12px/1.4 var(--font-sans); }
html body[data-active-view="results"] #view-results .client-results-tools .site-select-trigger { min-height: 44px; padding: 10px 12px; border-color: #dce2ec; border-radius: 10px; }
/* Le due spunte sono un gruppo solo, staccato dalle tendine da una riga
   sottile: la casella e' centrata sul testo, non sopra di esso. */
html body[data-active-view="results"] #view-results :is(.client-check-label, .results-saved-filter) { display: flex; flex-direction: row; align-items: center; justify-content: flex-start; text-align: left; gap: 10px; min-height: 38px; margin: 0; padding: 0; color: #0b1f3a; font: 400 13px/1.5 var(--font-sans); cursor: pointer; }
html body[data-active-view="results"] #view-results .client-check-label { margin-top: 0; padding-top: 14px; border-top: 1px solid #eef1f5; }
html body[data-active-view="results"] #view-results :is(.client-check-label, .results-saved-filter):hover { color: #2b6b49; }
html body[data-active-view="results"] #view-results :is(.client-check-label, .results-saved-filter) input { flex: none; width: 17px; height: 17px; margin: 0; accent-color: #488868; cursor: pointer; }
html body[data-active-view="results"] #view-results :is(.client-check-label, .results-saved-filter) span { min-width: 0; }
/* clienti.css gli da' flex-basis:100%: in una colonna flex diventa un'altezza
   e sotto «Solo salvati» restava un vuoto. Vuoto, il paragrafo non occupa niente. */
html body[data-active-view="results"] #view-results #client-run-metrics { flex: none; margin: 10px 0 0; padding-top: 10px; color: #8693a8; font: 400 12px/1.5 var(--font-sans); border-top: 1px solid #eef1f5; }
html body[data-active-view="results"] #view-results #client-run-metrics:empty { display: none; }

html body[data-active-view="results"] #view-results .results-sections { display: flex !important; flex: none; gap: 4px; width: 100%; margin: 0; padding: 4px; overflow: visible; border: 0; background: #f3f5f8; border-radius: 12px; }
html body[data-active-view="results"] #view-results .results-section-tab { display: inline-flex; flex: 1 1 0; align-items: center; justify-content: center; min-width: 0; min-height: 34px; gap: 6px; padding: 7px 10px; color: #596b87; background: transparent; border: 1px solid transparent; border-radius: 9px; font: 500 12px/1.3 var(--font-sans); text-align: center; white-space: normal; box-shadow: none; cursor: pointer; }
html body[data-active-view="results"] #view-results .results-section-tab:hover:not(.is-active) { color: #0b1f3a; }
html body[data-active-view="results"] #view-results .results-section-tab.is-active { color: #0b1f3a; background: #fff; border-color: #e1e6ee; font-weight: 600; box-shadow: 0 1px 2px rgba(11, 31, 58, .08); }
html body[data-active-view="results"] #view-results .results-section-tab b { min-width: 20px; height: auto; margin: 0; padding: 1px 6px; color: #607596; background: #e7ebf1; border-radius: 999px; font-size: 11px; font-weight: 600; font-variant-numeric: tabular-nums; }
html body[data-active-view="results"] #view-results .results-section-tab.is-active b { color: #2b6b49; background: #eaf6f1; }
html body[data-active-view="results"] #view-results .result-panel { display: flex; flex-direction: column; flex: 1; width: 100%; min-height: 0; margin: 0; padding: 0; overflow: visible; border: 0; border-radius: 0; background: none; box-shadow: none; }
/* La lista arriva ai bordi della card: le righe hanno lo stesso rientro degli strumenti sopra. */
html body[data-active-view="results"] #view-results #results-table-wrap { display: block; flex: 1 1 auto; min-height: 0; margin: 0 -18px; padding: 0; overflow: auto; overscroll-behavior: contain; scrollbar-width: thin; scrollbar-color: #dce3e9 transparent; border: 0; border-top: 1px solid #eef1f5; }
html body[data-active-view="results"] #view-results .result-candidate-list { display: flex; flex-direction: column; margin: 0; padding: 0; list-style: none; background: none; border: 0; border-radius: 0; }
html body[data-active-view="results"] #view-results .result-candidate-list li { margin: 0; padding: 0; }
html body[data-active-view="results"] #view-results .result-candidate-list li + li { border-top: 1px solid #eef1f5; }
/* Una lista sola, non una pila di card: la selezione e' una barra a sinistra
   e un fondo appena tinto, non un bordo sottile che si confondeva con gli altri. */
html body[data-active-view="results"] #view-results .result-candidate { position: relative; display: flex; align-items: center; width: 100%; min-height: 60px; gap: 12px; padding: 10px 18px; text-align: left; color: #0b1f3a; background: transparent; border: 0; border-radius: 0; cursor: pointer; transition: background 140ms ease; }
html body[data-active-view="results"] #view-results .result-candidate:hover { background: #f7faf8; }
html body[data-active-view="results"] #view-results .result-candidate.is-selected { background: #f0f8f3; }
html body[data-active-view="results"] #view-results .result-candidate.is-selected::before { position: absolute; top: 0; bottom: 0; left: 0; width: 3px; background: #4b936a; content: ""; }
html body[data-active-view="results"] #view-results .result-candidate-score.is-rank { width: 28px; height: 28px; color: #5a6a7e; background: none; border-radius: 0; font: 600 13px/1 var(--font-sans); font-variant-numeric: tabular-nums; }
html body[data-active-view="results"] #view-results .result-candidate.is-selected .result-candidate-score.is-rank { color: #2b6b49; }
html body[data-active-view="results"] #view-results .result-candidate-distance { flex: none; min-width: 52px; color: #3d4c63; font: 500 13px/1 var(--font-sans); font-variant-numeric: tabular-nums; text-align: right; }
html body[data-active-view="results"] #view-results .result-candidate-saved { flex: none; color: #488868; }
html body[data-active-view="results"] #view-results .result-candidate-saved .ui-icon { width: 15px; height: 15px; }
html body[data-active-view="results"] #view-results .result-candidate-score { display: grid; place-items: center; flex: none; width: 36px; height: 36px; color: #162844; background: #f0f3f7; border-radius: 10px; font: 600 16px/1 var(--font-display); }
html body[data-active-view="results"] #view-results .result-candidate-score.is-positive { color: #2b7275; background: #eaf6f1; }
html body[data-active-view="results"] #view-results .result-candidate-score.is-review { color: #947035; background: #faf4e9; }
html body[data-active-view="results"] #view-results .result-candidate-score .ui-icon { width: 17px; height: 17px; }
html body[data-active-view="results"] #view-results .result-candidate-copy { display: flex; flex: 1; flex-direction: column; min-width: 0; gap: 2px; }
html body[data-active-view="results"] #view-results .result-candidate-copy strong { overflow: hidden; color: #0b1f3a; font: 600 14px/1.4 var(--font-sans); text-overflow: ellipsis; white-space: nowrap; }
html body[data-active-view="results"] #view-results .result-candidate-copy small { overflow: hidden; color: #8a96a8; font: 400 12px/1.4 var(--font-sans); text-overflow: ellipsis; white-space: nowrap; }
html body[data-active-view="results"] #view-results .result-load-more { flex: none; margin: 0 -18px; padding: 12px 0 0; text-align: center; border: 0; border-top: 1px solid #eef1f5; }
html body[data-active-view="results"] #view-results .result-load-more-button { min-height: 40px; padding: 9px 18px; color: #52647f; background: transparent; border: 1px solid #dce2ec; border-radius: 999px; font-size: 12px; }
html body[data-active-view="results"] #view-results .result-load-more-button .ui-icon { display: none; }
html body[data-active-view="results"] #view-results .empty-results { min-height: 200px; padding: 36px 24px; background: #f8fafb; border: 0; border-radius: 12px; }
html body[data-active-view="results"] #view-results .empty-results h3 { margin: 0 0 6px; color: #0b1f3a; font: 500 19px/1.3 var(--font-display); letter-spacing: -.02em; }
html body[data-active-view="results"] #view-results .empty-results p { margin: 0; color: #607596; font-size: 13px; line-height: 1.6; }

/* La scheda arriva in fondo come l'elenco. I contatti stanno subito sotto
   l'intestazione, non in un piede in fondo: cosi' lo spazio libero resta
   sotto il contenuto e non fra i dati e il telefono. Scorre solo il corpo. */
html body[data-active-view="results"] #view-results .result-detail { display: flex; flex-direction: column; align-self: stretch; min-width: 0; min-height: 0; overflow: hidden; color: #0b1f3a; background: #fff; border: 1px solid #e9edf2; border-radius: 16px; box-shadow: 0 14px 34px rgba(20, 38, 64, .05), 0 2px 3px rgba(20, 38, 64, .025); }
html body[data-active-view="results"] #view-results .result-detail-header { display: grid; grid-template-columns: minmax(0, 1fr) auto; flex: none; align-items: center; gap: 0 14px; padding: 26px 30px 0; }
html body[data-active-view="results"] #view-results .result-detail-kicker { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; min-width: 0; color: #8995a9; font-size: 12px; line-height: 1.5; }
html body[data-active-view="results"] #view-results .result-detail-badge { display: inline-block; padding: 5px 9px; color: #52647f; background: #f0f3f7; border-radius: 6px; font-size: 10px; font-weight: 600; letter-spacing: .06em; text-transform: uppercase; }
html body[data-active-view="results"] #view-results .result-detail-badge.is-positive { color: #287378; background: #eaf6f1; }
html body[data-active-view="results"] #view-results .result-detail-badge.is-review { color: #916415; background: #faf2e2; }
html body[data-active-view="results"] #view-results .result-detail-actions { display: flex; align-items: center; gap: 10px; }
html body[data-active-view="results"] #view-results .result-contact.button { min-width: 112px; color: white; background: #488868; border-color: #488868; font-weight: 600; }
html body[data-active-view="results"] #view-results .result-contact.button:hover { color: white; background: #367351; }
html body[data-active-view="results"] #view-results .result-save.is-saved { color: #397750; background: #eaf6f1; border-color: #afd4be; }
/* «Chiamalo»: la scelta a mano fra i da rivedere e gli esclusi. */
html body[data-active-view="results"] #view-results .result-detail-actions { flex-wrap: wrap; }
html body[data-active-view="results"] #view-results .result-call.button { color: #6e4a0b; background: #fdf3d6; border-color: #f1dc9f; }
html body[data-active-view="results"] #view-results .result-call.button:hover { background: #fbebbd; }
html body[data-active-view="results"] #view-results .result-call.button.is-active { color: #397750; background: #eaf6f1; border-color: #afd4be; }
/* «Verificato»: il passo dopo la telefonata. Verde pieno quando e' fatto. */
html body[data-active-view="results"] #view-results .result-verify.button { color: #397750; background: #fff; border-color: #afd4be; }
html body[data-active-view="results"] #view-results .result-verify.button:hover { background: #eaf6f1; }
html body[data-active-view="results"] #view-results .result-verify.button.is-active { color: #fff; background: #488868; border-color: #488868; }
html body[data-active-view="results"] #view-results #result-detail-title { grid-column: 1 / -1; margin: 0 0 6px; padding: 0; color: #0b1f3a; font: 500 26px/1.15 var(--font-display); letter-spacing: -.035em; overflow-wrap: anywhere; }
html body[data-active-view="results"] #view-results .result-detail-address { grid-column: 1 / -1; margin: 0; color: #627799; font-size: 13px; line-height: 1.65; overflow-wrap: anywhere; }
html body[data-active-view="results"] #view-results .result-detail-address a { color: #32868b; text-decoration: none; }
html body[data-active-view="results"] #view-results .result-detail-body { flex: 1 1 auto; min-height: 0; padding: 20px 30px 22px; overflow: auto; overscroll-behavior: contain; scrollbar-width: thin; scrollbar-color: #dce3e9 transparent; }

html body[data-active-view="results"] #view-results .result-evidence-verdict { margin: 0 0 6px; color: #4a5c74; font-size: 12px; line-height: 1.5; }
html body[data-active-view="results"] #view-results .result-evidence-verdict strong { color: #0b1f3a; font-weight: 500; }
html body[data-active-view="results"] #view-results .result-evidence.is-against { background: #fbf5f4; border-left-color: #c08b84; }
html body[data-active-view="results"] #view-results .result-admission-section { margin-top: 22px; }
html body[data-active-view="results"] #view-results .result-admission-list { margin: 0; padding: 0; list-style: none; }
html body[data-active-view="results"] #view-results .result-admission { display: flex; align-items: flex-start; gap: 10px; padding: 10px 0; border-top: 1px solid #eef1f5; }
html body[data-active-view="results"] #view-results .result-admission:first-child { border-top: 0; }
html body[data-active-view="results"] #view-results .result-admission > .result-admission-icon { flex: none; margin-top: 1px; color: #5b9d70; }
html body[data-active-view="results"] #view-results .result-admission.is-unknown > .result-admission-icon, html body[data-active-view="results"] #view-results .result-admission.is-contradicted > .result-admission-icon { color: #b58234; }
html body[data-active-view="results"] #view-results .result-admission-icon .ui-icon { width: 16px; height: 16px; }
html body[data-active-view="results"] #view-results .result-admission-copy { display: flex; flex-direction: column; gap: 3px; min-width: 0; color: #607087; font-size: 13px; line-height: 1.6; overflow-wrap: anywhere; }
html body[data-active-view="results"] #view-results .result-admission-head { display: flex; align-items: baseline; flex-wrap: wrap; gap: 8px; }
html body[data-active-view="results"] #view-results .result-admission-head strong { color: #0b1f3a; font-size: 13px; font-weight: 500; }
html body[data-active-view="results"] #view-results .result-admission-head em { color: #5b9d70; font-size: 11px; font-style: normal; letter-spacing: .04em; text-transform: uppercase; }
html body[data-active-view="results"] #view-results .result-admission.is-unknown .result-admission-head em, html body[data-active-view="results"] #view-results .result-admission.is-contradicted .result-admission-head em { color: #b58234; }
html body[data-active-view="results"] #view-results .result-admission a { color: #758792; font-size: 12px; text-underline-offset: 3px; }
html body[data-active-view="results"] #view-results .result-facts { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; margin: 0 0 18px; padding: 0; }
html body[data-active-view="results"] #view-results .result-facts > div { min-width: 0; padding: 12px 16px; background: #f6f8fa; border-radius: 13px; }
html body[data-active-view="results"] #view-results .result-facts dt { margin: 0 0 6px; color: #8290a6; font-size: 10px; font-weight: 400; letter-spacing: .08em; line-height: 1.5; text-transform: uppercase; }
html body[data-active-view="results"] #view-results .result-facts dd { margin: 0; color: #27666c; font-size: 13px; font-weight: 500; line-height: 1.5; overflow-wrap: anywhere; }
html body[data-active-view="results"] #view-results .result-facts > div:last-child dd { color: #0b1f3a; }
html body[data-active-view="results"] #view-results .result-evidence-section h3,
html body[data-active-view="results"] #view-results .result-callout h3 { margin: 0 0 9px; color: #0b1f3a; font: 500 14px/1.5 var(--font-sans); letter-spacing: 0; }
html body[data-active-view="results"] #view-results .result-synthesis,
html body[data-active-view="results"] #view-results .result-evidence-empty { margin: 0 0 14px; color: #607087; font-size: 14px; line-height: 1.65; }
/* Sintesi AI: stesso linguaggio delle altre sezioni della scheda. Sezione
   piatta come «Dal sito», etichette maiuscole piccole come i dt, la domanda
   come una citazione (bordo verde a sinistra), fonti come i tag. */
html body #view-results .result-narrative { margin: 4px 0 20px; padding: 0 0 20px; border-bottom: 1px solid #e6ebef; }
html body #view-results .result-narrative-heading { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 10px; margin: 0 0 12px; }
html body[data-active-view="results"] #view-results .result-narrative-heading h3 { margin: 0; color: #0b1f3a; font: 500 14px/1.5 var(--font-sans); letter-spacing: 0; }
html body #view-results .result-ai-label { display: inline-block; padding: 3px 8px; color: #287378; background: #eaf6f1; border-radius: 6px; font-size: 10px; font-weight: 600; letter-spacing: .06em; line-height: 1.5; text-transform: uppercase; white-space: nowrap; }
html body #view-results .result-narrative.is-empty .result-ai-label { color: #52647f; background: #f0f3f7; }
html body #view-results .result-narrative-question { margin: 0 0 16px; padding: 14px 18px; background: #f4faf6; border: 0; border-left: 3px solid #5b9d70; border-radius: 0 12px 12px 0; }
html body #view-results .result-narrative-question h4 { margin: 0 0 6px; color: #8290a6; font-size: 10px; font-weight: 400; letter-spacing: .08em; line-height: 1.5; text-transform: uppercase; }
html body #view-results .result-narrative-question p { margin: 0; color: #23446c; font-size: 14px; line-height: 1.55; overflow-wrap: anywhere; }
html body #view-results .result-narrative-text p { margin: 0 0 12px; color: #0b1f3a; font-size: 14px; line-height: 1.65; overflow-wrap: anywhere; }
html body #view-results .result-narrative-text p:last-child { margin-bottom: 0; }
html body #view-results .result-narrative-refs { display: inline-flex; gap: 4px; margin-left: 6px; vertical-align: 1px; white-space: nowrap; }
html body #view-results .result-narrative .result-ref { display: inline-grid; place-items: center; min-width: 18px; height: 18px; padding: 0 5px; color: #27666c; background: #eef6f2; border-radius: 999px; font-size: 11px; font-weight: 500; line-height: 1; text-decoration: none; }
html body #view-results .result-narrative .result-ref:hover { background: #dcefe5; }
html body #view-results .result-narrative-footer { margin-top: 16px; }
html body #view-results .result-narrative-sources { display: grid; grid-template-columns: max-content minmax(0, 1fr); gap: 16px; align-items: baseline; margin: 0 0 10px; }
html body #view-results .result-narrative-sources > div { display: flex; flex-wrap: wrap; gap: 6px; min-width: 0; }
html body #view-results .result-narrative-sources > span { color: #8290a6; font-size: 10px; letter-spacing: .08em; line-height: 1.5; text-transform: uppercase; }
html body #view-results .result-narrative-sources a { display: inline-flex; align-items: center; gap: 6px; max-width: 100%; padding: 4px 10px 4px 5px; color: #27666c; background: #eef6f2; border-radius: 999px; font-size: 12px; line-height: 1.5; text-decoration: none; overflow-wrap: anywhere; }
html body #view-results .result-narrative-sources a:hover { text-decoration: underline; }
html body #view-results .result-narrative-sources a b { display: inline-grid; place-items: center; min-width: 18px; height: 18px; color: #27666c; background: #fff; border-radius: 999px; font-size: 11px; font-weight: 500; }
html body #view-results .result-narrative-note { margin: 0; color: #8895a8; font-size: 12px; line-height: 1.5; }
html body #view-results .result-proof-details { margin-bottom: 20px; border-bottom: 1px solid #e6ebef; }
html body #view-results .result-proof-details > summary { padding: 0 0 16px; cursor: pointer; color: #4a6179; font-size: 13px; font-weight: 500; }
html body #view-results .result-proof-details > summary:focus-visible { outline: 2px solid #458866; outline-offset: 3px; }
@media (max-width: 600px) {
  html body #view-results .result-narrative-sources { grid-template-columns: 1fr; gap: 6px; }
}
html body[data-active-view="results"] #view-results .result-evidence { margin: 0 0 12px; padding: 14px 18px; background: #f6f8fa; border-left: 3px solid #ccd5e1; border-radius: 0 12px 12px 0; }
html body[data-active-view="results"] #view-results .result-evidence.is-site { background: #f4faf6; border-left-color: #5b9d70; }
html body[data-active-view="results"] #view-results .result-evidence blockquote { margin: 0; padding: 0; color: #23446c; border: 0; font: 400 14px/1.55 var(--font-sans); overflow-wrap: anywhere; }
html body[data-active-view="results"] #view-results .result-evidence figcaption { margin-top: 6px; color: #8895a8; font-size: 12px; line-height: 1.5; overflow-wrap: anywhere; }
html body[data-active-view="results"] #view-results .result-evidence figcaption a { color: #758792; text-underline-offset: 3px; }
html body[data-active-view="results"] #view-results .result-callout { display: flex; align-items: flex-start; gap: 12px; margin: 18px 0 12px; padding: 14px 16px; color: #5f4b1e; background: #fdf8ec; border: 1px solid #f1e2bd; border-left: 3px solid #d9a441; border-radius: 13px; }
html body[data-active-view="results"] #view-results .result-callout > .ui-icon { flex: none; width: 18px; height: 18px; margin-top: 1px; color: #c48a1c; stroke-width: 2; }
html body[data-active-view="results"] #view-results .result-callout > div { min-width: 0; }
html body[data-active-view="results"] #view-results .result-callout h3 { margin: 0 0 3px; color: #6e4a0b; font: 600 13px/1.4 var(--font-sans); letter-spacing: 0; }
html body[data-active-view="results"] #view-results .result-callout p { margin: 0; max-width: 72ch; color: #6b5a33; font-size: 13px; line-height: 1.55; overflow-wrap: anywhere; }
html body[data-active-view="results"] #view-results .result-personal-note { padding: 12px; color: #68768b; font-size: 12px; line-height: 1.6; }
html body[data-active-view="results"] #view-results .result-analyze { margin-top: 16px; }
/* Recapiti: una riga di chip, come i tag del sito. */
html body[data-active-view="results"] #view-results .result-detail-footer { flex: none; margin: 16px 30px 0; padding: 0 0 16px; border-bottom: 1px solid #e9edf2; }
html body[data-active-view="results"] #view-results .result-contact-links { display: flex; align-items: center; flex-wrap: wrap; gap: 6px; min-width: 0; color: #8a96a8; font-size: 12px; }
html body[data-active-view="results"] #view-results .result-contact-links > span { padding: 6px 0; }
html body[data-active-view="results"] #view-results .result-contact-links a { display: inline-flex; align-items: center; gap: 6px; min-height: 32px; max-width: 100%; padding: 5px 12px 5px 10px; color: #284971; background: #f6f8fa; border-radius: 999px; font-size: 12.5px; line-height: 1.4; text-decoration: none; overflow-wrap: anywhere; }
html body[data-active-view="results"] #view-results .result-contact-links a:hover { color: #27666c; background: #eef6f2; }
html body[data-active-view="results"] #view-results .result-contact-links .ui-icon { flex: none; width: 14px; height: 14px; color: #8492a8; }
html body[data-active-view="results"] #view-results .result-contact-links a:hover .ui-icon { color: #5b9d70; }
/* Da chiedere in chiamata: in giallo, come i callout, perche' a colpo
   d'occhio si veda cosa manca e va chiesto al telefono. */
html body[data-active-view="results"] #view-results .result-ask { margin: 0 0 20px; }
html body[data-active-view="results"] #view-results .result-ask ul { display: flex; flex-direction: column; align-items: flex-start; gap: 6px; margin: 0; padding: 0; list-style: none; }
html body[data-active-view="results"] #view-results .result-ask li { position: relative; max-width: 100%; margin: 0; padding: 5px 12px 5px 26px; color: #6e4a0b; background: #fdf3d6; border: 1px solid #f1dc9f; border-radius: 9px; font-size: 13.5px; font-weight: 500; line-height: 1.5; overflow-wrap: anywhere; }
html body[data-active-view="results"] #view-results .result-ask li::before { content: ""; position: absolute; top: calc(5px + .75em - 3px); left: 11px; width: 7px; height: 7px; background: #d9a441; border-radius: 50%; }
/* «Non adatto»: scelta personale, in fondo e senza peso visivo. */
html body[data-active-view="results"] #view-results .result-detail-end { margin-top: 18px; padding-top: 14px; border-top: 1px solid #eef1f5; }
html body[data-active-view="results"] #view-results .result-detail-end .result-personal-note { margin: 0 0 6px; padding: 0; }
html body[data-active-view="results"] #view-results .result-dismiss { min-height: 32px; padding: 4px 0; color: #8290a6; background: none; border: 0; font: 400 12px/1.5 var(--font-sans); text-decoration: underline; text-decoration-color: #d5dbe4; text-underline-offset: 3px; cursor: pointer; }
html body[data-active-view="results"] #view-results .result-dismiss:hover:not(:disabled) { color: #52647f; }
html body[data-active-view="results"] #view-results .result-dismiss:disabled { cursor: default; opacity: .6; }
html body[data-active-view="results"] #view-results .result-detail-empty { display: flex; flex: 1; flex-direction: column; align-items: center; justify-content: center; min-height: 360px; padding: 32px; text-align: center; }
html body[data-active-view="results"] #view-results .result-detail-empty #result-detail-title { margin-top: 18px; font-size: 26px; }
html body[data-active-view="results"] #view-results .result-detail-empty p { max-width: 340px; color: #8490a3; font-size: 14px; line-height: 1.7; }
html body[data-active-view="results"] #view-results .result-detail-symbol { display: grid; place-items: center; width: 56px; height: 56px; color: #5c9076; background: #edf7f1; border-radius: 16px; }
html body[data-active-view="results"] #view-results .result-detail-symbol .ui-icon { width: 24px; height: 24px; }
html body[data-active-view="results"] #view-results .result-detail-back { display: none; }
html body[data-active-view="results"] #view-results :is(button, summary, a, input, select):focus-visible { outline: 2px solid #448863; outline-offset: 3px; }
html body[data-active-view="results"] #view-results .result-candidate:focus-visible { outline-offset: -4px; }

@media (max-width: 1100px) {
  html body[data-active-view="results"] .app-main { padding: 20px 24px 0; }
  html body[data-active-view="results"] #view-results .results-page-intro { flex-wrap: wrap; gap: 12px; }
  html body[data-active-view="results"] #view-results .results-header-actions { flex: 1 1 100%; justify-content: flex-start; margin-left: 0; }
  html body[data-active-view="results"] #view-results .results-run-bar { flex: 1 1 auto; }
  html body[data-active-view="results"] #view-results .run-picker { flex: 1 1 auto; width: auto; max-width: 420px; }
  html body[data-active-view="results"] #view-results .result-detail-header { padding: 22px 22px 0; }
  html body[data-active-view="results"] #view-results .result-detail-body { padding: 18px 22px; }
  html body[data-active-view="results"] #view-results .result-detail-footer { margin: 14px 22px 0; }
  html body[data-active-view="results"] #view-results .result-detail-kicker { grid-column: 1 / -1; margin-bottom: 12px; }
  html body[data-active-view="results"] #view-results .result-detail-actions { grid-column: 1 / -1; grid-row: 3; margin: 14px 0 0; }
  html body[data-active-view="results"] #view-results .result-detail-address { grid-row: 4; margin-top: 12px; }
  html body[data-active-view="results"] #view-results .result-facts { grid-template-columns: 1fr; gap: 8px; }
  html body[data-active-view="results"] #view-results .result-facts > div { padding: 10px 14px; }
}
@media (max-width: 850px) {
  html:has(body[data-active-view="results"] #view-results.is-active) { height: auto; overflow: auto; }
  html body[data-active-view="results"] { height: auto; min-height: 100dvh; overflow: visible; }
  html body[data-active-view="results"] .app-content { height: auto; overflow: visible; }
  html body[data-active-view="results"] .app-main { display: block; overflow: visible; padding: 20px 20px 32px; }
  html body[data-active-view="results"] #view-results.is-active { height: auto; overflow: visible; }
  html body[data-active-view="results"] #view-results .results-workbench { grid-template-columns: minmax(0, 1fr); grid-template-rows: auto; gap: 20px; }
  html body[data-active-view="results"] #view-results .results-workbench { padding-bottom: 0; }
  html body[data-active-view="results"] #view-results .results-browser { max-height: none; }
  html body[data-active-view="results"] #view-results #results-table-wrap { flex: none; max-height: 460px; }
  html body[data-active-view="results"] #view-results .result-detail { scroll-margin-top: 80px; max-height: none; }
  html body[data-active-view="results"] #view-results .result-detail-body { overflow: visible; }
  html body[data-active-view="results"] #view-results .result-detail-back { display: block; align-self: flex-start; min-height: 44px; margin: 10px 18px 0; padding: 8px 4px; color: #537b66; background: none; border: 0; font-size: 13px; }
  html body[data-active-view="results"] #view-results .result-detail-header { padding-top: 12px; }
  html body[data-active-view="results"] #view-results .result-facts { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  html body[data-active-view="results"] #view-results .run-picker { flex: 1; }
}
@media (max-width: 560px) {
  html body[data-active-view="results"] .app-header { display: flex; justify-content: space-between; gap: 8px; padding: 0 16px; }
  html body[data-active-view="results"] .app-header .sidebar-head { flex: none; }
  html body[data-active-view="results"] .app-header .brand { gap: 6px; }
  html body[data-active-view="results"] .app-header .brand .brand-word { font-size: 17px; }
  html body[data-active-view="results"] .app-header .brand-mark { width: 24px; height: 24px; }
  html body[data-active-view="results"] .app-header .main-nav { position: relative; inset: auto; width: auto; min-width: 0; gap: 0; margin: 0; transform: none; }
  html body[data-active-view="results"] .app-header .nav-item { width: 44px; min-width: 44px; min-height: 44px; padding: 10px; }
  html body[data-active-view="results"] .app-header .account-menu-wrap { flex: none; }
  html body[data-active-view="results"] #view-results .results-page-intro h1 { font-size: 26px; }
  html body[data-active-view="results"] #view-results .results-header-actions { flex-wrap: wrap; }
  html body[data-active-view="results"] #view-results .results-run-bar { flex: 1 1 100%; }
  html body[data-active-view="results"] #view-results .run-picker { max-width: none; }
  html body[data-active-view="results"] #view-results .export-menu { flex: 1; }
  html body[data-active-view="results"] #view-results #export-toggle { width: 100%; }
  html body[data-active-view="results"] #view-results #client-qualify { flex: 1 1 100%; }
  html body[data-active-view="results"] #view-results .results-browser { padding: 14px 14px 12px; }
  html body[data-active-view="results"] #view-results #results-table-wrap, html body[data-active-view="results"] #view-results .result-load-more { margin-inline: -14px; }
  html body[data-active-view="results"] #view-results .workspace-new-analysis.button { flex: 1; }
  html body[data-active-view="results"] #view-results .results-summary { font-size: 12px; }
  html body[data-active-view="results"] #view-results #hotel-search { font-size: 16px; }
  html body[data-active-view="results"] #view-results .result-candidate { gap: 12px; padding: 12px 14px; }
  html body[data-active-view="results"] #view-results .result-candidate-copy strong { font-size: 13px; }
  html body[data-active-view="results"] #view-results .result-detail-header { padding-inline: 18px; }
  html body[data-active-view="results"] #view-results #result-detail-title { font-size: 25px; }
  html body[data-active-view="results"] #view-results .result-detail-body { padding: 18px; }
  html body[data-active-view="results"] #view-results .result-facts { grid-template-columns: 1fr; }
  html body[data-active-view="results"] #view-results .result-detail-footer { margin: 14px 18px 0; }
  html body[data-active-view="results"] #view-results .result-detail-actions .button { min-height: 44px; }
}
/* Scheda v4: che cosa fa l'attivita', dal sito e da Google. */
html body #view-results .result-hours { margin: -6px 0 18px; border-bottom: 0; }
html body #view-results .result-hours > summary { padding: 0; font-size: 12px; }
html body #view-results .result-hours ul { display: grid; grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); gap: 2px 16px; margin: 10px 0 0; padding: 0; list-style: none; color: #4a5c74; font-size: 12px; line-height: 1.7; }
html body #view-results .result-site { margin: 4px 0 20px; }
/* Una griglia sola per tutte le righe: la colonna delle etichette è larga
   quanto la più lunga, non una misura fissa che lasciava un buco. */
html body #view-results .result-site-rows { display: grid; grid-template-columns: max-content minmax(0, 1fr); gap: 12px 16px; align-items: baseline; margin: 0 0 14px; }
html body #view-results .result-site-rows > div { display: contents; }
html body #view-results .result-site-rows dt { color: #8290a6; font-size: 10px; letter-spacing: .08em; line-height: 1.5; text-transform: uppercase; }
html body #view-results .result-site-rows dd { margin: 0; color: #0b1f3a; font-size: 13px; line-height: 1.6; overflow-wrap: anywhere; }
html body #view-results .result-site-rows dd a { color: #32868b; text-underline-offset: 3px; }
html body #view-results .result-tags { display: flex; flex-wrap: wrap; gap: 6px; margin: 0; padding: 0; list-style: none; }
html body #view-results .result-tags li { margin: 0; padding: 4px 10px; color: #27666c; background: #eef6f2; border-radius: 999px; font-size: 12px; line-height: 1.5; }
html body #view-results .result-tags a { color: inherit; text-decoration: none; }
html body #view-results .result-tags a:hover { text-decoration: underline; }
html body #view-results .result-tech { margin-top: 18px; border-top: 1px solid #eef1f5; border-bottom: 0; }
html body #view-results .result-tech > summary { padding: 14px 0 0; font-size: 12px; }
html body #view-results .result-tech h4 { margin: 18px 0 6px; color: #0b1f3a; font-size: 13px; font-weight: 500; }
html body #view-results .result-tech-links { margin: 0; padding: 0; list-style: none; font-size: 12px; line-height: 1.8; overflow-wrap: anywhere; }
html body #view-results .result-tech-links a { color: #758792; text-underline-offset: 3px; }
@media (max-width: 650px) {
  html body #view-results .result-site-rows { grid-template-columns: 1fr; gap: 4px; }
  html body #view-results .result-site-rows dd { margin-bottom: 8px; }
}
@media (max-width: 380px) {
  html body[data-active-view="results"] .app-header .brand-word { display: none; }
}
@media (prefers-reduced-motion: reduce) {
  html body[data-active-view="results"] #view-results * { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
}

/* --- Fuori raggio: una scheda sua, con la spiegazione e il modo di allargare --
   Schede e bottoni hanno un display esplicito, che batterebbe l'attributo
   hidden: qui lo si ribadisce. */
html body[data-active-view="results"] #view-results :is(.results-section-tab, .results-outside-note, .button)[hidden] { display: none !important; }
html body[data-active-view="results"] #view-results .results-outside-note { display: flex; flex: none; flex-wrap: wrap; align-items: center; gap: 10px 14px; margin: 0; padding: 12px 14px; color: #4f5f73; background: #f7f9fb; border: 1px solid #e9edf2; border-radius: 12px; font: 400 12.5px/1.5 var(--font-sans); }
html body[data-active-view="results"] #view-results .results-outside-note p { flex: 1 1 260px; margin: 0; }
html body[data-active-view="results"] #view-results .results-outside-note .button { min-height: 38px; padding: 8px 14px; color: #2b6b49; border-color: #a5dec2; font-weight: 600; }
html body[data-active-view="results"] #view-results .results-outside-note .button:hover:not(:disabled) { background: #f0f8f3; }

html body #qualify-dialog .qualify-dialog-note { margin: 0; color: #5a6a7e; font: 400 13px/1.55 var(--font-sans); }
