/* V2-WINS-PANEL-CANON-001 — Wins Panel footer strip + right drawer.
   Cross-surface (cairn / cockpit / pebble). 56px sticky at bottom, expands
   into a 360px right drawer with Today / This Week / Settings tabs.
   Scoped under .wins-strip / .wins-drawer so it doesn't clobber host CSS. */

.wins-strip {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  height: 56px;
  background: #0f172a;
  color: #f1f5f9;
  border-top: 1px solid #334155;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 0 14px;
  z-index: 9000;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  font-size: 13px;
  box-shadow: 0 -2px 8px rgba(0, 0, 0, 0.18);
}
.wins-strip-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: #1e293b;
  border: 1px solid #475569;
  border-radius: 999px;
  padding: 4px 12px;
  font-weight: 600;
  cursor: pointer;
  white-space: nowrap;
  color: #f1f5f9;
}
.wins-strip-badge:hover { background: #334155; }
.wins-strip-badge[data-empty="true"] { color: #94a3b8; }
.wins-strip-previews {
  flex: 1;
  display: flex;
  gap: 8px;
  overflow-x: auto;
  scrollbar-width: thin;
  scrollbar-color: #475569 transparent;
  align-items: center;
  min-width: 0;
}
.wins-strip-previews::-webkit-scrollbar { height: 6px; }
.wins-strip-previews::-webkit-scrollbar-thumb { background: #475569; border-radius: 3px; }
.wins-strip-preview {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: #1e293b;
  border: 1px solid #334155;
  border-radius: 6px;
  padding: 4px 8px;
  white-space: nowrap;
  font-size: 12px;
  flex-shrink: 0;
}
.wins-strip-preview .lane-chip {
  background: #334155;
  border-radius: 4px;
  padding: 1px 6px;
  font-size: 11px;
  color: #cbd5e1;
}
.wins-strip-preview .verdict-chip {
  background: transparent;
  border: 1px solid #475569;
  border-radius: 4px;
  padding: 0 5px;
  cursor: pointer;
  font-size: 11px;
  color: #cbd5e1;
}
.wins-strip-preview .verdict-chip:hover { background: #334155; color: #f8fafc; }
.wins-strip-preview .verdict-chip.is-good { color: #22c55e; border-color: #166534; }
.wins-strip-preview .verdict-chip.is-wrong { color: #ef4444; border-color: #7f1d1d; }
.wins-strip-clear {
  background: transparent;
  border: 1px solid #475569;
  color: #cbd5e1;
  border-radius: 6px;
  padding: 4px 10px;
  cursor: pointer;
  font-size: 12px;
  white-space: nowrap;
}
.wins-strip-clear:hover { background: #1e293b; color: #f8fafc; }
.wins-strip-empty {
  flex: 1;
  color: #94a3b8;
  font-style: italic;
  font-size: 12px;
}

/* Right drawer */
.wins-drawer {
  position: fixed;
  top: 0;
  bottom: 0;
  right: 0;
  width: 360px;
  background: #0f172a;
  color: #f1f5f9;
  border-left: 1px solid #334155;
  z-index: 9001;
  display: none;
  flex-direction: column;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  box-shadow: -4px 0 16px rgba(0, 0, 0, 0.3);
}
.wins-drawer[data-open="true"] { display: flex; }
.wins-drawer-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 16px;
  border-bottom: 1px solid #334155;
}
.wins-drawer-head h2 {
  margin: 0;
  font-size: 15px;
  font-weight: 600;
}
.wins-drawer-close {
  background: transparent;
  border: none;
  color: #cbd5e1;
  font-size: 20px;
  cursor: pointer;
  line-height: 1;
}
.wins-drawer-tabs {
  display: flex;
  border-bottom: 1px solid #334155;
}
.wins-drawer-tab {
  flex: 1;
  background: transparent;
  border: none;
  color: #94a3b8;
  padding: 10px;
  cursor: pointer;
  font-size: 13px;
  font-weight: 500;
  border-bottom: 2px solid transparent;
}
.wins-drawer-tab[aria-selected="true"] {
  color: #f1f5f9;
  border-bottom-color: #14b8a6;
}
.wins-drawer-body {
  flex: 1;
  overflow-y: auto;
  padding: 12px 14px;
}
.wins-drawer-section { margin-bottom: 14px; }
.wins-drawer-section-head {
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.6px;
  color: #94a3b8;
  margin: 0 0 6px;
}
.wins-row {
  background: #1e293b;
  border: 1px solid #334155;
  border-radius: 6px;
  padding: 8px 10px;
  margin-bottom: 6px;
  font-size: 12px;
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.wins-row[data-reviewed="true"] { opacity: 0.55; }
.wins-row-line1 {
  display: flex;
  gap: 6px;
  align-items: center;
  flex-wrap: wrap;
  color: #cbd5e1;
}
.wins-row-line1 .ts { color: #64748b; font-variant-numeric: tabular-nums; font-size: 11px; }
.wins-row-summary { color: #f1f5f9; word-break: break-word; }
.wins-row-actions {
  display: flex;
  gap: 6px;
  align-items: center;
}
.wins-row-actions .verdict-chip {
  background: transparent;
  border: 1px solid #475569;
  color: #cbd5e1;
  border-radius: 4px;
  padding: 2px 8px;
  cursor: pointer;
  font-size: 11px;
}
.wins-row-actions .verdict-chip.is-good { color: #22c55e; border-color: #166534; }
.wins-row-actions .verdict-chip.is-wrong { color: #ef4444; border-color: #7f1d1d; }
.wins-empty-state {
  padding: 24px 12px;
  color: #94a3b8;
  text-align: center;
  font-style: italic;
  font-size: 13px;
}
.wins-lane-row {
  background: #1e293b;
  border: 1px solid #334155;
  border-radius: 6px;
  padding: 10px;
  margin-bottom: 8px;
  font-size: 12px;
}
.wins-lane-row-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 6px;
}
.wins-lane-name { font-weight: 600; color: #f1f5f9; }
.wins-lane-meta { color: #94a3b8; font-size: 11px; }
.wins-tier-toggle {
  display: inline-flex;
  border: 1px solid #475569;
  border-radius: 6px;
  overflow: hidden;
}
.wins-tier-btn {
  background: transparent;
  border: none;
  color: #94a3b8;
  padding: 4px 9px;
  font-size: 11px;
  cursor: pointer;
}
.wins-tier-btn[aria-pressed="true"] {
  background: #14b8a6;
  color: #0f172a;
  font-weight: 600;
}
.wins-toast {
  position: fixed;
  bottom: 72px;
  left: 50%;
  transform: translateX(-50%);
  background: #1e293b;
  color: #f1f5f9;
  border: 1px solid #475569;
  border-radius: 6px;
  padding: 6px 12px;
  font-size: 12px;
  z-index: 9100;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
}

/* Push host content up by the strip height. Browsers ignore padding-bottom on
   <body> when it's already auto-managed; an explicit data-attribute lets us
   target body without bleeding into other surfaces' layouts. */
body[data-wins-strip-mounted="true"] {
  padding-bottom: 56px !important;
}
