.hw-intro{display:grid;grid-template-columns:repeat(3,1fr);gap:16px;margin:0 0 24px}.hw-intro>div{background:var(--card);border:1px solid var(--line);border-radius:16px;padding:20px;display:grid;grid-template-columns:26px 1fr;gap:8px 12px}.hw-intro svg{width:22px;height:22px;color:var(--blue)}.hw-intro span{grid-column:2;color:var(--muted);font-size:13px;line-height:1.5}.hw-bank-row{background:transparent;border:0;border-bottom:1px solid var(--line);padding:22px;width:100%;display:flex;align-items:center;text-align:left;gap:18px;color:inherit;cursor:pointer}.hw-bank-row:hover{background:var(--soft)}.hw-bank-row>span:nth-child(2){flex:1;min-width:0}.hw-bank-row strong{font-size:16px;line-height:1.5}.hw-bank-row small{display:block;color:var(--muted);line-height:1.7}.hw-bank-row>svg{width:18px;flex-shrink:0}.hw-layout{display:grid;grid-template-columns:260px minmax(0,1fr);gap:24px;align-items:start}.hw-outline{padding:16px;position:sticky;top:20px}.hw-outline>.btn{width:100%;margin-top:16px}.hw-outline-item{display:flex;align-items:center;gap:12px;background:none;border:0;padding:14px 10px;width:100%;text-align:left;border-radius:10px;color:inherit;cursor:pointer}.hw-outline-item small{display:block;color:var(--muted);margin-top:6px}.hw-outline-item svg{width:20px}.hw-outline-item.active{background:var(--soft);color:var(--blue)}.hw-number{display:inline-flex;align-items:center;justify-content:center;min-width:34px;height:34px;border-radius:10px;background:var(--bg);border:1px solid var(--line);font-weight:650;flex-shrink:0;color:inherit}.hw-total{border-top:1px solid var(--line);margin-top:24px;padding-top:20px;display:grid;gap:10px}.hw-total small{color:var(--muted)}.hw-total strong{font-size:22px}.hw-total .badge{justify-self:start}.hw-editor{overflow:hidden;min-width:0}.hw-tabs{display:flex;border-bottom:1px solid var(--line);padding:0 24px;gap:24px}.hw-tabs button{padding:18px 0;background:none;border:0;border-bottom:2px solid transparent;color:var(--muted);cursor:pointer}.hw-tabs .active{color:var(--blue);border-color:var(--blue);font-weight:650}.hw-prose{white-space:pre-wrap;overflow-wrap:anywhere;line-height:1.8;font-size:16px}.hw-tip{padding:18px 20px;background:var(--soft);border-radius:12px;line-height:1.7;font-size:14px;margin:0 0 18px}.hw-image{margin:16px 0;max-width:100%}.hw-image img{display:block;max-width:100%;max-height:560px;object-fit:contain;border-radius:10px}.hw-assets{display:grid;gap:12px}.hw-assets>.btn{justify-self:start}.hw-rubric{background:var(--bg);border-radius:14px;padding:20px}.hw-rubric label{display:flex;align-items:center;gap:14px;margin:10px 0}.hw-rubric label>span:first-child{width:120px}.hw-rubric input{width:82px}.hw-rubric>div{display:flex;gap:8px;margin-top:18px}.hw-sandbox{border:1px solid var(--line);border-radius:14px;padding:20px;margin-top:20px}.hw-test-row{display:flex;gap:10px}.hw-test-row input{min-width:0;flex:1}.hw-sandbox p{font-size:14px;color:var(--muted);margin:14px 0 0}.hw-preview-question{margin-top:24px;overflow:hidden}.hw-preview-question>h1,.hw-preview-question>h2,.hw-preview-question>.hw-prose,.hw-preview-question>.hw-image,.hw-preview-question>p,.hw-preview-question>.btn{margin:24px}.hw-attempt-grid{display:grid;grid-template-columns:210px minmax(0,1fr);gap:24px;margin-top:24px;align-items:start}.hw-answer-nav{padding:24px}.hw-answer-nav>div{display:flex;flex-wrap:wrap;gap:8px;margin-top:20px}.hw-answer-nav small,.hw-answer-nav p{color:var(--muted);font-size:13px;line-height:1.7}.hw-number.active{outline:2px solid var(--blue);outline-offset:2px}.hw-number.answered{background:#e3f4eb;color:#176a47}.hw-attempt-actions{display:flex;justify-content:space-between}.hw-submit-bar{display:flex;align-items:center;gap:12px;padding:22px 0;flex-wrap:wrap}.hw-submit-bar>span{flex:1;font-size:13px;color:var(--muted)}.hw-score{font-size:42px;font-weight:700;color:var(--blue)}.hw-score span{font-size:22px;color:var(--muted)}.hw-comparison{display:grid;grid-template-columns:1fr 1fr;gap:20px;background:var(--bg);padding:20px;border-radius:12px}.hw-comparison small{display:block;color:var(--muted);margin-bottom:10px}.hw-comparison strong{overflow-wrap:anywhere}.hw-explanation{padding:20px;border-left:3px solid var(--blue);background:var(--soft);border-radius:0 12px 12px 0}.hw-explanation h3{margin:0 0 12px}.hw-question .field{margin-top:18px}.hw-editor textarea{min-height:160px;resize:vertical}.hw-editor input,.hw-editor select,.hw-editor textarea,.hw-question input{width:100%}.hw-editor .hw-rubric input{width:82px}[data-theme=dark] .hw-number.answered{background:#14382f;color:#a6dec5}
@media(max-width:850px){.hw-layout{grid-template-columns:1fr}.hw-outline{position:static;max-height:260px;overflow:auto}.hw-intro{grid-template-columns:1fr}.hw-intro>div{padding:16px}.hw-attempt-grid{grid-template-columns:1fr}.hw-answer-nav{padding:18px}.hw-answer-nav h3,.hw-answer-nav p,.hw-answer-nav small{display:none}.hw-answer-nav>div{margin:0}.hw-bank-row{padding:18px 14px;gap:12px;flex-wrap:wrap}.hw-bank-row .badge{font-size:11px}.hw-tabs{gap:18px;padding:0 18px}.hw-tabs button{font-size:13px}.hw-editor .panel-head{flex-wrap:wrap}.hw-submit-bar>.btn{flex:1}.hw-submit-bar>span{flex-basis:100%}.hw-comparison{grid-template-columns:1fr}.hw-editor .editor-order{gap:6px}.hw-layout .editor-fields{padding:20px}}
#hw-filter{padding:11px 14px;border:1px solid var(--line);border-radius:10px;background:var(--card);color:inherit;font:inherit;max-width:100%}.hw-editor .hw-sandbox input{padding:12px;border:1px solid var(--line);border-radius:9px;background:var(--card);color:inherit;font:inherit}
.hw-bank-actions{display:flex;gap:10px;flex-wrap:wrap}
.hw-import-preview{margin-top:12px;border:1px solid var(--line);border-radius:10px;padding:12px}
.hw-import-preview summary{cursor:pointer;font-weight:550;overflow-wrap:anywhere}
.hw-import-preview>div{padding:14px 0;border-top:1px solid var(--line);margin-top:12px}
.hw-import-preview p{margin-top:8px;overflow-wrap:anywhere}
#hw-import-result{margin-top:18px;font-size:14px;overflow-wrap:anywhere}
@media(max-width:760px){.hw-bank-actions{width:100%}.hw-bank-actions>.btn{flex:1 1 auto}}

.hw-drop-hint{border:2px dashed #cad3ea;border-radius:12px;padding:16px;margin:16px 0;color:#5b6782;background:#f7f9ff;line-height:1.5}.hw-dragging .hw-drop-hint{border-color:#3157df;background:#eaf0ff;color:#2444bb}.hw-dragging{outline:2px solid #3157df;outline-offset:10px;border-radius:12px}

.hw-bank-filterbar{display:flex;gap:12px;padding:22px}.hw-bank-filterbar .search{flex:1;max-width:none}.hw-bank-filters{display:grid;gap:22px;padding:0 22px 22px}.hw-filter-pick{border:0;padding:0;margin:0;min-width:0}.hw-filter-pick legend{font-weight:600;margin-bottom:12px}.hw-filter-pick>div{display:flex;flex-wrap:wrap;gap:8px}.hw-bank-summary{display:flex;align-items:center;justify-content:space-between;padding:0 22px 18px;color:var(--muted);font-size:14px}.hw-managed-row{display:flex;align-items:center;gap:16px;padding-right:22px;border-top:1px solid var(--line)}.hw-managed-row .hw-bank-row{flex:1;min-width:0;border:0}.hw-managed-row .hw-bank-row:disabled{opacity:1;cursor:default}.hw-managed-row>.btn{flex-shrink:0}@media(max-width:650px){.hw-bank-filterbar{padding:16px;flex-wrap:wrap}.hw-bank-filterbar .search{min-width:180px}.hw-bank-filters{padding:0 16px 18px}.hw-filter-pick .btn{padding:10px 12px;min-height:44px}.hw-managed-row{flex-wrap:wrap;padding:0 0 16px;gap:0}.hw-managed-row .hw-bank-row{flex-basis:100%}.hw-managed-row>.btn{margin-left:16px;min-height:44px}.hw-bank-summary{padding:0 16px 16px}}

.hw-content-table{width:100%;border-collapse:collapse;table-layout:fixed;white-space:normal;font-size:inherit;line-height:1.55;margin:8px 0}.hw-content-table th,.hw-content-table td{padding:12px 10px;text-align:left;vertical-align:top;border:1px solid var(--line);overflow-wrap:anywhere}.hw-content-table th{background:var(--soft);font-weight:600}.hw-content-table th:first-child{width:55%}@media(max-width:520px){.hw-content-table th,.hw-content-table td{padding:10px 7px}.hw-content-table{font-size:14px}.hw-content-table th:first-child{width:50%}}

/* Homework workspace: shared visual rhythm with open courses. */
.hw-study{max-width:1120px;margin-inline:auto;min-width:0}
.hw-study>.back-link{margin-bottom:24px;color:var(--muted)}
.hw-study .heading{margin:0 0 20px;gap:24px;align-items:center}
.hw-study .heading h1{font-size:clamp(26px,2.6vw,38px);line-height:1.22;letter-spacing:-.9px;max-width:900px;margin:8px 0 14px;font-weight:550;text-wrap:balance}
.hw-study .heading .eyebrow{letter-spacing:.5px;font-size:12px;text-transform:none;color:var(--muted)}
.hw-study .subline{font-size:14px;color:var(--muted);margin:0}
.hw-study-intro{max-width:780px;color:var(--muted);margin:0 0 30px}
.hw-study-intro .hw-prose{font-size:15px;line-height:1.65;margin:0}
.hw-study .hw-attempt-grid{grid-template-columns:224px minmax(0,1fr);gap:28px;margin-top:28px}
:root .hw-study .panel{border-radius:24px;box-shadow:none}
.hw-study .hw-answer-nav{padding:24px;position:sticky;top:24px;background:transparent}
.hw-study .hw-progress-head{display:flex;justify-content:space-between;align-items:center;margin:0;gap:10px}
.hw-study .hw-progress-head h3{display:block;font-size:16px;margin:0}
.hw-study #hw-filled-count{font-size:13px;color:var(--muted);font-variant-numeric:tabular-nums}
.hw-study #hw-progress{display:block;appearance:none;-webkit-appearance:none;width:100%;height:4px;border:0;border-radius:8px;overflow:hidden;margin:18px 0 24px;background:var(--line);color:#a78a48}
.hw-study #hw-progress::-webkit-progress-bar{background:var(--line);border-radius:8px}
.hw-study #hw-progress::-webkit-progress-value{background:#a78a48;border-radius:8px}
.hw-study #hw-progress::-moz-progress-bar{background:#a78a48;border-radius:8px}
.hw-study .hw-question-numbers{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:8px;margin:0}
.hw-study .hw-number{width:100%;min-width:0;height:38px;min-height:38px;border-radius:10px;background:var(--card);font:500 14px 'Golos Text',sans-serif;cursor:pointer;position:relative;transition:background .15s,border-color .15s}
.hw-study .hw-number.answered{background:var(--soft);color:var(--ink);border-color:var(--line)}
.hw-study .hw-number.answered::after{content:'';position:absolute;width:4px;height:4px;border-radius:50%;bottom:4px;background:currentColor}
.hw-study .hw-number.active{outline:0;background:var(--action);color:var(--on-action);border-color:var(--action)}
.hw-study .hw-number:hover:not(.active){border-color:var(--muted)}
.hw-study .hw-number:focus-visible{outline:2px solid var(--focus);outline-offset:3px}
.hw-study .hw-answer-nav>small{display:block;margin-top:20px;font-size:12px;line-height:1.6}
.hw-study .hw-question{overflow:hidden;min-width:0}
.hw-study .hw-question .panel-head{padding:26px 32px;border-bottom:1px solid var(--line);align-items:center;gap:12px}
.hw-study .hw-question .panel-head h2{font-size:21px;line-height:1.3;margin:0;scroll-margin-top:24px}
.hw-study .hw-step-total{font-weight:400;color:var(--muted);font-size:16px}
.hw-study .badge{font-weight:400;font-size:12px;background:var(--bg);color:var(--muted);white-space:nowrap}
.hw-study .hw-question .editor-fields{padding:28px 32px 24px}
.hw-study .hw-prose{font-size:17px;line-height:1.85;margin:0 0 24px}
.hw-study .hw-response{margin:32px 0 24px;padding:24px;background:var(--bg);border-radius:16px}
.hw-study .hw-response .field{margin:0;gap:12px;font-size:15px;font-weight:500}
.hw-study #hw-answer{display:block;min-height:56px;border:1px solid var(--line);border-radius:12px;background:var(--card);padding:14px 16px;font:500 20px 'Golos Text',sans-serif;color:var(--ink);letter-spacing:.5px;box-shadow:none}
.hw-study #hw-answer::placeholder{font-size:16px;font-weight:400;letter-spacing:0;color:var(--muted)}
.hw-study #hw-answer:focus{border-color:var(--muted);outline:2px solid var(--focus);outline-offset:3px}
.hw-study #hw-answer-hint{margin:12px 0 0;line-height:1.65;font-size:13px;color:var(--muted)}
.hw-study .hw-grading-note{margin-top:12px;font-size:12px;color:var(--muted);line-height:1.6}
.hw-study .hw-grading-note summary{cursor:pointer;width:fit-content;padding:4px 0;text-underline-offset:4px}
.hw-study .hw-grading-note p{margin:8px 0 0}
.hw-study .hw-attempt-actions{padding-top:4px;gap:12px}
:root .hw-study .btn{border-radius:12px;min-height:48px;padding:12px 20px;font-size:14px}
.hw-study .hw-attempt-actions .btn:last-child:not(:disabled){background:var(--action);color:var(--on-action);border-color:var(--action)}
.hw-study .hw-submit-bar{display:flex;gap:12px;align-items:center;margin:20px 0 0 252px;padding:20px 0;border-top:1px solid var(--line)}
.hw-study .hw-submit-bar>span{font-size:12px;line-height:1.6;min-width:120px}
.hw-study .hw-submit-bar .btn{font-size:13px;padding-inline:16px}
.hw-study .hw-preview-question{margin-top:24px}
.hw-study .hw-preview-question>.hw-prose,.hw-study .hw-preview-question>h2,.hw-study .hw-preview-question>.hw-image{margin:28px 32px}
.hw-study .hw-preview-question .panel-head,.hw-study-result .editor-fields{padding:28px 32px}
.hw-study-result .hw-score{color:var(--ink);white-space:nowrap}
@media(max-width:1100px){.hw-study .hw-attempt-grid{grid-template-columns:190px minmax(0,1fr);gap:20px}.hw-study .hw-answer-nav{padding:18px}.hw-study .hw-submit-bar{margin-left:210px}.hw-study .hw-submit-bar>span{flex-basis:100%}}
@media(max-width:850px){.hw-study>.back-link{margin-bottom:20px}.hw-study .heading h1{font-size:28px;letter-spacing:-.6px}.hw-study .hw-attempt-grid{display:flex;flex-direction:column;gap:16px;margin-top:22px}.hw-study .hw-answer-nav{position:static;width:100%;padding:18px 18px 14px}.hw-study .hw-question{width:100%}.hw-study #hw-progress{margin:12px 0 16px}.hw-study .hw-question-numbers{display:flex;flex-wrap:nowrap;overflow-x:auto;padding:3px 3px 10px;margin:-3px;gap:8px;scrollbar-width:thin}.hw-study .hw-number{flex:0 0 44px;min-width:44px;height:44px}.hw-study .hw-answer-nav>small{display:none}.hw-study .hw-submit-bar{margin:18px 0 0;display:grid;grid-template-columns:1fr 1fr;gap:12px}.hw-study .hw-submit-bar>span{grid-column:1/-1}.hw-study .hw-question .panel-head{padding:22px 24px}.hw-study .hw-question .editor-fields{padding:24px}.hw-study .hw-preview-question>.hw-prose,.hw-study .hw-preview-question>h2,.hw-study .hw-preview-question>.hw-image{margin:24px}.hw-study .hw-preview-question .panel-head,.hw-study-result .editor-fields{padding:24px}}
@media(max-width:480px){:root .hw-study .panel{border-radius:20px}.hw-study .heading h1{font-size:25px}.hw-study .heading .eyebrow{font-size:11px}.hw-study .subline{font-size:12px}.hw-study-intro{margin-bottom:22px}.hw-study-intro .hw-prose{font-size:14px}.hw-study .hw-question .panel-head{padding:20px}.hw-study .hw-question .editor-fields{padding:22px 20px 20px}.hw-study .hw-question .panel-head h2{font-size:18px}.hw-study .hw-prose{font-size:16px;line-height:1.75}.hw-study .hw-response{padding:18px;margin:26px -4px 20px}.hw-study .hw-submit-bar .btn{font-size:12px;padding:12px 8px}.hw-study .hw-preview-question>.hw-prose,.hw-study .hw-preview-question>h2,.hw-study .hw-preview-question>.hw-image{margin:20px}.hw-study .hw-preview-question .panel-head,.hw-study-result .editor-fields{padding:20px}}
@media(prefers-reduced-motion:reduce){.hw-study *{transition:none!important;scroll-behavior:auto!important}}
.hw-study-intro summary{font-size:14px;cursor:pointer;width:fit-content;padding:4px 0;line-height:1.6}
.hw-study-intro[open] .hw-prose{margin-top:12px}
.hw-study .hw-question .editor-fields{display:block}

/* Written homework: one readable task column and one submission workspace. */
.hw-written-tools{display:flex;align-items:center;justify-content:space-between;gap:16px;margin:24px 0;color:var(--muted);font-size:13px}
.hw-written-layout{display:grid;grid-template-columns:minmax(0,1fr) 360px;gap:28px;align-items:start}
.hw-written-layout>*{min-width:0}.hw-written-questions{display:grid;gap:24px}
.hw-study .hw-written-question{margin:0;overflow:hidden}
.hw-study .hw-written-question .panel-head{padding:24px 28px;align-items:center;gap:16px}
.hw-study .hw-written-question h2{font-size:20px;line-height:1.4;letter-spacing:-.4px}
.hw-written-question .badge{flex-shrink:0;font-size:12px;font-weight:500;background:var(--soft);color:var(--muted);border-color:transparent}
.hw-written-condition{padding:28px}.hw-written-condition .hw-prose{font-size:17px;line-height:1.85;margin:0}.hw-written-condition .hw-image{margin:0 0 24px}
.hw-written-delivery{scroll-margin-top:24px;outline:none}.hw-written-delivery:focus-visible{outline:2px solid var(--focus);outline-offset:5px;border-radius:24px}
.hw-written-delivery .panel{margin:0}.hw-written-delivery .step-title{gap:12px}.hw-written-delivery .step-title h2{font-size:21px;letter-spacing:-.4px}.hw-written-delivery .file-count{white-space:nowrap;font-size:12px}
.hw-written-delivery .submission-file{flex-wrap:wrap;gap:10px}.hw-written-delivery .submission-file-main{flex-basis:calc(100% - 44px)}
.hw-written-delivery .submission-file-order{width:100%;justify-content:flex-end}.hw-written-delivery .form-actions{display:flex;flex-direction:column;align-items:stretch;gap:20px;padding:20px 24px}
.hw-written-delivery #submit-work{width:100%;justify-content:center}.hw-written-delivery .check-inline{font-size:13px;line-height:1.6}
@media(max-width:1100px){.hw-written-layout{grid-template-columns:minmax(0,1fr) 320px;gap:20px}.hw-study .hw-written-question .panel-head,.hw-written-condition{padding:24px}}
@media(max-width:850px){.hw-written-layout{grid-template-columns:1fr;gap:28px}.hw-written-tools{margin:20px 0}.hw-written-delivery .submission-form{max-width:none}.hw-written-questions{gap:18px}}
@media(max-width:480px){.hw-written-tools{gap:10px;align-items:center;font-size:12px}.hw-written-tools .btn{font-size:12px;min-height:44px;padding:10px 12px;white-space:nowrap}.hw-study .hw-written-question .panel-head{padding:18px 20px}.hw-study .hw-written-question h2{font-size:18px}.hw-written-condition{padding:20px}.hw-written-condition .hw-prose{font-size:16px;line-height:1.75}.hw-written-delivery .form-actions{padding:18px}}
@media(min-width:851px) and (min-height:800px){.hw-written-delivery:has(.files:empty){position:sticky;top:24px}}
