.client-button { border: 0; background: transparent; font: inherit; cursor: pointer; }
.portal-logo { width: 52px; height: 52px; object-fit: contain; }
.auth-logo { width: 80px; height: 80px; object-fit: contain; margin-bottom: 34px; display: block; }
.handled-kpis { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.kpi { width: 100%; text-align: left; color: inherit; cursor: pointer; }
.kpi.brand-complete { border-top-color: #ff6600; }
.kpi:hover { border-color: rgba(105, 6, 205, .28); box-shadow: 0 4px 16px rgba(31, 41, 55, .1); }
.sparkline { width: 100%; height: 30px; margin: 4px 0; overflow: visible; }
.sparkline polyline { fill: none; stroke: var(--brand); stroke-width: 2; vector-effect: non-scaling-stroke; }
.brand-complete .sparkline polyline { stroke: #ff6600; }
.sparkline-empty { display: block; height: 30px; }
.col-help { width: 13px !important; height: 13px !important; color: var(--muted); opacity: .7; vertical-align: middle; margin-left: 2px; }
.compare-toggle { display: inline-flex; align-items: center; gap: 7px; color: var(--muted); font-size: 12px; font-weight: 700; }
.export-menu { position: relative; }
.export-options { position: absolute; top: calc(100% + 6px); right: 0; z-index: 10; width: 170px; padding: 6px; border: 1px solid var(--line); border-radius: 8px; background: var(--surface); box-shadow: 0 8px 24px rgba(31,41,55,.14); }
.export-options button { width: 100%; padding: 9px 10px; border: 0; border-radius: 6px; color: var(--ink); text-align: left; background: transparent; }
.export-options button:hover { background: #f2e8ff; }
.channel-card-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(270px, 1fr)); gap: 16px; }
.channel-card { display: grid; gap: 16px; min-height: 210px; padding: 18px; color: var(--ink); text-align: left; border: 1px solid var(--line); border-top: 4px solid #ff6600; border-radius: 8px; background: linear-gradient(180deg, var(--surface), #fffaf6); box-shadow: var(--shadow); transition: transform .16s ease, border-color .16s ease, box-shadow .16s ease; }
.channel-card:hover { border-color: rgba(105, 6, 205, .26); box-shadow: 0 12px 28px rgba(31, 41, 55, .1); transform: translateY(-1px); }
.channel-card header { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.channel-card header span { color: var(--brand); font-size: 14px; font-weight: 850; }
.channel-card header svg { width: 18px; color: var(--muted); }
.channel-primary { display: grid; gap: 3px; }
.channel-primary strong { color: var(--ink); font-size: 34px; line-height: 1; }
.channel-primary small,.channel-stat-grid small { color: var(--muted); font-size: 12px; font-weight: 750; }
.channel-stat-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; }
.channel-stat-grid span { display: grid; gap: 5px; min-width: 0; padding: 11px; border: 1px solid rgba(216, 226, 236, .82); border-radius: 8px; background: var(--surface); }
.channel-stat-grid b { color: var(--ink); font-size: 16px; line-height: 1.2; white-space: nowrap; }
.channel-detail-row { width: 100%; grid-template-columns: minmax(150px, .8fr) minmax(360px, 2fr) 24px; border: 0; background: transparent; text-align: left; cursor: pointer; }
.channel-detail-row:hover { background: #f8f5fb; }
.channel-metrics { display: grid; grid-template-columns: repeat(3, minmax(100px, 1fr)); gap: 10px; }
.channel-metrics span { display: grid; gap: 4px; color: var(--muted); font-size: 12px; }
.channel-metrics b { color: var(--ink); font-size: 14px; }
.ticket-toolbar { display: flex; align-items: end; justify-content: space-between; gap: 16px; margin: 30px 0 12px; flex-wrap: wrap; }
.ticket-toolbar label, .compact-filter, .profile-form label { display: grid; gap: 7px; color: var(--muted); font-size: 12px; font-weight: 700; }
.ticket-toolbar select, .compact-filter select, .profile-form input { min-height: 40px; padding: 0 12px; border: 1px solid var(--line); border-radius: 8px; background: #fff; color: var(--ink); }
.portal-ticket-search { min-width: 220px; padding: 0 12px; }
.ticket-table-wrap { overflow-x: auto; border: 1px solid var(--line); border-radius: 8px; background: #fff; }
.ticket-table { width: 100%; min-width: 1220px; border-collapse: collapse; }
.ticket-table th { padding: 11px 12px; color: var(--muted); font-size: 11px; text-align: left; background: #f8f5fb; border-bottom: 1px solid var(--line); }
.ticket-table td { padding: 13px 12px; font-size: 13px; border-bottom: 1px solid var(--line); }
.ticket-table tbody tr { cursor: pointer; }
.ticket-table tbody tr:hover { background: #faf8fc; }
.ticket-table td:first-child { display: grid; gap: 4px; min-width: 220px; }
.ticket-table td small { color: var(--muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 280px; }
.ticket-table svg { width: 16px; }
.response-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.response-card { display: grid; gap: 8px; padding: 20px; border: 1px solid var(--line); border-top: 4px solid #ff6600; border-radius: 8px; background: var(--surface); box-shadow: var(--shadow); }
.response-card-label { display: flex; align-items: center; gap: 7px; margin: 0; color: var(--muted); font-size: 12px; font-weight: 750; }
.response-card-label svg { width: 15px; height: 15px; }
.response-card-value { color: var(--ink); font-size: 36px; line-height: 1; letter-spacing: -.02em; }
.response-card-value.tone-success { color: var(--success); }
.response-card-value.tone-warning { color: #b45309; }
.response-card-value.tone-danger { color: var(--danger); }
.response-card-sub-text { margin: 0; color: var(--muted); font-size: 12px; }
.response-sla-bar { height: 6px; border-radius: 999px; background: var(--line); overflow: hidden; }
.response-sla-bar span { display: block; height: 100%; border-radius: 999px; background: var(--success); transition: width .4s ease; }
.response-sla-bar span.tone-warning { background: #f59e0b; }
.response-sla-bar span.tone-danger { background: var(--danger); }
.response-card-sub { display: flex; gap: 16px; flex-wrap: wrap; }
.response-card-sub span { display: grid; gap: 3px; font-size: 12px; }
.response-card-sub b { color: var(--ink); font-size: 15px; }
.response-card-sub small { color: var(--muted); font-size: 11px; font-weight: 700; }
.tone-danger { color: var(--danger); }
.empty-cell { padding: 30px !important; color: var(--muted); text-align: center !important; }
.sla-badge { display: inline-flex; padding: 4px 8px; border-radius: 999px; font-size: 11px; font-weight: 800; white-space: nowrap; }
.sla-badge.met { color: var(--success); background: var(--success-soft); }
.sla-badge.breached { color: var(--danger); background: #fff0ef; }
.sla-badge.review,.sla-badge.pending { color: #8a5a00; background: #fff7db; }
.sla-badge.excluded { color: var(--muted); background: #f4f7fb; }
.sla-badge.unknown { color: var(--muted); background: #edf1f5; }
.sla-badge.partial { color: #d97706; background: #fef3c7; }
.sla-reason { display: block; color: var(--muted); font-size: 10px; margin-top: 3px; max-width: 150px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.billing-badge { display: inline-flex; padding: 4px 8px; color: var(--success); font-size: 11px; font-weight: 800; white-space: nowrap; border-radius: 999px; background: var(--success-soft); }
.billing-badge.invoiced { color: var(--brand); background: #f4ecff; }
.profile-page { max-width: 920px; display: grid; gap: 20px; }
.profile-hero { position: relative; overflow: hidden; display: flex; align-items: center; gap: 18px; padding: 24px; border: 1px solid rgba(105, 6, 205, .14); border-radius: 8px; background: linear-gradient(135deg, #fff, #f2e8ff 56%, #fff4ec); box-shadow: var(--shadow); }
.profile-hero::after { content: ""; position: absolute; inset: auto 22px 18px auto; width: 98px; height: 98px; background: radial-gradient(circle, rgba(255, 102, 0, .13), transparent 68%); pointer-events: none; }
.profile-avatar-wrap { position: relative; flex: 0 0 auto; }
.profile-avatar { width: 72px; height: 72px; display: grid; place-items: center; color: #fff; font-size: 22px; font-weight: 850; border-radius: 50%; background: #ff6600; box-shadow: 0 10px 24px rgba(255, 102, 0, .18); }
.profile-cat-icon { position: absolute; right: -5px; bottom: -5px; display: grid; place-items: center; width: 30px; height: 30px; color: #5200a8; background: #fff; border: 1px solid rgba(105,6,205,.18); border-radius: 999px; box-shadow: var(--shadow); }
.profile-cat-icon svg { width: 17px; height: 17px; }
.profile-hero h2 { margin: 4px 0; }
.profile-grid { display: grid; grid-template-columns: minmax(280px, 1fr) minmax(300px, 1fr); gap: 16px; align-items: start; }
.profile-form { display: grid; gap: 14px; padding: 20px; border: 1px solid var(--line); border-radius: 8px; background: #fff; }
.profile-form h3 { margin: 0; }
.secondary-button { min-height: 42px; padding: 0 16px; justify-self: start; border: 1px solid var(--line); border-radius: 8px; background: #fff; color: var(--ink); font-weight: 700; }
.ticket-dialog { width: min(820px, calc(100% - 32px)); max-height: 88vh; padding: 0; border: 0; border-radius: 8px; box-shadow: 0 32px 80px rgba(31, 41, 55, .2); }
.ticket-dialog::backdrop { background: rgba(23, 32, 51, .55); }
.dialog-head { position: sticky; top: 0; z-index: 2; display: flex; align-items: center; justify-content: space-between; gap: 20px; padding: 18px 20px; border-bottom: 1px solid var(--line); background: #fff; }
.dialog-head h2 { margin: 4px 0 0; font-size: 20px; }
.dialog-body { padding: 20px; }
.ticket-summary { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px; margin-bottom: 20px; }
.ticket-summary span { display: grid; gap: 6px; padding: 12px 14px; border: 1px solid var(--line); border-radius: 8px; font-size: 12px; background: var(--surface); }
.ticket-summary b { color: var(--muted); font-size: 10px; font-weight: 800; text-transform: uppercase; letter-spacing: .04em; }
.detail-metric { color: var(--ink); font-size: 15px; font-weight: 700; }
.response-moments { display: grid; gap: 12px; margin-top: 24px; }
.response-moments h3 { margin: 0; font-size: 16px; }
.portal-review-note { margin: 0; padding: 10px 14px; border-left: 3px solid #f59e0b; border-radius: 4px; background: #fffbeb; color: #92400e; font-size: 13px; line-height: 1.5; }
.portal-exclusion-reason { margin: 0 0 4px; padding: 8px 12px; border-left: 3px solid #94a3b8; border-radius: 4px; background: #f1f5f9; color: #475569; font-size: 13px; line-height: 1.5; }
.portal-exclusion-banner { margin: 0 0 16px; padding: 10px 14px; border-left: 3px solid #94a3b8; border-radius: 4px; background: #f1f5f9; color: #475569; font-size: 13px; line-height: 1.5; }
.response-moment { padding: 0; border: 1px solid var(--line); border-left: 4px solid var(--brand); border-radius: 8px; background: var(--surface); overflow: hidden; }
.response-moment.is-excluded { border-left-color: #94a3b8; opacity: .9; }
.response-moment header { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; padding: 13px 16px; background: linear-gradient(90deg, rgba(105,6,205,.05), transparent); border-bottom: 1px solid var(--line); }
.response-moment header div { display: grid; gap: 3px; }
.response-moment header div span { color: var(--brand); font-size: 10px; font-weight: 800; text-transform: uppercase; letter-spacing: .05em; }
.response-moment header div strong { font-size: 15px; }
.response-moment dl { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 0; margin: 0; }
.response-moment dl div { display: grid; gap: 5px; padding: 12px 16px; border-right: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.response-moment dl div:nth-child(even) { border-right: 0; }
.response-moment dl div:nth-last-child(-n+2) { border-bottom: 0; }
.response-moment dt { font-size: 10px; font-weight: 800; text-transform: uppercase; letter-spacing: .04em; }
.response-moment dl div:nth-child(1) dt,.response-moment dl div:nth-child(3) dt { color: #6906cd; }
.response-moment dl div:nth-child(2) dt,.response-moment dl div:nth-child(4) dt { color: #ff6600; }
.response-moment dd { display: grid; gap: 4px; margin: 0; font-size: 13px; color: var(--ink); }
.response-moment dd small { color: var(--muted); line-height: 1.4; font-size: 12px; }
.loading-state.compact { min-height: 220px; }
.preference-row { grid-template-columns: 1fr auto; align-items: center; padding: 12px 0; border-bottom: 1px solid var(--line); }
.preference-row span { display: grid; gap: 4px; }
.preference-row small { color: var(--muted); font-weight: 400; }
.preference-row input { width: 20px; height: 20px; accent-color: var(--brand); }
.feedback-layout { display: grid; grid-template-columns: minmax(300px, .8fr) minmax(360px, 1.2fr); gap: 28px; }
.portal-feedback-form { display: grid; gap: 16px; align-self: start; padding: 22px; border: 1px solid var(--line); border-top: 4px solid #ff6600; border-radius: 8px; background: var(--surface); box-shadow: var(--shadow); }
.portal-feedback-form h2 { margin: 5px 0; }
.portal-feedback-form label { display: grid; gap: 7px; color: var(--muted); font-size: 12px; font-weight: 700; }
.portal-feedback-form input,.portal-feedback-form select,.portal-feedback-form textarea { width: 100%; padding: 11px 12px; border: 1px solid var(--line); border-radius: 8px; color: var(--ink); background: var(--surface); font: inherit; }
.portal-feedback-list { display: grid; gap: 12px; }
.portal-feedback-item { padding: 17px; border: 1px solid var(--line); border-radius: 8px; background: var(--surface); box-shadow: var(--shadow); }
.portal-feedback-item > div { display: flex; align-items: center; gap: 8px; }
.portal-feedback-item time { margin-left: auto; color: var(--muted); font-size: 11px; }
.portal-feedback-item h3 { margin: 12px 0 7px; font-size: 16px; }
.portal-feedback-item p { margin: 0; color: var(--muted); line-height: 1.5; white-space: pre-wrap; }
.portal-feedback-item aside { display: grid; gap: 5px; margin-top: 12px; padding: 10px; color: var(--ink); font-size: 12px; background: var(--info-soft); border-radius: 6px; }
.feedback-type,.feedback-status { padding: 3px 7px; border-radius: 999px; font-size: 10px; font-weight: 800; }
.feedback-type { color: #5200a8; background: #f2e8ff; }.feedback-type.bug { color: var(--danger); background: #fff0ef; }.feedback-status { color: var(--info); background: var(--info-soft); }
.ai-placeholder { display: grid; justify-items: center; gap: 12px; max-width: 620px; margin: 16px auto 0; padding: 44px 28px; text-align: center; border: 1px solid rgba(105, 6, 205, .14); border-radius: 8px; background: linear-gradient(135deg, #fff, #f8f2ff 58%, #fff5ed); box-shadow: var(--shadow); }
.ai-orb { display: grid; place-items: center; width: 74px; height: 74px; color: #fff; border-radius: 50%; background: linear-gradient(135deg, #6906cd, #ff6600); box-shadow: 0 16px 36px rgba(105, 6, 205, .22); }
.ai-orb svg { width: 31px; height: 31px; }
.ai-placeholder h2 { margin: 0; }
.ai-placeholder p:last-child { max-width: 440px; color: var(--muted); line-height: 1.55; }

html[data-theme="dark"] { color-scheme: dark; --ink:#f5f3f8;--muted:#a8b3c3;--line:#354055;--surface:#1b2130;--page:#111621;--info-soft:#222d40;--success-soft:#17382e; }
html[data-theme="dark"] body,html[data-theme="dark"] .topbar,html[data-theme="dark"] .dialog-head,html[data-theme="dark"] .ticket-dialog,html[data-theme="dark"] .ticket-table,html[data-theme="dark"] .profile-form,html[data-theme="dark"] .ticket-toolbar select,html[data-theme="dark"] .portal-ticket-search,html[data-theme="dark"] .compact-filter select,html[data-theme="dark"] .profile-form input { background:var(--page);color:var(--ink) }
html[data-theme="dark"] .kpi,html[data-theme="dark"] .customer-updates,html[data-theme="dark"] .profile-hero,html[data-theme="dark"] .portal-feedback-form,html[data-theme="dark"] .portal-feedback-item,html[data-theme="dark"] .response-moment,html[data-theme="dark"] .channel-card,html[data-theme="dark"] .ai-placeholder { background:var(--surface); }
html[data-theme="dark"] .ticket-table th,html[data-theme="dark"] .channel-detail-row:hover,html[data-theme="dark"] .ticket-table tbody tr:hover { background:#242b3b; }
html[data-theme="dark"] .sync-label-button { background:var(--surface); color:var(--ink); }
html[data-theme="dark"] .sync-label-button:hover { background:#2b203b; color:#a87ee0; border-color:#6906cd; }
html[data-theme="dark"] .response-moment header { background: linear-gradient(90deg, rgba(105,6,205,.1), transparent); }
html[data-theme="dark"] .portal-review-note { background:#2d2308; color:#fcd34d; border-color:#b45309; }
html[data-theme="dark"] .portal-exclusion-reason { background:#1e2535; color:#94a3b8; border-color:#354055; }
html[data-theme="dark"] .portal-exclusion-banner { background:#1e2535; color:#94a3b8; border-color:#354055; }
html[data-theme="dark"] .response-moment.is-excluded { opacity:.85; }
html[data-theme="dark"] .response-card { background:var(--surface); }
html[data-theme="dark"] .panel-intro { background:#1e2535; color:#94a3b8; border-color:#354055; }
html[data-theme="dark"] .view-tabs button small { color:var(--muted); }
html[data-theme="dark"] .view-tabs button.active small { color:#a87ee0; }
html[data-theme="dark"] .billing-badge.approved { color:#c4a0f5; background:rgba(105,6,205,.18); }

/* ── Sidebar layout ────────────────────────────────────────────────────── */
.dashboard-layout { display: flex; align-items: flex-start; gap: 0; margin-top: 28px; }
.dashboard-content { flex: 1; min-width: 0; padding-left: 32px; }

/* ── Sidebar navigation ────────────────────────────────────────────────── */
.view-tabs {
  display: flex;
  width: 210px;
  min-width: 210px;
  flex-direction: column;
  border-bottom: none;
  border-right: 1px solid var(--line);
  margin-top: 0;
  gap: 2px;
  padding: 4px 0;
  position: sticky;
  top: 80px;
  max-height: calc(100vh - 100px);
  overflow-y: auto;
  overflow-x: hidden;
}
.view-tabs button {
  flex: none;
  width: 100%;
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 12px;
  padding: 12px 16px 12px 18px;
  font-size: 15px;
  font-weight: 900;
  border-radius: 6px 0 0 6px;
  border-bottom: 0;
  border-left: 3px solid transparent;
  margin-bottom: 0;
  text-align: left;
  transition: background .14s ease, color .14s ease, border-color .14s ease;
}
.view-tabs button svg { width: 18px; height: 18px; flex-shrink: 0; }
.view-tabs button span { display: flex; flex-direction: column; gap: 1px; }
.view-tabs button:hover { background: rgba(105, 6, 205, .06); color: var(--brand); border-left-color: rgba(105, 6, 205, .25); }
.view-tabs button.active { color: var(--brand); border-left-color: var(--brand); background: rgba(105, 6, 205, .07); }
.view-tabs button small {
  display: block;
  font-size: 11px;
  font-weight: 600;
  color: var(--muted);
  line-height: 1.2;
  opacity: .85;
}
.view-tabs button.active small { color: var(--brand); opacity: 1; }
.view-tabs button:hover small { opacity: 1; }


/* ── Section headings ─────────────────────────────────────────────────── */
.section-heading { padding-bottom: 18px; margin-bottom: 28px; border-bottom: 1px solid var(--line); }
.section-heading h2 { font-size: 20px; font-weight: 800; letter-spacing: -.025em; }
.report-section > .section-heading::after {
  display: none; /* no decorative line — the border-bottom is enough */
}

/* ── Panel intro (uitleg per tab) ─────────────────────────────────────── */
.panel-intro {
  margin: -12px 0 24px;
  padding: 12px 16px;
  border-left: 3px solid rgba(105, 6, 205, .3);
  border-radius: 0 8px 8px 0;
  background: linear-gradient(90deg, rgba(105, 6, 205, .04), transparent);
  color: var(--muted);
  font-size: 13px;
  line-height: 1.55;
}
.panel-intro b { color: var(--ink); font-weight: 700; }

/* ── Billing badge: distinguish approved from finalized ───────────────── */
.billing-badge.approved { color: #5200a8; background: rgba(105, 6, 205, .1); }

/* ── Ticket table polish ──────────────────────────────────────────────── */
.ticket-table tbody tr:last-child td { border-bottom: 0; }
.ticket-table td strong { font-size: 13px; font-weight: 700; }
.ticket-table-wrap { box-shadow: var(--shadow); }

/* ── KPI cards: slightly more modern ─────────────────────────────────── */
.kpi { border-radius: 10px; }
.kpi-grid { gap: 14px; }
.sync-label-button { display: inline-flex; align-items: center; gap: 6px; min-height: 36px; padding: 0 14px; border: 1px solid var(--line); border-radius: 8px; background: #fff; color: var(--ink); font-size: 13px; font-weight: 700; cursor: pointer; transition: border-color .14s, background .14s; }
.sync-label-button:hover { border-color: var(--brand); background: #f8f2ff; color: var(--brand); }
.sync-label-button svg { width: 14px; height: 14px; }
.sync-label-button:disabled { opacity: .55; cursor: not-allowed; }

/* ── Response cards ───────────────────────────────────────────────────── */
.response-card { border-radius: 10px; }
.response-card-value { font-size: 38px; letter-spacing: -.03em; }

@media print { .topbar,.heading-actions,.view-tabs,.customer-updates,.ticket-toolbar,.ticket-table-wrap,.profile-page,.feedback-layout,.ticket-dialog{display:none!important}.page-shell{max-width:none;padding:0}.kpi-grid{grid-template-columns:repeat(3,1fr)!important}.report-section[hidden]{display:none!important}.report-section[data-panel="overview"]{display:block!important}.kpi{box-shadow:none;break-inside:avoid} }
@media(max-width:800px){.handled-kpis{grid-template-columns:1fr}.channel-detail-row{grid-template-columns:1fr 24px}.channel-metrics{grid-column:1/-1;grid-template-columns:1fr}.channel-stat-grid{grid-template-columns:1fr}.profile-grid{grid-template-columns:1fr}.ticket-summary{grid-template-columns:repeat(2,1fr)}.response-moment dl{grid-template-columns:1fr}.response-moment dl div{border-right:0}.response-grid{grid-template-columns:1fr}.dashboard-layout{flex-direction:column}.view-tabs{width:100%;min-width:0;flex-direction:row;border-right:none;border-bottom:2px solid var(--line);position:relative;top:auto;max-height:none;overflow-x:auto;overflow-y:hidden;padding:0;gap:0}.view-tabs button{flex:none;flex-direction:column;align-items:center;border-left:0;border-bottom:3px solid transparent;border-radius:0;padding:10px 14px;font-size:13px;gap:6px}.view-tabs button.active{border-left-color:transparent;border-bottom-color:var(--brand)}.view-tabs button svg{width:16px;height:16px}.dashboard-content{padding-left:0;padding-top:20px}}
@media(max-width:800px){.feedback-layout{grid-template-columns:1fr}}

/* ── Preview-modus banner ─────────────────────────────────────────────── */
.preview-banner {
  position: sticky;
  top: 68px; /* stacks directly under the 68px topbar when scrolling */
  z-index: 150;
  padding: 10px 20px;
  background: linear-gradient(90deg, #5200a8, #6906cd);
  color: #fff;
  font-size: 13px;
  font-weight: 700;
  text-align: center;
  letter-spacing: .01em;
  box-shadow: 0 2px 8px rgba(105,6,205,.25);
}

/* ── Export contact note ──────────────────────────────────────────────── */
.export-contact-note { margin: 6px 0 0; font-size: 12px; color: var(--muted); }
.export-contact-note a { color: var(--muted); text-decoration: underline; text-decoration-color: transparent; transition: color .14s, text-decoration-color .14s; }
.export-contact-note a:hover { color: var(--brand); text-decoration-color: currentColor; }

/* ── Pagination ───────────────────────────────────────────────────────── */
.ticket-pagination { margin-top: 16px; }
.pagination-controls { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; padding: 10px 0; }
.pagination-size { display: inline-flex; align-items: center; gap: 8px; color: var(--muted); font-size: 12px; font-weight: 700; }
.pagination-size select { min-height: 36px; padding: 0 10px; border: 1px solid var(--line); border-radius: 8px; background: #fff; color: var(--ink); font-size: 13px; cursor: pointer; }
.pagination-nav { display: flex; align-items: center; gap: 10px; }
.pagination-btn { min-height: 36px; min-width: 80px; padding: 0 14px; border: 1px solid var(--line); border-radius: 8px; background: #fff; color: var(--ink); font-size: 13px; font-weight: 700; cursor: pointer; transition: border-color .14s, background .14s, color .14s; }
.pagination-btn:hover:not(:disabled) { border-color: var(--brand); background: #f8f2ff; color: var(--brand); }
.pagination-btn:disabled { opacity: .45; cursor: not-allowed; }
.pagination-info { color: var(--muted); font-size: 13px; white-space: nowrap; }
html[data-theme="dark"] .pagination-size select,
html[data-theme="dark"] .pagination-btn { background: var(--surface); color: var(--ink); }

/* ── Responsive table columns ─────────────────────────────────────────── */
@media(max-width:960px) { .col-desktop { display: none !important; } }
@media(max-width:600px) { .col-tablet { display: none !important; } }

/* ── Hamburger button (hidden on desktop) ─────────────────────────────── */
.menu-toggle { display: none; }
.nav-overlay { display: none; position: fixed; inset: 0; z-index: 190; background: rgba(23,32,51,.55); }
.nav-overlay.active { display: block; }

/* ── Mobile nav: hamburger slide-in (≤767px) ─────────────────────────── */
@media(max-width:767px) {
  .menu-toggle { display: flex; }
  .topbar { gap: 6px; }

  /* Override the horizontal tab bar from the 800px breakpoint */
  .view-tabs {
    position: fixed !important;
    top: 0 !important;
    left: -260px !important;
    width: 240px !important;
    min-width: 0 !important;
    height: 100dvh !important;
    z-index: 200;
    background: var(--surface, #fff);
    border-right: 1px solid var(--line) !important;
    border-bottom: none !important;
    flex-direction: column !important;
    transition: left .22s ease;
    padding: 60px 0 16px !important;
    max-height: 100dvh !important;
    overflow-y: auto !important;
    overflow-x: hidden !important;
    gap: 2px !important;
  }
  .view-tabs.nav-open { left: 0 !important; box-shadow: 4px 0 24px rgba(31,41,55,.2); }
  .view-tabs button {
    flex-direction: row !important;
    align-items: center !important;
    justify-content: flex-start !important;
    border-left: 3px solid transparent !important;
    border-bottom: 0 !important;
    border-radius: 6px 0 0 6px !important;
    padding: 12px 16px 12px 18px !important;
    font-size: 15px !important;
    gap: 12px !important;
    min-height: 44px;
  }
  .view-tabs button.active { border-left-color: var(--brand) !important; border-bottom-color: transparent !important; background: rgba(105,6,205,.07); }
  .view-tabs button svg { width: 18px !important; height: 18px !important; }
  .view-tabs button span { display: flex !important; flex-direction: column !important; gap: 1px !important; align-items: flex-start !important; }
  html[data-theme="dark"] .view-tabs { background: var(--page); }

  /* Filters stack vertically */
  .ticket-toolbar { flex-direction: column; align-items: stretch; gap: 10px; }
  .ticket-toolbar label { width: 100%; }
  .ticket-toolbar label select, .portal-ticket-search { width: 100%; min-width: 0; box-sizing: border-box; }

  /* KPI cards single column — override the 800px 1-column already set */
  .handled-kpis { grid-template-columns: 1fr !important; }

  /* Touch targets */
  .primary-button, .secondary-button, .sync-label-button { min-height: 44px; }
  .icon-button { min-width: 44px; min-height: 44px; }

  /* Pagination on mobile */
  .pagination-controls { flex-direction: column; align-items: flex-start; gap: 8px; }
  .pagination-nav { width: 100%; justify-content: space-between; }
}
