:root {
  color-scheme: light;
  font-family: Inter, system-ui, -apple-system, "Segoe UI", sans-serif;
  color: #18251d;
  background: #f5f8f6;
  --ep-green: #187b30;
  --ep-dark: #116327;
  --ep-muted: #536457;
  --ep-border: #dce7df;
}
*, *::before, *::after { box-sizing: border-box; }
[hidden] { display: none !important; }
body { margin: 0; line-height: 1.55; }
h1, h2, p, dl, dd { margin: 0; overflow-wrap: anywhere; }
h1 { font-size: clamp(28px, 4vw, 42px); line-height: 1.15; letter-spacing: -.035em; }
h2 { font-size: 19px; line-height: 1.35; letter-spacing: -.015em; }
a { color: var(--ep-dark); }
button, input { font: inherit; }
button:disabled { opacity: .55; cursor: not-allowed; }
:focus-visible { outline: 2px solid var(--ep-dark); outline-offset: 3px; }
.ep-shell { width: min(calc(100% - 48px), 1200px); margin-inline: auto; }
.ep-topbar { background: #fff; border-bottom: 1px solid var(--ep-border); }
.ep-topbar-inner { min-height: 74px; display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.ep-brand { display: flex; align-items: center; gap: 11px; min-width: 0; }
.ep-brand img { flex: 0 0 42px; width: 42px; height: 42px; object-fit: contain; }
.ep-brand strong, .ep-brand span { display: block; overflow-wrap: anywhere; }
.ep-brand strong { font-size: 15px; }
.ep-brand span { font-size: 12px; color: var(--ep-muted); }
.ep-main { padding-block: 28px 44px; }
.ep-panel { min-width: 0; background: #fff; border: 1px solid var(--ep-border); border-radius: 14px; box-shadow: 0 2px 4px #193b2310; }
.ep-eyebrow { font-size: 12px; color: var(--ep-dark); font-weight: 700; letter-spacing: .065em; text-transform: uppercase; }
.ep-muted { color: var(--ep-muted); font-size: 14px; }
.ep-caption { color: var(--ep-muted); font-size: 13px; }
.ep-button {
  display: inline-flex; justify-content: center; align-items: center; gap: 8px; min-height: 44px;
  max-width: 100%; padding: 8px 14px; border: 1px solid transparent; border-radius: 8px; cursor: pointer;
  font-size: 14px; line-height: 1.35; font-weight: 650; text-align: center; text-decoration: none; overflow-wrap: anywhere;
}
.ep-primary { color: #fff; background: var(--ep-green); border-color: var(--ep-green); }
.ep-primary:hover:not(:disabled) { background: var(--ep-dark); border-color: var(--ep-dark); }
.ep-quiet { color: var(--ep-dark); background: #fff; border-color: #c5d8c9; }
.ep-quiet:hover { background: #edf7ef; border-color: #9ec6a6; }
.ep-login {
  display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, .86fr);
  max-width: 1010px; margin: clamp(12px, 6vw, 76px) auto 0; gap: 20px; align-items: stretch;
}
.ep-login-intro, .ep-hero { background: #eaf5ed; border: 1px solid #d5e8d9; border-radius: 15px; }
.ep-login-intro, .ep-login-card { padding: clamp(22px, 4vw, 36px); }
.ep-login-intro { display: grid; align-content: center; gap: 12px; grid-column: 1; grid-row: 1; }
.ep-login-intro > p:not(.ep-eyebrow), .ep-hero > p:not(.ep-eyebrow) { max-width: 63ch; color: #405849; }
.ep-login-steps { display: grid; gap: 10px; list-style: none; padding: 0; margin: 10px 0 0; }
.ep-login-steps li { display: flex; align-items: center; gap: 10px; font-size: 14px; font-weight: 600; }
.ep-login-steps span, .ep-step {
  display: inline-grid; place-items: center; flex: 0 0 auto; width: 32px; height: 32px;
  border-radius: 9px; background: #d6eddb; color: var(--ep-dark); font-weight: 700;
}
.ep-login-card { display: grid; align-content: center; gap: 12px; grid-column: 2; }
.ep-form, .ep-field { display: grid; gap: 14px; min-width: 0; }
.ep-field { gap: 6px; }
.ep-field label { font-size: 14px; font-weight: 650; }
.ep-field input { min-width: 0; min-height: 46px; padding: 8px 11px; border: 1px solid #b9cbbd; border-radius: 8px; background: #fff; color: #18251d; }
.ep-field input::placeholder { color: #607166; }
.ep-login-note { border-top: 1px solid var(--ep-border); padding-top: 12px; }
.ep-hero { display: grid; gap: 9px; margin-bottom: 18px; padding: clamp(18px, 3vw, 28px); }
.ep-course-grid { list-style: none; display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 280px), 1fr)); gap: 14px; margin: 0; padding: 0; }
.ep-course { display: flex; flex-direction: column; gap: 12px; padding: 17px; }
.ep-course-copy { white-space: pre-wrap; overflow-wrap: anywhere; }
.ep-summary { display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 3; overflow: hidden; }
.ep-course-meta, .ep-quiz-meta { display: flex; gap: 8px 20px; flex-wrap: wrap; font-size: 14px; }
.ep-course-meta { margin-top: auto; }
.ep-course-meta dt, .ep-quiz-meta dt { color: var(--ep-muted); font-size: 12px; }
.ep-course-meta dd, .ep-quiz-meta dd { font-weight: 650; font-variant-numeric: tabular-nums; }
.ep-card-action { padding-top: 10px; border-top: 1px solid var(--ep-border); }
.ep-tags, .ep-paging, .ep-submit-row { display: flex; gap: 8px 10px; flex-wrap: wrap; align-items: center; }
.ep-tag { display: inline-flex; align-items: center; border-radius: 999px; padding: 3px 9px; font-size: 12px; font-weight: 650; background: #e9eeeb; color: #374a3d; }
.ep-tag-passed { background: #dff2e3; color: var(--ep-dark); }
.ep-tag-in_progress { background: #fff1d9; color: #70470b; }
.ep-tag-overdue, .ep-tag-failed { background: #ffebef; color: #982238; }
.ep-paging { justify-content: center; margin-top: 18px; }
.ep-empty { display: grid; justify-items: center; text-align: center; gap: 10px; padding: 28px 18px; }
.ep-back { display: inline-block; margin-bottom: 14px; font-size: 14px; font-weight: 650; text-underline-offset: 3px; }
.ep-detail-hero { grid-template-columns: minmax(0, 1fr) auto; gap: 14px 22px; }
.ep-detail-hero h1 { margin-block: 5px 7px; }
.ep-detail-hero .ep-course-copy { max-width: 78ch; }
.ep-detail-meta { display: grid; align-content: start; gap: 8px; }
.ep-stage { display: grid; gap: 13px; margin-top: 14px; padding: clamp(16px, 3vw, 24px); }
.ep-stage > .ep-button { justify-self: start; }
.ep-stage-heading { display: flex; align-items: flex-start; gap: 11px; }
.ep-stage-heading .ep-muted { margin-top: 2px; }
.ep-message { padding: 10px 13px; border: 1px solid var(--ep-border); border-radius: 9px; font-size: 14px; }
.ep-message:empty { display: none; }
.ep-notice { background: #eef5ef; color: #274631; }
.ep-error { background: #fff1f3; border-color: #f1c5cc; color: #99243b; }
.ep-warning { background: #fff5e5; border-color: #efdab5; color: #71460d; }
.ep-quiz-meta > div { background: #f4f7f5; border: 1px solid var(--ep-border); border-radius: 8px; padding: 8px 12px; min-width: 110px; }
.ep-test-progress { display: grid; gap: 4px; padding: 10px 0; color: var(--ep-muted); font-size: 13px; }
.ep-test-progress progress { width: 100%; max-width: 36rem; height: 10px; accent-color: var(--ep-green); }
.ep-question { min-inline-size: 0; margin: 0; padding: 9px 14px 14px; border: 1px solid var(--ep-border); border-radius: 10px; }
.ep-question legend { max-width: 100%; padding-inline: 4px; font-weight: 650; }
.ep-question-number { display: inline-block; min-width: 23px; padding: 2px 5px; margin-right: 7px; border-radius: 5px; background: #e3f1e6; color: var(--ep-dark); text-align: center; font-size: 12px; }
.ep-options { display: grid; gap: 6px; margin-top: 7px; }
.ep-option { display: flex; align-items: flex-start; gap: 9px; padding: 8px 10px; min-height: 40px; border: 1px solid var(--ep-border); border-radius: 7px; cursor: pointer; }
.ep-option:hover, .ep-option:has(input:checked) { background: #eaf6ed; border-color: #a1caab; }
.ep-option input { flex: 0 0 auto; margin: 4px 0 0; accent-color: var(--ep-green); }
@media (max-width: 760px) {
  .ep-login { grid-template-columns: minmax(0, 1fr); gap: 12px; margin-top: 0; }
  .ep-login-card, .ep-login-intro { grid-row: auto; grid-column: auto; }
  .ep-detail-hero { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 460px) {
  .ep-shell { width: calc(100% - 24px); }
  .ep-main { padding-block: 16px 32px; }
  .ep-topbar-inner { min-height: 64px; }
  .ep-brand { gap: 7px; }
  .ep-brand img { width: 34px; height: 34px; flex-basis: 34px; }
  .ep-brand strong { font-size: 13px; }
  .ep-brand span { font-size: 11px; }
  .ep-card-action .ep-button { width: 100%; }
  .ep-course-meta, .ep-quiz-meta { gap: 8px; }
}

.ep-tag-reading { background:#edf8f0; color:#176e2a; }
.ep-open-state { margin-bottom:12px; }
.ep-open-state:has([hidden]) { margin-bottom:0; }

.ep-draft-panel { padding:12px 14px; border:1px solid #dce7df; border-radius:10px; background:#f7faf8; margin-bottom:14px; }
.ep-draft-panel .ep-submit-row { margin-top:8px; }
