:root {
  --blue: #0b5ea7;
  --blue-deep: #084b86;
  --ink: #12304d;
  --panel: rgba(255, 255, 255, 0.82);
  --panel-strong: rgba(255, 255, 255, 0.92);
  --line: rgba(11, 94, 167, 0.16);
  --shadow: 0 20px 60px rgba(8, 75, 134, 0.16);
  --danger: #a83a4d;
}

* { box-sizing: border-box; }
html, body { min-height: 100%; }
body {
  margin: 0;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: var(--ink);
  background: linear-gradient(130deg, #e9f5ff 0%, #ffffff 42%, #d9ecff 100%);
  overflow-x: hidden;
}

.bg {
  position: fixed;
  inset: auto auto 0 auto;
  width: 120vw;
  height: 42vh;
  border-radius: 50%;
  filter: blur(24px);
  opacity: .42;
  pointer-events: none;
  animation: drift 16s ease-in-out infinite alternate;
}
.bg-one {
  left: -8vw;
  bottom: -10vh;
  background: radial-gradient(circle at 30% 30%, rgba(11, 94, 167, .35), rgba(11, 94, 167, 0));
}
.bg-two {
  right: -18vw;
  bottom: -16vh;
  background: radial-gradient(circle at 40% 40%, rgba(71, 150, 219, .28), rgba(71, 150, 219, 0));
  animation-duration: 22s;
}
.bg-three {
  left: 18vw;
  bottom: -20vh;
  background: radial-gradient(circle at 50% 35%, rgba(255, 255, 255, .9), rgba(255, 255, 255, 0));
  animation-duration: 28s;
}

@keyframes drift {
  0% { transform: translate3d(-2%, 0, 0) scaleX(1); }
  50% { transform: translate3d(3%, -2%, 0) scaleX(1.08); }
  100% { transform: translate3d(-1%, 2%, 0) scaleX(.96); }
}

.shell {
  position: relative;
  z-index: 1;
  width: min(1120px, calc(100% - 32px));
  margin: 28px auto 48px;
}

.grid { display: grid; gap: 18px; }
.two-up { grid-template-columns: 1fr 1fr; }
.admin-grid { grid-template-columns: 1.15fr .85fr; }
.full-width { grid-column: 1 / -1; }

.card {
  background: var(--panel);
  backdrop-filter: blur(14px);
  border: 1px solid var(--line);
  border-radius: 24px;
  box-shadow: var(--shadow);
  padding: 24px;
}

.hero {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 18px;
  background: linear-gradient(135deg, rgba(255,255,255,.9), rgba(233,245,255,.84));
}

.brand {
  display: flex;
  align-items: center;
  gap: 18px;
}

.brand-logo {
  width: 88px;
  height: 88px;
  object-fit: contain;
  border-radius: 22px;
  background: rgba(255,255,255,.85);
  padding: 10px;
  box-shadow: inset 0 0 0 1px rgba(11, 94, 167, 0.08);
}

.eyebrow {
  margin: 0 0 6px;
  color: var(--blue);
  font-weight: 700;
  letter-spacing: .08em;
  text-transform: uppercase;
  font-size: .78rem;
}

h1, h2, h3, p, ul, ol { margin-top: 0; }
h1 { margin-bottom: 10px; font-size: clamp(2rem, 4vw, 3.2rem); line-height: 1.04; }
h2 { margin-bottom: 14px; font-size: 1.2rem; }
h3 { margin-bottom: 10px; font-size: 1rem; }

.intro, .muted { color: rgba(18, 48, 77, .74); }
.steps { margin: 0; padding-left: 18px; line-height: 1.8; }
.stack { display: flex; flex-direction: column; gap: 14px; }
.small-gap { gap: 8px; }
.hidden { display: none !important; }

label span {
  display: block;
  margin-bottom: 6px;
  font-weight: 600;
}

input, textarea, button {
  font: inherit;
}

input, textarea {
  width: 100%;
  border: 1px solid rgba(11, 94, 167, 0.16);
  background: rgba(255,255,255,.9);
  color: var(--ink);
  border-radius: 16px;
  padding: 14px 16px;
  outline: none;
  transition: border-color .2s, box-shadow .2s;
}
input:focus, textarea:focus {
  border-color: rgba(11, 94, 167, .45);
  box-shadow: 0 0 0 4px rgba(11, 94, 167, .09);
}
textarea { resize: vertical; min-height: 120px; }

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border: 0;
  border-radius: 999px;
  padding: 13px 18px;
  text-decoration: none;
  background: linear-gradient(135deg, var(--blue) 0%, var(--blue-deep) 100%);
  color: #fff;
  cursor: pointer;
  box-shadow: 0 14px 30px rgba(8, 75, 134, .18);
}
.button:hover { transform: translateY(-1px); }
.button:disabled { opacity: .5; cursor: not-allowed; transform: none; }
.button-secondary {
  background: rgba(255,255,255,.75);
  color: var(--blue-deep);
  border: 1px solid rgba(11, 94, 167, .18);
  box-shadow: none;
}
.button-danger {
  background: linear-gradient(135deg, var(--danger), #8d2740);
}

.inline-actions, .spread, .hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: center;
}
.spread { justify-content: space-between; }

.stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
}
.stat, .mini-card {
  border-radius: 18px;
  padding: 16px;
  background: var(--panel-strong);
  border: 1px solid rgba(11, 94, 167, 0.1);
}
.stat strong, .mini-card strong { display: block; font-size: 1.6rem; color: var(--blue-deep); }
.stat span, .mini-card span { color: rgba(18, 48, 77, .72); font-size: .92rem; }
.info-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}

.result-row {
  display: grid;
  gap: 8px;
}
.result-top {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  font-weight: 600;
}
.progress {
  height: 12px;
  border-radius: 999px;
  background: rgba(11, 94, 167, .08);
  overflow: hidden;
}
.progress > span {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, var(--blue), #7eb6e8);
}

.vote-options {
  display: grid;
  gap: 12px;
}
.vote-option {
  border: 1px solid rgba(11, 94, 167, .14);
  background: rgba(255,255,255,.86);
  border-radius: 18px;
  padding: 15px 16px;
  display: flex;
  gap: 12px;
  align-items: center;
}
.vote-option input { width: 18px; height: 18px; margin: 0; }
.notice {
  border-radius: 16px;
  padding: 14px 16px;
  background: rgba(11, 94, 167, .08);
  color: var(--blue-deep);
}
.notice.error {
  background: rgba(168, 58, 77, .12);
  color: #7e2036;
}
.policy-list {
  margin: 0;
  padding-left: 20px;
  line-height: 1.7;
}

@media (max-width: 860px) {
  .two-up, .admin-grid, .info-grid { grid-template-columns: 1fr; }
  .hero, .brand { flex-direction: column; align-items: flex-start; }
  .stats { grid-template-columns: 1fr; }
  .shell { width: min(100% - 20px, 1120px); }
  .card { padding: 18px; border-radius: 20px; }
  h1 { font-size: 2rem; }
}
