/* Production planner (js/neo-planner.js, 2026-11-14), under the budget guide: three rows of choices on the left, and a
   console on the right whose meter lights the tier they come to. */
.neo-planner {
  max-width: 1120px;
  margin: 56px auto 0;
  scroll-margin-top: 96px;
}
.neo-planner[hidden] { display: none; }
.neo-planner-head { margin-bottom: 24px; text-align: center; }
.neo-planner-live { display: none; }
.neo-planner-kicker { margin: 0 0 6px; color: #78f7e8; font: 600 .75rem/1.2 'Chakra Petch', sans-serif; letter-spacing: .26em; }
.neo-planner-head h3 { margin: 0; color: #fff; font-size: clamp(1.375rem, 3vw, 1.75rem); line-height: 1.4; }
.neo-planner-head p:last-child { margin: 8px 0 0; color: rgba(232, 240, 239, .76); font-size: 1rem; }

.neo-planner-body {
  display: grid;
  grid-template-columns: minmax(0, 7fr) minmax(0, 5fr);
  gap: 24px;
  align-items: stretch;
}
.neo-planner-form { display: grid; gap: 20px; margin: 0; }
.neo-planner-form fieldset { min-width: 0; margin: 0; padding: 0; border: 0; }
.neo-planner-form legend { display: flex; align-items: baseline; gap: 10px; margin-bottom: 10px; padding: 0; color: #fff; font-size: 1rem; font-weight: 700; }
.neo-planner-form legend b { color: #ffe27a; font: 600 .8125rem/1 'Chakra Petch', sans-serif; letter-spacing: .1em; }
.neo-planner-options { display: flex; flex-wrap: wrap; gap: 8px; }
.neo-planner-option { position: relative; display: inline-flex; cursor: pointer; }
.neo-planner-option input { position: absolute; inset: 0; margin: 0; opacity: 0; cursor: pointer; }
.neo-planner-option span {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  padding: 8px 16px;
  border: 1px solid rgba(120, 247, 232, .28);
  background: rgba(120, 247, 232, .03);
  color: rgba(232, 240, 239, .88);
  font-size: .9375rem;
  line-height: 1.3;
  clip-path: polygon(0 0, calc(100% - 8px) 0, 100% 8px, 100% 100%, 0 100%);
  transition: background-color .2s ease, border-color .2s ease, color .2s ease, box-shadow .2s ease;
}
.neo-planner-option:hover span { border-color: rgba(120, 247, 232, .7); background: rgba(120, 247, 232, .08); }
.neo-planner-option input:checked + span {
  border-color: #78f7e8;
  background: linear-gradient(100deg, rgba(120, 247, 232, .24), rgba(120, 247, 232, .08));
  color: #fff;
  font-weight: 700;
  box-shadow: inset 0 0 0 1px rgba(120, 247, 232, .35), 0 0 18px rgba(120, 247, 232, .18);
}
.neo-planner-option input:focus-visible + span { outline: 2px solid #ffe27a; outline-offset: 2px; }

/* The console with the result. */
.neo-planner-result {
  position: relative;
  display: flex;
  flex-direction: column;
  padding: 24px;
  overflow: hidden;
  border: 1px solid rgba(120, 247, 232, .4);
  background:
    linear-gradient(rgba(120, 247, 232, .035) 1px, transparent 1px) 0 0 / 100% 24px,
    linear-gradient(90deg, rgba(120, 247, 232, .035) 1px, transparent 1px) 0 0 / 24px 100%,
    radial-gradient(ellipse 80% 60% at 100% 0, rgba(255, 226, 122, .1), transparent 70%),
    #03080b;
  clip-path: polygon(0 0, calc(100% - 20px) 0, 100% 20px, 100% 100%, 0 100%);
}
.neo-planner-result::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 20px;
  height: 2px;
  background: linear-gradient(90deg, #78f7e8, #ffe27a 70%, transparent);
}
.neo-planner-label { margin: 0; color: #78f7e8; font: 600 .6875rem/1.2 'Chakra Petch', sans-serif; letter-spacing: .24em; }
.neo-planner-summary { margin: 6px 0 0; color: rgba(232, 240, 239, .7); font-size: .875rem; line-height: 1.5; }
.neo-planner-range {
  margin: 14px 0 0;
  color: #fff;
  font: 700 clamp(1.75rem, 4vw, 2.25rem)/1.2 'Chakra Petch', 'Noto Sans JP', sans-serif;
  letter-spacing: .02em;
  text-shadow: 0 0 18px rgba(120, 247, 232, .35);
}
.neo-planner-tier { margin: 4px 0 0; color: #ffe27a; font-size: 1rem; font-weight: 700; }

/* Three segments for the three tiers; the lit one glows and a marker sits under it. */
.neo-planner-meter { position: relative; display: grid; grid-template-columns: repeat(3, 1fr); gap: 4px; margin: 20px 0 0; padding-bottom: 12px; }
.neo-planner-meter span { height: 10px; border: 1px solid rgba(120, 247, 232, .25); background: rgba(120, 247, 232, .05); transition: background .35s ease, box-shadow .35s ease, border-color .35s ease; }
.neo-planner-meter[data-tier="0"] span:nth-child(1),
.neo-planner-meter[data-tier="1"] span:nth-child(2),
.neo-planner-meter[data-tier="2"] span:nth-child(3) {
  border-color: #78f7e8;
  background: linear-gradient(90deg, #78f7e8, #ffe27a);
  box-shadow: 0 0 16px rgba(120, 247, 232, .55);
}
.neo-planner-meter i {
  position: absolute;
  bottom: 0;
  left: calc(100% / 6);
  width: 0;
  height: 0;
  border: 6px solid transparent;
  border-bottom-color: #ffe27a;
  border-top: 0;
  transform: translateX(-50%);
  transition: left .45s cubic-bezier(.2, .7, .2, 1);
}
.neo-planner-meter[data-tier="1"] i { left: 50%; }
.neo-planner-meter[data-tier="2"] i { left: calc(100% * 5 / 6); }
.neo-planner-scale { display: grid; grid-template-columns: repeat(3, 1fr); gap: 4px; margin-top: 6px; color: rgba(232, 240, 239, .6); font: 600 .75rem/1.2 'Chakra Petch', 'Noto Sans JP', sans-serif; text-align: center; }
.neo-planner-why { margin: 16px 0 0; color: rgba(244, 251, 250, .9); font-size: .9375rem; line-height: 1.7; }
.neo-planner-note { margin: 10px 0 0; color: rgba(232, 240, 239, .6); font-size: .8125rem; line-height: 1.6; }
.neo-planner-go { align-self: stretch; justify-content: center; margin-top: auto; min-height: 52px; }
.neo-planner-note + .neo-planner-go { margin-top: 20px; }

/* When the tier changes, the figures flicker in. */
html[data-motion="on"] .neo-planner.is-shift .neo-planner-range,
html[data-motion="on"] .neo-planner.is-shift .neo-planner-tier { animation: neo-planner-flicker .5s steps(1, end) both; }
@keyframes neo-planner-flicker { 0% { opacity: 0; } 20% { opacity: 1; } 35% { opacity: .2; } 50%, 100% { opacity: 1; } }
html:not([data-motion="on"]) .neo-planner-meter span, html:not([data-motion="on"]) .neo-planner-meter i { transition: none; }

/* The budget guide's card for the same tier lights with the meter. */
#budget .budget-card.is-plan-match { border-color: #78f7e8; box-shadow: 0 0 0 1px rgba(120, 247, 232, .45), 0 0 26px rgba(120, 247, 232, .18); }

@media (max-width: 860px) {
  .neo-planner { margin-top: 40px; }
  .neo-planner-live {
    position: sticky;
    top: 76px;
    z-index: 2;
    display: flex;
    align-items: center;
    gap: 10px;
    margin: 0 0 16px;
    padding: 10px 14px;
    border: 1px solid rgba(120, 247, 232, .4);
    border-left: 2px solid #78f7e8;
    background: rgba(3, 8, 11, .94);
    box-shadow: 0 8px 20px rgba(0, 0, 0, .45);
  }
  .neo-planner-live span { color: #78f7e8; font: 600 .6875rem/1 'Chakra Petch', sans-serif; letter-spacing: .2em; }
  .neo-planner-live b { color: #fff; font-size: .9375rem; }
  .neo-planner-body { grid-template-columns: minmax(0, 1fr); }
  .neo-planner-result { padding: 20px; }
}
@media (prefers-reduced-motion: reduce) {
  .neo-planner *, .neo-planner { animation: none !important; transition: none !important; }
}
