.projects-layout {
  display: flex;
  width: 100%;
  height: 100%;
  gap: 20px;
  align-items: stretch;
}

/* Side columns */
.projects-column {
  display: flex;
  flex-direction: column;
  gap: 20px;
  width: 200px;
}

/* Game in centre */
.game-wrapper {
  position: relative;
  flex: 1 1 0;
  min-height: 0;  
}

/* Canvas fills centre */
#gameCanvas {
  width: 100%;
  height: 100%;
  display: block;
}

/* Overlay */
#projectOverlay {
  display: none;
  position: absolute;
  inset: 0;
  background: rgba(0,0,0,0.85);
  align-items: center;
  justify-content: center;
  z-index: 10;
}

/* Project cards */
.project-card {
  background: #111;
  border: 2px solid #333;
  border-radius: 12px;
  padding: 1rem;
  color: #888;
  font-family: sans-serif;
  cursor: not-allowed;
  transition: all 0.3s ease;
  flex: 1 1 0;
  min-height: 0; 
}

/* Locked state */
.project-card.locked {
  opacity: 0.4;
}

/* Unlocked */
.project-card.unlocked {
  opacity: 1;
  cursor: pointer;
  border-color: currentColor;
}

/* Hover effect */
.project-card.unlocked:hover {
  transform: scale(1.05);
}

/* Title */
.project-card h3 {
  margin: 0;
  font-size: 16px;
}

/* Expanded modal */
.project-modal {
  background: #111;
  border-radius: 12px;
  padding: 2rem;
  width: 80%;
  height: 80%;
  color: white;
  overflow-y: auto; 
}

.card-subtitle {
  font-size: 12px;
  color: #666;
  margin-top: 6px;
  line-height: 1.4;
}

.modal-image {
  width: 100%;
  height: 80%;
  object-fit: contain;
  border-radius: 8px;
  margin-bottom: 1rem;
}

.modal-description {
  font-size: 0.9rem;
  line-height: 1.6;
  color: #ccc;
  margin: 0.75rem 0 1.25rem;
}

.modal-link {
  display: inline-block;
  font-size: 0.9rem;
  text-decoration: none;
  font-weight: bold;
  letter-spacing: 0.05em;
  transition: opacity 0.2s;
}

.modal-link:hover {
  opacity: 0.7;
}

.project-card.locked .unlocked-text   { 
  display: none; 
}

.project-card.unlocked .locked-hint   { 
  display: none; 
}