/* Customer support page. It runs inside the shared account shell (style.css, brand.css, account-page.css and
   workspace-chrome.css, body.account-page), so the frame, headings, labels, inputs and buttons come from there.
   Only the support-specific pieces live here. No inline styles: the CSP only allows style-src 'self'. */

/* Left column: the safety reminder sits under the description, like a small callout. */
.settings-description .sp-safety{margin:18px 0 0;padding:12px 14px;border-left:2px solid var(--umt-accent);background:var(--umt-tint);color:var(--umt-ink);font-size:12px;line-height:1.7;max-width:260px}

/* Right column: the app swaps a notice, a refresh stamp and the views in here. Each view is one card. */
/* The refresh stamp (the panel's own small note) reads as small print under the cards; errors stay on top. */
.sp-panel{min-width:0;display:flex;flex-direction:column}
.sp-panel>.sp-note{order:1;margin:14px 0 0}.sp-panel>.sp-note:empty{margin:0}
.sp-new,.sp-list,.sp-thread{background:var(--umt-surface);border:1px solid var(--umt-line);border-radius:10px;padding:28px;min-width:0}
.sp-new+div{margin-top:24px}
.support-page .sp-new h2,.support-page .sp-list h2,.support-page .sp-thread-title{font-size:19px;font-weight:700;line-height:1.3;letter-spacing:-.03em;margin:0 0 18px;outline:none;overflow-wrap:anywhere}
.support-page .sp-thread-title{margin:20px 0 6px}

/* Status lines: the same small print as the rest of the app. Empty ones keep their place in the page (they are live
   regions) but take no space. */
.sp-note,.sp-error{font-size:12px;line-height:1.7;margin:0 0 12px;overflow-wrap:anywhere}
.sp-note{color:var(--umt-muted)}
.sp-error{color:var(--umt-accent)}
.sp-note:empty,.sp-error:empty{margin:0}
.sp-new>.sp-note,.sp-new>.sp-error,.sp-thread>.sp-note,.sp-thread>.sp-error{margin:12px 0 0}
.sp-new>.sp-note:empty,.sp-new>.sp-error:empty,.sp-thread>.sp-note:empty,.sp-thread>.sp-error:empty{margin:0}

/* Fields: label text and controls match the account settings form. */
.support-page .sp-field{display:block;margin:0 0 22px;font-size:12px;font-weight:550}
.support-page .sp-label{display:block;float:none;margin:0 0 9px;color:var(--umt-ink);font-size:12px;font-weight:550}
.support-page .sp-field input{margin:0}
.support-page .sp-field textarea{display:block;width:100%;min-height:132px;margin:0;border:1px solid #d9d6cc;border-radius:6px;background:#fffefb;padding:10px 12px;color:var(--umt-ink);font:14px/1.6 'UMT Sans',sans-serif;resize:vertical}
.support-page .sp-field textarea::placeholder{color:#8a867d}

/* Actions row: button, then the character counter as small print. */
.sp-row{display:flex;flex-wrap:wrap;gap:10px;align-items:center}
.sp-counter{color:#77736b;font-size:11px;font-variant-numeric:tabular-nums}
.sp-counter.over{color:var(--umt-accent);font-weight:600}
/* Secondary buttons use the app's quiet button. Primary buttons keep the account accent button as is. */
.support-page button.sp-btn:not(.primary){background:transparent;border-color:var(--umt-line);color:var(--umt-ink)}
.support-page button.sp-btn:not(.primary):hover:not(:disabled){background:var(--umt-soft)}

/* Ticket list: rows like the account usage list, each row one button. */
.sp-tickets{list-style:none;margin:0;padding:0;border-top:1px solid #eeeae2}
.support-page button.sp-ticket{display:block;width:100%;min-height:0;margin:0;padding:14px 10px;border:0;border-bottom:1px solid #eeeae2;border-radius:0;background:transparent;color:var(--umt-ink);text-align:left;font:400 13px/1.5 'UMT Sans',sans-serif}
.support-page button.sp-ticket:hover{background:var(--umt-paper)}
.support-page button.sp-ticket:hover .sp-subject{color:var(--umt-accent)}
.sp-ticket-top{display:flex;gap:8px;align-items:center}
.sp-ticket .sp-meta{display:block;margin-top:4px}
.sp-subject{font-weight:550;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;min-width:0;flex:1}
.sp-dot{flex:none;width:8px;height:8px;border-radius:50%;background:var(--umt-accent)}
.sp-new-reply{flex:none;font-size:10px;color:var(--umt-accent);font-weight:600;letter-spacing:.02em}
.sp-meta{color:#77736b;font-size:11px;line-height:1.6;overflow-wrap:anywhere}

/* Status badges: the account page's small label. */
.sp-badge{display:inline-block;flex:none;font-size:10px;line-height:1.2;padding:5px 8px;border-radius:4px;background:var(--umt-soft);color:var(--umt-ink)}
.sp-badge.status-open{background:var(--umt-tint);color:var(--umt-accent)}
.sp-badge.status-closed{color:var(--umt-muted)}

/* Thread view. */
.sp-thread-head{display:flex;flex-wrap:wrap;gap:10px;align-items:center;justify-content:space-between}
.sp-messages{display:flex;flex-direction:column;gap:10px;margin:20px 0}
.sp-msg{max-width:85%;padding:12px 14px;border-radius:10px;border:1px solid var(--umt-line)}
.sp-msg.you{align-self:flex-end;background:#f9ede6;border-color:#e5c8b8}
.sp-msg.support{align-self:flex-start;background:var(--umt-soft)}
.sp-msg-who{font-size:11px;color:#77736b;margin:0 0 4px}
.sp-msg-body{margin:0;font-size:13px;line-height:1.7;white-space:pre-wrap;overflow-wrap:anywhere}
.sp-reply{margin-top:20px;padding-top:20px;border-top:1px solid var(--umt-line)}

@media(max-width:650px){
 .sp-new,.sp-list,.sp-thread{padding:22px 18px}
 .settings-description .sp-safety{max-width:none}
 .support-page .sp-field textarea{font-size:16px}
 .sp-msg{max-width:100%}
}
