/* Ward 4 Community Survey — Styles
   Matches Dave Thompson campaign branding
   Colors: --navy #1a1a2e, --red #c0392b, --light-grey #f4f4f6
*/

/* Container */
#ward4-survey-app {
  font-family: inherit;
  max-width: 680px;
  margin: 0 auto;
  min-height: 480px;
  position: relative;
}

/* Intro Screen */
.sv-intro {
  text-align: center;
  padding: 40px 20px;
  animation: svFadeIn 0.4s ease;
}
.sv-intro-icon { font-size: 3rem; margin-bottom: 16px; }
.sv-intro-title {
  font-size: 2rem; font-weight: 800; color: #1a1a2e;
  margin: 0 0 16px; line-height: 1.2;
}
.sv-intro-text {
  font-size: 1.05rem; color: #555566; line-height: 1.6;
  margin: 0 0 12px; max-width: 500px; margin-left: auto; margin-right: auto;
}
.sv-intro-note {
  font-size: 0.8rem; color: #888899; margin-top: 20px;
}

/* Question Screen */
.sv-question-screen {
  padding: 0 4px;
  animation: svSlideIn 0.3s ease;
}
.sv-progress-wrap {
  display: flex; align-items: center; gap: 12px;
  margin-bottom: 28px;
}
.sv-progress-bar {
  flex: 1; height: 8px; background: #e0e0e5;
  border-radius: 4px; overflow: hidden;
}
.sv-progress-fill {
  height: 100%; background: linear-gradient(90deg, #c0392b, #e74c3c);
  border-radius: 4px; transition: width 0.5s ease;
}
.sv-progress-label {
  font-size: 0.78rem; font-weight: 600; color: #888899;
  white-space: nowrap;
}

/* Question Header */
.sv-q-header {
  display: flex; align-items: flex-start; gap: 14px;
  margin-bottom: 24px;
}
.sv-q-icon {
  font-size: 1.8rem; line-height: 1;
  flex-shrink: 0; margin-top: 2px;
}
.sv-q-heading {
  font-size: 1.35rem; font-weight: 700; color: #1a1a2e;
  line-height: 1.3; margin: 0;
}

.sv-q-subtitle {
  font-size: 0.9rem; color: #888899; margin: -16px 0 20px;
  padding-left: 46px;
}

/* Options */
.sv-options {
  display: flex; flex-direction: column; gap: 10px;
}

.sv-option {
  display: flex; align-items: center; justify-content: space-between;
  padding: 16px 20px;
  background: #fff;
  border: 2px solid #e0e0e5;
  border-radius: 12px;
  cursor: pointer;
  font-family: inherit; font-size: 1rem; font-weight: 600;
  color: #1a1a2e;
  transition: all 0.2s ease;
  text-align: left;
  width: 100%;
  min-height: 56px;
}
.sv-option:hover:not(.disabled) {
  border-color: #1a1a2e;
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(0,0,0,0.06);
}
.sv-option.selected {
  border-color: #c0392b;
  background: #fdf6f5;
  color: #c0392b;
}
.sv-option.disabled {
  opacity: 0.45; cursor: not-allowed;
}
.sv-option-text { flex: 1; }
.sv-option-check {
  width: 24px; height: 24px; border-radius: 50%;
  border: 2px solid #e0e0e5; display: flex;
  align-items: center; justify-content: center;
  font-size: 0.8rem; color: transparent;
  transition: all 0.2s;
  flex-shrink: 0;
}
.sv-option.selected .sv-option-check {
  border-color: #c0392b; background: #c0392b; color: #fff;
}

/* Multi-select counter */
.sv-multi-count {
  text-align: center; font-size: 0.82rem; color: #888899;
  margin-top: 8px; font-weight: 600;
}

/* Text Input */
.sv-textarea {
  width: 100%; min-height: 120px; padding: 16px;
  border: 2px solid #e0e0e5; border-radius: 12px;
  font-family: inherit; font-size: 1rem; line-height: 1.5;
  color: #1a1a2e; resize: vertical;
  transition: border-color 0.2s;
}
.sv-textarea:focus {
  outline: none; border-color: #1a1a2e;
}
.sv-char-count {
  text-align: right; font-size: 0.78rem; color: #888899;
  margin-top: 6px;
}

/* Email Step */
.sv-email-input {
  width: 100%; padding: 14px 16px;
  border: 2px solid #e0e0e5; border-radius: 12px;
  font-family: inherit; font-size: 1rem;
  color: #1a1a2e; transition: border-color 0.2s;
  margin-bottom: 16px;
}
.sv-email-input:focus { outline: none; border-color: #1a1a2e; }

.sv-checkbox-wrap {
  display: flex; align-items: flex-start; gap: 10px;
  cursor: pointer; margin-bottom: 12px;
}
.sv-checkbox-wrap input[type="checkbox"] {
  position: absolute; opacity: 0; width: 0; height: 0;
}
.sv-checkbox-custom {
  width: 22px; height: 22px; border: 2px solid #e0e0e5;
  border-radius: 6px; flex-shrink: 0; margin-top: 1px;
  transition: all 0.2s; position: relative;
}
.sv-checkbox-wrap input:checked ~ .sv-checkbox-custom {
  background: #c0392b; border-color: #c0392b;
}
.sv-checkbox-wrap input:checked ~ .sv-checkbox-custom::after {
  content: '✓'; color: #fff; font-size: 0.7rem;
  position: absolute; top: 50%; left: 50%;
  transform: translate(-50%, -50%);
}
.sv-checkbox-label {
  font-size: 0.92rem; color: #555566; line-height: 1.4;
}
.sv-privacy {
  font-size: 0.78rem; color: #888899; line-height: 1.4;
  padding-left: 32px; margin: 0;
}

/* Navigation */
.sv-nav {
  display: flex; justify-content: space-between;
  margin-top: 28px; gap: 12px;
}
.sv-btn-primary, .sv-btn-next, .sv-btn-back, .sv-btn-secondary, .sv-btn-tertiary {
  font-family: inherit; font-weight: 700; border: none;
  cursor: pointer; transition: all 0.2s; text-decoration: none;
  display: inline-flex; align-items: center; justify-content: center;
}
.sv-btn-primary {
  padding: 14px 36px; font-size: 1.05rem;
  background: #c0392b; color: #fff; border-radius: 10px;
  border: 2px solid #c0392b;
}
.sv-btn-primary:hover { background: #a93226; border-color: #a93226; }
.sv-btn-next {
  padding: 12px 28px; font-size: 0.95rem;
  background: #c0392b; color: #fff; border-radius: 10px;
}
.sv-btn-next:hover { background: #a93226; }
.sv-btn-next.disabled { background: #ccc; cursor: not-allowed; }
.sv-btn-back {
  padding: 12px 20px; font-size: 0.9rem;
  background: transparent; color: #888899;
  border: 2px solid #e0e0e5; border-radius: 10px;
}
.sv-btn-back:hover { border-color: #888899; color: #555; }
.sv-btn-secondary {
  padding: 12px 24px; font-size: 0.9rem;
  background: #1a1a2e; color: #fff; border-radius: 10px;
}
.sv-btn-secondary:hover { background: #2d2d52; }
.sv-btn-tertiary {
  padding: 10px 20px; font-size: 0.88rem;
  background: transparent; color: #888899;
  border: 2px solid #e0e0e5; border-radius: 10px;
}
.sv-btn-tertiary:hover { border-color: #888899; }

/* Skip */
.sv-skip {
  display: block; margin: 16px auto 0;
  background: transparent; border: none; color: #888899;
  font-family: inherit; font-size: 0.85rem; font-weight: 600;
  cursor: pointer; text-decoration: underline; text-align: center;
}
.sv-skip-center { text-align: center; }
.sv-skip:hover { color: #555; }

/* Thank You */
.sv-thanks {
  text-align: center; padding: 48px 20px;
  animation: svFadeIn 0.5s ease;
}
.sv-thanks-icon { font-size: 3.5rem; margin-bottom: 16px; }
.sv-thanks-title {
  font-size: 2.2rem; font-weight: 800; color: #1a1a2e;
  margin: 0 0 12px;
}
.sv-thanks-text {
  font-size: 1.05rem; color: #555566; line-height: 1.6;
  margin: 0 0 8px; max-width: 460px; margin-left: auto; margin-right: auto;
}
.sv-thanks-buttons {
  display: flex; flex-wrap: wrap; gap: 12px;
  justify-content: center; margin-top: 32px;
}

/* Follow-up indicator */
.sv-followup .sv-q-heading { font-size: 1.2rem; }

/* Animations */
@keyframes svSlideIn {
  from { opacity: 0; transform: translateX(20px); }
  to { opacity: 1; transform: translateX(0); }
}
@keyframes svFadeIn {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: translateY(0); }
}
.sv-slide-in { animation: svSlideIn 0.3s ease; }

/* Mobile */
@media (max-width: 768px) {
  #ward4-survey-app { min-height: 420px; }
  .sv-intro-title { font-size: 1.6rem; }
  .sv-intro-text { font-size: 0.95rem; }
  .sv-q-heading { font-size: 1.15rem; }
  .sv-q-icon { font-size: 1.5rem; }
  .sv-option { padding: 14px 16px; font-size: 0.92rem; min-height: 52px; }
  .sv-btn-primary { padding: 12px 28px; font-size: 0.95rem; }
  .sv-btn-next { padding: 10px 22px; font-size: 0.88rem; }
  .sv-btn-back { padding: 10px 16px; font-size: 0.82rem; }
  .sv-thanks-title { font-size: 1.8rem; }
  .sv-progress-label { font-size: 0.72rem; }
}

@media (max-width: 480px) {
  .sv-q-header { gap: 10px; }
  .sv-q-icon { font-size: 1.3rem; }
  .sv-q-heading { font-size: 1.05rem; }
  .sv-option { padding: 12px 14px; font-size: 0.88rem; }
  .sv-thanks-buttons { flex-direction: column; align-items: stretch; }
  .sv-thanks-buttons button, .sv-thanks-buttons a { width: 100%; }
}
