/* Estrutura e medidas dos módulos da referência, com tokens institucionais CLOSETFY. */
.support-module { --support-border:var(--border2); --support-surface:var(--surface2); --support-secondary:var(--surface3); --support-muted:var(--text3); color:var(--text1); min-width:0; font-family:Inter,system-ui,sans-serif; font-size:16px; line-height:1.55; }
.support-module *, .support-module *::before, .support-module *::after { box-sizing:border-box; }
.support-module-header { display:flex; align-items:center; margin-bottom:1rem; }
.support-module-header h1 { margin:0; font-family:var(--font-body,Inter,system-ui,sans-serif); font-size:clamp(1.8rem,2.6vw,2.5rem); line-height:1.05; font-weight:700; }
#help-center .help-tabs, .gestao-help .help-tabs, .support-module .support-desk-tabs { display:flex; gap:.5rem; overflow-x:auto; margin:0 0 1.25rem; padding:.32rem; background:var(--surface2); border:1px solid var(--border2); border-radius:13px; box-shadow:var(--shadow-sm); }
#help-center .help-tab, .gestao-help .help-tab, .support-module .support-desk-tabs button { display:inline-flex; flex:0 0 auto; align-items:center; justify-content:center; gap:.42rem; min-height:38px; padding:.52rem .72rem; border:1px solid transparent; border-radius:7.74px; color:var(--text2); background:var(--surface3); font-family:var(--font-ui); font-size:.7rem; font-weight:750; line-height:1; white-space:nowrap; cursor:pointer; }
#help-center .help-tab.is-active, .gestao-help .help-tab.is-active, .support-module .support-desk-tabs button.active { color:var(--accent); border-color:color-mix(in srgb,var(--accent) 38%,var(--border2)); background:color-mix(in srgb,var(--accent) 12%,var(--surface2)); box-shadow:inset 0 -2px var(--accent); }
.support-module [hidden] { display:none!important; }
.support-module.support-workspace, .support-module #support-content, .support-module [data-support-workspace] { display:grid; gap:1rem; min-width:0; }
.support-module .panel { min-width:0; overflow:hidden; border:1px solid var(--support-border); border-radius:19px; background:var(--support-surface); box-shadow:var(--shadow-sm,none); }
.support-module .panel-heading { display:flex; align-items:center; justify-content:space-between; gap:1rem; padding:1.175rem 1.5rem; border-bottom:1px solid var(--support-border); }
.support-module h2, .support-module h3 { font-family:Manrope,Inter,sans-serif; font-weight:700; letter-spacing:-.035em; line-height:1.55; }
.support-module h2 { font-size:1.5rem; }
.support-module h3 { font-size:1.17rem; }
.support-module .panel-heading h2 { margin:0; font-size:1.15rem; }
.support-module .panel-heading h3 { margin:0; }
.support-module .panel-heading p { margin:.35rem 0 0; color:var(--support-muted); font-size:.72rem; }
.support-module p { overflow-wrap:anywhere; }
.support-module .empty-state { padding:2rem 1rem; text-align:center; color:var(--support-muted); font-size:.8rem; }
.support-module .empty-state.compact { padding:1rem .6rem; }
.support-module .danger, .support-module .text-danger { color:var(--danger); }
.support-module .button { display:inline-flex; justify-content:center; align-items:center; gap:.5rem; min-height:44px; padding:.3875rem 1rem; border:1px solid transparent; border-radius:7.74px; background:var(--support-surface); color:var(--text1); font:inherit; font-size:.78rem; font-weight:700; cursor:pointer; text-decoration:none; }
.support-module .button-primary { color:var(--text-inverse); background:var(--accent); border-color:var(--accent); }
.support-module .button-secondary { background:var(--support-secondary); }
.support-module .button-quiet { color:var(--accent); background:color-mix(in srgb,var(--accent) 13%,transparent); }
.support-module .button-small { min-height:30px; padding:.4rem .65rem; font-size:.68rem; }
.support-module .button:disabled { opacity:.6; cursor:wait; }
.support-module input, .support-module select, .support-module textarea { width:100%; min-width:0; padding:.775rem .905rem; border:1px solid var(--support-border); border-radius:9px; background:var(--support-secondary); color:var(--text1); font:inherit; font-size:1rem; font-weight:400; }
.support-module input:not([type=file]), .support-module select { min-height:44px; padding-block:.3875rem; }
.support-module input:focus, .support-module select:focus, .support-module textarea:focus, .support-module [tabindex]:focus-visible { outline:2px solid color-mix(in srgb,var(--accent) 45%,transparent); outline-offset:2px; }
.support-module textarea { resize:vertical; }
.support-module input[type=file] { min-height:44px; padding:.25rem; font-size:1rem; }
.support-module input[type=file]::file-selector-button { margin-right:.75rem; min-height:34px; padding:.3rem .7rem; border:1px solid var(--support-border); border-radius:9px; color:var(--text1); background:var(--support-secondary); font:inherit; font-weight:700; cursor:pointer; }
.support-module .field { display:grid; gap:.5rem; min-width:0; color:var(--text2); font-size:.79rem; font-weight:700; }
.support-module .form-grid { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:1rem; padding:1.5rem; }
.support-module .field-wide { grid-column:1/-1; }
.support-module .modal-actions { display:flex; justify-content:flex-end; gap:.75rem; margin-top:1.5rem; padding-top:1rem; border-top:1px solid var(--support-border); }
.support-module .support-new { width:100%; max-width:none; margin:0; }
.support-module .editor-toolbar { display:flex; gap:.35rem; flex-wrap:wrap; padding:.45rem; border:1px solid var(--support-border); border-bottom:0; border-radius:9px 9px 0 0; background:var(--support-secondary); }
.support-module .editor-toolbar button { min-width:34px; padding:.35rem; border:0; border-radius:4px; background:transparent; color:var(--text1); font-size:1rem; cursor:pointer; }
.support-module .editor-toolbar input { flex-basis:100%; }
.support-module .support-editor { min-height:180px; max-height:60vh; overflow:auto; padding:.8rem; border:1px solid var(--support-border); border-radius:0 0 9px 9px; outline:none; overflow-wrap:anywhere; font-size:1rem; font-weight:400; }
.support-module .support-editor:focus { border-color:var(--accent); }
.support-module .upload-drop { display:grid; justify-items:center; align-content:center; gap:.75rem; padding:1.5rem; text-align:center; border:1px dashed var(--support-border); border-radius:9px; background:var(--support-secondary); cursor:pointer; color:var(--text2); font-size:.79rem; font-weight:700; }
.support-module .upload-drop input { order:3; width:min(100%,36rem); max-width:100%; margin:0; }
.support-module .upload-drop strong, .support-module .upload-drop small, .support-module .upload-drop span { display:block; max-width:100%; margin:0; overflow-wrap:anywhere; }
.support-module .upload-drop strong { order:1; }
.support-module .upload-drop small { order:2; color:var(--support-muted); font-size:.66rem; }
.support-module .upload-drop span { order:4; }
.support-module .support-mine-heading { display:flex; justify-content:space-between; align-items:center; gap:1rem; margin:0; padding:.75rem 0; }
.support-module .support-mine-heading h2 { margin:0; }
.support-module .support-simple-filters { display:flex; gap:.5rem; flex-wrap:wrap; margin:0; padding:.5rem 0; }
.support-module .support-simple-filters button { flex:0 0 auto; min-height:38px; padding:.52rem .72rem; border:1px solid var(--support-border); border-radius:7.74px; color:var(--text2); background:var(--support-surface); font-size:.7rem; font-weight:750; line-height:1; cursor:pointer; }
.support-module .support-simple-filters .active { border-color:var(--accent); color:var(--text-inverse); background:var(--accent); box-shadow:inset 0 -2px color-mix(in srgb,var(--text-inverse) 35%,transparent); }
.support-module [data-mine-sections] { display:grid; gap:1rem; }
.support-module .support-list { padding:0 1.5rem 1.5rem; margin:0; }
.support-module .support-list > .panel-heading { margin:0 -1.5rem .75rem; }
.support-module .count-badge { display:inline-flex; justify-content:center; align-items:center; min-width:22px; height:22px; padding:0 .35rem; border-radius:999px; background:var(--support-secondary); color:var(--text2); font-size:.66rem; }
.support-module .support-list .support-ticket { margin-top:.75rem; }
.support-module .support-kpis { display:grid; grid-template-columns:repeat(4,minmax(0,1fr)); gap:.75rem; margin:0; }
.support-module .support-kpis button { display:grid; gap:.3rem; padding:1rem; text-align:left; text-decoration:none; color:var(--text1); border:1px solid var(--support-border); border-radius:13px; background:var(--support-surface); font:inherit; }
.support-module .support-kpis strong { font-size:1.7rem; font-weight:700; }
.support-module .support-kpis small { color:var(--text1); font-size:.833333em; }
.support-module .support-kpis .danger { border-color:var(--danger); }
.support-module .support-filters { display:flex; align-items:end; gap:1rem; margin:0; padding:1rem 1.5rem; }
.support-module .support-filters label { display:grid; gap:.4rem; min-width:0; font-size:.72rem; color:var(--text2); }
.support-module .support-filters label > span { font-size:.66rem; font-weight:700; }
.support-module .support-filters input, .support-module .support-filters select { font-size:.79rem; font-weight:700; }
.support-module .support-search-field { flex:1; }
.support-module .support-priority-field { flex:0 1 190px; }
.support-module .support-kanban { display:grid; grid-template-columns:repeat(4,minmax(0,1fr)); gap:1rem; align-items:start; }
.support-module .support-history-grid { grid-template-columns:1fr; }
.support-module .support-column { min-width:0; min-height:420px; padding:1rem; border:1px solid var(--support-border); border-radius:13px; background:var(--support-secondary); }
.support-module .support-column > header { display:flex; justify-content:space-between; align-items:center; gap:.75rem; margin-bottom:.75rem; font-size:1rem; }
.support-module .support-column > header span { font-size:1rem; }
.support-module .support-column > div { display:grid; gap:.75rem; }
.support-module .support-ticket { display:grid; min-width:0; gap:.5rem; padding:1rem; border:1px solid var(--support-border); border-left:4px solid var(--accent); border-radius:9px; background:var(--support-surface); cursor:pointer; }
.support-module .support-ticket.priority-alta { border-left-color:var(--warning); }
.support-module .support-ticket.priority-urgente { border-left-color:var(--danger); }
.support-module .support-ticket > div:first-child { display:flex; justify-content:space-between; align-items:baseline; gap:.5rem; flex-wrap:wrap; font-size:1rem; }
.support-module .badge { display:inline-flex; width:max-content; max-width:100%; padding:.3rem .52rem; border-radius:999px; color:var(--text1); font-size:.64rem; font-weight:700; }
.support-module .support-ticket h3 { margin:0; font-size:.86rem; overflow-wrap:anywhere; }
.support-module .support-ticket dl { display:grid; gap:.2rem; margin:0; }
.support-module .support-ticket dl div { display:flex; justify-content:space-between; align-items:baseline; gap:.5rem; }
.support-module .support-ticket dt, .support-module .support-ticket dd, .support-module .support-ticket small { margin:0; color:var(--support-muted); font-size:.66rem; overflow-wrap:anywhere; }
.support-module [data-support-back] { justify-self:start; }
.support-module .support-detail { display:grid; grid-template-columns:minmax(280px,.7fr) minmax(0,1.5fr); gap:1rem; margin-top:0; }
.support-module .support-detail > .panel { padding:1.5rem; }
.support-module .support-detail h2 { margin:.75rem 0 1rem; overflow-wrap:anywhere; }
.support-module .details-grid { display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); gap:.75rem; margin-bottom:1.2rem; }
.support-module .details-grid > div { display:grid; gap:.25rem; min-width:0; padding:.75rem; border-radius:9px; background:var(--support-secondary); }
.support-module .details-grid small { color:var(--support-muted); font-size:.62rem; text-transform:uppercase; }
.support-module .details-grid strong { font-size:.78rem; overflow-wrap:anywhere; }
.support-module .ticket-actions { display:grid; gap:1rem; margin-top:1.5rem; }
.support-module .ticket-action-group { display:grid; gap:.75rem; padding:1rem; border:1px solid var(--support-border); border-radius:13px; background:var(--support-secondary); }
.support-module .ticket-action-group h3, .support-module .ticket-action-group p, .support-module .ticket-requester-confirmation p { margin:0; }
.support-module .ticket-action-group h3 { font-size:.85rem; }
.support-module .ticket-transfer > p { color:var(--support-muted); font-size:.72rem; }
.support-module .ticket-requester-confirmation p { font-size:.8rem; }
.support-module .ticket-resolution { margin-top:1rem; padding:.75rem; border:1px solid color-mix(in srgb,var(--success) 35%,var(--support-border)); border-radius:9px; }
.support-module .ticket-resolution small { color:var(--support-muted); }
.support-module .ticket-resolution p { margin:.4rem 0 0; font-size:.8rem; white-space:pre-wrap; }
.support-module .detail-tabs { display:flex; gap:.5rem; margin:0 0 .75rem; border-bottom:1px solid var(--support-border); }
.support-module .detail-tabs button { padding:.6rem; border:0; border-bottom:2px solid transparent; color:var(--support-muted); background:transparent; font-size:1rem; cursor:pointer; }
.support-module .detail-tabs .active { color:var(--accent); border-color:var(--accent); }
.support-module .ticket-conversation { display:grid; gap:.75rem; max-height:48vh; overflow:auto; padding:.75rem 0; }
.support-module .ticket-conversation article { padding:1rem; border-radius:9px; background:var(--support-secondary); }
.support-module .ticket-conversation article > div { display:flex; justify-content:space-between; gap:.5rem; font-size:1rem; }
.support-module .ticket-conversation time { color:var(--support-muted); font-size:.68rem; white-space:nowrap; }
.support-module .ticket-conversation p { margin:0 0 1rem; font-size:1rem; white-space:pre-wrap; line-height:1.55; }
.support-module .ticket-conversation a, .support-module .ticket-conversation > span { display:block; overflow-wrap:anywhere; color:var(--accent); font-size:.75rem; }
.support-module .ticket-reply { display:grid; gap:.75rem; padding-top:.75rem; }
.support-module .ticket-reply small { color:var(--support-muted); font-size:.68rem; }
.support-module .presence-notice { display:flex; align-items:center; gap:.45rem; margin:.75rem 0; padding:.65rem; border-radius:9px; background:color-mix(in srgb,var(--accent) 8%,var(--support-secondary)); font-size:.72rem; overflow-wrap:anywhere; }
.support-module .presence-dot { flex:0 0 8px; width:8px; height:8px; border-radius:50%; background:var(--success); box-shadow:0 0 0 4px color-mix(in srgb,var(--success) 15%,transparent); }
.support-module .timeline { display:grid; gap:.8rem; padding:1rem 0; }
.support-module .timeline > div { display:grid; grid-template-columns:10px minmax(0,1fr); align-items:start; gap:.8rem; }
.support-module .timeline > div > span { width:8px; height:8px; margin-top:6px; border-radius:50%; background:var(--accent); }
.support-module .timeline p { display:grid; gap:.3rem; margin:0; font-size:.8rem; }
.support-module .timeline small, .support-module .timeline em { color:var(--support-muted); font-size:.7rem; font-style:normal; }
@media(max-width:1100px) {
  .support-module .support-kanban { grid-template-columns:repeat(2,minmax(0,1fr)); gap:.7rem; }
  .support-module .support-kpis { grid-template-columns:repeat(2,minmax(0,1fr)); gap:.7rem; }
  .support-module .support-column { min-height:0; }
  .support-module .support-detail { grid-template-columns:minmax(16rem,.8fr) minmax(0,1.2fr); }
}
@media(max-width:1024px) {
  #help-center .help-tabs, .gestao-help .help-tabs, .support-module .support-desk-tabs { display:grid; grid-template-columns:repeat(auto-fit,minmax(8.5rem,1fr)); gap:.4rem; overflow:visible; margin-bottom:.9rem; padding:.35rem; }
  #help-center .help-tab, .gestao-help .help-tab, .support-module .support-desk-tabs button { width:100%; min-height:42px; white-space:normal; line-height:1.25; }
  .support-module .support-kpis { gap:.7rem; }
  .support-module .form-grid { gap:.85rem; }
}
@media(max-width:767px) {
  .support-module-header h1 { font-size:clamp(1.4rem,7vw,1.75rem); }
  #help-center .help-tabs, .gestao-help .help-tabs, .support-module .support-desk-tabs { grid-template-columns:repeat(2,minmax(0,1fr)); gap:.32rem; margin-bottom:.7rem; }
  #help-center .help-tab, .gestao-help .help-tab, .support-module .support-desk-tabs button { min-height:40px; padding:.45rem .5rem; font-size:.68rem; }
  .support-module .support-new { padding:.65rem; }
  .support-module .support-new > .panel-heading { padding:.75rem; }
  .support-module .panel-heading h2 { font-size:1rem; }
  .support-module .panel-heading p { margin-top:.2rem; line-height:1.4; }
  .support-module .field { gap:.3rem; }
  .support-module .button { min-height:40px; padding:.52rem .72rem; }
  .support-module .button-small { min-height:38px; padding:.4rem .6rem; }
  .support-module textarea { padding:.55rem .65rem; }
  .support-module .support-detail, .support-module .form-grid { grid-template-columns:1fr; }
  .support-module .support-detail > .panel, .support-module .form-grid { padding:1rem; }
  .support-module .support-list { padding:0 1rem 1rem; }
  .support-module .support-list > .panel-heading { margin-inline:-1rem; }
  .support-module .support-filters, .support-module .support-mine-heading { align-items:stretch; flex-direction:column; gap:.65rem; }
  .support-module .support-priority-field { flex:auto; }
  .support-module .support-kanban { grid-template-columns:1fr; gap:.65rem; overflow:visible; }
  .support-module .support-filters, .support-module .support-column, .support-module .ticket-action-group, .support-module .support-ticket { padding:.75rem; }
  .support-module .support-kpis { gap:.5rem; }
  .support-module .support-kpis button { min-height:4.8rem; padding:.65rem; }
  .support-module .support-mine-heading .button, .support-module .ticket-actions .button, .support-module .ticket-reply .button { width:100%; }
  .support-module .ticket-conversation { max-height:min(46dvh,28rem); }
  .support-module .ticket-conversation article > div, .support-module .support-ticket dl div { align-items:flex-start; flex-wrap:wrap; }
  .support-module .details-grid { grid-template-columns:1fr; }
  .support-module .modal-actions { margin-top:.5rem; padding-top:.75rem; }
  .support-module .modal-actions .button { width:100%; }
  .support-module .form-grid { gap:.7rem; }
  .support-module .upload-drop { gap:.5rem; padding:1rem; }
}

.gestao-help.support-module { display:block; }

.support-module .support-file-link { display:inline; padding:0; border:0; color:var(--accent); background:transparent; font:inherit; text-align:left; cursor:pointer; }
.support-module .support-file-link:disabled { opacity:.6; cursor:wait; }
