/* Orbace Sudoku — score card (docs/plans/2026-07-17-score-card-web-template-prd.md).
 * Inline card rendered inside the puzzle's container element. Replaces the
 * legacy full-screen overlay used by stampOverlay and Tea Moment completion UI.
 * Namespaced under .osc- (Orbace Score Card).
 * Reuses design tokens from styles.css (--rice, --ivory, --ink, --mid, --tea,
 * --seal, --amber, --line, --serif, --mono, --sans) and existing classes
 * (.seal, .v1-tag, .v1-ss-*, .v1-store-btn, .btn, .btn.primary, .btn.ghost). */

.osc-card {
  position: absolute;
  inset: 0;
  background: #FBF8EF;
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 24px;
  box-shadow: 0 18px 40px -24px rgba(43, 39, 35, .35);
  margin: 0;
  z-index: 10;
  overflow-y: auto;
}

.osc-enter {
  animation: osc-enter .35s ease-out;
}
@keyframes osc-enter {
  0% { transform: scale(.92); opacity: 0; }
  100% { transform: scale(1); opacity: 1; }
}

.osc-head {
  display: flex;
  gap: 12px;
  align-items: center;
  margin-bottom: 10px;
}
.osc-head-info { flex: 1; min-width: 0; }
.osc-head-title { font-family: var(--serif); font-size: 15px; font-weight: 600; }
.osc-head-sub { font-family: var(--mono); font-size: 13px; color: var(--mid); margin-top: 3px; }

/* App download CTAs, moved onto the header row (2026-07-20 feedback) — the
   full v1-store-btn (even its "sm" variant) is far too wide for two of them
   to share a line with the puzzle title, so these are the brand's own seal-
   badge PNGs (docs/designes/) instead, sized to match the header's own
   .seal.md title seal (48x48 — see index.html/js for that reference size)
   rather than the site's generic store-button proportions. */
.osc-head-stores { display: flex; gap: 6px; flex: 0 0 auto; }
.osc-head-store-btn {
  display: inline-flex; align-items: center; justify-content: center;
  width: 48px; height: 48px; border-radius: 8px;
  overflow: hidden;
  box-shadow: inset 0 0 0 2px rgba(255,255,255,.25), 0 1px 2px rgba(139,26,43,.35);
  transition: transform .15s ease;
}
.osc-head-store-btn:hover { transform: translateY(-1px); }
.osc-head-store-btn img { width: 100%; height: 100%; object-fit: cover; display: block; }

.osc-total {
  text-align: center;
  font-family: var(--serif);
  font-size: 52px;
  font-weight: 600;
  margin: 4px 0 10px;
}

.osc-tags {
  display: flex;
  gap: 6px;
  justify-content: center;
  flex-wrap: wrap;
  margin-bottom: 14px;
  font-size: 13px;
}

.osc-stats {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 6px;
  text-align: center;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  padding: 10px 0;
  margin-bottom: 12px;
}
.osc-stats .v1-ss-label { font-size: 13px; color: var(--mid); }
.osc-stats .v1-ss-val { font-family: var(--mono); font-size: 14px; font-weight: 500; }

.osc-breakdown {
  font-size: 13px;
  color: var(--mid);
  display: flex;
  flex-direction: column;
  gap: 4px;
  margin-bottom: 6px;
}
.osc-breakdown-row {
  display: flex;
  justify-content: space-between;
}
.osc-breakdown-row b { color: var(--ink); }
.osc-breakdown-divider {
  border: none;
  border-top: 1px solid var(--line);
  margin: 4px 0;
}
.osc-breakdown-total {
  font-weight: 600;
  color: var(--ink);
  font-size: 14px;
}

.osc-formula {
  font-size: 12px;
  color: var(--mid);
  text-align: center;
  margin-bottom: 16px;
  line-height: 1.5;
}

.osc-ctas {
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.osc-cta-row {
  display: flex;
  gap: 8px;
  justify-content: center;
  flex-wrap: wrap;
}
.osc-cta-row .btn { flex: 1; min-width: 0; }

/* Moved up to right below the total score + enlarged (validation feedback,
   2026-07-17) — was 13px, sitting below all the CTAs. */
.osc-supu-link {
  display: block;
  text-align: center;
  font-size: 16px;
  font-weight: 500;
  color: var(--mid);
  margin: 6px 0 16px;
  text-decoration: underline;
  cursor: pointer;
}
.osc-supu-link:hover { color: var(--seal); }

@media (max-width: 720px) {
  .osc-card { padding: 18px; }
  .osc-total { font-size: 44px; }
}
