/**
 * Shared win-modal design (Stuck in Traffic style).
 * Include after each puzzle's player.css so layout is consistent site-wide.
 */

/* ── Shell ── */
.modal,
#win-modal.modal,
#result-modal.modal {
  position: fixed;
  inset: 0;
  z-index: 50;
  display: grid;
  place-items: center;
  padding: 16px;
}

.modal.hidden,
#win-modal.hidden,
#result-modal.hidden {
  display: none;
}

.modal[hidden],
#win-modal[hidden],
#result-modal[hidden] {
  display: none !important;
}

.modal-backdrop,
#win-modal-backdrop,
#result-modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(26, 43, 51, 0.45);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
}

/* Sibling backdrops (outside the modal shell) */
body > .modal-backdrop,
.app > .modal-backdrop,
body > #win-modal-backdrop,
.app > #win-modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 49;
}

.modal-card {
  position: relative;
  z-index: 1;
  width: min(340px, 100%);
  background: var(--panel-solid, #fffbf3);
  border: 3px solid #2c2416;
  border-radius: 22px;
  padding: 24px;
  text-align: center;
  box-shadow: 6px 6px 0 var(--gold, #e9c46a);
  max-height: min(92vh, 900px);
  overflow: auto;
  pointer-events: auto;
}

.modal {
  pointer-events: auto;
}

.modal-card .emoji,
.modal-card .win-burst {
  font-size: 2.6rem;
  line-height: 1;
}

.modal-card h2,
.modal-card #win-title,
.modal-card #result-title {
  margin: 8px 0 10px;
  color: var(--text, #2C2416);
  font-size: 1.35rem;
  font-family: "Waukegan LDO", "Eurostile", "Arial Narrow", system-ui, sans-serif;
  font-weight: 700;
  letter-spacing: 0.02em;
}

.modal-card .muted,
.modal-card .modal-lead,
.modal-card .win-sub,
.modal-card #win-msg {
  margin: 0;
  color: var(--muted, #7A6A52);
  font-size: 0.95rem;
  line-height: 1.45;
}

.modal-card .mono,
.modal-card .win-stats,
.modal-card #win-stats,
.modal-card #result-stats,
.modal-card #result-detail {
  margin: 10px 0 0;
  font-size: 0.88rem;
  color: var(--muted, #7A6A52);
  font-variant-numeric: tabular-nums;
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  line-height: 1.45;
}

.modal-card .mono strong,
.modal-card .win-stats strong,
.modal-card #result-stats strong {
  color: var(--text, #2C2416);
  font-weight: 700;
}

/* Finish score (0–1000) - shown on every puzzle win popup */
.modal-card .win-score-line {
  margin: 14px 0 0;
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--text, #2C2416);
  font-variant-numeric: tabular-nums;
}

.modal-card .win-score-value,
.modal-card #win-score,
.modal-card #result-score {
  font-size: 1.55rem;
  font-weight: 800;
  color: var(--accent-2, #1A7A6F);
  font-variant-numeric: tabular-nums;
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  letter-spacing: -0.02em;
}

.modal-card .win-score-max {
  font-size: 0.92rem;
  font-weight: 600;
  color: var(--muted, #7A6A52);
}

.modal-card .win-score-note,
.modal-card #win-score-note {
  margin: 6px 0 0;
  font-size: 0.78rem;
  color: var(--muted, #7A6A52);
}

/* Traffic stars */
.modal-card .stars {
  font-size: 1.5rem;
  letter-spacing: 0.08em;
  color: var(--yellow, #e8b923);
  margin-bottom: 8px;
  text-shadow: 0 1px 0 rgba(255, 255, 255, 0.8);
}

/* Compact score chips → single traffic-like stack when present */
.modal-card .score-row {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 10px;
  margin: 12px 0 0;
}

.modal-card .score-box {
  flex: 1 1 90px;
  min-width: 88px;
  max-width: 120px;
  padding: 10px 8px;
  border-radius: 12px;
  background: var(--panel-2, rgba(0, 0, 0, 0.04));
  border: 1px solid var(--border, rgba(36, 157, 143, 0.28));
}

.modal-card .score-label {
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--muted, #7A6A52);
  margin-bottom: 4px;
}

.modal-card .score-value {
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--text, #2C2416);
  font-variant-numeric: tabular-nums;
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
}

/* Sewer-style dl stats */
.modal-card dl.win-stats {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin: 12px 0 0;
  text-align: center;
}

.modal-card dl.win-stats > div {
  padding: 10px 8px;
  border-radius: 12px;
  background: var(--panel-2, rgba(0, 0, 0, 0.04));
  border: 1px solid var(--border, rgba(36, 157, 143, 0.28));
}

.modal-card dl.win-stats dt {
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--muted, #7A6A52);
  margin: 0 0 4px;
}

.modal-card dl.win-stats dd {
  margin: 0;
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--text, #2C2416);
  font-variant-numeric: tabular-nums;
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
}

/* ── Next puzzle countdown: label on first line, timer on second ── */
.next-puzzle-note {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 6px;
  margin: 14px 0 0;
  padding: 12px 14px;
  border-radius: 12px;
  background: var(--panel-2, rgba(0, 0, 0, 0.04));
  border: 1px solid var(--border, rgba(36, 157, 143, 0.28));
  color: var(--muted, #7A6A52);
  font-size: 0.9rem;
  line-height: 1.35;
  text-align: center;
}

.next-puzzle-label {
  display: block;
  font-weight: 600;
  color: var(--muted, #7A6A52);
}

.next-puzzle-countdown,
.next-puzzle-note > strong,
#next-puzzle-countdown {
  display: block;
  font-weight: 800;
  font-size: 1.15rem;
  font-variant-numeric: tabular-nums;
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  color: var(--text, #2C2416);
  letter-spacing: 0.02em;
  white-space: nowrap;
}

/* ── Actions ── */
.modal-actions {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-top: 16px;
}

.modal-actions .primary,
.modal-actions .btn-primary,
.modal-actions button.primary {
  width: 100%;
  appearance: none;
  border: none;
  border-radius: 12px;
  padding: 12px 16px;
  font-weight: 700;
  font-size: 0.95rem;
  cursor: pointer;
  background: var(--accent, #249D8F);
  color: #fff;
}

.modal-actions .primary:hover,
.modal-actions .btn-primary:hover,
.modal-actions button.primary:hover {
  filter: brightness(1.05);
}

.modal-actions .btn-link,
.modal-actions a.btn-link,
.modal-actions a.btn-ghost,
.modal-actions .btn-ghost {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  box-sizing: border-box;
  padding: 11px 14px;
  border-radius: 12px;
  border: 1px solid var(--border, rgba(36, 157, 143, 0.28));
  background: var(--panel-2, rgba(255, 255, 255, 0.78));
  color: var(--accent-2, #1A7A6F);
  text-decoration: none;
  font-weight: 700;
  font-size: 0.92rem;
  cursor: pointer;
}

.modal-actions .btn-link:hover,
.modal-actions a.btn-link:hover {
  border-color: var(--border-strong, rgba(26, 122, 111, 0.42));
}

.modal-actions button:not(.primary):not(.btn-primary),
.modal-actions .btn-secondary {
  width: 100%;
  appearance: none;
  border: 1px solid var(--border, rgba(36, 157, 143, 0.28));
  border-radius: 12px;
  padding: 11px 14px;
  font-weight: 700;
  font-size: 0.92rem;
  cursor: pointer;
  background: transparent;
  color: var(--text, #2C2416);
}

.modal-actions button:not(.primary):not(.btn-primary):hover {
  background: var(--panel-2, rgba(0, 0, 0, 0.03));
}

.modal-note,
.modal-fineprint,
.score-note {
  margin: 12px 0 0;
  font-size: 0.78rem;
  color: var(--muted, #7A6A52);
  line-height: 1.4;
}

/* Dark / sewer cards still work with variables when set */
html.theme-valentines .modal-card {
  background: rgba(255, 255, 255, 0.96);
}

/*
 * Halloween page tokens are light-on-dark (cream text, dark panels).
 * Win cards stay light-colored, so re-pin modal copy to dark ink for contrast.
 */
html.theme-halloween .modal-card {
  background: linear-gradient(
    145deg,
    rgba(255, 252, 247, 0.98) 0%,
    rgba(255, 244, 230, 0.96) 100%
  );
  border-color: rgba(234, 88, 12, 0.35);
  color: #1a1008;
  box-shadow:
    0 1px 0 rgba(255, 255, 255, 0.85) inset,
    0 20px 50px rgba(0, 0, 0, 0.45),
    0 0 0 1px rgba(249, 115, 22, 0.12);
}

html.theme-halloween .modal-card h2,
html.theme-halloween .modal-card #win-title,
html.theme-halloween .modal-card #result-title,
html.theme-halloween .modal-card .mono strong,
html.theme-halloween .modal-card .win-stats strong,
html.theme-halloween .modal-card #result-stats strong,
html.theme-halloween .modal-card .score-value,
html.theme-halloween .modal-card dl.win-stats dd,
html.theme-halloween .next-puzzle-countdown,
html.theme-halloween .next-puzzle-note > strong,
html.theme-halloween #next-puzzle-countdown {
  color: #1a1008;
}

html.theme-halloween .modal-card .muted,
html.theme-halloween .modal-card .modal-lead,
html.theme-halloween .modal-card .win-sub,
html.theme-halloween .modal-card #win-msg,
html.theme-halloween .modal-card .mono,
html.theme-halloween .modal-card .win-stats,
html.theme-halloween .modal-card #win-stats,
html.theme-halloween .modal-card #result-stats,
html.theme-halloween .modal-card #result-detail,
html.theme-halloween .modal-card .score-label,
html.theme-halloween .modal-card dl.win-stats dt,
html.theme-halloween .modal-note,
html.theme-halloween .modal-fineprint,
html.theme-halloween .score-note,
html.theme-halloween .next-puzzle-note,
html.theme-halloween .next-puzzle-label {
  color: #7c4a1e;
}

html.theme-halloween .modal-card .score-box,
html.theme-halloween .modal-card dl.win-stats > div,
html.theme-halloween .next-puzzle-note {
  background: rgba(255, 237, 213, 0.85);
  border-color: rgba(234, 88, 12, 0.28);
}

html.theme-halloween .modal-actions .primary,
html.theme-halloween .modal-actions .btn-primary,
html.theme-halloween .modal-actions button.primary {
  background: #ea580c;
  color: #fff;
}

html.theme-halloween .modal-actions .btn-link,
html.theme-halloween .modal-actions a.btn-link,
html.theme-halloween .modal-actions a.btn-ghost,
html.theme-halloween .modal-actions .btn-ghost {
  background: rgba(255, 247, 237, 0.95);
  border-color: rgba(234, 88, 12, 0.35);
  color: #c2410c;
}

html.theme-halloween .modal-actions button:not(.primary):not(.btn-primary),
html.theme-halloween .modal-actions .btn-secondary {
  background: rgba(255, 255, 255, 0.7);
  border-color: rgba(234, 88, 12, 0.35);
  color: #1a1008;
}

html.theme-halloween .modal-actions button:not(.primary):not(.btn-primary):hover {
  background: rgba(255, 237, 213, 0.95);
}

/* Linewire (and others) set .modal-card h2 to var(--ok) - keep it readable */
html.theme-halloween .modal-card h2 {
  color: #c2410c;
}

/*
 * New Year tokens are light-on-navy. Keep win cards light with dark ink
 * so titles/stats stay readable (same pattern as Halloween).
 */
html.theme-newyear .modal-card {
  background: linear-gradient(
    145deg,
    rgba(255, 252, 245, 0.98) 0%,
    rgba(245, 236, 208, 0.96) 100%
  );
  border-color: rgba(212, 175, 55, 0.4);
  color: #0c1a32;
  box-shadow:
    0 1px 0 rgba(255, 255, 255, 0.85) inset,
    0 20px 50px rgba(0, 0, 0, 0.45),
    0 0 0 1px rgba(212, 175, 55, 0.15);
}

html.theme-newyear .modal-card h2,
html.theme-newyear .modal-card #win-title,
html.theme-newyear .modal-card #result-title,
html.theme-newyear .modal-card .mono strong,
html.theme-newyear .modal-card .win-stats strong,
html.theme-newyear .modal-card #result-stats strong,
html.theme-newyear .modal-card .score-value,
html.theme-newyear .modal-card dl.win-stats dd,
html.theme-newyear .next-puzzle-countdown,
html.theme-newyear .next-puzzle-note > strong,
html.theme-newyear #next-puzzle-countdown {
  color: #0c1a32;
}

html.theme-newyear .modal-card .muted,
html.theme-newyear .modal-card .modal-lead,
html.theme-newyear .modal-card .win-sub,
html.theme-newyear .modal-card #win-msg,
html.theme-newyear .modal-card .mono,
html.theme-newyear .modal-card .win-stats,
html.theme-newyear .modal-card #win-stats,
html.theme-newyear .modal-card #result-stats,
html.theme-newyear .modal-card #result-detail,
html.theme-newyear .modal-card .score-label,
html.theme-newyear .modal-card dl.win-stats dt,
html.theme-newyear .modal-note,
html.theme-newyear .modal-fineprint,
html.theme-newyear .score-note,
html.theme-newyear .next-puzzle-note,
html.theme-newyear .next-puzzle-label {
  color: #5a4a28;
}

html.theme-newyear .modal-card .score-box,
html.theme-newyear .modal-card dl.win-stats > div,
html.theme-newyear .next-puzzle-note {
  background: rgba(240, 215, 140, 0.28);
  border-color: rgba(212, 175, 55, 0.35);
}

html.theme-newyear .modal-actions .primary,
html.theme-newyear .modal-actions .btn-primary,
html.theme-newyear .modal-actions button.primary {
  background: #c9a227;
  color: #0c1a32;
}

html.theme-newyear .modal-actions .btn-link,
html.theme-newyear .modal-actions a.btn-link,
html.theme-newyear .modal-actions a.btn-ghost,
html.theme-newyear .modal-actions .btn-ghost {
  background: rgba(255, 252, 245, 0.95);
  border-color: rgba(212, 175, 55, 0.4);
  color: #8a7020;
}

html.theme-newyear .modal-actions button:not(.primary):not(.btn-primary),
html.theme-newyear .modal-actions .btn-secondary {
  background: rgba(255, 255, 255, 0.75);
  border-color: rgba(212, 175, 55, 0.4);
  color: #0c1a32;
}

html.theme-newyear .modal-actions button:not(.primary):not(.btn-primary):hover {
  background: rgba(240, 215, 140, 0.35);
}

html.theme-newyear .modal-card h2 {
  color: #8a7020;
}

/*
 * Lunar New Year tokens are light-on-deep-red. Keep win cards light with dark ink.
 */
html.theme-lunarnewyear .modal-card {
  background: linear-gradient(
    145deg,
    rgba(255, 252, 245, 0.98) 0%,
    rgba(255, 243, 224, 0.96) 100%
  );
  border-color: rgba(220, 38, 38, 0.35);
  color: #3f0a0c;
  box-shadow:
    0 1px 0 rgba(255, 255, 255, 0.85) inset,
    0 20px 50px rgba(0, 0, 0, 0.45),
    0 0 0 1px rgba(234, 179, 8, 0.2);
}

html.theme-lunarnewyear .modal-card h2,
html.theme-lunarnewyear .modal-card #win-title,
html.theme-lunarnewyear .modal-card #result-title,
html.theme-lunarnewyear .modal-card .mono strong,
html.theme-lunarnewyear .modal-card .win-stats strong,
html.theme-lunarnewyear .modal-card #result-stats strong,
html.theme-lunarnewyear .modal-card .score-value,
html.theme-lunarnewyear .modal-card dl.win-stats dd,
html.theme-lunarnewyear .next-puzzle-countdown,
html.theme-lunarnewyear .next-puzzle-note > strong,
html.theme-lunarnewyear #next-puzzle-countdown {
  color: #3f0a0c;
}

html.theme-lunarnewyear .modal-card .muted,
html.theme-lunarnewyear .modal-card .modal-lead,
html.theme-lunarnewyear .modal-card .win-sub,
html.theme-lunarnewyear .modal-card #win-msg,
html.theme-lunarnewyear .modal-card .mono,
html.theme-lunarnewyear .modal-card .win-stats,
html.theme-lunarnewyear .modal-card #win-stats,
html.theme-lunarnewyear .modal-card #result-stats,
html.theme-lunarnewyear .modal-card #result-detail,
html.theme-lunarnewyear .modal-card .score-label,
html.theme-lunarnewyear .modal-card dl.win-stats dt,
html.theme-lunarnewyear .modal-note,
html.theme-lunarnewyear .modal-fineprint,
html.theme-lunarnewyear .score-note,
html.theme-lunarnewyear .next-puzzle-note,
html.theme-lunarnewyear .next-puzzle-label {
  color: #8a4a28;
}

html.theme-lunarnewyear .modal-card .score-box,
html.theme-lunarnewyear .modal-card dl.win-stats > div,
html.theme-lunarnewyear .next-puzzle-note {
  background: rgba(254, 226, 226, 0.75);
  border-color: rgba(220, 38, 38, 0.28);
}

html.theme-lunarnewyear .modal-actions .primary,
html.theme-lunarnewyear .modal-actions .btn-primary,
html.theme-lunarnewyear .modal-actions button.primary {
  background: #dc2626;
  color: #fff;
}

html.theme-lunarnewyear .modal-actions .btn-link,
html.theme-lunarnewyear .modal-actions a.btn-link,
html.theme-lunarnewyear .modal-actions a.btn-ghost,
html.theme-lunarnewyear .modal-actions .btn-ghost {
  background: rgba(255, 252, 245, 0.95);
  border-color: rgba(220, 38, 38, 0.35);
  color: #b91c1c;
}

html.theme-lunarnewyear .modal-actions button:not(.primary):not(.btn-primary),
html.theme-lunarnewyear .modal-actions .btn-secondary {
  background: rgba(255, 255, 255, 0.75);
  border-color: rgba(220, 38, 38, 0.35);
  color: #3f0a0c;
}

html.theme-lunarnewyear .modal-actions button:not(.primary):not(.btn-primary):hover {
  background: rgba(254, 226, 226, 0.9);
}

html.theme-lunarnewyear .modal-card h2 {
  color: #b91c1c;
}

/*
 * Full Moon tokens are light-on-navy. Keep win cards light with dark ink.
 */
html.theme-fullmoon .modal-card {
  background: linear-gradient(
    145deg,
    rgba(252, 253, 255, 0.98) 0%,
    rgba(232, 238, 248, 0.96) 100%
  );
  border-color: rgba(168, 184, 212, 0.45);
  color: #0f1628;
  box-shadow:
    0 1px 0 rgba(255, 255, 255, 0.9) inset,
    0 20px 50px rgba(0, 0, 0, 0.45),
    0 0 0 1px rgba(245, 230, 168, 0.15);
}

html.theme-fullmoon .modal-card h2,
html.theme-fullmoon .modal-card #win-title,
html.theme-fullmoon .modal-card #result-title,
html.theme-fullmoon .modal-card .mono strong,
html.theme-fullmoon .modal-card .win-stats strong,
html.theme-fullmoon .modal-card #result-stats strong,
html.theme-fullmoon .modal-card .score-value,
html.theme-fullmoon .modal-card dl.win-stats dd,
html.theme-fullmoon .next-puzzle-countdown,
html.theme-fullmoon .next-puzzle-note > strong,
html.theme-fullmoon #next-puzzle-countdown {
  color: #0f1628;
}

html.theme-fullmoon .modal-card .muted,
html.theme-fullmoon .modal-card .modal-lead,
html.theme-fullmoon .modal-card .win-sub,
html.theme-fullmoon .modal-card #win-msg,
html.theme-fullmoon .modal-card .mono,
html.theme-fullmoon .modal-card .win-stats,
html.theme-fullmoon .modal-card #win-stats,
html.theme-fullmoon .modal-card #result-stats,
html.theme-fullmoon .modal-card #result-detail,
html.theme-fullmoon .modal-card .score-label,
html.theme-fullmoon .modal-card dl.win-stats dt,
html.theme-fullmoon .modal-note,
html.theme-fullmoon .modal-fineprint,
html.theme-fullmoon .score-note,
html.theme-fullmoon .next-puzzle-note,
html.theme-fullmoon .next-puzzle-label {
  color: #4a5d78;
}

html.theme-fullmoon .modal-card .score-box,
html.theme-fullmoon .modal-card dl.win-stats > div,
html.theme-fullmoon .next-puzzle-note {
  background: rgba(232, 238, 248, 0.85);
  border-color: rgba(168, 184, 212, 0.4);
}

html.theme-fullmoon .modal-actions .primary,
html.theme-fullmoon .modal-actions .btn-primary,
html.theme-fullmoon .modal-actions button.primary {
  background: #2a3a58;
  color: #f5e6a8;
}

html.theme-fullmoon .modal-actions .btn-link,
html.theme-fullmoon .modal-actions a.btn-link,
html.theme-fullmoon .modal-actions a.btn-ghost,
html.theme-fullmoon .modal-actions .btn-ghost {
  background: rgba(252, 253, 255, 0.95);
  border-color: rgba(168, 184, 212, 0.45);
  color: #2a3a58;
}

html.theme-fullmoon .modal-actions button:not(.primary):not(.btn-primary),
html.theme-fullmoon .modal-actions .btn-secondary {
  background: rgba(255, 255, 255, 0.75);
  border-color: rgba(168, 184, 212, 0.45);
  color: #0f1628;
}

html.theme-fullmoon .modal-actions button:not(.primary):not(.btn-primary):hover {
  background: rgba(232, 238, 248, 0.95);
}

html.theme-fullmoon .modal-card h2 {
  color: #2a3a58;
}

/* Pi Day is light-on-navy - keep win cards readable */
html.theme-piday .modal-card {
  background: linear-gradient(
    145deg,
    rgba(248, 250, 252, 0.98) 0%,
    rgba(226, 232, 240, 0.96) 100%
  );
  border-color: rgba(56, 189, 248, 0.4);
  color: #0f172a;
  box-shadow:
    0 1px 0 rgba(255, 255, 255, 0.9) inset,
    0 20px 50px rgba(0, 0, 0, 0.45);
}

html.theme-piday .modal-card h2,
html.theme-piday .modal-card #win-title,
html.theme-piday .modal-card #result-title,
html.theme-piday .modal-card .mono strong,
html.theme-piday .modal-card .win-stats strong,
html.theme-piday .next-puzzle-countdown,
html.theme-piday #next-puzzle-countdown {
  color: #0f172a;
}

html.theme-piday .modal-card .muted,
html.theme-piday .modal-card .mono,
html.theme-piday .modal-card .win-stats,
html.theme-piday .next-puzzle-note,
html.theme-piday .next-puzzle-label {
  color: #475569;
}

html.theme-piday .next-puzzle-note {
  background: rgba(224, 242, 254, 0.85);
  border-color: rgba(56, 189, 248, 0.35);
}

html.theme-piday .modal-actions .primary,
html.theme-piday .modal-actions button.primary {
  background: #0284c7;
  color: #fff;
}

html.theme-piday .modal-actions .btn-link,
html.theme-piday .modal-actions a.btn-link {
  background: rgba(248, 250, 252, 0.95);
  border-color: rgba(56, 189, 248, 0.4);
  color: #0369a1;
}

html.theme-piday .modal-actions button:not(.primary):not(.btn-primary) {
  background: rgba(255, 255, 255, 0.75);
  border-color: rgba(56, 189, 248, 0.35);
  color: #0f172a;
}

html.theme-piday .modal-card h2 {
  color: #0369a1;
}

/* PALETTE-RICH */
.modal-card {
  background: linear-gradient(180deg, #FFFBF3 0%, #F7EBD0 100%);
  border-color: rgba(36, 157, 143, 0.35);
}
.next-puzzle-note {
  background: color-mix(in srgb, #249D8F 12%, #FDF0D5) !important;
  border-color: color-mix(in srgb, #E9C46A 45%, rgba(36,157,143,0.25)) !important;
}
.modal-actions .primary,
button.primary {
  background: linear-gradient(180deg, #3DB5A3, #249D8F, #1A7A6F) !important;
  color: #fff !important;
}
#btn-share-x,
#btn-share-x-win {
  background: linear-gradient(180deg, #E9C46A, #D4A84A) !important;
  color: #2C2416 !important;
}

/* CORAL-EMPHASIS */
.modal-actions a.btn-link {
  border-color: color-mix(in srgb, #E76F51 40%, rgba(36,157,143,0.3)) !important;
  color: #C9543A !important;
}
#btn-close-modal {
  border-color: color-mix(in srgb, #E76F51 45%, transparent) !important;
  color: #C9543A !important;
}
.next-puzzle-note strong {
  color: #E76F51 !important;
}
