/* Circle Direct standalone telemedicine simulation. No external assets or fonts. */
:root {
  --red: #b92b27;
  --red-dark: #92211e;
  --red-soft: #fff1ef;
  --ink: #282422;
  --muted: #706965;
  --line: #e9e2dc;
  --warm-bg: #faf7f3;
  --white: #ffffff;
  --green: #25734a;
  --green-soft: #edf8f1;
  --doctor: #285f54;
  --doctor-dark: #1d493f;
  --doctor-soft: #edf5f2;
  --amber: #8a6127;
  --amber-soft: #fff7e7;
  --shadow: 0 8px 28px rgba(60, 42, 30, 0.06);
  --radius: 16px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--warm-bg);
  color: var(--ink);
  font-family: Inter, ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  font-size: 16px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

button,
input,
select,
textarea {
  font: inherit;
}

button,
a {
  -webkit-tap-highlight-color: transparent;
}

button {
  cursor: pointer;
}

button:disabled,
input:disabled,
select:disabled,
textarea:disabled {
  cursor: not-allowed;
  opacity: 0.58;
}

button:focus-visible,
a:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible {
  outline: 3px solid rgba(185, 43, 39, 0.3);
  outline-offset: 3px;
}

.stage-card--doctor button:focus-visible,
.stage-card--doctor input:focus-visible,
.stage-card--doctor select:focus-visible,
.stage-card--doctor textarea:focus-visible {
  outline-color: rgba(40, 95, 84, 0.32);
}

[hidden] {
  display: none !important;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.skip-link {
  position: fixed;
  top: 8px;
  left: 12px;
  z-index: 200;
  padding: 10px 16px;
  border-radius: 8px;
  background: var(--ink);
  color: var(--white);
  text-decoration: none;
  transform: translateY(-180%);
}

.skip-link:focus {
  transform: translateY(0);
}

.mock-banner {
  position: sticky;
  top: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px 10px;
  min-height: 48px;
  padding: 10px 20px;
  border-bottom: 1px solid #efcfcb;
  background: var(--red-soft);
  color: var(--red-dark);
  font-size: 0.8rem;
  letter-spacing: 0.01em;
  text-align: center;
}

.mock-banner strong {
  flex: 0 0 auto;
  font-size: 0.78rem;
  letter-spacing: 0.07em;
}

.mock-banner__icon {
  display: inline-grid;
  flex: 0 0 auto;
  width: 21px;
  height: 21px;
  place-items: center;
  border-radius: 50%;
  background: var(--red);
  color: var(--white);
  font-size: 0.78rem;
}

.site-header {
  border-bottom: 1px solid var(--line);
  background: var(--white);
}

.site-header__inner {
  display: flex;
  width: min(1220px, calc(100% - 40px));
  min-height: 82px;
  margin: 0 auto;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.back-link {
  color: var(--muted);
  font-size: 0.88rem;
  font-weight: 600;
  text-decoration: none;
}

.back-link:hover {
  color: var(--red);
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
}

.brand__mark {
  display: grid;
  width: 34px;
  height: 34px;
  place-items: center;
  border-radius: 10px;
  background: var(--red);
  color: var(--white);
  font-size: 1.25rem;
  font-weight: 800;
}

.brand__name {
  font-size: 1.12rem;
  font-weight: 800;
  letter-spacing: -0.025em;
}

.brand__divider {
  width: 1px;
  height: 22px;
  margin: 0 2px;
  background: var(--line);
}

.brand__descriptor {
  color: var(--muted);
  font-size: 0.83rem;
}

.demo-badge,
.fiction-tag,
.provider-badge {
  display: inline-flex;
  flex: 0 0 auto;
  align-items: center;
  border-radius: 999px;
  font-size: 0.7rem;
  font-weight: 700;
  white-space: nowrap;
}

.demo-badge,
.fiction-tag {
  padding: 6px 11px;
  background: #f3efeb;
  color: #625a55;
}

.provider-badge {
  padding: 6px 11px;
  background: var(--doctor-soft);
  color: var(--doctor);
}

.page-shell {
  width: min(1220px, calc(100% - 40px));
  margin: 0 auto;
  padding: 42px 0 56px;
}

.intro {
  display: flex;
  margin-bottom: 30px;
  align-items: flex-end;
  justify-content: space-between;
  gap: 32px;
}

.eyebrow,
.stage-heading__label {
  margin: 0 0 8px;
  color: var(--red);
  font-size: 0.74rem;
  font-weight: 800;
  letter-spacing: 0.095em;
  text-transform: uppercase;
}

.stage-card--doctor .stage-heading__label {
  color: var(--doctor);
}

h1,
h2,
h3,
p {
  margin-top: 0;
}

h1 {
  max-width: 760px;
  margin-bottom: 10px;
  font-size: clamp(1.85rem, 3.4vw, 2.65rem);
  line-height: 1.14;
  letter-spacing: -0.04em;
}

.intro__copy {
  max-width: 750px;
  margin-bottom: 0;
  color: var(--muted);
  font-size: 0.98rem;
}

.demo-actions {
  display: flex;
  flex: 0 0 auto;
  gap: 10px;
}

.button {
  display: inline-flex;
  min-height: 44px;
  padding: 10px 17px;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border: 1px solid transparent;
  border-radius: 9px;
  font-size: 0.86rem;
  font-weight: 700;
  line-height: 1.25;
  text-align: center;
  transition: background-color 150ms ease, border-color 150ms ease, color 150ms ease, transform 150ms ease;
}

.button:not(:disabled):active {
  transform: translateY(1px);
}

.button--primary {
  background: var(--red);
  color: var(--white);
}

.button--primary:hover:not(:disabled) {
  background: var(--red-dark);
}

.button--secondary {
  border-color: #dcd4ce;
  background: var(--white);
  color: #49423e;
}

.button--secondary:hover:not(:disabled) {
  border-color: #bfb4ac;
  background: #fcfaf8;
}

.button--doctor {
  background: var(--doctor);
  color: var(--white);
}

.button--doctor:hover:not(:disabled) {
  background: var(--doctor-dark);
}

.button--wide {
  width: 100%;
  margin-top: 22px;
}

.button--small {
  min-height: 38px;
  padding: 8px 12px;
  flex: 0 0 auto;
  font-size: 0.76rem;
}

.button__icon {
  font-size: 0.72rem;
}

.auto-play-status {
  margin: -12px 0 24px;
  padding: 12px 16px;
  border: 1px solid #e5d6c0;
  border-radius: 10px;
  background: var(--amber-soft);
  color: #725324;
  font-size: 0.86rem;
  font-weight: 600;
}

.simulation-layout {
  display: grid;
  grid-template-columns: 270px minmax(0, 1fr);
  align-items: start;
  gap: 24px;
}

.journey-card,
.stage-card {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--white);
  box-shadow: var(--shadow);
}

.journey-card {
  position: sticky;
  top: 68px;
  min-width: 0;
  padding: 20px 14px 14px;
}

.journey-card__heading {
  display: flex;
  padding: 0 8px 14px;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.journey-card__kicker {
  font-size: 0.8rem;
  font-weight: 800;
}

.journey-card__count {
  color: var(--muted);
  font-size: 0.7rem;
  white-space: nowrap;
}

.step-list {
  display: flex;
  margin: 0;
  padding: 0;
  flex-direction: column;
  gap: 3px;
  list-style: none;
}

.step-button {
  display: flex;
  width: 100%;
  min-height: 57px;
  padding: 9px;
  align-items: center;
  gap: 11px;
  border: 0;
  border-radius: 10px;
  background: transparent;
  color: var(--ink);
  text-align: left;
}

.step-button:hover:not(:disabled) {
  background: #faf7f4;
}

.step-button[aria-current="step"] {
  background: var(--red-soft);
}

.step-button__number {
  display: grid;
  flex: 0 0 auto;
  width: 28px;
  height: 28px;
  place-items: center;
  border: 1px solid #ddd5cf;
  border-radius: 50%;
  background: var(--white);
  color: var(--muted);
  font-size: 0.74rem;
  font-weight: 800;
}

.step-button[aria-current="step"] .step-button__number {
  border-color: var(--red);
  background: var(--red);
  color: var(--white);
}

.step-button.is-complete .step-button__number {
  border-color: #b9dbc7;
  background: var(--green-soft);
  color: var(--green);
}

.step-button__text {
  display: flex;
  min-width: 0;
  flex: 1;
  flex-direction: column;
}

.step-button__text strong {
  font-size: 0.8rem;
}

.step-button__text small {
  overflow: hidden;
  color: var(--muted);
  font-size: 0.66rem;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.step-button__state {
  color: var(--green);
  font-size: 0.8rem;
  font-weight: 800;
}

.safety-note {
  display: flex;
  margin-top: 15px;
  padding: 13px 10px 2px;
  gap: 9px;
  border-top: 1px solid var(--line);
  color: var(--green);
  font-size: 0.78rem;
}

.safety-note p {
  margin: 0;
  color: var(--muted);
  font-size: 0.7rem;
  line-height: 1.45;
}

.safety-note strong {
  display: block;
  margin-bottom: 2px;
  color: var(--ink);
  font-size: 0.73rem;
}

.workspace {
  min-width: 0;
}

.stage-card {
  min-height: 510px;
  padding: 28px 30px 30px;
  overflow: hidden;
}

.stage-card--patient {
  border-top: 3px solid #d66b64;
}

.stage-card--doctor {
  border-color: #cfddd8;
  border-top: 3px solid var(--doctor);
  background: #fffefd;
  box-shadow: 0 8px 28px rgba(35, 77, 67, 0.07);
}

.role-banner {
  display: flex;
  margin: -28px -30px 25px;
  padding: 10px 30px;
  align-items: center;
  gap: 8px;
  border-bottom: 1px solid;
  font-size: 0.69rem;
  letter-spacing: 0.035em;
}

.role-banner > span:last-child {
  margin-left: auto;
  font-size: 0.68rem;
  letter-spacing: 0;
}

.role-banner--patient {
  border-color: #f0d8d4;
  background: #fff8f6;
  color: var(--red-dark);
}

.role-banner--doctor {
  border-color: #d4e3de;
  background: var(--doctor-soft);
  color: var(--doctor-dark);
}

.role-banner__dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: currentColor;
}

.stage-heading {
  display: flex;
  margin-bottom: 25px;
  align-items: flex-start;
  justify-content: space-between;
  gap: 20px;
}

.stage-heading h2,
.completion-hero h2 {
  margin-bottom: 7px;
  font-size: clamp(1.3rem, 2vw, 1.65rem);
  line-height: 1.25;
  letter-spacing: -0.025em;
}

.stage-heading p:not(.stage-heading__label) {
  margin-bottom: 0;
  color: var(--muted);
  font-size: 0.86rem;
}

.mini-label {
  color: var(--muted);
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.setup-grid,
.brief-row,
.payment-grid,
.outcome-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
}

.field-group {
  min-width: 0;
}

.field-group label,
.choice-fieldset legend {
  display: block;
  margin-bottom: 8px;
  color: #3d3733;
  font-size: 0.79rem;
  font-weight: 750;
}

.field-group small {
  display: block;
  margin-top: 7px;
  color: var(--muted);
  font-size: 0.68rem;
}

input,
select,
textarea {
  width: 100%;
  border: 1px solid #dcd4ce;
  border-radius: 9px;
  background: #fffefd;
  color: var(--ink);
  font-size: 0.84rem;
}

input,
select {
  min-height: 45px;
  padding: 9px 12px;
}

textarea {
  min-height: 76px;
  padding: 11px 12px;
  line-height: 1.5;
  resize: vertical;
}

input::placeholder,
textarea::placeholder {
  color: #9b918a;
}

input:hover:not(:disabled),
select:hover:not(:disabled),
textarea:hover:not(:disabled) {
  border-color: #bfb4ac;
}

input[aria-invalid="true"],
select[aria-invalid="true"],
textarea[aria-invalid="true"] {
  border-color: var(--red);
  background: #fff9f8;
}

.choice-fieldset {
  min-width: 0;
  margin: 25px 0 0;
  padding: 0;
  border: 0;
}

.visit-options {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 13px;
}

.visit-option {
  position: relative;
  display: grid;
  min-height: 138px;
  padding: 17px;
  grid-template-columns: auto auto minmax(0, 1fr);
  align-items: flex-start;
  gap: 11px;
  border: 1px solid #ded6d0;
  border-radius: 12px;
  background: var(--white);
  color: var(--ink);
  text-align: left;
}

.visit-option:hover:not(:disabled) {
  border-color: #c3a29e;
}

.visit-option[aria-checked="true"] {
  border-color: var(--red);
  background: #fffafa;
  box-shadow: 0 0 0 1px var(--red);
}

.visit-option__selector {
  display: block;
  width: 18px;
  height: 18px;
  margin-top: 2px;
  border: 1.5px solid #b9afa8;
  border-radius: 50%;
  background: var(--white);
}

.visit-option[aria-checked="true"] .visit-option__selector {
  border: 5px solid var(--red);
}

.visit-option__icon {
  display: grid;
  width: 35px;
  height: 35px;
  place-items: center;
  border-radius: 9px;
  background: var(--red-soft);
  color: var(--red);
  font-size: 1rem;
}

.visit-option__body {
  display: flex;
  min-width: 0;
  flex-direction: column;
}

.visit-option__body strong {
  font-size: 0.9rem;
}

.visit-option__body small {
  margin: 3px 0 11px;
  color: var(--muted);
  font-size: 0.7rem;
}

.visit-option__body > span {
  color: var(--muted);
  font-size: 0.66rem;
}

.visit-option__price {
  position: absolute;
  right: 17px;
  bottom: 15px;
  display: flex;
  align-items: flex-end;
  flex-direction: column;
  color: var(--red-dark);
  font-size: 0.9rem;
  font-weight: 800;
}

.visit-option__price small {
  color: var(--muted);
  font-size: 0.59rem;
  font-weight: 600;
}

.fee-preview,
.selection-preview {
  margin-top: 18px;
  padding: 13px 16px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: #fcfaf8;
  color: var(--muted);
  font-size: 0.78rem;
}

.fee-preview strong,
.selection-preview strong {
  color: var(--ink);
}

.lock-notice {
  display: flex;
  margin-top: 18px;
  padding: 12px 14px;
  align-items: flex-start;
  gap: 10px;
  border: 1px solid #d9e9de;
  border-radius: 9px;
  background: var(--green-soft);
  color: var(--green);
  font-size: 0.76rem;
}

.lock-notice p {
  margin: 0;
}

.qa-list {
  display: flex;
  flex-direction: column;
  gap: 19px;
}

.question-number {
  display: inline-block;
  margin-right: 6px;
  color: var(--red);
  font-size: 0.67rem;
  letter-spacing: 0.04em;
}

.optional-label {
  margin-left: 5px;
  color: var(--muted);
  font-size: 0.63rem;
  font-weight: 500;
}

.privacy-caption,
.button-caption,
.chat-caption {
  margin: 18px 0 0;
  color: var(--muted);
  font-size: 0.69rem;
}

.privacy-caption span {
  margin-right: 5px;
}

.button-caption {
  margin-top: 8px;
  text-align: center;
}

.slot-options {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 13px;
}

.slot-day {
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #fcfaf8;
}

.slot-day h3 {
  margin-bottom: 3px;
  font-size: 0.85rem;
}

.slot-day > span {
  display: block;
  margin-bottom: 13px;
  color: var(--muted);
  font-size: 0.67rem;
}

.slot-day__times {
  display: grid;
  gap: 8px;
}

.slot-button {
  display: flex;
  min-height: 42px;
  padding: 9px 10px;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
  border: 1px solid #ded6d0;
  border-radius: 8px;
  background: var(--white);
  color: var(--ink);
  font-size: 0.75rem;
  font-weight: 700;
}

.slot-button::after {
  content: "○";
  color: #a99e96;
}

.slot-button:hover:not(:disabled) {
  border-color: #c3a29e;
}

.slot-button[aria-checked="true"] {
  border-color: var(--red);
  background: var(--red-soft);
  color: var(--red-dark);
}

.slot-button[aria-checked="true"]::after {
  content: "●";
  color: var(--red);
}

.booking-summary,
.fee-card {
  padding: 20px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #fcfaf8;
}

.booking-summary h3 {
  margin-bottom: 16px;
  font-size: 0.9rem;
}

.summary-list {
  display: flex;
  margin: 0;
  flex-direction: column;
  gap: 12px;
}

.summary-list > div {
  display: grid;
  grid-template-columns: 90px minmax(0, 1fr);
  gap: 12px;
  font-size: 0.75rem;
}

.summary-list dt {
  color: var(--muted);
}

.summary-list dd {
  margin: 0;
  font-weight: 650;
  text-align: right;
}

.fee-card > div {
  display: flex;
  margin-top: 13px;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  color: var(--muted);
  font-size: 0.78rem;
}

.fee-card > div strong {
  color: var(--ink);
}

.fee-card .fee-card__total {
  margin-top: 17px;
  padding-top: 15px;
  border-top: 1px dashed #d8cec7;
  color: var(--ink);
  font-weight: 800;
}

.fee-card .fee-card__total strong {
  color: var(--red);
  font-size: 1.15rem;
}

.fee-card p {
  margin: 14px 0 0;
  color: var(--muted);
  font-size: 0.66rem;
  text-align: right;
}

.lifecycle-strip {
  display: flex;
  margin-top: 20px;
  align-items: center;
  gap: 10px;
  color: var(--muted);
  font-size: 0.68rem;
}

.status-pill,
.secure-mock-badge {
  display: inline-flex;
  flex: 0 0 auto;
  padding: 6px 10px;
  align-items: center;
  border-radius: 999px;
  font-size: 0.7rem;
  font-weight: 750;
  white-space: nowrap;
}

.status-pill--pending {
  background: var(--amber-soft);
  color: var(--amber);
}

.status-pill--waiting {
  background: var(--amber-soft);
  color: var(--amber);
}

.status-pill--progress {
  background: var(--doctor-soft);
  color: var(--doctor);
}

.status-pill--complete,
.secure-mock-badge {
  background: var(--green-soft);
  color: var(--green);
}

.confirmation-notice {
  display: flex;
  margin-top: 22px;
  padding: 18px;
  align-items: flex-start;
  gap: 14px;
  border: 1px solid #cce2d4;
  border-radius: 12px;
  background: var(--green-soft);
}

.confirmation-notice__icon {
  display: grid;
  flex: 0 0 auto;
  width: 34px;
  height: 34px;
  place-items: center;
  border-radius: 50%;
  background: var(--green);
  color: var(--white);
  font-weight: 800;
}

.confirmation-notice h3 {
  margin: 3px 0 4px;
  color: var(--green);
  font-size: 0.95rem;
}

.confirmation-notice p {
  margin-bottom: 10px;
  color: #52705e;
  font-size: 0.72rem;
}

.reference-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  color: var(--muted);
  font-size: 0.7rem;
}

.reference-row strong {
  color: var(--ink);
  font-size: 0.74rem;
  letter-spacing: 0.04em;
}

.waiting-panel {
  padding: 38px 24px;
  border: 1px solid #eadfd5;
  border-radius: 14px;
  background: #fdf9f4;
  text-align: center;
}

.waiting-symbol {
  display: flex;
  height: 34px;
  margin-bottom: 14px;
  align-items: center;
  justify-content: center;
  gap: 6px;
}

.waiting-symbol span {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: #c69054;
  animation: waiting-pulse 1.5s ease-in-out infinite;
}

.waiting-symbol span:nth-child(2) {
  animation-delay: 180ms;
}

.waiting-symbol span:nth-child(3) {
  animation-delay: 360ms;
}

.waiting-symbol.is-available span {
  background: var(--green);
  animation: none;
}

@keyframes waiting-pulse {
  0%, 70%, 100% { transform: translateY(0); opacity: 0.45; }
  35% { transform: translateY(-6px); opacity: 1; }
}

.waiting-panel h3 {
  margin: 8px 0;
  font-size: 1.1rem;
}

.waiting-panel > p:not(.mini-label) {
  margin-bottom: 20px;
  color: var(--muted);
  font-size: 0.8rem;
}

.operational-note,
.provider-routing-note {
  display: flex;
  margin-top: 20px;
  padding: 13px 15px;
  align-items: flex-start;
  gap: 11px;
  border-left: 3px solid #c98d3d;
  border-radius: 0 8px 8px 0;
  background: var(--amber-soft);
  color: #7b5b2d;
}

.operational-note p,
.provider-routing-note p {
  margin: 0;
  font-size: 0.72rem;
}

.operational-note strong,
.provider-routing-note strong {
  display: block;
  margin-bottom: 2px;
}

.doctor-brief {
  border: 1px solid #d8e3df;
  border-radius: 12px;
  overflow: hidden;
}

.doctor-brief__header {
  display: flex;
  padding: 15px 17px;
  align-items: center;
  gap: 11px;
  border-bottom: 1px solid #dce6e2;
  background: #f5f9f7;
}

.patient-avatar {
  display: grid;
  width: 39px;
  height: 39px;
  place-items: center;
  border-radius: 50%;
  background: #e5efeb;
  color: var(--doctor);
  font-size: 0.72rem;
  font-weight: 800;
}

.doctor-brief__header > div:nth-child(2) {
  display: flex;
  flex: 1;
  flex-direction: column;
}

.doctor-brief__header strong {
  font-size: 0.84rem;
}

.doctor-brief__header span:not(.fiction-tag) {
  color: var(--muted);
  font-size: 0.66rem;
}

.review-brief-list {
  display: grid;
  margin: 0;
  padding: 7px 17px;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  column-gap: 24px;
}

.review-brief-list > div {
  padding: 12px 0;
  border-bottom: 1px solid #edf0ee;
}

.review-brief-list > div:nth-last-child(-n+2) {
  border-bottom: 0;
}

.review-brief-list dt {
  margin-bottom: 4px;
  color: var(--muted);
  font-size: 0.64rem;
  font-weight: 700;
  text-transform: uppercase;
}

.review-brief-list dd {
  margin: 0;
  font-size: 0.76rem;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}

.ai-guidance {
  margin-top: 20px;
  padding: 18px;
  border: 1px solid #d8cbaa;
  border-left: 4px solid #a77d36;
  border-radius: 10px;
  background: #fffaf0;
}

.ai-guidance__label {
  margin-bottom: 8px;
  color: #806026;
  font-size: 0.66rem;
  font-weight: 850;
  letter-spacing: 0.055em;
}

.ai-guidance h3 {
  margin-bottom: 7px;
  color: #5f491f;
  font-size: 0.88rem;
}

.ai-guidance p {
  margin-bottom: 8px;
  color: #695634;
  font-size: 0.76rem;
}

.ai-guidance small {
  display: block;
  color: #806f4f;
  font-size: 0.65rem;
}

.consultation-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 16px;
}

.consultation-layout.has-video {
  grid-template-columns: minmax(240px, 0.85fr) minmax(320px, 1.15fr);
}

.video-panel,
.chat-panel {
  min-width: 0;
  border: 1px solid #d8e3df;
  border-radius: 12px;
  overflow: hidden;
}

.video-panel {
  padding: 13px;
  background: #202825;
  color: #f5f8f6;
}

.video-panel__header {
  display: flex;
  margin-bottom: 12px;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  font-size: 0.59rem;
}

.video-panel__header strong {
  color: #d5e5de;
  letter-spacing: 0.04em;
}

.video-panel__header span {
  color: #9fb1a9;
  text-align: right;
}

.video-tiles {
  display: grid;
  height: calc(100% - 32px);
  grid-template-rows: repeat(2, minmax(150px, 1fr));
  gap: 10px;
}

.video-tile {
  position: relative;
  display: flex;
  min-height: 150px;
  padding: 22px 12px 12px;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  border: 1px solid #43504a;
  border-radius: 9px;
  background: #2d3833;
}

.video-tile--patient {
  background: #35332f;
}

.video-tile__tag {
  position: absolute;
  top: 8px;
  left: 9px;
  color: #b7c6bf;
  font-size: 0.52rem;
  font-weight: 800;
  letter-spacing: 0.05em;
}

.video-tile__avatar {
  display: grid;
  width: 52px;
  height: 52px;
  margin-bottom: 9px;
  place-items: center;
  border-radius: 50%;
  background: #49665b;
  color: #eef6f2;
  font-size: 0.86rem;
  font-weight: 800;
}

.video-tile--patient .video-tile__avatar {
  background: #6c5a4b;
}

.video-tile strong {
  font-size: 0.75rem;
}

.video-tile small {
  margin-top: 3px;
  color: #aebbb5;
  font-size: 0.58rem;
}

.chat-panel {
  display: flex;
  min-height: 395px;
  flex-direction: column;
  background: var(--white);
}

.chat-panel__header {
  display: flex;
  padding: 12px 14px;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  border-bottom: 1px solid #e3eae7;
  background: #f7faf8;
  font-size: 0.68rem;
}

.chat-panel__header > div {
  display: flex;
  align-items: center;
  gap: 7px;
}

.chat-panel__header > span {
  color: var(--muted);
  font-size: 0.58rem;
}

.online-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--green);
}

.chat-log {
  display: flex;
  min-height: 220px;
  max-height: 330px;
  padding: 16px;
  overflow-y: auto;
  flex: 1;
  flex-direction: column;
  gap: 12px;
  background: #fcfdfc;
}

.chat-message {
  display: flex;
  max-width: 86%;
  flex-direction: column;
  gap: 4px;
}

.chat-message--doctor {
  align-self: flex-start;
}

.chat-message--patient {
  align-self: flex-end;
}

.chat-message__meta {
  color: var(--muted);
  font-size: 0.58rem;
}

.chat-message--patient .chat-message__meta {
  text-align: right;
}

.chat-message__bubble {
  padding: 10px 12px;
  border-radius: 5px 12px 12px 12px;
  background: #eaf2ee;
  color: #2f443c;
  font-size: 0.75rem;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}

.chat-message--patient .chat-message__bubble {
  border-radius: 12px 5px 12px 12px;
  background: #f3ece7;
  color: #493e37;
}

.chat-composer {
  display: grid;
  padding: 12px;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: end;
  gap: 9px;
  border-top: 1px solid #e3eae7;
}

.chat-composer textarea {
  min-height: 52px;
  max-height: 120px;
  font-size: 0.75rem;
}

.chat-composer .button {
  min-height: 52px;
  padding: 9px 12px;
  font-size: 0.7rem;
}

.chat-caption {
  margin: 0;
  padding: 0 13px 11px;
  background: var(--white);
  font-size: 0.6rem;
}

.consultation-actions {
  display: flex;
  margin-top: 18px;
  padding-top: 17px;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  border-top: 1px solid #dce6e2;
}

.consultation-actions p {
  margin: 0;
  color: var(--muted);
  font-size: 0.7rem;
}

.consultation-actions p strong {
  display: block;
  color: var(--ink);
}

.outcome-grid {
  align-items: start;
}

.outcome-field {
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: #fdfcf9;
}

.outcome-field--required {
  border-color: #c9dcd5;
  background: #f8fbfa;
}

.outcome-field--full {
  grid-column: 1 / -1;
}

.provider-only-label,
.patient-safe-label {
  display: inline-flex;
  margin-left: 5px;
  padding: 2px 6px;
  border-radius: 999px;
  font-size: 0.55rem;
  font-weight: 750;
  vertical-align: middle;
}

.provider-only-label {
  background: var(--doctor-soft);
  color: var(--doctor);
}

.patient-safe-label {
  background: var(--red-soft);
  color: var(--red-dark);
}

.provider-routing-note {
  border-left-color: var(--doctor);
  background: var(--doctor-soft);
  color: var(--doctor-dark);
}

.completion-hero {
  padding: 10px 0 24px;
  text-align: center;
}

.completion-hero__icon {
  display: grid;
  width: 58px;
  height: 58px;
  margin: 0 auto 17px;
  place-items: center;
  border-radius: 50%;
  background: var(--green-soft);
  color: var(--green);
  font-size: 1.5rem;
  font-weight: 800;
}

.completion-hero > p:not(.stage-heading__label) {
  margin-bottom: 13px;
  color: var(--muted);
  font-size: 0.82rem;
}

.patient-advice-card {
  max-width: 680px;
  margin: 0 auto;
  padding: 23px;
  border: 1px solid #ead7d2;
  border-radius: 13px;
  background: #fffaf8;
}

.patient-advice-card h3 {
  margin: 5px 0 14px;
  font-size: 0.95rem;
}

.patient-advice-text {
  color: #493d38;
  font-size: 0.86rem;
  line-height: 1.7;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}

.completion-status {
  display: flex;
  max-width: 680px;
  margin: 18px auto 0;
  padding: 15px 17px;
  align-items: flex-start;
  gap: 11px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: #fcfaf8;
  color: var(--green);
}

.completion-status strong {
  display: block;
  margin-bottom: 3px;
  color: var(--ink);
  font-size: 0.78rem;
}

.completion-status p {
  margin: 0;
  color: var(--muted);
  font-size: 0.7rem;
}

.reference-row--completion {
  max-width: 680px;
  margin: 18px auto 0;
  padding-top: 15px;
  border-top: 1px solid var(--line);
}

.validation-message {
  margin-top: 15px;
  padding: 12px 15px;
  border: 1px solid #ecc8c4;
  border-radius: 9px;
  background: var(--red-soft);
  color: var(--red-dark);
  font-size: 0.78rem;
  font-weight: 650;
}

.navigation-controls {
  display: grid;
  margin-top: 18px;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 16px;
}

.navigation-hint {
  color: var(--muted);
  font-size: 0.7rem;
  text-align: center;
}

.site-footer {
  display: flex;
  width: min(1220px, calc(100% - 40px));
  margin: 0 auto;
  padding: 22px 0 30px;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 0.7rem;
}

@media (max-width: 1050px) {
  .simulation-layout {
    grid-template-columns: 235px minmax(0, 1fr);
    gap: 18px;
  }

  .stage-card {
    padding: 25px 23px;
  }

  .role-banner {
    margin: -25px -23px 23px;
    padding-right: 23px;
    padding-left: 23px;
  }

  .visit-options,
  .slot-options {
    grid-template-columns: 1fr;
  }

  .slot-day__times {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .consultation-layout.has-video {
    grid-template-columns: 1fr;
  }

  .video-tiles {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    grid-template-rows: auto;
  }
}

@media (max-width: 820px) {
  .mock-banner {
    flex-wrap: wrap;
  }

  .site-header__inner {
    min-height: 72px;
  }

  .brand__descriptor,
  .brand__divider,
  .demo-badge {
    display: none;
  }

  .page-shell {
    padding-top: 30px;
  }

  .intro {
    align-items: flex-start;
    flex-direction: column;
    gap: 20px;
  }

  .simulation-layout {
    grid-template-columns: 1fr;
  }

  .journey-card {
    position: static;
    padding: 15px 12px 12px;
  }

  .step-list {
    padding-bottom: 6px;
    overflow-x: auto;
    flex-direction: row;
    scroll-snap-type: x proximity;
  }

  .step-list li {
    flex: 0 0 165px;
    scroll-snap-align: start;
  }

  .step-button__text small {
    white-space: normal;
  }

  .safety-note {
    margin-top: 8px;
  }
}

@media (max-width: 600px) {
  .mock-banner {
    padding: 9px 12px;
    font-size: 0.69rem;
  }

  .mock-banner__icon {
    display: none;
  }

  .site-header__inner,
  .page-shell,
  .site-footer {
    width: min(100% - 24px, 1220px);
  }

  .back-link,
  .brand__name {
    font-size: 0.75rem;
  }

  .brand__mark {
    width: 29px;
    height: 29px;
    font-size: 1rem;
  }

  .intro {
    margin-bottom: 22px;
  }

  .demo-actions {
    width: 100%;
  }

  .demo-actions .button {
    flex: 1;
  }

  .stage-card {
    min-height: 0;
    padding: 22px 17px;
  }

  .role-banner {
    margin: -22px -17px 21px;
    padding: 10px 17px;
    flex-wrap: wrap;
  }

  .role-banner > span:last-child {
    width: 100%;
    margin-left: 15px;
  }

  .stage-heading {
    align-items: flex-start;
    flex-direction: column;
    gap: 12px;
  }

  .stage-heading .button {
    align-self: stretch;
  }

  .setup-grid,
  .brief-row,
  .payment-grid,
  .outcome-grid,
  .review-brief-list {
    grid-template-columns: 1fr;
  }

  .review-brief-list > div:nth-last-child(-n+2) {
    border-bottom: 1px solid #edf0ee;
  }

  .review-brief-list > div:last-child {
    border-bottom: 0;
  }

  .visit-option {
    min-height: 150px;
  }

  .slot-day__times {
    grid-template-columns: 1fr 1fr;
  }

  .lifecycle-strip {
    align-items: flex-start;
    flex-direction: column;
  }

  .waiting-panel {
    padding: 30px 15px;
  }

  .chat-panel__header {
    align-items: flex-start;
    flex-direction: column;
    gap: 4px;
  }

  .chat-composer {
    grid-template-columns: 1fr;
  }

  .chat-composer .button {
    min-height: 42px;
  }

  .consultation-actions {
    align-items: stretch;
    flex-direction: column;
  }

  .outcome-field--full {
    grid-column: auto;
  }

  .navigation-controls {
    grid-template-columns: 1fr 1fr;
    gap: 10px;
  }

  .navigation-hint {
    grid-column: 1 / -1;
    grid-row: 1;
  }

  .navigation-controls .button {
    width: 100%;
  }

  .site-footer {
    align-items: flex-start;
    flex-direction: column;
    gap: 5px;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    scroll-behavior: auto !important;
    transition-duration: 0.01ms !important;
  }
}

/* Current live medical brief, scoped so every other mock stage is unchanged. */
#stage-brief .brief-form {
  min-width: 0;
}

#stage-brief .form-group {
  min-width: 0;
  margin-bottom: 20px;
}

#stage-brief .form-group > label:first-child {
  display: block;
  margin-bottom: 8px;
  color: var(--ink);
  font-size: 15px;
  font-weight: 500;
}

#stage-brief input,
#stage-brief select,
#stage-brief textarea {
  width: 100%;
  min-width: 0;
  padding: 12px 15px;
  border: 1px solid #dedbd8;
  border-radius: 9px;
  background-color: var(--white);
  color: var(--ink);
  font-size: 15px;
  transition: border-color 150ms ease, box-shadow 150ms ease;
}

#stage-brief input:focus,
#stage-brief select:focus,
#stage-brief textarea:focus {
  border-color: var(--red);
  outline: none;
  box-shadow: 0 0 0 2px rgba(185, 43, 39, 0.2);
}

#stage-brief textarea {
  min-height: 94px;
}

#stage-brief .q-grid {
  display: grid;
  min-width: 0;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 0 15px;
}

#stage-brief .q-grid .span-2 {
  grid-column: 1 / -1;
}

#stage-brief .section-header {
  margin: 25px 0 15px;
  padding-bottom: 10px;
  border-bottom: 1px solid #dedbd8;
  color: var(--red);
  font-size: 17px;
  font-weight: 600;
}

#stage-brief .section-header:first-child {
  margin-top: 0;
}

#stage-brief .required-star {
  margin-left: 4px;
  color: var(--red);
}

#stage-brief .field-error input,
#stage-brief .field-error select,
#stage-brief .field-error textarea {
  border-color: var(--red);
}

#stage-brief .collapsible-card {
  margin: 18px 0;
  border: 1px solid #dedbd8;
  border-radius: 9px;
  background: var(--white);
  overflow: hidden;
}

#stage-brief .collapsible-card.hidden {
  display: none;
}

#stage-brief .collapsible-header {
  display: flex;
  width: 100%;
  margin: 0;
  padding: 12px 15px;
  align-items: center;
  gap: 8px;
  border: 0;
  background: transparent;
  color: var(--red);
  font: inherit;
  font-weight: 600;
  text-align: left;
  user-select: none;
}

#stage-brief .collapsible-header .caret {
  margin-left: auto;
  font-size: 12px;
  transition: transform 0.2s ease;
}

#stage-brief .collapsible-header[aria-expanded="true"] .caret {
  transform: rotate(180deg);
}

#stage-brief .collapsible-card .q-grid {
  display: none;
  padding: 0 15px 15px;
}

#stage-brief .collapsible-card.open .q-grid {
  display: grid;
}

#stage-brief .boolean-options {
  display: flex;
  flex-wrap: wrap;
  gap: 4px 22px;
}

#stage-brief .checkbox-group {
  display: flex;
  margin-bottom: 10px;
  align-items: center;
}

#stage-brief .checkbox-group input {
  width: auto;
  min-height: 0;
  margin: 0 10px 0 0;
  padding: 0;
}

#stage-brief .checkbox-group label {
  margin-bottom: 0;
  font-size: 15px;
  font-weight: 400;
}

#stage-brief .muted-note,
#stage-brief .draft-note {
  color: var(--muted);
  font-size: 14px;
}

#stage-brief .form-group .muted-note {
  margin: 7px 0 0;
}

#stage-brief .height-unit {
  width: auto;
  min-width: 94px;
  margin: 8px 0 0 8px;
}

#stage-brief .height-unit-label {
  position: absolute;
}

#stage-brief .height-conv {
  display: inline-block;
  margin: 8px 0 0 8px;
}

#stage-brief .action-buttons {
  display: flex;
  margin-top: 30px;
  justify-content: space-between;
  gap: 10px;
}

#stage-brief .action-buttons .btn {
  padding: 10px 20px;
  font-size: 15px;
  font-weight: 500;
}

#stage-brief .draft-note {
  margin: 10px 0 0;
}

#stage-schedule details.brief-review {
  min-width: 0;
  margin: 0 0 20px;
  padding: 12px 15px;
  border: 1px solid #dedbd8;
  border-radius: 9px;
  background: var(--white);
}

#stage-schedule details.brief-review summary {
  color: var(--red);
  font-weight: 600;
  cursor: pointer;
}

#stage-schedule #briefReviewList,
#stage-review .review-brief-list {
  min-width: 0;
}

#stage-schedule .qa-item,
#stage-review .qa-item {
  margin: 12px 0;
}

#stage-schedule .qa-question,
#stage-review .qa-question {
  font-size: 14px;
  font-weight: 600;
}

#stage-schedule .qa-answer,
#stage-review .qa-answer {
  color: var(--muted);
  font-size: 14px;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}

#stage-schedule .review-section,
#stage-review .review-section {
  margin: 18px 0 8px;
  padding-bottom: 6px;
  border-bottom: 1px solid #dedbd8;
  color: var(--red);
  font-size: 14px;
  font-weight: 600;
}

#stage-review .review-brief-list {
  display: block;
  max-height: 650px;
  margin: 0;
  padding: 7px 17px;
  overflow-y: auto;
}

#stage-review .review-brief-list > .review-section {
  padding: 0 0 6px;
  border-bottom: 1px solid #dce6e2;
  color: var(--doctor);
}

#stage-review .review-brief-list > .qa-item {
  margin: 0;
  padding: 12px 0;
  border-bottom: 1px solid #edf0ee;
}

#stage-review .review-brief-list > .qa-item:last-child {
  border-bottom: 0;
}

#stage-review .review-brief-list .qa-question {
  margin-bottom: 4px;
}

@media (max-width: 768px) {
  #stage-brief .q-grid,
  #stage-brief .collapsible-card.open .q-grid {
    grid-template-columns: minmax(0, 1fr);
  }

  #stage-brief .q-grid .span-2 {
    grid-column: auto;
  }

  #stage-brief .height-unit {
    margin-left: 0;
  }

  #stage-brief .height-conv {
    display: block;
    margin-left: 0;
  }
}

@media (max-width: 576px) {
  #stage-brief .action-buttons {
    flex-direction: column;
  }

  #stage-brief .action-buttons .btn {
    width: 100%;
  }

  #stage-schedule details.brief-review {
    padding: 11px 12px;
  }
}
