/* Account pages and the private teacher workspace. */
.teacher-header-nav { display: flex; flex-wrap: wrap; justify-content: flex-end; align-items: center; gap: 6px 25px; font-size: 12px; }
.teacher-header-nav a { text-decoration: none; color: #5e6558; padding: 8px 0; white-space: nowrap; }
.teacher-header-nav a span { margin-left: 5px; color: #8a8f80; }
.teacher-header-nav a:hover { color: var(--ink); }
.teacher-header-nav form { margin: 0; }
.teacher-header-nav button { appearance: none; -webkit-appearance: none; font: inherit; color: #5e6558; background: transparent; border: 1px solid #dddfd5; border-radius: 9px; padding: 9px 14px; cursor: pointer; white-space: nowrap; }
.teacher-header-nav button:hover { background: #eeefe8; }
.teacher-header-nav button:focus-visible, .account-submit:focus-visible { outline: 3px solid var(--focus); outline-offset: 4px; }

.account-page .site-header { border-bottom: 0; }
.main-content.account-main { display: flex; justify-content: center; align-items: center; padding: 36px 24px 62px; }
.account-card { width: 100%; max-width: 410px; text-align: center; }
.account-symbol { display: grid; place-items: center; width: 53px; height: 53px; background: #efedf4; color: #786888; border: 1px solid #e8e3ee; border-radius: 16px; font: 35px/1 Georgia, serif; margin: 0 auto 29px; padding-bottom: 8px; }
.account-eyebrow { margin: 0 0 15px; color: #7e8375; font-size: 10px; letter-spacing: 1.65px; font-weight: 550; }
.account-card h1 { font-size: 42px; letter-spacing: -1.8px; line-height: 1.12; margin-bottom: 14px; }
.account-intro { margin: 0; font-size: 14px; line-height: 1.75; color: var(--muted); }
.account-form { margin-top: 33px; text-align: left; }
.account-field { margin-bottom: 19px; }
.account-field label { display: block; margin-bottom: 9px; color: #454a40; font-size: 12px; font-weight: 500; }
.account-field input { display: block; width: 100%; min-height: 50px; padding: 13px 15px; border: 1px solid #dfe2d8; border-radius: 12px; background: white; color: var(--ink); font: inherit; font-size: 15px; transition: border-color 150ms ease, box-shadow 150ms ease; }
.account-field input:focus { outline: 0; border-color: #9d8daf; box-shadow: 0 0 0 3px #7c629c0e; }
.account-field input[aria-invalid="true"] { border-color: #b78070; }
.account-submit { width: 100%; display: flex; align-items: center; justify-content: center; gap: 14px; min-height: 50px; padding: 14px 20px; margin-top: 24px; border: 1px solid #30372e; border-radius: 12px; background: #30372e; color: white; font-family: inherit; font-size: 13px; font-weight: 500; cursor: pointer; transition: background 150ms ease; }
.account-submit:hover { background: #414b3d; }
.account-submit span { font-size: 19px; line-height: .7; font-weight: 400; }
.account-note { margin: 25px 0 0; color: #7f8478; font-size: 11px; line-height: 1.8; }
.account-setup-link { margin: 24px 0 0; color: #7f8478; font-size: 11px; line-height: 1.8; }
.account-setup-link a { color: #7d698f; text-underline-offset: 3px; }
.account-footer { text-align: center; padding: 22px 24px; color: #8b8f84; font-size: 10px; }
.form-errors { padding: 13px 15px; margin-bottom: 23px; background: #faf0ed; color: #984a35; border: 1px solid #efd8d1; border-radius: 10px; font-size: 12px; line-height: 1.6; }
.form-errors ul, .field-errors ul { list-style: none; padding: 0; margin: 0; }
.field-errors { color: #a54f37; font-size: 12px; line-height: 1.65; margin-top: 8px; }
.field-help { color: #787e70; font-size: 11px; line-height: 1.65; margin-top: 8px; }
.field-help ul { margin: 0; padding-left: 17px; }
.setup-card { max-width: 425px; }
.setup-card .account-symbol { margin-bottom: 22px; }
.setup-card h1 { font-size: 37px; }
.setup-card .account-form { margin-top: 27px; }

.main-content.teacher-main { width: min(100%, 1060px); padding-top: 52px; padding-bottom: 76px; }
.teacher-intro .eyebrow, .transcript-header .eyebrow { color: #82738f; margin-top: 0; margin-bottom: 18px; }
.teacher-intro .eyebrow-line, .transcript-header .eyebrow-line { background: #9b8baa; }
.teacher-intro h1 { font-size: clamp(34px, 4.2vw, 44px); letter-spacing: -1.7px; margin-bottom: 14px; }
.teacher-intro .intro-description { font-size: 15px; }
.teacher-intro-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 24px; margin-top: 24px; }
.teacher-intro-actions .workspace-text-link { display: inline-flex; align-items: center; min-height: 40px; }
.conversation-filters { margin-top: 36px; }
.workspace-section-heading { display: flex; align-items: baseline; justify-content: space-between; flex-wrap: wrap; gap: 8px 20px; margin-bottom: 18px; }
.workspace-section-heading h2, .api-panel-heading h2 { margin: 0; font-size: 15px; font-weight: 500; letter-spacing: -.2px; }
.workspace-section-heading p { margin: 0; color: #818779; font-size: 11px; line-height: 1.6; }
.filter-form { display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr) minmax(0, 1fr) auto; gap: 15px; align-items: start; }
.filter-errors { grid-column: 1 / -1; margin-bottom: 0; }
.workspace-field { min-width: 0; }
.workspace-field label { display: block; margin: 0 0 9px; color: #67705d; font-size: 11px; font-weight: 500; }
.workspace-field select { appearance: none; width: 100%; min-height: 45px; padding: 11px 34px 11px 14px; border: 1px solid #dfe3d8; border-radius: 10px; color: #424b37; background: #fff url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12' fill='none'%3E%3Cpath d='m3 4.5 3 3 3-3' stroke='%23838978' stroke-width='1.2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") no-repeat right 13px center; font-family: inherit; font-size: 13px; line-height: 1.6; cursor: pointer; }
.workspace-field select:hover { border-color: #b9c1ae; }
.workspace-field select:focus-visible { outline: 3px solid #86719925; outline-offset: 1px; border-color: #a18db3; }
.workspace-field select[aria-invalid="true"] { border-color: #b78070; }
.filter-actions { display: flex; align-items: center; gap: 15px; padding-top: 22px; }
.workspace-button { min-height: 45px; padding: 11px 18px; border: 1px solid #343b30; border-radius: 10px; background: #343b30; color: #fff; font-family: inherit; font-size: 12px; font-weight: 500; line-height: 1.6; white-space: nowrap; cursor: pointer; transition: background 150ms ease; }
.workspace-button:hover { background: #49513f; }
.workspace-button:focus-visible { outline: 3px solid var(--focus); outline-offset: 4px; }
.workspace-text-link { color: #82718f; font-size: 11px; line-height: 1.7; text-decoration: underline; text-underline-offset: 4px; white-space: nowrap; }
.workspace-text-link:hover { color: #614978; }
.api-panel { margin-top: 31px; padding: 24px 26px 25px; border: 1px solid #e2e5dc; border-radius: 17px; background: #fff; }
.api-panel-heading { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 12px; }
.api-status { display: inline-flex; align-items: center; gap: 7px; border-radius: 6px; padding: 5px 8px; color: #637457; background: #f1f4ec; font-size: 10px; }
.api-status > span { display: block; width: 5px; height: 5px; background: #879e73; border-radius: 50%; }
.api-status.is-paused { color: #90735b; background: #f8f3ec; }
.api-status.is-paused > span { background: #b49a7e; }
.api-panel-body { display: grid; grid-template-columns: minmax(0, .8fr) minmax(0, 1.2fr); gap: 32px; margin-top: 25px; }
.api-usage { border-right: 1px solid #edefe7; padding: 2px 30px 0 0; }
.usage-label { margin: 0; color: #707968; font-size: 12px; }
.usage-label > span { color: #939b89; font-size: 10px; }
.usage-amount { margin: 12px 0 6px; color: #333a2d; font-size: clamp(30px, 4vw, 37px); font-weight: 450; letter-spacing: -1.6px; line-height: 1.2; font-variant-numeric: tabular-nums; overflow-wrap: anywhere; }
.usage-currency { font-size: .7em; margin-right: 3px; color: #717b65; vertical-align: 3px; font-weight: 400; }
.usage-count { margin: 0; color: #87917a; font-size: 11px; }
.usage-scope { margin: 19px 0 0; color: #899180; font-size: 10px; line-height: 1.8; }
.usage-scope strong { font-weight: 500; color: #6d7860; }
.usage-unconfirmed { margin: 12px 0 0; color: #947752; font-size: 10px; line-height: 1.6; }
.api-settings-form { min-width: 0; }
.api-controls { min-width: 0; }
.api-settings-actions { display: flex; align-items: stretch; gap: 8px; }
.api-reset-button { min-height: 40px; padding: 9px 13px; border: 1px solid #ded8e5; border-radius: 10px; background: #faf8fc; color: #756183; font: inherit; font-size: 11px; cursor: pointer; }
.api-reset-button:hover { background: #f0ebf5; }
.api-reset-button:focus-visible { outline: 2px solid var(--focus); outline-offset: 3px; }
.api-settings-form .workspace-field label { margin-top: 1px; }
.api-access-control { margin: 19px 0 20px; }
.api-toggle { display: flex; align-items: center; gap: 10px; width: fit-content; color: #59624e; font-size: 12px; line-height: 1.7; cursor: pointer; }
.api-toggle input { appearance: none; flex: 0 0 auto; width: 36px; height: 22px; border: 1px solid #ced3c5; border-radius: 20px; padding: 0; margin: 0; background: #e4e7df; cursor: pointer; transition: background 150ms ease; }
.api-toggle input::before { content: ""; display: block; width: 16px; height: 16px; border-radius: 50%; background: #fff; box-shadow: 0 1px 3px #28351c26; margin: 2px; transition: transform 150ms ease; }
.api-toggle input:checked { background: #80718f; border-color: #80718f; }
.api-toggle input:checked::before { transform: translateX(14px); }
.api-toggle input:focus-visible { outline: 3px solid var(--focus); outline-offset: 4px; }
.api-settings-footer { display: flex; align-items: center; justify-content: space-between; gap: 22px; }
.api-settings-footer p { max-width: 245px; margin: 0; color: #8b9182; font-size: 10px; line-height: 1.7; }
.api-counter-date time { color: #59624e; font-variant-numeric: tabular-nums; }
.api-settings-footer .workspace-button { min-height: 40px; padding: 9px 14px; font-size: 11px; }
.settings-saved { margin: 16px 0 0; padding: 10px 12px; border: 1px solid #e0e6d6; border-radius: 8px; background: #f5f8f0; color: #667c51; font-size: 12px; line-height: 1.6; }
.conversation-library { margin-top: 32px; }
.library-heading { display: flex; justify-content: space-between; align-items: center; gap: 15px; margin-bottom: 16px; }
.library-heading h2 { margin: 0; font-size: 15px; font-weight: 500; letter-spacing: -.2px; }
.library-heading > span { color: #858a7e; font-size: 11px; }
.conversation-list { display: grid; gap: 13px; }
.privacy-copy { max-width: 680px; color: var(--muted); font-size: 15px; line-height: 1.8; }
.privacy-copy h2 { margin: 26px 0 8px; font-size: 20px; font-weight: 500; color: var(--ink); }
.privacy-copy a { color: #756183; text-underline-offset: 4px; }
.allowance-panel { margin-top: 28px; padding: 24px 26px; border: 1px solid var(--line); border-radius: 17px; background: white; }
.allowance-entry { display: flex; align-items: flex-end; flex-wrap: wrap; gap: 12px; }
.allowance-entry .workspace-field { flex: 1; min-width: 180px; }
.allowance-entry input { width: 100%; max-width: 300px; min-height: 44px; padding: 10px 13px; border: 1px solid #dfe3d8; border-radius: 10px; color: #424b37; background: #fff; font: inherit; font-size: 14px; }
.allowance-entry input:focus-visible { outline: 3px solid #86719925; outline-offset: 1px; border-color: #a18db3; }
.allowance-entry input:disabled { background: #f7f7f4; color: #8b9182; }
.allowance-entry button { min-height: 44px; }
.allowance-panel + .student-settings { margin-top: 24px; }
.allowance-inherit { display: flex; align-items: center; gap: 8px; margin: 12px 0 18px; color: var(--muted); font-size: 12px; }
.allowance-note { margin: 13px 0 0; color: var(--muted); font-size: 11px; line-height: 1.6; }
.student-card-copy .student-balance { margin-top: 7px; font-size: 11px; color: #756183; }
.conversation-pagination { margin-top: 20px; text-align: center; }
.conversation-pagination [aria-disabled="true"] { opacity: .65; cursor: wait; }
.conversation-pagination [hidden] { display: none; }
.conversation-pagination p:not(.sr-only) { color: #9b4938; font-size: 12px; }
.conversation-card { display: flex; gap: 20px; align-items: center; text-decoration: none; background: white; border: 1px solid #e4e7de; border-radius: 17px; padding: 25px; transition: border-color 150ms ease, box-shadow 150ms ease; }
.conversation-card:hover { border-color: #b8aac7; box-shadow: 0 5px 22px #35264607; }
.conversation-avatar { flex: 0 0 auto; display: grid; place-items: center; width: 47px; height: 47px; color: #6f775e; background: #eff2e9; border-radius: 15px; font-size: 17px; font-weight: 450; }
.conversation-card-copy { min-width: 0; flex: 1; }
.conversation-card-heading { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; }
.conversation-card h3 { margin: 0; font-size: 17px; font-weight: 500; letter-spacing: -.4px; line-height: 1.45; }
.sample-badge { display: inline-flex; align-items: center; width: fit-content; white-space: nowrap; padding: 4px 7px; background: #f4f0f8; color: #867197; border: 1px solid #eae3f0; border-radius: 5px; font-size: 9px; font-weight: 450; letter-spacing: .05px; }
.conversation-card-copy > p { margin: 9px 0 10px; color: #787f6e; font-size: 12px; line-height: 1.7; }
.conversation-card-copy p > span, .conversation-card-date > span { margin: 0 5px; color: #b5b9ad; }
.conversation-card-date { font-size: 10px; color: #92988b; }
.conversation-open { display: grid; place-items: center; height: 30px; width: 30px; flex: 0 0 auto; border: 1px solid #e5e7df; border-radius: 50%; color: #8b7a9d; font-size: 17px; }
.library-empty { text-align: center; padding: 42px 24px; border: 1px dashed #d4d9cb; border-radius: 16px; }
.library-empty h3 { font-size: 15px; font-weight: 500; margin: 0 0 10px; }
.library-empty p { margin: 0; color: var(--muted); font-size: 13px; }
.library-note { margin: 17px 0 0; color: #8a8093; font-size: 10px; line-height: 1.8; }
.teacher-footer { color: #858b7c; }

/* Accounts remain deliberately small: a list and one clear creation action. */
.student-page-actions { display: flex; align-items: center; justify-content: flex-start; flex-wrap: wrap; gap: 14px; margin: 26px 0; }
.student-page-actions .workspace-button { display: inline-flex; align-items: center; justify-content: center; gap: 9px; text-decoration: none; }
.students-main .teacher-intro > p:not(.eyebrow) { max-width: 680px; margin: 0; color: var(--muted); font-size: 15px; line-height: 1.8; }
.account-card .student-page-actions { justify-content: center; }
.student-list { display: grid; gap: 12px; margin-top: 25px; }
.student-card { display: flex; align-items: center; gap: 18px; padding: 22px 24px; border: 1px solid var(--line); border-radius: 16px; background: #fff; }
.student-card-copy { flex: 1; min-width: 0; }
.student-card h3 { margin: 0; color: #41493a; font-size: 16px; line-height: 1.5; font-weight: 500; overflow-wrap: anywhere; }
.student-card p { margin: 6px 0 0; color: var(--muted); font-size: 12px; line-height: 1.7; overflow-wrap: anywhere; }
.student-card p span { margin-left: 5px; color: #5f6756; }
.student-status { padding: 5px 8px; border-radius: 6px; background: #f1f4ec; color: #637457; font-size: 10px; line-height: 1.5; }
.student-status.is-inactive { background: #f4f0ea; color: #917961; }
.account-card .teacher-back { margin-bottom: 28px; }
.workspace-field select { transition: border-color var(--motion-quick) ease, box-shadow var(--motion-quick) ease; }
.conversation-card:active { border-color: #9d8dac; }
.teacher-intro .workspace-button { display: inline-flex; align-items: center; justify-content: center; text-decoration: none; }

/* Folder-backed teaching material: readable forms and reversible removals. */
.content-main .teacher-back, .content-editor-main .teacher-back { margin-bottom: 30px; }
.content-introduction { white-space: pre-line; }
.content-library { margin-top: 38px; }
.content-records { display: grid; gap: 11px; }
.content-record { display: flex; align-items: center; flex-wrap: wrap; gap: 16px 24px; padding: 21px 24px; border: 1px solid var(--line); border-radius: 15px; background: #fff; }
.content-record-copy { min-width: 0; flex: 1 1 230px; }
.content-record h3 { margin: 0; font-size: 16px; font-weight: 500; line-height: 1.5; overflow-wrap: anywhere; }
.content-record h3 a { text-decoration: none; }
.content-record h3 a:hover { color: #75608e; }
.content-record-meta { margin: 5px 0 0; color: #747b6a; font-size: 11px; line-height: 1.7; }
.content-record-meta:first-child { margin: 0 0 6px; }
.content-record-actions { display: flex; align-items: center; flex-wrap: wrap; gap: 10px 20px; }
.content-record-actions > a { color: #75608e; font-size: 12px; line-height: 1.7; text-underline-offset: 4px; white-space: nowrap; }
.content-record form { margin: 0; }
.content-record-actions > .content-remove, .content-remove { color: #94766b; }
.content-quiet-button { appearance: none; border: 1px solid var(--line); border-radius: 9px; padding: 8px 12px; background: #f8f8f4; color: #5f6855; font: inherit; font-size: 12px; line-height: 1.5; cursor: pointer; }
.content-quiet-button:hover { background: #f0f0e9; border-color: #cdd3c3; }
.content-quiet-button:focus-visible, .content-removed summary:focus-visible { outline: 3px solid var(--focus); outline-offset: 3px; }
.content-count { margin-left: 6px; color: #8f9588; font-size: 11px; font-weight: 400; }
.content-removed { margin-top: 24px; padding-top: 19px; border-top: 1px solid var(--line); }
.content-removed > summary { width: fit-content; color: #7c8073; font-size: 12px; line-height: 1.7; cursor: pointer; }
.content-removed > summary span { margin-left: 6px; color: #969b8f; }
.content-removed > p { margin: 13px 0 0; font-size: 12px; color: var(--muted); line-height: 1.7; }
.content-removed .content-records { margin-top: 17px; }
.content-removed .content-record { background: #f6f6f1; }
.content-archive-notice { display: flex; align-items: center; flex-wrap: wrap; gap: 14px 22px; margin-top: 24px; padding: 18px 20px; border: 1px solid #ebe1d3; border-radius: 12px; background: #faf7f1; }
.content-archive-notice p { flex: 1 1 300px; margin: 0; color: #897653; font-size: 12px; line-height: 1.7; }
.content-archive-notice form { margin: 0; }
.main-content.content-editor-main { width: min(100%, 920px); }
.content-editor-main .intro-description { max-width: 700px; line-height: 1.8; }
.content-editor-form { margin-top: 34px; }
.content-fields { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 23px 22px; }
.content-field { min-width: 0; }
.content-field.is-wide { grid-column: 1 / -1; }
.content-field > label { display: block; margin-bottom: 9px; color: #4c5443; font-size: 12px; font-weight: 500; line-height: 1.7; }
.content-field input:not([type="checkbox"]), .content-field select, .content-field textarea { display: block; width: 100%; min-height: 46px; border: 1px solid #dce1d4; border-radius: 11px; padding: 12px 14px; background: #fff; color: var(--ink); font: inherit; font-size: 14px; line-height: 1.75; transition: border-color var(--motion-quick) ease, box-shadow var(--motion-quick) ease; }
.content-field textarea { resize: vertical; min-height: 130px; tab-size: 4; }
.content-field input:focus-visible, .content-field select:focus-visible, .content-field textarea:focus-visible { outline: 0; border-color: #a48eb7; box-shadow: 0 0 0 3px #9072ad13; }
.content-field input:disabled, .content-field select:disabled { background: #eeeFE8; color: #737c67; opacity: 1; }
.content-field [aria-invalid="true"] { border-color: #bc8c79; }
.content-field .content-checkbox { display: flex; align-items: center; gap: 10px; margin: 2px 0; cursor: pointer; }
.content-checkbox input { width: 18px; height: 18px; margin: 0; accent-color: #80718f; }
.content-checkbox input:focus-visible { outline: 2px solid var(--focus); outline-offset: 3px; }
.content-field input[type="file"] { background: #fbfbf8; font-size: 12px; }
.content-field input[type="file"]::file-selector-button { margin-right: 12px; padding: 7px 11px; border: 1px solid #e1dce8; border-radius: 7px; background: #f3f0f7; color: #75608e; font: inherit; cursor: pointer; }
.content-field .field-help { margin-bottom: 0; font-size: 11px; line-height: 1.8; }
.content-form-footer { display: flex; align-items: center; justify-content: space-between; gap: 24px; border-top: 1px solid var(--line); padding-top: 23px; margin-top: 29px; }
.content-form-footer > p { flex: 1; max-width: 360px; margin: 0; color: #7e8772; font-size: 11px; line-height: 1.8; }
.content-form-buttons { display: flex; align-items: center; justify-content: flex-end; flex-wrap: wrap; gap: 18px; }
.content-confirm { max-width: 650px; }
.content-confirm h1 { font-size: clamp(30px, 4vw, 40px); line-height: 1.25; letter-spacing: -1.2px; overflow-wrap: anywhere; }
.content-confirm > p:not(.eyebrow) { margin: 0; color: var(--muted); font-size: 15px; line-height: 1.85; }
.content-confirm form { margin-top: 29px; }
.content-confirm .content-form-buttons { justify-content: flex-start; }
.content-remove-button { border-color: #835d50; background: #835d50; }
.content-remove-button:hover { background: #6f4b3f; }

.main-content.transcript-main { max-width: 900px; padding-top: 31px; }
.teacher-back { display: inline-flex; align-items: center; gap: 11px; margin-bottom: 43px; color: #7b8272; font-size: 12px; text-decoration: none; }
.teacher-back span { font-size: 16px; }
.teacher-back:hover { color: var(--ink); }
.transcript-header h1 { font-size: clamp(30px, 4vw, 42px); line-height: 1.2; letter-spacing: -1.4px; margin-bottom: 15px; }
.transcript-meta { margin: 0 0 13px; color: #747c6a; font-size: 13px; line-height: 1.8; }
.transcript-meta > span { margin: 0 5px; color: #adb3a5; }
.transcript-submeta { display: flex; align-items: center; flex-wrap: wrap; gap: 8px; color: #92978c; font-size: 10px; }
.transcript-submeta .sample-badge { margin-left: 5px; }
.transcript-sample-note { margin: 22px 0 0; color: #8b7b96; font-size: 11px; line-height: 1.8; }
.transcript-problem { background: #fff; border: 1px solid #e2e5db; border-radius: 17px; padding: 24px 27px 21px; margin-top: 25px; }
.transcript-problem h2 { margin: 0 0 14px; color: #666e5d; font-size: 12px; font-weight: 550; }
.transcript-problem-text { font-size: 14px; line-height: 1.9; white-space: normal; overflow-wrap: anywhere; }
.transcript-problem-text .katex-display, .transcript-text .katex-display { overflow-x: auto; overflow-y: hidden; padding: 5px 0; margin: 10px 0; }
.transcript-problem-text .katex, .transcript-text .katex { white-space: normal; }
.transcript { display: flex; flex-direction: column; gap: 27px; margin-top: 37px; }
.transcript-message { width: 91%; min-width: 0; }
.transcript-message.from-student { align-self: flex-end; }
.transcript-message.from-tutor { align-self: flex-start; }
.transcript-message-meta { display: flex; align-items: center; flex-wrap: wrap; gap: 9px; margin-bottom: 9px; padding: 0 3px; font-size: 10px; }
.transcript-speaker { color: #666e5d; font-weight: 550; }
.transcript-action { color: #9a9f92; }
.transcript-message-meta time { margin-left: auto; color: #a2a79a; font-variant-numeric: tabular-nums; font-size: 9px; }
.transcript-bubble { padding: 20px 23px; border-radius: 17px; border: 1px solid #e7e9e1; }
.from-student .transcript-bubble { background: #eeeee8; border-color: #e8e8df; border-top-right-radius: 5px; }
.from-tutor .transcript-bubble { background: white; border-top-left-radius: 5px; }
.transcript-text { white-space: pre-wrap; overflow-wrap: anywhere; font-size: 14px; line-height: 1.85; color: #474e3f; }
.assessment-label { display: inline-flex; width: fit-content; margin-bottom: 12px; border-radius: 5px; padding: 4px 7px; background: #f3f0f7; color: #867297; font-size: 10px; }
.message-details { padding: 9px 4px 0; color: #91978a; font-size: 10px; }
.message-details summary { cursor: pointer; width: fit-content; }
.message-details summary:focus-visible { outline: 2px solid var(--focus); outline-offset: 4px; }
.message-details p { margin: 8px 0 0; line-height: 1.7; }
.transcript-empty { color: var(--muted); text-align: center; font-size: 13px; }
.transcript-end { display: flex; align-items: center; justify-content: center; gap: 16px; margin-top: 34px; }
.transcript-end > span { width: 27px; height: 1px; background: #dcded4; }
.transcript-end p { font-size: 10px; color: #969c8c; margin: 0; }

@media (max-width: 900px) {
  .filter-form { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .filter-actions { grid-column: 1 / -1; padding-top: 0; }
  .api-panel-body { grid-template-columns: minmax(0, .9fr) minmax(0, 1.1fr); gap: 24px; }
  .api-usage { padding-right: 24px; }
  .api-settings-footer { align-items: flex-start; flex-direction: column; gap: 14px; }
}
@media (max-width: 700px) {
  .teacher-header-nav { gap: 14px; font-size: 11px; }
  .teacher-header-nav button { padding: 8px 10px; }
  .teacher-page .brand { font-size: 19px; }
  .teacher-page .brand-mark { width: 29px; height: 29px; }
  .teacher-page .site-header { gap: 12px; }
  .main-content.account-main { align-items: flex-start; padding: 38px 28px 38px; }
  .account-card h1 { font-size: 37px; }
  .setup-card h1 { font-size: 34px; }
  .account-symbol { margin-bottom: 26px; }
  .account-form { margin-top: 28px; }
  .account-field input { font-size: 16px; }
  .main-content.teacher-main { padding: 42px 24px 55px; }
  .conversation-filters { margin-top: 30px; }
  .workspace-section-heading { margin-bottom: 17px; }
  .workspace-section-heading p { width: 100%; }
  .filter-form { grid-template-columns: 1fr; gap: 16px; }
  .workspace-field select { font-size: 16px; }
  .workspace-field label { font-size: 12px; }
  .filter-actions { gap: 20px; margin-top: 2px; }
  .filter-actions .workspace-button { flex: 1; }
  .workspace-text-link { font-size: 12px; }
  .api-panel { margin-top: 27px; padding: 21px 19px; }
  .api-panel-body { grid-template-columns: 1fr; gap: 21px; margin-top: 23px; }
  .api-usage { border-right: 0; border-bottom: 1px solid #edefe7; padding: 0 0 22px; }
  .usage-amount { font-size: 35px; }
  .usage-scope { margin-top: 14px; }
  .api-toggle { min-height: 32px; font-size: 13px; }
  .api-settings-footer { gap: 16px; }
  .api-settings-footer p { max-width: none; font-size: 11px; }
  .api-settings-footer .workspace-button { width: 100%; min-height: 44px; font-size: 12px; }
  .api-settings-actions { width: 100%; }
  .api-settings-actions > button { flex: 1; }
  .api-reset-button { min-height: 44px; font-size: 12px; }
  .conversation-library { margin-top: 30px; }
  .library-heading > span { font-size: 10px; }
  .conversation-card { align-items: flex-start; gap: 14px; padding: 20px 17px; }
  .conversation-avatar { width: 36px; height: 38px; border-radius: 11px; font-size: 14px; }
  .conversation-card-heading { gap: 7px; }
  .conversation-card h3 { font-size: 15px; }
  .conversation-card-copy > p { font-size: 11px; margin: 9px 0 8px; }
  .conversation-open { display: none; }
  .main-content.transcript-main { padding-top: 25px; }
  .teacher-back { margin-bottom: 31px; }
  .transcript-header h1 { font-size: 32px; }
  .transcript-meta { font-size: 12px; }
  .transcript-problem { padding: 20px; }
  .transcript-problem-text { font-size: 13px; }
  .transcript { gap: 24px; margin-top: 29px; }
  .transcript-message { width: 96%; }
  .transcript-bubble { padding: 17px 18px; border-radius: 14px; }
  .transcript-text { font-size: 13px; }
  .transcript-message-meta { gap: 7px; font-size: 9px; }
}
@media (max-width: 560px) {
  .teacher-header-nav { width: 100%; justify-content: flex-start; gap: 5px 16px; font-size: 11px; }
  .teacher-header-nav form { margin-left: auto; }
  .teacher-header-nav a { padding-top: 6px; padding-bottom: 6px; }
  .teacher-header-nav button { min-height: 32px; padding: 6px 10px; }
  .student-card { padding: 18px; flex-wrap: wrap; gap: 12px; }
  .student-card .conversation-avatar { width: 36px; height: 38px; border-radius: 11px; }
  .student-card h3 { font-size: 15px; }
  .student-card p { font-size: 11px; }
  .student-page-actions .workspace-button { width: 100%; }
  html:lang(mk) .teacher-header-nav { gap: 5px 13px; }
  .content-fields { grid-template-columns: minmax(0, 1fr); gap: 21px; }
  .content-field input:not([type="checkbox"]), .content-field select, .content-field textarea { font-size: 16px; }
  .content-field input[type="file"] { font-size: 12px; }
  .content-record { padding: 18px; gap: 13px; }
  .content-record h3 { font-size: 15px; }
  .content-record-actions { gap: 14px 22px; }
  .content-form-footer { align-items: stretch; flex-direction: column; gap: 20px; }
  .content-form-footer > p { max-width: none; }
  .content-form-buttons .workspace-button { flex: 1; text-align: center; }
  .content-confirm .content-form-buttons { flex-wrap: nowrap; }
  .content-confirm .workspace-button { white-space: normal; }
  .content-main .library-heading { flex-wrap: wrap; }
}
@media (max-width: 380px) {
  .teacher-page .brand { font-size: 17px; gap: 6px; }
  .teacher-header-nav { gap: 10px; font-size: 10px; }
  .teacher-header-nav a span { display: none; }
}

.transcript-status { margin: 10px 4px 0; font-size: 12px; line-height: 1.6; color: var(--muted); }

.student-card { text-decoration: none; transition: border-color var(--motion-quick) ease, box-shadow var(--motion-quick) ease; }
.student-card:hover { border-color: #c6bfce; box-shadow: 0 4px 20px #38322e06; }
.student-card:focus-visible { outline: 2px solid var(--focus); outline-offset: 4px; }
.student-open { color: #8b8097; }
.main-content.student-detail-main { max-width: 1040px; }
.student-intro h1 { overflow-wrap: anywhere; }
.student-intro > p:last-child { font-size: 14px; }
.student-intro > p:last-child span { margin: 0 8px; }
.student-stats { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; margin-top: 32px; }
.student-stat { min-width: 0; border: 1px solid var(--line); border-radius: 18px; padding: 27px; background: #fff; }
.student-stat h2, .student-setting h2 { margin: 0; font-size: 14px; font-weight: 500; }
.student-stat .student-stat-value { font-size: 46px; line-height: 1.2; letter-spacing: -1px; color: var(--ink); margin: 17px 0 13px; }
.student-stat .is-unrecorded { font-size: 24px; letter-spacing: -.4px; margin-top: 25px; margin-bottom: 23px; }
.student-stat > p:last-child, .student-setting p { margin: 0; font-size: 12px; line-height: 1.8; color: var(--muted); }
.student-stat p span { margin: 0 4px; }
.student-activity-note { max-width: 760px; color: var(--muted); font-size: 11px; line-height: 1.9; margin: 16px 3px 28px; }
.student-settings { border: 1px solid var(--line); border-radius: 18px; background: #fff; padding: 0 27px; }
.student-setting { display: flex; justify-content: space-between; align-items: center; gap: 30px; padding: 25px 0; }
.student-setting + .student-setting { border-top: 1px solid var(--line); }
.student-setting > div { max-width: 530px; }
.student-setting p { margin-top: 7px; }
.student-setting a { flex-shrink: 0; }
.student-delete-link { color: #986856; }
.usage-explanation { max-width: 360px; margin-top: 8px; color: var(--muted); font-size: 11px; line-height: 1.8; }
.usage-explanation summary { cursor: pointer; color: #82708f; }
.usage-explanation ul { padding-left: 17px; }
.usage-explanation li + li { margin-top: 12px; }
@media (max-width: 700px) {
  .student-stats { grid-template-columns: 1fr; gap: 14px; margin-top: 25px; }
  .student-stat { padding: 22px; }
  .student-settings { padding: 0 22px; }
  .student-setting { align-items: flex-start; flex-direction: column; gap: 16px; padding: 23px 0; }
}
