/* ==========================================================================
   Guessquatch — Footprints Gameplay Styles
   Weathered Woodgrain Trail-Sign Theme with Blue Trail-Blaze Accent.
   ========================================================================== */

.fp-screen {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

/* Weathered Woodgrain Game Header Slat with Blue Trail-Blaze Accent */
.fp-header {
  --wood-pos-x: 72%;
  --wood-pos-y: 34%;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 12px 16px;
  border-left: 10px solid var(--blaze-footprints);
}

.fp-header-left,
.fp-header-right {
  display: flex;
  align-items: center;
  gap: 12px;
}

.fp-title-wrap {
  display: inline-flex;
  align-items: center;
  gap: 9px;
}

.fp-title-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 30px;
  height: 30px;
  border-radius: 5px;
  background-color: var(--blaze-footprints);
  border: 1.5px solid var(--blaze-footprints-border);
  box-shadow: 0 2px 0 var(--blaze-footprints-lip);
  color: #F6F2EA;
}

.fp-title {
  margin: 0;
  font-size: 1.24rem;
  font-weight: 900;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--wood-text);
  text-shadow: 0 1px 2px rgba(20, 11, 4, 0.65);
}

.fp-workspace {
  display: grid;
  grid-template-columns: 1fr;
  gap: 16px;
  align-items: start;
}

.fp-main-col {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 14px;
  width: 100%;
  min-width: 0;
}

/* Clue Sign Plate & Countdown */
.fp-clue-plate {
  width: 100%;
  display: flex;
  flex-direction: column;
  gap: 11px;
  padding: 16px 18px 18px;
  border-left: 10px solid var(--blaze-footprints);
}

.fp-clue-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.fp-clue-badges {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px;
}

.fp-timer-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 10px;
  border-radius: 4px;
  border: 1px solid var(--wood-streak-border);
  background-color: var(--wood-streak-bg);
  box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.55);
  color: var(--wood-text);
  font-family: var(--font-mono);
  font-size: 0.8rem;
  font-weight: 800;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

.fp-timer-pill--urgent {
  border-color: rgba(240, 196, 36, 0.65);
  color: #F4CE52;
}

.fp-timer-pill--done {
  border-color: rgba(68, 191, 120, 0.58);
  color: #5CE094;
}

.fp-timer-track {
  width: 100%;
  height: 8px;
  border-radius: 4px;
  background-color: var(--wood-trough-bg);
  border: 1px solid var(--wood-trough-border);
  box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.65);
  overflow: hidden;
}

.fp-timer-fill {
  height: 100%;
  background-color: var(--blaze-footprints);
  transition: width 60ms linear;
}

.fp-timer-fill--done {
  background-color: var(--tile-correct-bg);
}

.fp-clue-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

/* Each Revealed Clue Styled as a Clean Woodgrain Slat */
.fp-clue-item {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 10px 12px;
  border-radius: 6px;
  background-color: var(--wood-btn-bg);
  background-image:
    linear-gradient(var(--wood-btn-tint), var(--wood-btn-tint)),
    url('../assets/wood-slat.jpg');
  background-size: 100% 100%, 520px auto;
  background-repeat: no-repeat, repeat;
  border: 1.5px solid var(--wood-btn-border);
  box-shadow:
    inset 0 1px 0 var(--wood-bevel-top),
    0 3px 0 var(--wood-btn-lip);
  font-size: 0.92rem;
  font-weight: 700;
  color: var(--wood-text);
  text-shadow: 0 1px 2px rgba(18, 10, 4, 0.6);
}

.fp-clue-item--active {
  border-color: var(--blaze-footprints-border);
  border-left: 6px solid var(--blaze-footprints);
  box-shadow:
    inset 0 1px 0 rgba(255, 240, 212, 0.28),
    0 3px 0 var(--wood-btn-lip);
}

/* Future Locked Clues Styled as Recessed Dark-Wood Troughs */
.fp-clue-item--locked {
  background-image: none;
  background-color: var(--wood-trough-bg);
  border-color: var(--wood-trough-border);
  box-shadow: inset 0 2px 5px rgba(0, 0, 0, 0.55);
  color: var(--wood-text-muted);
  text-shadow: none;
  opacity: 0.72;
}

.fp-clue-text {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  line-height: 1.38;
}

/* Word Tiles & Guess Plate (Recessed Dark-Wood Trough) */
.fp-word-plate {
  width: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 11px;
  padding: 16px 14px;
}

.fp-word-row {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 6px;
  width: 100%;
  max-width: 520px;
}

.fp-word-row--shake {
  animation: gq-shake 360ms ease-in-out;
}

/* Chunky Wooden Letter Blanks */
.fp-tile {
  flex: 0 1 48px;
  min-width: 26px;
  aspect-ratio: 1 / 1;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 6px;
  border: 1.5px solid var(--wood-tile-border);
  background-color: var(--wood-tile-bg);
  background-image:
    linear-gradient(var(--wood-tile-overlay), var(--wood-tile-overlay)),
    url('../assets/wood-slat.jpg');
  background-size: 100% 100%, 340px auto;
  background-repeat: no-repeat, repeat;
  color: var(--wood-text);
  text-shadow: 0 1px 2px rgba(18, 10, 4, 0.65);
  box-shadow:
    inset 0 1px 0 var(--wood-bevel-top),
    0 4px 0 var(--wood-tile-lip);
  font-size: clamp(1rem, 4vw, 1.45rem);
  font-weight: 900;
  letter-spacing: 0.02em;
  text-transform: uppercase;
  user-select: none;
}

.fp-word-row[data-word-length="9"] .fp-tile,
.fp-word-row[data-word-length="10"] .fp-tile {
  font-size: clamp(0.88rem, 3.4vw, 1.25rem);
}

.fp-tile--cursor {
  border-color: var(--blaze-footprints-border);
}

.fp-tile--filled {
  border-color: var(--wood-tile-filled-border);
  animation: gq-tile-pop 110ms ease-out;
}

.fp-tile--locked {
  background-image: none;
  background-color: var(--blaze-footprints);
  border-color: var(--blaze-footprints-border);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.28),
    0 4px 0 var(--blaze-footprints-lip);
  color: #F6F2EA;
}

.fp-tile--correct {
  background-image: none;
  background-color: var(--tile-correct-bg);
  border-color: var(--tile-correct-border);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.28),
    0 4px 0 var(--tile-correct-lip);
  color: var(--tile-correct-text);
}

.fp-tile--missed {
  background-image: none;
  background-color: var(--wood-trough-solid);
  border-color: var(--blaze-campfire);
  box-shadow: 0 4px 0 var(--blaze-campfire-lip);
  color: var(--wood-text);
}

.fp-guess-hint {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 6px;
  text-align: center;
  font-size: 0.84rem;
  font-weight: 700;
  color: var(--wood-text-sub);
}

.fp-lock-controls {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 10px;
}

/* On-Screen Keyboard */
.fp-keyboard {
  width: 100%;
  max-width: 500px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding-bottom: 4px;
}

.fp-kb-enter-ready {
  --key-lip: var(--blaze-footprints-lip);
  background-image: none;
  background-color: var(--blaze-footprints);
  border-color: var(--blaze-footprints-border);
  color: #F6F2EA;
}

/* Player Lock-In Status Panel */
.fp-players-panel {
  width: 100%;
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding: 16px;
}

.fp-player-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.fp-player-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 9px 11px;
  border-radius: var(--radius-sm);
  background-color: var(--wood-trough-bg);
  border: 1.5px solid var(--wood-trough-border);
  box-shadow: inset 0 2px 5px rgba(0, 0, 0, 0.5);
  color: var(--wood-text);
}

.fp-player-row--local {
  border-color: var(--blaze-footprints-border);
  border-left: 5px solid var(--blaze-footprints);
}

.fp-player-left {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
}

.fp-winner-icon {
  display: inline-flex;
  color: var(--blaze-forage);
}

.fp-player-name-col {
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.fp-player-name {
  font-size: 0.88rem;
  font-weight: 800;
  color: var(--wood-text);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.fp-player-guess-sub {
  font-family: var(--font-mono);
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  color: var(--wood-text-sub);
}

/* Summary / Scoreboard */
.fp-summary-slot {
  width: 100%;
  display: flex;
  justify-content: center;
}

.fp-summary-card {
  max-width: 520px;
  border-left: 10px solid var(--blaze-footprints);
}

.fp-scoreboard-guess {
  font-family: var(--font-mono);
  font-size: 0.84rem;
  font-weight: 800;
  letter-spacing: 0.06em;
  color: var(--wood-text);
}

/* Responsive Adjustments */
@media (min-width: 640px) {
  .fp-word-plate {
    padding: 16px 18px;
  }

  .fp-word-row {
    gap: 7px;
  }
}

@media (min-width: 960px) {
  .fp-workspace {
    grid-template-columns: minmax(0, 1fr) 295px;
    gap: 20px;
  }
}
