.code-modal-panel {
  width: 100%;
  max-width: 680px;
  max-height: 85vh;
  background: var(--liquid-glass-bg);
  border: 1px solid var(--liquid-glass-border);
  border-top: 1px solid var(--liquid-glass-border-top);
  border-bottom: 2px solid var(--theme-accent);
  border-radius: var(--radius-modal);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  box-shadow: 0 24px 64px rgba(0, 0, 0, 0.98);
}

/* Modal Tabs Navigation */
.code-tab-bar {
  display: flex;
  gap: 8px;
  border-bottom: 1px solid var(--liquid-glass-border);
  padding: 0 20px;
  background: rgba(0, 0, 0, 0.45);
}

.code-tab-btn {
  background: transparent;
  border: none;
  border-bottom: 2px solid transparent;
  color: var(--color-moon-mist);
  font-family: var(--font-aeonikpro);
  font-size: 13px;
  font-weight: 800;
  padding: 10px 14px;
  cursor: pointer;
  transition: all 0.12s ease;
}

.code-tab-btn:hover {
  color: #ffffff;
}

.code-tab-btn.active {
  color: var(--color-cyan);
  border-bottom-color: var(--color-cyan);
}

.code-tab-pane {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.code-tab-pane.hidden {
  display: none !important;
}

.code-textarea {
  width: 100%;
  height: 280px;
  background: #02050e;
  border: 1px solid var(--liquid-glass-border);
  border-radius: var(--radius-card);
  padding: 12px;
  color: #38bdf8;
  font-family: var(--font-dotdigital);
  font-size: 12px;
  line-height: 1.4;
  resize: vertical;
  outline: none;
  white-space: pre;
}

.code-textarea:focus {
  border-color: var(--theme-accent);
}

.code-actions-row {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  margin-top: 8px;
}

/* Custom Level Select Cards */
.custom-levels-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
  max-height: 240px;
  overflow-y: auto;
}

.custom-level-item {
  background: var(--glass-3d-card-bg);
  border: 1px solid var(--glass-3d-card-border);
  border-radius: var(--radius-card);
  padding: 8px 12px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 8px;
}

.custom-level-item:hover {
  border-color: var(--theme-accent);
}

.custom-level-title {
  font-weight: 700;
  color: var(--color-ice-highlight);
  font-size: 13px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}