:root {
  --blue: #0094d4;
  --blue-dark: #007bb3;
  --blue-soft: #e8f7fd;
  --dark: #282d31;
  --grey: #69727a;
  --light-grey: #f1f3f5;
  --line: #dfe3e6;
  --white: #ffffff;
  --red: #b53b47;
  --red-bg: #fff0f1;
  --green: #287454;
  --green-bg: #ebf7f0;
  --amber: #956b16;
  --amber-bg: #fff8e7;
  --navy: var(--dark);
  --navy-2: #3a4147;
  --teal: var(--blue);
  --teal-dark: var(--blue-dark);
  --mint: var(--blue-soft);
  --mint-2: #b9e6f7;
  --sky: var(--blue-soft);
  --cream: var(--light-grey);
  --ink: var(--dark);
  --muted: var(--grey);
  --surface: var(--white);
  --shadow: 0 20px 60px rgba(31, 41, 47, .09);
  --shadow-soft: 0 8px 26px rgba(31, 41, 47, .07);
  --radius: 18px;
}

* { box-sizing: border-box; }
html { min-height: 100%; background: var(--light-grey); scroll-behavior: smooth; }
body {
  min-height: 100%;
  margin: 0;
  color: var(--ink);
  background: var(--light-grey);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  -webkit-font-smoothing: antialiased;
}
button, input { font: inherit; }
button { cursor: pointer; }
button:focus-visible, [tabindex]:focus-visible, input:focus-visible, summary:focus-visible {
  outline: 3px solid rgba(0, 148, 212, .32);
  outline-offset: 3px;
}
.skip-link { position: fixed; left: 18px; top: -70px; z-index: 30; padding: 11px 15px; border-radius: 8px; color: white; background: var(--dark); }
.skip-link:focus { top: 18px; }

.course-shell {
  width: min(1240px, calc(100% - 40px));
  min-height: calc(100vh - 40px);
  margin: 20px auto;
  display: grid;
  grid-template-rows: auto auto 1fr auto;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 22px;
  background: var(--white);
  box-shadow: var(--shadow);
}
.topbar { display: flex; justify-content: space-between; align-items: center; gap: 24px; padding: 20px 30px; border-bottom: 1px solid var(--line); background: var(--white); }
.brand { display: flex; align-items: center; gap: 13px; padding: 0; border: 0; color: var(--dark); background: transparent; text-align: left; }
.brand-mark { display: grid; place-items: center; width: 48px; height: 44px; padding: 2px; border-radius: 10px; background: white; }
.brand-mark img { display: block; width: 100%; height: 100%; object-fit: contain; }
.brand strong, .brand small { display: block; }
.brand strong { font-size: 1rem; letter-spacing: -.01em; }
.brand small { margin-top: 3px; color: var(--grey); font-size: .76rem; }
.top-actions { display: flex; gap: 8px; }
.icon-button { padding: 9px 12px; border: 1px solid var(--line); border-radius: 9px; color: var(--grey); background: var(--white); font-size: .82rem; font-weight: 650; transition: border-color .2s ease, color .2s ease, background .2s ease; }
.icon-button:hover { border-color: #b7c1c8; color: var(--dark); background: var(--light-grey); }
.progress-region { padding: 11px 30px 13px; border-bottom: 1px solid var(--line); background: #fafbfc; }
.progress-copy { display: flex; justify-content: space-between; margin-bottom: 7px; color: var(--grey); font-size: .74rem; font-weight: 650; }
.progress-track { height: 5px; overflow: hidden; border-radius: 99px; background: #e3e7e9; }
.progress-track span { display: block; width: 0; height: 100%; border-radius: inherit; background: var(--blue); transition: width .45s cubic-bezier(.22,1,.36,1); }

main { min-height: 590px; background: var(--white); }
.screen { max-width: 1050px; margin: 0 auto; padding: 52px 52px 58px; animation: enter .42s cubic-bezier(.22,1,.36,1); }
@keyframes enter { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: translateY(0); } }
.eyebrow { margin: 0 0 12px; color: var(--blue); font-size: .72rem; font-weight: 800; letter-spacing: .14em; text-transform: uppercase; }
h1 { margin: 0; color: var(--dark); font-size: clamp(2rem, 4vw, 3.3rem); letter-spacing: -.045em; line-height: 1.04; }
h2 { margin: 0 0 14px; color: var(--dark); font-size: clamp(1.45rem, 2.6vw, 2.15rem); letter-spacing: -.025em; line-height: 1.18; }
h3 { margin: 0 0 8px; color: var(--dark); }
.lead { max-width: 760px; margin: 18px 0 30px; color: var(--grey); font-size: 1.1rem; line-height: 1.65; }
.instruction { display: flex; gap: 10px; align-items: flex-start; margin: 20px 0; padding: 14px 16px; border: 1px solid #cdebf8; border-radius: 12px; color: #315563; background: var(--blue-soft); font-weight: 650; }
.instruction::before { content: "ACTION"; flex: none; margin-top: 1px; padding: 3px 6px; border-radius: 4px; color: white; background: var(--blue); font-size: .62rem; letter-spacing: .08em; }

.hero { position: relative; display: grid; align-items: center; overflow: hidden; min-height: 530px; padding: 54px; border: 1px solid var(--line); border-radius: 20px; color: var(--dark); background-color: white; background-image: linear-gradient(90deg, #fff 0%, rgba(255,255,255,.99) 38%, rgba(255,255,255,.88) 52%, rgba(255,255,255,.12) 76%), url("media/course-cover.png"); background-position: center; background-size: cover; box-shadow: var(--shadow-soft); }
.hero::before { content: ""; position: absolute; inset: 0; border-radius: inherit; pointer-events: none; }
.hero::after { content: ""; position: absolute; left: 0; bottom: 0; width: 180px; height: 4px; background: var(--blue); }
.hero > * { position: relative; z-index: 1; }
.hero-content { max-width: 530px; }
.hero h1 { color: var(--dark); }
.hero .eyebrow { color: var(--blue); }
.hero .lead { color: var(--grey); }
.hero-badge { aspect-ratio: 1; display: grid; place-items: center; border: 1px solid rgba(255,255,255,.2); border-radius: 50%; background: rgba(255,255,255,.06); backdrop-filter: blur(8px); }
.hero-badge span { color: white; font-size: 3rem; font-weight: 800; }
.metric-row { display: grid; grid-template-columns: repeat(4, 1fr); gap: 9px; margin-top: 22px; }
.metric { padding: 12px; border: 1px solid var(--line); border-radius: 10px; background: rgba(255,255,255,.82); }
.metric strong, .metric small { display: block; }
.metric strong { font-size: 1.05rem; }
.metric small { margin-top: 3px; color: var(--grey); font-size: .7rem; }

.module-grid, .choice-grid, .card-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
.module-card, .choice-card, .select-card, .control-card { position: relative; width: 100%; padding: 20px; border: 1px solid var(--line); border-radius: 14px; color: var(--ink); background: white; text-align: left; transition: transform .22s ease, border-color .22s ease, box-shadow .22s ease, background .22s ease; }
.module-card:hover, .choice-card:hover, .select-card:hover, .control-card:hover { transform: translateY(-2px); border-color: rgba(0,148,212,.55); box-shadow: var(--shadow-soft); }
.module-card.complete { border-color: #afd6c3; background: var(--green-bg); }
.module-number { display: inline-grid; place-items: center; width: 34px; height: 34px; margin-bottom: 16px; border-radius: 9px; color: var(--blue); background: var(--blue-soft); font-weight: 800; }
.module-card strong, .choice-card strong { display: block; margin-bottom: 7px; color: var(--dark); }
.module-card p, .choice-card p { margin: 0; color: var(--grey); line-height: 1.5; }
.module-card small { display: block; margin-top: 14px; color: var(--grey); }
.status-chip { position: absolute; top: 18px; right: 18px; color: var(--green); font-size: .67rem; font-weight: 800; letter-spacing: .06em; text-transform: uppercase; }
.status-chip:not(.in-progress) { color: var(--grey); }
.module-card.complete .status-chip { color: var(--green); }
.status-chip.in-progress { color: var(--blue-dark); }
.activity-hint { margin: 0 0 14px; color: var(--grey); font-size: .86rem; line-height: 1.5; }

.roadmap { position: relative; aspect-ratio: 1672 / 941; overflow: hidden; border: 1px solid var(--line); border-radius: 18px; background: white url("media/course-roadmap-v2.png") center / 100% 100% no-repeat; box-shadow: var(--shadow-soft); }
.roadmap .module-grid { position: absolute; inset: 0; z-index: 2; display: block; min-height: 0; padding: 0; }
.roadmap .module-card { position: absolute; z-index: 2; width: 126px; height: 50px; min-height: 0; padding: 8px 11px; overflow: hidden; border: 1px solid rgba(166,180,188,.88); border-radius: 999px; background: rgba(255,255,255,.96); box-shadow: 0 6px 18px rgba(36,45,51,.14); backdrop-filter: blur(8px); transform: translate(-50%, -50%); transform-origin: center; transition: width .38s cubic-bezier(.22,1,.36,1), height .38s cubic-bezier(.22,1,.36,1), padding .38s cubic-bezier(.22,1,.36,1), border-radius .32s ease, box-shadow .3s ease, transform .3s ease, background .3s ease; }
.roadmap .module-card:nth-child(1) { left: 17.2%; top: 77.1%; }
.roadmap .module-card:nth-child(2) { left: 32.1%; top: 65.1%; }
.roadmap .module-card:nth-child(3) { left: 44.1%; top: 53.7%; }
.roadmap .module-card:nth-child(4) { left: 56.1%; top: 41.8%; }
.roadmap .module-card:nth-child(5) { left: 68.1%; top: 26.5%; }
.roadmap .module-card:nth-child(6) { left: 84.1%; top: 15.5%; }
.roadmap .module-card:hover, .roadmap .module-card:focus-visible { z-index: 10; width: 226px; height: 174px; padding: 16px; border-radius: 15px; border-color: var(--blue); background: rgba(255,255,255,.985); box-shadow: 0 18px 38px rgba(36,45,51,.2); transform: translate(-50%, -50%) scale(1.015); }
.roadmap .module-card:nth-child(6):hover, .roadmap .module-card:nth-child(6):focus-visible { transform: translate(-66%, -14%) scale(1.015); }
.roadmap .module-number { display: inline-grid; width: 32px; height: 32px; margin: 0 8px 0 0; border-radius: 50%; color: white; background: var(--blue); box-shadow: 0 4px 10px rgba(0,148,212,.2); vertical-align: middle; }
.roadmap .module-card strong { display: inline-block; margin: 0; padding: 0; color: var(--dark); font-size: .78rem; line-height: 32px; vertical-align: middle; white-space: nowrap; }
.roadmap .module-title { display: block; max-height: 0; margin: 0; overflow: hidden; color: var(--dark); font-size: .9rem; font-weight: 800; line-height: 1.3; opacity: 0; transition: max-height .3s ease, margin .3s ease, opacity .22s ease; }
.roadmap .module-card p, .roadmap .module-card small, .roadmap .status-chip { opacity: 0; pointer-events: none; transition: opacity .2s ease .05s; }
.roadmap .module-card p { display: block; max-height: 0; overflow: hidden; font-size: .72rem; line-height: 1.4; }
.roadmap .module-card small { display: block; margin-top: 8px; font-size: .68rem; }
.roadmap .status-chip { top: 18px; right: 14px; max-width: 78px; font-size: .55rem; text-align: right; }
.roadmap .module-card:hover strong, .roadmap .module-card:focus-visible strong { display: none; }
.roadmap .module-card:hover .module-title, .roadmap .module-card:focus-visible .module-title { max-height: 42px; margin: 8px 64px 6px 0; opacity: 1; }
.roadmap .module-card:hover p, .roadmap .module-card:focus-visible p { max-height: 62px; opacity: 1; }
.roadmap .module-card:hover small, .roadmap .module-card:focus-visible small, .roadmap .module-card:hover .status-chip, .roadmap .module-card:focus-visible .status-chip { opacity: 1; }
.roadmap .assessment-card { border-color: #addbed; background: rgba(255,255,255,.97); }
.roadmap .assessment-card .module-number { background: var(--dark); }
.roadmap .assessment-card.ready { border-color: var(--blue); box-shadow: 0 10px 28px rgba(0,148,212,.2); }
.roadmap .assessment-card.ready .module-number { background: var(--blue); }
.roadmap .assessment-card.ready .status-chip { color: var(--blue-dark); }
.roadmap .assessment-card.locked { cursor: not-allowed; filter: grayscale(.7); opacity: .8; }
.roadmap .assessment-card.locked:hover { border-color: #addbed; }
.roadmap .module-card.available:not(.complete) { border-color: rgba(0,148,212,.8); background: rgba(239,249,253,.98); box-shadow: 0 8px 24px rgba(0,148,212,.2); }
.roadmap .module-card.available:not(.complete) .status-chip { color: var(--blue-dark); }
.roadmap .module-card.locked:not(.assessment-card) { cursor: not-allowed; border-color: #addbed; background: rgba(255,255,255,.97); filter: grayscale(.7); opacity: .8; }
.roadmap .module-card.locked:not(.assessment-card):hover, .roadmap .module-card.locked:not(.assessment-card):focus-visible { border-color: #addbed; background: rgba(255,255,255,.97); box-shadow: 0 18px 38px rgba(36,45,51,.16); filter: grayscale(.7); opacity: .8; }
.roadmap .module-card.locked:not(.assessment-card):hover p, .roadmap .module-card.locked:not(.assessment-card):focus-visible p,
.roadmap .module-card.locked:not(.assessment-card):hover small, .roadmap .module-card.locked:not(.assessment-card):focus-visible small { color: var(--dark); }
.roadmap-label { position: absolute; z-index: 3; padding: 6px 10px; border-radius: 999px; color: var(--dark); background: white; box-shadow: 0 4px 12px rgba(36,45,51,.1); font-size: .65rem; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; }
.roadmap-start { left: 15px; bottom: 14px; }
.roadmap-finish { top: 14px; right: 14px; color: white; background: var(--blue); }

.video-placeholder { display: grid; grid-template-columns: minmax(0, 1fr) minmax(220px, 270px); align-items: center; gap: 42px; min-height: 500px; padding: 38px 48px; border-radius: 18px; color: white; background: var(--dark); box-shadow: inset 0 0 0 1px rgba(255,255,255,.06); }
.video-stage { display: flex; flex-direction: column; justify-content: space-between; }
.video-kicker { color: #76ccec; font-size: .7rem; font-weight: 800; letter-spacing: .13em; }
.video-placeholder h2 { margin-top: 14px; color: white; font-size: 2.15rem; }
.video-placeholder p { color: #c2c8cc; line-height: 1.65; }
.play-button { display: inline-flex; align-items: center; gap: 10px; width: max-content; padding: 12px 17px; border: 0; border-radius: 9px; color: white; background: var(--blue); font-weight: 750; transition: background .2s ease, transform .2s ease; }
.play-button:hover { background: var(--blue-dark); transform: translateY(-1px); }
.play-button::before { content: "▶"; font-size: .72rem; }
.portrait-video-frame { width: 100%; max-width: 270px; margin-inline: auto; padding: 7px; border: 1px solid rgba(255,255,255,.16); border-radius: 24px; background: #15191c; box-shadow: 0 22px 45px rgba(0,0,0,.28); }
.avatar-placeholder { position: relative; aspect-ratio: 9 / 16; display: grid; align-content: end; justify-items: center; overflow: hidden; border: 1px solid rgba(255,255,255,.12); border-radius: 18px; color: var(--dark); background: linear-gradient(160deg, #e9ecee, #bfc7cc); }
.portrait-format { position: absolute; top: 14px; right: 14px; padding: 5px 8px; border-radius: 6px; color: white; background: rgba(40,45,49,.72); font-size: .68rem; font-weight: 800; letter-spacing: .08em; }
.avatar-head { width: 86px; height: 86px; margin-bottom: -3px; border-radius: 50%; background: #d2d7da; }
.avatar-body { width: 180px; height: 150px; border-top: 12px solid #c0c7cb; border-radius: 80px 80px 0 0; background: white; }
.avatar-placeholder small { position: absolute; bottom: 14px; padding: 5px 9px; border-radius: 5px; color: white; background: rgba(40,45,49,.9); }
.transcript { margin-top: 14px; overflow: hidden; border: 1px solid var(--line); border-radius: 11px; background: white; }
.transcript summary { padding: 13px 15px; color: var(--dark); cursor: pointer; font-weight: 700; }
.transcript[open] summary { border-bottom: 1px solid var(--line); }
.transcript p { padding: 2px 15px 15px; color: var(--grey); line-height: 1.6; }

.landscape-video-lesson { display: grid; grid-template-columns: minmax(0, 1.55fr) minmax(230px, .65fr); gap: 20px; align-items: stretch; }
.lesson-player-shell { overflow: hidden; border: 1px solid #cbd5da; border-radius: 16px; background: #171c1f; box-shadow: 0 16px 38px rgba(31,41,47,.16); }
.lesson-player-head { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 11px 14px; color: #bfc7cb; background: #252b2f; font-size: .68rem; }
.lesson-player-head span { display: flex; align-items: center; gap: 7px; font-weight: 800; letter-spacing: .07em; text-transform: uppercase; }
.lesson-player-head span i { width: 8px; height: 8px; border-radius: 50%; background: var(--blue); box-shadow: 0 0 0 4px rgba(0,148,212,.14); }
.lesson-player-head strong { color: white; font-size: .68rem; }
.lesson-video { display: block; width: 100%; aspect-ratio: 16 / 9; background: black; object-fit: contain; }
.lesson-video-summary { display: flex; flex-direction: column; padding: 25px; border: 1px solid var(--line); border-radius: 16px; background: linear-gradient(155deg, #fff, #f5f8f9); }
.lesson-video-summary h2 { font-size: 1.45rem; }
.lesson-video-summary > p:not(.console-kicker) { margin: 0; color: var(--grey); line-height: 1.6; }
.watch-status { display: grid; grid-template-columns: 36px 1fr; align-items: center; gap: 10px; margin-top: auto; padding: 12px; border: 1px solid #cfe8f3; border-radius: 10px; background: var(--blue-soft); }
.watch-status > span { display: grid; place-items: center; width: 34px; height: 34px; border-radius: 9px; color: white; background: var(--blue); font-size: .75rem; }
.watch-status strong, .watch-status small { display: block; }
.watch-status strong { color: var(--dark); font-size: .76rem; }
.watch-status small { margin-top: 3px; color: var(--grey); font-size: .66rem; line-height: 1.35; }
.watch-status.complete { border-color: #b9dac8; background: var(--green-bg); }
.watch-status.complete > span { background: var(--green); }

.telehealth-console { overflow: hidden; border: 1px solid #cfd8dd; border-radius: 18px; background: #f6f8f9; box-shadow: var(--shadow-soft); }
.console-top { display: flex; justify-content: space-between; align-items: center; gap: 16px; padding: 12px 16px; border-bottom: 1px solid #dce3e7; color: var(--grey); background: white; font-size: .72rem; }
.console-top span { display: flex; align-items: center; gap: 7px; font-weight: 750; text-transform: uppercase; letter-spacing: .06em; }
.console-top span i { width: 8px; height: 8px; border-radius: 50%; background: #29a66f; box-shadow: 0 0 0 4px rgba(41,166,111,.12); }
.console-top strong { color: var(--dark); }
.console-layout { display: grid; grid-template-columns: minmax(250px, .72fr) 1.28fr; min-height: 500px; }
.console-call { position: relative; overflow: hidden; min-height: 420px; background: var(--dark); }
.console-call img { width: 100%; height: 100%; display: block; object-fit: cover; object-position: center 24%; }
.call-label { position: absolute; left: 14px; bottom: 14px; padding: 7px 10px; border-radius: 7px; color: white; background: rgba(31,37,41,.8); backdrop-filter: blur(7px); font-size: .7rem; font-weight: 700; }
.call-controls { position: absolute; left: 50%; bottom: 15px; display: flex; gap: 7px; transform: translateX(-50%); }
.call-controls i { width: 30px; height: 30px; border: 1px solid rgba(255,255,255,.5); border-radius: 50%; background: rgba(255,255,255,.2); backdrop-filter: blur(7px); }
.call-controls i:last-child { background: #c84550; }
.console-workflow { display: flex; flex-direction: column; justify-content: center; padding: 36px 40px; background: white; }
.console-kicker { margin: 0 0 8px; color: var(--blue); font-size: .7rem; font-weight: 800; letter-spacing: .1em; text-transform: uppercase; }
.console-workflow h2, .verification-panel h2 { margin-bottom: 20px; }
.console-workflow ol { display: grid; gap: 9px; margin: 0 0 24px; padding: 0; list-style: none; }
.console-workflow li { display: grid; grid-template-columns: 42px 1fr; gap: 0 12px; align-items: center; padding: 11px 13px; border: 1px solid var(--line); border-radius: 10px; }
.console-workflow li > span { grid-row: span 2; display: grid; place-items: center; width: 34px; height: 34px; border-radius: 8px; color: var(--blue); background: var(--blue-soft); font-size: .68rem; font-weight: 850; }
.console-workflow li strong { font-size: .85rem; }
.console-workflow li small { color: var(--grey); font-size: .7rem; }
.console-workflow .play-button { margin-top: auto; }
.readiness-track { height: 6px; background: #e6eaec; }
.readiness-track span { display: block; width: 0; height: 100%; background: var(--blue); transition: width .3s ease; }
.verification-layout { display: grid; grid-template-columns: 240px 1fr; min-height: 500px; }
.compact-call { min-height: 500px; }
.privacy-badge { position: absolute; top: 14px; right: 14px; padding: 6px 9px; border-radius: 7px; color: var(--blue-dark); background: rgba(255,255,255,.9); font-size: .66rem; font-weight: 800; }
.verification-panel { padding: 28px; background: white; }
.verification-panel .select-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.verification-panel .select-card { display: flex; gap: 10px; align-items: center; min-height: 67px; padding: 13px; font-size: .82rem; }
.console-checkmark { flex: none; display: grid; place-items: center; width: 24px; height: 24px; border: 2px solid #b7c0c5; border-radius: 6px; }
.select-card.selected .console-checkmark { border-color: var(--blue); color: white; background: var(--blue); }
.select-card.selected .console-checkmark::before { content: "✓"; font-weight: 900; }
.console-error span i { background: #c84550; box-shadow: 0 0 0 4px rgba(200,69,80,.12); }
.connection-state { display: grid; grid-template-columns: .8fr 1.2fr; min-height: 280px; }
.lost-video { display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 30px; color: white; background: var(--dark); text-align: center; }
.camera-off { display: grid; place-items: center; width: 64px; height: 64px; margin-bottom: 17px; border: 1px solid rgba(255,255,255,.25); border-radius: 18px; color: white; background: rgba(255,255,255,.08); font-size: 2rem; }
.lost-video small { margin-top: 7px; color: #b9c0c4; line-height: 1.4; }
.connection-scenario { display: flex; flex-direction: column; justify-content: center; padding: 34px; background: white; }
.connection-scenario span { margin-bottom: 10px; color: #b53b47; font-size: .7rem; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; }
.connection-scenario p { margin: 0; color: var(--dark); font-size: 1rem; line-height: 1.6; }

.module-video-m3 { background: linear-gradient(145deg, #242a2e, #343c41); }
.module-video-m3 .portrait-video-frame { border-color: rgba(0,148,212,.45); box-shadow: 0 0 0 1px rgba(0,148,212,.14), 0 22px 45px rgba(0,0,0,.28); }
.ehr-workspace { overflow: hidden; border: 1px solid #cfd8dd; border-radius: 18px; background: #f3f6f7; box-shadow: var(--shadow-soft); }
.ehr-top { display: flex; justify-content: space-between; align-items: center; gap: 16px; padding: 13px 18px; border-bottom: 1px solid var(--line); color: var(--grey); background: white; font-size: .72rem; }
.ehr-top span { font-weight: 800; letter-spacing: .07em; text-transform: uppercase; }
.ehr-top strong { color: var(--dark); }
.ehr-layout { display: grid; grid-template-columns: 210px 1fr; min-height: 470px; }
.ehr-sidebar { padding: 25px 20px; border-right: 1px solid var(--line); background: #eef2f4; }
.ehr-complete { display: grid; grid-template-columns: 28px 1fr; align-items: center; gap: 9px; margin-bottom: 9px; padding: 10px; border: 1px solid #c8dfd3; border-radius: 9px; color: var(--green); background: white; }
.ehr-complete span { display: grid; place-items: center; width: 25px; height: 25px; border-radius: 7px; color: white; background: var(--green); font-size: .75rem; font-weight: 900; }
.ehr-complete strong { color: var(--dark); font-size: .78rem; }
.ehr-sidebar > small { display: block; margin-top: 20px; color: var(--grey); line-height: 1.5; }
.ehr-editor { padding: 26px; background: white; }
.ehr-editor-head { display: flex; justify-content: space-between; align-items: center; margin-bottom: 20px; padding-bottom: 16px; border-bottom: 1px solid var(--line); }
.ehr-editor-head div span, .ehr-editor-head div strong { display: block; }
.ehr-editor-head div span { margin-bottom: 4px; color: var(--grey); font-size: .68rem; text-transform: uppercase; letter-spacing: .07em; }
.draft-chip { padding: 6px 9px; border-radius: 7px; color: var(--blue-dark); background: var(--blue-soft); font-size: .68rem; font-weight: 800; }
.ehr-editor .select-grid { grid-template-columns: repeat(2, minmax(0,1fr)); }
.ehr-editor .select-card { display: flex; gap: 10px; align-items: center; min-height: 70px; padding: 13px; font-size: .82rem; }
.risk-workspace { margin-bottom: 18px; }
.risk-timeline { display: grid; grid-template-columns: 1fr 44px 1fr 44px 1fr; align-items: center; gap: 0; padding: 30px 28px; background: white; }
.risk-stage { min-height: 130px; padding: 16px; border: 1px solid var(--line); border-radius: 12px; background: #fafbfc; text-align: center; }
.risk-stage > span { display: grid; place-items: center; width: 32px; height: 32px; margin: 0 auto 10px; border-radius: 9px; color: var(--blue); background: var(--blue-soft); font-size: .68rem; font-weight: 850; }
.risk-stage strong, .risk-stage small { display: block; }
.risk-stage strong { font-size: .82rem; }
.risk-stage small { margin-top: 7px; color: var(--grey); font-size: .7rem; line-height: 1.4; }
.risk-stage.active { border-color: #acdcef; background: var(--blue-soft); }
.risk-stage.active > span { color: white; background: var(--blue); }
.risk-line { height: 3px; background: linear-gradient(90deg, var(--blue), #b8ddea); }
.ehr-question { padding: 22px 28px; border-top: 1px solid var(--line); background: #f5f7f8; }
.ehr-question span { color: var(--blue-dark); font-size: .68rem; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; }
.ehr-question p { margin: 8px 0 0; color: var(--dark); line-height: 1.55; }

.module-video-m5 { background: linear-gradient(145deg, #252b2f, #354047); }
.module-video-m5 .play-button { box-shadow: 0 8px 20px rgba(0,148,212,.22); }
.medication-workspace { overflow: hidden; margin-bottom: 18px; border: 1px solid #cfd8dd; border-radius: 18px; background: #f4f6f7; box-shadow: var(--shadow-soft); }
.medication-top { display: flex; justify-content: space-between; align-items: center; gap: 14px; padding: 13px 18px; border-bottom: 1px solid var(--line); color: var(--grey); background: white; font-size: .72rem; }
.medication-top span { font-weight: 800; letter-spacing: .07em; text-transform: uppercase; }
.medication-top strong { color: var(--dark); }
.prescribing-instructions { display: flex; align-items: center; justify-content: center; gap: 15px; padding: 18px; border-bottom: 1px solid var(--line); background: #fafbfc; }
.prescribing-instructions > div { display: flex; align-items: center; gap: 10px; }
.prescribing-instructions > div > span { display: grid; place-items: center; width: 30px; height: 30px; border-radius: 8px; color: white; background: var(--blue); font-size: .72rem; font-weight: 850; }
.prescribing-instructions p { margin: 0; }
.prescribing-instructions p strong, .prescribing-instructions p small { display: block; }
.prescribing-instructions p strong { font-size: .78rem; }
.prescribing-instructions p small { margin-top: 2px; color: var(--grey); font-size: .68rem; }
.prescribing-instructions > i { width: 55px; height: 2px; background: #c7d0d5; }
.medication-tray { padding: 18px 20px 4px; background: white; }
.tray-photo { position: relative; min-height: 190px; margin-bottom: 18px; overflow: hidden; border: 1px solid var(--line); border-radius: 13px; background: #eef2f4 url("media/medication-tray.png") center / cover no-repeat; }
.tray-photo::after { content: ""; position: absolute; inset: 0; background: linear-gradient(0deg, rgba(31,37,41,.45), transparent 45%); }
.tray-photo span { position: absolute; left: 14px; bottom: 12px; z-index: 1; padding: 6px 9px; border-radius: 6px; color: white; background: rgba(31,37,41,.72); font-size: .65rem; font-weight: 700; }
.medication-tray .medicine-bank { display: grid; grid-template-columns: repeat(4, minmax(0,1fr)); gap: 9px; margin-bottom: 10px; border-style: dashed; background: #f7f9fa; }
.medicine-option { display: flex; align-items: center; gap: 9px; min-width: 0; min-height: 64px; width: 100%; padding: 8px; border-radius: 10px; white-space: normal; text-align: left; line-height: 1.25; }
.medicine-thumb { flex: 0 0 38px; width: 38px; height: 38px; border-radius: 8px; background-image: url("media/medication-tray.png"); background-size: 430px auto; box-shadow: inset 0 0 0 1px rgba(40,45,49,.08); }
.medicine-thumb.thumb-0 { background-position: 23% 25%; }
.medicine-thumb.thumb-1 { background-position: 48% 23%; }
.medicine-thumb.thumb-2 { background-position: 71% 62%; }
.medicine-thumb.thumb-3 { background-position: 83% 32%; }
.medicine-name { min-width: 0; overflow-wrap: anywhere; font-size: .72rem; }
.medicine-option.selected .medicine-thumb { box-shadow: inset 0 0 0 2px white; }
.prescribing-board .lane-board { padding: 14px 20px 22px; background: white; }
.prescribing-board .lane { position: relative; min-height: 235px; padding: 18px 14px; border-style: solid; text-align: left; transition: transform .2s ease, box-shadow .2s ease; }
.prescribing-board .lane:hover { transform: translateY(-2px); box-shadow: 0 9px 20px rgba(38,48,54,.09); }
.prescribing-board .lane-icon { display: grid; place-items: center; width: 32px; height: 32px; margin-bottom: 13px; border-radius: 9px; color: white; font-weight: 900; }
.prescribing-board .lane[data-lane="red"] .lane-icon { background: var(--red); }
.prescribing-board .lane[data-lane="amber"] .lane-icon { background: #b4841d; }
.prescribing-board .lane[data-lane="green"] .lane-icon { background: var(--green); }
.prescribing-board .lane h3 { margin-bottom: 2px; letter-spacing: .04em; }
.prescribing-board .lane > small { display: block; margin-bottom: 12px; color: var(--grey); font-size: .7rem; }
.prescribing-board .lane > div { min-height: 90px; padding-top: 8px; border-top: 1px solid rgba(40,45,49,.1); }
.prescribing-board .placed-medicine { display: inline-flex; max-width: 100%; margin: 4px 4px 0 0; border-radius: 8px; white-space: normal; overflow-wrap: anywhere; text-align: left; font-size: .68rem; line-height: 1.25; }
.closeout-flow { padding: 24px 34px 18px; border-bottom: 1px solid var(--line); background: white; }
.closeout-steps { display: grid; grid-template-columns: 32px 1fr 32px 1fr 32px 1fr 32px; align-items: center; }
.closeout-steps span { display: grid; place-items: center; width: 32px; height: 32px; border: 2px solid #cad2d7; border-radius: 50%; color: var(--grey); background: white; font-size: .7rem; font-weight: 850; }
.closeout-steps span.active { border-color: var(--blue); color: white; background: var(--blue); }
.closeout-steps i { height: 2px; background: #d6dde1; }
.closeout-labels { display: grid; grid-template-columns: repeat(4, 1fr); margin-top: 8px; color: var(--grey); font-size: .64rem; text-align: center; }
.closeout-panel { padding: 26px; background: #f8fafb; }
.closeout-panel h2 { margin-bottom: 8px; }
.closeout-panel .select-grid { grid-template-columns: repeat(2, minmax(0,1fr)); }
.closeout-panel .select-card { display: flex; align-items: center; gap: 10px; min-height: 72px; padding: 14px; font-size: .82rem; }
.medication-case { display: grid; grid-template-columns: .75fr 1fr 1.15fr; min-height: 210px; background: white; }
.medicine-profile { display: flex; align-items: center; gap: 15px; padding: 24px; border-right: 1px solid var(--line); }
.medicine-symbol { flex: none; display: grid; place-items: center; width: 56px; height: 56px; border-radius: 15px; color: white; background: var(--blue); font-size: 1rem; font-weight: 850; }
.medicine-profile div small, .medicine-profile div strong, .medicine-profile div span { display: block; }
.medicine-profile div small { color: var(--grey); font-size: .67rem; }
.medicine-profile div strong { margin: 3px 0; }
.medicine-profile div span { color: var(--blue-dark); font-size: .7rem; font-weight: 750; }
.safeguard-status { display: grid; align-content: center; gap: 10px; padding: 22px; border-right: 1px solid var(--line); background: #fafbfc; }
.safeguard-row { display: grid; grid-template-columns: 30px 1fr; align-items: center; gap: 10px; padding: 10px; border: 1px solid var(--line); border-radius: 9px; background: white; }
.safeguard-row > span { display: grid; place-items: center; width: 28px; height: 28px; border-radius: 8px; color: white; font-weight: 900; }
.safeguard-row.complete > span { background: var(--green); }
.safeguard-row.blocked > span { background: var(--red); }
.safeguard-row strong, .safeguard-row small { display: block; }
.safeguard-row strong { font-size: .74rem; }
.safeguard-row small { margin-top: 2px; color: var(--grey); font-size: .66rem; }
.case-alert { display: flex; flex-direction: column; justify-content: center; padding: 25px; }
.case-alert span { color: var(--red); font-size: .68rem; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; }
.case-alert p { margin: 8px 0 0; line-height: 1.55; }

.choice-card { min-height: 108px; display: flex; gap: 13px; align-items: flex-start; }
.choice-letter { flex: 0 0 auto; display: grid; place-items: center; width: 32px; height: 32px; border-radius: 8px; color: var(--dark); background: var(--light-grey); font-weight: 800; }
.choice-card.selected { border-color: var(--blue); background: var(--blue-soft); box-shadow: 0 0 0 2px rgba(0,148,212,.14); }
.choice-card.selected .choice-letter { color: white; background: var(--blue); }
.choice-card.correct { border-color: #79b99a; background: var(--green-bg); }
.choice-card.incorrect { border-color: #da9299; background: var(--red-bg); }
.feedback { margin-top: 20px; padding: 16px 18px; border: 1px solid #cae9f6; border-left: 4px solid var(--blue); border-radius: 10px; background: var(--blue-soft); line-height: 1.55; }
.feedback.correct { border-color: #c5e3d3; border-left-color: var(--green); background: var(--green-bg); }
.feedback.incorrect { border-color: #f0c8cc; border-left-color: var(--red); background: var(--red-bg); }
.answer-key { margin-top: 14px; padding: 13px 15px; border: 1px solid rgba(40,45,49,.12); border-radius: 9px; color: var(--dark); background: rgba(255,255,255,.78); }
.answer-key > strong { display: block; margin-bottom: 7px; color: var(--dark); font-size: .76rem; letter-spacing: .04em; text-transform: uppercase; }
.answer-key ul { margin: 0; padding-left: 20px; }
.answer-key li { margin: 4px 0; line-height: 1.45; }

.gate-experience { padding: 18px; overflow: hidden; border: 1px solid var(--line); border-radius: 18px; background: linear-gradient(#fafcfd, #f1f4f6); }
.gate-experience.clinical-gates { min-height: 500px; padding: 154px 5% 66px; background: #f5f7f8 url("media/five-gates.png") center / cover no-repeat; }
.gate-grid { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 13px; perspective: 1400px; }
.gate { position: relative; min-height: 250px; padding: 0; overflow: visible; border: 0; border-radius: 10px; color: var(--dark); background: #e8f7fd; text-align: center; box-shadow: inset 0 0 0 2px rgba(0,148,212,.35), 0 10px 24px rgba(38,48,54,.13); transform-style: preserve-3d; }
.gate:hover .gate-door { border-color: var(--blue); box-shadow: 0 12px 24px rgba(0,148,212,.18); }
.gate-reveal { position: absolute; inset: 0; display: grid; place-items: center; padding: 16px 12px; overflow: hidden; border-radius: inherit; color: var(--dark); background: linear-gradient(160deg, #fff, var(--blue-soft)); }
.gate-reveal::before { content: "✓"; position: absolute; top: 14px; width: 30px; height: 30px; display: grid; place-items: center; border-radius: 50%; color: white; background: var(--blue); font-weight: 900; }
.gate-reveal span { margin-top: 32px; font-size: .75rem; font-weight: 700; line-height: 1.4; }
.gate-door { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 18px 12px; border: 2px solid #dce3e7; border-left: 5px solid #d4dce0; border-radius: inherit; background: linear-gradient(110deg, rgba(255,255,255,.98), rgba(229,235,238,.96)); box-shadow: 0 8px 18px rgba(38,48,54,.12); transform: rotateY(0); transform-origin: left center; backface-visibility: hidden; transition: transform .72s cubic-bezier(.2,.75,.25,1), box-shadow .25s ease; }
.gate-door::after { content: ""; position: absolute; inset: 9px; border: 1px solid rgba(0,148,212,.24); border-radius: 7px; pointer-events: none; }
.gate-door i { position: absolute; right: 11px; top: 50%; width: 7px; height: 25px; border-radius: 4px; background: var(--blue); box-shadow: 0 0 0 3px white; }
.gate-index { position: absolute; top: 18px; color: var(--blue); font-size: .64rem; font-weight: 850; letter-spacing: .1em; text-transform: uppercase; }
.gate strong { font-size: .85rem; line-height: 1.3; }
.gate small { display: block; margin-top: 9px; color: var(--grey); font-size: .7rem; line-height: 1.3; }
.gate.opened { box-shadow: inset 0 0 0 2px rgba(0,148,212,.48), 0 10px 24px rgba(38,48,54,.1); }
.gate.opened .gate-door { transform: rotateY(-104deg); box-shadow: 10px 8px 22px rgba(38,48,54,.18); }

.assessment-builder { display: grid; grid-template-columns: minmax(230px, .72fr) 1.28fr; gap: 24px; padding: 26px; border: 1px solid var(--line); border-radius: 18px; background: linear-gradient(145deg, #f7f9fa, #eef3f5); box-shadow: var(--shadow-soft); }
.stack-summary { display: flex; flex-direction: column; justify-content: space-between; padding: 24px; border-radius: 14px; color: white; background: var(--dark); }
.stack-summary h2 { color: white; }
.stack-summary p:not(.console-kicker) { color: #c5ccd0; line-height: 1.55; }
.stack-meter { display: flex; align-items: baseline; gap: 9px; margin-top: 30px; padding-top: 20px; border-top: 1px solid rgba(255,255,255,.14); }
.stack-meter strong { color: #57c5ee; font-size: 2rem; }
.stack-meter span { color: #b8c0c4; font-size: .75rem; }
.stack-layers { display: flex; flex-direction: column-reverse; justify-content: center; gap: 8px; }
.stack-layer { position: relative; display: grid; grid-template-columns: 44px 1fr 34px; align-items: center; gap: 12px; width: 100%; min-height: 66px; padding: 12px 14px; border: 1px solid #d4dce0; border-left: 5px solid #aeb8bd; border-radius: 11px; color: var(--dark); background: white; text-align: left; box-shadow: 0 5px 12px rgba(38,48,54,.06); transition: transform .25s ease, border-color .25s ease, box-shadow .25s ease, background .25s ease; }
.stack-layer:hover { transform: translateX(-3px); border-color: var(--blue); box-shadow: 0 8px 18px rgba(38,48,54,.1); }
.stack-number { display: grid; place-items: center; width: 38px; height: 38px; border-radius: 9px; color: var(--grey); background: var(--light-grey); font-size: .7rem; font-weight: 850; }
.stack-copy strong, .stack-copy small, .stack-detail { display: block; }
.stack-copy strong { font-size: .88rem; }
.stack-copy small { margin-top: 3px; color: var(--grey); font-size: .7rem; }
.stack-detail { max-height: 0; overflow: hidden; color: var(--grey); font-size: .78rem; line-height: 1.45; opacity: 0; transition: max-height .35s ease, margin .35s ease, opacity .25s ease; }
.stack-action { display: grid; place-items: center; width: 30px; height: 30px; border-radius: 8px; color: var(--blue); background: var(--blue-soft); font-size: 1.2rem; font-weight: 800; }
.stack-layer.built { min-height: 92px; border-color: #a9d9ed; border-left-color: var(--blue); background: linear-gradient(90deg, var(--blue-soft), white 34%); transform: translateX(-6px); }
.stack-layer.built .stack-number { color: white; background: var(--blue); }
.stack-layer.built .stack-detail { max-height: 90px; margin-top: 7px; opacity: 1; }
.stack-layer.built .stack-action { color: white; background: var(--green); }
.select-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 11px; }
.select-card { min-height: 92px; }
.select-card.selected { border-color: var(--blue); background: var(--blue-soft); box-shadow: inset 3px 0 0 var(--blue); }
.select-card.selected::after { content: "✓"; position: absolute; top: 11px; right: 13px; color: var(--blue); font-weight: 900; }

.sequence-list { display: grid; gap: 10px; }
.sequence-item { display: grid; grid-template-columns: 48px 1fr auto; align-items: center; gap: 12px; padding: 13px; border: 1px solid var(--line); border-radius: 12px; background: white; }
.sequence-number { display: grid; place-items: center; width: 34px; height: 34px; border-radius: 8px; color: var(--blue); background: var(--blue-soft); font-weight: 800; }
.move-buttons { display: flex; gap: 5px; }
.move-buttons button { width: 34px; height: 34px; border: 1px solid var(--line); border-radius: 7px; color: var(--dark); background: white; }
.move-buttons button:hover { border-color: var(--blue); color: var(--blue); }
.lane-board { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; }
.lane { min-height: 210px; padding: 15px; border: 1px dashed #b8c0c5; border-radius: 13px; }
.lane[data-lane="red"] { border-color: #d9a6aa; background: var(--red-bg); }
.lane[data-lane="amber"] { border-color: #e0c67f; background: var(--amber-bg); }
.lane[data-lane="green"] { border-color: #a6cfb9; background: var(--green-bg); }
.lane h3 { font-size: .88rem; line-height: 1.4; }
.medicine-bank { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 14px; padding: 15px; border: 1px solid var(--line); border-radius: 12px; background: var(--light-grey); }
.medicine { padding: 8px 11px; border: 1px solid var(--line); border-radius: 8px; color: var(--dark); background: white; font-weight: 700; }
.medicine.selected { border-color: var(--blue); color: white; background: var(--blue); }
.lane .medicine { margin: 4px 4px 0 0; }
.age-tabs { display: flex; gap: 8px; margin-bottom: 16px; padding: 4px; border-radius: 11px; background: var(--light-grey); }
.age-tabs button { flex: 1; padding: 11px; border: 0; border-radius: 8px; color: var(--grey); background: transparent; font-weight: 750; }
.age-tabs button.active { color: white; background: var(--blue); box-shadow: 0 3px 10px rgba(0,148,212,.18); }
.control-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; }
.control-card { padding-left: 54px; }
.control-card::before { content: ""; position: absolute; left: 17px; top: 18px; width: 21px; height: 21px; border: 2px solid #aab2b8; border-radius: 5px; }
.control-card.selected { border-color: var(--blue); background: var(--blue-soft); }
.control-card.selected::before { content: "✓"; display: grid; place-items: center; border-color: var(--blue); color: white; background: var(--blue); font-weight: 900; }

.result-panel { max-width: 720px; margin: 0 auto; padding: 40px; border-radius: 20px; color: white; background: var(--dark); text-align: center; }
.result-panel h1, .result-panel h2 { color: white; }
.score-ring { display: grid; place-items: center; width: 156px; height: 156px; margin: 22px auto; border-radius: 50%; background: conic-gradient(var(--blue) var(--score), rgba(255,255,255,.13) 0); }
.score-ring::before { content: ""; grid-area: 1/1; width: 122px; height: 122px; border-radius: 50%; background: var(--dark); }
.score-ring strong { position: relative; grid-area: 1/1; font-size: 2rem; }
.review-list { margin-top: 22px; text-align: left; }
.result-panel.passed { position: relative; display: flex; min-height: 570px; flex-direction: column; align-items: center; justify-content: center; overflow: hidden; border: 1px solid #d9e3e8; color: var(--dark); background: white url("media/course-complete.png") center / cover no-repeat; box-shadow: 0 24px 60px rgba(31,41,47,.13); animation: celebration-enter .7s cubic-bezier(.22,1,.36,1); }
.result-panel.passed::before { content: ""; position: absolute; inset: 0; background: radial-gradient(circle at center, rgba(255,255,255,.88) 0%, rgba(255,255,255,.62) 38%, rgba(255,255,255,.08) 78%); }
.result-panel.passed > * { position: relative; z-index: 1; }
.result-panel.passed h1 { color: var(--dark); font-size: clamp(2.5rem, 6vw, 4.3rem); animation: celebration-copy .65s .15s both cubic-bezier(.22,1,.36,1); }
.result-panel.passed h2 { margin: 8px 0 2px; color: var(--blue-dark); font-size: 1.15rem; font-weight: 750; animation: celebration-copy .65s .25s both cubic-bezier(.22,1,.36,1); }
.result-panel.passed .eyebrow { color: var(--blue); }
.result-panel.passed .score-ring { width: 142px; height: 142px; margin: 20px auto 14px; color: var(--dark); background: conic-gradient(var(--blue) var(--score), rgba(40,45,49,.1) 0); animation: score-arrive .75s .3s both cubic-bezier(.22,1,.36,1); }
.result-panel.passed .score-ring::before { width: 110px; height: 110px; background: rgba(255,255,255,.94); }
.result-panel.passed .result-message { margin: 5px 0 0; padding: 11px 16px; border: 1px solid #cbeaf7; border-radius: 9px; color: var(--blue-dark); background: rgba(232,247,253,.9); font-weight: 750; }
.celebration-check { display: grid; place-items: center; width: 58px; height: 58px; margin-bottom: 14px; border: 5px solid white; border-radius: 50%; color: white; background: var(--blue); box-shadow: 0 0 0 2px var(--blue), 0 12px 25px rgba(0,148,212,.24); font-size: 1.65rem; font-weight: 900; animation: check-pop .7s .05s both cubic-bezier(.2,1.5,.4,1); }
@keyframes celebration-enter { from { opacity: 0; transform: translateY(12px) scale(.985); } }
@keyframes celebration-copy { from { opacity: 0; transform: translateY(14px); } }
@keyframes score-arrive { from { opacity: 0; transform: scale(.65) rotate(-22deg); } }
@keyframes check-pop { from { opacity: 0; transform: scale(.25) rotate(-25deg); } }

.course-footer { display: grid; grid-template-columns: 130px 1fr 170px; align-items: center; gap: 16px; padding: 16px 30px; border-top: 1px solid var(--line); background: #fafbfc; }
.course-footer p { margin: 0; color: var(--grey); font-size: .8rem; text-align: center; }
.button { min-height: 44px; padding: 11px 18px; border: 1px solid transparent; border-radius: 9px; font-weight: 750; transition: transform .18s ease, background .18s ease, border-color .18s ease, box-shadow .18s ease; }
.button-primary { color: white; background: var(--blue); box-shadow: 0 6px 14px rgba(0,148,212,.18); }
.button-primary:hover { transform: translateY(-1px); background: var(--blue-dark); box-shadow: 0 8px 18px rgba(0,148,212,.24); }
.button-primary:disabled { cursor: not-allowed; color: #899197; background: #e1e5e7; box-shadow: none; transform: none; }
.button-ghost { border-color: var(--line); color: var(--dark); background: white; }
.button-ghost:hover { border-color: #b7c0c6; background: var(--light-grey); }

.modal { width: min(650px, calc(100% - 30px)); padding: 0; overflow: hidden; border: 1px solid var(--line); border-radius: 16px; box-shadow: 0 26px 80px rgba(25,31,35,.3); }
.modal::backdrop { background: rgba(25,31,35,.64); backdrop-filter: blur(3px); }
.modal-head { display: flex; justify-content: space-between; align-items: center; padding: 18px 22px; border-bottom: 1px solid var(--line); }
.modal-head h2 { margin: 0; font-size: 1.18rem; }
.close-button { width: 36px; height: 36px; border: 0; border-radius: 8px; color: var(--grey); background: var(--light-grey); font-size: 1.4rem; }
.modal-body { padding: 22px; line-height: 1.6; }
.modal-body ul { padding-left: 22px; }
.support-contact { margin-top: 20px; padding: 15px 16px; border: 1px solid #cdebf8; border-radius: 10px; background: var(--blue-soft); }
.support-contact strong { color: var(--dark); }
.support-contact p { margin: 6px 0 0; color: var(--grey); }
.support-contact a { color: var(--blue-dark); font-weight: 750; overflow-wrap: anywhere; }
.modal-actions { display: flex; justify-content: flex-end; gap: 10px; margin-top: 24px; }
.toast { position: fixed; left: 50%; bottom: 22px; z-index: 40; padding: 10px 16px; border-radius: 9px; color: white; background: var(--dark); box-shadow: var(--shadow); opacity: 0; pointer-events: none; transform: translate(-50%, 18px); transition: .25s ease; }
.toast.show { opacity: 1; transform: translate(-50%, 0); }

@media (max-width: 780px) {
  .course-shell { width: 100%; min-height: 100vh; margin: 0; border: 0; border-radius: 0; }
  .topbar { padding: 14px 16px; align-items: flex-start; }
  .brand small { display: none; }
  .top-actions { flex-wrap: wrap; justify-content: flex-end; }
  .icon-button { padding: 8px; font-size: .75rem; }
  .progress-region { padding-inline: 18px; }
  .screen { padding: 34px 20px 42px; }
  .hero { min-height: 560px; padding: 30px 24px; align-items: end; background-image: linear-gradient(0deg, #fff 0%, rgba(255,255,255,.98) 48%, rgba(255,255,255,.12) 82%), url("media/course-cover.png"); background-position: 66% center; }
  .hero-badge { display: none; }
  .metric-row { grid-template-columns: repeat(2, 1fr); }
  .video-placeholder { grid-template-columns: 1fr; gap: 28px; padding: 28px 24px; }
  .portrait-video-frame { width: min(250px, 100%); }
  .landscape-video-lesson { grid-template-columns: 1fr; }
  .lesson-video-summary { min-height: 250px; }
  .console-layout, .verification-layout, .connection-state { grid-template-columns: 1fr; }
  .console-call { min-height: 480px; }
  .compact-call { min-height: 420px; }
  .console-workflow, .verification-panel, .connection-scenario { padding: 26px 22px; }
  .verification-panel .select-grid { grid-template-columns: 1fr; }
  .ehr-layout { grid-template-columns: 1fr; }
  .ehr-sidebar { border-right: 0; border-bottom: 1px solid var(--line); }
  .ehr-editor { padding: 22px 18px; }
  .ehr-editor .select-grid { grid-template-columns: 1fr; }
  .risk-timeline { grid-template-columns: 1fr; gap: 8px; padding: 20px; }
  .risk-line { width: 3px; height: 22px; margin: 0 auto; background: linear-gradient(var(--blue), #b8ddea); }
  .prescribing-instructions { align-items: flex-start; }
  .prescribing-instructions > i { width: 25px; margin-top: 15px; }
  .closeout-panel .select-grid { grid-template-columns: 1fr; }
  .medication-case { grid-template-columns: 1fr; }
  .medicine-profile, .safeguard-status { border-right: 0; border-bottom: 1px solid var(--line); }
  .medication-tray .medicine-bank { grid-template-columns: repeat(2, minmax(0,1fr)); }
  .tray-photo { min-height: 165px; }
  .module-grid, .choice-grid, .card-grid, .control-grid { grid-template-columns: 1fr; }
  .roadmap { min-height: 0; aspect-ratio: auto; overflow: visible; padding: 24px 18px; background: linear-gradient(90deg, transparent 35px, #c9eaf7 35px, #c9eaf7 39px, transparent 39px), linear-gradient(#fafcfd, #fff); }
  .roadmap .module-grid { position: relative; inset: auto; display: grid; grid-template-columns: 1fr; gap: 14px; min-height: 0; padding: 0; }
  .roadmap .module-card, .roadmap .module-card:nth-child(n) { position: relative; left: auto; top: auto; width: auto; height: auto; min-height: 150px; margin: 0 0 0 38px; padding: 17px; overflow: visible; border-radius: 14px; transform: none; }
  .roadmap .module-card:hover, .roadmap .module-card:focus-visible, .roadmap .module-card:nth-child(6):hover, .roadmap .module-card:nth-child(6):focus-visible { width: auto; height: auto; padding: 17px; transform: none; }
  .roadmap .module-number { margin: 0 9px 10px 0; }
  .roadmap .module-card strong, .roadmap .module-card:hover strong, .roadmap .module-card:focus-visible strong { display: inline-block; margin: 0; line-height: 32px; }
  .roadmap .module-title, .roadmap .module-card:hover .module-title, .roadmap .module-card:focus-visible .module-title { max-height: none; margin: 2px 70px 7px 0; opacity: 1; }
  .roadmap .module-card p, .roadmap .module-card small, .roadmap .status-chip { max-height: none; opacity: 1; pointer-events: auto; }
  .roadmap .status-chip { top: 20px; right: 16px; }
  .roadmap .module-card::before { content: ""; position: absolute; left: -38px; top: 25px; width: 18px; height: 18px; border: 4px solid white; border-radius: 50%; background: var(--blue); box-shadow: 0 0 0 2px #9fd9f0; }
  .roadmap .module-card.complete::before { background: var(--green); box-shadow: 0 0 0 2px #afd6c3; }
  .roadmap .assessment-card::before { background: var(--dark); box-shadow: 0 0 0 2px #bfc7cb; }
  .roadmap .assessment-card.ready::before { background: var(--blue); box-shadow: 0 0 0 2px #9fd9f0; }
  .roadmap .module-card p { display: block; overflow: visible; font-size: .82rem; -webkit-line-clamp: initial; }
  .roadmap-label { display: none; }
  .gate-experience.clinical-gates { min-height: 0; padding: 18px; background: linear-gradient(#fafcfd, #f1f4f6); }
  .gate-grid { grid-template-columns: repeat(2, 1fr); gap: 18px; }
  .gate { min-height: 220px; }
  .assessment-builder { grid-template-columns: 1fr; padding: 18px; }
  .stack-summary { padding: 22px; }
  .stack-layer.built { transform: none; }
  .select-grid { grid-template-columns: repeat(2, 1fr); }
  .lane-board { grid-template-columns: 1fr; }
  .course-footer { grid-template-columns: 100px 1fr 126px; padding: 13px 14px; }
  .course-footer p { display: none; }
}

@media (max-width: 460px) {
  .brand-mark { width: 42px; height: 38px; }
  .brand strong { font-size: .9rem; }
  .top-actions { gap: 5px; }
  .icon-button { border-color: transparent; background: var(--light-grey); }
  .gate-grid, .select-grid { grid-template-columns: 1fr; }
  .gate { min-height: 200px; }
  .medication-tray .medicine-bank { grid-template-columns: 1fr; }
  .course-footer { grid-template-columns: 1fr 1.25fr; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: .01ms !important; transition-duration: .01ms !important; }
}
