:root {
  --bg: #0f172a;
  --card: #1e293b;
  --accent: #6366f1;
  --accent2: #8b5cf6;
  --text: #f1f5f9;
  --muted: #94a3b8;
  --success: #22c55e;
  --warning: #f59e0b;
  --border: #334155;
}
* { box-sizing: border-box; }
body {
  margin: 0;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Hiragino Sans", "Noto Sans JP", sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.5;
  padding: 16px;
}
.container { max-width: 480px; margin: 0 auto; }
h1 { font-size: 1.6rem; text-align: center; margin: 8px 0 4px; }
.subtitle { text-align: center; color: var(--muted); font-size: 0.9rem; margin-bottom: 20px; }
.card {
  background: var(--card);
  border-radius: 16px;
  padding: 16px;
  margin-bottom: 16px;
  border: 1px solid var(--border);
}
.card h2 { font-size: 1.1rem; margin: 0 0 12px; color: #c4b5fd; }
label { display: block; font-size: 0.85rem; color: var(--muted); margin-bottom: 4px; }
input, select {
  width: 100%;
  padding: 12px;
  border-radius: 10px;
  border: 1px solid var(--border);
  background: #0f172a;
  color: var(--text);
  font-size: 1rem;
  margin-bottom: 12px;
}
.row { display: flex; gap: 8px; }
.row > div { flex: 1; }
button {
  width: 100%;
  padding: 16px;
  background: linear-gradient(135deg, var(--accent), var(--accent2));
  color: white;
  border: none;
  border-radius: 12px;
  font-size: 1.1rem;
  font-weight: bold;
  cursor: pointer;
  margin: 8px 0 20px;
}
button:active { transform: scale(0.98); }
.result-item {
  background: #0f172a;
  border-radius: 12px;
  padding: 12px;
  margin-bottom: 12px;
  border-left: 4px solid var(--accent);
}
.result-item.best { border-left-color: var(--success); }
.result-title { font-weight: bold; margin-bottom: 8px; font-size: 1.05rem; }
.scenario { margin: 8px 0; padding: 8px; background: #1e293b; border-radius: 8px; }
.scenario-title { font-size: 0.85rem; color: #c4b5fd; margin-bottom: 4px; }
.points { color: #a5b4fc; }
.time { color: #fbbf24; font-weight: bold; }
.days { color: #34d399; font-weight: bold; }
.small { font-size: 0.8rem; color: var(--muted); }
.remain { font-size: 1.3rem; text-align: center; margin: 8px 0; color: #fbbf24; }
footer { text-align: center; color: var(--muted); font-size: 0.75rem; margin-top: 20px; }
.optional { font-size: 0.75rem; color: var(--muted); }
.error {
  color: #f87171;
  font-size: 0.8rem;
  margin: -8px 0 12px;
  display: none;
}
.field-error {
  color: #f87171;
  font-size: 0.75rem;
  margin: -8px 0 8px;
  display: none;
  line-height: 1.3;
}
input.invalid {
  border-color: #f87171;
}
.required-mark {
  color: #f87171;
  font-weight: bold;
  margin-left: 2px;
}
.note {
  text-align: center;
  font-size: 0.8rem;
  color: var(--muted);
  margin-bottom: 16px;
}