/* Golf Solitaire — seven open columns on the green felt. */

[hidden] { display: none !important; }

.gf-frame {
  width: min(760px, 96vw);
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding: clamp(10px, 2.2vw, 18px);
}
.deal-line {
  margin: 0;
  text-align: center;
  font-family: var(--hand);
  font-style: italic;
  font-size: clamp(14px, 2.1vw, 16.5px);
  color: var(--ink-soft);
  min-height: 1.4em;
}
.deal-line b { color: var(--oxblood); font-weight: 600; }

/* ---- the course ---- */
.course {
  position: relative;
  width: 100%;
  aspect-ratio: 10 / 5.1;
  border-radius: 10px;
  background: linear-gradient(180deg, rgba(31, 51, 38, .95), rgba(21, 36, 27, .98));
  box-shadow: inset 0 0 0 1px rgba(200, 156, 58, .3), inset 0 8px 22px rgba(0, 0, 0, .4);
  padding: 0;
}
.course .pcard {
  position: absolute;
  width: 12.2%;
  left: calc(3.3% + var(--col) * 13.5%);
  top: calc(3.5% + var(--k) * 12%);
  cursor: default;
  transition: transform .14s var(--ease), box-shadow .14s var(--ease), opacity .2s var(--ease);
}
.course .pcard.open { cursor: pointer; }
.course .pcard.open:hover { transform: translateY(-3px); }
.course .pcard.hint-glow {
  box-shadow: inset 0 0 0 2px rgba(122, 176, 132, .95), 0 6px 14px rgba(0, 0, 0, .4);
  z-index: 6;
}

/* the card back (the stock) */
.stock-pile .back {
  background:
    radial-gradient(120% 90% at 30% 0%, rgba(255, 255, 255, .14), rgba(255, 255, 255, 0) 55%),
    repeating-linear-gradient(45deg, rgba(94, 27, 32, .96) 0 6px, rgba(74, 20, 25, .96) 6px 12px),
    #5e1b20;
  box-shadow: inset 0 0 0 1px rgba(122, 104, 80, .55), inset 0 0 0 3px rgba(241, 230, 200, .16), 0 3px 8px rgba(0, 0, 0, .35);
}
.stock-pile .back::after {
  content: '✦';
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  color: rgba(227, 183, 84, .5);
  font-size: clamp(11px, 2vw, 15px);
}

/* ---- the tray: stock + waste ---- */
.tray {
  display: flex;
  align-items: center;
  gap: clamp(10px, 2.4vw, 22px);
  padding: 10px;
  border-radius: 10px;
  background: linear-gradient(180deg, rgba(31, 51, 38, .95), rgba(21, 36, 27, .98));
  box-shadow: inset 0 0 0 1px rgba(200, 156, 58, .3);
}
.stock {
  position: relative;
  border: none;
  background: none;
  padding: 10px 0 0 14px;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 10px;
  flex: none;
}
.stock-pile { position: relative; width: clamp(48px, 9vw, 62px); aspect-ratio: 5 / 7; }
.stock-pile .back { position: absolute; inset: 0; border-radius: 6px; }
.stock-pile.empty { border-radius: 6px; border: 1.5px dashed rgba(241, 230, 200, .25); }
.stock:hover .stock-pile .back:last-child { transform: translateY(-2px); }
.stock.pulse .stock-pile { animation: stock-pulse 1.1s ease 2; }
@keyframes stock-pulse {
  0%, 100% { transform: none; }
  50% { transform: translateY(-3px); }
}
.stock-label {
  font-family: var(--hand);
  font-style: italic;
  font-size: clamp(12.5px, 1.9vw, 15px);
  color: rgba(241, 230, 200, .75);
  text-align: left;
  line-height: 1.25;
}

.waste-slot {
  width: clamp(52px, 10vw, 68px);
  aspect-ratio: 5 / 7;
  border-radius: 7px;
  border: 1.5px dashed rgba(241, 230, 200, .3);
  position: relative;
  flex: none;
}
.waste-slot .pcard { position: absolute; inset: 0; width: 100%; }

.tray-line {
  margin: 0;
  font-family: var(--hand);
  font-style: italic;
  font-size: clamp(13px, 2vw, 15.5px);
  color: rgba(241, 230, 200, .8);
  flex: 1;
  text-align: right;
}
.tray-line b { color: var(--gold, #e3b754); font-weight: 600; }

.frame-actions { display: flex; gap: 8px; justify-content: center; flex-wrap: wrap; }

.help-body { text-align: left; font-size: 15.5px; line-height: 1.55; color: var(--ink-soft); }
.help-body p { margin: 0 0 12px; }
.help-body b { color: var(--oxblood); }

.new-best {
  display: inline-block;
  font-family: var(--caps);
  text-transform: uppercase;
  letter-spacing: .12em;
  font-size: 11.5px;
  color: var(--parchment);
  background: var(--oxblood);
  border-radius: 5px;
  padding: 2px 8px;
  margin-left: 6px;
  vertical-align: 1px;
}

@media (max-width: 640px) {
  .peaks .pcard { border-radius: 4px; }
  .gf-frame .pc-corner.br { display: none; }
  .gf-frame .pc-corner { font-size: clamp(9px, 2.2vw, 12px); }
  .gf-frame .pc-glyph { font-size: clamp(11px, 3vw, 16px); }
}
