/* The [stw_demo] form, and the /demo page around it (deploy/demo-page/).
   Colours, type and buttons follow savetowishlist.com's free plugin page:
   coral #f6646a buttons with 6px corners, a white-to-peach hero, Noto Sans
   from the theme. */
.stw-demo-form-card {
  --stw-coral: #f6646a;
  --stw-coral-dark: #e14f55;
  --stw-coral-soft: #fff2f2;
  --stw-peach: #f5d9ba;
  --stw-ink: #2a1a14;
  --stw-muted: #666;
  --stw-line: #ecdcd2;
}

/* --- The form ---------------------------------------------------------------- */
.stw-demo-form-card {
  max-width: 560px;
  margin: 0 auto;
  padding: 32px;
  background: #fff;
  border-radius: 10px;
  box-shadow: 0 16px 48px rgba(178, 93, 35, 0.14);
  color: var(--stw-ink);
  box-sizing: border-box;
  text-align: left;
}
.stw-demo-form-card *, .stw-demo-form-card *::before { box-sizing: border-box; }
.stw-demo-form { display: flex; flex-direction: column; gap: 12px; margin: 0; }
.stw-demo-form > label { font-size: 15px; font-weight: 700; }
.stw-demo-form input[type=text] {
  width: 100%;
  padding: 13px 14px;
  border: 1px solid var(--stw-line);
  border-radius: 6px;
  font: inherit;
  font-size: 16px;
  outline: none;
  background: #fff;
}
.stw-demo-form input[type=text]:focus { border-color: var(--stw-coral); box-shadow: 0 0 0 3px rgba(246, 100, 106, 0.2); }
.stw-demo-form fieldset { border: 1px solid var(--stw-line); border-radius: 6px; padding: 12px 14px 14px; margin: 4px 0 0; }
.stw-demo-form legend { font-size: 13px; font-weight: 700; padding: 0 4px; }
.stw-demo-choice { display: flex; gap: 9px; align-items: flex-start; margin-top: 9px; }
.stw-demo-choice input[type=radio] { margin: 4px 0 0; accent-color: var(--stw-coral); flex: none; }
.stw-demo-choice label { font-weight: 600; font-size: 14px; cursor: pointer; }
.stw-demo-choice span { display: block; font-weight: 400; font-size: 13px; color: var(--stw-muted); margin-top: 2px; line-height: 1.45; }
.stw-demo-submit {
  background: var(--stw-coral);
  color: #fff;
  border: none;
  padding: 16px 20px;
  border-radius: 6px;
  font: inherit;
  font-size: 18px;
  font-weight: 700;
  line-height: 1.1;
  cursor: pointer;
  box-shadow: rgba(0, 0, 0, 0.08) 0 2px 3px;
}
.stw-demo-submit:hover { background: var(--stw-coral-dark); }
.stw-demo-submit:disabled { opacity: 0.6; cursor: wait; }
.stw-demo-progress { list-style: none; margin: 18px 0 0; padding: 0; font-size: 14px; }
.stw-demo-progress li { padding: 6px 0 6px 28px; position: relative; color: #999; }
.stw-demo-progress li::before {
  content: '';
  position: absolute;
  left: 4px;
  top: 9px;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  border: 2px solid var(--stw-line);
}
.stw-demo-progress li.is-busy, .stw-demo-progress li.is-done { color: var(--stw-ink); }
.stw-demo-progress li.is-busy::before { border-color: var(--stw-coral); border-right-color: transparent; animation: stw-demo-spin 0.8s linear infinite; }
.stw-demo-progress li.is-done::before { background: var(--stw-coral); border-color: var(--stw-coral); }
.stw-demo-progress li.is-skip { color: #aaa; }
@keyframes stw-demo-spin { to { transform: rotate(360deg); } }
.stw-demo-status { margin-top: 16px; font-size: 14px; min-height: 20px; line-height: 1.5; color: var(--stw-muted); }
.stw-demo-status.is-error { color: #b42318; }
.stw-demo-status code { background: var(--stw-coral-soft); color: var(--stw-coral-dark); padding: 1px 6px; border-radius: 4px; font-size: 12px; }
.stw-demo-note { color: var(--stw-muted); font-size: 13px; margin: 16px 0 0; line-height: 1.5; }
/* On the /demo page the reassurance line sits under the card instead. */
.stw-demo-page .stw-demo-note { display: none; }

/* The /demo page around the form carries its own styles (deploy/demo-page/
   demo-page.html), so it looks right with or without this plugin. */
@media (max-width: 480px) { .stw-demo-form-card { padding: 20px 16px; } }
