/* Starkwood ONE v2.1.99 — Sales Performance single-mount / duplicate-load repair */
.sw-sales-performance-original-v2199{display:none!important}
.sw-sales-performance-v2199{padding:2rem;min-width:0;color:#1e293b}
.sw-sales-performance-v2199 *{box-sizing:border-box}
.sw-sp-page-inner{display:flex;flex-direction:column;gap:1.5rem;max-width:100%}
.sw-sp-page-head{display:flex;align-items:flex-start;justify-content:space-between;gap:1.25rem}
.sw-sp-page-head h1{margin:0;color:#1e293b;font-size:1.25rem;line-height:1.45;font-weight:800}
.sw-sp-page-head p{margin:.25rem 0 0;color:#64748b;font-size:.875rem;line-height:1.45;max-width:880px}
.sw-sp-head-actions{display:flex;align-items:center;justify-content:flex-end;gap:.5rem;flex-wrap:wrap;flex:none}
.sw-sp-head-actions select,.sw-sp-exec-filters select,.sw-sp-log-filters select,.sw-sp-history-controls select{height:38px;border:1px solid #dce3ef;background:#fff;border-radius:10px;padding:0 34px 0 12px;color:#334155;font-size:12px;outline:none}
.sw-sp-backup-btn,.sw-sp-generate-btn,.sw-sp-exec-filters button{display:inline-flex;align-items:center;justify-content:center;gap:.42rem;height:38px;border-radius:10px;padding:0 13px;font-size:12px;font-weight:700;cursor:pointer;white-space:nowrap}
.sw-sp-backup-btn{background:#fff;color:#0b9a68;border:1px solid #12a874}
.sw-sp-backup-btn:hover{background:#f0fbf7}
.sw-sp-generate-btn,.sw-sp-exec-filters button{background:#2e5ae8;color:#fff;border:1px solid #2e5ae8}
.sw-sp-generate-btn:hover,.sw-sp-exec-filters button:hover{filter:brightness(.96)}
.sw-sp-backup-btn:disabled,.sw-sp-generate-btn:disabled,.sw-sp-exec-filters button:disabled{opacity:.58;cursor:wait}
.sw-sp-target-card{display:flex;align-items:center;gap:1.5rem;padding:1rem;background:#fff;border:1px solid #eef0f5;border-radius:16px;box-shadow:0 1px 2px rgba(15,23,42,.03),0 10px 26px rgba(15,23,42,.035)}
.sw-sp-target-main{flex:1;min-width:0}
.sw-sp-eyebrow{text-transform:uppercase;letter-spacing:.055em;color:#64748b;font-size:11px;font-weight:700}
.sw-sp-target-value{font-size:18px;line-height:1.3;color:#1e293b;font-weight:800;margin-top:3px}
.sw-sp-target-value span{font-size:13px;color:#94a3b8;font-weight:400}
.sw-sp-target-empty{margin-top:3px;font-size:14px;color:#94a3b8}
.sw-sp-progress{height:8px;background:#f1f5f9;border-radius:999px;margin-top:8px;overflow:hidden}
.sw-sp-progress i{height:100%;display:block;border-radius:999px;transition:width .2s ease}
.sw-sp-target-editor{display:flex;align-items:center;gap:.5rem;white-space:nowrap;font-size:12px;color:#94a3b8}
.sw-sp-money-input{height:36px;width:150px;display:flex;align-items:center;border:1px solid #dce3ef;border-radius:9px;background:#fff;overflow:hidden}
.sw-sp-money-input b{padding-left:10px;color:#94a3b8;font-size:15px}
.sw-sp-money-input input{min-width:0;width:100%;height:100%;border:0;outline:none;background:transparent;padding:0 9px;font:inherit;color:#334155}
.sw-sp-grid{display:grid;gap:1rem;min-width:0}
.sw-sp-grid-4{grid-template-columns:repeat(4,minmax(0,1fr))}
.sw-sp-grid-3{grid-template-columns:repeat(3,minmax(0,1fr))}
.sw-sp-grid-2{grid-template-columns:repeat(2,minmax(0,1fr))}
.sw-sp-gap-top{margin-top:.8rem}
.sw-sp-stat-card{background:#fff;border:1px solid #eef0f5;border-radius:16px;padding:1.15rem;min-width:0;box-shadow:0 1px 2px rgba(15,23,42,.035),0 8px 24px rgba(15,23,42,.035)}
.sw-sp-stat-icon{width:42px;height:42px;border-radius:12px;display:flex;align-items:center;justify-content:center;margin-bottom:.85rem}
.sw-sp-stat-value{font-size:1.55rem;line-height:1.1;font-weight:800;word-break:break-word}
.sw-sp-stat-label{font-size:.875rem;color:#64748b;margin-top:.42rem;line-height:1.35}
.sw-sp-stat-sub{font-size:.73rem;color:#94a3b8;margin-top:.3rem;line-height:1.35}
.sw-sp-charts-row{display:grid;grid-template-columns:minmax(300px,1fr) minmax(0,2fr);gap:1rem}
.sw-sp-chart-card,.sw-sp-panel,.sw-sp-history-total{background:#fff;border:1px solid #eef0f5;border-radius:16px;padding:1.25rem;box-shadow:0 1px 2px rgba(15,23,42,.03),0 8px 24px rgba(15,23,42,.03);min-width:0}
.sw-sp-chart-heading{font-size:.875rem;font-weight:700;color:#334155;margin-bottom:.5rem}
.sw-sp-donut-wrap{display:flex;justify-content:center;align-items:center;height:180px}
.sw-sp-donut{width:150px;height:150px;border-radius:50%;position:relative}
.sw-sp-donut:after{content:"";position:absolute;inset:30px;border-radius:50%;background:#fff}
.sw-sp-donut>div{position:absolute;z-index:2;inset:0;display:flex;flex-direction:column;align-items:center;justify-content:center}
.sw-sp-donut b{font-size:24px;line-height:1;color:#1e293b}
.sw-sp-donut span{font-size:10px;color:#94a3b8;margin-top:4px}
.sw-sp-legend{display:flex;flex-wrap:wrap;gap:6px 12px;margin-top:4px}
.sw-sp-legend span{display:flex;align-items:center;gap:6px;color:#64748b;font-size:11px}
.sw-sp-legend i{width:8px;height:8px;border-radius:50%;display:inline-block}
.sw-sp-horizontal-bars{height:190px;overflow:auto;padding:4px 2px 0}
.sw-sp-hbar-row{display:grid;grid-template-columns:minmax(90px,170px) minmax(90px,1fr) auto;gap:9px;align-items:center;margin:8px 0}
.sw-sp-hbar-label{white-space:nowrap;overflow:hidden;text-overflow:ellipsis;color:#64748b;font-size:11px}
.sw-sp-hbar-track{height:14px;border-radius:6px;background:#f1f5f9;overflow:hidden}
.sw-sp-hbar-track i{display:block;height:100%;background:#2e5ae8;border-radius:6px}
.sw-sp-hbar-value{font-size:11px;font-weight:700;color:#475569;text-align:right;min-width:60px}
.sw-sp-empty-chart,.sw-sp-empty-cell{text-align:center!important;color:#94a3b8!important;padding:24px!important;font-size:12px!important;font-weight:400!important}
.sw-sp-overview-sections{display:flex;flex-direction:column;gap:1.5rem}
.sw-sp-overview-sections>section{min-width:0}
.sw-sp-section-title{display:flex;align-items:center;gap:.5rem;margin:0 0 .75rem;font-size:.9rem;color:#334155;min-width:0}
.sw-sp-section-title strong{font-weight:800}
.sw-sp-type-badges{display:flex;flex-wrap:wrap;gap:.45rem;margin-top:.75rem}
.sw-sp-type-badges span{background:#eef4ff;color:#2e5ae8;border-radius:999px;padding:.3rem .6rem;font-size:11px;font-weight:650}
.sw-sp-sales-log-section{border-top:1px solid #e2e8f0;padding-top:.35rem}
.sw-sp-sales-log-toggle{width:100%;display:flex;align-items:center;justify-content:space-between;gap:1rem;background:transparent;border:0;padding:1rem 0 .5rem;cursor:pointer;color:inherit}
.sw-sp-sales-log-toggle .sw-sp-section-title{margin:0}
.sw-sp-chevron{color:#94a3b8;display:flex;transition:transform .15s ease}
.sw-sp-chevron.is-open{transform:rotate(90deg)}
.sw-sp-sales-log-body{padding-top:.5rem}
.sw-sp-log-filters{display:flex;align-items:flex-end;gap:.75rem;flex-wrap:wrap;margin-bottom:1rem}
.sw-sp-log-filters label{display:flex;flex-direction:column;gap:4px}
.sw-sp-log-filters label>span{font-size:10px;color:#94a3b8;font-weight:600}
.sw-sp-log-total{margin-left:auto;text-align:right;display:flex;flex-direction:column;gap:2px}
.sw-sp-log-total span{font-size:10px;color:#94a3b8}
.sw-sp-log-total strong{font-size:14px;color:#1e293b}
.sw-sp-table-wrap{background:#fff;border:1px solid #eef0f5;border-radius:16px;overflow:auto;box-shadow:0 1px 2px rgba(15,23,42,.025);max-width:100%}
.sw-sp-table{width:100%;border-collapse:collapse;font-size:12px;min-width:820px}
.sw-sp-table th{text-align:left;font-size:10.5px;color:#94a3b8;font-weight:600;padding:.7rem 1rem;border-bottom:1px solid #eef0f5;background:#fff;white-space:nowrap}
.sw-sp-table td{padding:.8rem 1rem;border-bottom:1px solid #f5f6f8;color:#64748b;vertical-align:top;line-height:1.35}
.sw-sp-table tbody tr:last-child td{border-bottom:0}
.sw-sp-table tbody tr:hover td{background:#fbfcfe}
.sw-sp-table td strong{color:#334155;font-weight:700}
.sw-sp-table td small{display:block;color:#94a3b8;font-size:10px;margin-top:2px}
.sw-sp-table th button{border:0;background:transparent;padding:0;color:inherit;font:inherit;font-weight:600;cursor:pointer}
.sw-sp-table tfoot td{background:#f8fafc;border-top:1px solid #e2e8f0;border-bottom:0;color:#334155;font-weight:800}
.sw-sp-history-grid{display:grid;grid-template-columns:minmax(0,1fr) minmax(260px,.85fr);gap:1rem}
.sw-sp-history-head{display:flex;align-items:center;justify-content:space-between;gap:.7rem;flex-wrap:wrap;margin-bottom:.5rem}
.sw-sp-history-head .sw-sp-section-title{margin:0}
.sw-sp-history-controls{display:flex;align-items:center;gap:.45rem;flex-wrap:wrap}
.sw-sp-segmented{display:flex;gap:3px;background:#eef0f5;border-radius:9px;padding:3px}
.sw-sp-segmented button{border:0;background:transparent;color:#475569;border-radius:7px;padding:6px 9px;font-size:10px;font-weight:700;cursor:pointer}
.sw-sp-segmented button.active{background:#0b1739;color:#fff}
.sw-sp-history-controls select{height:32px;padding-top:0;padding-bottom:0}
.sw-sp-mini-chart{height:115px;display:flex;align-items:stretch;gap:4px;border-bottom:1px solid #eef0f5;padding:0 2px 22px;margin-top:8px}
.sw-sp-mini-bar{flex:1;min-width:0;display:flex;flex-direction:column;justify-content:flex-end;position:relative}
.sw-sp-mini-bar-area{height:88px;display:flex;align-items:flex-end;justify-content:center}
.sw-sp-mini-bar-area i{display:block;width:min(14px,70%);min-height:2px;background:#2e5ae8;border-radius:3px 3px 0 0}
.sw-sp-mini-bar>span{position:absolute;bottom:-19px;left:50%;transform:translateX(-50%);font-size:8.5px;color:#94a3b8;white-space:nowrap}
.sw-sp-history-total{display:flex;flex-direction:column;justify-content:center}
.sw-sp-history-total>span{font-size:10px;color:#94a3b8;text-transform:uppercase;letter-spacing:.06em;font-weight:700}
.sw-sp-history-total>div{display:flex;align-items:flex-end;gap:2rem;margin-top:.7rem}
.sw-sp-history-total>div>div{display:flex;flex-direction:column}
.sw-sp-history-total strong{font-size:1.75rem;line-height:1.1;color:#1e293b}
.sw-sp-history-total small{font-size:11px;color:#64748b;margin-top:4px}
.sw-sp-two-panel{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:1rem}
.sw-sp-dashcards{display:flex;gap:.7rem;flex-wrap:wrap}
.sw-sp-dashcards>div{min-width:110px;flex:1;background:#fff;border:1px solid #eef0f5;border-radius:12px;padding:.8rem}
.sw-sp-dashcards strong{display:block;color:#1e293b;font-size:1.25rem}
.sw-sp-dashcards span{display:block;color:#64748b;font-size:11px;margin-top:3px}
.sw-sp-dashcards small{display:block;color:#94a3b8;font-size:9px;margin-top:2px}
.sw-sp-exec-section{border-top:1px solid #e2e8f0;padding-top:1.5rem;min-width:0}
.sw-sp-exec-head h2{margin:0;color:#1e293b;font-size:1.08rem;font-weight:800}
.sw-sp-exec-head p{margin:.25rem 0 0;color:#64748b;font-size:.8rem;line-height:1.45;max-width:1000px}
.sw-sp-exec-filters{display:flex;align-items:center;gap:.65rem;flex-wrap:wrap;margin:1rem 0}
.sw-sp-exec-filters button{height:37px;font-size:11px;padding:0 14px}
.sw-sp-navy-summary{border-radius:16px;padding:1.25rem;color:#fff;background:#0b1739;margin-bottom:1rem}
.sw-sp-navy-summary .sw-sp-eyebrow{color:rgba(255,255,255,.6)}
.sw-sp-navy-main{display:flex;align-items:flex-end;gap:2rem;margin-top:.3rem}
.sw-sp-navy-main>div{display:flex;flex-direction:column}
.sw-sp-navy-main strong{font-size:1.75rem;line-height:1.1}
.sw-sp-navy-main span,.sw-sp-navy-split span{font-size:10px;color:rgba(255,255,255,.52);margin-top:3px}
.sw-sp-navy-split{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:.8rem;margin-top:1rem;padding-top:1rem;border-top:1px solid rgba(255,255,255,.11)}
.sw-sp-navy-split>div{display:flex;flex-direction:column}
.sw-sp-navy-split strong{font-size:12px}
.sw-sp-exec-table{margin-top:1rem}
.sw-sp-loading,.sw-sp-error{background:#fff;border:1px solid #eef0f5;border-radius:16px;padding:2rem;text-align:center;color:#64748b}
.sw-sp-error{display:flex;flex-direction:column;gap:.5rem;align-items:center}
.sw-sp-error strong{color:#b23b3b}
.sw-sp-error button{margin-top:.5rem;border:0;border-radius:9px;background:#2e5ae8;color:#fff;padding:.55rem 1rem;font-weight:700;cursor:pointer}

/* Report modal */
html.sw-sp-modal-open,html.sw-sp-modal-open body{overflow:hidden!important}
.sw-sp-report-modal{position:fixed;inset:0;z-index:999970;background:rgba(11,23,57,.62);display:flex;align-items:stretch;justify-content:center;padding:24px}
.sw-sp-report-shell{width:min(980px,96vw);height:100%;background:#dfe5ef;border-radius:14px;overflow:hidden;display:flex;flex-direction:column;box-shadow:0 20px 60px rgba(3,9,26,.35)}
.sw-sp-report-toolbar{height:48px;flex:none;background:#5f6b85;color:#fff;display:flex;align-items:center;justify-content:space-between;gap:1rem;padding:0 14px}
.sw-sp-report-toolbar>div:first-child{display:flex;align-items:baseline;gap:8px;min-width:0}
.sw-sp-report-toolbar strong{font-size:13px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.sw-sp-report-toolbar small{font-size:9px;color:rgba(255,255,255,.72);white-space:nowrap}
.sw-sp-report-toolbar>div:last-child{display:flex;gap:8px}
.sw-sp-report-toolbar button{height:32px;border:0;border-radius:8px;padding:0 12px;font-size:11px;font-weight:700;display:flex;align-items:center;gap:6px;cursor:pointer}
#sw-sp-print-report{background:#2e5ae8;color:#fff}
.sw-sp-close-report{background:#fff;color:#334155}
.sw-sp-report-scroll{flex:1;overflow:auto;padding:18px}
.sw-sp-report-paper{width:210mm;min-height:297mm;margin:0 auto;background:#fff;padding:16mm 17mm;box-shadow:0 2px 12px rgba(15,23,42,.18)}
.sw-sp-report-title-row{display:flex;justify-content:space-between;align-items:flex-start;border-bottom:1.5px solid #0b1739;padding-bottom:8px}
.sw-sp-report-title-row h2{font-size:17px;margin:0;color:#0b1739}
.sw-sp-report-title-row p{font-size:9.5px;color:#64748b;margin:3px 0 0}
.sw-sp-report-title-row span{font-size:9px;color:#94a3b8}
.sw-sp-report-period{font-size:9px;color:#64748b;margin:8px 0}
.sw-sp-report-summary{display:grid;grid-template-columns:repeat(5,minmax(0,1fr));gap:6px;margin:8px 0 12px}
.sw-sp-report-summary div{border:1px solid #e8edf5;border-radius:7px;padding:7px}
.sw-sp-report-summary span{display:block;font-size:8px;color:#94a3b8;text-transform:uppercase}
.sw-sp-report-summary strong{display:block;font-size:11px;margin-top:2px}
.sw-sp-report-table{width:100%;border-collapse:collapse;font-size:9px}
.sw-sp-report-table th{text-align:left;border-bottom:1px solid #94a3b8;padding:5px 4px;color:#475569}
.sw-sp-report-table td{border-bottom:1px solid #eef0f5;padding:5px 4px;vertical-align:top;color:#334155}
.sw-sp-report-foot{font-size:8px;color:#94a3b8;border-top:1px solid #e8edf5;margin-top:12px;padding-top:6px}

@media(max-width:1180px){
  .sw-sp-grid-4{grid-template-columns:repeat(2,minmax(0,1fr))}
  .sw-sp-charts-row{grid-template-columns:minmax(260px,.9fr) minmax(0,1.4fr)}
  .sw-sp-history-grid{grid-template-columns:1fr}
}
@media(max-width:900px){
  .sw-sales-performance-v2199{padding:1.25rem}
  .sw-sp-page-head{flex-direction:column}
  .sw-sp-head-actions{width:100%;justify-content:flex-start}
  .sw-sp-target-card{align-items:flex-start;flex-direction:column}
  .sw-sp-target-editor{width:100%;justify-content:space-between}
  .sw-sp-money-input{width:min(220px,60vw)}
  .sw-sp-charts-row,.sw-sp-two-panel{grid-template-columns:1fr}
  .sw-sp-donut-wrap{height:155px}
  .sw-sp-donut{width:135px;height:135px}
}
@media(max-width:680px){
  .sw-sales-performance-v2199{padding:1rem .8rem 1.5rem}
  .sw-sp-page-inner{gap:1rem}
  .sw-sp-page-head h1{font-size:1.15rem}
  .sw-sp-page-head p{font-size:.8rem}
  .sw-sp-head-actions{display:grid;grid-template-columns:1fr 1fr;width:100%}
  .sw-sp-head-actions .sw-sp-backup-btn{grid-column:1/-1}
  .sw-sp-head-actions select,.sw-sp-head-actions button{width:100%}
  .sw-sp-grid-4,.sw-sp-grid-3,.sw-sp-grid-2{grid-template-columns:1fr}
  .sw-sp-stat-card{padding:1rem}
  .sw-sp-stat-value{font-size:1.35rem}
  .sw-sp-charts-row{gap:.75rem}
  .sw-sp-chart-card,.sw-sp-panel,.sw-sp-history-total{padding:1rem}
  .sw-sp-hbar-row{grid-template-columns:90px 1fr auto}
  .sw-sp-history-total>div{gap:1.2rem}
  .sw-sp-log-total{margin-left:0;text-align:left;width:100%}
  .sw-sp-exec-filters{display:grid;grid-template-columns:1fr 1fr}
  .sw-sp-exec-filters select{width:100%}
  .sw-sp-exec-filters button{grid-column:1/-1;width:100%}
  .sw-sp-navy-main{gap:1.2rem;flex-wrap:wrap}
  .sw-sp-navy-main strong{font-size:1.45rem}
  .sw-sp-navy-split{grid-template-columns:1fr}
  .sw-sp-report-modal{padding:0}
  .sw-sp-report-shell{width:100vw;height:100vh;border-radius:0}
  .sw-sp-report-toolbar{height:auto;min-height:52px;align-items:flex-start;padding:9px 10px;flex-wrap:wrap}
  .sw-sp-report-toolbar>div:last-child{width:100%}
  .sw-sp-report-toolbar button{flex:1;justify-content:center}
  .sw-sp-report-scroll{padding:10px}
  .sw-sp-report-paper{width:210mm;transform-origin:top left}
}

/* v2.1.99 duplicate-runtime safeguards: exactly one custom Sales Performance root may render. */
[id^="sw-sales-performance-v"]:not(#sw-sales-performance-v2199){display:none!important}
#sw-sales-performance-v2199[class*="sw-sales-performance-original-v"]{display:block!important}
