/* ══════════════════════════════════════════════
   CREATURES SCREEN & CARDS
══════════════════════════════════════════════ */
.slot-indicator { color: var(--text-dim); font-size: 14px; margin-top: 2px; }

.creatures-grid {
  flex: 1; overflow-y: auto; padding: 12px;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
  gap: 10px;
  align-content: start;
}
@media (max-width: 380px) {
  .creatures-grid { grid-template-columns: repeat(2, 1fr); padding: 8px; gap: 8px; }
}

/* ── Creature Card ── */
.creature-card {
  position: relative;
  background: var(--bg3); border: 2px solid var(--border);
  cursor: pointer; transition: all 0.2s; overflow: hidden;
  aspect-ratio: 1; display: flex; flex-direction: column;
}
.creature-card:hover { border-color: var(--border2); transform: translateY(-2px); box-shadow: 0 6px 20px rgba(0,0,0,0.5); }
.creature-card.incubating { opacity: 0.85; }

.creature-card-img {
  flex: 1; display: flex; align-items: center; justify-content: center;
  font-size: 48px; position: relative; overflow: hidden;
  background: radial-gradient(circle at 50% 60%, rgba(255,255,255,0.03), transparent 70%);
}
.creature-card-img img {
  width: 80%; height: 80%; object-fit: contain; image-rendering: pixelated;
}

/* Incubation overlay */
.incubation-overlay {
  position: absolute; inset: 0;
  background: rgba(0,0,0,0.7);
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px;
}
.inc-icon { font-size: 24px; animation: pulse 1.5s ease-in-out infinite; }
.inc-timer { font-family: 'Share Tech Mono'; font-size: 13px; color: var(--accent); }
@keyframes pulse { 0%,100%{opacity:0.6;transform:scale(1)} 50%{opacity:1;transform:scale(1.1)} }

/* Expedition overlay */
.expedition-overlay {
  position: absolute; inset: 0;
  background: rgba(0,0,0,0.7);
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px;
}
.exp-overlay-icon { font-size: 24px; }
.exp-overlay-text { font-size: 12px; color: var(--orange); font-family: 'Share Tech Mono'; }

.creature-card-info {
  padding: 5px 7px;
  border-top: 1px solid var(--border);
  background: rgba(0,0,0,0.3);
}
.creature-name {
  font-family: 'Press Start 2P'; font-size: 6px;
  color: var(--text); white-space: nowrap;
  overflow: hidden; text-overflow: ellipsis; margin-bottom: 3px;
}
.creature-meta { display: flex; align-items: center; justify-content: space-between; }
.stage-badge { font-size: 12px; color: var(--text-dim); }

/* Empty slot */
.creature-slot-empty {
  border: 2px dashed var(--border); aspect-ratio: 1;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  color: var(--text-dark); font-size: 13px;
  cursor: pointer; transition: all 0.2s;
  background: rgba(255,255,255,0.01);
}
.creature-slot-empty:hover { border-color: var(--border2); color: var(--text-dim); }
.slot-plus { font-size: 26px; margin-bottom: 5px; color: var(--text-dark); }

/* ── Creature Detail ── */
.creature-detail-header {
  display: flex; gap: 16px; padding: 16px;
  border-bottom: 1px solid var(--border);
}
.creature-detail-img {
  width: 100px; height: 100px; flex-shrink: 0;
  background: var(--bg2); border: 2px solid var(--border);
  display: flex; align-items: center; justify-content: center;
  font-size: 60px; overflow: hidden;
}
.creature-detail-img img { width: 100%; height: 100%; object-fit: contain; image-rendering: pixelated; }
.creature-detail-info { flex: 1; min-width: 0; }
.creature-species { font-size: 12px; color: var(--text-dim); font-style: italic; margin-bottom: 2px; font-family: 'Share Tech Mono'; }
.creature-display-name { font-family: 'Press Start 2P'; font-size: 10px; color: var(--text); margin-bottom: 6px; line-height: 1.5; }
.creature-badges { display: flex; flex-wrap: wrap; gap: 4px; margin-bottom: 7px; }
.creature-flavor { font-size: 14px; color: var(--text-dim); font-style: italic; line-height: 1.4; }
.discoverer-tag { font-size: 13px; color: var(--text-dark); font-family: 'Share Tech Mono'; margin-top: 6px; }
.discoverer-tag span { color: var(--gold); }

.creature-detail-body { padding: 14px 16px; }

/* Stats */
.stats-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 5px; margin-bottom: 14px; }
.stat-row { display: flex; align-items: center; gap: 6px; }
.stat-label { font-family: 'Press Start 2P'; font-size: 6px; color: var(--text-dim); width: 28px; }
.stat-bar-wrap { flex: 1; height: 7px; background: var(--bg2); border: 1px solid var(--border); overflow: hidden; }
.stat-bar { height: 100%; transition: width 0.5s ease; }
.stat-bar.hp  { background: var(--green); }
.stat-bar.atk { background: var(--red); }
.stat-bar.def { background: #4488ff; }
.stat-bar.spd { background: var(--gold); }
.stat-bar.stm { background: var(--orange); }
.stat-bar.int { background: var(--purple); }
.stat-bar.lck { background: var(--accent); }
.stat-val { font-size: 13px; color: var(--text); width: 26px; text-align: right; font-family: 'Share Tech Mono'; }

/* Abilities */
.abilities-list { display: flex; flex-direction: column; gap: 6px; margin-bottom: 14px; }
.ability-card {
  background: var(--bg2); border: 1px solid var(--border);
  padding: 8px 10px; display: flex; align-items: flex-start; gap: 8px;
}
.ability-icon { font-size: 18px; flex-shrink: 0; margin-top: 2px; }
.ability-info { flex: 1; }
.ability-name { font-family: 'Press Start 2P'; font-size: 7px; color: var(--text); margin-bottom: 3px; }
.ability-desc { font-size: 14px; color: var(--text-dim); line-height: 1.3; }
.ability-meta { display: flex; flex-wrap: wrap; gap: 5px; margin-top: 4px; }
.ability-tag {
  font-size: 11px; padding: 1px 5px;
  background: rgba(255,255,255,0.04); color: var(--text-dim);
  border: 1px solid var(--border); font-family: 'Share Tech Mono';
}

/* Rename */
.rename-row { display: flex; gap: 6px; margin-top: 8px; }
.rename-input {
  flex: 1; background: var(--bg2); border: 2px solid var(--border);
  color: var(--text); font-family: 'VT323'; font-size: 18px;
  padding: 6px 10px; outline: none;
}
.rename-input:focus { border-color: var(--accent); }

/* Action buttons row */
.creature-actions { display: flex; gap: 8px; margin-top: 12px; flex-wrap: wrap; }

/* History card (ghost) */
.history-card {
  background: var(--bg2); border: 2px dashed var(--border);
  padding: 10px; cursor: pointer; transition: all 0.15s;
  display: flex; flex-direction: column; align-items: center; gap: 5px;
  text-align: center; opacity: 0.6;
}
.history-card:hover { opacity: 0.85; border-color: var(--border2); }
.history-label { font-size: 11px; color: var(--red); font-family: 'Share Tech Mono'; }