/* ============================================
   WARD 4 POLL — campaign poll (index.html)
   Navy panel, red accents, light question cards.
   Mobile-first. Respects prefers-reduced-motion.
   ============================================ */

/* ---- Election bar: second CTA (stack under voting CTA) ---- */
.election-action {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: 10px;
  min-width: 260px;
}
.election-poll-support {
  font-size: 0.82rem;
  color: rgba(255,255,255,0.66);
  margin: 0;
  line-height: 1.45;
  text-align: center;
}
@media (max-width: 768px) {
  .election-action { min-width: 0; }
}

/* ---- Poll section ---- */
.poll-section {
  background: var(--navy);
  color: var(--white);
  padding: var(--section-padding) 0;
  scroll-margin-top: 92px;
}
.poll-panel {
  background: linear-gradient(180deg, rgba(255,255,255,0.04), rgba(255,255,255,0.01));
  border: 1px solid rgba(255,255,255,0.10);
  border-top: 4px solid var(--red);
  border-radius: 14px;
  padding: clamp(28px, 5vw, 56px);
}

/* ---- Teaser ---- */
.poll-teaser { text-align: center; max-width: 640px; margin: 0 auto; }
.poll-eyebrow {
  display: inline-block;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--red);
  margin-bottom: 16px;
}
.poll-teaser h2 {
  font-size: clamp(1.9rem, 4vw, 2.6rem);
  font-weight: 800;
  letter-spacing: -0.02em;
  color: var(--white);
  margin: 0 0 16px;
}
.poll-teaser-copy {
  font-size: 1.08rem;
  line-height: 1.65;
  color: rgba(255,255,255,0.82);
  margin: 0 auto 26px;
  max-width: 560px;
}
.poll-cta {
  background: var(--red);
  color: var(--white);
  border-color: var(--red);
  font-size: 1.05rem;
  padding: 15px 34px;
}
.poll-cta:hover { background: var(--red-hover); border-color: var(--red-hover); color: var(--white); }
.poll-teaser-meta {
  font-size: 0.88rem;
  color: rgba(255,255,255,0.72);
  margin: 16px 0 6px;
}
.poll-teaser-privacy {
  font-size: 0.78rem;
  color: rgba(255,255,255,0.5);
  margin: 0;
  line-height: 1.5;
}

/* ---- Interactive app ---- */
.poll-app { max-width: 680px; margin: 0 auto; }

.poll-progress-top {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  margin-bottom: 10px;
}
.poll-count {
  font-size: 0.82rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.7);
}
.poll-step-label {
  font-size: 0.8rem;
  color: rgba(255,255,255,0.55);
}
.poll-progress-bar {
  height: 6px;
  background: rgba(255,255,255,0.12);
  border-radius: 3px;
  overflow: hidden;
  margin-bottom: 28px;
}
.poll-progress-fill {
  height: 100%;
  background: var(--red);
  border-radius: 3px;
  transition: width 0.4s ease;
  width: 0;
}

.poll-question-title {
  font-size: clamp(1.35rem, 3vw, 1.75rem);
  font-weight: 700;
  line-height: 1.3;
  color: var(--white);
  margin: 0 0 22px;
}

.poll-answers { display: grid; gap: 10px; margin: 0; padding: 0; border: 0; }
.poll-answer { position: relative; }
.poll-answer input {
  position: absolute;
  width: 1px; height: 1px;
  margin: -1px; padding: 0;
  overflow: hidden;
  clip: rect(0,0,0,0);
  white-space: nowrap;
  border: 0;
}
.poll-answer label {
  display: block;
  background: rgba(255,255,255,0.05);
  border: 1.5px solid rgba(255,255,255,0.16);
  border-radius: 10px;
  padding: 15px 18px;
  font-size: 1.02rem;
  line-height: 1.4;
  color: var(--white);
  cursor: pointer;
  transition: border-color 0.15s ease, background 0.15s ease;
}
.poll-answer label:hover { border-color: rgba(255,255,255,0.4); }
.poll-answer input:checked + label {
  background: rgba(192,57,43,0.18);
  border-color: var(--red);
  font-weight: 600;
}
.poll-answer input:focus-visible + label {
  outline: 2px solid var(--white);
  outline-offset: 2px;
}

/* Other free-text reveal */
.poll-other {
  margin-top: 10px;
}
.poll-other input,
.poll-free textarea {
  width: 100%;
  box-sizing: border-box;
  background: rgba(255,255,255,0.07);
  border: 1.5px solid rgba(255,255,255,0.2);
  border-radius: 10px;
  color: var(--white);
  font-family: inherit;
  font-size: 1rem;
  padding: 13px 15px;
  outline: none;
}
.poll-other input:focus,
.poll-free textarea:focus {
  border-color: var(--red);
  background: rgba(255,255,255,0.1);
}
.poll-free textarea {
  min-height: 130px;
  resize: vertical;
  line-height: 1.55;
}
.poll-free .poll-hint {
  display: flex;
  justify-content: space-between;
  font-size: 0.78rem;
  color: rgba(255,255,255,0.5);
  margin-top: 8px;
}

/* Nav controls */
.poll-nav {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: 26px;
}
.poll-nav .btn { flex: 0 0 auto; }
.btn-poll-back {
  background: transparent;
  color: var(--white);
  border-color: rgba(255,255,255,0.3);
}
.btn-poll-back:hover { background: rgba(255,255,255,0.12); border-color: rgba(255,255,255,0.5); color: var(--white); }
.btn-poll-next {
  background: var(--red);
  color: var(--white);
  border-color: var(--red);
  margin-left: auto;
}
.btn-poll-next:hover { background: var(--red-hover); border-color: var(--red-hover); color: var(--white); }
.btn-poll-next:disabled,
.btn-poll-back:disabled {
  opacity: 0.4;
  cursor: not-allowed;
}

/* Submission screen */
.poll-submit-head {
  text-align: center;
  margin-bottom: 22px;
}
.poll-submit-head h3 {
  font-size: 1.6rem;
  font-weight: 800;
  color: var(--white);
  margin: 0 0 10px;
}
.poll-submit-head p {
  font-size: 1rem;
  color: rgba(255,255,255,0.8);
  line-height: 1.6;
  max-width: 480px;
  margin: 0 auto;
}
.poll-email-field {
  max-width: 460px;
  margin: 0 auto;
}
.poll-email-field label {
  display: block;
  font-size: 0.95rem;
  font-weight: 600;
  margin-bottom: 8px;
  color: var(--white);
}
.poll-email-field input[type="email"] {
  width: 100%;
  box-sizing: border-box;
  background: rgba(255,255,255,0.07);
  border: 1.5px solid rgba(255,255,255,0.2);
  border-radius: 10px;
  color: var(--white);
  font-family: inherit;
  font-size: 1rem;
  padding: 14px 16px;
  outline: none;
}
.poll-email-field input[type="email"]:focus { border-color: var(--red); }
.poll-consent {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  margin: 16px 0 6px;
  font-size: 0.95rem;
  color: rgba(255,255,255,0.85);
  cursor: pointer;
}
.poll-consent input {
  width: 18px; height: 18px;
  margin-top: 2px;
  accent-color: var(--red);
  flex: 0 0 auto;
}
.poll-consent input:focus-visible { outline: 2px solid var(--white); outline-offset: 2px; }
.poll-privacy-note {
  font-size: 0.78rem;
  color: rgba(255,255,255,0.5);
  margin: 8px 0 22px;
  line-height: 1.5;
}
.poll-submit-actions { text-align: center; }
.btn-poll-submit {
  background: var(--red);
  color: var(--white);
  border-color: var(--red);
  font-size: 1.05rem;
  padding: 15px 40px;
}
.btn-poll-submit:hover { background: var(--red-hover); border-color: var(--red-hover); color: var(--white); }
.btn-poll-submit:disabled { opacity: 0.6; cursor: not-allowed; }

/* Error / retry */
.poll-error {
  text-align: center;
  background: rgba(192,57,43,0.14);
  border: 1px solid rgba(192,57,43,0.4);
  border-radius: 10px;
  padding: 18px 20px;
  margin-bottom: 18px;
  font-size: 0.95rem;
  color: #ffd6d1;
}

/* Thank-you / results */
.poll-thanks { text-align: center; }
.poll-thanks h3 {
  font-size: 1.7rem;
  font-weight: 800;
  color: var(--white);
  margin: 0 0 12px;
}
.poll-thanks p { font-size: 1rem; color: rgba(255,255,255,0.82); line-height: 1.6; }
.poll-results {
  margin: 30px auto 0;
  max-width: 560px;
  text-align: left;
}
.poll-results h4 {
  font-size: 1.05rem;
  color: var(--white);
  margin: 0 0 6px;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}
.poll-results .poll-results-note {
  font-size: 0.8rem;
  color: rgba(255,255,255,0.55);
  margin: 0 0 16px;
}
.poll-result-item {
  border: 1px solid rgba(255,255,255,0.12);
  border-radius: 10px;
  padding: 14px 16px;
  margin-bottom: 10px;
}
.poll-result-item .r-top {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  font-size: 0.92rem;
  margin-bottom: 8px;
}
.poll-result-item .r-label { color: rgba(255,255,255,0.88); }
.poll-result-item .r-pct { color: var(--red); font-weight: 700; white-space: nowrap; }
.poll-result-item .r-bar {
  height: 7px;
  background: rgba(255,255,255,0.12);
  border-radius: 4px;
  overflow: hidden;
}
.poll-result-item .r-bar span { display: block; height: 100%; background: var(--red); border-radius: 4px; }
.poll-next-steps {
  margin: 30px 0 0;
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  justify-content: center;
}
.poll-next-steps .btn { font-size: 0.95rem; }

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
  .poll-progress-fill { transition: none; }
  .poll-answer label { transition: none; }
}
