/* Stili confinati alla sezione, coerenti con il tema del registro. */
#app .surveys-area { min-width:0; }
#app .surveys-area .topbar { gap:20px; flex-wrap:wrap; }
#app .surveys-area h2 { font-size:22px; margin:0 0 16px; overflow-wrap:anywhere; }
#app .surveys-area h3 { font-size:17px; margin:0 0 12px; overflow-wrap:anywhere; }
#app .surveys-area p { line-height:1.6; }
#app .surveys-area button { min-height:40px; white-space:normal; }
#app .surveys-area button:disabled { opacity:.6; cursor:default; }
#app .surveys-area button:focus-visible, #app .surveys-area input:focus-visible, #app .surveys-area select:focus-visible, #app .surveys-area textarea:focus-visible { outline:2px solid var(--forest); outline-offset:3px; }
#app .surveys-area .survey-muted, #app .surveys-area small { color:var(--muted); font-size:13px; font-weight:400; line-height:1.5; }
#app .survey-toolbar, #app .survey-actions, #app .survey-card-heading, #app .survey-question-heading { display:flex; align-items:center; justify-content:space-between; gap:12px; flex-wrap:wrap; }
#app .survey-toolbar { margin-bottom:20px; }
#app .survey-actions { justify-content:flex-start; margin:20px 0; }
#app .survey-card-heading { margin-bottom:14px; }
#app .survey-list { display:grid; gap:16px; }
#app .survey-card, #app .survey-intro, #app .survey-results, #app .survey-form { padding:24px; margin-top:16px; }
#app .survey-card { margin-top:0; }
#app .survey-preview { display:-webkit-box; -webkit-line-clamp:3; -webkit-box-orient:vertical; overflow:hidden; white-space:pre-wrap; overflow-wrap:anywhere; color:var(--muted); }
#app .survey-description { white-space:pre-wrap; overflow-wrap:anywhere; }
#app .survey-card footer { display:flex; justify-content:space-between; align-items:center; gap:16px; flex-wrap:wrap; font-size:13px; margin-top:20px; }
#app .survey-badge { display:inline-flex; border-radius:30px; padding:5px 11px; font-size:12px; font-weight:700; }
#app .survey-draft { color:#4f5963; background:#eef0f2; }
#app .survey-active { color:#1e527e; background:#e6f1fa; }
#app .survey-completed { color:#1d6b43; background:#e2f2e7; }
#app .survey-expired { color:#934522; background:#fff0df; }
#app .survey-info, #app .survey-error { padding:14px 16px; border-radius:8px; background:#edf4f5; color:var(--ink); margin:12px 0; font-size:14px; }
#app .survey-error, #app [data-dialog-error]:not(:empty) { background:#fff0ed; color:#9d3325; }
#app .surveys-area label { display:grid; gap:7px; font-size:14px; font-weight:600; min-width:0; margin:14px 0; }
#app .surveys-area input:not([type=checkbox]):not([type=radio]), #app .surveys-area select, #app .surveys-area textarea { display:block; width:100%; min-width:0; max-width:100%; border:1px solid var(--line); background:#fff; color:var(--ink); border-radius:7px; padding:10px 12px; font:inherit; font-weight:400; }
#app .surveys-area textarea { resize:vertical; }
#app .surveys-area fieldset { border:0; padding:0; margin:0; min-width:0; }
#app .surveys-area .survey-question { border:1px solid var(--line); border-radius:10px; padding:20px; margin:20px 0; }
#app .surveys-area .survey-question legend { padding:0 6px; font-weight:700; font-size:16px; max-width:100%; overflow-wrap:anywhere; }
#app .survey-fields { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:20px; }
#app .surveys-area .survey-choice { display:flex; align-items:flex-start; gap:10px; font-weight:400; padding:10px 12px; border:1px solid var(--line); border-radius:7px; margin:8px 0; cursor:pointer; overflow-wrap:anywhere; }
#app .surveys-area .survey-choice input { appearance:auto; width:18px; height:18px; flex:0 0 18px; margin:1px 0 0; accent-color:var(--forest); }
#app .surveys-area .survey-teachers { max-height:300px; overflow:auto; border:1px solid var(--line); padding:12px; border-radius:8px; }
#app .survey-option { display:flex; align-items:center; gap:10px; }
#app .survey-option label { flex:1; }
#app .survey-option button { flex-shrink:0; margin-top:25px; }
#app .survey-stats { display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); gap:12px; margin:22px 0; }
#app .survey-stats>div { border:1px solid var(--line); padding:15px; border-radius:9px; }
#app .survey-stats strong, #app .survey-stats span { display:block; }
#app .survey-stats strong { font-size:26px; color:var(--forest); }
#app .survey-stats span { margin-top:4px; font-size:13px; color:var(--muted); }
#app .survey-recipient-list { list-style:none; padding:0; margin:0; }
#app .survey-recipient-list li { display:flex; justify-content:space-between; align-items:center; gap:16px; padding:14px 0; border-top:1px solid var(--line); }
#app .survey-recipient-list strong, #app .survey-recipient-list small { display:block; overflow-wrap:anywhere; }
#app .survey-result { border-top:1px solid var(--line); padding:24px 0 8px; margin-top:20px; }
#app .survey-bar-row { margin:16px 0; }
#app .survey-bar-row>div:first-child { display:flex; justify-content:space-between; gap:16px; margin-bottom:8px; font-size:14px; }
#app .survey-bar-row strong { white-space:nowrap; }
#app .survey-bar-row span { overflow-wrap:anywhere; }
#app .survey-bar { height:9px; border-radius:10px; background:#edf0f2; overflow:hidden; }
#app .survey-bar>span { display:block; height:100%; background:var(--forest); border-radius:10px; }
#app .survey-result blockquote { padding:16px; margin:12px 0; background:#f5f7f8; border-radius:8px; }
#app .survey-result blockquote p { white-space:pre-wrap; overflow-wrap:anywhere; margin-bottom:0; }
#app #survey-dialog { width:min(560px,calc(100% - 32px)); max-height:85vh; overflow:auto; padding:26px; color:var(--ink); background:var(--panel); border:1px solid var(--line); border-radius:14px; box-shadow:var(--shadow); }
#app #survey-dialog::backdrop { background:rgba(15,27,39,.5); }
@media(max-width:600px) {
  #app .survey-card, #app .survey-intro, #app .survey-results, #app .survey-form { padding:18px; }
  #app .survey-fields { grid-template-columns:1fr; gap:0; }
  #app .surveys-area .survey-question { padding:14px; }
  #app .survey-stats { gap:6px; }
  #app .survey-stats>div { padding:10px 7px; }
  #app .survey-stats span { font-size:12px; }
  #app .surveys-area input, #app .surveys-area select, #app .surveys-area textarea { font-size:16px!important; }
  #app .survey-card footer { align-items:stretch; flex-direction:column; }
  #app .survey-card footer button { width:100%; }
}
