/* Overview (variant A, 13.11). Only overview content; the shell keeps its own styles.
   Layout follows the overview's own width (container queries), so it stays right whatever the sidebar does. */
.ov{--ov-card-line:color-mix(in srgb,var(--line) 70%,transparent);container:ov/inline-size;padding-bottom:28px;animation:ov-in .22s ease-out}
:root[data-theme="light"] .ov{--ov-card-line:var(--line)}
.ov [hidden]{display:none!important}

/* Heading: title, live status under it, actions on the right */
.ov .ov-heading{display:flex;align-items:flex-start;justify-content:space-between;flex-wrap:wrap;gap:14px 16px;min-height:0;margin-bottom:20px}
.ov .ov-heading-main{display:flex;flex-direction:column;gap:7px;min-width:0;flex:1 1 280px}
.ov .ov-heading h1{font-size:28px;font-weight:600;letter-spacing:-.02em;line-height:1.15}
.ov .overview-actions{gap:8px;margin-left:auto;padding-top:2px}
.ov .overview-actions .button{min-height:40px;padding:0 16px;border-radius:10px;font-size:13px;font-weight:500}
.ov .overview-actions .run-button{font-weight:600;min-width:112px}
.ov .overview-actions .run-button.is-stop{background:transparent;color:var(--error);border-color:color-mix(in srgb,var(--error) 38%,transparent)}
.ov .overview-actions .run-button.is-stop:hover:not(:disabled){filter:none;background:color-mix(in srgb,var(--error) 10%,transparent)}
.ov .ov-status{display:flex;align-items:center;gap:7px;min-height:20px;margin:0;padding:0}
.ov .ov-status-mark{display:inline-grid;place-items:center;width:16px;height:16px;flex:0 0 16px;color:var(--muted);background:none;border-radius:0}
.ov .ov-status-mark .icon{width:15px;height:15px;stroke-width:2}
.ov .ov-status-mark:empty{display:none}
.ov .ov-status-mark.live,.ov .ov-status-mark.running{color:var(--good)}
.ov .ov-status-mark.warning,.ov .ov-status-mark.error{color:var(--warn)}
.ov .ov-status-main{display:flex;flex-wrap:wrap;align-items:baseline;gap:2px 10px;min-width:0}
.ov .ov-status-main h2{font-size:13.5px;font-weight:500;letter-spacing:0;color:var(--muted)}
.ov .ov-status:has(.ov-status-mark.live) h2,.ov .ov-status:has(.ov-status-mark.running) h2{color:var(--good)}
.ov .ov-status:has(.ov-status-mark.warning) h2,.ov .ov-status:has(.ov-status-mark.error) h2{color:var(--warn)}
.ov .ov-status-main>p{margin:0;font-size:13px;color:var(--muted)}

/* Blocker: the one thing that stops sales, in a yellow card */
.ov .ov-alerts{display:grid;gap:10px;margin:0 0 16px}
.ov .ov-alerts:not(:has(>:not([hidden]))){display:none}
.ov .ov-blocker.ov-account-block{display:grid;gap:4px;background:color-mix(in srgb,var(--error) 9%,var(--surface,transparent));border-color:color-mix(in srgb,var(--error) 40%,transparent);color:var(--text,inherit)}
.ov .ov-blocker.ov-account-block[hidden]{display:none}
.ov .ov-blocker.ov-account-block strong{font-size:15px;color:var(--error)}
.ov .ov-blocker.ov-account-block::before{background:color-mix(in srgb,var(--error) 18%,transparent);color:var(--error)}
.ov .ov-blocker{position:relative;margin:0;padding:15px 18px 15px 60px;border-radius:14px;background:var(--warn-bg);border:1px solid color-mix(in srgb,var(--warn) 30%,transparent);color:var(--text);font-size:13.5px;line-height:1.55;text-wrap:pretty}
.ov .ov-blocker::before{content:"!";position:absolute;left:16px;top:13px;width:30px;height:30px;border-radius:9px;display:grid;place-items:center;background:color-mix(in srgb,var(--warn) 22%,transparent);color:var(--warn);font-weight:700;font-size:15px;line-height:1}

/* Tiles */
.ov .ov-metrics{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:12px;margin:0 0 20px;padding:0;background:none;border-radius:0}
.ov .ov-metrics:not(:has(.ov-balances>.ov-metric:not([hidden]))){grid-template-columns:repeat(3,minmax(0,1fr))}
.ov .ov-metrics>.ov-metric,.ov .ov-balances{display:flex;flex-direction:column;gap:8px;min-width:0;padding:16px 18px;background:var(--surface);border:1px solid var(--ov-card-line);border-radius:14px;color:var(--text);font:inherit;text-align:left;transition:border-color .15s,background .15s}
.ov .ov-balances:not(:has(>.ov-metric:not([hidden]))){display:none}
.ov .ov-metrics>.ov-metric>span:first-child,.ov .ov-balances-title{color:var(--muted);font-size:13px;line-height:1.35}
.ov .ov-metrics>.ov-metric>strong{display:block;margin:0;font-size:30px;font-weight:600;line-height:1.15;letter-spacing:-.02em;font-variant-numeric:tabular-nums;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.ov a.ov-metric,.ov button.ov-metric{cursor:pointer}
.ov a.ov-metric:hover,.ov button.ov-metric:hover{text-decoration:none;border-color:color-mix(in srgb,var(--accent) 40%,transparent)}
.ov a.ov-metric:focus-visible,.ov button.ov-metric:focus-visible{outline:2px solid var(--accent);outline-offset:2px}
.ov .ov-metric small.sr-only{display:none}
.ov .ov-metric-note{margin-top:auto;font-size:12px;line-height:1.4;color:var(--muted)}
.ov .ov-metric-note.warn{color:var(--warn)}
.ov .ov-balances{gap:9px}
.ov .ov-balances>.ov-metric{display:flex;align-items:baseline;justify-content:space-between;flex-wrap:wrap;gap:2px 10px;min-width:0;padding:0;background:none;border:0}
.ov .ov-balances>.ov-metric>span{font-size:13px;color:var(--muted)}
.ov .ov-balances>.ov-metric>strong{font-size:19px;font-weight:600;letter-spacing:-.01em;line-height:1.3;font-variant-numeric:tabular-nums;overflow-wrap:anywhere}

/* Two cards: by game and activity */
.ov .ov-data-grid{display:grid;grid-template-columns:minmax(0,1.08fr) minmax(0,1fr);gap:16px;align-items:start;margin:0}
.ov .ov-game-section,.ov .ov-log-section{min-width:0;padding:18px 20px;background:var(--surface);border:1px solid var(--ov-card-line);border-radius:14px}
.ov .ov-data-grid .ov-section-heading{display:flex;align-items:center;justify-content:space-between;gap:12px;min-height:28px;margin:0 0 12px}
.ov .ov-data-grid h2{font-size:16px;font-weight:600;letter-spacing:-.01em}
.ov .ov-section-link{display:inline-flex;align-items:center;gap:4px;min-height:28px;padding:0 2px;border:0;background:none;color:var(--accent);font-size:13px;font-weight:500;white-space:nowrap}
.ov .ov-section-link .icon{width:14px;height:14px}
.ov .ov-section-link>[data-icon]{display:flex}
.ov .ov-section-link:hover{text-decoration:none;filter:brightness(1.12)}
.ov .ov-checked-time{display:inline-flex;align-items:center;gap:5px;font-variant-numeric:tabular-nums;white-space:nowrap}
.ov .ov-checked-time>.icon{width:12px;height:12px;opacity:.7}
.ov .ov-checked-time>span{margin:0}

.ov .ov-game-table{width:100%;table-layout:fixed;border-collapse:collapse}
.ov .ov-game-table th{text-align:left;font-weight:400}
.ov .ov-game-table th:first-child{width:62%}.ov .ov-game-table th:nth-child(2),.ov .ov-game-table th:nth-child(3){width:19%}
.ov .ov-game-table thead{color:var(--faint);font-size:11.5px}
.ov .ov-game-table thead th{padding:0 0 6px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.ov .ov-game-table thead th:not(:first-child){text-align:right}
.ov .ov-game-table tbody th,.ov .ov-game-table tbody td{padding:9px 0;overflow-wrap:anywhere}
.ov .ov-game-name{display:flex;align-items:center;gap:12px;padding-right:14px}
.ov .ov-game-name>img{width:32px;height:32px;flex:0 0 32px;border-radius:8px;object-fit:contain}
.ov .ov-game-label{display:block;min-width:0;flex:1}
.ov .ov-game-label>strong{display:block;color:var(--text);font-size:13.5px;font-weight:500;line-height:1.35;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.ov .ov-game-bars{display:flex;flex-direction:column;gap:3px;width:100%;margin-top:7px}
.ov .ov-game-bar{display:block;width:100%;height:4px;flex:0 0 4px;overflow:hidden;border-radius:99px;background:color-mix(in srgb,var(--muted) 13%,transparent)}
.ov .ov-game-bar.catalogue rect{fill:var(--muted);opacity:.45}.ov .ov-game-bar.published rect{fill:var(--accent)}
.ov .ov-game-number{text-align:right;font-size:15px;font-weight:400;font-variant-numeric:tabular-nums;color:var(--muted)}
.ov .ov-game-number.published{color:var(--text);font-weight:600}
.ov .ov-legend-square{display:inline-block;width:8px;height:4px;border-radius:99px;margin-right:6px;vertical-align:2px}
.ov .ov-legend-square.catalogue{background:var(--muted);opacity:.55}.ov .ov-legend-square.published{background:var(--accent)}
.ov .ov-game-foot{display:flex;align-items:center;justify-content:space-between;flex-wrap:wrap;gap:5px 12px;margin-top:8px;padding-top:10px;border-top:1px solid var(--ov-card-line);color:var(--faint);font-size:12px}
.ov .ov-game-foot a{display:flex;align-items:center;gap:8px;min-height:30px;color:var(--muted)}
.ov .ov-game-foot a:hover{color:var(--text);text-decoration:none}
.ov .ov-game-foot strong{color:var(--text);font-weight:500;font-variant-numeric:tabular-nums}

/* Activity: coloured round marks, text, time */
.ov .ov-log-title{display:flex;align-items:baseline;gap:8px}
.ov .ov-log-title>span{font-size:12px;color:var(--faint)}
.ov .ov-log-list{margin:0 -8px;padding:0;list-style:none;max-height:440px;overflow:auto;scrollbar-width:thin}
.ov li.ov-log-row{display:grid;grid-template-columns:28px minmax(0,1fr) auto;gap:12px;align-items:center;padding:8px;border-radius:10px;font-size:13px;line-height:1.5;transition:background .15s}
.ov li.ov-log-row:hover{background:var(--raised)}
.ov .ov-log-symbol{display:grid;place-items:center;width:28px;height:28px;margin:0;border-radius:50%;background:color-mix(in srgb,var(--muted) 14%,transparent);color:var(--muted)}
.ov .ov-log-symbol>.icon{width:14px;height:14px;stroke-width:2}
.ov .ov-log-row.good .ov-log-symbol{background:var(--good-bg);color:var(--good)}
.ov .ov-log-row.warn .ov-log-symbol{background:var(--warn-bg);color:var(--warn)}
.ov .ov-log-message{min-width:0;overflow-wrap:anywhere}
.ov .ov-log-message>strong{display:inline;color:var(--text);font-size:13px;font-weight:400;line-height:1.5}
.ov .ov-log-row.warn .ov-log-message>strong{color:var(--warn)}
.ov .ov-event-time{font-size:12px;line-height:1.5;color:var(--faint);font-variant-numeric:tabular-nums;white-space:nowrap}
.ov .ov-chart-empty,.ov .ov-log-empty{min-height:150px;display:flex;flex-direction:column;align-items:flex-start;justify-content:center;padding:20px 8px;color:var(--muted)}
.ov .ov-chart-empty{padding-inline:0}
.ov .ov-chart-empty strong,.ov .ov-log-empty strong{color:var(--muted);font-size:13.5px;font-weight:500}

/* Connections: status as coloured text on the right */
.ov .ov-connections{margin-top:20px}
.ov .ov-connections>h2{margin:0 0 10px;font-size:13px;font-weight:500;color:var(--muted)}
.ov .ov-connection-strip{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px}
.ov .ov-connection-item{display:grid;grid-template-columns:36px minmax(0,1fr) auto;align-items:center;gap:12px;min-width:0;margin:0;padding:14px 16px;background:var(--surface);border:1px solid var(--ov-card-line);border-radius:14px;color:var(--text);font:inherit;text-align:left;transition:border-color .15s}
.ov a.ov-connection-item:hover{text-decoration:none;border-color:color-mix(in srgb,var(--accent) 40%,transparent)}
.ov .ov-connection-item:focus-visible{outline:2px solid var(--accent);outline-offset:2px}
.ov .ov-connection-item>img{width:36px;height:36px;object-fit:contain;border-radius:10px}
.ov .ov-connection-main{display:flex;flex-direction:column;min-width:0}
.ov .ov-connection-main>strong{font-size:14px;font-weight:500;line-height:1.45;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.ov .ov-connection-meta{display:flex;align-items:baseline;flex-wrap:wrap;gap:2px 10px;color:var(--muted);font-size:12px;line-height:1.5}
.ov .ov-connection-meta>span{overflow-wrap:anywhere}
.ov .ov-connection-meta>span:empty{display:none}
.ov .ov-connection-item>.status{font-size:13px;color:var(--muted);white-space:nowrap}
.ov .ov-connection-item>.status.good{color:var(--good)}
.ov .ov-connection-item>.status.warn,.ov .ov-connection-item>.status.warning-label{color:var(--warn)}

/* Tablet and narrow desktop */
@container ov (max-width:900px){
 .ov .ov-metrics,.ov .ov-metrics:not(:has(.ov-balances>.ov-metric:not([hidden]))){grid-template-columns:repeat(2,minmax(0,1fr))}
 .ov .ov-metrics>:nth-child(3):last-child{grid-column:1 / -1}
 .ov .ov-data-grid{grid-template-columns:minmax(0,1fr)}
 .ov .ov-log-section{order:-1}
 .ov .ov-log-list{max-height:360px}
}
/* Phone */
@container ov (max-width:560px){
 .ov .ov-heading{gap:12px;margin-bottom:16px}
 .ov .ov-heading h1{font-size:25px}
 .ov .ov-status-main{gap:1px 8px}.ov .ov-status-main h2,.ov .ov-status-main>p{font-size:13px}
 .ov .overview-actions{width:100%;margin-left:0;padding-top:0}
 .ov .overview-actions>.button:not([hidden]){flex:1 1 0;min-width:0;min-height:44px;padding:0 12px;border-radius:12px;font-size:14px}
 .ov .ov-blocker{padding:14px 16px;font-size:13px}
 .ov .ov-blocker::before{display:none}
 .ov .ov-metrics{gap:10px;margin-bottom:16px}
 .ov .ov-metrics>.ov-metric,.ov .ov-balances{padding:14px}
 .ov .ov-metrics>.ov-metric>strong{font-size:26px}
 .ov .ov-metrics>.ov-metric:nth-child(n+3),.ov .ov-balances{grid-column:1 / -1}
 .ov .ov-metrics>.ov-metric:nth-child(3){display:grid;grid-template-columns:minmax(0,1fr) auto;align-items:center;column-gap:12px}
 .ov .ov-metrics>.ov-metric:nth-child(3)>strong{grid-column:2;grid-row:1}
 .ov .ov-balances>.ov-metric>strong{font-size:18px}
 .ov .ov-data-grid{gap:14px}
 .ov .ov-game-section,.ov .ov-log-section{padding:14px}
 .ov .ov-game-table th:first-child{width:52%}.ov .ov-game-table th:nth-child(2),.ov .ov-game-table th:nth-child(3){width:24%}
 .ov .ov-game-table thead th:not(:first-child){padding-left:6px}
 .ov .ov-game-table thead{font-size:11px}
 .ov .ov-legend-square{display:none}
 .ov .ov-game-name{gap:10px;padding-right:10px}.ov .ov-game-name>img{width:28px;height:28px;flex-basis:28px;border-radius:7px}
 .ov .ov-game-label>strong{font-size:13px}.ov .ov-game-number{font-size:14px}
 .ov li.ov-log-row{gap:10px;padding:8px 6px}
 .ov .ov-log-list{margin-inline:-6px}
 .ov .ov-connections{margin-top:16px}
 .ov .ov-connection-strip{grid-template-columns:minmax(0,1fr);gap:10px}
 .ov .ov-connection-item{padding:12px 14px}
}
@container ov (max-width:330px){
 .ov .ov-metrics>.ov-metric>strong{font-size:23px}
 .ov .ov-connection-item{grid-template-columns:32px minmax(0,1fr);row-gap:4px}
 .ov .ov-connection-item>img{width:32px;height:32px}
 .ov .ov-connection-item>.status{grid-column:2}
}
@keyframes ov-in{from{opacity:0;transform:translateY(3px)}to{opacity:1;transform:translateY(0)}}@keyframes ov-spin{to{transform:rotate(360deg)}}
.ov .ov-status-mark.busy .icon{animation:ov-spin 2.2s linear infinite}
@media(prefers-reduced-motion:reduce){.ov,.ov .ov-status-mark.busy .icon{animation:none}.ov li.ov-log-row,.ov .ov-metrics>.ov-metric{transition:none}}

/* Auto-purchase off: overview alert and the same card above Sales */
.ov .ov-blocker.delivery-warning,.delivery-warning{display:grid;gap:6px;justify-items:start}
.ov .ov-blocker.delivery-warning[hidden],.delivery-warning[hidden]{display:none}
.delivery-warning strong{font-size:15px;color:var(--warn)}
.delivery-warning .delivery-warning-action{margin-top:4px}
.sales-delivery-warning{position:relative;margin:0 0 16px;padding:15px 18px 15px 60px;border-radius:14px;background:var(--warn-bg);border:1px solid color-mix(in srgb,var(--warn) 30%,transparent);color:var(--text);font-size:13.5px;line-height:1.55;text-wrap:pretty}
.sales-delivery-warning::before{content:"!";position:absolute;left:16px;top:13px;width:30px;height:30px;border-radius:9px;display:grid;place-items:center;background:color-mix(in srgb,var(--warn) 22%,transparent);color:var(--warn);font-weight:700;font-size:15px;line-height:1}
