/* Dashboard UI kit, Phase 3 pages and the responsive layer. Loaded after style.css. */

/* ============ SHARED ============ */
[hidden]{display:none !important}
#toast-container{z-index:1100}
:focus-visible{outline:2px solid var(--accent-light);outline-offset:2px}
.visually-hidden{position:absolute !important;width:1px;height:1px;overflow:hidden;clip:rect(0 0 0 0);white-space:nowrap}
.skip-link{position:absolute;left:12px;top:-48px;z-index:200;background:var(--accent);color:#fff;padding:8px 14px;border-radius:var(--radius-sm);font-weight:600}
.skip-link:focus{top:12px;color:#fff}
.muted{color:var(--text-3)}
.small{font-size:12px}
.push{margin-left:auto}
.pos{color:var(--green)}
.neg{color:var(--red)}
.warn-text{color:var(--yellow)}
.link-btn{background:none;border:0;color:var(--accent-light);font:600 13px var(--font);cursor:pointer;padding:4px 0}
.link-btn:hover{color:var(--text)}
.btn-icon{display:inline-flex;align-items:center;justify-content:center;border:0;cursor:pointer;color:var(--text-2);background:transparent;font-size:16px;flex-shrink:0}
.btn-icon:hover{background:var(--surface-2);color:var(--text)}
.btn-icon svg{width:18px;height:18px}
.btn-icon:disabled,.btn:disabled{opacity:.4;cursor:not-allowed;transform:none}
.btn-danger-solid{background:var(--red);color:#1a0505;border:0}
.btn-danger-solid:hover{background:#fca5a5}
.btn.is-busy{position:relative;color:transparent !important}
.btn.is-busy::after{content:'';position:absolute;width:14px;height:14px;border:2px solid var(--text);border-color:var(--text) transparent var(--text) transparent;border-radius:50%;animation:spin .7s linear infinite}
.lang-picker{display:inline-flex;align-items:center;gap:6px;padding:0 4px 0 10px;height:34px;border:1px solid var(--border);border-radius:var(--radius-sm);background:var(--surface);color:var(--text-2);cursor:pointer}
.lang-picker:hover{border-color:var(--border-hover);color:var(--text)}
.lang-picker svg{width:15px;height:15px;flex-shrink:0}
.lang-select{background:transparent;border:0;color:var(--text);font:600 13px var(--font);padding:6px 4px;cursor:pointer;outline:none;max-width:110px}
.lang-select option{background:var(--bg-2);color:var(--text)}
.lang-picker:focus-within{outline:2px solid var(--accent-light);outline-offset:2px}

.page-header-row{display:flex;align-items:flex-start;justify-content:space-between;gap:16px;flex-wrap:wrap}
.page-actions{display:flex;gap:8px;flex-wrap:wrap}
.toolbar{display:flex;gap:10px;align-items:flex-end;margin-bottom:16px;flex-wrap:wrap}
.toolbar .input{width:auto;min-width:160px;flex:1 1 200px}
.toolbar select.input{flex:0 1 auto;min-width:140px}
.toolbar .form-field{flex:0 0 auto}
.section-intro{font-size:14px;color:var(--text-2);line-height:1.6;margin-bottom:14px;max-width:72ch}
.section-actions{display:flex;gap:8px;margin:12px 0 16px;flex-wrap:wrap}
.preset-row{display:flex;gap:4px;align-items:center;flex-wrap:wrap}
.export-actions{display:flex;gap:8px}

.pill{display:inline-flex;align-items:center;gap:4px;padding:2px 9px;border-radius:999px;font-size:12px;font-weight:600;line-height:1.6;white-space:nowrap;border:1px solid transparent}
.pill-neutral{background:var(--surface-2);color:var(--text-2);border-color:var(--border)}
.pill-info{background:rgba(96,165,250,.12);color:#93c5fd}
.pill-ok{background:var(--green-soft);color:var(--green)}
.pill-warn{background:rgba(251,191,36,.12);color:var(--yellow)}
.pill-danger{background:var(--red-soft);color:var(--red)}
.pill-critical{background:var(--red);color:#1a0505}
.chip-line{display:flex;flex-wrap:wrap;gap:6px;align-items:center}
.chip-line.counts{margin-bottom:12px}

.empty-block,.error-block{text-align:center;padding:40px 20px;border:1px dashed var(--border);border-radius:var(--radius);display:flex;flex-direction:column;align-items:center;gap:8px}
.error-block{border-color:rgba(248,113,113,.3)}
.empty-block p,.error-block p{font-size:14px;color:var(--text-2);max-width:56ch}
.empty-title{font-weight:700;font-size:16px}

.notice{display:flex;align-items:center;justify-content:space-between;gap:12px;flex-wrap:wrap;padding:12px 16px;margin-bottom:16px;border-radius:var(--radius-sm);background:rgba(251,191,36,.08);border:1px solid rgba(251,191,36,.25);color:var(--yellow);font-size:13px;line-height:1.5}
.notice-info{background:rgba(96,165,250,.07);border-color:rgba(96,165,250,.25);color:var(--text)}
.notice-warn{background:rgba(251,191,36,.08);border-color:rgba(251,191,36,.3);color:var(--text)}
.notice-ok{background:var(--green-soft);border-color:rgba(52,211,153,.3);color:var(--text)}
.notes{margin:6px 0 0 18px;display:flex;flex-direction:column;gap:4px;color:var(--text-2)}

/* ============ FORMS ============ */
.form-grid{display:flex;flex-direction:column;gap:14px}
.form-grid-2{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px}
.form-grid-3{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:12px}
.form-row{display:flex;gap:8px;align-items:center;flex-wrap:wrap}
.form-row .input{flex:1;min-width:180px}
.form-field{display:flex;flex-direction:column;gap:6px;min-width:0}
.form-label{font-size:13px;font-weight:600;color:var(--text-2)}
.form-hint{font-size:12px;color:var(--text-3);line-height:1.5}
.form-hint.inline{margin-left:8px;font-weight:400}
select.input{cursor:pointer}
textarea.input{resize:vertical;min-height:64px;line-height:1.5}
.input:disabled{opacity:.6;cursor:not-allowed}
.check-row{display:flex;align-items:center;gap:8px;font-size:14px;color:var(--text-2);cursor:pointer}
.check-row input{width:16px;height:16px;accent-color:var(--accent);flex-shrink:0}
.chip-picker{display:flex;flex-wrap:wrap;gap:6px;max-height:220px;overflow:auto;padding:2px}
button.role-chip{font-family:var(--font);color:var(--text)}
.role-chip.static{cursor:default}

/* ============ MODAL ============ */
.modal-overlay{align-items:flex-start}
.modal-v2{max-height:calc(100dvh - 80px);display:flex;flex-direction:column;padding:0}
.modal-v2.modal-wide{max-width:760px}
.modal-head{display:flex;align-items:center;justify-content:space-between;gap:12px;padding:18px 22px;border-bottom:1px solid var(--border)}
.modal-head h2{margin:0;font-size:18px;overflow-wrap:anywhere}
.modal-body{padding:18px 22px;overflow-y:auto}
.modal-v2 .modal-body{flex:1 1 auto}
.main > .form-hint{margin-bottom:14px;max-width:72ch}
.modal-v2 .modal-actions{margin:0;padding:14px 22px;border-top:1px solid var(--border);flex-wrap:wrap}
.modal-text{font-size:14px;color:var(--text-2);line-height:1.6}

/* ============ TABLES & CARDS ============ */
.table-scroll{overflow-x:auto;border:1px solid var(--border);border-radius:var(--radius);margin-bottom:12px}
.data-table{width:100%;border-collapse:collapse;font-size:13px}
.data-table th{text-align:left;font-size:11px;text-transform:uppercase;letter-spacing:.5px;color:var(--text-3);background:var(--surface);padding:10px 12px;white-space:nowrap}
.data-table td{padding:10px 12px;border-top:1px solid var(--border);color:var(--text-2);vertical-align:middle}
.data-table th.num,.data-table td.num{text-align:right;font-variant-numeric:tabular-nums}
.data-table .td-empty{text-align:center;color:var(--text-3);padding:24px}
.row-actions{display:flex;gap:6px;justify-content:flex-end}

.card-list{display:flex;flex-direction:column;gap:8px}
.card-row{display:flex;align-items:center;gap:14px;padding:14px 16px;background:var(--surface);border:1px solid var(--border);border-radius:var(--radius);text-align:left;width:100%;font-family:var(--font);color:var(--text)}
.card-row.is-stale,.card-row.is-off{opacity:.65}
.card-button{cursor:pointer;transition:border-color var(--transition)}
.card-button:hover{border-color:var(--border-hover)}
.card-main{flex:1;min-width:0;display:flex;flex-direction:column;gap:5px}
.card-title{display:flex;align-items:center;gap:8px;flex-wrap:wrap;font-size:14px}
.card-sub{font-size:13px;color:var(--text-2);overflow-wrap:anywhere}
.card-actions{display:flex;gap:6px;flex-wrap:wrap;justify-content:flex-end}
.card-side{display:flex;flex-direction:column;align-items:flex-end;gap:6px}
.who{font-weight:600}

/* ============ PANELS, KPIs, CHARTS ============ */
.panel{background:var(--surface);border:1px solid var(--border);border-radius:var(--radius);padding:18px 20px;margin-bottom:16px;min-width:0}
.panel-title{font-size:15px;font-weight:700;margin-bottom:6px}
.panel-title.spaced{margin:24px 0 10px}
.kpi-grid{display:grid;grid-template-columns:repeat(auto-fit,minmax(min(100%,190px),1fr));gap:10px;margin-bottom:16px}
.kpi-grid-2{grid-template-columns:repeat(2,minmax(0,1fr))}
.kpi{background:var(--surface);border:1px solid var(--border);border-radius:var(--radius);padding:14px 16px;min-width:0}
.panel .kpi{background:var(--bg-2)}
.kpi-label{font-size:12px;color:var(--text-2);font-weight:600;display:flex;align-items:center;gap:6px;flex-wrap:wrap}
.kpi-value{font-size:24px;font-weight:800;letter-spacing:-.4px;margin-top:4px;font-variant-numeric:tabular-nums}
.kpi-pos{color:var(--green)}
.kpi-neg{color:var(--red)}
.kpi-hint{font-size:11.5px;color:var(--text-3);margin-top:4px;line-height:1.45}
.est-tag{font-size:10px;text-transform:uppercase;letter-spacing:.6px;padding:1px 6px;border-radius:4px;border:1px dashed var(--yellow);color:var(--yellow);cursor:help}
.panel .bar-row{grid-template-columns:minmax(120px,max-content) minmax(0,1fr) 48px}
.chart-grid-2{display:grid;grid-template-columns:repeat(auto-fit,minmax(min(100%,380px),1fr));gap:16px}
.facts{display:grid;grid-template-columns:max-content 1fr;gap:6px 18px;font-size:13px;margin:8px 0 14px}
.facts dt{color:var(--text-3)}
.facts dd{color:var(--text)}

.chart{width:100%}
.chart-svg{width:100%;height:auto;display:block;overflow:visible}
.chart-svg .chart-grid{stroke:var(--border);stroke-width:1}
.chart-svg .chart-axis{fill:var(--text-3);font-size:11px;font-family:var(--font)}
.chart-svg .chart-missing{fill:rgba(148,163,184,.08)}
.chart-legend{display:flex;gap:14px;flex-wrap:wrap;font-size:12px;color:var(--text-2);margin-top:6px}
.chart-legend i{display:inline-block;width:10px;height:10px;border-radius:2px;margin-right:6px;vertical-align:-1px}

/* ============ OVERVIEW WIDGETS ============ */
.widget-grid{display:flex;flex-direction:column;gap:18px}
.widget{min-width:0}
.widget-stats .stats{grid-template-columns:repeat(4,minmax(0,1fr))}
.widget .stats,.widget .growth-chart-wrap,.widget .quick-actions-wrap,.widget .mod-status-wrap{margin-bottom:0}
.widget-head{display:flex;align-items:center;justify-content:space-between;margin-bottom:10px}
.widget-head h3{font-size:15px;font-weight:700}
.widget-incidents .widget-body,.widget-applications .widget-body,.widget-modcases .widget-body,.widget-quick .widget-body{background:var(--surface);border:1px solid var(--border);border-radius:var(--radius);padding:16px 18px}
.widget-grid.is-customizing .widget{outline:1px dashed var(--border-hover);outline-offset:6px;border-radius:var(--radius)}
.widget-tools{display:flex;align-items:center;gap:6px;margin-bottom:8px;padding:6px 8px;border-radius:var(--radius-sm);background:var(--surface-2);font-size:13px}
.widget-grip{cursor:grab;color:var(--text-3);letter-spacing:-2px;user-select:none}
.widget-tools-title{flex:1;font-weight:600}
.widget.dragging{opacity:.4}
.widget.drop-target{outline-color:var(--accent) !important}
.hidden-widgets{display:flex;gap:8px;flex-wrap:wrap;align-items:center;margin-top:20px}
.widget-empty{font-size:13px;color:var(--text-3)}
.mini-list{list-style:none;display:flex;flex-direction:column}
.mini-list li{display:flex;align-items:center;gap:8px;padding:8px 0;border-top:1px solid var(--border);font-size:13px;min-width:0}
.mini-list li:first-child{border-top:0}
.mini-title{flex:1;min-width:0;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;color:var(--text)}
.mini-list time{font-size:12px;color:var(--text-3);white-space:nowrap}
.mini-stats{display:flex;gap:24px;flex-wrap:wrap;margin-bottom:10px}
.mini-stats div{display:flex;flex-direction:column}
.mini-stats strong{font-size:22px;font-weight:800;font-variant-numeric:tabular-nums}
.mini-stats span{font-size:12px;color:var(--text-3)}
.sev-strip{display:grid;grid-template-columns:repeat(4,1fr);gap:6px;margin-bottom:10px}
.sev-cell{padding:8px 10px;border-radius:var(--radius-sm);background:var(--bg-2);border-left:3px solid var(--text-3);display:flex;flex-direction:column}
.sev-cell strong{font-size:18px;font-variant-numeric:tabular-nums}
.sev-cell span{font-size:11px;color:var(--text-3)}
.sev-critical{border-left-color:var(--red)}
.sev-high{border-left-color:#fb923c}
.sev-medium{border-left-color:var(--yellow)}
.sev-low{border-left-color:var(--text-3)}

/* ============ PERMISSIONS ============ */
.perm-groups{display:grid;grid-template-columns:repeat(auto-fit,minmax(min(100%,260px),1fr));gap:12px}
.perm-group{border:1px solid var(--border);border-radius:var(--radius-sm);padding:10px 12px 12px;display:flex;flex-direction:column;gap:10px;min-width:0}
.perm-group legend{font-size:12px;font-weight:700;text-transform:uppercase;letter-spacing:.6px;color:var(--text-3);padding:0 4px}
.perm-item{display:flex;flex-direction:column;gap:2px}
.perm-item .form-hint{padding-left:24px}

/* ============ INCIDENTS & HISTORY ============ */
.timeline{list-style:none;display:flex;flex-direction:column;gap:8px}
.timeline-day{font-size:12px;font-weight:700;text-transform:uppercase;letter-spacing:.6px;color:var(--text-3);margin-top:10px}
.timeline-item{border-left:3px solid var(--text-3);border-radius:var(--radius-sm)}
.sev-edge-critical{border-left-color:var(--red)}
.sev-edge-high{border-left-color:#fb923c}
.sev-edge-medium{border-left-color:var(--yellow)}
.timeline-btn{width:100%;text-align:left;background:var(--surface);border:1px solid var(--border);border-left:0;border-radius:0 var(--radius-sm) var(--radius-sm) 0;padding:12px 14px;cursor:pointer;color:var(--text);font-family:var(--font);display:flex;flex-direction:column;gap:6px}
.timeline-btn:hover{border-color:var(--border-hover)}
.timeline-top{display:flex;align-items:center;gap:6px;flex-wrap:wrap}
.timeline-title{font-weight:700;font-size:14px;overflow-wrap:anywhere}
.timeline-meta{font-size:12px;color:var(--text-3)}
.incident-detail{display:flex;flex-direction:column;gap:14px}
.incident-desc{font-size:14px;color:var(--text-2);white-space:pre-wrap;line-height:1.6}
.sub-title{font-size:13px;font-weight:700;text-transform:uppercase;letter-spacing:.6px;color:var(--text-3);margin-top:6px}
.event-log{list-style:none;display:flex;flex-direction:column;border-left:2px solid var(--border);margin-left:6px}
.event{position:relative;padding:6px 0 10px 16px;font-size:13px}
.event::before{content:'';position:absolute;left:-6px;top:11px;width:10px;height:10px;border-radius:50%;background:var(--surface-3);border:2px solid var(--bg-2)}
.event-note::before{background:var(--accent)}
.event-status::before{background:var(--green)}
.event-head{display:flex;gap:4px;align-items:baseline;flex-wrap:wrap;color:var(--text-2)}
.event-body{margin-top:4px;color:var(--text);background:var(--surface);border:1px solid var(--border);border-radius:var(--radius-sm);padding:8px 10px;white-space:pre-wrap;overflow-wrap:anywhere}
.note-box{display:flex;flex-direction:column;gap:8px}

/* ============ RECRUITMENT ============ */
.answers{display:flex;flex-direction:column;gap:4px}
.answers dt{font-size:12px;font-weight:700;color:var(--text-3);margin-top:8px}
.answers dd{font-size:14px;color:var(--text);white-space:pre-wrap;overflow-wrap:anywhere;background:var(--surface);border:1px solid var(--border);border-radius:var(--radius-sm);padding:8px 10px}
.question-list{display:flex;flex-direction:column;gap:8px}
.question-row{display:grid;grid-template-columns:24px minmax(0,1fr) 150px auto 36px;gap:8px;align-items:center}
.q-num{font-weight:700;color:var(--text-3);text-align:center}

/* ============ REPORTS, WORKFLOWS, TEMPLATES ============ */
.report-summary{display:flex;gap:14px;flex-wrap:wrap;align-items:baseline;font-size:13px;color:var(--text-2);margin-bottom:10px}
.builder-block{border:1px solid var(--border);border-radius:var(--radius-sm);padding:12px;display:flex;flex-direction:column;gap:10px;background:var(--bg)}
.builder-head{display:flex;align-items:center;gap:10px;flex-wrap:wrap}
.builder-head select{flex:1;min-width:200px}
.step-dot{width:22px;height:22px;border-radius:50%;background:var(--accent-soft);color:var(--accent-light);font-size:12px;font-weight:800;display:inline-flex;align-items:center;justify-content:center}
.builder-row{display:grid;grid-template-columns:minmax(150px,220px) minmax(0,1fr) 36px;gap:8px;align-items:center}
.builder-row-top{align-items:start}
.builder-fields{display:flex;flex-direction:column;gap:6px;min-width:0}
.section-checks{display:grid;grid-template-columns:repeat(auto-fit,minmax(min(100%,260px),1fr));gap:8px;margin-top:10px}

/* ============ SETTINGS ============ */
.swatches{display:flex;gap:8px;flex-wrap:wrap;align-items:center}
.swatch{width:34px;height:34px;border-radius:50%;border:2px solid transparent;cursor:pointer;box-shadow:inset 0 0 0 2px rgba(0,0,0,.25)}
.swatch.is-on{border-color:var(--text)}
.swatch-default{width:auto;padding:0 12px;border-radius:999px;background:linear-gradient(135deg,#8b5cf6,#c084fc);color:#fff;font:600 12px var(--font)}
.color-input{width:40px;height:34px;border:1px solid var(--border);border-radius:var(--radius-sm);background:transparent;cursor:pointer;padding:2px}

/* ============ SERVER PICKER & SIDEBAR BUTTONS ============ */
.server-cards{display:grid;grid-template-columns:repeat(auto-fill,minmax(min(100%,240px),1fr));gap:10px}
.server-card{display:flex;align-items:center;gap:12px;padding:14px;background:var(--surface);border:1px solid var(--border);border-radius:var(--radius);color:var(--text);cursor:pointer;text-align:left;font-family:var(--font)}
.server-card:hover{border-color:var(--border-hover)}
.server-card img,.server-card .no-icon{width:40px;height:40px;border-radius:50%;flex-shrink:0}
.server-card .no-icon{background:var(--surface-2);display:flex;align-items:center;justify-content:center;font-weight:700;color:var(--accent)}
.server-card .gi-name{font-weight:600;font-size:14px}
.server-card .gi-sub{font-size:12px;color:var(--text-3)}
.guild-list li,.nav-list li{list-style:none}
button.guild-item,button.nav-item{width:100%;background:transparent;border:1px solid transparent;color:var(--text-2);font-family:var(--font);text-align:left}
button.guild-item{color:var(--text)}
button.guild-item.active{background:var(--accent-soft);border-color:var(--border-hover)}
button.nav-item.active{color:var(--accent-light);background:var(--accent-soft)}
.main{outline:none}

/* ============ PUBLIC STATUS PAGE ============ */
.status-page{max-width:820px;margin:0 auto;padding:40px 20px 60px;display:flex;flex-direction:column;gap:28px}
.status-hero{display:flex;align-items:center;gap:16px;padding:22px 24px;border-radius:var(--radius-lg);border:1px solid var(--border);background:var(--surface)}
.status-hero h1{font-size:22px;font-weight:800}
.status-hero p{font-size:13px;color:var(--text-3);margin-top:2px}
.status-dot{width:14px;height:14px;border-radius:50%;flex-shrink:0;background:var(--green);box-shadow:0 0 0 6px var(--green-soft)}
.status-degraded .status-dot{background:var(--yellow);box-shadow:0 0 0 6px rgba(251,191,36,.15)}
.status-maintenance .status-dot{background:#60a5fa;box-shadow:0 0 0 6px rgba(96,165,250,.15)}
.status-outage .status-dot{background:var(--red);box-shadow:0 0 0 6px var(--red-soft)}
.status-section{display:flex;flex-direction:column;gap:12px}
.status-section h2{font-size:16px;font-weight:700}
.status-section-head{display:flex;justify-content:space-between;align-items:baseline;gap:12px}
.status-component{background:var(--surface);border:1px solid var(--border);border-radius:var(--radius);padding:14px 16px;display:flex;flex-direction:column;gap:10px}
.status-component-head{display:flex;align-items:center;gap:10px;flex-wrap:wrap}
.status-component-head strong{flex:1;min-width:140px}
.uptime-bars{display:grid;grid-template-columns:repeat(90,1fr);gap:2px;height:30px}
.ub{border-radius:2px;background:var(--surface-3)}
.ub-up{background:var(--green)}
.ub-partial{background:var(--yellow)}
.ub-down{background:var(--red)}
.ub-nodata{background:var(--surface-2)}
.uptime-axis{display:flex;justify-content:space-between}
.notice-card{background:var(--surface);border:1px solid var(--border);border-left:3px solid #60a5fa;border-radius:var(--radius-sm);padding:14px 16px;display:flex;flex-direction:column;gap:6px}
.notice-card.notice-incident{border-left-color:var(--red)}
.notice-card h3{font-size:15px}
.notice-card p{font-size:14px;color:var(--text-2);white-space:pre-wrap}

/* ============ RESPONSIVE ============ */
.drawer-backdrop{display:none}
@media(max-width:1100px){
  .main{padding:28px 24px}
}
@media(max-width:860px){
  .mobile-menu-btn{display:inline-flex;align-items:center;margin-left:-8px}
  .nav-left{gap:8px}
  .navbar{padding:0 12px}
  .user-pill .name{display:none}
  .user-pill{padding:4px}
  .lang-picker{padding-left:8px}
  .lang-select{max-width:86px}
  .dash{flex-direction:row}
  .sidebar{position:fixed;z-index:150;top:64px;bottom:0;left:0;width:min(86vw,300px);height:auto;max-height:none;border-right:1px solid var(--border);border-bottom:0;transform:translateX(-105%);transition:transform .22s ease;visibility:hidden}
  body.nav-open .sidebar{transform:none;visibility:visible;box-shadow:12px 0 40px rgba(0,0,0,.5)}
  .sidebar-section:first-child .guild-list{flex-direction:column;overflow:visible}
  body.nav-open .drawer-backdrop{display:block;position:fixed;inset:64px 0 0 0;background:rgba(3,3,10,.6);z-index:140}
  body.nav-open{overflow:hidden}
  .main{padding:20px 16px;width:100%}
  .form-grid-3{grid-template-columns:1fr}
  .builder-row{grid-template-columns:1fr 36px}
  .builder-row > :nth-child(2){grid-column:1 / -1;grid-row:2}
}
@media(max-width:600px){
  .page-header h1{font-size:21px}
  .form-grid-2{grid-template-columns:1fr}
  .toolbar .input{min-width:0;width:100%;flex-basis:100%}
  .toolbar .form-field{flex:1 1 140px}
  .export-actions{width:100%}
  .export-actions .btn{flex:1}
  .card-row{flex-wrap:wrap;align-items:flex-start}
  .card-actions,.card-side{width:100%;justify-content:flex-start;flex-direction:row;align-items:center}
  .question-row{grid-template-columns:24px minmax(0,1fr) 36px}
  .question-row select,.question-row .check-row{grid-column:2 / 3}
  .sev-strip{grid-template-columns:repeat(2,1fr)}
  .stats,.widget-stats .stats{grid-template-columns:1fr 1fr}
  .modal-overlay{padding:0;align-items:stretch}
  .modal-v2,.modal-v2.modal-wide{max-width:none;width:100%;max-height:none;min-height:100dvh;border-radius:0;border:0}
  .modal-head{position:sticky;top:0;background:var(--bg-2);z-index:1}
  .modal-v2 .modal-actions{position:sticky;bottom:0;background:var(--bg-2)}
  .modal-v2 .modal-actions .btn{flex:1}
  .segmented{width:100%;overflow-x:auto}
  .segmented button{flex:1;white-space:nowrap}
  /* Tables become stacked cards; each cell shows its column name. */
  .table-scroll{border:0;overflow:visible}
  .data-table thead{display:none}
  .data-table,.data-table tbody,.data-table tr,.data-table td{display:block;width:100%}
  .data-table tr{background:var(--surface);border:1px solid var(--border);border-radius:var(--radius-sm);padding:8px 12px;margin-bottom:8px}
  .data-table td{border:0;padding:4px 0;display:flex;justify-content:space-between;align-items:center;gap:12px;text-align:right}
  .data-table td::before{content:attr(data-label);font-size:11px;text-transform:uppercase;letter-spacing:.4px;color:var(--text-3);text-align:left;flex-shrink:0}
  .data-table td[data-label=""]::before{content:none}
  .data-table td.td-empty{justify-content:center}
  .row-actions{justify-content:flex-start}
  .uptime-bars{height:24px;gap:1px}
  .status-hero{padding:16px}
  .facts{grid-template-columns:1fr}
  .facts dd{margin-bottom:6px}
  .growth-chart-header{flex-direction:column;align-items:flex-start}
}
@media(max-width:480px){
  .brand span{display:none}
  .nav-right{gap:8px}
  .nav-right .user-pill{display:none}
  .lang-picker{padding:0 2px 0 8px;height:32px}
  .lang-select{max-width:78px;font-size:12px}
  .nav-right .btn-sm{padding:6px 10px}
}
@media(prefers-reduced-motion:reduce){
  *,*::before,*::after{animation-duration:.01ms !important;animation-iteration-count:1 !important;transition-duration:.01ms !important;scroll-behavior:auto !important}
  .reveal{opacity:1;transform:none}
}

/* ── Sticky roles ── */
.toolbar-wrap{align-items:center}
.form-stack{display:flex;flex-direction:column;gap:12px}
.form-stack .sub-title{margin-top:10px}
.plain-list{margin:6px 0 0 18px;display:flex;flex-direction:column;gap:6px;font-size:14px;color:var(--text-2);line-height:1.5}
.sticky-card{align-items:flex-start}
.sticky-avatar{width:28px;height:28px;border-radius:50%;flex-shrink:0;object-fit:cover;background:var(--surface-2)}
.sticky-roles{display:flex;flex-wrap:wrap;gap:6px}
.sticky-role{display:inline-flex;align-items:center;gap:6px;padding:3px 4px 3px 9px;border-radius:999px;background:var(--surface-2);border:1px solid var(--border);font-size:12.5px;color:var(--text);max-width:100%}
.sticky-role > span:nth-child(2){overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.sticky-role.is-off{color:var(--text-3);border-style:dashed}
.sticky-role.is-off > span:nth-child(2){text-decoration:line-through}
.sticky-role .role-dot{width:8px;height:8px;border-radius:50%;flex-shrink:0}
.sticky-nick{padding-right:9px;color:var(--text-2)}
.sticky-role-x{display:inline-grid;place-items:center;width:18px;height:18px;border-radius:50%;border:0;background:transparent;color:var(--text-3);cursor:pointer;font-size:14px;line-height:1}
.sticky-role-x:hover,.sticky-role-x:focus-visible{background:var(--red-soft);color:var(--red);outline:none}
.sticky-card .card-side .section-actions{margin:0;justify-content:flex-end}
.sticky-how{margin-top:16px}

/* ── Ticket inbox ── */
.tix-avatar{width:36px;height:36px;border-radius:50%;flex-shrink:0;object-fit:cover;background:var(--surface-2)}
.tix-avatar-blank{display:inline-block}
.tix-preview{white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.tix-head{display:flex;align-items:flex-start;gap:14px;flex-wrap:wrap;margin-bottom:14px}
.tix-head-main{flex:1;min-width:220px;display:flex;flex-direction:column;gap:6px}
.tix-head-main h2{font-size:18px;font-weight:700;overflow-wrap:anywhere}
.tix-head-actions{margin:0}
.tix-thread{display:flex;flex-direction:column;border:1px solid var(--border);border-radius:var(--radius);background:var(--surface);overflow:hidden}
.tix-log{display:flex;flex-direction:column;gap:14px;padding:18px;height:min(60vh,560px);overflow-y:auto;background:var(--bg-2)}
.tix-msg{display:flex;gap:10px;align-items:flex-start;max-width:min(720px,100%)}
.tix-msg.from-staff{align-self:flex-end;flex-direction:row-reverse}
.tix-bubble{min-width:0;padding:9px 13px;border-radius:14px;background:var(--surface-2);border:1px solid var(--border)}
.tix-msg.from-staff .tix-bubble{background:var(--accent-soft);border-color:var(--border-hover)}
.tix-meta{display:flex;align-items:center;gap:8px;flex-wrap:wrap;margin-bottom:3px;font-size:13px}
.tix-via{font-size:11px;color:var(--accent-light)}
.tix-text{font-size:14px;line-height:1.5;white-space:pre-wrap;overflow-wrap:anywhere}
.tix-mention{color:var(--accent-light);background:var(--accent-soft);border-radius:4px;padding:0 3px}
.tix-files{list-style:none;margin-top:6px;display:flex;flex-direction:column;gap:3px;font-size:13px}
.tix-event{align-self:center;font-size:12px;color:var(--text-3);text-align:center}
.tix-empty{align-self:center;margin:auto}
.tix-composer{display:flex;flex-direction:column;gap:8px;padding:12px;border-top:1px solid var(--border)}
.tix-input{resize:vertical;min-height:72px;font-family:var(--font)}
.tix-composer-row{display:flex;align-items:center;gap:12px;flex-wrap:wrap}
.tix-composer-row .form-hint{flex:1;min-width:160px}
.tix-count{font-variant-numeric:tabular-nums}
.tix-thread > .notice{margin:12px}
@media(max-width:640px){
  .tix-log{padding:12px;height:62vh}
  .tix-msg .tix-avatar{width:28px;height:28px}
  .sticky-card{flex-direction:column}
  .sticky-card .card-side{align-items:flex-start;width:100%}
  .sticky-card .card-side .section-actions{justify-content:flex-start}
}

/* ── Overview welcome ── */
.ov-hero{margin-bottom:20px}
.ov-summary{display:flex;flex-direction:column;gap:16px}
.ov-tiles{display:grid;grid-template-columns:repeat(auto-fit,minmax(200px,1fr));gap:12px}
.ov-tile{display:flex;flex-direction:column;gap:6px;padding:16px 18px;background:var(--surface);border:1px solid var(--border);border-radius:var(--radius);text-align:left;font-family:var(--font);color:var(--text);min-width:0}
.ov-tile-link{cursor:pointer;transition:border-color var(--transition)}
.ov-tile-link:hover,.ov-tile-link:focus-visible{border-color:var(--border-hover);outline:none}
.ov-label{display:inline-flex;align-items:center;gap:7px;font-size:12px;font-weight:600;text-transform:uppercase;letter-spacing:.5px;color:var(--text-3)}
.ov-value{font-size:28px;font-weight:800;letter-spacing:-.5px;font-variant-numeric:tabular-nums;line-height:1.1}
.ov-foot{font-size:12.5px;color:var(--text-2)}
.ov-foot.is-warn{color:var(--yellow)}
.ov-dot{width:8px;height:8px;border-radius:50%;background:var(--green);box-shadow:0 0 0 3px var(--green-soft)}
.ov-meter{height:6px;border-radius:999px;background:var(--surface-2);overflow:hidden;margin-top:4px}
.ov-meter span{display:block;height:100%;background:var(--green);border-radius:inherit}
.ov-growth,.ov-modlog{background:var(--surface);border:1px solid var(--border);border-radius:var(--radius);padding:16px 18px}
.ov-section-title{font-size:15px;font-weight:700;margin-bottom:12px}
.ov-periods{display:grid;grid-template-columns:repeat(5,minmax(0,1fr));gap:1px;background:var(--border);border:1px solid var(--border);border-radius:var(--radius-sm);overflow:hidden}
.ov-period{display:flex;flex-direction:column;gap:4px;padding:12px 14px;background:var(--bg-2);min-width:0}
.ov-period-total{background:var(--surface-2)}
.ov-change{font-size:22px;font-weight:800;font-variant-numeric:tabular-nums}
.ov-change.up{color:var(--green)}
.ov-change.down{color:var(--red)}
.ov-since{color:var(--text-3)}
.ov-modlist{list-style:none;display:flex;flex-direction:column}
.ov-modlist li{display:flex;align-items:center;gap:10px;padding:9px 0;border-top:1px solid var(--border);font-size:13.5px}
.ov-modlist li:first-child{border-top:0}
.ov-mod-main{flex:1;min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.ov-mod-reason{color:var(--text-2)}
.ov-mod-reason::before{content:' · '}
@media(max-width:900px){.ov-periods{grid-template-columns:repeat(2,minmax(0,1fr))}.ov-period-total{grid-column:1/-1}}
@media(max-width:480px){.ov-value{font-size:24px}.ov-modlist li{flex-wrap:wrap}.ov-mod-main{white-space:normal}}
.widget,.growth-chart-wrap{min-width:0}
.growth-canvas{display:block;max-width:100%}

/* ── Member growth chart ── */
.mg{background:var(--surface);border:1px solid var(--border);border-radius:var(--radius);padding:18px 20px 14px;min-width:0}
.mg-head{display:flex;align-items:flex-start;justify-content:space-between;gap:14px;flex-wrap:wrap;margin-bottom:10px}
.mg-heading{display:flex;flex-direction:column;gap:6px;min-width:0}
.mg-title{font-size:15px;font-weight:700}
.mg-summary{display:flex;align-items:baseline;gap:10px;flex-wrap:wrap;min-height:24px}
.mg-total{font-size:22px;font-weight:800;letter-spacing:-.4px;font-variant-numeric:tabular-nums}
.mg-net{font-size:13px;font-weight:700;padding:2px 8px;border-radius:999px;background:var(--surface-2);color:var(--text-2);font-variant-numeric:tabular-nums}
.mg-net.up{background:var(--green-soft);color:var(--green)}
.mg-net.down{background:var(--red-soft);color:var(--red)}
.mg-sub{font-size:13px;color:var(--text-2)}
.mg-filters{flex-shrink:0}
.mg-legend{display:flex;gap:16px;flex-wrap:wrap;font-size:12px;color:var(--text-2);margin-bottom:6px}
.mg-legend span{display:inline-flex;align-items:center;gap:6px}
.mg-key{display:inline-block;width:10px;height:10px;border-radius:3px;flex-shrink:0}
.mg-key-line{width:16px;height:3px;border-radius:2px;background:linear-gradient(90deg,var(--accent-light),var(--accent))}
.mg-key-join,.mg-key-up{background:var(--green)}
.mg-key-leave,.mg-key-down{background:var(--red)}
.mg-key-total{background:var(--accent)}
.mg-key-none{background:var(--text-3)}
.mg-plot{position:relative;min-height:270px;outline:none;border-radius:var(--radius-sm);touch-action:pan-y;transition:opacity .25s ease;user-select:none}
.mg-plot:focus-visible{box-shadow:0 0 0 2px var(--accent-soft),0 0 0 3px var(--accent)}
.mg-plot.is-loading{opacity:.45}
.mg-svg{display:block;max-width:100%;overflow:visible}
.mg-grid line{stroke:rgba(255,255,255,.055);stroke-width:1}
.mg-grid .mg-zero{stroke:rgba(255,255,255,.12)}
.mg-axis{fill:var(--text-3);font-size:11px;font-family:var(--font);font-variant-numeric:tabular-nums}
.mg-before{fill:rgba(255,255,255,.025)}
.mg-gap{opacity:.9}
.mg-gap-line{stroke:rgba(255,255,255,.07);stroke-width:2}
.mg-shade-label{fill:var(--text-3);font-size:11px;font-family:var(--font)}
.mg-stroke{fill:none;stroke-width:2.5;stroke-linecap:round;stroke-linejoin:round;filter:drop-shadow(0 4px 10px rgba(139,92,246,.35))}
.mg-solo{fill:var(--accent)}
.mg-bar-join{fill:var(--green);opacity:.75}
.mg-bar-leave{fill:var(--red);opacity:.75}
.mg-bar rect{transition:opacity .15s ease}
.mg-svg.is-hovering .mg-bar rect{opacity:.28}
.mg-svg.is-hovering .mg-bar.is-active rect{opacity:1}
.mg-cross{opacity:0;transition:transform .14s cubic-bezier(.2,.7,.3,1),opacity .15s ease}
.mg-svg.is-hovering .mg-cross{opacity:1}
.mg-cross-line{stroke:rgba(255,255,255,.22);stroke-width:1;stroke-dasharray:3 4}
.mg-dot{opacity:0;transition:transform .14s cubic-bezier(.2,.7,.3,1),opacity .15s ease;pointer-events:none}
.mg-dot.is-on{opacity:1}
.mg-dot-halo{fill:var(--green);opacity:.18}
.mg-dot-core{fill:var(--bg);stroke:var(--green);stroke-width:2.5}
.mg-dot.down .mg-dot-halo{fill:var(--red)}
.mg-dot.down .mg-dot-core{stroke:var(--red)}
.mg-tip{position:absolute;left:0;top:0;min-width:190px;max-width:260px;padding:11px 13px;border-radius:12px;background:rgba(12,12,26,.94);border:1px solid rgba(139,92,246,.28);box-shadow:0 12px 32px rgba(0,0,0,.45);backdrop-filter:blur(8px);font-size:12.5px;pointer-events:none;opacity:0;transition:transform .14s cubic-bezier(.2,.7,.3,1),opacity .15s ease;z-index:2}
.mg-tip.is-on{opacity:1}
.mg-tip-date{font-weight:700;font-size:12.5px;margin-bottom:8px;color:var(--text)}
.mg-tip dl{display:grid;grid-template-columns:1fr auto;gap:5px 16px;margin:0}
.mg-tip dt{display:inline-flex;align-items:center;gap:7px;color:var(--text-2)}
.mg-tip dt .mg-key{width:7px;height:7px;border-radius:50%}
.mg-tip dd{margin:0;text-align:right;font-weight:700;font-variant-numeric:tabular-nums}
.mg-tip dd.is-join,.mg-tip dd.is-up{color:var(--green)}
.mg-tip dd.is-leave,.mg-tip dd.is-down{color:var(--red)}
.mg-tip dl dt:last-of-type,.mg-tip dl dd:last-of-type{padding-top:6px;border-top:1px solid rgba(255,255,255,.08)}
.mg-tip-empty{color:var(--text-2);margin:0}
.mg-empty{display:flex;flex-direction:column;align-items:center;justify-content:center;gap:6px;min-height:240px;text-align:center;color:var(--text-2);font-size:13.5px;padding:0 20px}
.mg-empty strong{color:var(--text);font-size:15px}
.mg-note{font-size:12px;color:var(--text-3);margin-top:8px;line-height:1.5}
.mg-enter .mg-stroke{stroke-dasharray:1;stroke-dashoffset:1;animation:mg-draw .9s cubic-bezier(.4,0,.2,1) forwards}
.mg-enter .mg-area{opacity:0;animation:mg-fade .7s ease .25s forwards}
.mg-enter .mg-bar rect{transform-box:fill-box;transform-origin:center bottom;transform:scaleY(0);animation:mg-grow .5s cubic-bezier(.2,.7,.3,1) forwards;animation-delay:calc(min(var(--i),60) * 8ms)}
.mg-enter .mg-bar .mg-bar-leave{transform-origin:center top}
@keyframes mg-draw{to{stroke-dashoffset:0}}
@keyframes mg-fade{to{opacity:1}}
@keyframes mg-grow{to{transform:scaleY(1)}}
@media(max-width:560px){.mg{padding:14px 12px 10px}.mg-head{flex-direction:column}.mg-filters{width:100%;display:flex}.mg-filters button{flex:1;padding-left:4px;padding-right:4px;font-size:12px}.mg-tip{min-width:170px}}
@media(prefers-reduced-motion:reduce){.mg-enter .mg-stroke,.mg-enter .mg-area,.mg-enter .mg-bar rect{animation:none;stroke-dashoffset:0;opacity:1;transform:none}.mg-cross,.mg-dot,.mg-tip{transition:none}}

/* ── Owner panel ── */
.op-private{display:inline-flex;align-items:center;gap:6px;font-size:12px;font-weight:600;color:var(--accent-light);padding:5px 10px;border:1px solid var(--border-hover);border-radius:999px;background:var(--accent-soft)}
.op-lock{width:8px;height:8px;border-radius:2px;background:var(--accent-light)}
.op-tabs{display:flex;gap:4px;border-bottom:1px solid var(--border);margin-bottom:18px;overflow-x:auto}
.op-tabs a{padding:10px 14px;font-size:14px;font-weight:600;color:var(--text-2);border-bottom:2px solid transparent;margin-bottom:-1px;white-space:nowrap}
.op-tabs a:hover{color:var(--text)}
.op-tabs a.active{color:var(--text);border-bottom-color:var(--accent)}
.op-body{display:flex;flex-direction:column;gap:16px;min-width:0}
.op-meta{font-size:12.5px;color:var(--text-3);display:flex;align-items:center;gap:6px;flex-wrap:wrap}
.op-dot{display:inline-block;width:7px;height:7px;border-radius:50%;background:var(--text-3);margin-left:4px;vertical-align:middle}
.op-dot.on{background:var(--green);box-shadow:0 0 0 3px var(--green-soft)}
.op-cards{display:grid;grid-template-columns:minmax(0,1fr);gap:14px}
@media(min-width:700px){.op-cards{grid-template-columns:repeat(2,minmax(0,1fr))}}
@media(min-width:1500px){.op-cards{grid-template-columns:repeat(4,minmax(0,1fr))}}
.op-cards.op-cards-small{grid-template-columns:minmax(0,1fr)}
@media(min-width:520px){.op-cards.op-cards-small{grid-template-columns:repeat(3,minmax(0,1fr))}}
.op-card{display:flex;flex-direction:column;gap:8px;padding:18px;background:var(--surface);border:1px solid var(--border);border-radius:var(--radius);min-width:0}
.op-label{font-size:12px;font-weight:600;text-transform:uppercase;letter-spacing:.5px;color:var(--text-3)}
.op-value{font-size:30px;font-weight:800;letter-spacing:-.6px;font-variant-numeric:tabular-nums;line-height:1.1}
.op-rows{display:flex;flex-direction:column;border-top:1px solid var(--border);margin-top:4px}
.op-row{display:flex;justify-content:space-between;align-items:baseline;gap:10px;padding:7px 0;border-bottom:1px solid rgba(255,255,255,.04);font-size:13px}
.op-row span:first-child{color:var(--text-2)}
.op-row strong{font-variant-numeric:tabular-nums;display:inline-flex;align-items:baseline;gap:6px;white-space:nowrap}
.op-change{font-size:11px;font-weight:700;padding:1px 6px;border-radius:999px;background:var(--surface-2);color:var(--text-2)}
.op-change.up{background:var(--green-soft);color:var(--green)}
.op-change.down{background:var(--red-soft);color:var(--red)}
.is-up{color:var(--green)}
.is-down{color:var(--red)}
.op-foot{font-size:12px;color:var(--text-3);line-height:1.5;margin-top:auto}
.op-split{display:grid;grid-template-columns:minmax(0,1.6fr) minmax(0,1fr);gap:16px}
.op-split > .panel{margin-bottom:0}
.op-panel-head{display:flex;align-items:center;justify-content:space-between;gap:10px;flex-wrap:wrap;margin-bottom:12px}
.op-gap{margin-bottom:10px}
.op-gap:not(:first-child){margin-top:16px}
.op-sub{font-size:12.5px;color:var(--text-3)}
.op-bars{list-style:none;display:flex;flex-direction:column;gap:8px}
.op-bars li{display:grid;grid-template-columns:minmax(0,9rem) minmax(0,1fr) auto;align-items:center;gap:10px;font-size:13px}
.op-bar-label{overflow:hidden;text-overflow:ellipsis;white-space:nowrap;font-family:ui-monospace,SFMono-Regular,Menlo,Consolas,monospace;font-size:12.5px;color:var(--text)}
.op-bar-track{height:8px;border-radius:999px;background:var(--surface-2);overflow:hidden}
.op-bar-fill{display:block;height:100%;border-radius:inherit;background:linear-gradient(90deg,var(--accent),var(--accent-light))}
.op-bar-value{font-variant-numeric:tabular-nums;font-weight:700;text-align:right}
.op-list{list-style:none;display:flex;flex-direction:column}
.op-list li{display:flex;align-items:center;gap:10px;padding:8px 0;border-top:1px solid var(--border);font-size:13.5px}
.op-list li:first-child{border-top:0}
.op-link{display:inline-flex;align-items:center;gap:8px;flex:1;min-width:0;background:none;border:0;color:var(--text);font:inherit;cursor:pointer;text-align:left;padding:0}
.op-link span{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.op-link:hover span,.op-link:focus-visible span{color:var(--accent-light)}
.op-icon{border-radius:50%;flex-shrink:0;object-fit:cover;background:var(--surface-2)}
.op-icon-blank{display:inline-grid;place-items:center;font-size:12px;font-weight:700;color:var(--text-2)}
.op-defs summary{cursor:pointer;font-weight:600;font-size:14px}
.op-defs[open] summary{margin-bottom:10px}
.op-rangebar{display:flex;flex-direction:column;gap:10px}
.op-ranges{align-self:flex-start;max-width:100%;overflow-x:auto}
.op-custom{display:flex;align-items:flex-end;gap:10px;flex-wrap:wrap}
.op-custom[hidden]{display:none}
.op-custom .form-field{min-width:150px}
.op-summary{display:grid;grid-template-columns:repeat(auto-fit,minmax(200px,1fr));gap:12px}
.op-summary > div{padding:12px 16px;background:var(--surface);border:1px solid var(--border);border-radius:var(--radius);display:flex;flex-direction:column;gap:4px}
.op-summary strong{font-size:22px;font-weight:800;font-variant-numeric:tabular-nums}
.op-summary small{color:var(--text-2);font-size:12.5px}
.op-chart{margin:0}
.op-table tbody tr.op-row-link{cursor:pointer;transition:background var(--transition)}
.op-table tbody tr.op-row-link:hover,.op-table tbody tr.op-row-link:focus-visible{background:var(--surface-2);outline:none}
.op-server{display:flex;align-items:center;gap:10px;min-width:180px}
.op-server strong{display:block;color:var(--text)}
.op-id{font-family:ui-monospace,SFMono-Regular,Menlo,Consolas,monospace;font-size:11.5px;color:var(--text-3)}
.op-server-head{display:flex;align-items:center;gap:16px;flex-wrap:wrap}
.op-server-head h2{font-size:22px;font-weight:800;margin-bottom:6px;overflow-wrap:anywhere}
.mg-tip dt.is-focus,.mg-tip dd.is-focus{color:var(--text);font-weight:700}
.mg-tip-note{margin-top:8px;font-size:11.5px;color:var(--text-3);line-height:1.4}
@media(max-width:900px){.op-split{grid-template-columns:minmax(0,1fr)}}
@media(max-width:640px){.op-value{font-size:26px}.op-bars li{grid-template-columns:minmax(0,7rem) minmax(0,1fr) auto}
  .op-table thead{display:none}.op-table tr{display:grid;grid-template-columns:1fr 1fr;padding:10px 12px;border-top:1px solid var(--border)}
  .op-table td{border:0;padding:3px 0}.op-table td:first-child{grid-column:1/-1;padding-bottom:6px}
  .op-table td.num{text-align:left}.op-table td::before{content:attr(data-label);display:block;font-size:10.5px;text-transform:uppercase;letter-spacing:.4px;color:var(--text-3)}
  .op-table td:first-child::before{content:none}}
.mg-stroke-open{fill:none;stroke:var(--accent-light);stroke-width:2.5;stroke-linecap:round;stroke-dasharray:4 5;opacity:.8}
.op-ranges{flex-wrap:wrap}

/* ── Owner controls ── */
.op-facts{display:grid;grid-template-columns:repeat(auto-fit,minmax(150px,1fr));gap:10px;margin-bottom:6px}
.op-facts > div{display:flex;flex-direction:column;gap:3px;padding:10px 12px;border-radius:var(--radius-sm);background:var(--bg-2);border:1px solid var(--border);min-width:0}
.op-facts span{font-size:11.5px;text-transform:uppercase;letter-spacing:.4px;color:var(--text-3)}
.op-facts strong{font-size:15px;font-variant-numeric:tabular-nums;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.op-compose-grid{display:grid;grid-template-columns:minmax(0,1.2fr) minmax(0,1fr);gap:20px;align-items:start}
.op-compose textarea{resize:vertical;min-height:140px;font-family:var(--font);line-height:1.5}
.op-compose .form-grid{display:grid;gap:12px}
.op-compose .form-grid-2{grid-template-columns:repeat(2,minmax(0,1fr))}
.op-compose .form-field[hidden]{display:none}
.op-preview-col{display:flex;flex-direction:column;gap:10px;min-width:0}
.op-embed-wrap{display:flex;flex-direction:column;align-items:flex-start;gap:8px;padding:14px;border-radius:var(--radius-sm);background:#313338}
.op-embed{width:100%;max-width:520px;background:#2b2d31;border-left:4px solid var(--accent);border-radius:4px;padding:10px 14px 12px;color:#dbdee1;font-size:14px;display:flex;flex-direction:column;gap:6px}
.op-embed-author{display:flex;align-items:center;gap:8px;font-size:12.5px;font-weight:600;color:#f2f3f5}
.op-embed-avatar{display:inline-grid;place-items:center;width:20px;height:20px;border-radius:50%;background:var(--accent);color:#fff;font-size:11px;font-weight:800}
.op-embed-title{font-weight:700;color:#f2f3f5;font-size:15px;overflow-wrap:anywhere}
.op-embed-body{white-space:pre-wrap;overflow-wrap:anywhere;line-height:1.45}
.op-embed-foot{font-size:11.5px;color:#949ba4}
.op-embed-button{display:inline-flex;padding:6px 14px;border-radius:4px;background:#4e5058;color:#fff;font-size:13.5px;font-weight:500}
.op-audience{font-size:13.5px;color:var(--text-2);display:flex;flex-direction:column;gap:6px}
.op-audience strong{color:var(--text)}
.op-audience summary{cursor:pointer;color:var(--text-2)}
.op-ann-list{list-style:none;display:flex;flex-direction:column}
.op-ann-list > li{display:flex;align-items:center;justify-content:space-between;gap:14px;flex-wrap:wrap;padding:12px 0;border-top:1px solid var(--border)}
.op-ann-list > li:first-child{border-top:0}
.op-ann-main{flex:1;min-width:240px;display:flex;flex-direction:column;gap:6px}
.op-ann-list .section-actions{margin:0}
.op-progress{height:6px;border-radius:999px;background:var(--surface-2);overflow:hidden;max-width:420px}
.op-progress span{display:block;height:100%;background:linear-gradient(90deg,var(--accent),var(--green));border-radius:inherit;transition:width .4s ease}
.op-detail-text{padding:12px 14px;border-radius:var(--radius-sm);background:var(--bg-2);border:1px solid var(--border);margin-bottom:14px;font-size:14px}
@media(max-width:900px){.op-compose-grid{grid-template-columns:minmax(0,1fr)}}
@media(max-width:560px){.op-compose .form-grid-2{grid-template-columns:minmax(0,1fr)}}
/* Workflow builder: a vertical flow (trigger → conditions → steps) beside a palette of steps to click or drag in. */
.wf-builder{display:grid;grid-template-columns:minmax(0,1fr) 210px;gap:16px;align-items:start}
.wf-canvas{display:flex;flex-direction:column;min-width:0}
.wf-node{border:1px solid var(--border);border-radius:var(--radius-sm);padding:12px;display:flex;flex-direction:column;gap:10px;background:var(--bg)}
.wf-trigger{border-color:var(--accent-soft)}
.wf-node-head{display:flex;align-items:center;gap:10px;flex-wrap:wrap}
.wf-node-head select{flex:1;min-width:180px}
.wf-then{margin-bottom:8px}
.wf-node-icon{width:26px;height:26px;border-radius:8px;background:var(--accent-soft);color:var(--accent-light);display:inline-flex;align-items:center;justify-content:center;flex:none}
.wf-node-icon svg{width:15px;height:15px}
.wf-link{width:2px;height:16px;background:var(--border-strong);margin-left:24px}
.wf-flow{list-style:none;margin:0;padding:0 0 0 12px;border-left:2px solid var(--border-strong);margin-left:12px;display:flex;flex-direction:column;gap:10px}
.wf-step{position:relative;border:1px solid var(--border);border-radius:var(--radius-sm);padding:10px 12px;background:var(--surface);display:flex;flex-direction:column;gap:8px;transition:border-color var(--transition),opacity var(--transition)}
.wf-step::before{content:"";position:absolute;left:-14px;top:22px;width:12px;height:2px;background:var(--border-strong)}
.wf-step.is-wait{border-style:dashed}
.wf-step.is-wait .wf-node-icon{background:var(--yellow-soft);color:var(--yellow)}
.wf-step.is-check .wf-node-icon{background:var(--green-soft);color:var(--green)}
.wf-step.dragging{opacity:.45}
.wf-step.test-error{border-color:var(--red)}
.wf-step.test-warn{border-color:var(--yellow)}
.wf-step-head{display:flex;align-items:center;gap:8px;min-width:0}
.wf-step-head select{flex:1;min-width:0}
.wf-step-n{font-size:12px;font-weight:800;color:var(--accent-light);min-width:14px;text-align:center;font-variant-numeric:tabular-nums}
.wf-grip{cursor:grab;color:var(--text);opacity:.45;display:inline-flex;padding:2px;flex:none}
.wf-grip svg{width:16px;height:16px}
.wf-grip:hover{opacity:.9}
.wf-step-tools{display:flex;gap:2px;flex:none}
.wf-step-tools .btn-icon[disabled]{opacity:.3;cursor:default}
.wf-drop{height:4px;border-radius:2px;background:var(--accent);list-style:none}
.wf-inline{display:flex;gap:8px}
.wf-inline .input:first-child{max-width:110px}
.wf-vars{margin-top:8px;font-family:var(--font-mono);font-size:12px;overflow-wrap:anywhere}
.wf-palette{position:sticky;top:0;border:1px solid var(--border);border-radius:var(--radius-sm);padding:12px;background:var(--bg);display:flex;flex-direction:column;gap:10px}
.wf-palette-head{display:flex;flex-direction:column;gap:2px}
.wf-palette-items{display:flex;flex-direction:column;gap:6px}
.wf-chip{display:flex;align-items:center;gap:8px;width:100%;text-align:left;padding:7px 10px;border-radius:var(--radius-sm);border:1px solid var(--border);background:var(--surface);color:var(--text);font:inherit;font-size:13px;cursor:grab;transition:border-color var(--transition),background var(--transition)}
.wf-chip:hover:not([disabled]){border-color:var(--accent);background:var(--accent-soft)}
.wf-chip:focus-visible{outline:2px solid var(--accent);outline-offset:2px}
.wf-chip[disabled]{opacity:.45;cursor:not-allowed}
.wf-chip span{display:inline-flex;flex:none}
.wf-chip svg{width:15px;height:15px}
.wf-note{display:flex;gap:8px;align-items:flex-start;font-size:13px;padding:6px 8px;border-radius:var(--radius-sm);background:var(--bg)}
.wf-note > span{display:inline-flex;flex:none;margin-top:1px}
.wf-note > span svg{width:15px;height:15px}
.wf-note.is-ok > span{color:var(--green)}
.wf-note.is-info > span{color:var(--blue)}
.wf-note.is-warn{background:var(--yellow-soft)}
.wf-note.is-warn > span{color:var(--yellow)}
.wf-note.is-error{background:var(--red-soft)}
.wf-note.is-error > span{color:var(--red)}
.wf-preview{margin:6px 0 0;padding:6px 10px;border-left:3px solid var(--border-strong);color:var(--text);white-space:pre-wrap;overflow-wrap:anywhere}
.wf-summary{padding:10px 12px;border-radius:var(--radius-sm);border:1px solid var(--border)}
.wf-summary.is-ok{border-color:var(--green);background:var(--green-soft)}
.wf-summary.is-warn{border-color:var(--yellow);background:var(--yellow-soft)}
.wf-summary p{margin:4px 0 0}
@media(max-width:800px){
  .wf-builder{grid-template-columns:minmax(0,1fr)}
  .wf-palette{position:static;order:-1}
  .wf-palette-items{flex-direction:row;flex-wrap:wrap}
  .wf-chip{width:auto}
}
@media(prefers-reduced-motion:reduce){.wf-step,.wf-chip{transition:none}}
/* Reputation */
.rep-results{display:flex;flex-direction:column;gap:4px;margin-top:10px}
.rep-member{display:inline-flex;align-items:center;gap:8px;background:none;border:0;padding:4px 6px;margin:-4px -6px;border-radius:var(--radius-sm);color:var(--text);font:inherit;cursor:pointer;text-align:left;min-width:0}
.rep-member:hover{background:var(--accent-soft)}
.rep-member:focus-visible{outline:2px solid var(--accent);outline-offset:1px}
.rep-member img,.rep-avatar-blank{width:24px;height:24px;border-radius:50%;flex:none;background:var(--accent-soft)}
.rep-avatar-blank.big,.rep-profile-head img{width:56px;height:56px;border-radius:50%}
.rep-member > span:nth-child(2){overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.rep-subhead{font-size:13px;font-weight:700;margin:18px 0 8px;text-transform:uppercase;letter-spacing:.5px;color:var(--text-2)}
.rep-save{margin-top:14px;display:flex;justify-content:flex-end}
.rep-profile-head{display:flex;align-items:center;gap:14px;margin-bottom:14px}
.rep-profile-head h3{margin:0;font-size:18px}
.rep-profile-head p{margin:2px 0 0}
.rep-score{margin-left:auto;display:flex;flex-direction:column;align-items:flex-end}
.rep-score strong{font-size:26px;font-weight:800;font-variant-numeric:tabular-nums;color:var(--accent-light)}
.rep-level{display:flex;flex-direction:column;gap:6px}
.rep-level .op-progress{max-width:none}
.rep-level-top{display:flex;justify-content:space-between;gap:8px}
.rep-ach{list-style:none;margin:0;padding:0;display:grid;grid-template-columns:repeat(auto-fill,minmax(min(100%,210px),1fr));gap:8px}
.rep-ach li{display:flex;gap:10px;align-items:flex-start;padding:10px;border:1px solid var(--border);border-radius:var(--radius-sm);opacity:.55}
.rep-ach li.is-earned{opacity:1;border-color:var(--accent)}
.rep-ach li > div{display:flex;flex-direction:column;gap:2px;min-width:0}
.rep-ach-emoji{font-size:20px;line-height:1}
.rep-ach-progress{font-size:12px;font-variant-numeric:tabular-nums;color:var(--text-2)}
.rep-history{list-style:none;margin:0;padding:0;display:flex;flex-direction:column;gap:6px}
.rep-history li{display:grid;grid-template-columns:52px minmax(0,1fr) auto;gap:8px;align-items:baseline;font-size:13.5px}
.rep-delta{font-weight:800;font-variant-numeric:tabular-nums;text-align:right}
.rep-delta.pos{color:var(--green)}
.rep-delta.neg{color:var(--red)}
.rep-adjust{display:grid;grid-template-columns:120px minmax(0,1fr) auto;gap:8px}
@media(max-width:600px){.rep-adjust{grid-template-columns:1fr}.rep-profile-head{flex-wrap:wrap}}
.rep-kpis{grid-template-columns:repeat(3,minmax(0,1fr))}
@media(max-width:480px){.rep-kpis{grid-template-columns:minmax(0,1fr)}}
@media(max-width:900px){.rep-split .rep-lookup{order:-1}}
/* Onboarding */
.ob-kpis{grid-template-columns:repeat(4,minmax(0,1fr))}
@media(max-width:800px){.ob-kpis{grid-template-columns:repeat(2,minmax(0,1fr))}}
.ob-funnel{list-style:none;margin:6px 0 0;padding:0;display:flex;flex-direction:column;gap:6px}
.ob-funnel li{display:grid;grid-template-columns:minmax(90px,200px) minmax(0,1fr) 48px;gap:10px;align-items:center;font-size:13.5px}
.ob-funnel li.is-step .ob-funnel-label{padding-left:12px;color:var(--text-2)}
.ob-funnel-label{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.ob-funnel-bar{height:10px;border-radius:999px;background:var(--bg-2, var(--bg));overflow:hidden}
.ob-funnel-bar span{display:block;height:100%;border-radius:inherit;background:var(--accent)}
.ob-funnel-n{text-align:right;font-variant-numeric:tabular-nums;font-weight:700}
.ob-layout{display:grid;grid-template-columns:minmax(0,1fr) minmax(260px,340px);gap:16px;align-items:start;margin-top:10px}
.ob-side{position:sticky;top:12px}
.ob-steps{list-style:none;margin:0;padding:0;display:flex;flex-direction:column;gap:10px}
.ob-step{border:1px solid var(--border);border-radius:var(--radius-sm);padding:12px;background:var(--bg);display:flex;flex-direction:column;gap:10px}
.ob-step.is-selected{border-color:var(--accent)}
.ob-step-head{display:flex;align-items:center;gap:8px}
.ob-step-pick{display:flex;align-items:center;gap:8px;flex:1;min-width:0;background:none;border:0;padding:0;color:var(--text);font:inherit;cursor:pointer;text-align:left}
.ob-step-pick:focus-visible{outline:2px solid var(--accent);outline-offset:3px;border-radius:4px}
.ob-step-pick .muted{margin-left:auto}
.ob-step.is-selected .ob-step-pick .muted{visibility:hidden}
.ob-empty{padding:16px;border:1px dashed var(--border);border-radius:var(--radius-sm);text-align:center}
.ob-add{display:flex;flex-wrap:wrap;gap:6px;align-items:center;margin-top:10px}
.ob-add .wf-chip{width:auto}
.ob-role-rows{display:flex;flex-direction:column;gap:6px}
.ob-role-row{display:grid;grid-template-columns:minmax(0,1.2fr) minmax(0,1fr) minmax(0,1.3fr) 64px 36px;gap:6px;align-items:center}
.ob-q-row{display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1fr) auto auto 36px;gap:6px;align-items:center}
.ob-actions{gap:8px}
.ob-preview{display:flex;flex-direction:column;gap:8px}
.ob-dmsg{background:#313338;color:#dbdee1;border-radius:8px;padding:12px;font-size:14px;line-height:1.4}
.ob-dhead{display:flex;align-items:center;gap:6px;margin-bottom:6px}
.ob-dhead strong{color:#fff}
.ob-dhead .muted{color:#949ba4}
.ob-dbot{background:#5865f2;color:#fff;font-size:10px;font-weight:700;padding:1px 4px;border-radius:3px}
.ob-dembed{border-left:4px solid #8b5cf6;background:#2b2d31;border-radius:4px;padding:10px 12px;display:flex;flex-direction:column;gap:6px}
.ob-dtitle{color:#fff}
.ob-dembed p{margin:0;white-space:pre-wrap;overflow-wrap:anywhere;max-height:220px;overflow:auto}
.ob-dfoot{font-size:12px;color:#949ba4}
.ob-dcontrols{display:flex;flex-wrap:wrap;gap:6px;margin-top:8px}
.ob-dbtn{padding:6px 12px;border-radius:4px;font-size:13px;font-weight:600;color:#fff;background:#5865f2}
.ob-dbtn.is-success{background:#248046}
.ob-dbtn.is-secondary{background:#4e5058}
.ob-dselect{display:flex;justify-content:space-between;align-items:center;width:100%;background:#1e1f22;border-radius:4px;padding:8px 10px;color:#949ba4}
.ob-dselect span{display:inline-flex}
.ob-dselect svg{width:14px;height:14px}
.ob-doptions{list-style:none;margin:0;padding:8px 10px;border:1px solid var(--border);border-radius:var(--radius-sm);font-size:13px;display:flex;flex-direction:column;gap:4px}
.rep-member.is-static{cursor:default}
.rep-member.is-static:hover{background:none}
@media(max-width:900px){
  .ob-layout{grid-template-columns:minmax(0,1fr)}
  .ob-side{position:static;order:-1}
  .ob-role-row{grid-template-columns:minmax(0,1fr) 72px 36px}
  .ob-role-row > :nth-child(1){grid-column:1 / 3;grid-row:1}
  .ob-role-row > :nth-child(5){grid-column:3;grid-row:1}
  .ob-role-row > :nth-child(2){grid-column:1;grid-row:2}
  .ob-role-row > :nth-child(4){grid-column:2 / 4;grid-row:2}
  .ob-role-row > :nth-child(3){grid-column:1 / 4;grid-row:3}
  .ob-q-row{grid-template-columns:minmax(0,1fr) 36px}
  .ob-q-row > :nth-child(1){grid-column:1;grid-row:1}
  .ob-q-row > :nth-child(5){grid-column:2;grid-row:1}
  .ob-q-row > :nth-child(n+2):nth-child(-n+4){grid-column:1 / 3}
}
/* Community events */
.cev-slots{display:grid;grid-template-columns:repeat(auto-fit,minmax(min(100%,240px),1fr));gap:8px;margin:8px 0}
.cev-slot{display:flex;align-items:center;gap:10px;padding:10px 12px;border:1px solid var(--border);border-radius:var(--radius-sm);background:var(--bg)}
.cev-slot > div{display:flex;flex-direction:column;flex:1;min-width:0}
.cev-slot-rank{width:24px;height:24px;border-radius:50%;background:var(--accent-soft);color:var(--accent-light);font-weight:800;font-size:12px;display:inline-flex;align-items:center;justify-content:center;flex:none}
/* Integrations */
.int-kind{display:inline-flex;align-items:center;gap:6px;font-size:11.5px;font-weight:700;letter-spacing:.3px;padding:2px 8px;border-radius:999px;border:1px solid currentColor;white-space:nowrap}
.int-kind.is-youtube{color:#ff4d6a}
.int-kind.is-twitch{color:#a78bfa}
.int-kind.is-github{color:var(--text)}
.int-kind.is-rss{color:#fb923c}
.int-kind.is-minecraft{color:var(--green)}
.int-kind.is-source{color:var(--blue)}
.int-kinds{display:grid;grid-template-columns:repeat(auto-fill,minmax(min(100%,200px),1fr));gap:8px}
.int-kind-card{display:flex;flex-direction:column;align-items:flex-start;gap:6px;padding:10px 12px;border:1px solid var(--border);border-radius:var(--radius-sm);background:var(--bg);color:var(--text);font:inherit;text-align:left;cursor:pointer}
.int-kind-card:hover:not([disabled]){border-color:var(--accent)}
.int-kind-card.is-selected{border-color:var(--accent);background:var(--accent-soft)}
.int-kind-card[disabled]{opacity:.5;cursor:not-allowed}
.int-kind-card:focus-visible{outline:2px solid var(--accent);outline-offset:2px}
.card-sub a{color:var(--accent-light)}

/* ── Owner Panel → Reviews (review moderation) ── */
.rm-sub{display:flex;gap:6px;margin-bottom:16px;flex-wrap:wrap}
.rm-sub button{padding:7px 14px;border-radius:999px;border:1px solid var(--border);background:var(--surface);color:var(--text-2);font:inherit;font-size:13.5px;font-weight:600;cursor:pointer}
.rm-sub button.active{background:var(--accent-soft);border-color:var(--accent);color:var(--text)}
.rm-chips{display:flex;gap:6px;flex-wrap:wrap;margin-bottom:12px}
.rm-chips button{display:inline-flex;align-items:center;gap:6px;padding:6px 12px;border-radius:var(--radius-sm);border:1px solid var(--border);background:var(--surface);color:var(--text-2);font:inherit;font-size:13px;cursor:pointer}
.rm-chips button.active{border-color:var(--accent);color:var(--text);background:var(--accent-soft)}
.rm-chips .n{font-variant-numeric:tabular-nums;font-size:12px;color:var(--text-3)}
.rm-filters{display:flex;gap:8px;flex-wrap:wrap;margin-bottom:14px}
.rm-filters .input{width:auto;flex:1 1 160px;min-width:0}
.rm-filters input[type="search"]{flex:3 1 240px}
.rm-list{display:flex;flex-direction:column;gap:8px}
.rm-row{display:flex;flex-direction:column;gap:6px;text-align:left;width:100%;padding:12px 14px;border-radius:var(--radius);border:1px solid var(--border);border-left:3px solid var(--border);background:var(--surface);color:var(--text);font:inherit;cursor:pointer;transition:border-color var(--transition)}
.rm-row:hover{border-color:var(--border-hover)}
.rm-row.risk-high{border-left-color:var(--red)}
.rm-row.risk-medium{border-left-color:var(--yellow)}
.rm-row-top{display:flex;align-items:center;gap:8px;flex-wrap:wrap}
.rm-row-body{display:flex;align-items:baseline;gap:8px;flex-wrap:wrap;font-size:14px}
.rm-excerpt{color:var(--text-2);overflow-wrap:anywhere}
.rm-row-meta{display:flex;gap:10px;flex-wrap:wrap}
.rm-flag{padding:1px 7px;border-radius:6px;background:var(--surface-2);border:1px solid var(--border)}
.rm-stars{color:#f5b84a;letter-spacing:1px;white-space:nowrap}
.rm-stars .off{color:var(--border-strong)}
.rm-detail{display:flex;flex-direction:column;gap:14px}
.rm-detail-head{display:flex;align-items:center;gap:8px;flex-wrap:wrap}
.rm-detail-grid{display:grid;grid-template-columns:minmax(0,1.1fr) minmax(0,1fr);gap:14px;align-items:start}
@media(max-width:860px){.rm-detail-grid{grid-template-columns:minmax(0,1fr)}}
.rm-col{display:flex;flex-direction:column;gap:12px;min-width:0}
.rm-card{display:flex;flex-direction:column;gap:8px;padding:14px;border-radius:var(--radius);border:1px solid var(--border);background:var(--surface-2)}
.rm-card summary{cursor:pointer}
.rm-author{display:flex;align-items:center;gap:10px}
.rm-author img{border-radius:50%}
.rm-title{margin:0;font-size:16px}
.rm-pre{white-space:pre-wrap;overflow-wrap:anywhere;margin:0}
.rm-imgs{display:grid;grid-template-columns:repeat(auto-fill,minmax(200px,1fr));gap:10px}
.rm-img{border:1px solid var(--border);border-radius:var(--radius);overflow:hidden;background:var(--surface-2)}
.rm-img.is-rejected{border-color:var(--red)}
.rm-img-btn{display:block;width:100%;padding:0;border:0;background:#000;cursor:zoom-in;aspect-ratio:4/3}
.rm-img-btn img{width:100%;height:100%;object-fit:contain;display:block}
.rm-img-gone{aspect-ratio:4/3;display:grid;place-items:center;color:var(--text-3);font-size:13px;background:var(--bg-2)}
.rm-img-info{padding:10px;display:flex;flex-direction:column;gap:6px}
.rm-conf{display:grid;grid-template-columns:minmax(0,1fr) 90px 40px;gap:8px;align-items:center;font-size:13px}
.rm-conf-bar{height:6px;border-radius:999px;background:var(--bg-2);overflow:hidden}
.rm-conf-bar span{display:block;height:100%;background:var(--accent)}
.rm-reports{margin:0;padding-left:18px;display:flex;flex-direction:column;gap:4px;font-size:13.5px}
.rm-events{margin:6px 0 0;padding-left:18px;display:flex;flex-direction:column;gap:4px;font-size:13px}
.rm-form{display:flex;flex-direction:column;gap:12px}
.rm-grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(220px,1fr));gap:12px}
.rm-cats{display:flex;flex-direction:column;gap:6px;margin-top:12px}
.rm-cat-row{display:grid;grid-template-columns:minmax(0,1fr) 220px;gap:10px;align-items:center;padding:8px 0;border-bottom:1px solid var(--border);font-size:14px}
@media(max-width:600px){.rm-cat-row{grid-template-columns:minmax(0,1fr)}}
/* Automatic moderation switch */
.rm-auto{margin-bottom:14px}
.rm-auto-head{display:flex;align-items:flex-start;justify-content:space-between;gap:16px}
.rm-auto-head .mg-title{display:flex;align-items:center;gap:8px;margin:0}
.rm-auto-row{margin-top:12px;max-width:420px}
.rm-switch{flex:none;position:relative;width:52px;height:30px;border-radius:999px;border:1px solid var(--border);background:var(--surface-2);cursor:pointer;transition:background var(--transition),border-color var(--transition)}
.rm-switch span{position:absolute;top:3px;left:3px;width:22px;height:22px;border-radius:50%;background:var(--text-3);transition:transform var(--transition),background var(--transition)}
.rm-switch.is-on{background:var(--green-soft);border-color:var(--green)}
.rm-switch.is-on span{transform:translateX(22px);background:var(--green)}
.rm-switch:focus-visible{outline:2px solid var(--accent);outline-offset:2px}
.rm-switch:disabled{opacity:.5;cursor:not-allowed}
.rm-final{display:flex;flex-direction:column;gap:4px;padding:10px 12px;border-radius:10px;border:1px solid var(--accent);background:var(--accent-soft)}

/* Recruitment form editor: answer types, choices, question ideas and templates */
.question-card{display:flex;flex-direction:column;gap:8px;padding:10px;border:1px solid var(--border);border-radius:12px;background:var(--surface-2)}
.question-card>.form-hint{margin:0 0 0 32px}
.q-label{position:relative;min-width:0}
.q-label .input{width:100%;padding-right:52px}
.q-count{position:absolute;right:10px;top:50%;transform:translateY(-50%);font-size:11px;color:var(--text-3);font-variant-numeric:tabular-nums;pointer-events:none}
.q-count.is-full{color:var(--yellow)}
.q-choices{display:flex;flex-direction:column;gap:8px;margin-left:32px}
.q-chips{display:flex;flex-wrap:wrap;gap:6px}
.q-chips:empty{display:none}
.q-chip{display:inline-flex;align-items:center;gap:4px;max-width:100%;padding:3px 4px 3px 10px;border-radius:999px;background:var(--accent-soft);color:var(--text);font-size:13px;overflow-wrap:anywhere}
.q-chip-x{display:grid;place-items:center;width:20px;height:20px;padding:0;border:0;border-radius:50%;background:none;color:var(--text-3);cursor:pointer;flex:none}
.q-chip-x:hover,.q-chip-x:focus-visible{background:var(--surface-3);color:var(--text)}
.q-chip-x svg{width:12px;height:12px}
.q-choice-add{display:flex;gap:8px}
.q-choice-add .input{flex:1;min-width:0}
.q-actions{display:flex;flex-wrap:wrap;gap:8px}
.q-tip{margin:-4px 0 0}
.q-ideas{display:flex;flex-direction:column;gap:12px;padding:12px;border:1px dashed var(--border);border-radius:12px}
.q-ideas[hidden]{display:none}
.q-ideas>.form-hint{margin:0}
.q-idea-group{display:flex;flex-direction:column;gap:6px}
.q-idea-cat{font-size:12px;font-weight:700;letter-spacing:.04em;text-transform:uppercase;color:var(--text-3)}
.q-idea-list{display:flex;flex-wrap:wrap;gap:6px}
.q-idea{display:inline-flex;align-items:center;gap:8px;max-width:100%;padding:6px 10px;border:1px solid var(--border);border-radius:10px;background:var(--surface);color:var(--text);font:inherit;font-size:13px;text-align:left;cursor:pointer}
.q-idea:hover:not(:disabled),.q-idea:focus-visible{border-color:var(--accent)}
.q-idea:disabled{opacity:.45;cursor:default}
.q-idea-type{flex:none;padding:1px 6px;border-radius:6px;font-size:11px;font-weight:600;background:var(--surface-3);color:var(--text-2)}
.q-idea-type.is-yesno{background:var(--green-soft);color:var(--green)}
.q-idea-type.is-choice{background:rgba(59,130,246,.15);color:var(--blue)}
.q-templates{display:flex;flex-direction:column;gap:8px}
.q-tpl-list{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:8px}
.q-tpl{display:flex;align-items:center;gap:8px;padding:10px 12px;border:1px solid var(--border);border-radius:12px;background:var(--surface);color:var(--text);font:inherit;font-weight:600;cursor:pointer;text-align:left}
.q-tpl:hover,.q-tpl:focus-visible{border-color:var(--accent)}
.q-tpl-icon{font-size:18px}
@media (max-width:640px){
  .q-tpl-list{grid-template-columns:repeat(2,minmax(0,1fr))}
  .q-choices,.question-card>.form-hint{margin-left:0}
}
