:root {
  --bg: #070304;
  --crimson: #e11d3c;
  --crimson-deep: #8f0f26;
  --ember: #ff5a3c;
  --ink: #f5ecec;
  --muted: #c9a9ad;
  --glass: rgba(255, 255, 255, 0.05);
  --glass-border: rgba(255, 120, 130, 0.22);
  --radius: 18px;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  min-height: 100vh;
  font-family: "Segoe UI", system-ui, -apple-system, "Helvetica Neue", Arial, sans-serif;
  color: var(--ink);
  background:
    radial-gradient(1100px 500px at 85% -10%, rgba(225, 29, 60, 0.28), transparent 60%),
    radial-gradient(900px 600px at -10% 30%, rgba(143, 15, 38, 0.22), transparent 55%),
    linear-gradient(180deg, #0d0205 0%, var(--bg) 45%, #050102 100%);
  padding: 0 1rem 3rem;
}

.sky { position: fixed; inset: 0; pointer-events: none; overflow: hidden; z-index: 0; }
.moon {
  position: absolute; top: 3.5rem; right: 6%;
  width: 84px; height: 84px; border-radius: 50%;
  background: radial-gradient(circle at 35% 35%, #fff5f0, #e8b4ac 55%, #b06a63);
  box-shadow: 0 0 60px 18px rgba(255, 90, 60, 0.25);
  opacity: 0.9;
}
.bat { position: absolute; fill: #1a050a; opacity: 0.85; }
.bat-a { width: 150px; top: 2.2rem; right: 16%; transform: rotate(-6deg); }
.bat-b { width: 90px; top: 6.5rem; right: 9%; transform: rotate(5deg); opacity: 0.7; }
.bat-c { width: 60px; top: 1.4rem; left: 5%; transform: rotate(3deg); opacity: 0.55; }

.hero, main, footer { position: relative; z-index: 1; max-width: 880px; margin: 0 auto; }

.hero { text-align: center; padding: 4.5rem 0 1.5rem; }
.eyebrow { letter-spacing: 0.35em; font-size: 0.72rem; color: var(--muted); margin: 0 0 0.6rem; }
.hero h1 {
  margin: 0; font-size: clamp(3rem, 10vw, 5.2rem); font-weight: 800; letter-spacing: -0.03em;
  text-transform: lowercase;
}
.hero h1 span { color: var(--crimson); text-shadow: 0 0 28px rgba(225, 29, 60, 0.55); }
.tagline { color: var(--muted); max-width: 560px; margin: 0.8rem auto 0; line-height: 1.55; }

.glass {
  background: var(--glass);
  border: 1px solid var(--glass-border);
  border-radius: var(--radius);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  box-shadow: 0 18px 40px rgba(0, 0, 0, 0.45);
}

.notice { padding: 1rem 1.3rem; margin: 1.5rem 0; border-left: 4px solid var(--crimson); }
.notice h2 { margin: 0 0 0.4rem; font-size: 1rem; color: #ffb3ba; }
.notice p { margin: 0; line-height: 1.55; color: #ecd9db; }

.panel { padding: 1.4rem; margin-bottom: 1.5rem; }
.panel h2, .plan-head h2 { margin-top: 0; }

.field { display: block; margin-bottom: 1rem; }
.field span { display: block; font-size: 0.85rem; color: var(--muted); margin-bottom: 0.4rem; letter-spacing: 0.04em; }
.field input {
  width: 100%; padding: 0.85rem 1rem; border-radius: 12px;
  border: 1px solid var(--glass-border); background: rgba(0, 0, 0, 0.45);
  color: var(--ink); font-size: 1.05rem; outline: none;
}
.field input:focus { border-color: var(--crimson); box-shadow: 0 0 0 3px rgba(225, 29, 60, 0.25); }
.error { color: #ff8f9d; margin: -0.4rem 0 1rem; }

.profiles { border: 0; padding: 0; margin: 0 0 1.2rem; display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 0.7rem; }
.profiles legend { font-size: 0.85rem; color: var(--muted); margin-bottom: 0.5rem; letter-spacing: 0.04em; }
.profile-card {
  display: block; padding: 0.9rem 1rem; border-radius: 14px; cursor: pointer;
  border: 1px solid var(--glass-border); background: rgba(0, 0, 0, 0.35);
  transition: border-color 0.15s ease, background 0.15s ease;
}
.profile-card strong { display: block; margin-bottom: 0.25rem; }
.profile-card span { color: var(--muted); font-size: 0.88rem; line-height: 1.4; }
.profile-card input { accent-color: var(--crimson); margin-bottom: 0.5rem; }
.profile-card:has(input:checked) { border-color: var(--crimson); background: rgba(225, 29, 60, 0.12); }

button {
  font: inherit; cursor: pointer; border-radius: 999px; padding: 0.65rem 1.15rem;
  border: 1px solid var(--glass-border); background: rgba(255, 255, 255, 0.06); color: var(--ink);
}
button:hover { border-color: var(--crimson); }
button.primary {
  background: linear-gradient(135deg, var(--crimson), var(--crimson-deep));
  border: 0; font-weight: 700; padding: 0.8rem 1.6rem;
  box-shadow: 0 10px 26px rgba(225, 29, 60, 0.35);
}
button.danger { color: #ff9aa6; }
.status { color: #ffc2c9; margin-top: 0.9rem; }
.muted { color: var(--muted); }

.plan-head { padding: 1.3rem 1.4rem; margin-bottom: 1.2rem; }
.actions { display: flex; flex-wrap: wrap; gap: 0.5rem; margin: 0.8rem 0 1rem; }

.track { height: 8px; border-radius: 999px; background: rgba(255, 255, 255, 0.1); overflow: hidden; margin: 0.6rem 0 1rem; }
.track.big { height: 12px; }
.fill {
  height: 100%; width: 0%;
  background: linear-gradient(90deg, var(--crimson-deep), var(--crimson), var(--ember));
  transition: width 0.3s ease;
}

.phase { padding: 1.2rem 1.3rem; margin-bottom: 1.1rem; }
.phase-head { display: flex; justify-content: space-between; align-items: baseline; gap: 1rem; }
.phase-head h3 { margin: 0; font-size: 1.12rem; }
.phase-count { color: var(--muted); font-variant-numeric: tabular-nums; }
.phase-desc { color: var(--muted); margin: 0.35rem 0 0; line-height: 1.5; }

.items { list-style: none; padding: 0; margin: 0.4rem 0 0.8rem; }
.item { border-top: 1px solid rgba(255, 255, 255, 0.07); }
.item label { display: flex; gap: 0.8rem; padding: 0.75rem 0.2rem; cursor: pointer; align-items: flex-start; }
.item input[type="checkbox"] { width: 1.15rem; height: 1.15rem; margin-top: 0.2rem; accent-color: var(--crimson); flex: none; }
.item-body { display: flex; flex-wrap: wrap; gap: 0.35rem 0.6rem; align-items: baseline; }
.item-desc { flex-basis: 100%; color: #e6d2d5; line-height: 1.45; }
.item-tool { flex-basis: 100%; color: var(--muted); font-size: 0.85rem; }
.item-tool::before { content: "Tool / technique: "; color: #a97f85; }
.item:has(input:checked) .item-desc, .item:has(input:checked) strong { opacity: 0.55; text-decoration: line-through; }

.sev {
  font-size: 0.68rem; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase;
  padding: 0.14rem 0.5rem; border-radius: 999px; border: 1px solid;
}
.sev-info { color: #b9c7d6; border-color: rgba(185, 199, 214, 0.4); }
.sev-low { color: #a8d8b9; border-color: rgba(168, 216, 185, 0.4); }
.sev-medium { color: #ffd28a; border-color: rgba(255, 210, 138, 0.45); }
.sev-high { color: #ffab7a; border-color: rgba(255, 171, 122, 0.5); }
.sev-critical { color: #ff8f9d; border-color: rgba(255, 143, 157, 0.6); background: rgba(225, 29, 60, 0.14); }

.notes {
  width: 100%; min-height: 3.2rem; resize: vertical; border-radius: 12px;
  border: 1px solid var(--glass-border); background: rgba(0, 0, 0, 0.4);
  color: var(--ink); padding: 0.7rem 0.9rem; font: inherit;
}
.notes:focus { outline: none; border-color: var(--crimson); }

footer { text-align: center; color: var(--muted); font-size: 0.88rem; padding-top: 1rem; line-height: 1.5; }

@media print {
  body { background: #fff; color: #111; }
  .sky, .hero .eyebrow, .panel:not(#plan-panel), .actions, footer, .notes { display: none !important; }
  .glass { background: #fff; border-color: #ccc; box-shadow: none; backdrop-filter: none; }
  .item-desc, .phase-desc, .item-tool, .muted { color: #333; }
  .hero h1 span { color: #8f0f26; text-shadow: none; }
  .tagline { color: #444; }
}
