:root {
  --red: #4a0e0e;
  --beige: #f4e7c9;
  --bg: #f7f2e9;
  --ink: #2b2b2b;
  --line: #ddd3bd;
}
* { box-sizing: border-box; }
body {
  margin: 0; background: var(--bg); color: var(--ink);
  font-family: Georgia, 'Times New Roman', serif;
}
.site-header { text-align: center; padding: 2.2rem 1rem 0.5rem; }
.brand { font-size: 2rem; letter-spacing: 0.45em; color: var(--red); font-weight: 700; text-indent: 0.45em; }
.brand-sub { letter-spacing: 0.6em; font-size: 0.7rem; color: #8a6d3b; text-indent: 0.6em; margin-top: 0.2rem; }
.site-header h1 { color: var(--red); font-weight: 500; margin: 1.4rem 0 0.3rem; font-size: 1.9rem; }
.tagline { color: #6d6558; margin: 0; font-style: italic; }
main { max-width: 880px; margin: 1.5rem auto 2rem; padding: 0 1rem; }
.card {
  background: #fffdf8; border: 1px solid var(--line); border-radius: 10px;
  padding: 1.6rem; box-shadow: 0 2px 14px rgba(74, 14, 14, 0.06);
}
.progress { height: 6px; background: #eee5cf; border-radius: 3px; overflow: hidden; margin-bottom: 1.4rem; }
#progress-bar { height: 100%; background: var(--red); width: 0; transition: width 0.3s ease; }
.layout { display: flex; gap: 2rem; }
.step-pane { flex: 1 1 auto; min-width: 0; }
.step-pane h2 { color: var(--red); font-weight: 500; margin: 0 0 0.3rem; font-size: 1.35rem; }
.step-sub { color: #6d6558; margin: 0 0 1.1rem; }
.options { display: grid; grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); gap: 0.7rem; }
.opt {
  border: 1px solid var(--line); border-radius: 8px; background: #fff;
  padding: 0.85rem 0.7rem; cursor: pointer; text-align: center; font: inherit;
}
.opt small { display: block; color: #8a8172; margin-top: 0.25rem; font-size: 0.78rem; }
.opt.selected { border-color: var(--red); background: #faf3e0; box-shadow: inset 0 0 0 1px var(--red); }
.swatch { width: 26px; height: 26px; border-radius: 50%; margin: 0 auto 0.45rem; border: 1px solid #cbbf9f; }
.swatch.yellow_14, .swatch.yellow_18 { background: linear-gradient(135deg, #f3dd8f, #c9a227); }
.swatch.white_14, .swatch.white_18 { background: linear-gradient(135deg, #ffffff, #c9ccd4); }
.swatch.rose_14 { background: linear-gradient(135deg, #f6cdb4, #d99a76); }
.swatch.platinum { background: linear-gradient(135deg, #f4f4f6, #aeb2ba); }
.nav { display: flex; justify-content: space-between; margin-top: 1.5rem; }
.btn {
  font: inherit; border-radius: 6px; padding: 0.65rem 1.3rem; cursor: pointer;
  border: 1px solid var(--red); text-decoration: none; display: inline-block;
}
.btn.primary { background: var(--red); color: var(--beige); }
.btn.ghost { background: transparent; color: var(--red); }
.btn[disabled] { opacity: 0.45; cursor: default; }
.summary {
  flex: 0 0 210px; border-left: 1px solid var(--line); padding-left: 1.2rem;
}
.summary h3 { color: var(--red); font-weight: 500; margin-top: 0; font-size: 1rem; }
.summary ul { list-style: none; padding: 0; margin: 0; font-size: 0.9rem; }
.summary li { padding: 0.3rem 0; border-bottom: 1px dotted var(--line); }
.summary li span { color: #8a8172; display: block; font-size: 0.75rem; text-transform: uppercase; letter-spacing: 0.06em; }
.field { margin-bottom: 0.9rem; }
.field label { display: block; font-size: 0.9rem; margin-bottom: 0.3rem; color: var(--red); }
.field input, .field textarea, .field select {
  width: 100%; padding: 0.6rem; border: 1px solid var(--line); border-radius: 6px; font: inherit;
}
.field textarea { resize: vertical; }
.field .optional { color: #6d6558; font-size: 0.8rem; }
.field .hint { color: #6d6558; font-size: 0.8rem; margin-top: 0.3rem; }
.check { display: flex; gap: 0.5rem; align-items: flex-start; font-size: 0.85rem; color: #6d6558; }
.error { color: #a11; margin-top: 0.8rem; }
.center { text-align: center; }
.spinner {
  width: 44px; height: 44px; margin: 1rem auto; border-radius: 50%;
  border: 4px solid var(--beige); border-top-color: var(--red);
  animation: spin 0.9s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }
#result-img { max-width: 100%; width: 520px; border-radius: 10px; border: 1px solid var(--line); }
.angle-bar { display: flex; gap: 0.4rem; justify-content: center; margin-top: 0.8rem; }
.angle-btn { background: #fff; border: 1px solid var(--line); color: var(--ink); border-radius: 999px; padding: 0.4rem 1.1rem; font: inherit; font-size: 0.9rem; cursor: pointer; }
.angle-btn.active { background: var(--red); border-color: var(--red); color: var(--beige); }
.angle-hint { margin: 0.5rem 0 0; font-size: 0.85rem; }
.result-summary { color: var(--red); font-size: 1.1rem; }
.disclaimer { color: #8a8172; font-size: 0.85rem; max-width: 520px; margin: 0.8rem auto; }
.result-actions { display: flex; flex-wrap: wrap; gap: 0.6rem; justify-content: center; margin-top: 1rem; }
.note { color: #6d6558; font-size: 0.9rem; }
#result-brief { max-width: 640px; margin: 1rem auto 0; text-align: left; }
#result-brief summary { color: var(--red); cursor: pointer; text-align: center; }
.brief {
  font-size: 0.92rem; line-height: 1.55; background: #fff;
  border: 1px solid var(--line); border-radius: 8px; padding: 0.5rem 1.1rem 1rem;
}
.brief h4 { color: var(--red); margin: 0.9rem 0 0.3rem; font-size: 0.95rem; }
.brief p { margin: 0.2rem 0; }
.brief ul { margin: 0.2rem 0; padding-left: 1.2rem; }
.step-count { color: #6d6558; font-size: 0.85rem; margin: 0.4rem 0 0; }
.contact-note { color: #6d6558; margin: 0 0 0.8rem; }
.revision-box {
  max-width: 640px; margin: 1.25rem auto 0; padding: 1rem 1.1rem 1.1rem;
  background: #fff; border: 1px solid var(--line); border-radius: 8px;
  text-align: left;
}
.revision-box h3 { color: var(--red); margin: 0 0 0.35rem; font-size: 1.05rem; }
.revision-box p { margin: 0.25rem 0 0.75rem; color: #6d6558; }
.revision-box textarea {
  width: 100%; box-sizing: border-box; resize: vertical; min-height: 96px;
  border: 1px solid var(--line); border-radius: 8px; padding: 0.75rem;
  font: inherit; background: #fffdf8; color: var(--ink);
}
.revision-box .btn { margin-top: 0.75rem; }
footer { text-align: center; color: #8a8172; font-size: 0.85rem; padding-bottom: 2rem; }
@media (max-width: 680px) {
  .layout { flex-direction: column; }
  .summary { border-left: none; border-top: 1px solid var(--line); padding: 1rem 0 0; flex-basis: auto; }
}
