/* ============================================================
   wizard.css  –  Layout, wizard header/progress/body/footer
   ============================================================ */

/* LAYOUT */
.builder-layout {
  display: flex;
  flex-direction: column;
  min-height: calc(100vh - 64px);
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 1.5rem 2rem;
}

/* WIZARD HEADER – progress bar */
.wizard-header {
  padding: 2rem 0 1.5rem;
  text-align: center;
}

.wizard-header__title {
  font-family: 'Cinzel', serif;
  font-size: 2rem;
  color: var(--gold);
  margin-bottom: 1.5rem;
  letter-spacing: 0.05em;
}

.wizard-progress {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0;
  flex-wrap: nowrap;
  overflow-x: auto;
  padding-bottom: 0.25rem;
}

.wizard-progress__step {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.3rem;
  flex-shrink: 0;
  cursor: default;
  user-select: none;
}

.wizard-progress__step.clickable {
  cursor: pointer;
}

.wizard-progress__step.clickable:hover .wizard-progress__num {
  transform: scale(1.12);
  box-shadow: 0 0 10px rgba(201,162,39,0.3);
}

.wizard-progress__num {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  border: 2px solid var(--border);
  background: var(--bg-deep);
  color: var(--text-muted);
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: 'Cinzel', serif;
  font-size: 0.9rem;
  font-weight: 700;
  transition: all 0.25s ease;
  position: relative;
}

.wizard-progress__label {
  font-size: 0.7rem;
  color: var(--text-muted);
  white-space: nowrap;
  transition: color 0.25s ease;
}

.wizard-progress__connector {
  flex: 1;
  min-width: 20px;
  max-width: 60px;
  height: 2px;
  background: var(--border);
  margin-bottom: 22px;
  transition: background 0.25s ease;
}

/* Aktivní krok */
.wizard-progress__step.active .wizard-progress__num {
  background: var(--gold);
  border-color: var(--gold);
  color: var(--bg-deep);
}

.wizard-progress__step.active .wizard-progress__label {
  color: var(--gold);
  font-weight: 600;
}

/* Dokončené kroky */
.wizard-progress__step.done .wizard-progress__num {
  background: var(--bg-card);
  border-color: var(--gold);
  color: var(--gold);
}

.wizard-progress__step.done .wizard-progress__num::after {
  content: '✓';
  position: absolute;
  font-size: 0.55rem;
  bottom: -2px;
  right: -2px;
  background: #27ae60;
  color: #fff;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
}

.wizard-progress__step.done .wizard-progress__label {
  color: var(--text-dim);
}

/* Navštívený krok (neúplný) */
.wizard-progress__step.visited .wizard-progress__num {
  background: var(--bg-card);
  border-color: #e67e22;
  color: #e67e22;
}

.wizard-progress__step.visited .wizard-progress__num::after {
  content: '…';
  position: absolute;
  font-size: 0.6rem;
  bottom: -2px;
  right: -2px;
  background: #e67e22;
  color: #fff;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  line-height: 1;
}

.wizard-progress__step.visited .wizard-progress__label {
  color: #e67e22;
}

.wizard-progress__connector.visited {
  background: #e67e22;
}

.wizard-progress__connector.done {
  background: var(--gold);
}

/* Skrytý krok (Kouzla pro nemágy) */
.wizard-progress__step.step-hidden,
.wizard-progress__connector.step-hidden {
  display: none;
}

/* WIZARD NAV TOP – duplicitní navigace pod progress barem */
.wizard-nav-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.6rem 0;
  border-bottom: 1px solid var(--border);
  margin-bottom: 0.5rem;
}

/* WIZARD BODY */
.wizard-body {
  flex: 1;
  padding: 0.5rem 0;
}

.wizard-step {
  display: none;
  animation: fadeIn 0.3s ease;
}

.wizard-step.active {
  display: block;
}

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(8px); }
  to   { opacity: 1; transform: translateY(0); }
}

.step-title {
  font-family: 'Cinzel', serif;
  font-size: 1.5rem;
  color: var(--gold);
  margin-bottom: 0.4rem;
}

.step-desc {
  color: var(--text-dim);
  margin-bottom: 1.5rem;
  font-size: 0.95rem;
}

/* WIZARD FOOTER */
.wizard-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.2rem 0;
  border-top: 1px solid var(--border);
  margin-top: 1rem;
  gap: 1rem;
}

.wizard-footer__info {
  font-size: 0.85rem;
  color: var(--text-muted);
  text-align: center;
  flex: 1;
}

.wizard-footer__info.error {
  color: #e07070;
}

.reset-link {
  background: transparent;
  border: none;
  color: var(--text-dim);
  font-size: 0.78rem;
  cursor: pointer;
  padding: 0.2rem 0.4rem;
  border-radius: 4px;
  transition: color 0.15s;
  font-family: 'Crimson Text', serif;
}

.reset-link:hover {
  color: #e07070;
}

/* POMOCNÉ TŘÍDY */
.hidden {
  display: none !important;
}

.info-btn {
  background: transparent;
  border: 1px solid rgba(201, 162, 39, 0.3);
  border-radius: 50%;
  width: 20px;
  height: 20px;
  color: var(--text-muted);
  font-size: 0.7rem;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: all 0.15s;
  flex-shrink: 0;
}

.info-btn:hover {
  border-color: var(--gold);
  color: var(--gold);
}

/* Banner sdílený mezi kroky */
.racial-bonus-banner {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.5rem;
  padding: 0.6rem 1rem;
  background: rgba(201, 162, 39, 0.06);
  border: 1px solid rgba(201, 162, 39, 0.25);
  border-radius: 6px;
  font-size: 0.82rem;
  color: var(--text-dim);
  margin-bottom: 1rem;
}

.racial-bonus-banner em {
  color: var(--text-muted);
  font-style: normal;
}

/* Sdílený tracker */
.skill-points-tracker {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 0.8rem 1rem;
  background: rgba(201, 162, 39, 0.06);
  border: 1px solid rgba(201, 162, 39, 0.2);
  border-radius: 6px;
  font-size: 0.9rem;
  color: var(--text);
  margin-bottom: 0.5rem;
}

.skill-points-tracker strong {
  font-family: 'Cinzel', serif;
  font-size: 1.3rem;
  color: var(--gold);
}

/* Sdílený stat-btn */
.stat-btn {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  border: 1px solid var(--border);
  background: var(--bg-deep);
  color: var(--gold);
  font-size: 1.1rem;
  line-height: 1;
  cursor: pointer;
  transition: background 0.15s, border-color 0.15s;
  display: flex;
  align-items: center;
  justify-content: center;
}

.stat-btn:hover:not(:disabled) {
  background: var(--gold);
  border-color: var(--gold);
  color: var(--bg-deep);
}

.stat-btn:disabled {
  opacity: 0.3;
  cursor: not-allowed;
}

/* Sdílený hybrid badge */
.stat-hybrid-badge {
  font-size: 0.62rem;
  color: var(--gold);
  background: rgba(201, 162, 39, 0.1);
  border: 1px solid rgba(201, 162, 39, 0.25);
  border-radius: 10px;
  padding: 0.05rem 0.4rem;
  white-space: nowrap;
  width: fit-content;
  cursor: pointer;
  transition: background 0.15s;
}
.stat-hybrid-badge:hover {
  background: rgba(201, 162, 39, 0.2);
  border-color: var(--gold);
}

/* Import welcome panel */
.import-welcome-panel {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1rem;
  padding: 0.6rem 1rem;
  margin-bottom: 1rem;
  background: rgba(201, 162, 39, 0.05);
  border: 1px solid rgba(201, 162, 39, 0.18);
  border-radius: 8px;
  font-size: 0.85rem;
  color: var(--text-dim);
}
.import-welcome-panel.hidden { display: none; }
.import-welcome-panel__text { white-space: nowrap; }
.btn--sm { font-size: 0.8rem; padding: 0.3rem 0.8rem; }

@media (max-width: 500px) {
  .import-welcome-panel { flex-direction: column; gap: 0.5rem; text-align: center; }
}

/* Disabled step (non-caster spells) */
.wizard-progress__step.step-disabled .wizard-progress__num {
  background: var(--bg-deep);
  border-color: rgba(255,255,255,0.1);
  color: rgba(255,255,255,0.2);
  cursor: not-allowed;
}

.wizard-progress__step.step-disabled .wizard-progress__label {
  color: rgba(255,255,255,0.2);
  cursor: not-allowed;
}

.wizard-progress__step.step-disabled {
  cursor: not-allowed;
}

/* Select button for race/class cards */
.btn--select {
  padding: 0.3rem 1.2rem;
  font-size: 0.82rem;
  border-color: rgba(201, 162, 39, 0.4);
  background: rgba(201, 162, 39, 0.08);
  color: var(--gold);
}

.btn--select:hover {
  background: rgba(201, 162, 39, 0.2);
  border-color: var(--gold);
  transform: translateY(-1px);
}

.btn--select.btn--selected {
  background: var(--gold);
  border-color: var(--gold);
  color: var(--bg-deep);
}
