/* BredaNet Assistenza v2.3 — Assistente AI, Spazio file e notifiche evolute */
.title-icon{width:1.15em;height:1.15em;vertical-align:-.18em;margin-right:.35rem}

/* Assistente AI */
.ai-layout-v23{display:grid;grid-template-columns:minmax(230px,.32fr) minmax(0,1fr);gap:1rem;align-items:start}
.ai-history-v23{position:sticky;top:1rem;max-height:calc(100vh - 2rem);overflow:auto}
.ai-history-v23 .section-title{margin-bottom:.75rem}
.ai-conv-v23{display:grid;gap:.2rem;padding:.7rem .8rem;border:1px solid var(--border,#dbe5ee);border-radius:10px;margin:.45rem 0;color:inherit;text-decoration:none;background:#fff}
.ai-conv-v23.selected{border-color:var(--portal-accent,#1689e7);box-shadow:0 0 0 2px color-mix(in srgb,var(--portal-accent,#1689e7) 12%,transparent)}
.ai-conv-v23 small{color:#64748b}
.ai-chat-v23{min-height:560px;display:flex;flex-direction:column;gap:1rem}
.ai-messages-v23{display:grid;gap:.8rem;min-height:320px;max-height:62vh;overflow:auto;padding:.2rem}
.ai-msg-v23{max-width:min(88%,820px);padding:.85rem 1rem;border:1px solid #dbe5ee;border-radius:14px;background:#fff;box-shadow:0 4px 18px rgba(15,23,42,.04)}
.ai-msg-v23.user{margin-left:auto;background:#f3f8ff;border-color:#cfe4fb}
.ai-msg-v23.assistant{margin-right:auto;background:#f8fafc}
.ai-msg-v23 small,.ai-msg-v23 em{display:block;color:#64748b;font-size:.78rem;margin-bottom:.35rem}
.ai-msg-v23 .prewrap{white-space:pre-wrap;line-height:1.55;overflow-wrap:anywhere}
.ai-empty-v23{display:grid;place-items:center;text-align:center;min-height:290px;color:#64748b}
.ai-empty-v23 b{font-size:1.25rem;color:#0f172a}
.ai-composer-v23{border-top:1px solid #e2e8f0;padding-top:1rem;margin-top:auto}
.ai-composer-v23 textarea{min-height:100px;resize:vertical}
.ai-compose-actions-v23{display:flex;gap:.65rem;align-items:center;justify-content:space-between;flex-wrap:wrap}
.ai-file-button-v23{display:inline-flex;align-items:center;gap:.45rem;padding:.55rem .75rem;border:1px solid #cbd5e1;border-radius:9px;cursor:pointer;background:#fff;font-weight:650}
.ai-file-button-v23 input{position:absolute;inline-size:1px;block-size:1px;opacity:0;pointer-events:none}
.ai-file-context-v23{display:flex;align-items:center;gap:.55rem;padding:.65rem .75rem;border-radius:10px;background:#eff6ff;border:1px solid #bfdbfe;margin-bottom:.75rem}
.ai-file-context-v23 svg{width:18px;height:18px;flex:0 0 auto}
.ai-warning-v23{border-left:4px solid #f59e0b;background:#fffbeb}
.ai-settings-v23 .check{align-items:flex-start}

/* Centro notifiche */
.notification-v23-list{display:grid;gap:.7rem}
.notification-filters-v23{align-items:end;margin-bottom:1rem}
.notification-filters-v23 label{min-width:130px}
.notification-archive-row-v23{border:1px solid #dbe5ee;border-radius:12px;background:#fff;overflow:hidden}
.notification-archive-row-v23>summary{list-style:none;cursor:pointer;display:flex;align-items:center;justify-content:space-between;gap:1rem;padding:.72rem .9rem}
.notification-archive-row-v23>summary::-webkit-details-marker{display:none}
.notification-archive-row-v23>summary span:first-child{display:grid;gap:.15rem;min-width:0}
.notification-archive-row-v23>summary b{white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.notification-archive-row-v23>summary small{color:#64748b}
.notification-archive-row-v23>div{padding:.85rem .9rem;border-top:1px solid #e2e8f0;background:#f8fafc}
.notification-archive-row-v23>div p{margin-top:0;white-space:pre-wrap}
.archive-read-v23{font-size:.78rem;padding:.25rem .5rem;border-radius:999px;background:#eef2f7;color:#475569;white-space:nowrap}
.pagination-v23{display:flex;align-items:center;justify-content:center;gap:.7rem;flex-wrap:wrap;margin:1rem 0}
.bell-footer-v23{display:flex;align-items:center;justify-content:space-between;gap:.7rem;padding:.65rem .8rem;border-top:1px solid #e2e8f0}
.bell-footer-v23 form{margin:0}

/* I miei file */
.cloud-drop-v23{border:1.5px dashed #94a3b8!important;border-radius:12px;padding:.9rem!important;background:#f8fafc;transition:.15s ease}
.cloud-drop-v23.is-dragover{border-color:var(--portal-accent,#1689e7)!important;background:#eff6ff}
.cloud-drop-v23 span{display:block;color:#64748b;font-size:.8rem;margin-top:.3rem}
.cloud-item-v23 .cloud-actions{display:flex;gap:.4rem;flex-wrap:wrap}

@media (max-width:900px){
  .ai-layout-v23{grid-template-columns:1fr}
  .ai-history-v23{position:static;max-height:none}
  .ai-chat-v23{min-height:480px}
  .ai-messages-v23{max-height:none}
  .ai-msg-v23{max-width:100%}
  .notification-filters-v23{display:grid;grid-template-columns:repeat(2,minmax(0,1fr))}
}
@media (max-width:600px){
  .notification-filters-v23{grid-template-columns:1fr}
  .notification-archive-row-v23>summary{align-items:flex-start}
  .archive-read-v23{margin-top:.1rem}
  .ai-compose-actions-v23{align-items:stretch}
  .ai-file-button-v23,.ai-compose-actions-v23 button{width:100%;justify-content:center}
}
