/* 신규 진단·전략 페이지에서만 사용하는 한모 독립 실험실 스타일입니다. */
body.hanmo-lab{--lab-text:#f2f5f8;--lab-muted:#b8c9d5;--lab-border:#38556a;color:var(--lab-text);}
body.hanmo-ui.hanmo-refined .hanmo-main.lab-layout{width:min(1184px,100%);max-width:1184px;margin:0 auto;padding:28px 32px 36px;}
.hanmo-lab .lab-heading{max-width:820px;margin:0 0 46px;}
.hanmo-lab .lab-kicker{margin:0 0 14px;color:#f4c76c;font-size:12px;font-weight:700;letter-spacing:.12em;}
.hanmo-lab .lab-heading h1{margin:0 0 14px;color:var(--lab-text);font-weight:650;font-size:clamp(26px,3vw,34px);letter-spacing:-.03em;}
.hanmo-lab .lab-heading>p:last-child{max-width:78ch;margin:0;color:var(--lab-muted);font-size:15px;line-height:1.8;word-break:keep-all;}
.hanmo-lab .lab-panel{margin:0 0 35px;padding:28px 0;border-top:1px solid var(--lab-border);background:transparent;box-shadow:none;}
.hanmo-lab .lab-section-heading{display:flex;align-items:baseline;justify-content:space-between;gap:16px;flex-wrap:wrap;margin:0 0 20px;}
.hanmo-lab .lab-section-heading h2{margin:0;font-weight:600;color:var(--lab-text);font-size:21px;}
.hanmo-lab .lab-minor{color:var(--lab-muted);font-size:12px;}
.hanmo-lab .lab-explainer{display:grid;gap:8px;margin:0 0 24px;color:var(--lab-muted);font-size:14px;}
.hanmo-lab .lab-explainer p{margin:0;line-height:1.7;}
.hanmo-lab .lab-explainer strong{color:var(--lab-text);font-weight:600;}
.hanmo-lab .lab-check{display:flex;align-items:flex-start;gap:12px;margin:0 0 24px;padding:17px 18px;border:1px solid var(--lab-border);border-radius:4px;cursor:pointer;}
.hanmo-lab .lab-check input{margin-top:4px;accent-color:#f4c76c;}
.hanmo-lab .lab-check span{font-size:14px;}
.hanmo-lab .lab-check small{display:block;margin-top:5px;color:var(--lab-muted);font-size:12px;}
.hanmo-lab .lab-actions{display:flex;gap:12px;flex-wrap:wrap;margin:20px 0;}
.hanmo-lab .lab-button{border:1px solid #62849a;border-radius:4px;padding:11px 17px;min-height:44px;background:transparent;color:var(--lab-text);cursor:pointer;font:600 14px var(--hm-font,system-ui);}
.hanmo-lab .lab-button.primary{background:#f4c76c;border-color:#f4c76c;color:#081725;}
.hanmo-lab .lab-button:hover:not(:disabled){border-color:#f4c76c;}
.hanmo-lab .lab-button:focus-visible,.hanmo-lab input:focus-visible,.hanmo-lab select:focus-visible,.hanmo-lab .lab-key-target:focus-visible{outline:3px solid #f4c76c;outline-offset:3px;}
.hanmo-lab .lab-button:disabled{opacity:.45;cursor:not-allowed;}
.hanmo-lab .lab-status{min-height:1.8em;margin:14px 0;color:#e5cc98;font-size:14px;}
.hanmo-lab .lab-key-panel{padding:22px 0 10px;}
.hanmo-lab .lab-key-panel p{margin:0 0 12px;color:var(--lab-muted);}
.hanmo-lab .lab-key-target{min-height:100px;width:100%;background:#0a2637;border:1px dashed #88a8bc;border-radius:5px;color:var(--lab-text);font:500 16px var(--hm-font,system-ui);cursor:default;}
.hanmo-lab .lab-summary{padding:14px 0;margin:0 0 20px;color:#e9d39d;font-size:14px;line-height:1.8;}
.hanmo-lab .lab-stats{margin:0 0 20px;}
.hanmo-lab .lab-stats>div{display:grid;grid-template-columns:minmax(200px,30%) 1fr;gap:20px;padding:15px 0;border-top:1px solid #294557;}
.hanmo-lab .lab-stats dt{font-size:14px;color:var(--lab-muted);}
.hanmo-lab .lab-stats dd{margin:0;font-weight:600;font-variant-numeric:tabular-nums;overflow-wrap:anywhere;font-size:15px;}
.hanmo-lab .lab-footnote{font-size:13px;line-height:1.7;color:var(--lab-muted);max-width:80ch;margin:20px 0;}
.hanmo-lab .lab-table-scroll{width:100%;overflow-x:auto;margin:0 0 18px;}
.hanmo-lab .lab-table{border-collapse:collapse;width:100%;font-size:13px;text-align:left;}
.hanmo-lab .lab-table caption{text-align:left;color:var(--lab-muted);padding:0 0 12px;font-size:12px;}
.hanmo-lab .lab-table th{font-weight:600;color:#f4c76c;white-space:nowrap;border-bottom:1px solid #517088;padding:11px 9px;}
.hanmo-lab .lab-table td{padding:12px 9px;color:var(--lab-text);border-bottom:1px solid #243f51;vertical-align:middle;}
.hanmo-lab .lab-input-table{min-width:850px;}
.hanmo-lab .lab-input-table input{max-width:104px;min-width:55px;width:100%;box-sizing:border-box;}
.hanmo-lab .lab-input-table input[data-field="name"]{min-width:94px;}
.hanmo-lab :is(input,select){background:#0a2536;border:1px solid #517088;color:var(--lab-text);border-radius:3px;padding:10px;font:500 13px var(--hm-font,system-ui);}
.hanmo-lab .lab-controls{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:22px;margin:26px 0;}
.hanmo-lab .lab-controls label{display:flex;flex-direction:column;gap:8px;font-size:13px;color:var(--lab-muted);}
.hanmo-lab .lab-controls input,.hanmo-lab .lab-controls select{width:100%;min-height:42px;}
.hanmo-lab .lab-text-button{color:var(--lab-muted);background:none;border:0;text-decoration:underline;font:inherit;cursor:pointer;padding:8px;}
.hanmo-lab .lab-text-button:disabled{opacity:.4;cursor:default;}
.hanmo-lab .lab-sensitivity{margin:12px 0 22px;padding-left:20px;color:var(--lab-text);font-size:14px;}
.hanmo-lab .lab-sensitivity li{margin-bottom:8px;}
.hanmo-lab h3{margin:24px 0 12px;font-size:17px;}
.hanmo-lab [hidden]{display:none!important;}
@media(max-width:900px){
 body.hanmo-ui.hanmo-refined .hanmo-main.lab-layout{padding:28px 24px 36px;}
 .hanmo-lab .lab-controls{grid-template-columns:repeat(2,minmax(0,1fr));}
 .hanmo-lab .lab-stats>div{grid-template-columns:1fr;gap:5px;}
}
@media(max-width:640px){
 body.hanmo-ui.hanmo-refined .hanmo-main.lab-layout{padding:20px 16px 28px;}
 .hanmo-lab .lab-controls{grid-template-columns:1fr;}
 .hanmo-lab .lab-section-heading{display:block;}
}


/* 세 실험실은 표시 중인 단계만 보여 주어 기본 PC 뷰포트에서 스크롤을 없앱니다. */
.hanmo-lab .lab-heading{margin-bottom:12px;max-width:none}
.hanmo-lab .lab-heading h1{font-size:clamp(22px,2.4vw,30px);margin-bottom:4px}
.hanmo-lab .lab-heading>p:last-child{font-size:13px;line-height:1.55;max-width:none}
.hanmo-lab .lab-kicker{margin-bottom:5px;font-size:11px}
.hanmo-lab .lab-panel{margin-bottom:0;padding:12px 0;border-top:1px solid #38566a}
.hanmo-lab .lab-section-heading{margin-bottom:9px}
.hanmo-lab .lab-section-heading h2{font-size:18px}
.hanmo-lab .lab-actions{gap:9px;margin:10px 0}
.hanmo-lab .lab-button{min-height:36px;padding:7px 13px}
.hanmo-lab .lab-footnote{font-size:12px;line-height:1.55;margin:10px 0}
.hanmo-lab .lab-summary{padding:5px 0;margin:4px 0 9px}
.hanmo-lab .lab-table-scroll{margin-bottom:7px}
.hanmo-lab .lab-table caption{padding-bottom:5px}
.hanmo-lab .lab-table th{padding:5px 9px}
.hanmo-lab .lab-table td{padding:4px 9px}
.hanmo-lab .lab-input-table{min-width:520px}
.hanmo-lab .lab-input-table td:nth-child(1){width:38%}
.hanmo-lab .lab-input-table input[data-field="name"]{min-width:100px;max-width:none}
.hanmo-lab .lab-input-table input{min-height:32px;max-width:150px;padding:4px 8px}
.hanmo-lab .lab-text-button{padding:4px}
.hanmo-lab .lab-auto-details{display:flex;align-items:center;flex-wrap:wrap;gap:8px 18px;padding:7px 0;border-block:1px solid #284657}
.hanmo-lab .lab-auto-details p{display:flex;align-items:center;gap:8px;margin:0;color:#c4d3de;font-size:12px}
.hanmo-lab .lab-auto-details strong{color:#f2f5f8;font-weight:600}
.hanmo-lab .lab-auto-details a{color:#f4c76c;font-size:12px}
.hanmo-lab .lab-check-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:9px 18px;margin:12px 0}
.hanmo-lab .lab-check-grid p{margin:0;padding:9px 12px;border:1px solid #38566a;display:flex;justify-content:space-between;gap:14px}
.hanmo-lab .lab-check-grid strong{font-size:13px}
.hanmo-lab .lab-check-grid span{color:#c4d3de;font-size:12px;text-align:right}
.hanmo-lab .lab-check{margin:4px 0;padding:10px 12px}
.hanmo-lab .lab-check small{font-size:11px}
.hanmo-lab .lab-status{margin:7px 0;font-size:13px;min-height:22px}
.hanmo-lab .lab-result-panel{margin-top:0}
.hanmo-lab .lab-stats-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:0 20px}
.hanmo-lab .lab-stats-grid>div{display:block;padding:9px 0;border-top:1px solid #284657}
.hanmo-lab .lab-stats-grid dt{font-size:11px}
.hanmo-lab .lab-stats-grid dd{font-size:13px}
.hanmo-lab .lab-strategy-answer{max-width:80ch;margin:24px 0;color:#f4d394;font-size:clamp(18px,2.2vw,26px);font-weight:700;line-height:1.7}
.hanmo-lab .lab-inline-link{display:inline-flex;align-items:center;text-decoration:none}
.hanmo-lab .lab-reaction-target{display:grid;place-items:center;width:100%;height:clamp(148px,26vh,248px);
  font:700 clamp(20px,3vw,28px) "Noto Sans KR",system-ui;cursor:pointer;
  color:#f2f5f8;background:#123d5d;border:1px solid #4d7895;border-radius:5px}
.hanmo-lab .lab-reaction-target[data-phase="waiting"]{background:#9c552e;color:#fff}
.hanmo-lab .lab-reaction-target[data-phase="go"]{background:#15805b;color:#fff}
.hanmo-lab .lab-reaction-target[data-phase="break"]{background:#123d5d}
.hanmo-lab .lab-reaction-target:disabled{opacity:1;cursor:default}
.hanmo-lab .lab-reaction-target:focus-visible{outline:3px solid #f4c76c;outline-offset:3px}
.hanmo-reaction .lab-result-panel{margin-top:10px}
.hanmo-lab .lab-panel[hidden],.hanmo-lab [hidden]{display:none!important}
@media(min-width:1100px) and (min-height:680px){
  body.hanmo-lab.hanmo-refined>.hanmo-main.lab-layout{
    display:flex;flex-direction:column;justify-content:flex-start;
    width:min(1184px,100%);padding:12px 32px 10px;max-width:1184px;min-height:0;
  }
}
@media(max-height:740px){
 .hanmo-lab .lab-heading{margin-bottom:6px}
 .hanmo-lab .lab-panel{padding:7px 0}
 .hanmo-lab .lab-check-grid{margin:6px 0;gap:5px 12px}
 .hanmo-lab .lab-check-grid p{padding:5px 10px}
 .hanmo-lab .lab-actions{margin:6px 0}
 .hanmo-lab .lab-auto-details{padding:4px 0}
 .hanmo-lab .lab-reaction-target{height:clamp(120px,24vh,190px)}
}


/* 낮은 데스크톱에서도 최대 8개 가상 과목의 마지막 행·실행 버튼까지 모두 보이도록 압축합니다. */
@media(min-width:1100px) and (min-height:680px) and (max-height:820px){
 .hanmo-strategy .lab-heading{margin-bottom:6px}
 .hanmo-strategy .lab-panel{padding:6px 0}
 .hanmo-strategy .lab-section-heading{margin-bottom:3px}
 .hanmo-strategy .lab-table td{padding:2px 8px}
 .hanmo-strategy .lab-input-table input{box-sizing:border-box;height:28px;min-height:28px;padding:2px 7px}
 .hanmo-strategy .lab-table th{padding:4px 8px}
 .hanmo-strategy .lab-table caption{padding-bottom:2px;font-size:11px}
 .hanmo-strategy .lab-actions{margin:4px 0}
 .hanmo-strategy .lab-auto-details{padding:3px 0}
 .hanmo-strategy .lab-status{margin:0}
 .hanmo-strategy .lab-heading{margin-bottom:2px}
}

/* 진단 결과의 권장 조치 목록은 같은 화면에 배치합니다. */
.hanmo-readiness #readiness-advice{margin:6px 0 10px;padding-top:8px;border-top:1px solid var(--lab-border);color:var(--lab-muted);font-size:13px;line-height:1.55}
.hanmo-readiness #readiness-advice h3{margin:0 0 4px;color:var(--lab-text);font-size:14px;font-weight:600}
.hanmo-readiness #readiness-advice ul{margin:0;padding-inline-start:18px}
.hanmo-readiness #readiness-advice li{margin:2px 0;overflow-wrap:anywhere}
.hanmo-readiness #readiness-result:focus-visible{outline:2px solid #f4c76c;outline-offset:-2px}
@media(min-width:1100px) and (min-height:680px){
 .hanmo-readiness #readiness-result{flex:0 0 auto;min-height:0;overflow:visible}
}

/* 결과의 경쟁자·대기시간 가정을 독립된 제목으로 짧게 표시합니다. */
.hanmo-strategy #strategy-result .lab-strategy-answer{margin:12px 0}
.hanmo-strategy .strategy-assumption h3{font-size:14px;margin:12px 0 3px}
.hanmo-strategy .strategy-assumption .lab-footnote{margin:4px 0 8px;max-width:none}
.hanmo-strategy #strategy-wait-summary{color:var(--lab-text);font-weight:600}
.hanmo-strategy #strategy-result:focus-visible{outline:2px solid #f4c76c;outline-offset:-2px}
@media(min-width:1100px) and (min-height:680px){
 .hanmo-strategy #strategy-result{flex:0 0 auto;min-height:0;overflow:visible}
}

/* 수식은 기본 접힘으로 유지하고 펼쳤을 때만 상세한 모형을 표시합니다. */
.hanmo-strategy .strategy-formulas{margin:10px 0 12px;border-block:1px solid var(--lab-border);padding:6px 0}
.hanmo-strategy .strategy-formulas summary{cursor:pointer;color:#f4c76c;font-weight:600;font-size:13px;padding:6px 0}
.hanmo-strategy .strategy-formulas summary:focus-visible{outline:2px solid #f4c76c;outline-offset:2px}
.hanmo-strategy #strategy-assumptions:not([open])>.strategy-assumptions{display:none}
.hanmo-strategy .strategy-formula-body{padding:0 0 6px;overflow-wrap:anywhere;container-type:inline-size;min-width:0}
.hanmo-strategy .strategy-formula-body .lab-footnote{max-width:none;margin:5px 0 10px}
.hanmo-strategy .strategy-formula-list{margin:0}
.hanmo-strategy .strategy-formula-list dt{font-size:14px;font-weight:600;color:var(--lab-text);margin:12px 0 4px}
.hanmo-strategy .strategy-formula-list dd{margin:0}
.hanmo-strategy .strategy-math-line{margin:8px 0;padding:3px 0;min-width:0;overflow:visible}
.hanmo-strategy .strategy-math-line math{font-size:clamp(13px,1.5vw,20px);font-size:clamp(12px,3.3cqi,20px);color:var(--lab-text);margin-inline:0}
.hanmo-strategy .strategy-formula-list dd>.lab-footnote{margin:8px 0 14px}

/* 진단 등급은 측정값과 별도로 표시하며 색과 문자 모두로 의미를 전달합니다. */
.hanmo-readiness .readiness-grade-legend{display:flex;flex-wrap:wrap;align-items:center;gap:6px 14px;margin:8px 0 12px;color:var(--lab-muted);font-size:12px}
.hanmo-readiness .readiness-grade-legend>span{display:inline-flex;gap:5px;align-items:center}
.hanmo-readiness .readiness-grade{display:inline-flex;align-items:center;justify-content:center;flex:0 0 auto;min-width:26px;height:26px;border-radius:5px;padding:0 4px;font-size:14px;font-weight:750;line-height:1;color:#111827}
.hanmo-readiness .readiness-grade[data-grade="A"]{background:#22c55e}
.hanmo-readiness .readiness-grade[data-grade="B"]{background:#f97316}
.hanmo-readiness .readiness-grade[data-grade="C"]{background:#eab308}
.hanmo-readiness .readiness-grade[data-grade="D"]{background:#92400e;color:#fff}
.hanmo-readiness .readiness-grade[data-grade="F"]{background:#dc2626;color:#fff}
.hanmo-readiness .readiness-grade[data-grade="none"]{background:#64748b;color:#fff}
.hanmo-readiness .readiness-grade-legend .readiness-grade{min-width:20px;height:20px;font-size:12px}
.hanmo-readiness .readiness-grade-grid{grid-template-columns:repeat(2,minmax(0,1fr));gap:8px 12px;margin:0 0 10px}
.hanmo-readiness .readiness-grade-grid>div{min-width:0;display:block;border:1px solid var(--lab-border);border-radius:6px;background:#102c3d;padding:10px 12px}
.hanmo-readiness .readiness-grade-grid dt{display:flex;justify-content:space-between;align-items:center;gap:8px;font-size:12px;overflow-wrap:anywhere;margin-bottom:4px}
.hanmo-readiness .readiness-metric-main{display:block;font-size:clamp(16px,1.7vw,21px);line-height:1.35;color:var(--lab-text);font-weight:700;overflow-wrap:anywhere}
.hanmo-readiness .readiness-metric-detail,.hanmo-readiness .readiness-grade-grid .readiness-grade-note{display:block;font-size:11px;font-weight:400;line-height:1.5;color:var(--lab-muted);overflow-wrap:anywhere}
.hanmo-readiness .readiness-grade-criteria{border-block:1px solid var(--lab-border);padding:8px 0;margin:8px 0}
.hanmo-readiness .readiness-grade-criteria summary{cursor:pointer;font-size:13px;font-weight:600;color:var(--lab-text)}
.hanmo-readiness .readiness-criteria-list{padding-inline-start:18px;margin:6px 0;font-size:12px;line-height:1.65;color:var(--lab-muted);overflow-wrap:anywhere}
.hanmo-reaction .reaction-input-guide{margin:6px 0;font-size:13px;color:var(--lab-muted);text-align:center}
.hanmo-reaction .lab-reaction-target{padding:12px;text-align:center;overflow-wrap:anywhere}
/* 추천 순서와 네 개의 요약 지표, 과목별 관측 비율, 가정별 비교를 구분합니다. */
.hanmo-strategy .strategy-result-overview,.hanmo-strategy .strategy-result-block{min-width:0;margin:0 0 12px}
.hanmo-strategy .strategy-result-overview h3,.hanmo-strategy .strategy-result-block h3{margin:8px 0;font-size:15px;font-weight:650;color:var(--lab-text)}
.hanmo-strategy .strategy-order{list-style:none;display:grid;grid-template-columns:repeat(auto-fit,minmax(min(100%,128px),1fr));gap:8px;margin:0 0 10px;padding:0}
.hanmo-strategy .strategy-order li{min-inline-size:0;padding:10px 12px;border:1px solid var(--lab-border);border-radius:8px;background:#102c3d;display:flex;flex-direction:column;gap:6px;overflow-wrap:anywhere}
.hanmo-strategy .strategy-order li:first-child{border-color:#d9ab59}
.hanmo-strategy .strategy-card-head{display:flex;align-items:center;flex-wrap:wrap;justify-content:space-between;gap:4px 8px}
.hanmo-strategy .strategy-order-rank{padding:2px 7px;border-radius:5px;background:#294557;color:var(--lab-text);font-size:15px;font-weight:750;white-space:nowrap}
.hanmo-strategy .strategy-order li:first-child .strategy-order-rank{background:#f4d394;color:#162334}
.hanmo-strategy .strategy-order strong{font-size:18px;line-height:1.35;color:var(--lab-text)}
.hanmo-strategy .strategy-result-metrics{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:8px 12px;margin:0}
.hanmo-strategy .strategy-result-metrics>div{min-width:0;border:1px solid var(--lab-border);border-radius:6px;padding:10px 12px}
.hanmo-strategy .strategy-result-metrics dt{font-size:12px;color:var(--lab-muted);margin-bottom:4px}
.hanmo-strategy .strategy-result-metrics dd{margin:0;font-size:clamp(16px,2vw,24px);line-height:1.4;color:var(--lab-text);font-weight:700;font-variant-numeric:tabular-nums;overflow-wrap:anywhere}
.hanmo-strategy .strategy-result-metrics #strategy-overall-value{color:#f4d394}
.hanmo-strategy .strategy-result-metrics .strategy-metric-note{font-size:11px;font-weight:400;color:var(--lab-muted);line-height:1.55;margin-top:3px}
.hanmo-strategy .strategy-result-block{border-top:1px solid var(--lab-border);padding-top:3px}
.hanmo-strategy .strategy-course-rate{color:#f4d394;font-size:18px;line-height:1.25;font-variant-numeric:tabular-nums;font-weight:750;overflow-wrap:anywhere}
.hanmo-strategy .strategy-course-track{height:6px;border-radius:4px;background:#294557;overflow:hidden;margin-top:auto}
.hanmo-strategy .strategy-course-track span{display:block;height:100%;border-radius:4px;background:#8b5cf6}
.hanmo-strategy .strategy-conditions{width:100%;border-collapse:collapse;table-layout:fixed;font-size:13px}
.hanmo-strategy .strategy-conditions th,.hanmo-strategy .strategy-conditions td{padding:6px 8px;border-bottom:1px solid #294557;text-align:left;overflow-wrap:anywhere;vertical-align:top}
.hanmo-strategy .strategy-conditions thead th{color:var(--lab-muted);font-size:11px}
.hanmo-strategy .strategy-conditions tbody th{font-weight:500;color:var(--lab-text)}
.hanmo-strategy .strategy-conditions th:last-child,.hanmo-strategy .strategy-conditions td{text-align:right;font-variant-numeric:tabular-nums}
.hanmo-strategy .strategy-conditions .strategy-baseline{background:#102c3d}
.hanmo-strategy .strategy-conditions .strategy-baseline td{font-weight:700;color:#f4d394}
.hanmo-strategy .strategy-result-summary{min-inline-size:0}
.hanmo-strategy .strategy-result-summary .lab-footnote{max-width:none;margin:5px 0}
@media(max-width:640px){
  .hanmo-readiness .readiness-grade-grid,.hanmo-strategy .strategy-result-metrics{grid-template-columns:1fr}
  .hanmo-strategy .strategy-order{grid-template-columns:repeat(2,minmax(0,1fr))}
}

/* 일반 PC에서는 스크롤을 숨겨 잘라내지 않고 실제 내용의 높이를 맞춥니다. */
.hanmo-strategy .strategy-result-comparison,.hanmo-strategy .strategy-assumptions{min-width:0;display:grid;gap:12px 20px}
.hanmo-strategy .strategy-order-heading h2{margin:0;font-size:20px}
.hanmo-strategy .strategy-result-overview .strategy-order-heading h3{margin:4px 0 8px;font-size:18px}
.hanmo-strategy .strategy-order .strategy-course-track{width:100%;margin-top:2px}
@media(min-width:1100px) and (min-height:680px){
 .hanmo-readiness #readiness-result,.hanmo-strategy #strategy-result{padding:6px 0}
 .hanmo-readiness #readiness-result .lab-section-heading,.hanmo-strategy #strategy-result .lab-section-heading{margin-bottom:4px}
 .hanmo-readiness #readiness-summary{font-size:12px;line-height:1.45;padding:0;margin:3px 0 5px}
 .hanmo-readiness .readiness-grade-legend{margin:4px 0 6px;gap:4px 12px}
 .hanmo-readiness .readiness-grade-grid{grid-template-columns:repeat(4,minmax(0,1fr));gap:5px 8px;margin:0 0 6px}
 .hanmo-readiness .readiness-grade-grid>.readiness-metric:first-child{grid-column:span 2}
 .hanmo-readiness .readiness-grade-grid>div{padding:5px 8px}
 .hanmo-readiness .readiness-grade-grid dt{margin-bottom:1px;font-size:12px;line-height:1.3}
 .hanmo-readiness .readiness-grade-grid .readiness-grade{min-width:22px;height:22px;font-size:12px}
 .hanmo-readiness .readiness-metric-main{font-size:16px;line-height:1.35}
 .hanmo-readiness .readiness-metric-detail,.hanmo-readiness .readiness-grade-grid .readiness-grade-note{font-size:11px;line-height:1.35}
 .hanmo-readiness #readiness-advice{margin:4px 0;padding-top:4px;font-size:12px;line-height:1.4}
 .hanmo-readiness #readiness-advice h3{margin-bottom:2px;font-size:13px}
 .hanmo-readiness #readiness-advice ul{display:grid;grid-template-columns:repeat(auto-fit,minmax(250px,1fr));gap:3px 14px}
 .hanmo-readiness #readiness-advice li{margin:0}
 .hanmo-readiness #readiness-result>.lab-footnote{max-width:none;font-size:11px;line-height:1.4;margin:4px 0 6px}
 .hanmo-readiness .readiness-grade-criteria{padding:4px 0;margin:4px 0}
 .hanmo-readiness .readiness-grade-criteria[open] .readiness-criteria-list{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:5px 20px;font-size:13px}
 /* 등급 기준은 별도의 읽기 단계입니다. 펼치면 결과를 가리지 않고 기준 화면으로 전환합니다. */
 .hanmo-readiness #readiness-result:has(#readiness-grade-criteria[open])>:is(.lab-summary,.readiness-grade-legend,.readiness-grade-grid,#readiness-advice,.lab-footnote){display:none}
 .hanmo-readiness #readiness-grade-criteria[open] .lab-footnote{max-width:none}
 .hanmo-strategy .strategy-result-comparison{grid-template-columns:minmax(0,1fr) minmax(0,1.4fr);align-items:start;gap:5px 16px}
 .hanmo-strategy .strategy-result-overview,.hanmo-strategy .strategy-result-block{margin:0 0 5px}
 .hanmo-strategy .strategy-result-overview h3,.hanmo-strategy .strategy-result-block h3{margin:3px 0 4px;font-size:14px;line-height:1.4}
 .hanmo-strategy .strategy-order{grid-template-columns:repeat(4,minmax(0,1fr));gap:5px;margin:0 0 5px}
 .hanmo-strategy .strategy-order li{padding:7px 9px}
 .hanmo-strategy .strategy-order .strategy-course-track{height:5px}
 .hanmo-strategy .strategy-result-metrics{grid-template-columns:repeat(4,minmax(0,1fr));gap:5px 8px}
 .hanmo-strategy .strategy-result-metrics>div{padding:5px 8px}
 .hanmo-strategy .strategy-result-metrics dt{margin-bottom:2px;font-size:11px}
 .hanmo-strategy .strategy-result-metrics dd{font-size:17px;line-height:1.3}
 .hanmo-strategy .strategy-result-metrics .strategy-metric-note{font-size:11px;line-height:1.35;margin-top:2px}
 .hanmo-strategy #strategy-setup{border-top:0;padding:0}
 .hanmo-strategy .strategy-conditions{font-size:12px}
 .hanmo-strategy .strategy-conditions th,.hanmo-strategy .strategy-conditions td{padding:3px 5px;line-height:1.35}
 .hanmo-strategy .strategy-result-summary .lab-footnote{margin:3px 0;font-size:11px;line-height:1.35}
 .hanmo-strategy .strategy-assumptions{grid-template-columns:minmax(0,1.25fr) minmax(0,1fr);gap:10px 16px}
 .hanmo-strategy .strategy-assumption h3{margin:4px 0 2px;font-size:13px;line-height:1.35}
 .hanmo-strategy .strategy-assumption .lab-footnote{margin:2px 0;font-size:11px;line-height:1.4}
 .hanmo-strategy .strategy-formulas{margin:4px 0 5px;padding:2px 0}
 .hanmo-strategy .strategy-formulas summary{padding:3px 0}
 .hanmo-strategy #strategy-back,.hanmo-readiness #readiness-back{min-height:32px;padding:5px 12px}
 /* 수식 설명만 내부 스크롤을 허용하고 일반 결과의 스크롤은 만들지 않습니다. */
 .hanmo-strategy #strategy-result:has(#strategy-formulas[open]){display:flex;flex:1 1 0;min-height:0;flex-direction:column}
 .hanmo-strategy #strategy-result:has(#strategy-formulas[open]) :is(.strategy-order-heading h3,.strategy-order,.strategy-result-comparison,.strategy-assumptions){display:none}
 .hanmo-strategy #strategy-formulas[open]{flex:1 1 0;min-height:0;display:flex;flex-direction:column;overflow:hidden}
 .hanmo-strategy #strategy-formulas[open]::details-content{display:flex;flex-direction:column;flex:1 1 0;min-height:0}
 .hanmo-strategy #strategy-formulas[open] .strategy-formula-body{flex:1 1 0;min-height:0;max-height:calc(100dvh - 260px);overflow-y:auto;overflow-x:hidden;overscroll-behavior:contain;padding-inline-end:8px}
 .hanmo-strategy #strategy-result:has(#strategy-formulas[open]) #strategy-back{align-self:flex-start;flex:0 0 auto}
 .hanmo-strategy .lab-table-scroll{overflow:visible}
}

.hanmo-readiness .readiness-criteria-open,.hanmo-readiness #readiness-grade-criteria[open] .readiness-criteria-closed{display:none}
.hanmo-readiness #readiness-grade-criteria[open] .readiness-criteria-open{display:inline}

/* 닫힌 등급 기준은 접근성 트리와 화면 배치에서 제외하고, 펼치면 전체 내용을 복원합니다. */
.hanmo-readiness #readiness-grade-criteria:not([open])>:not(summary){display:none}

/* 8과목 긴 이름에서도 재실험 버튼까지 푸터 위에 배치합니다. */
@media(min-width:1100px) and (min-height:680px) and (max-height:820px){
 .hanmo-strategy #strategy-result{padding-block:3px}
 .hanmo-strategy .strategy-order-heading{display:flex;flex-wrap:wrap;align-items:baseline;gap:4px 16px;margin-block-end:5px}
 .hanmo-strategy .strategy-result-comparison{gap:4px 12px}
 .hanmo-strategy .strategy-result-overview,.hanmo-strategy .strategy-result-block{margin-bottom:3px}
 .hanmo-strategy .strategy-result-overview h3,.hanmo-strategy .strategy-result-block h3{margin:1px 0 3px}
 .hanmo-strategy .strategy-result-overview .strategy-order-heading h3{margin:0}
 .hanmo-strategy .strategy-order{gap:4px;margin-bottom:3px}
 .hanmo-strategy .strategy-order li{padding:6px 8px;gap:4px}
 .hanmo-strategy .strategy-result-metrics>div{padding:4px 7px}
 .hanmo-strategy .strategy-result-metrics dt{margin-bottom:1px}
 .hanmo-strategy .strategy-result-metrics .strategy-metric-note{margin-top:1px}
 .hanmo-strategy .strategy-conditions th,.hanmo-strategy .strategy-conditions td{padding:2px 5px}
 .hanmo-strategy .strategy-result-summary .lab-footnote{margin:2px 0}
 .hanmo-strategy .strategy-assumptions{gap:6px 12px}
 .hanmo-strategy .strategy-assumption h3{margin:2px 0 1px}
 .hanmo-strategy .strategy-assumption .lab-footnote{margin:1px 0}
 .hanmo-strategy .strategy-formulas{margin:2px 0 3px}
 .hanmo-strategy #strategy-result:not(:has(details[open]))>.strategy-formulas{display:inline-block;vertical-align:middle;margin-inline-end:14px}
 .hanmo-strategy #strategy-result:has(#strategy-assumptions[open]) .strategy-result-comparison{display:none}
}

/* B 이하 항목의 개선 조치를 결과 수치와 구분해 즉시 읽을 수 있도록 강조합니다. */
.hanmo-readiness #readiness-advice {
  border:1px solid #aa8548;border-left:4px solid #f4c76c;border-radius:5px;
  background:#30291b;color:#fff1cf;padding:7px 10px;
}
.hanmo-readiness #readiness-advice h3 {
  color:#ffdc97;font-size:15px;font-weight:750;margin:0 0 4px;
}
.hanmo-readiness #readiness-advice li {
  color:#fff1cf;font-weight:600;line-height:1.4;
}
@media(min-width:1100px) and (min-height:680px){
  .hanmo-readiness #readiness-advice{margin:4px 0;padding:4px 8px;font-size:12px}
  .hanmo-readiness #readiness-advice h3{font-size:14px;margin-bottom:2px}
  .hanmo-readiness #readiness-advice ul{grid-template-columns:repeat(3,minmax(0,1fr));gap:2px 12px}
}
