/* Sonographer In The Making — Preference Center
   Brand palette extracted from Jenny's Mailchimp welcome email:
     teal       #61bdb7  (sections, accents)
     pink       #f082b4  (primary buttons)
     navy       #242253  (all text)
     white      #ffffff  (card)
     off-white  #f4f4f4  (page bg)
   Font: 'Lucida Sans Unicode', 'Lucida Grande', sans-serif
   660px max width, everything centered.
*/

* { box-sizing: border-box; margin: 0; padding: 0; }

body {
  font-family: 'Lucida Sans Unicode', 'Lucida Grande', sans-serif;
  background: #f4f4f4;
  color: #242253;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  padding: 32px 16px 80px;
}

.container {
  max-width: 660px;
  margin: 0 auto;
  background: #ffffff;
  overflow: hidden;
}

/* Header — logo image on white (matches email header) */
.brand-header {
  padding: 24px 0 12px;
  text-align: center;
  background: #ffffff;
}
.brand-header img {
  display: block;
  width: 100%;
  max-width: 660px;
  height: auto;
  margin: 0 auto;
}
.brand-header h1 {
  font-size: 28px;
  font-weight: bold;
  color: #242253;
  margin: 16px 0 6px;
  text-align: center;
}
.greeting {
  font-size: 15px;
  color: #242253;
  text-align: center;
  margin-bottom: 0;
}

section { padding: 28px 32px; border-bottom: 1px solid #eef0f2; }
section:last-of-type { border-bottom: none; }

h2 {
  font-size: 20px;
  font-weight: bold;
  color: #242253;
  margin-bottom: 4px;
  text-align: center;
}
h3 {
  font-size: 17px;
  font-weight: bold;
  color: #242253;
  margin-bottom: 4px;
  text-align: center;
}
.prefs-subtitle {
  font-size: 13px;
  color: #242253;
  opacity: 0.7;
  margin-bottom: 20px;
  text-align: center;
}

/* Toggle rows */
.toggle-row {
  display: flex;
  align-items: flex-start;
  gap: 16px;
  padding: 14px 0;
  cursor: pointer;
  border-top: 1px solid #f4f4f4;
}
.toggle-row:first-of-type { border-top: none; }
.toggle-label { flex: 1; }
.toggle-label strong {
  display: block;
  font-size: 15px;
  font-weight: 600;
  color: #242253;
  margin-bottom: 3px;
}
.toggle-label p {
  font-size: 13px;
  color: #888;
  line-height: 1.5;
}

/* Toggle switch */
.toggle-input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}
.toggle-switch {
  display: inline-block;
  width: 42px;
  height: 24px;
  background: #d0d4da;
  border-radius: 12px;
  position: relative;
  flex-shrink: 0;
  margin-top: 2px;
  transition: background 0.2s ease;
}
.toggle-switch::after {
  content: '';
  position: absolute;
  top: 2px;
  left: 2px;
  width: 20px;
  height: 20px;
  background: #ffffff;
  border-radius: 50%;
  transition: transform 0.2s ease;
  box-shadow: 0 1px 3px rgba(0,0,0,0.15);
}
.toggle-input:checked + .toggle-switch {
  background: #61bdb7;
}
.toggle-input:checked + .toggle-switch::after {
  transform: translateX(18px);
}

/* Unsub section */
.unsub-section .toggle-row {
  background: #fef9f3;
  border: 1px solid #f2e6d3;
  border-radius: 10px;
  padding: 16px 18px;
}
.unsub-section .toggle-row .toggle-label strong { color: #8b5a1c; }

/* Feedback section */
.feedback-section h2 { margin-bottom: 4px; }
fieldset {
  border: none;
  margin: 12px 0 18px;
  padding: 0;
}
legend {
  font-size: 14px;
  font-weight: 600;
  color: #242253;
  margin-bottom: 10px;
}
fieldset label {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 0;
  font-size: 14px;
  color: #555;
  cursor: pointer;
}
fieldset input[type="checkbox"] {
  width: 16px;
  height: 16px;
  accent-color: #61bdb7;
}

.textarea-label {
  display: block;
  margin-bottom: 16px;
}
.textarea-label > span {
  display: block;
  font-size: 14px;
  font-weight: 600;
  color: #242253;
  margin-bottom: 6px;
}
textarea {
  width: 100%;
  border: 1px solid #d0d4da;
  border-radius: 8px;
  padding: 12px;
  font-family: inherit;
  font-size: 14px;
  line-height: 1.5;
  resize: vertical;
  transition: border-color 0.15s ease;
}
textarea:focus {
  outline: none;
  border-color: #61bdb7;
}
.submit-btn {
  background: #f082b4;
  color: #ffffff;
  border: none;
  border-radius: 50px;
  padding: 16px 28px;
  font-size: 16px;
  font-weight: normal;
  font-family: inherit;
  cursor: pointer;
  transition: background 0.15s ease;
  min-width: 200px;
}
.submit-btn:hover { background: #e06ba5; }
.submit-btn:disabled { background: #f2b3d0; cursor: not-allowed; }

.feedback-thanks {
  display: none;
  margin-top: 12px;
  font-size: 14px;
  color: #50a8a2;
  font-weight: 500;
}
.feedback-thanks.visible { display: block; }

/* Footer */
.page-footer {
  padding: 24px 32px;
  text-align: center;
  border-top: 1px solid #eef0f2;
  background: #f9fafb;
}
.page-footer p {
  font-size: 13px;
  color: #888;
  margin-bottom: 4px;
}
.muted { color: #aaa; font-size: 12px; }

/* Small screens */
@media (max-width: 560px) {
  body { padding: 16px 8px 60px; }
  .container { border-radius: 10px; }
  section { padding: 22px 20px; }
  .brand-header { padding: 32px 20px 24px; }
  .brand-header h1 { font-size: 24px; }
  .gift-choices { grid-template-columns: 1fr; }
}
