/* Baby Pottying brand tokens from https://www.babypottying.co.uk */
:root {
  --cream: #FFFAEB;
  --cream-alt: #FFFAEC;
  --ink: #000000;
  --olive: #535A30;
  --lime: #E4E390;
  --lime-border: #d6d57d;
  --coral: #FF6F52;
  --black: #000000;
  --radius: 12px;
  --font-heading: "League Spartan", "Helvetica Neue", sans-serif;
  --font-body: "Raleway", "Helvetica Neue", sans-serif;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  -webkit-tap-highlight-color: transparent;
}

body {
  margin: 0;
  min-height: 100vh;
  font-family: var(--font-body);
  font-weight: 400;
  font-size: 20px;
  line-height: 1.45;
  letter-spacing: normal;
  color: var(--ink);
  background: var(--cream);
}

.page {
  min-height: 100vh;
  padding: 1.75rem 1.1rem 2.75rem;
}

/* When embedded in an iframe, avoid 100vh inflation that creates dead space below the quiz */
html.in-iframe,
html.in-iframe body,
html.in-iframe .page {
  min-height: 0;
}


.shell {
  width: min(880px, 100%);
  margin: 0 auto;
}

.brand-header {
  padding: 1.4rem 1.5rem 0;
  text-align: center;
}

.brand-link {
  display: inline-block;
  font-family: var(--font-heading);
  font-size: clamp(1.45rem, 3vw, 1.85rem);
  font-weight: 700;
  letter-spacing: -0.04em;
  line-height: 1;
  color: var(--ink);
  text-decoration: none;
}

.brand-link:hover {
  color: var(--olive);
}

.brand-link:focus-visible {
  outline: 3px solid var(--coral);
  outline-offset: 4px;
}

.panel {
  background: var(--cream-alt);
  border-radius: 18px;
  border: 1px solid var(--lime-border);
  box-shadow: 0 18px 40px rgba(83, 90, 48, 0.08);
  overflow: hidden;
  min-height: 520px;
  display: flex;
  flex-direction: column;
}

.app-content {
  display: flex;
  flex: 1;
  min-width: 0;
  flex-direction: column;
}

.loading-state,
.error-state {
  padding: 2rem;
  color: var(--olive);
  line-height: 1.4;
}

.error-state {
  color: var(--olive);
}

.screen-body {
  padding: clamp(1.6rem, 4vw, 2.4rem);
  flex: 1;
}

.screen-body.is-entering {
  animation: none;
}

.screen-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  padding: 1.05rem 1.5rem;
  background: var(--olive);
  color: var(--cream);
}

@keyframes fade-up {
  from {
    opacity: 0;
    transform: translateY(8px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.progress-label,
.trait-label {
  margin: 0;
  font-family: var(--font-heading);
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--olive);
}

.progress-label {
  margin-bottom: 0.4rem;
}

.trait-label {
  margin-bottom: 0.85rem;
  color: var(--coral);
}

.question-title {
  margin: 0 0 0.85rem;
  font-family: var(--font-heading);
  font-size: clamp(1.7rem, 4vw, 2.5rem);
  font-weight: 700;
  letter-spacing: -0.05em;
  line-height: 1.1;
  color: var(--ink);
}

h1.question-title,
h2.question-title,
h3.question-title {
  font-family: var(--font-heading);
  font-weight: 700;
  letter-spacing: -0.05em;
}

.rule {
  width: 56px;
  height: 4px;
  background: var(--lime);
  border: 0;
  margin: 0 0 1.05rem;
}

.progress-track {
  width: 100%;
  max-width: 16rem;
  height: 4px;
  margin: 0 0 1.05rem;
  border-radius: 300px;
  background: rgba(83, 90, 48, 0.15);
  overflow: hidden;
}

.progress-fill {
  height: 100%;
  border-radius: 300px;
  background: var(--lime);
  transition: width 220ms ease;
}

.subheading {
  margin: 0 0 2rem;
  font-family: var(--font-heading);
  font-weight: 600;
  letter-spacing: -0.025em;
  max-width: 48rem;
  color: var(--ink);
  font-size: 1.05rem;
  line-height: 1.4;
}

.scale {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0.85rem;
  position: relative;
  margin: 0.5rem 0 0.25rem;
  padding-top: 0.35rem;
}

.scale::before {
  content: "";
  position: absolute;
  top: calc(0.35rem + 11px);
  left: 12.5%;
  right: 12.5%;
  border-top: 2px dotted var(--olive);
  opacity: 0.35;
  z-index: 0;
}

.scale-option {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.7rem;
  padding: 0;
  border: 0;
  margin: 0;
  background: transparent;
  background-color: transparent;
  cursor: pointer;
  font: inherit;
  color: inherit;
  text-align: center;
  appearance: none;
  -webkit-appearance: none;
  -webkit-tap-highlight-color: transparent;
  -webkit-touch-callout: none;
  user-select: none;
}

.scale-option:focus-visible {
  outline: none;
}

.scale-option:focus-visible .scale-dot {
  outline: 3px solid var(--coral);
  outline-offset: 3px;
}

.scale-dot {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  border: 2px solid var(--olive);
  background: var(--cream);
  background-color: var(--cream);
  box-sizing: border-box;
  transform: none;
}

.scale-option.is-selected .scale-dot,
.scale-option[aria-checked="true"] .scale-dot {
  background: var(--coral);
  background-color: var(--coral);
  border-color: var(--coral);
  box-shadow: inset 0 0 0 3px var(--cream);
}

.scale-label {
  font-family: var(--font-heading);
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: normal;
  line-height: 1.25;
  color: var(--ink);
  max-width: 9.5rem;
}

.btn {
  appearance: none;
  border: 0;
  background: none;
  font-family: var(--font-heading);
  font-weight: 700;
  letter-spacing: -0.03em;
  cursor: pointer;
  transition: none;
}

.btn:disabled {
  opacity: 0.4;
  cursor: not-allowed;
  transform: none;
}

.btn:focus-visible {
  outline: 3px solid var(--cream);
  outline-offset: 3px;
}

.btn-back {
  color: var(--cream);
  padding: 0.55rem 0.2rem;
  font-family: var(--font-body);
  font-weight: 500;
  letter-spacing: -0.04em;
}

.btn-back:not(:disabled):hover {
  opacity: 0.8;
}

.btn-next,
.btn-primary {
  background: var(--coral);
  color: var(--cream);
  border-radius: 300px;
  padding: 12.6px 25.2px;
  font-family: var(--font-heading);
  font-weight: 700;
  letter-spacing: -0.03em;
}

.btn-next:not(:disabled):hover,
.btn-primary:not(:disabled):hover {
  filter: brightness(0.96);
  transform: translateY(-1px);
}

.intro-lead,
.results-note {
  margin: 0 0 1.5rem;
  color: var(--ink);
  line-height: 1.45;
  letter-spacing: normal;
  font-size: 1.05rem;
  max-width: 42rem;
}

.results-intro {
  margin: 0 0 1.6rem;
  padding: 1.25rem 1.3rem 1.3rem;
  background: var(--lime);
  border: 1px solid var(--lime-border);
  border-radius: var(--radius);
}

.results-intro p {
  margin: 0 0 0.85rem;
}

.results-intro p:last-child {
  margin-bottom: 0;
}

.results-list {
  display: grid;
  gap: 1.2rem;
  margin: 0 0 0.5rem;
}

.result-card,
.combo-card {
  padding: 1.35rem 1.4rem 1.45rem;
  border: 1px solid var(--lime-border);
  border-radius: var(--radius);
  background: var(--lime);
}

.result-card {
  background: #fffdf4;
  border-color: var(--lime-border);
}

.combo-card .result-trait {
  color: var(--olive);
}

.result-header {
  margin-bottom: 0.95rem;
  padding-bottom: 0.75rem;
  border-bottom: 1px solid var(--lime-border);
}

.result-trait {
  margin: 0;
  font-family: var(--font-heading);
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--olive);
}

.result-score {
  margin: 0.35rem 0 0;
  font-family: var(--font-heading);
  font-size: 1.35rem;
  font-weight: 700;
  letter-spacing: -0.05em;
  color: var(--ink);
}

.guidance-list {
  display: grid;
  gap: 0.95rem;
}

.guidance-block {
  margin: 0;
}

.guidance-section {
  margin: 0 0 0.3rem;
  font-family: var(--font-heading);
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--olive);
}

.guidance-text {
  margin: 0 0 0.55rem;
  color: var(--ink);
  line-height: 1.4;
  letter-spacing: normal;
}

.guidance-text:last-child {
  margin-bottom: 0;
}

.dev-warning {
  margin: 0;
  padding: 0.9rem 1rem;
  border: 1px solid var(--coral);
  border-radius: var(--radius);
  background: var(--cream);
}

.dev-warning-title {
  margin: 0 0 0.55rem;
  font-family: var(--font-heading);
  font-weight: 700;
  letter-spacing: -0.04em;
  color: var(--olive);
}

.dev-warning-list {
  margin: 0 0 0.55rem;
  padding-left: 1.1rem;
  color: var(--ink);
  line-height: 1.4;
}

.dev-warning-list code {
  font-size: 0.92em;
  word-break: break-word;
}

.dev-warning-reason {
  margin: 0;
  color: var(--olive);
  line-height: 1.4;
}

.results-note {
  margin-top: 1.25rem;
  padding: 1rem 1.1rem;
  background: var(--lime);
  border-radius: var(--radius);
  color: var(--ink);
}

.intro-actions,
.results-actions {
  display: flex;
  gap: 0.75rem;
  margin-top: 0.5rem;
}

.intro-actions {
  flex-direction: column;
  align-items: flex-start;
}

.intro-duration {
  font-size: 1.05rem;
  opacity: 0.85;

  margin: 0;
  font-size: 1.05rem;
  letter-spacing: 0;
  color: var(--olive);
}

.intro-screen .intro-lead + .intro-lead {
  margin-top: -0.55rem;
}

.combo-list {
  display: grid;
  gap: 1.2rem;
  margin: 0 0 1.5rem;
}

@media (max-width: 760px) {
  .panel {
    min-height: 0;
  }

  .scale {
    grid-template-columns: 1fr;
    gap: 0.75rem;
  }

  .scale::before {
    display: none;
  }

  .scale-option {
    flex-direction: row;
    justify-content: flex-start;
    text-align: left;
    gap: 0.85rem;
    padding: 0.9rem 1rem;
    border: 1px solid var(--lime-border);
    border-radius: var(--radius);
    background: #fffdf4;
  }

  .scale-option.is-selected,
  .scale-option[aria-checked="true"] {
    border-color: var(--coral);
    background: var(--lime);
  }

  .scale-label {
    max-width: none;
    font-size: 0.95rem;
  }

  .screen-footer {
    flex-wrap: wrap;
  }

  .btn-next,
  .btn-primary {
    width: auto;
  }
}

@media (prefers-reduced-motion: reduce) {
  .screen-body,
  .screen-body.is-entering,
  .scale-dot,
  .btn,
  .progress-fill {
    animation: none !important;
    transition: none !important;
  }
}

/* Synthesised report */
.report-loading,
.report-fallback {
  margin: 0 0 1.5rem;
  padding: 1.25rem 1.3rem;
  border-radius: var(--radius);
  border: 1px solid var(--lime-border);
  background: #fffdf4;
}

.report-loading-title,
.report-fallback-title {
  margin: 0 0 0.45rem;
  font-family: var(--font-heading);
  font-weight: 700;
  letter-spacing: -0.04em;
  color: var(--olive);
}

.report-loading-copy,
.report-fallback-copy {
  margin: 0;
  color: var(--ink);
  line-height: 1.4;
  font-size: 1.05rem;
}

.report-narrative {
  display: grid;
  gap: 1.35rem;
  margin: 0 0 1.25rem;
}

.report-section {
  padding: 1.35rem 1.4rem 1.45rem;
  border: 1px solid var(--lime-border);
  border-radius: var(--radius);
  background: #fffdf4;
}

.report-section-title {
  margin: 0 0 0.85rem;
  font-family: var(--font-heading);
  font-size: clamp(1.25rem, 3vw, 1.55rem);
  font-weight: 700;
  letter-spacing: -0.05em;
  line-height: 1.15;
  color: var(--olive);
}

.report-section-body {
  letter-spacing: normal;
}

.tip-card-body {
  letter-spacing: normal;
}

.report-section-body .guidance-text {
  font-size: 1.05rem;
}

.report-meta {
  margin: 0 0 1.25rem;
  font-family: var(--font-heading);
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--olive);
  opacity: 0.85;
}

.qa-cards {
  margin: 0 0 1.5rem;
  padding: 1rem 1.15rem 1.15rem;
  border: 1px dashed var(--lime-border);
  border-radius: var(--radius);
  background: var(--cream);
}

.qa-cards > summary {
  cursor: pointer;
  font-family: var(--font-heading);
  font-weight: 700;
  letter-spacing: -0.03em;
  color: var(--olive);
  list-style: none;
}

.qa-cards > summary::-webkit-details-marker {
  display: none;
}

.qa-cards > summary::before {
  content: "+ ";
  color: var(--coral);
}

.qa-cards[open] > summary::before {
  content: "– ";
}

.qa-cards-note {
  margin: 0.75rem 0 1rem;
  color: var(--ink);
  font-size: 0.98rem;
  line-height: 1.4;
}


/* New synthesised results: tip cards + profile sections */
.report-section-help {
  background: #fffdf4;
}

.tip-card-grid {
  display: grid;
  gap: 0.95rem;
}

.tip-card {
  position: relative;
  padding: 1.1rem 1.15rem 1.15rem;
  border-radius: var(--radius);
  border: 1px solid var(--lime-border);
  background: var(--lime);
}

.tip-card-index {
  margin: 0 0 0.35rem;
  font-family: var(--font-heading);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--coral);
}

.tip-card-title {
  margin: 0 0 0.45rem;
  font-family: var(--font-heading);
  font-size: 1.15rem;
  font-weight: 700;
  letter-spacing: -0.04em;
  line-height: 1.2;
  color: var(--olive);
}

.tip-card-body .guidance-text {
  margin: 0;
  font-size: 1.02rem;
  line-height: 1.4;
  color: var(--ink);
}

.report-section-watch {
  background: #fffdf4;
}

.keep-eye-list {
  margin: 0;
  padding-left: 1.2rem;
  display: grid;
  gap: 0.65rem;
  color: var(--ink);
  font-size: 1.05rem;
  line-height: 1.4;
}

.keep-eye-list li::marker {
  color: var(--coral);
}

.full-profile-details {
  margin: 0;
  padding: 1.15rem 1.25rem 1.25rem;
  border: 1px dashed var(--lime-border);
  border-radius: var(--radius);
  background: var(--cream);
}

.full-profile-summary {
  cursor: pointer;
  font-family: var(--font-heading);
  font-size: clamp(1.05rem, 2.5vw, 1.25rem);
  font-weight: 700;
  letter-spacing: -0.04em;
  color: var(--olive);
  list-style: none;
}

.full-profile-summary::-webkit-details-marker {
  display: none;
}

.full-profile-summary::before {
  content: "+ ";
  color: var(--coral);
}

.full-profile-details[open] > .full-profile-summary::before {
  content: "– ";
}

.full-profile-body {
  margin-top: 0.95rem;
  padding-top: 0.85rem;
  border-top: 1px solid var(--lime-border);
}

.full-profile-body .guidance-text {
  font-size: 1.02rem;
}

@media (min-width: 761px) {
  .tip-card-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 1rem;
  }
}


/* Email-me-my-report form */
.email-report {
  margin: 0 0 1.5rem;
  padding: 1.35rem 1.4rem 1.4rem;
  border: 1px solid var(--lime-border);
  border-radius: var(--radius);
  background: #fffdf4;
}

.email-report-success {
  background: var(--lime);
}

.email-report-title {
  margin: 0 0 0.45rem;
  font-family: var(--font-heading);
  font-size: clamp(1.15rem, 2.8vw, 1.4rem);
  font-weight: 700;
  letter-spacing: -0.04em;
  color: var(--olive);
}

.email-report-copy {
  margin: 0 0 1rem;
  color: var(--ink);
  font-size: 1.02rem;
  line-height: 1.4;
  max-width: 40rem;
}

.email-report-form {
  display: grid;
  gap: 0.85rem;
  max-width: 28rem;
}

.email-field {
  display: grid;
  gap: 0.35rem;
}

.email-field-label {
  font-family: var(--font-heading);
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--olive);
}

.email-field input {
  appearance: none;
  width: 100%;
  padding: 0.75rem 0.9rem;
  border: 1px solid var(--lime-border);
  border-radius: var(--radius);
  background: var(--cream);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 1rem;
  line-height: 1.3;
}

.email-field input:focus-visible {
  outline: 3px solid var(--coral);
  outline-offset: 2px;
}

.email-field input:disabled {
  opacity: 0.65;
  cursor: not-allowed;
}

.email-report-submit {
  justify-self: start;
  margin-top: 0.15rem;
}

.email-privacy {
  margin: 0;
  font-size: 0.88rem;
  line-height: 1.4;
  color: var(--olive);
  max-width: 28rem;
}

.email-report-error {
  margin: 0;
  padding: 0.7rem 0.85rem;
  border: 1px solid var(--coral);
  border-radius: var(--radius);
  background: var(--cream);
  color: var(--olive);
  font-size: 0.98rem;
  line-height: 1.35;
}




.tool-credit {
  margin: 1rem 0.25rem 0;
  font-size: 0.82rem;
  line-height: 1.45;
  color: var(--ink);
}

.tool-credit a {
  color: var(--olive);
  text-decoration: underline;
}

.tool-credit a:hover {
  color: var(--coral);
}

.tool-credit em {
  font-style: italic;
}
