.category-group {
  display: grid;
  gap: 16px;
  margin-top: 26px;
  padding: 20px;
  scroll-margin-top: 86px;
  border: 1px solid rgba(156, 214, 255, .46);
  border-radius: 14px;
  background: linear-gradient(145deg, rgba(5, 31, 70, .72), rgba(7, 48, 88, .42));
  box-shadow: inset 0 1px rgba(255, 255, 255, .08), 0 8px 22px rgba(0, 0, 0, .18);
}

.category-header {
  display: flex;
  align-items: center;
  gap: 14px;
  padding-bottom: 15px;
  border-bottom: 1px solid rgba(166, 220, 255, .28);
}

.category-number {
  display: grid;
  width: 46px;
  height: 46px;
  flex: 0 0 46px;
  place-items: center;
  border: 1px solid rgba(160, 222, 255, .66);
  border-radius: 11px;
  color: #0b3864;
  background: linear-gradient(#c6efff, #71c7eb);
  box-shadow: 0 4px 0 #164b77;
  font-weight: 900;
}

.category-heading {
  margin: 0;
  color: #dff6ff;
  font-size: clamp(1.25rem, 3vw, 1.65rem);
  letter-spacing: .01em;
}

.category-header p {
  margin: 2px 0 0;
  color: #98c8e7;
  font-size: .82rem;
  font-weight: 700;
}

.category-ideas {
  display: grid;
  gap: 11px;
}

.category-nav {
  display: flex;
  gap: 7px;
  margin: 4px 0 20px;
  padding: 3px 0 6px;
  overflow-x: auto;
  scrollbar-width: thin;
}

.category-nav a {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  flex: 0 0 auto;
  padding: 8px 10px;
  border: 1px solid rgba(166, 220, 255, .4);
  border-radius: 8px;
  color: #d7efff;
  background: rgba(5, 34, 75, .6);
  font-size: .78rem;
  font-weight: 750;
  text-decoration: none;
}

.category-nav a:hover,
.category-nav a:focus-visible {
  border-color: #8ee1ff;
  background: rgba(31, 91, 145, .85);
}

.category-nav a span {
  min-width: 20px;
  padding: 1px 5px;
  border-radius: 99px;
  color: #123e6d;
  background: #bceaff;
  text-align: center;
  font-size: .7rem;
}

.idea.selected {
  border-color: #ffe074;
  background: rgba(100, 78, 18, .55);
  box-shadow: inset 0 0 0 1px rgba(255, 224, 116, .25);
}

.idea.selected .button {
  background: linear-gradient(#ffd95c, #d99a1c);
  box-shadow: 0 4px 0 #80540e;
}

.choice-control {
  display: inline-flex;
  min-width: 132px;
  align-self: center;
  align-items: center;
  justify-content: center;
  gap: 9px;
  padding: 10px 13px;
  border: 2px solid rgba(255,255,255,.5);
  border-radius: 9px;
  color: #fff;
  background: linear-gradient(#5fdf86,#238f4e);
  box-shadow: 0 4px 0 #145c31, inset 0 1px rgba(255,255,255,.5);
  font-weight: 800;
  cursor: pointer;
  user-select: none;
}

.choice-control.checked {
  background: linear-gradient(#ffd95c,#d99a1c);
  box-shadow: 0 4px 0 #80540e;
}

.choice-control:has(input:disabled) {
  cursor: not-allowed;
  filter: grayscale(.6);
  opacity: .48;
}

.choice-control input {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
}

.choice-box {
  display: grid;
  width: 21px;
  height: 21px;
  place-items: center;
  border: 2px solid rgba(255,255,255,.9);
  border-radius: 5px;
  background: rgba(2,31,58,.35);
}

.choice-control input:checked + .choice-box::after {
  content: "✓";
  color: #fff;
  font-size: 17px;
  font-weight: 950;
  line-height: 1;
}

.choice-control:has(input:focus-visible) {
  outline: 3px solid #ffe67a;
  outline-offset: 3px;
}

.vote-dialog {
  width: min(540px, calc(100% - 28px));
  padding: 0;
  border: 2px solid #9fd8ff;
  border-radius: 16px;
  color: #eff8ff;
  background: linear-gradient(145deg,#1d5391,#0a2652);
  box-shadow: 0 8px 0 #061f4b, 0 26px 70px rgba(0,0,0,.64);
}

.vote-dialog::backdrop {
  background: rgba(1,10,25,.76);
  backdrop-filter: blur(5px);
}

.vote-dialog-content {
  padding: clamp(24px,5vw,38px);
}

.vote-dialog h2 {
  margin: 0;
  font-size: clamp(1.7rem,5vw,2.4rem);
}

.vote-dialog-content > p:not(.eyebrow) {
  color: #c9e0f6;
}

.dialog-choices {
  display: grid;
  gap: 8px;
  margin: 20px 0;
  padding-left: 25px;
}

.dialog-choices li {
  padding: 9px 11px;
  border: 1px solid rgba(190,228,255,.38);
  border-radius: 8px;
  background: rgba(2,23,57,.42);
}

.dialog-actions {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  margin-top: 24px;
}

.dialog-secondary {
  border: 1px solid rgba(190,228,255,.55);
  border-radius: 9px;
  padding: 11px 15px;
  color: #d7edff;
  background: rgba(6,34,73,.62);
  font: 800 15px inherit;
  cursor: pointer;
}

.ballot-actions {
  position: sticky;
  z-index: 5;
  top: 12px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin: 0 0 18px;
  padding: 13px 15px;
  border: 1px solid rgba(190, 228, 255, .6);
  border-radius: 11px;
  background: rgba(4, 31, 70, .96);
  box-shadow: 0 5px 18px rgba(0, 0, 0, .34);
}

.ballot-actions[hidden] {
  display: none;
}

.ballot-counter {
  color: #d9efff;
  font-weight: 800;
}

.ballot-counter strong {
  color: #ffe074;
  font-size: 1.15rem;
}

@media (max-width: 560px) {
  .category-group {
    margin-top: 18px;
    padding: 14px;
  }

  .ballot-actions {
    top: 6px;
    align-items: stretch;
    flex-direction: column;
  }

  .choice-control {
    width: 100%;
  }

  .dialog-actions {
    align-items: stretch;
    flex-direction: column-reverse;
  }
}
