.oscs-page {
  box-sizing: border-box;
  width: 100%;
  max-width: 1170px;
  margin-right: auto;
  margin-left: auto;
  padding: 2.5rem clamp(1rem, 4vw, 1.5rem) 4rem;
  background: #fff;
}

body:has(.oscs-page),
body:has(.oscs-page) .inner-section {
  background: #fff;
}

.oscs-app,
.oscs-gate,
.oscs-modal {
  --oscs-purple: #5233ee;
  --oscs-ink: #1b0330;
  box-sizing: border-box;
  color: var(--oscs-ink);
  font-family: BrandonText, "Brandon Text", sans-serif;
}

.oscs-app *,
.oscs-gate *,
.oscs-modal * {
  box-sizing: border-box;
}

.oscs-app {
  margin: 0 0 2rem;
  padding: 0;
  background: transparent;
}

.oscs-intro {
  position: static;
  top: auto;
  z-index: auto;
  margin: 0 0 1.5rem;
  overflow: visible;
}

.oscs-app .oscs-title,
.oscs-gate .oscs-title {
  margin: 0;
  color: #121212;
  font-family: BrandonText, "Brandon Text", sans-serif;
  font-size: clamp(1.75rem, 3.5vw, 2.5rem);
  font-weight: 400;
  line-height: 1.15;
}

.oscs-intro-text {
  max-width: 40rem;
  margin: 0.55rem 0 0;
  color: #4d4d4d;
  font-family: "BrandonText-Regular", BrandonText, "Brandon Text", sans-serif;
  font-size: clamp(0.95rem, 0.9rem + 0.2vw, 1.05rem);
  font-weight: 400;
  line-height: 1.5;
}

.oscs-trending {
  margin: 0 0 1.5rem;
  padding: 0.85rem 1rem 0.7rem;
  border-radius: 18px;
  background: #fff;
}

.oscs-trending-kicker {
  margin: 0 0 0.45rem;
  color: #121212;
  font-family: BrandonText, "Brandon Text", sans-serif;
  font-size: 1rem;
  font-weight: 500;
  line-height: 1.2;
}

.oscs-trending ol {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  margin: 0;
  padding: 0;
  list-style: none;
}

.oscs-trending li {
  margin: 0;
}

.oscs-trending .oscs-launch {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 0.75rem;
  width: 100%;
  margin: 0;
  padding: 0.45rem 0.15rem;
  border: 0;
  background: transparent;
  color: #121212;
  font-family: "BrandonText-Regular", BrandonText, "Brandon Text", sans-serif;
  font-size: 1rem;
  line-height: 1.3;
  text-align: left;
  cursor: pointer;
}

.oscs-trending .oscs-launch small {
  flex: 0 0 auto;
  color: #6b6b6b;
  font-size: 0.85rem;
}

.oscs-gate .oscs-intro {
  margin-bottom: 1rem;
}

.oscs-gate .oscs-intro-text {
  margin: 0.55rem 0 0;
  color: #4d4d4d;
}

.oscs-app [hidden],
.oscs-modal [hidden] {
  display: none !important;
}

.oscs-legend,
.oscs-gate h2 {
  margin: 0 0 1.15rem;
  color: #1a1a1a;
  font-size: 1.35rem;
  font-weight: 700;
  line-height: 1.2;
}

.oscs-legend-row {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  margin: 0 0 1.15rem;
}

.oscs-legend-row .oscs-legend {
  margin: 0;
}

.oscs-info-mark {
  display: inline-flex;
  flex: 0 0 auto;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  border: 1.5px solid #d5d0e6;
  border-radius: 999px;
  background: #fff;
  color: #5233ee;
  font-family: Georgia, "Times New Roman", serif;
  font-size: 15px;
  font-style: italic;
  font-weight: 700;
  line-height: 1;
  cursor: pointer;
}

.oscs-info-mark:hover,
.oscs-info-mark:focus-visible {
  border-color: #5233ee;
  background: #efeaff;
}

.oscs-tools {
  margin: 0 0 1.35rem;
}

.oscs-switch {
  display: inline-flex;
  align-items: center;
  gap: 0.75rem;
  max-width: 36rem;
  cursor: pointer;
}

.oscs-switch input {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
}

.oscs-switch-track {
  position: relative;
  flex: 0 0 auto;
  width: 44px;
  height: 26px;
  border-radius: 999px;
  background: #e4e0f2;
}

.oscs-switch-track::after {
  content: "";
  position: absolute;
  top: 3px;
  left: 3px;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: #fff;
  box-shadow: 0 1px 2px rgba(27, 3, 48, 0.18);
  transition: transform 0.15s ease;
}

.oscs-switch input:checked + .oscs-switch-track {
  background: #5233ee;
}

.oscs-switch input:checked + .oscs-switch-track::after {
  transform: translateX(18px);
}

.oscs-switch input:focus-visible + .oscs-switch-track {
  outline: 3px solid #ffbf47;
  outline-offset: 3px;
}

.oscs-switch-copy {
  display: flex;
  flex-direction: column;
  gap: 0.1rem;
}

.oscs-switch-text {
  color: #1a1a1a;
  font-weight: 700;
}

.oscs-switch-note {
  color: #5c5670;
  font-size: 0.95rem;
  font-weight: 400;
}

.oscs-sub-label {
  margin: 0 0 0.75rem;
  color: #1a1a1a;
  font-size: 1.05rem;
  font-weight: 700;
}

.oscs-random {
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
  margin-top: 1.35rem;
}

.oscs-random-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.65rem 0.85rem;
}

.oscs-random-label {
  margin: 0;
  color: #1a1a1a;
  font-weight: 700;
}

.oscs-random-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.oscs-history {
  margin: 2.75rem 0 0;
}

.oscs-history .oscs-legend {
  margin: 0 0 0.35rem;
}

.oscs-history-count {
  margin: 0 0 1rem;
  color: #3c3552;
  font-size: 1rem;
  font-weight: 400;
}

.oscs-history .oscs-table-wrap {
  margin-top: 0;
}

.oscs-history-table th:last-child,
.oscs-history-table td:last-child {
  width: 6.5rem;
  text-align: right;
}

.oscs-history-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  margin-top: 0.95rem;
}

.oscs-history-tab {
  min-width: 2.4rem;
  padding: 0.35rem 0.8rem;
  border: 1.5px solid #d5d5d5;
  border-radius: 999px;
  background: #fff;
  color: #1a1a1a;
  font-family: "BrandonText-Regular", sans-serif;
  font-weight: 400;
  cursor: pointer;
}

.oscs-history-tab[aria-pressed="true"] {
  border-color: #b5b5b5;
  background: #f2f2f2;
}

.oscs-gate p {
  margin: 0;
  color: #3c3552;
}

.oscs-gate {
  margin: 2rem 0;
  padding: clamp(1rem, 3vw, 2rem);
  border-radius: 16px;
  background: #f9f9f9;
}

.oscs-gate a {
  color: var(--oscs-purple);
}

.oscs-mains,
.oscs-subs {
  display: flex;
  flex-wrap: wrap;
  gap: 0.85rem 0.9rem;
}

.oscs-panels:not(:has(.oscs-block:not([hidden]))) {
  display: none;
}

.oscs-block {
  margin-top: 0.95rem;
}

.oscs-chip,
.oscs-sub,
.oscs-launch,
.oscs-random-go,
.oscs-start,
.oscs-send,
.oscs-complete,
.oscs-mute {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1.5px solid #d5d5d5;
  border-radius: 999px;
  background: #fff;
  color: #1f1f1f;
  font-family: inherit;
  font-size: 1rem;
  font-weight: 600;
  line-height: 1.2;
  cursor: pointer;
}

.oscs-chip,
.oscs-sub {
  padding: 0.72rem 1.35rem;
}

.oscs-chip:hover,
.oscs-sub:hover,
.oscs-launch:hover,
.oscs-random-go:hover {
  border-color: #bdbdbd;
  background: #fafafa;
}

.oscs-chip[aria-pressed="true"],
.oscs-sub[aria-pressed="true"],
.oscs-chip[aria-pressed="true"]:hover,
.oscs-sub[aria-pressed="true"]:hover {
  border-color: rgb(70, 170, 117);
  background: rgb(70, 170, 117);
  color: #fff;
}

.oscs-chip:focus-visible,
.oscs-sub:focus-visible,
.oscs-launch:focus-visible,
.oscs-random-go:focus-visible,
.oscs-start:focus-visible,
.oscs-send:focus-visible,
.oscs-complete:focus-visible,
.oscs-mute:focus-visible,
.oscs-close:focus-visible,
.oscs-message:focus-visible {
  outline: 3px solid #ffbf47;
  outline-offset: 3px;
}

.oscs-table-wrap {
  margin-top: 1.5rem;
  overflow-x: auto;
  border-radius: 12px;
  background: #fff;
}

.oscs-table {
  width: 100%;
  border-collapse: collapse;
}

.oscs-table th,
.oscs-table td {
  padding: 0.85rem 0.75rem;
  border-bottom: 1px solid #ece8f8;
  text-align: left;
  vertical-align: middle;
}

.oscs-table th {
  color: #5233ee;
  font-weight: 700;
}

.oscs-done {
  white-space: nowrap;
}

.oscs-done-tick {
  width: 16px;
  height: 16px;
  margin-right: 0.4rem;
  vertical-align: -3px;
}

.oscs-done-count {
  color: #353535;
  font-size: 0.95rem;
}

.oscs-mark-done {
  flex: 0 0 auto;
  min-height: 36px;
  border: 1px solid #d9d6e5;
  border-radius: 999px;
  background: #f5f6f9;
  color: #1a1a1a;
  padding: 0.45rem 0.9rem;
}

.oscs-mark-done:hover,
.oscs-mark-done:focus-visible {
  border-color: #46aa75;
  background: #e7f6ee;
  color: #1a1a1a;
}

.oscs-mark-done.is-done {
  border-color: #46aa75;
  background: #46aa75;
  color: #fff;
}

.oscs-mark-done:focus-visible {
  outline: 3px solid #ffbf47;
  outline-offset: 3px;
}

.oscs-launch,
.oscs-random-go,
.oscs-start,
.oscs-send,
.oscs-complete {
  min-height: 40px;
  border-color: var(--oscs-purple);
  background: var(--oscs-purple);
  color: #fff;
  padding: 0.45rem 1rem;
}

.oscs-launch:hover,
.oscs-random-go:hover,
.oscs-start:hover,
.oscs-send:hover,
.oscs-complete:hover,
.oscs-launch:focus-visible,
.oscs-random-go:focus-visible,
.oscs-start:focus-visible,
.oscs-send:focus-visible,
.oscs-complete:focus-visible {
  border-color: #431fd4;
  background: #431fd4;
  color: #fff;
}

.oscs-start:disabled,
.oscs-send:disabled,
.oscs-complete:disabled,
.oscs-mute:disabled,
.oscs-message:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

.oscs-modal {
  position: fixed;
  z-index: 100000;
  inset: 0;
  overflow: hidden;
  background: #f6f7fb;
  color: #1b0330;
}

.oscs-modal.is-open {
  animation: oscs-screen 0.32s ease both;
}

.oscs-modal.is-closing {
  animation: oscs-screen-out 0.62s ease both;
}

.oscs-modal.is-open .oscs-card {
  animation: oscs-pop 0.5s cubic-bezier(0.16, 1, 0.3, 1) both;
}

.oscs-modal.is-closing .oscs-card {
  animation: oscs-pop-out 0.5s cubic-bezier(0.16, 1, 0.3, 1) both;
}

/* The site header sticks below the admin bar from 601px up. Leave that offset
   off while this station covers the page, so the popup is not pushed down. */
@media screen and (min-width: 601px) {
  body:has(#oscs-modal:not([hidden])) header,
  body:has(#oscs-modal:not([hidden])).admin-bar header {
    top: 0;
  }
}

.oscs-shell {
  display: flex;
  flex-direction: column;
  height: 100%;
  min-height: 0;
}

.oscs-bar {
  position: static;
  top: auto;
  z-index: auto;
  display: flex;
  align-items: center;
  gap: 0.75rem;
  min-height: 60px;
  padding: 0.7rem 1.35rem;
  border-bottom: 1px solid #eceef3;
  background: #fff;
}

.oscs-pill {
  flex: 0 0 auto;
  margin: 0;
  padding: 0.22rem 0.65rem;
  border-radius: 999px;
  background: #efeaff;
  color: #5b45e0;
  font-size: 0.8rem;
  font-weight: 600;
}

.oscs-bar-title {
  flex: 1 1 auto;
  min-width: 0;
  margin: 0;
  color: #1a1230;
  font-size: 18px;
  font-weight: 600;
  line-height: 1.3;
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  overflow: hidden;
}

.oscs-timer {
  flex: 0 0 auto;
  margin: 0;
  min-width: 3.2rem;
  color: #1a1230;
  font-variant-numeric: tabular-nums;
  font-weight: 700;
}

.oscs-timer.is-up {
  color: #9b2c2c;
}

.oscs-complete {
  flex: 0 0 auto;
  min-height: 36px;
  border-radius: 999px;
}

.oscs-close {
  display: inline-flex;
  flex: 0 0 auto;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  border: 0;
  border-radius: 999px;
  background: transparent;
  color: #6b7280;
  cursor: pointer;
}

.oscs-close:hover,
.oscs-close:focus-visible {
  background: #f4f5f8;
  color: #1a1230;
}

.oscs-body {
  flex: 1 1 auto;
  min-height: 0;
  padding: 1rem 1.15rem 1.15rem;
}

.oscs-work {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 2fr);
  grid-template-rows: minmax(0, 1fr);
  gap: 1rem;
  height: 100%;
  min-height: 0;
}

.oscs-work:not(:has(.oscs-panel .oscs-card:not([hidden]))) {
  grid-template-columns: minmax(0, 1fr);
}

.oscs-work:not(:has(.oscs-panel .oscs-card:not([hidden]))) .oscs-panel {
  display: none;
}

.oscs-panel {
  display: flex;
  flex-direction: column;
  min-width: 0;
  min-height: 0;
  height: 100%;
}

.oscs-panel > .oscs-card {
  flex: 1 1 auto;
  min-height: 0;
}

.oscs-card {
  border-radius: 18px;
  background: #fff;
  box-shadow: 0 16px 40px rgba(28, 27, 52, 0.08), 0 1px 2px rgba(28, 27, 52, 0.04);
}

.oscs-work:has(.oscs-panel .oscs-card:not([hidden])) .oscs-card-footer {
  display: none;
}

.oscs-brief,
.oscs-stage,
.oscs-debrief {
  display: flex;
  flex-direction: column;
  min-width: 0;
  min-height: 0;
  margin: 0;
  padding: 1.15rem 1.25rem;
  overflow: hidden;
}

.oscs-stage,
.oscs-debrief {
  height: 100%;
}

.oscs-brief {
  align-self: start;
  height: auto;
  max-height: 100%;
}

.oscs-brief-title {
  flex: 0 0 auto;
  margin: 0 0 0.75rem;
  color: #5233ee;
  font-size: 0.95rem;
  font-weight: 700;
}

.oscs-task {
  flex: 1 1 auto;
  min-height: 0;
  overflow: auto;
}

.oscs-task a:has(img),
.oscs-task img {
  cursor: zoom-in;
}

.oscs-task p {
  margin: 0 0 0.8rem;
}

.oscs-task ul,
.oscs-task ol {
  margin: 0 0 1rem 1.2rem;
}

.oscs-card-footer {
  display: flex;
  justify-content: flex-end;
  margin-top: 1.25rem;
}

.oscs-start {
  min-height: 44px;
  border-radius: 999px;
  padding: 0.65rem 1.25rem;
}

.oscs-send {
  min-height: 44px;
  border-radius: 17px;
  padding: 0.65rem 1.25rem;
}

.oscs-waiting {
  margin: 0;
  color: #5c5670;
}

.oscs-phases {
  display: grid;
  flex: 0 0 auto;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 0.75rem;
  margin: 0 0 0.9rem;
}

.oscs-stage.is-split .oscs-phases {
  flex: 1 1 auto;
  min-height: 0;
  margin-bottom: 0;
  grid-template-columns: minmax(0, 1.28fr) minmax(0, 0.82fr);
}

.oscs-stage.is-split .oscs-phases:has(.oscs-phase.is-examiner.is-current) {
  grid-template-columns: minmax(0, 0.82fr) minmax(0, 1.28fr);
}

.oscs-phase {
  display: flex;
  flex-direction: column;
  min-width: 0;
  min-height: 0;
  margin: 0;
  padding: 0.8rem 0.95rem 0.85rem;
  border: 1.5px solid #e6e4ee;
  border-radius: 14px;
  background: #f7f7fa;
  color: #6d6780;
}

.oscs-phase-label-voice {
  display: none;
}

.oscs-phase .oscs-chat {
  flex: 1 1 auto;
  min-height: 0;
  margin-top: 0.75rem;
}

.oscs-phase:not(.is-current) .oscs-composer,
.oscs-phase.is-done .oscs-composer {
  display: none;
}

.oscs-phase.is-current .oscs-phase-move,
.oscs-phase.is-examiner.is-current .oscs-phase-warn,
.oscs-phases.is-voice .oscs-phase-warn,
.oscs-phases:not(.is-voice) .oscs-phase-move {
  display: none;
}

.oscs-phases:not(.is-voice) .oscs-phase.is-examiner:not(.is-current) {
  cursor: pointer;
}

.oscs-phase-warn {
  margin: 0.7rem 0 0;
  padding: 0.65rem 0.75rem;
  border-radius: 10px;
  background: #fff4d6;
  color: #6a4500;
  font-size: 0.95rem;
  font-weight: 700;
  line-height: 1.4;
}

.oscs-stage.is-split .oscs-phase .oscs-log {
  min-height: 140px;
  border-radius: 12px;
  background: #fff;
}

button.oscs-phase-move {
  align-self: flex-start;
  margin-top: 0.75rem;
  min-height: 44px;
  border: 0;
  border-radius: 999px;
  padding: 0.65rem 1rem;
  background: #fff;
  color: #5233ee;
  font-family: BrandonText, "Brandon Text", sans-serif;
  font-size: 0.95rem;
  font-weight: 700;
  line-height: 1.3;
  text-align: left;
  cursor: pointer;
}

button.oscs-phase-move:hover,
button.oscs-phase-move:focus-visible {
  background: #efeaff;
}

.oscs-phase-finish {
  display: none;
}

.oscs-phases.is-voice .oscs-phase-finish,
.oscs-voice-finish:not([hidden]) {
  display: block;
}

.oscs-voice-finish {
  flex: 0 0 auto;
  margin: 0 0 0.75rem;
}

.oscs-voice-finish .oscs-phase-say {
  color: #5233ee;
}

.oscs-phases.is-voice .oscs-phase.is-examiner .oscs-phase-text:not(.oscs-phase-finish),
.oscs-phases.is-voice .oscs-chat,
.oscs-phases.is-voice .oscs-composer,
.oscs-phases.is-voice .oscs-phase-move,
.oscs-phases.is-voice .oscs-phase-label-text {
  display: none;
}

.oscs-phases.is-voice .oscs-phase-label-voice {
  display: inline;
}

.oscs-phases.is-voice .oscs-phase.is-examiner:not(.is-current) {
  cursor: pointer;
}

.oscs-orb.oscs-orb-idle {
  display: none;
}

.oscs-phases.is-voice .oscs-phase:not(.is-current) > .oscs-orb-idle {
  display: grid;
  flex: 1 1 auto;
  width: 160px;
  height: 160px;
  margin: 0.75rem auto;
}

.oscs-phases.is-voice .oscs-orb-idle .oscs-orb-core {
  width: 112px;
  height: 112px;
  background: #d5d3dc;
  box-shadow: none;
  animation: none;
  transform: none;
}

.oscs-phase > .oscs-voice {
  flex: 1 1 auto;
  width: 100%;
  margin-top: 0.35rem;
  padding: 0.25rem 0 0.35rem;
}

.oscs-phase > .oscs-voice .oscs-orb {
  width: 168px;
  height: 168px;
}

.oscs-phase > .oscs-voice .oscs-orb-core {
  width: 124px;
  height: 124px;
}

.oscs-phase-title {
  margin: 0 0 0.3rem;
  color: #6d6780;
  font-family: BrandonText, "Brandon Text", sans-serif;
  font-size: 0.95rem;
  font-weight: 700;
  line-height: 1.3;
}

.oscs-phase-text {
  margin: 0;
  font-size: 0.98rem;
  line-height: 1.4;
}

.oscs-phase-say {
  font-weight: 700;
}

.oscs-phase.is-current {
  border-color: #5233ee;
  background: #f4f0ff;
  color: #1b0330;
  box-shadow: 0 0 0 4px rgba(82, 51, 238, 0.12);
}

.oscs-phase.is-current .oscs-phase-title,
.oscs-phase.is-current .oscs-phase-say {
  color: #5233ee;
}

.oscs-phase.is-examiner.is-current {
  border-color: #c4922a;
  background: #fff8e8;
  box-shadow: 0 0 0 4px rgba(196, 146, 42, 0.18);
  animation: oscs-phase-in 0.45s ease;
}

.oscs-phase.is-examiner.is-current .oscs-phase-title {
  color: #8a5a00;
}

.oscs-phase.is-done {
  background: #f7f7fa;
  box-shadow: none;
}

@keyframes oscs-phase-in {
  from {
    box-shadow: 0 0 0 0 rgba(196, 146, 42, 0);
  }
  to {
    box-shadow: 0 0 0 4px rgba(196, 146, 42, 0.18);
  }
}

.oscs-loading {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.9rem;
  min-height: 180px;
  color: #3c3552;
}

.oscs-loading p {
  margin: 0;
  font-size: 1.05rem;
  text-align: center;
}

.oscs-debrief-body > .oscs-loading {
  height: 100%;
}

.oscs-spinner {
  width: 36px;
  height: 36px;
  border: 3px solid #e4dff8;
  border-top-color: #5233ee;
  border-radius: 50%;
  animation: oscs-spin 0.8s linear infinite;
}

@keyframes oscs-spin {
  to {
    transform: rotate(360deg);
  }
}

.oscs-chat {
  display: flex;
  flex: 1 1 auto;
  flex-direction: column;
  min-height: 0;
}

.oscs-log {
  display: flex;
  flex: 1 1 auto;
  flex-direction: column;
  min-height: 0;
  overflow: auto;
  margin-bottom: 0.75rem;
  padding-right: 0.25rem;
}

.oscs-thread {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  margin-top: auto;
  padding: 0.45rem 0.7rem 0.35rem;
}

.oscs-bubble,
.oscs-message {
  font-family: "BrandonText-Regular", sans-serif;
  font-size: 17px;
  font-weight: 400;
  font-style: normal;
  line-height: 1.45;
}

.oscs-bubble {
  max-width: min(38rem, 92%);
  margin: 0;
  padding: 0.75rem 0.95rem;
  border-radius: 16px;
  white-space: pre-wrap;
}

.oscs-bubble.is-patient {
  align-self: flex-start;
  background: #f4f5f8;
  color: #1a1230;
}

.oscs-bubble.is-student {
  align-self: flex-end;
  background: #efeaff;
  color: #2a1868;
}

.oscs-bubble.is-examiner {
  align-self: stretch;
  max-width: 100%;
  border: 1.5px solid #e4d2a4;
  background: #fff8e8;
  color: #3d2e12;
}

.oscs-bubble.is-arriving {
  animation: oscs-fade-up 0.45s cubic-bezier(0.16, 1, 0.3, 1) both;
}

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

.oscs-bubble.is-examiner::before {
  content: "Examiner";
  display: block;
  margin-bottom: 0.3rem;
  color: #8a5a00;
  font-family: BrandonText, "Brandon Text", sans-serif;
  font-size: 0.95rem;
}

.oscs-chat-media {
  align-self: flex-start;
  display: block;
  width: min(280px, 100%);
  margin: 0;
  padding: 0;
  border: 1.5px solid #e4d2a4;
  border-radius: 16px;
  background: #fff8e8;
  overflow: hidden;
  cursor: zoom-in;
}

.oscs-chat-media img {
  display: block;
  width: 100%;
  max-height: 180px;
  object-fit: contain;
  background: #111;
}

.oscs-chat-media:not(:has(img)) {
  padding: 0.75rem 0.95rem;
  color: #3d2e12;
  font-family: BrandonText, "Brandon Text", sans-serif;
  text-align: left;
}

.oscs-with {
  margin: 0 0 0.75rem;
  color: #8a5a00;
  font-family: BrandonText, "Brandon Text", sans-serif;
}

.oscs-quit {
  width: min(520px, calc(100vw - 2rem));
  margin: auto;
  padding: 1.5rem 1.5rem 1.25rem;
  border: 0;
  border-radius: 16px;
  background: #fff;
  color: #1b0330;
  font-family: BrandonText, "Brandon Text", sans-serif;
}

.oscs-quit::backdrop {
  background: rgba(27, 3, 48, 0.45);
}

.oscs-quit h3 {
  margin: 0 0 0.75rem;
  color: #20124d;
  font-family: BrandonText, "Brandon Text", sans-serif;
  font-size: 1.25rem;
  font-weight: 400;
  line-height: 1.3;
}

.oscs-quit p {
  margin: 0 0 1.25rem;
  font-family: "BrandonText-Regular", BrandonText, "Brandon Text", sans-serif;
  font-size: 1rem;
  line-height: 1.45;
}

.oscs-quit-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
}

.oscs-quit-back,
.oscs-quit-leave {
  min-height: 44px;
  padding: 0.65rem 1rem;
  border: 2px solid #5233ee;
  border-radius: 9px;
  font-family: BrandonText, "Brandon Text", sans-serif;
  font-size: 16px;
  cursor: pointer;
}

.oscs-quit-back {
  background: #5233ee;
  color: #fff;
}

.oscs-quit-leave {
  background: #fff;
  color: #5233ee;
}

.oscs-quit-back:hover,
.oscs-quit-back:focus-visible {
  border-color: #431fd4;
  background: #431fd4;
  color: #fff;
}

.oscs-quit-leave:hover,
.oscs-quit-leave:focus-visible {
  background: #f4f1fd;
}

.oscs-quit-back:focus-visible,
.oscs-quit-leave:focus-visible {
  outline: 3px solid #ffbf47;
  outline-offset: 3px;
}

.oscs-guide {
  width: min(36rem, calc(100vw - 2rem));
  max-height: min(40rem, calc(100vh - 2rem));
  overflow: auto;
  border: 0;
  border-radius: 18px;
  padding: 1.2rem 1.35rem 1.45rem;
  color: #1a1230;
  font-family: "BrandonText-Regular", sans-serif;
}

.oscs-guide::backdrop {
  background: rgba(26, 18, 48, 0.45);
}

.oscs-guide-bar {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem;
}

.oscs-guide h3 {
  margin: 0;
  font-size: 1.3rem;
}

.oscs-guide h4 {
  margin: 1.15rem 0 0.35rem;
  font-size: 1.02rem;
}

.oscs-guide p,
.oscs-guide li {
  margin: 0.35rem 0;
  font-size: 1rem;
  line-height: 1.45;
}

.oscs-guide ul {
  margin: 0.2rem 0 0;
  padding-left: 1.15rem;
}

.oscs-guide-say {
  margin: 0.55rem 0 0;
  padding: 0.7rem 0.9rem;
  border-radius: 12px;
  background: #efeaff;
  color: #2a1868;
  font-weight: 600;
}

.oscs-guide-close {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  border: 0;
  border-radius: 999px;
  background: transparent;
  color: #6b7280;
  cursor: pointer;
}

.oscs-guide-close:hover,
.oscs-guide-close:focus-visible {
  background: #f4f5f8;
  color: #1a1230;
}

.oscs-media {
  width: min(720px, 92vw);
  border: 0;
  border-radius: 18px;
  padding: 1.2rem 1.3rem 1.3rem;
}

.oscs-media::backdrop {
  background: rgba(26, 18, 48, 0.45);
}

.oscs-media-kicker {
  margin: 0 0 0.35rem;
  color: #8a5a00;
  font-family: BrandonText, "Brandon Text", sans-serif;
}

.oscs-media-question {
  margin: 0 0 0.9rem;
}

.oscs-media-frame img,
.oscs-media-frame video {
  display: block;
  width: 100%;
  max-height: 70vh;
  border-radius: 12px;
  object-fit: contain;
  background: #111;
}

.oscs-media-frame audio {
  width: 100%;
}

.oscs-media-frame iframe {
  display: block;
  width: 100%;
  height: 70vh;
  border: 0;
  border-radius: 12px;
  background: #fff;
}

.oscs-media.is-station .oscs-media-close {
  display: none;
}

.oscs-media-close {
  margin-top: 0.9rem;
  border: 0;
  border-radius: 17px;
  background: #5233ee;
  color: #fff;
  padding: 0.55rem 1rem;
  font-family: BrandonText, "Brandon Text", sans-serif;
  cursor: pointer;
}

.oscs-composer {
  display: flex;
  flex: 0 0 auto;
  gap: 0.75rem;
  align-items: flex-end;
}

.oscs-message {
  display: block;
  flex: 1 1 auto;
  width: 100%;
  min-height: 44px;
  max-height: 20rem;
  padding: 0.65rem 1rem;
  border: 1px solid #e4e7f0;
  border-radius: 17px;
  background: #fff;
  color: #1a1230;
  resize: none;
  overflow: hidden;
}

.oscs-message::placeholder {
  font-family: "BrandonText-Regular", sans-serif;
  font-weight: 400;
  font-style: normal;
}

.oscs-voice {
  display: flex;
  flex: 1 1 auto;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 1rem;
  min-height: 0;
  padding: 1.5rem 0 0.5rem;
}

.oscs-orb {
  display: grid;
  place-items: center;
  width: 220px;
  height: 220px;
}

.oscs-orb-core {
  width: 168px;
  height: 168px;
  border-radius: 50%;
  background: radial-gradient(circle at 35% 30%, #d9d0ff, #5233ee 52%, #2a1578 100%);
  box-shadow: 0 18px 46px rgba(82, 51, 238, 0.35);
  transform: scale(1);
}

.oscs-orb[data-speaker="idle"] .oscs-orb-core {
  animation: oscs-breathe 5.6s ease-in-out infinite;
}

.oscs-orb[data-speaker="patient"] .oscs-orb-core,
.oscs-orb[data-speaker="student"] .oscs-orb-core {
  background: radial-gradient(circle at 35% 30%, #efeaff, #6d4dff 48%, #31168f 100%);
}

@keyframes oscs-breathe {
  0%,
  100% { transform: scale(1); }
  50% { transform: scale(1.035); }
}

.oscs-orb-status {
  margin: 0;
  color: #3c3552;
  font-weight: 600;
}

.oscs-mute {
  min-height: 40px;
  padding: 0.45rem 1rem;
  border-radius: 999px;
}

.oscs-mute[aria-pressed="true"] {
  border-color: #9b2c2c;
  color: #9b2c2c;
}

.oscs-remote-audio {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
  pointer-events: none;
}

.oscs-debrief-body {
  flex: 1 1 auto;
  min-height: 0;
  overflow: auto;
}

.oscs-feedback,
.oscs-debrief-body {
  color: #1a1230;
  font-family: "BrandonText-Regular", sans-serif;
  font-weight: 400;
}

.oscs-debrief-title {
  margin: 0 0 1rem;
  color: #1a1a1a;
  font-size: 1.35rem;
}

.oscs-score {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 0.75rem 1rem;
  margin-bottom: 0.4rem;
}

.oscs-score-figure {
  margin: 0;
  color: #20124d;
  font-family: BrandonText, "Brandon Text", sans-serif;
  font-size: 2rem;
  font-weight: 400;
  line-height: 1;
}

.oscs-score-pill {
  display: inline-flex;
  align-items: center;
  min-height: 32px;
  padding: 0.2rem 0.8rem;
  border-radius: 999px;
  font-family: BrandonText, "Brandon Text", sans-serif;
}

.oscs-score-pill.is-pass {
  background: #e7f7ef;
  color: #146c43;
}

.oscs-score-pill.is-fail {
  background: #fdecec;
  color: #9b2c2c;
}

.oscs-score-note,
.oscs-debrief-caption {
  margin: 0 0 1.1rem;
  color: #5c5670;
}

.oscs-personal {
  margin: 0 0 1.35rem;
  padding: 1.05rem 1.2rem 0.35rem;
  border-radius: 18px;
  background: #efeaff;
  color: #2a1868;
}

.oscs-personal h4 {
  margin: 0.85rem 0 0.3rem;
  color: #5233ee;
  font-family: BrandonText, "Brandon Text", sans-serif;
  font-size: 1.05rem;
}

.oscs-personal h4:first-child {
  margin-top: 0;
}

.oscs-personal p {
  margin: 0 0 0.85rem;
}

.oscs-case-feedback {
  margin: 1.35rem 0 0;
  padding: 1.15rem 1.25rem 1.2rem;
  border-radius: 18px;
  background: #efeaff;
  color: #2a1868;
  font-family: "BrandonText-Regular", sans-serif;
  font-size: clamp(16px, 2vw + 1rem, 20px);
  font-weight: 400;
  line-height: 1.45;
}

.oscs-case-feedback h3 {
  margin: 0 0 0.75rem;
  color: #5233ee;
  font-family: inherit;
  font-size: inherit;
  font-weight: inherit;
  line-height: inherit;
}

.oscs-case-feedback fieldset {
  margin: 0;
  padding: 0;
  border: 0;
  font-size: inherit;
}

.oscs-case-feedback legend,
.oscs-case-feedback p,
.oscs-case-feedback label,
.oscs-case-feedback textarea,
.oscs-case-feedback button {
  font-family: inherit;
  font-size: inherit;
  line-height: inherit;
}

.oscs-case-feedback legend {
  margin: 0;
  padding: 0;
  color: #2a1868;
  font-weight: 600;
}

.oscs-feedback-hint,
.oscs-feedback-note,
.oscs-case-feedback p {
  margin: 0.35rem 0 0;
}

.oscs-feedback-hint {
  color: #5c5670;
}

.oscs-scale {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 0.75rem 0 1rem;
}

.oscs-scale label {
  margin: 0;
}

.oscs-scale input {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
}

.oscs-scale span {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 44px;
  min-height: 44px;
  padding: 0 0.85rem;
  border: 2px solid #d9d3ef;
  border-radius: 999px;
  background: #fff;
  color: #353535;
  font-weight: 600;
  cursor: pointer;
}

.oscs-scale input:focus-visible + span {
  outline: 3px solid #ffbf47;
  outline-offset: 3px;
}

.oscs-scale input:checked + span {
  border-color: #5d28f6;
  background: #5d28f6;
  color: #fff;
}

.oscs-scale label:hover span {
  background: #f4f1fd;
}

.oscs-scale input:checked + span,
.oscs-scale label:hover input:checked + span {
  background: #5d28f6;
  color: #fff;
}

.oscs-feedback-comment {
  display: block;
  margin: 0 0 0.85rem;
  font-weight: 600;
}

.oscs-feedback-comment textarea {
  display: block;
  width: 100%;
  min-height: 120px;
  margin-top: 0.4rem;
  padding: 0.75rem 0.85rem;
  border: 2px solid #d9d3ef;
  border-radius: 12px;
  background: #fff;
  color: #1b0330;
  font: inherit;
  font-weight: 400;
  resize: vertical;
}

.oscs-feedback-send {
  min-height: 44px;
  margin-top: 0.85rem;
  padding: 0.55rem 1.15rem;
  border: 2px solid #5233ee;
  border-radius: 999px;
  background: #5233ee;
  color: #fff;
  font: inherit;
  cursor: pointer;
}

.oscs-feedback-send:hover,
.oscs-feedback-send:focus-visible {
  border-color: #431fd4;
  background: #431fd4;
}

.oscs-feedback-send:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

.oscs-feedback-note {
  color: #9b2c2c;
}

.oscs-marksheet-wrap {
  overflow-x: auto;
  margin: 0.2rem 0 1.2rem;
}

.oscs-marksheet {
  width: 100%;
  border-collapse: collapse;
}

.oscs-marksheet th {
  padding: 0 0.55rem 0.55rem 0;
  color: #5232ec;
  font-family: BrandonText, "Brandon Text", sans-serif;
  font-size: 1.05rem;
  font-weight: 400;
  text-align: left;
}

.oscs-marksheet th:nth-child(2),
.oscs-marksheet th:nth-child(3) {
  width: 3.4rem;
  padding-right: 0.35rem;
  text-align: center;
}

.oscs-marksheet td {
  padding: 0.85rem 0.7rem 0.85rem 0;
  border-top: 1px solid #ece8f8;
  vertical-align: top;
}

.oscs-marksheet td strong {
  display: block;
  margin-bottom: 0.45rem;
  color: #1a1a1a;
  font-family: BrandonText, "Brandon Text", sans-serif;
  font-weight: 400;
}

.oscs-mark-criterion {
  display: flex;
  align-items: flex-start;
  gap: 0.55rem;
  margin: 0.28rem 0;
  font-family: "BrandonText-Regular", sans-serif;
  font-weight: 400;
}

.oscs-mark-criterion input {
  width: 1.05rem;
  height: 1.05rem;
  margin: 0.15rem 0 0;
  accent-color: #5333ee;
  flex: 0 0 auto;
}

.oscs-mark-good,
.oscs-mark-excellent {
  width: 3.4rem;
  border-radius: 5px;
  background: #f6f6f6;
  color: #716f6f;
  font-family: BrandonText, "Brandon Text", sans-serif;
  text-align: center;
  vertical-align: middle;
}

.oscs-mark-good.is-met,
.oscs-mark-excellent.is-met {
  background: #68bc68;
  color: #fff;
}

.oscs-mark-excellent.is-empty {
  background: transparent;
}

.oscs-scenario h4 {
  margin: 1rem 0 0.35rem;
  font-family: BrandonText, "Brandon Text", sans-serif;
  font-size: 1.05rem;
}

.oscs-scenario p {
  margin: 0 0 0.8rem;
}

.oscs-scenario {
  margin-top: 0.5rem;
  padding-top: 0.25rem;
}

.oscs-error {
  margin: 1rem 0 0;
  color: #9b2c2c;
}

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

@keyframes oscs-screen {
  from { opacity: 0; }
  to { opacity: 1; }
}

@keyframes oscs-screen-out {
  from { opacity: 1; }
  to { opacity: 0; }
}

@keyframes oscs-pop {
  from {
    opacity: 0;
    transform: translateY(36px) scale(0.96);
  }
  to {
    opacity: 1;
    transform: none;
  }
}

@keyframes oscs-pop-out {
  from {
    opacity: 1;
    transform: none;
  }
  to {
    opacity: 0;
    transform: translateY(36px) scale(0.96);
  }
}

@media (prefers-reduced-motion: reduce) {
  .oscs-orb[data-speaker="idle"] .oscs-orb-core,
  .oscs-phase.is-examiner.is-current,
  .oscs-bubble.is-arriving,
  .oscs-spinner,
  .oscs-switch-track::after,
  .oscs-modal.is-open,
  .oscs-modal.is-closing,
  .oscs-modal.is-open .oscs-card,
  .oscs-modal.is-closing .oscs-card {
    animation: none;
  }

  .oscs-switch-track::after {
    transition: none;
  }
}

@media (max-width: 720px) {
  .oscs-bar {
    flex-wrap: wrap;
  }

  .oscs-bar-title {
    flex-basis: 100%;
    order: 5;
  }

  .oscs-work {
    grid-template-columns: minmax(0, 1fr);
    grid-template-rows: minmax(180px, 0.9fr) minmax(220px, 1.1fr);
  }

  .oscs-composer {
    flex-direction: column;
    align-items: stretch;
  }

  .oscs-phases {
    grid-template-columns: minmax(0, 1fr);
  }

  .oscs-stage.is-split {
    overflow: auto;
  }

  .oscs-stage.is-split .oscs-phases,
  .oscs-stage.is-split .oscs-phases:has(.oscs-phase.is-examiner.is-current) {
    flex: 0 0 auto;
    grid-template-columns: minmax(0, 1fr);
    grid-template-rows: auto;
  }

  .oscs-stage.is-split .oscs-phase.is-current .oscs-log {
    min-height: 220px;
  }

  .oscs-stage.is-split .oscs-phase:not(.is-current) .oscs-log {
    min-height: 96px;
  }
}
