@font-face {
  font-family: 'Georgia';
  src: local('Georgia');
}

:root {
  --bg-0: #101013;
  --bg-1: #161619;
  --bg-2: #1d1d21;
  --bg-3: #232328;
  --line: rgba(212, 165, 101, 0.16);
  --line-strong: rgba(212, 165, 101, 0.35);
  --gold: #d4a565;
  --gold-bright: #f0c98a;
  --cream: #e8e1d4;
  --cream-dim: #9a9384;
  --muted: #6f675a;
  --danger: #d97a6a;
  --success: #7fb37a;
  --shadow: 0 20px 60px rgba(0, 0, 0, 0.55);
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
  min-height: 100%;
}

body {
  font: 400 14.5px/1.6 "Segoe UI", system-ui, sans-serif;
  color: var(--cream);
  background:
    radial-gradient(1200px 600px at 15% -10%, rgba(212,165,101,0.08), transparent 60%),
    radial-gradient(1000px 500px at 100% 0%, rgba(139,111,66,0.10), transparent 55%),
    linear-gradient(180deg, var(--bg-0), var(--bg-1) 40%, var(--bg-0));
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 40px 20px 60px;
  position: relative;
  overflow-x: hidden;
}

body::before {
  content: '';
  position: fixed;
  inset: 0;
  pointer-events: none;
  background-image:
    repeating-linear-gradient(0deg, rgba(255,255,255,0.012) 0px, rgba(255,255,255,0.012) 1px, transparent 1px, transparent 3px);
  opacity: 0.5;
}

.bw-shell {
  width: 100%;
  max-width: 760px;
  position: relative;
  z-index: 1;
}

/* Brand header */
.bw-brand {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 14px;
  margin-bottom: 30px;
}

.bw-brand svg { width: 42px; height: 42px; filter: drop-shadow(0 0 10px rgba(212,165,101,0.35)); }

.bw-brand h1 {
  font: 700 26px/1 Georgia, "Times New Roman", serif;
  letter-spacing: 1.5px;
  margin: 0;
  color: var(--cream);
}

.bw-brand h1 span { color: var(--gold); }

.bw-brand .bw-tag {
  font: 500 10.5px/1 "Segoe UI", sans-serif;
  letter-spacing: 2.5px;
  text-transform: uppercase;
  color: var(--cream-dim);
  display: block;
  margin-top: 4px;
}

/* Stepper */
.bw-stepper {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 34px;
  padding: 0 4px;
}

.bw-stepper .bw-step-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  flex: 1;
  position: relative;
}

.bw-stepper .bw-step-item:not(:last-child)::after {
  content: '';
  position: absolute;
  top: 13px;
  left: 55%;
  right: -45%;
  height: 2px;
  background: var(--line);
  z-index: 0;
}

.bw-stepper .bw-step-item.done:not(:last-child)::after { background: var(--gold); opacity: 0.55; }

.bw-step-dot {
  width: 26px;
  height: 26px;
  border-radius: 50%;
  border: 2px solid var(--line-strong);
  background: var(--bg-2);
  display: flex;
  align-items: center;
  justify-content: center;
  font: 700 11px/1 "Segoe UI", sans-serif;
  color: var(--cream-dim);
  position: relative;
  z-index: 1;
  transition: all .25s ease;
}

.bw-step-item.active .bw-step-dot {
  border-color: var(--gold);
  color: var(--bg-0);
  background: var(--gold);
  box-shadow: 0 0 16px rgba(212,165,101,0.55);
}

.bw-step-item.done .bw-step-dot {
  border-color: var(--gold);
  color: var(--gold);
  background: transparent;
}

.bw-step-label {
  font: 600 9.5px/1 "Segoe UI", sans-serif;
  letter-spacing: 1px;
  text-transform: uppercase;
  color: var(--cream-dim);
  text-align: center;
}

.bw-step-item.active .bw-step-label { color: var(--gold-bright); }

/* Card */
.bw-card {
  background: var(--bg-2);
  border: 1px solid var(--line);
  border-top: 2px solid var(--gold);
  border-radius: 4px;
  padding: 28px 32px;
  position: relative;
}

.bw-card h2 {
  font: 700 19px/1.3 "Segoe UI", sans-serif;
  color: var(--cream);
  margin: 0 0 6px;
}

.bw-card h2 span { color: var(--gold); }

.bw-card .bw-lead {
  color: var(--cream-dim);
  margin: 0 0 22px;
  font-size: 13px;
}

/* Section grouping inside a form (WoltLab-style: subheading + divider) */
.bw-form-section { margin-bottom: 26px; }
.bw-form-section:last-of-type { margin-bottom: 0; }

.bw-form-section h3 {
  font: 700 14px/1 "Segoe UI", sans-serif;
  color: var(--gold-bright);
  margin: 0 0 10px;
  padding-bottom: 10px;
  border-bottom: 1px solid var(--line);
}

.bw-required { color: var(--danger); }

/* Long-form legal text (registration disclaimer, etc.) */
.bw-legal { margin-bottom: 24px; }

.bw-legal h3 {
  font: 700 15px/1.3 "Segoe UI", sans-serif;
  color: var(--gold-bright);
  margin: 22px 0 8px;
}

.bw-legal h3:first-child { margin-top: 0; }

.bw-legal p {
  color: var(--cream-dim);
  font-size: 13px;
  line-height: 1.7;
  margin: 0 0 10px;
}

.bw-legal ul {
  margin: 0 0 10px;
  padding-left: 20px;
  color: var(--cream-dim);
  font-size: 13px;
  line-height: 1.7;
}

/* Form elements */
.bw-field { margin-bottom: 18px; }

.bw-field label {
  display: block;
  font: 600 11.5px/1 "Segoe UI", sans-serif;
  letter-spacing: .5px;
  text-transform: uppercase;
  color: var(--cream-dim);
  margin-bottom: 8px;
}

.bw-field input[type=text],
.bw-field input[type=password],
.bw-field input[type=email],
.bw-field input[type=number] {
  width: 100%;
  background: var(--bg-0);
  border: 1px solid var(--line);
  border-radius: 3px;
  padding: 11px 13px;
  color: var(--cream);
  font: 500 14px "Segoe UI", sans-serif;
  outline: none;
  transition: border-color .2s ease, box-shadow .2s ease;
}

.bw-field input:focus {
  border-color: var(--gold);
  box-shadow: 0 0 0 3px rgba(212,165,101,0.15);
}

.bw-field .bw-hint { font-size: 11.5px; color: var(--muted); margin-top: 6px; }
.bw-field .bw-error { font-size: 12px; color: var(--danger); margin-top: 6px; }

.bw-row { display: flex; gap: 16px; }
.bw-row .bw-field { flex: 1; }

/* Buttons */
.bw-actions {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  margin-top: 28px;
  gap: 12px;
}

.bw-btn {
  appearance: none;
  border: 1px solid var(--line-strong);
  background: transparent;
  color: var(--cream-dim);
  font: 600 13px "Segoe UI", sans-serif;
  letter-spacing: .3px;
  padding: 10px 18px;
  border-radius: 3px;
  cursor: pointer;
  transition: all .2s ease;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

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

.bw-btn-primary {
  background: var(--gold);
  border-color: var(--gold);
  color: #241a0d;
}

.bw-btn-primary:hover { filter: brightness(1.08); color: #241a0d; }

.bw-btn:disabled { opacity: .5; cursor: not-allowed; }

.bw-btn-block { width: 100%; justify-content: center; }

/* Requirement list */
.bw-req-list { list-style: none; margin: 0 0 22px; padding: 0; }

.bw-req-list li {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 11px 0;
  border-bottom: 1px solid var(--line);
  font-size: 13.5px;
}

.bw-req-list li:last-child { border-bottom: none; }

.bw-req-icon {
  width: 20px; height: 20px;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0;
  font-size: 12px;
  font-weight: 700;
}

.bw-req-icon.ok { background: rgba(127,179,122,0.15); color: var(--success); }
.bw-req-icon.fail-critical { background: rgba(217,122,106,0.15); color: var(--danger); }
.bw-req-icon.fail-optional { background: rgba(212,165,101,0.15); color: var(--gold); }

.bw-req-detail { margin-left: auto; color: var(--cream-dim); font-size: 12px; }

/* License box */
.bw-license-box {
  max-height: 260px;
  overflow-y: auto;
  background: var(--bg-0);
  border: 1px solid var(--line);
  border-radius: 3px;
  padding: 18px 20px;
  font-size: 13px;
  color: var(--cream-dim);
  margin-bottom: 18px;
  line-height: 1.7;
}

.bw-license-box h3 { color: var(--cream); font-size: 14px; margin: 14px 0 6px; }
.bw-license-box h3:first-child { margin-top: 0; }

.bw-checkbox {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  font-size: 13.5px;
  color: var(--cream-dim);
  cursor: pointer;
  user-select: none;
}

.bw-checkbox input { margin-top: 3px; accent-color: var(--gold); width: 16px; height: 16px; }

/* Alerts */
.bw-alert {
  border-radius: 3px;
  padding: 13px 16px;
  font-size: 13px;
  margin-bottom: 18px;
  border: 1px solid;
  display: flex;
  gap: 10px;
  align-items: flex-start;
}

.bw-alert-danger { background: rgba(217,122,106,0.08); border-color: rgba(217,122,106,0.35); color: #f0b8ac; }
.bw-alert-success { background: rgba(127,179,122,0.08); border-color: rgba(127,179,122,0.35); color: #bfe0ba; }
.bw-alert-info { background: rgba(143,176,216,0.08); border-color: rgba(143,176,216,0.35); color: #bcd3ec; }

/* Progress (install step) */
.bw-progress-wrap { margin: 10px 0 22px; }

.bw-progress-track {
  height: 10px;
  border-radius: 6px;
  background: var(--bg-0);
  border: 1px solid var(--line);
  overflow: hidden;
  position: relative;
}

.bw-progress-fill {
  height: 100%;
  width: 0%;
  background: linear-gradient(90deg, var(--gold), var(--gold-bright));
  border-radius: 6px;
  transition: width .35s ease;
  position: relative;
}

.bw-progress-fill::after {
  content: '';
  position: absolute; inset: 0;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,0.35), transparent);
  width: 60px;
  animation: bw-shimmer 1.3s infinite linear;
}

@keyframes bw-shimmer {
  0% { transform: translateX(-80px); }
  100% { transform: translateX(260px); }
}

.bw-progress-meta {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  font-size: 11.5px;
  color: var(--cream-dim);
  margin-top: 8px;
  letter-spacing: .3px;
}

.bw-log {
  max-height: 160px;
  overflow-y: auto;
  background: var(--bg-0);
  border: 1px solid var(--line);
  border-radius: 3px;
  padding: 12px 14px;
  font: 400 12px/1.7 "Consolas", monospace;
  color: var(--cream-dim);
}

.bw-log .ok { color: var(--success); }
.bw-log .ok::before { content: '✓ '; }

/* Finish */
.bw-finish-icon {
  width: 56px; height: 56px;
  margin: 0 auto 16px;
  display: flex; align-items: center; justify-content: center;
}

.bw-finish-icon svg { width: 40px; height: 40px; }

.bw-summary {
  background: var(--bg-0);
  border: 1px solid var(--line);
  border-radius: 3px;
  padding: 16px 18px;
  margin: 18px 0;
  font-size: 13px;
}

.bw-summary div { display: flex; justify-content: space-between; gap: 12px; padding: 6px 0; border-bottom: 1px solid var(--line); }
.bw-summary div:last-child { border-bottom: none; }
.bw-summary .k { color: var(--cream-dim); }
.bw-summary .v { color: var(--cream); font-weight: 600; }

.bw-footer {
  text-align: center;
  color: var(--muted);
  font-size: 11.5px;
  margin-top: 26px;
  letter-spacing: .3px;
}

@media (max-width: 560px) {
  .bw-card { padding: 26px 20px; }
  .bw-row { flex-direction: column; gap: 0; }
  .bw-step-label { display: none; }
}
