:root {
  --ink: #19343a;
  --ink-soft: #5d7072;
  --forest: #17383c;
  --forest-2: #21494a;
  --lime: #c9e98a;
  --lime-dark: #9bc45e;
  --paper: #f5f7f2;
  --white: #ffffff;
  --line: #e5eae3;
  --muted: #edf1eb;
  --green: #3c8c66;
  --green-bg: #e8f5ed;
  --red: #bd5e51;
  --red-bg: #fbefec;
  --shadow: 0 18px 54px rgba(25, 52, 58, .07);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  color: var(--ink);
  background: var(--paper);
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }
html { min-width: 320px; background: var(--paper); }
body { margin: 0; min-height: 100vh; background: var(--paper); }
button, input { font: inherit; }
button { cursor: pointer; }
.app-shell { min-height: 100vh; display: grid; grid-template-columns: 286px minmax(0, 1fr); }

.sidebar {
  position: sticky; top: 0; display: flex; flex-direction: column; height: 100vh;
  padding: 28px 21px 20px; overflow: hidden; color: #f4f6ef; background: var(--forest);
}
.brand-row { display: flex; align-items: center; gap: 11px; }
.brand-mark {
  display: grid; place-items: center; width: 37px; height: 37px; border-radius: 12px;
  color: var(--forest); background: var(--lime); font: 800 12px Inter, ui-sans-serif, system-ui, sans-serif; letter-spacing: -.4px;
}
.brand-name { font: 800 18px Inter, ui-sans-serif, system-ui, sans-serif; letter-spacing: -.65px; }
.brand-name span { color: #a2b9ab; }
.sidebar-intro { margin: 50px 0 30px; padding: 0 5px; }
.eyebrow { display: block; color: #829794; font-size: 9px; font-weight: 700; letter-spacing: 1.28px; }
.sidebar .eyebrow { color: #a4b5a7; }
.sidebar-intro h2 { margin: 12px 0 11px; color: #fbfcf6; font: 700 25px/1.23 Inter, ui-sans-serif, system-ui, sans-serif; letter-spacing: -.9px; }
.sidebar-intro p { margin: 0; color: #a2b3ac; font-size: 12px; }
.sidebar-section-heading { display: flex; justify-content: space-between; align-items: center; margin: 0 5px 13px; color: #e1e9de; font-size: 12px; font-weight: 700; }
.sidebar-section-heading span:last-child { color: #91a59d; font-size: 10px; font-weight: 500; }
.ticket-grid { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 7px; max-height: 430px; overflow: auto; padding: 2px 4px 8px; scrollbar-color: #436061 transparent; scrollbar-width: thin; }
.ticket-button {
  position: relative; min-width: 0; height: 34px; border: 1px solid rgba(214, 230, 212, .12); border-radius: 9px;
  color: #c5d2c8; background: rgba(255,255,255,.045); font-size: 11px; font-weight: 600;
  transition: background .15s ease, color .15s ease, transform .15s ease;
}
.ticket-button:hover { color: white; background: rgba(255,255,255,.12); transform: translateY(-1px); }
.ticket-button.active { border-color: var(--lime); color: var(--forest); background: var(--lime); box-shadow: 0 4px 12px rgba(201,233,138,.18); }
.ticket-button.complete:not(.active)::after { position: absolute; top: 4px; right: 4px; width: 5px; height: 5px; border-radius: 50%; background: var(--lime); content: ''; }
.ticket-button.started:not(.active) { border-color: rgba(201,233,138,.38); color: #dce8cf; }
.sidebar-footer { margin-top: auto; padding: 18px 5px 0; border-top: 1px solid rgba(218,233,221,.13); }
.mini-progress-copy { display: flex; justify-content: space-between; margin-bottom: 9px; color: #bdcbc1; font-size: 11px; }
.mini-progress-copy strong { color: var(--lime); font-size: 11px; }
.sidebar-footer p { margin: 13px 0 0; color: #889f97; font-size: 10px; }
.progress-track { height: 5px; border-radius: 99px; overflow: hidden; background: #e9eee8; }
.sidebar .progress-track { background: rgba(255,255,255,.12); }
.progress-track span { display: block; width: 0; height: 100%; border-radius: inherit; background: var(--lime-dark); transition: width .3s ease; }

.page-area { min-width: 0; }
.topbar {
  position: sticky; z-index: 10; top: 0; display: flex; align-items: center; justify-content: space-between; gap: 24px;
  min-height: 94px; padding: 17px clamp(24px, 4vw, 62px); border-bottom: 1px solid var(--line); background: rgba(250,251,247,.94); backdrop-filter: blur(18px);
}
.topbar-title h1 { margin: 6px 0 0; color: var(--ink); font: 700 20px Inter, ui-sans-serif, system-ui, sans-serif; letter-spacing: -.65px; }
.topbar-title h1 span { color: #8da572; }
.topbar .eyebrow { color: #8b9a94; }
.topbar-actions { display: flex; align-items: center; justify-content: flex-end; gap: 16px; }
.search-wrap { position: relative; width: min(285px, 25vw); }
.search-box { display: flex; align-items: center; gap: 8px; min-height: 42px; padding: 0 10px; border: 1px solid #e5eae4; border-radius: 12px; background: white; box-shadow: 0 3px 12px rgba(35,62,57,.025); }
.search-icon { color: #7c918a; font-size: 21px; line-height: 1; transform: rotate(-15deg); }
.search-box input { width: 100%; min-width: 0; border: 0; outline: 0; color: var(--ink); background: transparent; font-size: 12px; }
.search-box input::placeholder { color: #9aa7a0; }
kbd { flex: 0 0 auto; padding: 3px 5px; border: 1px solid #e8ece7; border-radius: 5px; color: #9aa7a0; background: #f8faf7; font-size: 9px; }
.language-button { padding: 9px 11px; border: 1px solid #e2e9df; border-radius: 10px; color: #637870; background: #fff; font-size: 10px; white-space: nowrap; }
.language-button strong { margin-left: 4px; color: var(--forest); font-size: 10px; }
.toolbar-button, .primary-button { display: inline-flex; align-items: center; justify-content: center; gap: 7px; min-height: 38px; padding: 0 12px; border: 1px solid #e2e9df; border-radius: 10px; color: #5d746a; background: #fff; font-size: 10px; font-weight: 650; white-space: nowrap; transition: .15s ease; }
.toolbar-button:hover { border-color: #bfd39f; color: var(--forest); background: #f8fbf4; }
.toolbar-button span { display: inline-grid; place-items: center; min-width: 19px; height: 19px; padding: 0 5px; border-radius: 7px; color: #9d5147; background: #fbefec; font-size: 9px; }
.account-button { max-width: 110px; overflow: hidden; color: var(--forest); text-overflow: ellipsis; }
.primary-button { border-color: var(--forest); color: #fff; background: var(--forest); }
.primary-button:hover { border-color: #28545a; background: #28545a; }
.primary-button:disabled, .toolbar-button:disabled { opacity: .45; cursor: not-allowed; }
.online-indicator { display: flex; align-items: center; gap: 7px; color: #708178; font-size: 10px; white-space: nowrap; }
.online-indicator span { width: 7px; height: 7px; border-radius: 50%; background: #8abc75; box-shadow: 0 0 0 3px rgba(138,188,117,.15); }
.menu-button, .close-sidebar { display: none !important; }

.main-content { max-width: 1440px; margin: 0 auto; padding: 43px clamp(24px, 4vw, 62px) 25px; }
.workspace-grid { display: grid; grid-template-columns: minmax(0, 1fr) 268px; align-items: start; gap: clamp(24px, 3.3vw, 48px); }
.study-column { min-width: 0; }
.ticket-heading { display: flex; align-items: flex-start; justify-content: space-between; gap: 20px; }
.heading-actions { display: flex; align-items: center; gap: 10px; }
.start-test-button { min-height: 40px; }
.heading-line { display: flex; align-items: center; gap: 11px; }
.ticket-pill { padding: 6px 9px; border: 1px solid #dfe8d7; border-radius: 7px; color: #5b7d4b; background: #eef5e8; font-size: 9px; font-weight: 700; letter-spacing: .75px; }
.muted-label { color: #93a09a; font-size: 11px; }
.ticket-heading h2 { margin: 12px 0 0; color: var(--ink); font: 700 26px Inter, ui-sans-serif, system-ui, sans-serif; letter-spacing: -.9px; }
.ticket-score { display: grid; grid-template-columns: auto auto; align-items: baseline; column-gap: 4px; min-width: 76px; padding: 10px 12px 9px; border: 1px solid #e5eae2; border-radius: 12px; background: rgba(255,255,255,.68); }
.ticket-score strong { color: var(--forest); font: 800 20px Inter, ui-sans-serif, system-ui, sans-serif; }
.ticket-score span { color: #9aa6a0; font-size: 10px; }
.ticket-score small { grid-column: 1 / -1; margin-top: 1px; color: #8b9992; font-size: 9px; }
.question-progress { display: flex; align-items: center; gap: 13px; margin: 25px 0 18px; }
.question-progress .progress-track { flex: 1; height: 4px; }
.question-progress .progress-track span { background: #97bd67; }
.question-progress > span { min-width: 65px; color: #83928b; font-size: 10px; text-align: right; }
.question-card { min-height: 436px; padding: clamp(22px, 3.2vw, 38px); border: 1px solid #e7ece5; border-radius: 20px; background: var(--white); box-shadow: var(--shadow); }
.question-meta { display: flex; align-items: center; justify-content: space-between; margin-bottom: 17px; }
.question-number { color: #8b9a91; font-size: 10px; font-weight: 600; letter-spacing: .2px; }
.topic-chip { padding: 5px 8px; border-radius: 6px; color: #758c6c; background: #f1f6ec; font-size: 9px; }
.question-text { max-width: 820px; margin: 0; color: #233e41; font: 700 clamp(18px, 2vw, 24px)/1.42 Inter, ui-sans-serif, system-ui, sans-serif; letter-spacing: -.55px; }
.question-image-wrap { display: flex; justify-content: center; margin: 21px auto 25px; padding: 9px; border: 1px solid #edf0eb; border-radius: 12px; background: #fbfcfa; }
.question-image { display: block; max-width: min(100%, 560px); max-height: 310px; object-fit: contain; }
.answers-heading { margin: 24px 0 10px; color: #87948e; font-size: 9px; font-weight: 700; letter-spacing: 1px; text-transform: uppercase; }
.answers-list { display: grid; grid-template-columns: 1fr; gap: 9px; }
.answer-option {
  display: grid; grid-template-columns: 26px minmax(0,1fr); align-items: center; gap: 12px; width: 100%; min-height: 54px; padding: 10px 13px;
  border: 1px solid #e7ece6; border-radius: 12px; color: #526a68; background: #fff; text-align: left; transition: border .15s ease, background .15s ease, transform .15s ease;
}
.answer-option:hover { border-color: #bbd49b; background: #fbfdf8; transform: translateY(-1px); }
.answer-index { display: grid; place-items: center; width: 25px; height: 25px; border-radius: 8px; color: #7f9187; background: #f1f4ef; font-size: 10px; font-weight: 700; }
.answer-copy { min-width: 0; font-size: 12px; line-height: 1.55; }
.answer-option.is-correct { border-color: #a5d2b2; color: #286645; background: var(--green-bg); }
.answer-option.is-correct .answer-index { color: #fff; background: #4a9a6c; }
.answer-option.is-wrong { border-color: #e5b0a8; color: #9d5148; background: var(--red-bg); }
.answer-option.is-wrong .answer-index { color: #fff; background: #bf6b5f; }
.answer-option.is-selected:not(.is-correct):not(.is-wrong) { border-color: #b6c99f; background: #f7faF2; }
.answer-image { display: block; max-width: 100%; max-height: 168px; margin-top: 8px; object-fit: contain; }
.answer-label { display: block; margin-bottom: 2px; color: #8b9992; font-size: 9px; }
.feedback-box { display: flex; gap: 11px; align-items: flex-start; margin-top: 18px; padding: 14px 15px; border-radius: 12px; }
.feedback-box.correct { color: #356e4a; background: #edf7ef; }
.feedback-box.incorrect { color: #9b554a; background: #fcf0ed; }
.feedback-symbol { flex: 0 0 20px; display: grid; place-items: center; width: 20px; height: 20px; border-radius: 50%; color: white; background: currentColor; font-size: 11px; }
.feedback-box.correct .feedback-symbol { background: #58a073; }
.feedback-box.incorrect .feedback-symbol { background: #c56e61; }
.feedback-copy strong { display: block; margin-bottom: 3px; font-size: 11px; }
.feedback-copy p { margin: 0; color: inherit; font-size: 11px; line-height: 1.65; }
.explanation { margin-top: 9px; padding: 13px 15px; border-left: 2px solid #bed69f; border-radius: 0 9px 9px 0; color: #6e7f77; background: #f7f9f4; font-size: 11px; line-height: 1.7; white-space: pre-line; }
.loading-state { display: grid; place-content: center; justify-items: center; min-height: 360px; color: #8c9c92; font-size: 12px; }
.loader { width: 26px; height: 26px; border: 3px solid #e8eee3; border-top-color: #91b666; border-radius: 50%; animation: spin .8s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.question-navigation { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin: 18px 2px 0; }
.nav-button { display: inline-flex; align-items: center; justify-content: center; gap: 9px; min-width: 104px; height: 42px; padding: 0 14px; border: 1px solid #e2e9e0; border-radius: 11px; color: #5f746a; background: #fff; font-size: 11px; font-weight: 600; transition: .15s ease; }
.nav-button:hover:not(:disabled) { border-color: #bcd59a; color: var(--forest); background: #f8fbf3; }
.nav-button.next { border-color: var(--forest); color: #fff; background: var(--forest); }
.nav-button.next:hover:not(:disabled) { border-color: #28545a; background: #28545a; }
.nav-button:disabled { opacity: .42; cursor: not-allowed; }
.nav-dots { display: flex; justify-content: center; gap: 5px; }
.question-dot { width: 6px; height: 6px; padding: 0; border: 0; border-radius: 50%; background: #d8dfd7; }
.question-dot.answered { background: #a5c17c; }
.question-dot.active { width: 17px; border-radius: 9px; background: #597c58; }

.question-dot.selected { box-shadow: 0 0 0 2px #708d58; }
.finish-test-button { border-color: var(--forest); color: white; background: var(--forest); }
.finish-test-button:hover { color: white !important; background: #28545a !important; }
.abandon-test-button { color: #a15f55; }
.test-status { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin: 0 0 14px; padding: 11px 14px; border: 1px solid #e0e9d2; border-radius: 11px; color: #5d7457; background: #f2f7e9; font-size: 11px; }
.test-status strong { color: #365341; }
.question-navigation.testing .nav-dots { max-width: 230px; overflow: auto; padding: 5px; }
.question-navigation.testing .nav-button { min-width: 78px; }
.result-summary { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; margin-bottom: 23px; padding: 17px; border-radius: 13px; background: #f2f7e9; }
.result-summary strong { color: var(--forest); font: 800 26px Inter, ui-sans-serif, system-ui, sans-serif; }
.result-summary span { color: #667b70; font-size: 11px; }
.result-list { display: grid; gap: 12px; margin: 0; padding: 0; list-style: none; }
.result-item { padding: 15px; border: 1px solid #e7ece5; border-radius: 12px; background: #fff; }
.result-item h3 { margin: 0 0 10px; color: #355250; font-size: 13px; line-height: 1.5; }
.result-item p { margin: 6px 0; color: #718179; font-size: 11px; line-height: 1.55; }
.result-item .result-answer { color: #a0554b; }
.result-item .result-correct { color: #35734f; }
.result-item button { margin-top: 7px; padding: 7px 9px; border: 1px solid #e2e9df; border-radius: 8px; color: #587367; background: #fff; font-size: 10px; }
.result-actions { display: flex; flex-wrap: wrap; gap: 9px; margin-bottom: 16px; }
.history-list { display: grid; gap: 8px; max-height: min(60vh, 540px); overflow: auto; margin-top: 18px; }
.history-entry { display: flex; align-items: center; justify-content: space-between; gap: 12px; width: 100%; padding: 12px; border: 1px solid #e5ebe2; border-radius: 10px; color: #516a60; background: #fff; text-align: left; }
.history-entry:hover { border-color: #bed39d; background: #f9fbf5; }
.history-entry span { display: grid; gap: 4px; }
.history-entry small { color: #87968d; font-size: 9px; }
.history-entry strong { color: var(--forest); font-size: 12px; white-space: nowrap; }
.dialog-backdrop, .auth-screen { position: fixed; z-index: 80; inset: 0; display: grid; place-items: center; padding: 20px; background: rgba(15, 36, 37, .48); backdrop-filter: blur(8px); }
.dialog-card { position: relative; width: min(640px, 100%); max-height: min(86vh, 800px); overflow: auto; padding: 28px; border: 1px solid #e7ece5; border-radius: 19px; background: #fff; box-shadow: 0 24px 70px rgba(20, 43, 44, .2); }
.dialog-card h2 { margin: 0 38px 7px 0; color: var(--ink); font: 750 21px Inter, ui-sans-serif, system-ui, sans-serif; letter-spacing: -.5px; }
.dialog-card > div > p { margin: 0 0 14px; color: #77867e; font-size: 11px; line-height: 1.6; }
.dialog-close { position: absolute; top: 15px; right: 15px; display: grid; place-items: center; width: 32px; height: 32px; border: 1px solid #e6ece5; border-radius: 9px; color: #667a71; background: #fff; font-size: 20px; }
.dialog-actions { display: flex; flex-wrap: wrap; gap: 9px; margin-top: 18px; }
.dialog-user { color: #365b50 !important; font-weight: 700; }
.auth-screen { z-index: 100; background: rgba(17, 42, 44, .72); }
.auth-card { width: min(430px, 100%); padding: 34px; border: 1px solid #e7ece5; border-radius: 21px; background: #fbfcf8; box-shadow: 0 24px 70px rgba(8, 28, 29, .25); }
.auth-card .brand-mark { margin-bottom: 22px; }
.auth-card h1 { margin: 9px 0 8px; color: var(--ink); font: 750 25px Inter, ui-sans-serif, system-ui, sans-serif; letter-spacing: -.75px; }
.auth-description { margin: 0 0 22px; color: #78877e; font-size: 12px; line-height: 1.65; }
.auth-field { display: grid; gap: 7px; margin: 13px 0; color: #60736a; font-size: 10px; font-weight: 700; }
.auth-field input { width: 100%; min-height: 43px; padding: 0 12px; border: 1px solid #dfe7df; border-radius: 10px; outline: none; color: var(--ink); background: #fff; font-size: 12px; }
.auth-field input:focus { border-color: #a8c487; box-shadow: 0 0 0 3px rgba(169, 201, 135, .16); }
.auth-message { min-height: 18px; margin: 7px 0 8px; color: #ab5c50; font-size: 10px; line-height: 1.5; }
.auth-submit { width: 100%; min-height: 44px; }
.auth-toggle { display: block; margin: 15px auto 0; color: #688057; font-size: 10px; }
.auth-footnote { display: block; margin-top: 22px; color: #98a39b; font-size: 9px; line-height: 1.6; text-align: center; }
.auth-card .eyebrow { color: #87988e; }
.dialog-empty { padding: 24px 15px; border: 1px dashed #dce6da; border-radius: 11px; color: #84938a; font-size: 11px; text-align: center; }
.insight-column { display: grid; gap: 14px; padding-top: 18px; }
.stats-card, .note-card, .source-card { border: 1px solid #e6ece4; border-radius: 16px; background: rgba(255,255,255,.8); }
.stats-card { padding: 21px 20px 18px; }
.card-overline { display: flex; align-items: center; gap: 7px; color: #7f9086; font-size: 9px; font-weight: 700; letter-spacing: 1px; }
.spark-icon { color: #94b86c; font-size: 15px; }
.stats-hero { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin: 23px 0 17px; }
.stats-caption { display: block; margin-bottom: 5px; color: #829189; font-size: 10px; }
.stats-hero > div:first-child strong { color: var(--ink); font: 800 27px Inter, ui-sans-serif, system-ui, sans-serif; letter-spacing: -1px; }
.stats-total { margin-left: 5px; color: #9ca8a0; font-size: 9px; }
.donut { display: grid; place-items: center; width: 72px; height: 72px; border-radius: 50%; background: conic-gradient(#a9cb7c 0deg, #a9cb7c 0deg, #e9eee5 0deg); }
.donut > div { display: grid; place-content: center; width: 58px; height: 58px; border-radius: 50%; background: #fff; text-align: center; }
.donut strong { color: #55734d; font: 700 14px Inter, ui-sans-serif, system-ui, sans-serif; }
.donut span { margin-top: 1px; color: #9ba69f; font-size: 8px; }
.stats-divider { height: 1px; margin: 0 0 12px; background: #edf0eb; }
.stats-row { display: flex; justify-content: space-between; align-items: center; margin-top: 12px; color: #718179; font-size: 10px; }
.stats-row strong { color: #435e59; font-size: 11px; }
.legend-dot { display: inline-block; width: 7px; height: 7px; margin-right: 7px; border-radius: 50%; vertical-align: 1px; }
.legend-dot.green { background: #79b188; }
.legend-dot.coral { background: #d68b7e; }
.legend-dot.slate { background: #b9c4bc; }
.note-card { display: flex; gap: 12px; padding: 17px 16px; background: #f0f5e8; }
.note-icon { flex: 0 0 23px; display: grid; place-items: center; width: 23px; height: 23px; border-radius: 8px; color: #658351; background: #dcebc8; font: 700 12px Inter, ui-sans-serif, system-ui, sans-serif; }
.note-card h3 { margin: 1px 0 6px; color: #3e5b4e; font: 700 11px Inter, ui-sans-serif, system-ui, sans-serif; }
.note-card p { margin: 0; color: #71847a; font-size: 10px; line-height: 1.6; }
.source-card { padding: 17px 17px 15px; }
.source-label { display: block; margin-bottom: 7px; color: #9aa79f; font-size: 8px; font-weight: 700; letter-spacing: 1px; }
.source-card > strong { color: #496a53; font: 700 14px Inter, ui-sans-serif, system-ui, sans-serif; }
.source-card p { margin: 8px 0 13px; color: #8a9890; font-size: 9px; line-height: 1.55; }
.text-button { padding: 0; border: 0; color: #8b766d; background: transparent; font-size: 9px; text-decoration: underline; text-underline-offset: 3px; }
.text-button:hover { color: #9e5147; }
.page-footer { display: flex; justify-content: space-between; gap: 12px; margin-top: 34px; padding: 15px 2px 0; border-top: 1px solid #e5eae2; color: #9aa69f; font-size: 9px; }
.page-footer span:first-child { color: #809078; font-weight: 700; }

.search-results { position: absolute; z-index: 20; top: calc(100% + 8px); right: 0; left: 0; max-height: min(420px, 70vh); overflow: auto; padding: 6px; border: 1px solid #e5eae4; border-radius: 13px; background: #fff; box-shadow: 0 16px 40px rgba(24,48,45,.14); }
.search-result { display: block; width: 100%; padding: 10px; border: 0; border-radius: 9px; color: #405a55; background: #fff; text-align: left; }
.search-result:hover { background: #f3f7ed; }
.search-result small { display: block; margin-bottom: 4px; color: #8da078; font-size: 9px; font-weight: 700; }
.search-result span { display: -webkit-box; overflow: hidden; color: #596e68; font-size: 10px; line-height: 1.45; -webkit-box-orient: vertical; -webkit-line-clamp: 2; }
.search-empty { padding: 14px 10px; color: #819088; font-size: 10px; }
.toast { position: fixed; z-index: 50; right: 24px; bottom: 24px; max-width: min(360px, calc(100vw - 32px)); padding: 12px 16px; border-radius: 11px; color: #fff; background: #244a4d; box-shadow: 0 10px 30px rgba(22,55,58,.22); font-size: 11px; opacity: 0; pointer-events: none; transform: translateY(8px); transition: .2s ease; }
.toast.show { opacity: 1; transform: translateY(0); }
.sidebar-backdrop { display: none; }

@media (max-width: 1120px) {
  .app-shell { grid-template-columns: 250px minmax(0, 1fr); }
  .sidebar { padding-right: 16px; padding-left: 16px; }
  .workspace-grid { grid-template-columns: minmax(0, 1fr) 230px; gap: 22px; }
  .topbar { padding-right: 28px; padding-left: 28px; }
  .main-content { padding-right: 28px; padding-left: 28px; }
  .online-indicator { display: none; }
  .ticket-grid { grid-template-columns: repeat(5, minmax(0,1fr)); }
}
@media (max-width: 860px) {
  .app-shell { display: block; }
  .sidebar { position: fixed; z-index: 35; top: 0; bottom: 0; left: 0; width: min(300px, 86vw); height: 100dvh; transform: translateX(-102%); transition: transform .24s ease; box-shadow: 22px 0 50px rgba(13,37,37,.18); }
  .sidebar.open { transform: translateX(0); }
  .close-sidebar { display: grid !important; place-items: center; margin-left: auto; width: 34px; height: 34px; border: 1px solid rgba(255,255,255,.14); border-radius: 10px; color: #d9e5dc; background: transparent; font-size: 21px; }
  .menu-button { display: grid !important; place-items: center; flex: 0 0 auto; width: 38px; height: 38px; border: 1px solid #e1e9df; border-radius: 10px; color: #547066; background: #fff; font-size: 15px; }
  .sidebar-backdrop.show { position: fixed; z-index: 30; inset: 0; display: block; background: rgba(15,36,37,.34); }
  .topbar { justify-content: flex-start; gap: 13px; min-height: 78px; padding: 12px 20px; }
  .topbar-title { min-width: 0; flex: 1; }
  .topbar-title h1 { font-size: 17px; }
  .topbar-actions { gap: 8px; }
  .search-wrap { width: 42px; transition: width .2s ease; }
  .search-wrap.expanded { width: min(250px, 38vw); }
  .search-box { min-height: 38px; justify-content: center; padding: 0 9px; }
  .search-box input { display: none; }
  .search-wrap.expanded .search-box { justify-content: flex-start; }
  .search-wrap.expanded .search-box input { display: block; }
  .search-box kbd { display: none; }
  .language-button { padding: 8px; font-size: 0; }
  .language-button strong { margin-left: 0; font-size: 10px; }
  .history-button { display: none; }
  .toolbar-button { min-height: 35px; padding: 0 8px; font-size: 9px; }
  .account-button { max-width: 78px; }
  .main-content { padding: 29px 20px 22px; }
  .workspace-grid { grid-template-columns: minmax(0,1fr); }
  .insight-column { grid-template-columns: repeat(2,minmax(0,1fr)); padding-top: 0; }
  .stats-card { grid-row: span 2; }
  .source-card { grid-column: 2; }
  .ticket-grid { max-height: none; }
}
@media (max-width: 560px) {
  .topbar { gap: 9px; padding: 10px 13px; }
  .topbar-title .eyebrow { font-size: 7px; letter-spacing: .85px; }
  .topbar-title h1 { margin-top: 4px; font-size: 15px; }
  .topbar-actions { gap: 6px; }
  .search-wrap { width: 35px; }
  .search-box { min-height: 35px; padding: 0 6px; }
  .search-icon { font-size: 19px; }
  .main-content { padding: 23px 13px 20px; }
  .ticket-heading h2 { font-size: 21px; }
  .ticket-heading { gap: 10px; }
  .heading-actions { flex-direction: column-reverse; align-items: flex-end; gap: 7px; }
  .start-test-button { min-height: 34px; padding: 0 9px; font-size: 9px; }
  .ticket-score { min-width: 65px; padding: 8px 9px; }
  .question-card { min-height: 390px; padding: 19px 16px; border-radius: 16px; }
  .question-text { font-size: 18px; }
  .question-navigation { gap: 6px; }
  .question-navigation.testing { flex-wrap: wrap; justify-content: center; }
  .question-navigation.testing .nav-dots { order: 3; flex-basis: 100%; justify-content: center; }
  .question-navigation.testing .finish-test-button { order: 4; }
  .question-navigation.testing .abandon-test-button { order: 5; }
  .nav-button { min-width: 42px; height: 40px; padding: 0 10px; }
  .nav-button.previous span:last-child { display: none; }
  .nav-button.next span:first-child { display: none; }
  .nav-dots { gap: 4px; }
  .question-dot { width: 5px; height: 5px; }
  .question-dot.active { width: 12px; }
  .insight-column { grid-template-columns: 1fr; }
  .stats-card, .source-card { grid-column: auto; grid-row: auto; }
  .stats-hero { justify-content: flex-start; gap: 42px; }
  .page-footer { font-size: 8px; }
  .page-footer span:last-child { text-align: right; }
  .auth-card { padding: 26px 22px; }
  .dialog-card { padding: 23px 17px; }
}
