:root {
  --bg: #06101f;
  --bg-2: #081a2d;
  --panel: rgba(16, 35, 58, 0.84);
  --panel-2: rgba(18, 44, 70, 0.72);
  --line: rgba(171, 197, 233, 0.18);
  --line-strong: rgba(127, 170, 239, 0.36);
  --text: #f8fbff;
  --muted: #b8c4d8;
  --soft: #7f8da6;
  --blue: #3478ff;
  --blue-2: #62a0ff;
  --green: #69d184;
  --red: #ff6b73;
  --amber: #ffc75f;
  --cyan: #70d7ff;
  --violet: #a99cff;
  --shadow: 0 20px 60px rgba(0, 0, 0, 0.26);
  --radius: 8px;
  --nav-mobile: 86px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  background:
    linear-gradient(135deg, rgba(10, 35, 56, 0.7), transparent 38%),
    linear-gradient(180deg, var(--bg), #07192c 52%, #06101f);
  color: var(--text);
  font-family:
    Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

button,
input {
  font: inherit;
}

button {
  cursor: pointer;
}

a {
  color: inherit;
}

.app-shell {
  min-height: 100vh;
  display: grid;
  grid-template-columns: 100px minmax(0, 1fr);
}

.main-frame {
  min-width: 0;
}

.side-nav {
  position: sticky;
  top: 0;
  height: 100vh;
  padding: 20px 14px;
  border-right: 1px solid var(--line);
  background: rgba(5, 15, 29, 0.78);
  backdrop-filter: blur(16px);
  display: flex;
  flex-direction: column;
  gap: 10px;
  z-index: 5;
}

.brand-mark {
  width: 54px;
  height: 54px;
  margin: 0 auto 18px;
  border: 1px solid rgba(52, 120, 255, 0.55);
  background: linear-gradient(135deg, rgba(52, 120, 255, 0.98), rgba(24, 91, 216, 0.98));
  color: #fff;
  border-radius: 8px;
  font-weight: 900;
  font-size: 18px;
  box-shadow: var(--shadow);
}

.nav-item {
  min-height: 68px;
  border: 1px solid transparent;
  background: transparent;
  color: var(--muted);
  border-radius: 8px;
  display: grid;
  place-items: center;
  gap: 4px;
  padding: 8px 6px;
}

.nav-item svg {
  width: 24px;
  height: 24px;
}

.nav-item span {
  font-size: 13px;
  line-height: 1.15;
}

.nav-item.active {
  color: var(--blue-2);
  background: rgba(52, 120, 255, 0.14);
  border-color: rgba(52, 120, 255, 0.3);
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 4;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding: 26px clamp(18px, 5vw, 56px) 18px;
  background: rgba(6, 16, 31, 0.82);
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(18px);
}

.topbar h1 {
  margin: 0;
  font-size: 30px;
  line-height: 1.05;
  letter-spacing: 0;
}

.eyebrow {
  margin: 0 0 5px;
  color: var(--blue-2);
  font-weight: 800;
}

.icon-button {
  position: relative;
  width: 44px;
  height: 44px;
  border: 0;
  background: transparent;
  color: var(--text);
  border-radius: 8px;
  display: grid;
  place-items: center;
}

.icon-button:hover {
  background: rgba(255, 255, 255, 0.08);
}

.dot {
  position: absolute;
  top: 9px;
  right: 10px;
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: var(--amber);
}

.content {
  width: min(1180px, calc(100vw - 140px));
  margin: 0 auto;
  padding: 26px 0 80px;
}

.view-header {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 18px;
  align-items: end;
  margin-bottom: 22px;
}

.view-title {
  margin: 0;
  font-size: 34px;
  line-height: 1.1;
  letter-spacing: 0;
}

.view-subtitle {
  margin: 8px 0 0;
  color: var(--muted);
  font-size: 18px;
  line-height: 1.5;
  max-width: 760px;
}

.section-title {
  margin: 34px 0 16px;
  font-size: 22px;
  letter-spacing: 0;
}

.dashboard-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(300px, 0.85fr);
  gap: 18px;
  align-items: start;
}

.panel {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--panel);
  box-shadow: var(--shadow);
}

.progress-panel {
  padding: 24px;
}

.progress-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 16px;
}

.progress-top h2,
.panel h2,
.panel h3 {
  margin: 0;
}

.progress-value {
  display: grid;
  place-items: center;
  flex: 0 0 82px;
  width: 82px;
  height: 82px;
  min-width: 82px;
  aspect-ratio: 1;
  border: 1px solid rgba(52, 120, 255, 0.25);
  border-radius: 50%;
  color: var(--text);
  font-size: 28px;
  font-weight: 900;
}

.progress-bar {
  height: 14px;
  background: rgba(130, 154, 190, 0.2);
  border-radius: 999px;
  overflow: hidden;
}

.progress-fill {
  height: 100%;
  width: 0%;
  background: linear-gradient(90deg, #2e6cff, #67a6ff);
  border-radius: inherit;
  transition: width 180ms ease;
}

.progress-caption {
  color: var(--muted);
  margin: 12px 0 0;
}

.quick-card {
  display: grid;
  grid-template-columns: 58px minmax(0, 1fr) auto;
  gap: 14px;
  align-items: center;
  padding: 18px;
  min-height: 104px;
}

.quick-card + .quick-card {
  margin-top: 12px;
}

.quick-icon,
.topic-icon,
.lesson-icon,
.step-badge,
.answer-letter {
  display: grid;
  place-items: center;
  flex: 0 0 auto;
}

.quick-icon {
  width: 58px;
  height: 58px;
  border-radius: 8px;
  color: var(--blue-2);
  background: rgba(52, 120, 255, 0.13);
}

.quick-card h3 {
  margin: 0 0 5px;
}

.quick-card p,
.topic-card p,
.note p,
.faq-item p {
  margin: 0;
  color: var(--muted);
  line-height: 1.55;
}

.primary-button,
.ghost-button,
.answer-button,
.chip,
.small-action {
  border-radius: 8px;
  min-height: 44px;
  border: 1px solid rgba(52, 120, 255, 0.5);
  transition:
    background 140ms ease,
    border-color 140ms ease,
    transform 140ms ease;
}

.primary-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 0 18px;
  color: white;
  background: linear-gradient(135deg, #2f83ff, #1e61f0);
  border-color: rgba(112, 170, 255, 0.55);
  font-weight: 800;
}

.ghost-button,
.small-action {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 0 14px;
  color: var(--blue-2);
  background: rgba(52, 120, 255, 0.08);
  font-weight: 750;
}

.primary-button:hover,
.ghost-button:hover,
.small-action:hover,
.answer-button:hover,
.chip:hover {
  transform: translateY(-1px);
}

.topic-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(210px, 1fr));
  gap: 14px;
}

.topic-card {
  position: relative;
  border: 1px solid var(--line);
  background: var(--panel-2);
  border-radius: var(--radius);
  padding: 18px;
  min-height: 170px;
  color: inherit;
  text-align: left;
  display: grid;
  align-content: start;
  gap: 13px;
}

.topic-card:hover {
  border-color: var(--line-strong);
}

.topic-card.done {
  border-color: rgba(105, 209, 132, 0.45);
}

.topic-card .topic-icon {
  width: 48px;
  height: 48px;
  border-radius: 8px;
  color: var(--topic-color, var(--blue-2));
  background: color-mix(in srgb, var(--topic-color, #3478ff) 18%, transparent);
}

.topic-card h3 {
  margin: 0;
  font-size: 19px;
}

.topic-status {
  position: absolute;
  top: 12px;
  right: 12px;
  color: var(--green);
}

.recommended-list {
  display: grid;
  gap: 0;
  overflow: hidden;
}

.recommended-row {
  display: grid;
  grid-template-columns: 38px minmax(0, 1fr) auto;
  align-items: center;
  gap: 14px;
  min-height: 58px;
  padding: 10px 14px;
  border-bottom: 1px solid var(--line);
}

.recommended-row:last-child {
  border-bottom: 0;
}

.order-number {
  display: grid;
  place-items: center;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: linear-gradient(135deg, #3478ff, #245ee8);
  font-weight: 900;
}

.search-wrap {
  display: flex;
  gap: 10px;
  align-items: center;
}

.search-wrap input,
.field input,
.answer-input {
  width: 100%;
  min-height: 52px;
  border: 1px solid rgba(184, 196, 216, 0.28);
  border-radius: 8px;
  background: rgba(5, 18, 34, 0.55);
  color: var(--text);
  padding: 0 14px;
  outline: none;
}

.search-wrap input:focus,
.field input:focus,
.answer-input:focus {
  border-color: rgba(98, 160, 255, 0.72);
  box-shadow: 0 0 0 3px rgba(52, 120, 255, 0.16);
}

.chips {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.chip {
  padding: 0 14px;
  color: var(--text);
  background: rgba(255, 255, 255, 0.06);
}

.chip.active {
  color: #fff;
  background: linear-gradient(135deg, #2f83ff, #1f64ea);
}

.lesson-hero {
  display: grid;
  grid-template-columns: 72px minmax(0, 1fr);
  gap: 18px;
  align-items: center;
  margin-bottom: 24px;
}

.lesson-icon {
  width: 72px;
  height: 72px;
  border: 1px solid rgba(52, 120, 255, 0.28);
  border-radius: 8px;
  color: var(--topic-color, var(--blue-2));
  background: color-mix(in srgb, var(--topic-color, #3478ff) 18%, transparent);
}

.lesson-content {
  display: grid;
  gap: 16px;
}

.lesson-card {
  padding: 22px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: rgba(10, 27, 48, 0.66);
}

.lesson-card p,
.mini-card p,
.symbol-card p {
  margin: 0 0 13px;
  color: var(--muted);
  line-height: 1.62;
}

.lesson-card p:last-child,
.mini-card p:last-child,
.symbol-card p:last-child {
  margin-bottom: 0;
}

.lesson-card h2 {
  margin: 0 0 14px;
  color: var(--blue-2);
  font-size: 24px;
}

.lesson-card h3 {
  margin: 22px 0 10px;
  font-size: 19px;
}

.lesson-card ul,
.lesson-card ol {
  margin: 12px 0 16px;
  padding-left: 22px;
}

.lesson-card li {
  margin: 9px 0;
  color: var(--muted);
  line-height: 1.55;
}

.formula {
  display: inline-flex;
  max-width: 100%;
  margin: 0 0.12em;
  padding: 2px 7px;
  border: 1px solid rgba(98, 160, 255, 0.28);
  border-radius: 8px;
  background: rgba(52, 120, 255, 0.12);
  color: var(--text);
  font-family: "Segoe UI", ui-sans-serif, system-ui, sans-serif;
  font-size: 1em;
  font-weight: 800;
  line-height: 1.4;
  overflow-x: auto;
  white-space: nowrap;
  vertical-align: baseline;
}

p.formula {
  display: flex;
  width: fit-content;
  margin: 10px 0 16px;
  padding: 10px 12px;
  font-size: 18px;
  line-height: 1.4;
}

.blue {
  color: var(--blue-2);
  font-weight: 900;
}

.green {
  color: var(--green);
  font-weight: 900;
}

.red {
  color: var(--red);
  font-weight: 900;
}

.amber {
  color: var(--amber);
  font-weight: 900;
}

.step-list {
  display: grid;
  gap: 14px;
  margin: 14px 0 2px;
}

.step {
  display: grid;
  grid-template-columns: 42px minmax(0, 1fr);
  gap: 12px;
  align-items: start;
}

.step p,
.note p {
  margin: 0;
  color: var(--muted);
  line-height: 1.62;
}

.step-badge {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: linear-gradient(135deg, #367eff, #2464e8);
  color: white;
  font-weight: 900;
}

.note {
  display: grid;
  grid-template-columns: 52px minmax(0, 1fr);
  gap: 14px;
  align-items: center;
  margin: 16px 0 2px;
  padding: 16px;
  border: 1px solid rgba(255, 199, 95, 0.34);
  border-radius: var(--radius);
  background: rgba(255, 199, 95, 0.08);
}

.note svg {
  color: var(--amber);
}

.two-col {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
}

.three-col {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
}

.mini-card {
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.04);
}

.mini-card h3 {
  margin: 0 0 10px;
}

.symbol-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
  gap: 12px;
}

.symbol-card {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 16px;
  background: rgba(255, 255, 255, 0.04);
}

.symbol-mark {
  display: inline-grid;
  place-items: center;
  min-width: 52px;
  height: 52px;
  margin-bottom: 12px;
  padding: 0 10px;
  border-radius: 8px;
  color: var(--blue-2);
  background: rgba(52, 120, 255, 0.12);
  font-size: 26px;
  font-weight: 900;
}

.tool-layout {
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(320px, 1.1fr);
  gap: 18px;
  align-items: start;
}

.field-grid {
  display: grid;
  gap: 14px;
}

.field {
  display: grid;
  gap: 8px;
}

.field label {
  font-weight: 800;
}

.field-row {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

.result-box {
  min-height: 120px;
}

.answer-list {
  display: grid;
  gap: 12px;
}

.answer-button {
  display: grid;
  grid-template-columns: 54px minmax(0, 1fr);
  align-items: center;
  gap: 14px;
  width: 100%;
  min-height: 76px;
  padding: 12px 16px;
  color: var(--text);
  text-align: left;
  background: rgba(10, 27, 48, 0.68);
  border-color: var(--line);
}

.answer-button.selected {
  border-color: var(--blue-2);
  background: rgba(52, 120, 255, 0.14);
}

.answer-button.correct {
  border-color: rgba(105, 209, 132, 0.75);
}

.answer-button.wrong {
  border-color: rgba(255, 107, 115, 0.75);
}

.answer-letter {
  width: 42px;
  height: 42px;
  border: 1px solid var(--line-strong);
  border-radius: 50%;
  font-weight: 900;
}

.answer-button.selected .answer-letter {
  background: linear-gradient(135deg, #367eff, #2464e8);
  border-color: transparent;
}

.feedback {
  padding: 18px;
  border-radius: var(--radius);
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.04);
}

.feedback.correct {
  border-color: rgba(105, 209, 132, 0.55);
}

.feedback.wrong {
  border-color: rgba(255, 107, 115, 0.55);
}

.quiz-controls {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  margin-top: 18px;
}

.tables-grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 10px;
}

.tables-grid button {
  min-height: 58px;
  border-radius: 8px;
  border: 1px solid var(--line);
  color: var(--text);
  background: rgba(255, 255, 255, 0.06);
  font-weight: 900;
}

.tables-grid button.active {
  background: linear-gradient(135deg, #2f83ff, #1f64ea);
  border-color: transparent;
}

.operation-tabs {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}

.operation-tabs button {
  min-height: 58px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.06);
  color: var(--text);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-weight: 900;
}

.operation-tabs button.active {
  background: linear-gradient(135deg, #2f83ff, #1f64ea);
  border-color: transparent;
}

.operation-tabs svg {
  width: 20px;
  height: 20px;
}

.table-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.table-line {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.04);
  font-weight: 750;
}

.practice-question {
  text-align: center;
  font-size: 40px;
  font-weight: 900;
  margin: 8px 0 18px;
}

.stats-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}

.stat {
  padding: 16px;
  text-align: center;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.04);
}

.stat strong {
  display: block;
  font-size: 26px;
}

.chart-wrap {
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.04);
}

.bar-chart {
  display: grid;
  grid-template-columns: 44px repeat(3, minmax(62px, 1fr));
  grid-template-rows: 28px 220px 34px;
  gap: 0 16px;
  align-items: end;
}

.axis-label {
  grid-column: 1 / 2;
  grid-row: 1 / 3;
  align-self: start;
  color: var(--muted);
  font-size: 14px;
}

.y-axis {
  grid-column: 1 / 2;
  grid-row: 2 / 3;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  color: var(--muted);
}

.bar-slot {
  grid-row: 2 / 3;
  height: 220px;
  display: flex;
  align-items: end;
  justify-content: center;
  border-bottom: 1px solid rgba(98, 160, 255, 0.55);
  background:
    linear-gradient(to top, transparent 0, transparent 24%, rgba(98, 160, 255, 0.12) 25%, transparent 26%),
    linear-gradient(to top, transparent 0, transparent 49%, rgba(98, 160, 255, 0.12) 50%, transparent 51%),
    linear-gradient(to top, transparent 0, transparent 74%, rgba(98, 160, 255, 0.12) 75%, transparent 76%);
}

.bar {
  width: min(76px, 70%);
  min-height: 4px;
  border-radius: 8px 8px 0 0;
  background: linear-gradient(180deg, #2f83ff, #1f64ea);
  position: relative;
}

.bar span {
  position: absolute;
  top: -30px;
  left: 50%;
  transform: translateX(-50%);
  font-weight: 900;
}

.x-label {
  grid-row: 3 / 4;
  justify-self: center;
  align-self: center;
  font-weight: 800;
}

.geometry-visual,
.circle-visual,
.lines-visual,
.rectangle-visual {
  min-height: 210px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.04);
  display: grid;
  place-items: center;
  overflow: hidden;
}

.rectangle-visual .rect {
  width: 68%;
  height: 44%;
  border: 5px solid var(--blue-2);
  position: relative;
}

.rectangle-visual .rect::before,
.rectangle-visual .rect::after {
  position: absolute;
  color: var(--blue-2);
  font-weight: 900;
  font-size: 24px;
}

.rectangle-visual .rect::before {
  content: "b";
  left: 50%;
  bottom: -42px;
  transform: translateX(-50%);
}

.rectangle-visual .rect::after {
  content: "h";
  right: -38px;
  top: 50%;
  transform: translateY(-50%);
}

.circle-visual .circle {
  width: 160px;
  height: 160px;
  border: 5px solid var(--cyan);
  border-radius: 50%;
  position: relative;
}

.circle-visual .circle::before,
.circle-visual .circle::after {
  content: "";
  position: absolute;
  background: var(--amber);
  left: 50%;
  top: 50%;
  transform-origin: left center;
}

.circle-visual .circle::before {
  width: 72px;
  height: 4px;
}

.circle-visual .circle::after {
  width: 150px;
  height: 2px;
  transform: translateX(-50%) rotate(-25deg);
  background: rgba(255, 199, 95, 0.76);
}

.lines-visual {
  position: relative;
}

.lines-visual span {
  position: absolute;
  width: 72%;
  height: 3px;
  background: var(--blue-2);
  transform-origin: center;
}

.lines-visual span:nth-child(1) {
  transform: rotate(0deg);
}

.lines-visual span:nth-child(2) {
  transform: rotate(45deg);
}

.lines-visual span:nth-child(3) {
  transform: rotate(90deg);
}

.lines-visual span:nth-child(4) {
  transform: rotate(135deg);
}

.geometry-visual {
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
  padding: 24px;
}

.shape {
  width: 74px;
  height: 74px;
  display: grid;
  place-items: center;
}

.shape.square {
  border: 4px solid var(--blue-2);
}

.shape.circle-shape {
  border: 4px solid var(--cyan);
  border-radius: 50%;
}

.shape.triangle {
  width: 0;
  height: 0;
  border-left: 42px solid transparent;
  border-right: 42px solid transparent;
  border-bottom: 76px solid rgba(255, 199, 95, 0.9);
}

.faq-list {
  display: grid;
  gap: 10px;
}

.faq-item {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.04);
  overflow: hidden;
}

.faq-item summary {
  list-style: none;
  padding: 16px;
  font-weight: 850;
  cursor: pointer;
}

.faq-item summary::-webkit-details-marker {
  display: none;
}

.faq-item p {
  padding: 0 16px 16px;
}

.toast {
  position: fixed;
  left: 50%;
  bottom: 112px;
  transform: translateX(-50%) translateY(20px);
  max-width: min(520px, calc(100vw - 32px));
  padding: 12px 16px;
  color: var(--text);
  background: rgba(7, 22, 39, 0.96);
  border: 1px solid var(--line-strong);
  border-radius: 8px;
  opacity: 0;
  pointer-events: none;
  transition:
    opacity 150ms ease,
    transform 150ms ease;
  z-index: 20;
}

.toast.show {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}

.bottom-nav {
  display: none;
}

.hidden {
  display: none !important;
}

@media (max-width: 940px) {
  .app-shell {
    display: block;
  }

  .side-nav {
    display: none;
  }

  .topbar {
    padding: 18px 16px 14px;
  }

  .topbar h1 {
    font-size: 24px;
  }

  .content {
    width: min(100% - 28px, 760px);
    padding-bottom: calc(var(--nav-mobile) + 26px);
  }

  .bottom-nav {
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    height: var(--nav-mobile);
    padding: 9px 10px calc(9px + env(safe-area-inset-bottom));
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 4px;
    border-top: 1px solid var(--line);
    background: rgba(7, 22, 39, 0.94);
    backdrop-filter: blur(18px);
    z-index: 10;
  }

  .bottom-nav .nav-item {
    min-height: 58px;
    padding: 6px 2px;
  }

  .bottom-nav .nav-item span {
    font-size: 12px;
  }

  .dashboard-grid,
  .tool-layout,
  .two-col,
  .three-col {
    grid-template-columns: 1fr;
  }

  .view-header {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 620px) {
  .view-title {
    font-size: 29px;
  }

  .view-subtitle {
    font-size: 16px;
  }

  .topic-grid {
    grid-template-columns: 1fr;
  }

  .recommended-row {
    grid-template-columns: 42px minmax(0, 1fr);
  }

  .quick-card {
    grid-template-columns: 58px minmax(0, 1fr);
  }

  .quick-card .primary-button,
  .recommended-row .ghost-button {
    grid-column: 2;
    width: 100%;
  }

  .lesson-hero {
    grid-template-columns: 54px minmax(0, 1fr);
  }

  .lesson-icon {
    width: 54px;
    height: 54px;
  }

  .lesson-card {
    padding: 18px;
  }

  .field-row,
  .stats-grid,
  .table-list {
    grid-template-columns: 1fr;
  }

  .tables-grid {
    grid-template-columns: repeat(3, 1fr);
  }

  .operation-tabs {
    grid-template-columns: 1fr;
  }

  .quiz-controls {
    flex-direction: column;
  }

  .quiz-controls button {
    width: 100%;
  }

  .bar-chart {
    grid-template-columns: 36px repeat(3, minmax(48px, 1fr));
    grid-template-rows: 26px 190px 34px;
    gap: 0 8px;
  }

  .bar-slot {
    height: 190px;
  }
}
