/* The studio owns only its module; staff and existing educational forms keep their styles. */
.hsm-practice{--practice-primary:var(--hsm-studio-primary,#7658db);--practice-ink:var(--hsm-studio-ink,#252740);--practice-muted:var(--hsm-studio-muted,#667085);color:var(--practice-ink);font-family:inherit;max-width:1240px;margin-inline:auto;min-width:0}
.hsm-practice *{box-sizing:border-box}.hsm-practice-heading{display:flex;align-items:center;justify-content:space-between;gap:16px;padding:26px;background:linear-gradient(115deg,#f0eaff,#e7f8f3);border:1px solid #ded8f0;border-radius:28px;margin-bottom:20px;overflow:hidden}.hsm-practice-heading h2{font-size:clamp(24px,3vw,34px);margin:3px 0 8px;line-height:1.5}.hsm-practice-heading p{margin:0;line-height:1.9}.hsm-practice-eyebrow{font-size:12px;font-weight:800;color:#6340b5}.hsm-practice-orbit{display:grid;place-items:center;width:90px;height:90px;flex-shrink:0;border-radius:30px;background:#fff7ce;color:#d58e19;font-size:60px;transform:rotate(-12deg);box-shadow:10px 8px 0 #fff9}
.hsm-practice-toolbar,.hsm-practice-actions{display:flex;align-items:center;gap:10px;flex-wrap:wrap;margin-block:14px}.hsm-practice-button,.hsm-practice button,.hsm-practice input,.hsm-practice select,.hsm-practice textarea{font:inherit}.hsm-practice button{min-height:44px;border:1px solid #d8d5e7;border-radius:14px;background:#fff;color:var(--practice-ink);padding:9px 15px;cursor:pointer;font-weight:700}.hsm-practice button.hsm-practice-primary{background:var(--practice-primary);border-color:var(--practice-primary);color:#fff}.hsm-practice button:disabled{opacity:.55;cursor:default}.hsm-practice :is(button,input,select,textarea):focus-visible{outline:3px solid #48b8af;outline-offset:3px}.hsm-practice-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:16px}.hsm-practice-card{min-width:0;padding:20px;border:1px solid #deddea;border-radius:24px;background:#fff;box-shadow:0 6px 18px #34345506;display:flex;flex-direction:column;align-items:flex-start;gap:10px}.hsm-practice-card:nth-child(3n+2){background:linear-gradient(150deg,#fff,#f2faf8)}.hsm-practice-card:nth-child(3n+3){background:linear-gradient(150deg,#fff,#fff8ec)}.hsm-practice-card h3{margin:0;font-size:18px;line-height:1.7;overflow-wrap:anywhere}.hsm-practice-card p{margin:0;line-height:1.85}.hsm-practice-card>button{margin-top:auto}.hsm-practice-art{width:60px;height:60px;border-radius:20px;display:grid;place-items:center;background:#ede7ff;color:#6741bb;font-size:30px;line-height:1}.hsm-practice-meta{font-size:13px;color:var(--practice-muted);line-height:1.8}.hsm-practice-reward{display:inline-flex;gap:6px;flex-wrap:wrap;font-size:12px;font-weight:800;color:#79531c;background:#fff5d9;border-radius:12px;padding:6px 10px}.hsm-practice-progress{width:100%;height:7px;accent-color:var(--practice-primary)}.hsm-practice-empty{padding:28px 22px;border-radius:20px;background:#f4f4fb;border:1px dashed #d5d3e7;line-height:2}.hsm-practice-error{color:#a32840;background:#fff1f3;border-radius:12px;padding:10px 14px}.hsm-practice-success{color:#166344;background:#eaf8f1;border-radius:12px;padding:10px 14px}.hsm-practice-section{margin-block:26px}.hsm-practice-section>h3{font-size:19px;margin-bottom:14px}.hsm-practice-question{padding:clamp(18px,4vw,32px);border:1px solid #dbd4ef;border-radius:28px;background:linear-gradient(140deg,#fff,#f7f3ff);max-width:860px;margin-inline:auto}.hsm-practice-question h3{line-height:1.9;font-size:23px;margin-block:15px;white-space:pre-wrap}.hsm-practice-choices{display:grid;gap:12px;margin:20px 0;padding:0;border:0}.hsm-practice-choices legend{margin-bottom:12px}.hsm-practice-choice{display:flex;align-items:flex-start;gap:10px;padding:14px 16px;background:#fff;border:1px solid #dcd8ed;border-radius:16px;min-height:54px;cursor:pointer;line-height:1.8}.hsm-practice-choice:has(input:checked){background:#eee7ff;border-color:#9777e6;box-shadow:inset 0 0 0 1px #9777e6}.hsm-practice-choice input{width:20px;height:20px;min-height:20px!important;flex-shrink:0;accent-color:var(--practice-primary);margin-top:4px}.hsm-practice-solution{padding:18px 20px;border:1px solid #d2e8de;border-radius:18px;background:#edf9f3;white-space:pre-wrap;line-height:2;margin-block:16px}.hsm-practice-solution h4{margin:0 0 8px}.hsm-practice-form{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:14px;padding:20px;border:1px solid #dcd9e9;border-radius:22px;background:white}.hsm-practice label>span{display:block;margin-bottom:7px;font-size:13px;font-weight:700}.hsm-practice-form :is(input:not([type=checkbox]),select,textarea),.hsm-practice-answer-input{width:100%;min-height:44px;padding:10px 12px;color:var(--practice-ink);background:#fff;border:1px solid #cfccdf;border-radius:12px}.hsm-practice-form textarea{min-height:110px;resize:vertical}.hsm-practice-full{grid-column:1/-1}.hsm-practice-editor-card{padding:18px;border-radius:18px;background:#f7f6fc;border:1px solid #dedbeb;display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px}.hsm-practice-editor-card h4{margin:0}.hsm-practice-editor-card details{grid-column:1/-1}.hsm-practice-editor-card summary{cursor:pointer;min-height:44px;line-height:2.5}.hsm-practice-toggle{display:flex;gap:8px;align-items:center}.hsm-practice-toggle input{width:20px;height:20px;accent-color:var(--practice-primary)}.hsm-practice-history{display:grid;gap:10px}.hsm-practice-history details{border:1px solid #deddea;background:#fff;border-radius:17px;padding:8px 15px}.hsm-practice-history summary{cursor:pointer;min-height:44px;line-height:2;display:flex;align-items:center;justify-content:space-between;gap:12px}.hsm-practice-history summary span{font-size:12px;flex-shrink:0}.hsm-practice-filter{max-width:260px;min-width:140px;min-height:44px;border:1px solid #d5d0e5;border-radius:12px;padding:8px 12px;background:white;color:var(--practice-ink)}
@media(max-width:900px){.hsm-practice-grid{grid-template-columns:repeat(2,minmax(0,1fr))}.hsm-practice-form{grid-template-columns:repeat(2,minmax(0,1fr))}}
@media(max-width:540px){.hsm-practice-heading{padding:20px;border-radius:22px}.hsm-practice-orbit{width:56px;height:64px;font-size:42px;border-radius:20px}.hsm-practice-grid{gap:10px}.hsm-practice-card{padding:14px;border-radius:20px}.hsm-practice-card h3{font-size:16px}.hsm-practice-card button{width:100%;padding-inline:8px;font-size:13px}.hsm-practice-question h3{font-size:20px}.hsm-practice-form{padding:12px;gap:10px}.hsm-practice-editor-card{padding:12px}.hsm-practice-meta{font-size:12px}.hsm-practice-history summary{align-items:flex-start;flex-direction:column;gap:2px}}
/* The subject rail scrolls inside the panel, never the page or the WebView. */
.hsm-practice-subject-tabs{display:flex;flex-wrap:nowrap;gap:8px;width:100%;max-width:100%;min-width:0;overflow-x:auto;overscroll-behavior-inline:contain;scrollbar-width:thin;padding:4px 2px 12px;margin-block:8px;scroll-padding-inline:4px}
.hsm-practice-subject-tabs>button{flex:0 0 auto;white-space:nowrap;min-height:46px;padding:9px 18px;border-radius:16px;background:#fff;border-color:#d4c6f3;color:#57418d;box-shadow:0 3px 0 #e9e0fa}
.hsm-practice-subject-tabs>button[aria-selected=true]{background:linear-gradient(135deg,#8f55ea,#6445d8);border-color:#7751d4;color:#fff;box-shadow:0 5px 14px #8759d840}
.hsm-practice-student-toolbar{justify-content:space-between;align-items:flex-end}
.hsm-practice-student-toolbar>label{min-width:0;max-width:calc(100% - 110px);flex:1}
.hsm-practice-sort{width:min(320px,100%);min-height:46px;border:1px solid #d4c6f3;border-radius:14px;padding:8px 12px;background:#fff;color:var(--practice-ink)}
.hsm-practice-difficulty{display:inline-flex;align-items:center;gap:5px;padding:4px 10px;border-radius:9px;background:#ede5ff;color:#64429f;font-size:12px;font-weight:800;line-height:1.7}
.hsm-practice-card[data-difficulty=easy]{background:linear-gradient(145deg,#fff 30%,#d7f7ed);border-color:#a7dbc9;box-shadow:0 5px 0 #c8eadd}
.hsm-practice-card[data-difficulty=medium]{background:linear-gradient(145deg,#fff 28%,#e8ddff);border-color:#c7b6ef;box-shadow:0 5px 0 #e3d6f5}
.hsm-practice-card[data-difficulty=hard]{background:linear-gradient(145deg,#fff 28%,#ffe2b8);border-color:#e7bf89;box-shadow:0 5px 0 #f3d6b2}
.hsm-practice-card[data-difficulty=easy] .hsm-practice-difficulty{background:#bcebd9;color:#155d45}
.hsm-practice-card[data-difficulty=hard] .hsm-practice-difficulty{background:#ffdc9d;color:#724703}
.hsm-practice-card .hsm-practice-progress{border:0;border-radius:8px;overflow:hidden;accent-color:#8f55ea}
@media(max-width:540px){.hsm-practice-subject-tabs>button{padding-inline:14px;font-size:13px}.hsm-practice-student-toolbar{gap:8px}.hsm-practice-sort{font-size:13px}.hsm-practice-card{gap:9px}.hsm-practice-form>label{min-width:0}}
@media(prefers-reduced-motion:reduce){.hsm-practice-subject-tabs{scroll-behavior:auto}.hsm-practice *{transition:none!important;animation:none!important}}

.hsm-practice-art svg{width:38px;height:38px;filter:drop-shadow(0 2px 0 #fff8)}
.hsm-practice-card[data-difficulty=hard] .hsm-practice-art{background:linear-gradient(135deg,#ffedc7,#ffc581);color:#97541e}.hsm-practice-card[data-difficulty=easy] .hsm-practice-art{background:linear-gradient(135deg,#d1fff0,#8fe3c6);color:#1d745a}

/* Theme surface colors belong to the administrator; status badges keep their meaning.
   The highlight stays above the text area so the computed foreground retains contrast. */
.hsm-practice[data-panel="hsm_student"] .hsm-practice-card{background:radial-gradient(ellipse at 0 0,var(--hsm-highlight-card_practice,#f1e3ff),transparent 72px) 0 0/100% 92px no-repeat,var(--hsm-surface-card_practice,#e2ccff);color:var(--hsm-on-surface-card_practice,#252740);border-color:#ffffff80;box-shadow:inset 0 1px 0 #fff8,0 5px 0 #20204014}
.hsm-practice[data-panel="hsm_student"] .hsm-practice-card .hsm-practice-meta{color:inherit}
.hsm-practice[data-panel="hsm_student"] button.hsm-practice-primary{color:var(--journey-on-accent,#fff)}
.hsm-practice-policy{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px;align-items:end;padding:14px;border:1px solid #d3e1eb;border-radius:16px;margin-block:14px}.hsm-practice-policy label{min-width:0;display:grid;gap:6px}.hsm-practice-policy input{width:100%;min-width:0;box-sizing:border-box}.hsm-practice-policy button{min-height:44px}.hsm-practice-policy [role=status]{grid-column:1/-1;margin:0}.hsm-practice-budget{padding:12px;border-radius:14px;background:#e8f5ef;color:#205942}.hsm-practice-reasoning{padding:12px;border-inline-start:3px solid #6d71ad;margin-block:12px}.hsm-practice-reasoning p{white-space:pre-wrap}.hsm-practice [name=explanation]{width:100%;box-sizing:border-box;resize:vertical}.hsm-practice [data-practice-bank-results]>article{padding-block:10px;border-block-end:1px solid #dae4ed;overflow-wrap:anywhere}.hsm-practice [name=bank_search]{max-width:100%;min-width:0;box-sizing:border-box}
