/**
 * layout.css – Fejléc, progress bar, fő konténer, alsó navigáció
 *
 * Felelős:
 *   - .form-header (sticky fejléc, logó, ár badge)
 *   - .progress-nav (lépésjelző sáv)
 *   - .form-main (fő tartalomterület, scrollozható)
 *   - .bottom-nav (fixed alső navigáció: Vissza / Következő gombok)
 *   - .form-card (általános kártyakonténer)
 */

/* ==========================================================================
   FEJLÉC
   ========================================================================== */

.form-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--navy);
  border-bottom: 2px solid var(--red);
  box-shadow: var(--shadow-md);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 16px;
  max-width: 600px;
  margin: 0 auto;
}

/* --- Logó --- */
.header-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  flex-shrink: 0;
}

.logo-bolt {
  width: 36px;
  height: 36px;
  background: var(--red);
  border-radius: 9px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-size: 17px;
  flex-shrink: 0;
}

.logo-name {
  font-family: var(--font-title);
  font-size: 17px;
  font-weight: 700;
  color: var(--text-primary);
  display: block;
  letter-spacing: 1px;
  line-height: 1.1;
}

.logo-name em {
  color: var(--red);
  font-style: normal;
}

.logo-sub {
  font-size: 10px;
  color: var(--text-muted);
  display: block;
  margin-top: 1px;
  letter-spacing: 0.5px;
}

/* --- Ár badge --- */
.price-badge {
  background: var(--red-light);
  border: 1.5px solid var(--red-border);
  border-radius: 20px;
  padding: 5px 12px;
  font-size: 12px;
  font-weight: 700;
  color: var(--text-red);
  display: flex;
  align-items: center;
  gap: 6px;
  white-space: nowrap;
  transition: var(--transition);
  flex-shrink: 0;
}

.price-badge i {
  font-size: 11px;
}

/* --- Progress bar --- */
.progress-nav {
  padding: 10px 16px 0;
  max-width: 600px;
  margin: 0 auto;
}

.progress-track {
  height: 3px;
  background: rgba(255, 255, 255, 0.1);
  border-radius: 2px;
  margin-bottom: 10px;
  overflow: hidden;
}

.progress-fill {
  height: 100%;
  background: var(--red);
  border-radius: 2px;
  width: 20%; /* 1/5 lépésen → 20% */
  transition: width 0.4s ease;
}

/* --- Lépés pontok --- */
.step-dots {
  display: flex;
  justify-content: space-between;
  list-style: none;
  padding-bottom: 12px;
}

.step-dot-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  flex: 1;
}

.step-dot {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  border: 2px solid rgba(255, 255, 255, 0.15);
  background: var(--navy-mid);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  color: var(--text-muted);
  transition: all var(--transition);
}

.step-dot-label {
  font-size: 9px;
  color: var(--text-muted);
  font-weight: 600;
  letter-spacing: 0.3px;
  text-align: center;
  line-height: 1.2;
  transition: color var(--transition);
}

/* Aktív lépés */
.step-dot-item.active .step-dot {
  border-color: var(--red);
  color: var(--red);
  background: var(--navy-mid);
  box-shadow: 0 0 10px rgba(200, 16, 46, 0.4);
}

.step-dot-item.active .step-dot-label {
  color: var(--red);
}

/* Kész lépés */
.step-dot-item.done .step-dot {
  background: var(--red);
  border-color: var(--red);
  color: white;
}

.step-dot-item.done .step-dot-label {
  color: var(--text-secondary);
}

/* ==========================================================================
   FŐ TARTALOM
   ========================================================================== */

.form-main {
  max-width: 600px;
  margin: 0 auto;
  padding: 20px 16px 120px; /* bottom: hely az alsó navigációnak */
  width: 100%;
}

/* ==========================================================================
   ÁLTALÁNOS KÁRTYAKONTÉNER
   ========================================================================== */

.form-card {
  background: var(--card-bg);
  border: 1px solid var(--card-border);
  border-radius: var(--radius);
  padding: 20px;
  margin-bottom: 14px;
  transition: border-color var(--transition);
}

.form-card:last-child {
  margin-bottom: 0;
}

/* ==========================================================================
   ALSÓ NAVIGÁCIÓ (fixed)
   ========================================================================== */

.bottom-nav {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 90;
  background: var(--navy);
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  padding: 12px 16px;
  display: flex;
  gap: 10px;
  box-shadow: 0 -4px 20px rgba(0, 0, 0, 0.4);
}

/* Belső szélességkorlát */
.bottom-nav::before {
  content: '';
  position: absolute;
}

.btn-back {
  background: rgba(255, 255, 255, 0.07);
  border: 1.5px solid rgba(255, 255, 255, 0.12);
  border-radius: var(--radius-sm);
  padding: 13px 18px;
  font-size: 14px;
  font-weight: 700;
  color: var(--text-secondary);
  display: flex;
  align-items: center;
  gap: 7px;
  flex-shrink: 0;
  transition: all var(--transition);
}

.btn-back:hover {
  background: rgba(255, 255, 255, 0.11);
  color: var(--text-primary);
}

/* Az 1. lépésen a Vissza gomb rejtett */
.btn-back.hidden {
  visibility: hidden;
  pointer-events: none;
}

.btn-next {
  flex: 1;
  background: var(--red);
  border-radius: var(--radius-sm);
  padding: 13px;
  font-size: 15px;
  font-weight: 700;
  color: white;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  transition: all var(--transition);
  box-shadow: var(--shadow-red);
  font-family: var(--font-title);
  letter-spacing: 0.5px;
}

.btn-next:hover {
  background: var(--red-hover);
  transform: translateY(-1px);
  box-shadow: 0 6px 24px rgba(200, 16, 46, 0.5);
}

.btn-next:active {
  transform: translateY(0);
}

/* Disabled állapot */
.btn-next:disabled,
.btn-next.disabled {
  opacity: 0.45;
  pointer-events: none;
  box-shadow: none;
}

/* ==========================================================================
   TOAST ÉRTESÍTŐK KONTÉNER
   ========================================================================== */

#toastContainer {
  position: fixed;
  top: 16px;
  right: 16px;
  z-index: 9999;
  display: flex;
  flex-direction: column;
  gap: 8px;
  pointer-events: none;
  max-width: calc(100vw - 32px);
}
