* { box-sizing: border-box; }
:root {
  color-scheme: light;
  --ink: #1f2940;
  --muted: #526077;
  --indigo: #5144c7;
  --indigo-dark: #3c309f;
  --line: #dbe1ee;
  --surface: #fff;
  --background: #f4f6fc;
  --radius: 17px;
}
body { margin: 0; color: var(--ink); background: var(--background); font: 1rem/1.55 system-ui, -apple-system, "Segoe UI", sans-serif; }
a { color: var(--indigo-dark); font-weight: 650; }
a:hover { text-decoration-thickness: 2px; }
button, input, textarea, select { font: inherit; }
button { cursor: pointer; }
:focus-visible { outline: 3px solid #7266e2; outline-offset: 4px; }
h1, h2, h3, p { margin: 0; }
h1 { font-size: clamp(1.9rem, 4vw, 2.9rem); line-height: 1.12; letter-spacing: -.045em; }
h2 { font-size: 1.25rem; line-height: 1.3; letter-spacing: -.02em; }
h3 { font-size: 1.05rem; }
.skip { position: absolute; inset-block-start: 8px; inset-inline-start: 8px; transform: translateY(-160%); z-index: 5; background: white; padding: 8px 12px; }
.skip:focus { transform: none; }
.top { background: #fff; border-bottom: 1px solid var(--line); }
.top-inner { max-width: 1216px; min-height: 72px; padding: .75rem 1.5rem; margin: auto; display: flex; gap: 1.7rem; align-items: center; }
.brand { display: inline-flex; align-items: center; color: #202641; text-decoration: none; font-size: 1.32rem; letter-spacing: -.035em; font-weight: 780; white-space: nowrap; }
.brand > span:last-child { color: var(--indigo); }
.mark { width: 31px; height: 31px; background: #5445cd; border-radius: 8px; color: white; position: relative; display: grid; grid-template-columns: repeat(2, 5px); grid-template-rows: repeat(2, 5px); align-content: center; justify-content: center; gap: 3px; margin-right: 9px; }
.mark i { background: white; border-radius: 1.25px; }
.mark i:last-child { opacity: .55; }
nav { display: flex; flex-wrap: wrap; gap: .2rem; }
nav a { display: block; padding: .45rem .7rem; color: var(--muted); border-radius: 8px; font-size: .91rem; text-decoration: none; }
nav a:hover, nav a.current { background: #eeebff; color: var(--indigo-dark); }
.account { margin-left: auto; display: flex; gap: .75rem; align-items: center; font-size: .91rem; }
.account span { overflow-wrap: anywhere; }
.wrap { width: min(100%, 1216px); margin: auto; padding: 2.7rem 1.5rem 4rem; }
.wrap.guest { max-width: 1050px; padding-top: clamp(2rem, 9vh, 6rem); }
.login-layout { display: grid; grid-template-columns: 1.1fr 1fr; border-radius: 24px; background: #fff; overflow: hidden; border: 1px solid var(--line); box-shadow: 0 16px 52px #29227212; min-height: 435px; }
.login-intro { display: flex; flex-direction: column; justify-content: space-between; gap: 3rem; padding: clamp(1.7rem, 5vw, 3rem); background: radial-gradient(ellipse at right top, #6152d9, transparent 62%), #2b245c; color: white; }
.login-copy h1 { max-width: 320px; }
.login-copy p { margin-top: 1rem; color: #ece9ff; max-width: 260px; }
.motif { display: grid; grid-template-columns: repeat(3, 34px); grid-auto-rows: 34px; gap: 7px; width: max-content; transform: rotate(-10deg); margin: 12px 0 0 10px; }
.motif i { border: 1px solid #aca2ff; border-radius: 9px; background: #aa9dfd24; }
.motif i:nth-child(2), .motif i:nth-child(6), .motif i:nth-child(7) { background: #b7adff; }
.motif i:nth-child(5) { background: #f6edff; }
.login-form { align-self: center; padding: clamp(1.7rem, 5vw, 3rem); }
.login-form h2 { font-size: 1.65rem; }
.login-form p { margin: .45rem 0 1.6rem; }
.login-form .button { width: 100%; margin-top: .35rem; }
.intro { margin-top: .6rem; }
.muted { color: var(--muted); }
.page-head, .section-head { display: flex; justify-content: space-between; align-items: center; gap: 1rem; }
.page-head { margin-bottom: 1.5rem; }
.section-head { margin: 2rem 0 .9rem; }
.panel, .table-box { border: 1px solid var(--line); background: var(--surface); border-radius: var(--radius); }
.panel { padding: clamp(1.15rem, 2.8vw, 1.6rem); }
.empty { margin-top: 1.2rem; }
.empty p { color: var(--muted); margin-top: .4rem; }
.hero { margin: 1.6rem 0; display: flex; align-items: center; justify-content: space-between; gap: 1rem; background: radial-gradient(ellipse at top right, #6554d3, transparent 61%), #2f2761; padding: clamp(1.2rem, 4vw, 2rem); border-radius: var(--radius); color: white; }
.hero h2 { font-size: clamp(1.25rem, 3vw, 1.75rem); }
.hero p { margin-top: .4rem; color: #efebff; }
.hero-count { display: grid; text-align: center; color: #f3efff; padding: .45rem .85rem; border: 1px solid #e8e0ff65; border-radius: 12px; min-width: 6rem; }
.hero-count strong { color: #fff; font-size: clamp(1.3rem, 3vw, 2.15rem); line-height: 1.2; white-space: nowrap; }
.hero-count span { font-size: .88rem; }
.grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 275px), 1fr)); gap: 1rem; margin-top: 1.35rem; }
.exam-card { display: flex; flex-direction: column; align-items: flex-start; gap: .8rem; }
.exam-card p { color: var(--muted); flex: 1; }
.card-meta { display: flex; flex-wrap: wrap; gap: .45rem .8rem; list-style: none; margin: 0; padding: .75rem 0 0; width: 100%; border-top: 1px solid var(--line); color: var(--muted); font-size: .91rem; }
.card-meta li + li::before { content: "·"; margin-right: .8rem; font-weight: 700; }
.button { display: inline-flex; justify-content: center; align-items: center; gap: .4rem; width: fit-content; min-height: 42px; padding: .55rem .95rem; border: 1px solid transparent; border-radius: 9px; color: white; background: var(--indigo); text-decoration: none; font-size: .94rem; line-height: 1.25; font-weight: 700; }
.button:hover { background: var(--indigo-dark); }
.button.secondary { color: var(--indigo-dark); background: #eeebff; border-color: #e2ddff; }
.button.secondary:hover { background: #e2dcff; }
.button.subtle { min-height: 35px; color: var(--ink); background: white; border-color: var(--line); }
.button.subtle:hover { background: var(--background); }
.button:disabled { opacity: .65; cursor: wait; }
.pill { display: inline-flex; border-radius: 20px; padding: .2rem .63rem; font-size: .88rem; font-weight: 700; white-space: nowrap; }
.good { color: #16604b; background: #e6f6ee; }
.bad { color: #943145; background: #fff0f2; }
.neutral { color: #535d75; background: #edf0f6; }
.narrow { max-width: 750px; margin-top: 1.35rem; }
.narrow h2 { margin-bottom: 1rem; }
.fields { display: grid; gap: .95rem; }
label, legend { font-weight: 650; }
label { display: grid; gap: .33rem; }
input:not([type=radio], [type=checkbox]), textarea, select { width: 100%; padding: .65rem .75rem; background: white; color: var(--ink); border: 1px solid #aebad1; border-radius: 8px; }
textarea { resize: vertical; min-height: 44px; }
select { appearance: none; background-image: linear-gradient(45deg, transparent 50%, #655a94 50%), linear-gradient(135deg, #655a94 50%, transparent 50%); background-position: calc(100% - 19px) 50%, calc(100% - 13px) 50%; background-size: 6px 6px; background-repeat: no-repeat; padding-right: 2rem; }
fieldset { border: 0; padding: 0; min-width: 0; margin: 0; }
fieldset legend { padding: 0; margin-bottom: .4rem; }
.split { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .7rem; }
.check { display: flex; align-items: center; gap: .55rem; }
input[type=checkbox], input[type=radio] { accent-color: var(--indigo); inline-size: 1.02rem; block-size: 1.02rem; }
.actions { display: flex; gap: .55rem; flex-wrap: wrap; }
.back { display: inline-block; margin-bottom: .8rem; }
.table-box { overflow-x: auto; margin-top: .9rem; }
table { width: 100%; border-collapse: collapse; text-align: left; }
th, td { padding: .75rem .95rem; vertical-align: top; border-bottom: 1px solid var(--line); }
th { background: #f8f9fe; color: #404b66; font-size: .9rem; }
tr:last-child td { border-bottom: 0; }
td small { display: block; color: var(--muted); margin-top: .2rem; }
.alert { border-radius: 9px; padding: .75rem 1rem; margin-bottom: 1rem; }
.alert.error { color: #85263b; background: #ffecef; }
.alert.success { color: #16604b; background: #e5f6ee; }
.attempt-layout { display: grid; grid-template-columns: minmax(0, 1fr) 252px; gap: 1.25rem; align-items: start; }
.attempt-sidebar { grid-column: 2; grid-row: 1; position: sticky; top: .7rem; z-index: 1; display: grid; gap: .45rem; }
.attempt-sidebar .button { width: 100%; }
.timer { line-height: 1.1; font-size: 2.15rem; letter-spacing: -.035em; color: var(--indigo-dark); font-variant-numeric: tabular-nums; }
.timer.urgent { color: #a12f44; }
.save-state { min-height: 1.4em; color: var(--muted); font-size: .88rem; }
.answered { font-size: .92rem; }
.question-nav { display: grid; grid-template-columns: repeat(5, 1fr); gap: .3rem; max-height: 31vh; overflow: auto; padding: .25rem .18rem .4rem; }
.question-nav a { text-align: center; color: var(--ink); background: #eef0f7; border-radius: 6px; padding: .16rem; text-decoration: none; font-size: .88rem; }
.question-nav a.answered-link { color: var(--indigo-dark); background: #e6dfff; box-shadow: inset 0 0 0 1px #aba0e9; }
.question-list { display: grid; gap: 1rem; min-width: 0; }
.attempt-layout .question-list { grid-column: 1; grid-row: 1; }
.question { scroll-margin-top: 1rem; }
.question legend { padding: .14rem .65rem; border: 1px solid #e1ddfa; background: #f4f1ff; color: var(--indigo-dark); border-radius: 20px; }
.prompt { white-space: pre-wrap; overflow-wrap: anywhere; }
.question-image { display: block; max-width: 100%; width: auto; height: auto; margin: .7rem 0; border-radius: 5px; }
.options { display: grid; gap: .55rem; margin-top: .85rem; }
.option { display: flex; align-items: center; gap: .63rem; font-weight: 500; padding: .55rem .7rem; border: 1px solid var(--line); border-radius: 8px; cursor: pointer; overflow-wrap: anywhere; }
.option:hover, .option:has(input:checked) { background: #f5f2ff; border-color: #a89be5; }
.option > :first-child { flex: none; }
.letter { color: var(--indigo-dark); font-weight: 750; }
.stats, .compare { display: grid; gap: .7rem; }
.stats { grid-template-columns: repeat(3, 1fr); }
.stats div { padding: .75rem 1rem; border: 1px solid var(--line); border-radius: 10px; background: white; color: var(--muted); }
.stats strong { color: var(--ink); }
.review .section-head { margin: 0 0 .75rem; }
.compare { grid-template-columns: repeat(2, minmax(0, 1fr)); margin-bottom: 0; }
.compare div { border-radius: 8px; padding: .55rem .7rem; overflow-wrap: anywhere; }
.compare dt { font-weight: 750; }
.compare dd { margin: .2rem 0 0; }
.note { color: var(--muted); margin-top: .8rem; }
@media (max-width: 780px) {
  .top-inner { gap: .5rem .85rem; flex-wrap: wrap; padding-inline: 1rem; }
  nav { order: 2; width: 100%; }
  .wrap { padding-inline: 1rem; padding-top: 1.6rem; }
  .attempt-layout { display: flex; flex-direction: column; }
  .attempt-sidebar { top: 0; width: 100%; grid-template-columns: 1fr auto; align-items: center; padding: .6rem .8rem; box-shadow: 0 3px 8px #29227210; }
  .attempt-sidebar .muted, .attempt-sidebar .question-nav { display: none; }
  .attempt-sidebar .timer { grid-column: 1; grid-row: 1; font-size: 1.35rem; }
  .attempt-sidebar .save-state { grid-column: 1; grid-row: 2; }
  .attempt-sidebar .answered { grid-column: 2; grid-row: 2; text-align: right; font-size: .83rem; }
  .attempt-sidebar .button { grid-column: 2; grid-row: 1; width: auto; min-height: 35px; font-size: .85rem; padding: .35rem .55rem; }
  .attempt-layout .question-list { width: 100%; }
  .question { scroll-margin-top: 6rem; }
}
@media (max-width: 560px) {
  .login-layout { grid-template-columns: 1fr; }
  .login-intro { gap: 1.2rem; }
  .motif { grid-template-columns: repeat(3, 19px); grid-auto-rows: 19px; gap: 4px; margin: 3px; }
  .motif i { border-radius: 5px; }
  .page-head { flex-wrap: wrap; }
  .stats div { padding: .55rem; font-size: .85rem; }
  .stats strong { display: block; }
  .compare { grid-template-columns: 1fr; }
}

.medical-note { background: #edf0f8; margin-top: 1rem; }
.solutions-columns { display: grid; grid-template-columns: 220px minmax(0, 1fr); gap: 1.2rem; margin-top: 1.3rem; align-items: start; }
.solutions-index { position: sticky; top: 1rem; }
.solutions-index .question-nav { max-height: 62vh; margin-top: .65rem; }
.solution { padding: 0; scroll-margin-top: 1rem; }
.solution summary { cursor: pointer; padding: 1rem 1.3rem; color: var(--indigo-dark); }
.solution summary:focus-visible { outline-offset: -4px; border-radius: var(--radius); }
.solution summary .pill { margin-left: .5rem; }
.solution-preview { display: block; margin: .3rem 0 0 1.1rem; color: var(--muted); overflow-wrap: anywhere; }
.solution-body { padding: 1.15rem 1.3rem 1.4rem; border-top: 1px solid var(--line); }
.solution-body h3 { margin: .85rem 0 .35rem; }
.solution-options { display: grid; gap: .35rem; padding: 0; list-style: none; }
.solution-options strong { color: var(--indigo-dark); margin-right: .35rem; }
.solution-answer { border-radius: 8px; padding: .65rem .8rem; }
.source-page { margin: .8rem 0 .35rem; font-size: .88rem; }
.solution-references { margin-top: 1.2rem; }
.solution-references li + li { margin-top: .35rem; }
@media (max-width: 710px) {
  .solutions-columns { grid-template-columns: 1fr; }
  .solutions-index { position: static; }
  .solutions-index .question-nav { grid-template-columns: repeat(auto-fill,minmax(2rem,1fr)); max-height: 9rem; }
}

