:root {
  --vulcan-orange: #f04b23;
  --text: #111827;
  --muted: #6b7280;
  --line: #d1d5db;
  --background: #f9fafb;
  --card: #ffffff;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: Arial, Helvetica, sans-serif;
  background: var(--background);
  color: var(--text);
}

.app {
  width: min(1100px, calc(100% - 32px));
  margin: 32px auto;
  background: var(--card);
  border-radius: 20px;
  padding: 28px;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.08);
}

.site-header {
  display: flex;
  align-items: center;
  gap: 16px;
  border-bottom: 1px solid var(--line);
  padding-bottom: 20px;
  margin-bottom: 20px;
}

.brand-mark {
  width: 52px;
  height: 52px;
  border-radius: 14px;
  background: var(--vulcan-orange);
  color: white;
  display: grid;
  place-items: center;
  font-size: 28px;
  font-weight: 800;
}

h1,
h2,
h3,
p {
  margin-top: 0;
}

h1 {
  margin-bottom: 4px;
  font-size: 32px;
}

.site-header p,
.hint {
  color: var(--muted);
}

.progress {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 8px;
  margin-bottom: 28px;
}

.step {
  padding: 10px 12px;
  border-radius: 999px;
  background: #f3f4f6;
  color: var(--muted);
  font-size: 14px;
  text-align: center;
  font-weight: 700;
}

.step.active {
  background: var(--vulcan-orange);
  color: white;
}

.form-step {
  display: none;
}

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

.grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 18px;
}

label {
  display: block;
  font-weight: 700;
  margin-bottom: 16px;
}

input,
select,
textarea {
  width: 100%;
  margin-top: 8px;
  padding: 12px 14px;
  border: 1px solid var(--line);
  border-radius: 12px;
  font: inherit;
}

textarea {
  resize: vertical;
}

.option-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 12px;
  margin-bottom: 28px;
}

.option-card {
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 14px;
  background: #fff;
  cursor: pointer;
}

.option-card input {
  width: auto;
  margin-right: 8px;
}

.repeat-list {
  display: grid;
  gap: 12px;
  margin-bottom: 16px;
}

.repeat-card {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr auto;
  gap: 12px;
  align-items: end;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: #fff;
}

.table-wrap {
  overflow-x: auto;
  border: 1px solid var(--line);
  border-radius: 16px;
}

table {
  width: 100%;
  border-collapse: collapse;
}

th,
td {
  padding: 10px;
  border-bottom: 1px solid var(--line);
  text-align: left;
}

th {
  background: #f3f4f6;
}

td input {
  margin-top: 0;
}

.form-actions {
  display: flex;
  justify-content: flex-end;
  gap: 12px;
  margin-top: 28px;
  border-top: 1px solid var(--line);
  padding-top: 20px;
}

button {
  border: 0;
  border-radius: 999px;
  padding: 12px 18px;
  font: inherit;
  font-weight: 700;
  cursor: pointer;
}

.primary-button {
  background: var(--vulcan-orange);
  color: white;
}

.secondary-button {
  background: #f3f4f6;
  color: var(--text);
}

.danger-button {
  background: #fee2e2;
  color: #991b1b;
}

.hidden {
  display: none;
}

#reviewOutput {
  background: #111827;
  color: #f9fafb;
  padding: 18px;
  border-radius: 16px;
  overflow-x: auto;
  min-height: 220px;
}

@media (max-width: 800px) {
  .app {
    width: min(100% - 20px, 1100px);
    padding: 18px;
  }

  .grid,
  .option-grid,
  .progress {
    grid-template-columns: 1fr;
  }

  .repeat-card {
    grid-template-columns: 1fr;
  }

  h1 {
    font-size: 24px;
  }
}
