/* deletreo.css */
.game-area {
  gap: 0.8rem;
  justify-content: flex-start;
  padding-top: 0.9rem;
}

.del-pregunta { font-size: clamp(1.1rem, 4.5vw, 1.5rem); font-weight: 900; }

.del-img-wrap {
  position: relative;
  width: min(42vw, 30vh, 190px);
  aspect-ratio: 1;
  background: rgba(255,255,255,0.92);
  border: none;
  border-radius: var(--radius-md);
  box-shadow: var(--shadow);
  padding: 0.7rem;
  cursor: pointer;
}
.del-img-wrap img { width: 100%; height: 100%; object-fit: contain; pointer-events: none; }
.del-speaker {
  position: absolute; right: -8px; bottom: -8px;
  background: var(--c-deletreo); border-radius: 50%;
  width: 40px; height: 40px; display: grid; place-items: center;
  font-size: 1.2rem; box-shadow: var(--shadow-sm);
}

/* Casillas */
.del-slots {
  display: flex; flex-wrap: wrap; justify-content: center;
  gap: 0.4rem; max-width: 100%;
  --w: clamp(26px, calc((100vw - 2rem) / var(--n) - 8px), 52px);
}
.del-slot {
  width: var(--w); height: calc(var(--w) * 1.25);
  border-bottom: 4px solid #fff;
  display: grid; place-items: center;
  font-size: calc(var(--w) * 0.8); font-weight: 900; line-height: 1;
}
.del-slot.filled { color: var(--c-tubes); animation: bounce-in 0.35s both; }
.del-slot.helped { color: #A7F3D0; }

.del-status { display: flex; align-items: center; gap: 1rem; font-weight: 900; }
.del-help[disabled] { opacity: 0.45; cursor: default; }

/* Teclado */
.del-keyboard { display: flex; flex-direction: column; gap: 0.4rem; width: 100%; max-width: 560px; margin-top: auto; }
.del-row { display: flex; justify-content: center; gap: 0.3rem; }
.del-key {
  flex: 1 1 0; max-width: 52px; min-height: 48px;
  font-family: var(--font); font-weight: 900; font-size: clamp(1rem, 4.5vw, 1.4rem);
  background: rgba(255,255,255,0.92); color: var(--dark);
  border: none; border-radius: 10px; box-shadow: 0 3px 0 rgba(0,0,0,0.25);
  cursor: pointer; touch-action: manipulation;
}
.del-key:active { transform: translateY(2px); box-shadow: 0 1px 0 rgba(0,0,0,0.25); }
.del-key.bad { background: #FCA5A5; }

/* Error: sacude la pantalla */
.shake { animation: del-shake 0.4s; }
@keyframes del-shake {
  0%,100% { transform: translateX(0); }
  20% { transform: translateX(-14px); } 40% { transform: translateX(12px); }
  60% { transform: translateX(-9px); }  80% { transform: translateX(6px); }
}

.del-toast {
  position: fixed; left: 50%; top: 40%; transform: translateX(-50%);
  background: rgba(30,27,75,0.95); padding: 1rem 1.5rem; border-radius: var(--radius-md);
  font-weight: 900; text-align: center; z-index: 150; box-shadow: var(--shadow);
}

@media (max-height: 640px) {
  .del-key { min-height: 40px; }
  .del-img-wrap { width: min(34vw, 26vh, 150px); }
}
