/* =============================================================================
   The "proof of concept" pill. Fixed bottom-left, never in flow, so it can
   never move the page it is commenting on.
   ========================================================================== */

.sp-compare {
  position: fixed;
  left: 16px;
  bottom: 16px;
  z-index: 100000;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 10px;
  font-family: 'Source Code Pro', monospace;
  font-size: 12px;
  line-height: 1.45;
  color: #111;
}

.sp-compare-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 9px 16px;
  border: 1px solid #000;
  border-radius: 999px;
  background: #ffdd00;
  color: #000;
  font: inherit;
  font-weight: 600;
  cursor: pointer;
  box-shadow: 0 6px 20px rgba(0, 0, 0, .18);
}
.sp-compare-pill:hover { background: #000; color: #ffdd00; }
.sp-compare-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: currentColor;
  flex: 0 0 auto;
}

.sp-compare-card {
  width: min(500px, calc(100vw - 32px));
  max-height: min(70vh, 620px);
  overflow-y: auto;
  padding: 16px 18px 18px;
  background: #fff;
  border: 1px solid #000;
  border-radius: 14px;
  box-shadow: 0 18px 50px rgba(0, 0, 0, .22);
}

.sp-compare-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 8px;
}
.sp-compare-head strong { font-size: 14px; }
.sp-compare-close {
  border: 0;
  background: none;
  font: inherit;
  font-size: 20px;
  line-height: 1;
  cursor: pointer;
  padding: 0 2px;
  color: #666;
}
.sp-compare-close:hover { color: #000; }

.sp-compare-intro { margin: 0 0 12px; color: #444; }

.sp-compare-row {
  display: grid;
  grid-template-columns: 1fr 120px 132px;
  gap: 8px;
  padding: 5px 0;
  border-top: 1px solid #eee;
  align-items: baseline;
}
.sp-compare-cols {
  border-top: 0;
  font-weight: 700;
  color: #000;
}
.sp-compare-label { color: #333; }
.sp-compare-before { color: #9a3b3b; text-align: right; }
.sp-compare-after { color: #1f7a3d; text-align: right; font-weight: 600; }
.sp-compare-before.is-no::before,
.sp-compare-after.is-no::before { content: '✕ '; }
.sp-compare-before.is-ok::before,
.sp-compare-after.is-ok::before { content: '✓ '; }
.sp-compare-before.is-ok { color: #1f7a3d; }

.sp-compare-sep { height: 10px; }

.sp-compare-hide {
  margin-top: 14px;
  border: 1px solid #ddd;
  border-radius: 999px;
  background: #fff;
  font: inherit;
  font-size: 11px;
  color: #666;
  padding: 6px 14px;
  cursor: pointer;
}
.sp-compare-hide:hover { border-color: #000; color: #000; }

@media (max-width: 767px) {
  .sp-compare { left: 10px; bottom: 10px; }
  .sp-compare-pill { font-size: 11px; padding: 8px 13px; }
  .sp-compare-row { grid-template-columns: 1fr 74px 90px; }
}

@media print { .sp-compare { display: none; } }
