/* ——— The Gem Bank (js/screens/bank.js) ——— */

.bk-top .page-head p { max-width: 640px; }
.bk-stats { display: flex; flex-wrap: wrap; justify-content: center; gap: 12px; margin: 18px 0 20px; }
.bk-stat {
  display: grid;
  justify-items: center;
  min-width: 150px;
  padding: 8px 18px 10px;
  border-radius: 22px;
  border: 3px solid #fff;
  background: var(--card);
  box-shadow: 0 5px 0 #e3d6f2, var(--shadow);
}
.bk-stat small { font-size: 15px; font-weight: 600; color: var(--ink-soft); }
.bk-stat b { font-size: 26px; }
.bk-stat.gold { background: linear-gradient(180deg, #fff9e0, #ffefc0); box-shadow: 0 5px 0 #f1d68a, var(--shadow); }

.bk-shelf { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; align-items: start; }
.bk-jar {
  display: grid;
  justify-items: center;
  gap: 8px;
  padding: 16px 14px 18px;
  border-radius: 30px;
  border: 4px solid #fff;
  background: var(--card);
  box-shadow: 0 7px 0 #e3d6f2, var(--shadow);
  text-align: center;
  animation: pop-in 0.5s var(--bounce) backwards;
  animation-delay: calc(var(--i) * 90ms + 80ms);
}
.bk-head { display: grid; gap: 2px; }
.bk-head b { font-size: 22px; }
.bk-head small { font-size: 15px; font-weight: 600; color: var(--ink-soft); }
.bk-art { width: min(150px, 70%); }
.bk-art svg { display: block; width: 100%; height: auto; overflow: visible; }
.bk-deal { font-size: 18px; font-weight: 500; }
.bk-deal.big { font-size: 26px; font-weight: 700; }
.bk-plus { display: inline-block; padding: 0 8px; border-radius: 999px; background: #e3f8ee; color: #23955f; font-weight: 700; }
.bk-note { font-size: 14px; color: var(--ink-soft); }
.bk-when { font-size: 17px; font-weight: 600; color: var(--lilac-deep); }
.bk-jar .link-btn { margin: 0; font-size: 15px; }
.bk-buttons { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; }
.bk-jar .btn { padding: 10px 18px; font-size: 18px; }
.bk-jar .btn:disabled { opacity: 0.5; filter: grayscale(0.6); cursor: default; }

.bk-amount { display: flex; align-items: center; gap: 12px; }
.bk-amount b { min-width: 104px; font-size: 28px; }
.bk-step {
  width: 46px;
  height: 46px;
  border-radius: 50%;
  border: 3px solid #fff;
  background: var(--lilac-soft);
  font-size: 28px;
  font-weight: 700;
  line-height: 1;
  box-shadow: 0 4px 0 #d9c8f7;
}
.bk-step:disabled { opacity: 0.4; }
.bk-step:active:not(:disabled) { transform: translateY(3px); box-shadow: 0 1px 0 #d9c8f7; }
.bk-quick { display: flex; flex-wrap: wrap; justify-content: center; gap: 6px; }
.bk-quick button {
  padding: 5px 14px;
  border-radius: 999px;
  border: 3px solid #fff;
  background: #fff6d6;
  font-size: 16px;
  font-weight: 600;
  box-shadow: 0 3px 0 #f1d68a;
}

/* Days waited, as dots. */
.bk-days { display: flex; justify-content: center; gap: 6px; }
.bk-days i { width: 16px; height: 16px; border-radius: 50%; border: 3px solid var(--lilac); background: #fff; }
.bk-days i.on { background: var(--lilac); }

.bk-ready { background: linear-gradient(180deg, #fffbe8, #fff); box-shadow: 0 7px 0 #f1d68a, 0 0 0 6px rgba(255, 213, 77, 0.35), var(--shadow); }
.bk-ready .bk-art { animation: bob 2.2s ease-in-out infinite; }
.bk-glint { transform-box: fill-box; transform-origin: center; animation: twinkle 0.8s ease-in-out infinite alternate; }

.bk-lesson {
  margin-top: 26px;
  padding: 18px 22px 20px;
  border-radius: 28px;
  border: 4px solid #fff;
  background: linear-gradient(180deg, #f2fcff, #fff6fb);
  box-shadow: var(--shadow);
}
.bk-lesson h2 { font-size: 24px; text-align: center; }
.bk-lesson p { margin-top: 12px; font-size: 17px; line-height: 1.4; color: var(--ink-soft); }
.bk-steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; margin: 12px 0 0; padding: 0; list-style: none; counter-reset: step; }
.bk-steps li { display: grid; justify-items: center; gap: 2px; padding: 10px; border-radius: 20px; background: #fff; font-size: 17px; text-align: center; }
.bk-steps span { font-size: 36px; }

@media (max-width: 760px) {
  .bk-shelf { grid-template-columns: 1fr; }
  .bk-jar { grid-template-columns: 110px 1fr; grid-template-areas: 'art head' 'art body'; justify-items: start; text-align: left; }
  .bk-jar > :not(.bk-art):not(.bk-head) { grid-column: 2; }
  .bk-jar .bk-art { grid-area: art; grid-row: 1 / span 6; width: 100%; align-self: center; }
  .bk-head { grid-area: head; }
  .bk-buttons, .bk-quick { justify-content: flex-start; }
  .bk-stat { min-width: 0; flex: 1; padding: 6px 8px 8px; }
  .bk-stat small { font-size: 12px; }
  .bk-stat b { font-size: 20px; }
  .bk-steps { grid-template-columns: 1fr; }
  .bk-steps li { grid-template-columns: auto 1fr; justify-items: start; text-align: left; align-items: center; column-gap: 10px; }
  .bk-steps span { grid-row: span 2; font-size: 28px; }
}

@media (prefers-reduced-motion: reduce) {
  .bk-jar, .bk-ready .bk-art, .bk-glint { animation: none; }
}
