/* Rigonic Ticket Studio — separate overview and per-topic workspaces */
.rg-dashboard-body .ts-studio,.rg-dashboard-body .settings-page:has(.ts-form-nav){min-width:0;max-width:none}
.rg-dashboard-body .ts-studio{display:block}
.rg-dashboard-body .ts-head{display:flex;justify-content:space-between;align-items:end;gap:24px;margin-bottom:22px;background:linear-gradient(125deg,#0d233b,#0b1829);border:1px solid #294867;padding:27px}
.rg-dashboard-body .ts-head h1{font-size:clamp(30px,3vw,45px);letter-spacing:-.055em;margin:9px 0}
.rg-dashboard-body .ts-head p{margin:0;color:#acc4dc;max-width:600px;line-height:1.7}
.rg-dashboard-body .ts-primary{display:inline-flex;gap:9px;align-items:center;justify-content:center;background:#1b89ff;color:#fff;padding:15px 21px;font-size:13px;font-weight:800;white-space:nowrap;text-decoration:none}
.rg-dashboard-body .ts-tabs{display:flex;align-items:stretch;gap:8px;overflow-x:auto;scrollbar-width:thin;padding:0 0 14px;min-width:0}
.rg-dashboard-body .ts-tabs a{display:flex;align-items:center;gap:9px;min-width:max-content;max-width:240px;padding:13px 15px;background:#0b1a2b;border:1px solid #29425b;color:#c6dbf0;text-decoration:none;font-weight:750;font-size:12px}
.rg-dashboard-body .ts-tabs a.is-active,.rg-dashboard-body .ts-tabs a:hover{background:#133557;border-color:#3797ed;color:#fff}
.rg-dashboard-body .ts-tab-emoji{font-size:17px}
.rg-dashboard-body .ts-statusbar{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:12px;margin-bottom:26px}
.rg-dashboard-body .ts-statusbar>div{display:flex;align-items:center;justify-content:space-between;gap:14px;padding:17px 21px;border:1px solid #2a425d;background:#0c1b2d}
.rg-dashboard-body .ts-statusbar span{color:#88aacc;font-size:10px;letter-spacing:.15em;font-weight:800}
.rg-dashboard-body .ts-statusbar b{color:#fff;font-size:15px}
.rg-dashboard-body .ts-section-head{display:flex;align-items:end;justify-content:space-between;gap:14px;margin:0 0 18px}
.rg-dashboard-body .ts-section-head h2{font-size:28px;letter-spacing:-.05em;margin:8px 0 0}
.rg-dashboard-body .ts-section-head a{display:inline-flex;gap:10px;align-items:center;padding:11px 15px;color:#b7ddff;border:1px solid #31567a;background:#0e2338;text-decoration:none;font-weight:700}
.rg-dashboard-body .ts-topic-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:14px}
.rg-dashboard-body .ts-topic-card{min-width:0;display:flex;flex-direction:column;gap:12px;padding:22px;background:linear-gradient(145deg,#0e2137,#0b1728);border:1px solid #2e4a66;color:#f3f8ff;text-decoration:none;min-height:218px;transition:transform .18s,border-color .18s}
.rg-dashboard-body .ts-topic-card:hover{border-color:#49a2fc;transform:translateY(-2px)}
.rg-dashboard-body .ts-topic-card-top{display:flex;justify-content:space-between;align-items:center}
.rg-dashboard-body .ts-emoji{width:52px;height:52px;display:grid;place-items:center;background:#193c5e;border:1px solid #2f648f;font-size:26px}
.rg-dashboard-body .ts-index{color:#7099c1;font:800 11px Inter,sans-serif;letter-spacing:.15em}
.rg-dashboard-body .ts-topic-card h3{font-size:22px;letter-spacing:-.04em;margin:5px 0 0;line-height:1.25;overflow-wrap:anywhere}
.rg-dashboard-body .ts-topic-info{display:flex;gap:12px;flex-wrap:wrap;color:#a8c0da;font-size:12px}.rg-dashboard-body .ts-topic-info span{display:flex;gap:8px;align-items:center}.rg-dashboard-body .ts-topic-info i{color:#67b5fa}
.rg-dashboard-body .ts-topic-edit{display:flex;justify-content:space-between;align-items:center;gap:10px;border-top:1px solid #30485f;margin-top:auto;padding-top:13px;font-size:12px;font-weight:800;color:#9ad0ff}
.rg-dashboard-body .ts-footnote{display:flex;gap:10px;align-items:start;margin:24px 0;padding:14px 18px;border:1px solid #284765;background:#0d2337;font-size:12px;color:#aac6e1;line-height:1.65}.rg-dashboard-body .ts-footnote i{margin-top:3px;color:#6ebaff}
.rg-dashboard-body .ts-form-nav{max-width:100%;margin-bottom:22px;padding:14px 17px;border:1px solid #28455f;background:#0c1e30}
.rg-dashboard-body .settings-page:has(.ts-form-nav) .module-page-identity h1{font-size:clamp(26px,3vw,44px)!important}
.rg-dashboard-body .settings-page:has(.ts-form-nav) .module-page-grid{grid-template-columns:minmax(0,1fr) 260px!important;align-items:start}
.rg-dashboard-body .settings-page:has(.ts-form-nav) .module-form-v4{min-width:0!important;width:100%!important}
.rg-dashboard-body .settings-page:has(.ts-form-nav) .module-fields-v4{display:grid!important;grid-template-columns:repeat(2,minmax(0,1fr))!important;gap:15px!important}
.rg-dashboard-body .settings-page:has(.ts-form-nav) .settings-section-v6{grid-column:1/-1!important;border-left:3px solid #1b89ff!important}
.rg-dashboard-body .settings-page:has(.ts-form-nav) .field-v4{min-width:0!important;overflow:visible!important}
.rg-dashboard-body .settings-page:has(.ts-form-nav) .field-v4:has([name$='_message']),.rg-dashboard-body .settings-page:has(.ts-form-nav) .field-v4:has([name$='_title']){grid-column:1/-1}
.rg-dashboard-body .settings-page:has(.ts-form-nav) .module-live-preview-v10{width:100%!important;max-width:none!important}
/* Actual select retains its name/value for MySQL config saves. This is presentation only. */
.rg-dashboard-body .ts-resource-select{position:relative;min-width:0}
.rg-dashboard-body .ts-resource-select>select{position:absolute!important;opacity:0!important;pointer-events:none!important;width:1px!important;height:1px!important;left:0;top:0}
.rg-dashboard-body .ts-resource-trigger{display:flex!important;justify-content:space-between!important;align-items:center!important;gap:12px!important;width:100%!important;min-height:45px!important;background:#081a2d!important;border:1px solid #365574!important;color:#f1f7ff!important;text-align:left!important;padding:12px 13px!important;font-size:12px!important;line-height:1.4!important;overflow-wrap:anywhere}
.rg-dashboard-body .ts-resource-trigger i{color:#7ebdf5;flex-shrink:0}
.rg-dashboard-body .ts-resource-select.is-open .ts-resource-trigger,.rg-dashboard-body .ts-resource-trigger:hover{border-color:#4da6fd!important}
.rg-dashboard-body .ts-resource-popover{display:none;position:absolute;z-index:160;left:0;right:0;top:calc(100% + 5px);padding:7px;background:#0b1d32;border:1px solid #43688d;box-shadow:0 18px 34px #0008;min-width:min(280px,calc(100vw - 54px))}
.rg-dashboard-body .ts-resource-select.is-open .ts-resource-popover{display:block}
.rg-dashboard-body .ts-resource-search{width:100%!important;background:#071624!important;border:1px solid #345371!important;min-height:40px!important;padding:10px!important;color:white!important}
.rg-dashboard-body .ts-resource-options{max-height:260px;overflow:auto;margin-top:8px;display:grid;gap:3px}
.rg-dashboard-body .ts-resource-choice{display:block!important;width:100%!important;text-align:left!important;padding:11px 12px!important;border:0!important;background:#0b1d32!important;color:#e8f4ff!important;font-size:12px!important;font-weight:600!important}
.rg-dashboard-body .ts-resource-choice:hover,.rg-dashboard-body .ts-resource-choice[aria-selected='true']{background:#17416a!important;color:#fff!important}
.rg-dashboard-body .ts-resource-empty{font-size:12px;padding:12px;color:#a4bdd7}
/* Better mobile widths: no cut-off fields or nested scrollbars */
@media(max-width:1140px){.rg-dashboard-body .ts-topic-grid{grid-template-columns:repeat(2,minmax(0,1fr))}.rg-dashboard-body .settings-page:has(.ts-form-nav) .module-page-grid{grid-template-columns:1fr!important}}
@media(max-width:760px){
 .rg-dashboard-body .ts-head{align-items:flex-start;flex-direction:column;padding:19px}
 .rg-dashboard-body .ts-statusbar{grid-template-columns:1fr}
 .rg-dashboard-body .ts-topic-grid{grid-template-columns:1fr}
 .rg-dashboard-body .ts-section-head{align-items:flex-start;flex-direction:column}
 .rg-dashboard-body .settings-page:has(.ts-form-nav) .module-fields-v4{grid-template-columns:1fr!important}
 .rg-dashboard-body .settings-page:has(.ts-form-nav) .field-v4{grid-column:1/-1!important}
 .rg-dashboard-body .ts-form-nav{padding:11px}
}
