
:root{--ink:#171717;--muted:#66676c;--line:#e8e8e8;--yellow:#ffc824;--bg:#fff;--soft:#f7f7f7;color-scheme:light;font:16px/1.5 Inter,ui-sans-serif,system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",Arial,sans-serif}
*{box-sizing:border-box}
body{margin:0;background:var(--bg);color:var(--ink)}
.shell{max-width:1080px;padding:0 28px;margin:auto}
.topbar{height:80px;display:flex;align-items:center;justify-content:space-between;border-bottom:1px solid var(--line);gap:14px}
.identity{display:flex;align-items:center;gap:14px}.brand-name{font-size:23px;font-weight:850;letter-spacing:-1.2px}.brand-dot{color:#cc9a00}
.pill{font-size:12px;font-weight:650;color:#565656;padding:5px 10px;background:#f5f5f5;border-radius:100px;white-space:nowrap}
.privacy-indicator{font-size:12px;color:var(--muted);display:flex;align-items:center;gap:8px;white-space:nowrap}.private-dot{height:7px;width:7px;background:#1a9c6b;border-radius:50%}
.hero{text-align:center;padding:45px 0 25px}.logo{height:128px;width:128px;display:block;margin:0 auto 18px}
h1{font-size:clamp(27px,4.9vw,49px);letter-spacing:-2.3px;line-height:1.16;margin:0;font-weight:830}h1 span{color:#858585}
.subtitle{max-width:590px;color:var(--muted);font-size:15px;margin:16px auto 0}
.workspace{max-width:830px;margin:25px auto;padding:14px 0 30px;background:var(--bg)}.workspace h2{font-size:20px;font-weight:770;letter-spacing:-.45px;margin:0 0 18px}
.providers{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:10px}
.provider{border:1px solid var(--line);background:#fff;border-radius:14px;padding:14px 8px 12px;min-width:0;display:flex;flex-direction:column;align-items:center;gap:4px;cursor:pointer;transition:border .15s ease,background .15s ease}
.provider .provider-icon{width:33px;height:33px;display:block;margin-bottom:4px}.provider span{font-size:14px;font-weight:740}.provider small{font-size:11px;color:var(--muted)}
.provider.is-selected{background:#fffdf5;border-color:#eccf7f;box-shadow:0 0 0 1px #f7e6b7}.provider[aria-disabled=true]{opacity:.65}.provider[aria-disabled=true]:hover{border-color:#d0d0d0}
.help{font-size:12px;color:#737373;line-height:1.6;margin:10px 0}.provider-note{margin:11px 0 26px}
.field-label{font-size:13px;font-weight:720;display:block;margin:0 0 9px}.urlbar,.search-line{display:flex;align-items:stretch;gap:10px}
input[type=url],input[type=search],select{min-width:0;padding:13px 15px;color:var(--ink);background:#fff;border:1px solid #dbdbdb;border-radius:11px;font:inherit;font-size:14px;outline:none}
input[type=url],input[type=search]{flex:1;width:100%}input:focus-visible,select:focus-visible,button:focus-visible,label.upload:focus-within{outline:3px solid #ffd85d;outline-offset:2px}
.icon-button{width:49px;border-radius:11px;border:1px solid #dedede;background:#f8f8f8;font-size:23px;cursor:pointer}.icon-button:disabled{cursor:not-allowed;color:#bebebe}
.import-options{margin-top:17px}.import-options>summary{cursor:pointer;color:#686868;font-size:12px;padding:8px 0}.import-options .upload{margin-top:12px}
.upload{cursor:pointer;display:flex;align-items:center;gap:14px;background:#fafafa;border:1px dashed #cacaca;border-radius:12px;padding:17px 19px;width:100%}
.upload strong{font-size:14px;display:block}.upload small{font-size:12px;color:var(--muted);display:block;margin-top:3px}.upload-symbol{width:38px;height:38px;border:1px solid #e2e2e2;border-radius:10px;display:grid;place-items:center;font-size:22px;flex-shrink:0}
#file-import{position:absolute;clip-path:inset(50%);width:1px;height:1px;overflow:hidden}
.button-wrapper{margin-top:20px}.gnam-button{width:100%;display:flex;gap:11px;align-items:center;justify-content:center;border:0;border-radius:100px;background:var(--yellow);height:66px;font-weight:860;font-size:18px;letter-spacing:-.5px;cursor:pointer;transition:transform .2s ease,box-shadow .2s ease}.gnam-button:not(:disabled):hover{transform:translateY(-1px);box-shadow:0 8px 24px #d5a6002b}
.gnam-button:disabled{opacity:.53;cursor:not-allowed}.gnam-button-icon{width:39px;height:39px;overflow:visible}
.gnam-button.is-chewing .jaw{animation:jaw-bob .45s ease-in-out infinite alternate;transform-origin:30px 30px}.gnam-button.is-chewing .mouth-dots circle{animation:dot-dance .62s ease-in-out infinite;transform-box:fill-box;transform-origin:center}
.gnam-button.is-chewing .mouth-dots circle:nth-child(2){animation-delay:.15s}.gnam-button.is-chewing .mouth-dots circle:nth-child(3){animation-delay:.3s}
@keyframes jaw-bob{from{transform:scaleY(.76)}to{transform:scaleY(1.02)}}@keyframes dot-dance{0%,100%{transform:translateY(0) scale(1)}50%{transform:translateY(-6px) scale(1.12)}}
.below{text-align:center;margin-bottom:0}.status{padding:8px 0 0;font-size:13px;min-height:30px;color:#505050}.status.error{color:#9b2626}.status.ok{color:#116e46}
.results{border-top:1px solid var(--line);margin-top:33px;padding-top:27px}.meta-row{display:flex;align-items:center;justify-content:space-between;gap:12px;font-size:18px;margin-bottom:14px}.meta-row strong{overflow-wrap:anywhere}
.warning{padding:10px 13px;border-left:2px solid #dfc471;color:#725315;font-size:12px;line-height:1.6;background:#fffdf8}
.search-panel{margin-top:26px}.search-line button{border:0;border-radius:11px;background:var(--ink);color:#fff;font-size:14px;font-weight:750;padding:12px 25px;cursor:pointer}
.filters{display:flex;align-items:center;gap:12px;flex-wrap:wrap;margin-top:12px;font-size:12px;color:var(--muted)}.filters select{font-size:12px;padding:7px 10px;width:auto}.filters>span{margin-left:auto}
.stats{color:#5b5b5b;font-size:13px;margin:20px 0 10px}.result-actions{display:flex;gap:8px;flex-wrap:wrap;padding-bottom:14px}.small-button,.more{border:1px solid #dedede;background:#fff;border-radius:8px;padding:9px 12px;font-size:12px;font-weight:700;cursor:pointer}.small-button:disabled{opacity:.38;cursor:not-allowed}.quiet{margin-left:auto}
.downloads{border-top:1px solid var(--line);border-bottom:1px solid var(--line);padding:16px 0 20px}.downloads-heading{display:flex;justify-content:space-between;align-items:center;gap:12px;margin-bottom:14px}.downloads-heading strong{font-size:14px}.downloads-heading select{padding:9px 12px;font-size:12px;max-width:270px}
.download-buttons{display:flex;gap:9px;flex-wrap:wrap}.download-buttons button{border:1px solid #dcdcdc;border-radius:9px;padding:10px 16px;background:#fff;font:inherit;font-size:13px;font-weight:700;cursor:pointer}.download-buttons button:hover{background:#f9f9f9}.download-buttons .ext{color:#858585;font-size:11px;font-weight:500}
.message-list{display:flex;flex-direction:column;gap:20px;margin:24px 0}.message{border:0;padding:2px 0;min-width:0;display:flex;flex-direction:column;align-items:flex-start}.message.user{align-items:flex-end}.msg-meta{display:flex;align-items:center;gap:7px;font-size:11px;color:#777;margin-bottom:6px}.role{font-weight:750;color:#626262}.message.hit .msg-meta::before{content:'';display:inline-block;width:6px;height:6px;background:#d1a000;border-radius:50%}.message.hit .role{color:#947100}
.msg-text{white-space:pre-wrap;overflow-wrap:anywhere;margin:0;font-family:inherit;font-size:14px;line-height:1.7;max-width:100%;border:0;max-height:none;overflow:visible}.message.user .msg-text{padding:13px 16px;border-radius:18px 18px 5px 18px;background:#f4f4f4;max-width:min(88%,620px)}.message.assistant .msg-text{padding:1px 0;max-width:100%}
.expand-message{background:none;border:0;text-decoration:underline;color:#666;font:inherit;font-size:12px;cursor:pointer;padding:4px 0;align-self:flex-start}.more{width:100%;padding:14px;margin-top:12px}
.sr-only{position:absolute!important;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;border:0}
footer{display:flex;gap:14px;justify-content:space-between;margin:60px 0 30px;padding-top:19px;border-top:1px solid var(--line);font-size:11px;color:#898989;flex-wrap:wrap}
[hidden]{display:none!important}
@media(max-width:600px){.shell{padding:0 17px}.topbar{height:66px}.privacy-indicator{font-size:0}.private-dot{height:9px;width:9px}.hero{padding-top:30px}.logo{width:104px;height:104px}.workspace{padding:13px 0;margin:12px auto}.workspace h2{font-size:17px}.meta-row{flex-direction:column;align-items:flex-start}.quiet{margin-left:0}.filters>span{margin-left:0}.gnam-button{height:60px}h1{letter-spacing:-1.35px}.subtitle{font-size:14px}.providers{gap:6px}.provider{padding:12px 5px}.provider .provider-icon{width:27px;height:27px}.provider span{font-size:12px}.provider small{font-size:10px}.downloads-heading{align-items:flex-start}.downloads-heading select{max-width:205px}}
@media(prefers-reduced-motion:reduce){*,*::before,*::after{animation-duration:.01ms!important;animation-iteration-count:1!important;transition:none!important}}

/* Small factual caveat, not a failure banner; the technical validator remains untouched. */
#validation-note{font-size:11px!important;font-weight:400!important;line-height:1.5!important;color:#7e7e7e!important;background:none!important;border:0!important;padding:3px 0 8px!important;margin:0!important}

/* Grafo locale — componenti autonomi: nessun framework remoto */
.index-graph-panel{margin:26px 0 28px;padding:18px 18px 20px;border:1px solid var(--line);border-radius:16px;background:#fcfcfc}
.graph-header{display:flex;align-items:center;justify-content:space-between;gap:12px;flex-wrap:wrap}
.index-graph-panel h3{font-size:17px;margin:0;font-weight:780}
.index-graph-panel h4{font-size:14px;margin:24px 0 10px}
.graph-chip{font-size:11px;background:#f0f0f0;border-radius:20px;padding:5px 9px;color:#606060}
.graph-config{font-size:12px;margin:15px 0;color:#646464}
.graph-config summary{cursor:pointer;font-weight:650}
.graph-config .field-label{margin-top:10px}
#graph-definitions{display:block;resize:vertical;width:100%;min-height:140px;background:#fff;border-radius:9px;border:1px solid #dedede;font:12px/1.4 ui-monospace,Consolas,monospace;padding:12px;color:#333}
.graph-controls{display:flex;align-items:center;gap:10px;flex-wrap:wrap}
.graph-controls label{font-size:12px;color:#606060}
.graph-controls select{padding:8px 12px;font-size:12px}
.graph-controls .small-button{background:#171717;color:#fff;border-color:#171717;margin-left:auto}
.graph-status{font-size:12px;color:#777;margin:12px 0}
.graph-status.error{color:#9b2626}
.graph-counts{font-size:13px;font-weight:700;margin:12px 0 5px}
.graph-visual{background:#fff;border:1px solid #e4e4e4;border-radius:12px;overflow:hidden;margin:10px 0}
.graph-visual svg{width:100%;height:auto;max-height:380px;display:block}
.graph-list{display:flex;flex-direction:column;gap:9px}
.graph-item{border:1px solid #e8e8e8;background:white;border-radius:10px;padding:10px 12px;display:flex;justify-content:space-between;align-items:center;gap:12px;font-size:13px}
.graph-item strong{font-weight:700}.graph-item small{color:#666;display:block;font-size:11px;line-height:1.45;margin-top:3px}
.graph-item button{font:inherit;font-size:11px;font-weight:700;border-radius:8px;border:1px solid #dedede;background:white;padding:8px 10px;flex-shrink:0;cursor:pointer}
.graph-item button:hover{background:#fff9e8}
#graph-export{margin-top:15px}
@media(max-width:600px){.index-graph-panel{padding:13px}.graph-controls .small-button{margin-left:0}.graph-item{align-items:flex-start;flex-direction:column}.graph-item button{align-self:flex-start}}

.footer-links{display:flex;gap:14px;flex-wrap:wrap}.footer-links a{color:var(--muted);text-decoration:underline;text-underline-offset:2px}.footer-links a:hover{color:var(--ink)}
/* La versione e` un dato editoriale nel footer, non nell'intestazione. */
.footer-version{flex-basis:100%;text-align:right;font-size:10px;color:#8a8a8a;letter-spacing:.025em}
