:root {
  --bg: #f6f2ea;
  --bg-elevated: #fbf8f2;
  --surface: rgba(255, 255, 255, 0.9);
  --surface-strong: #fffdf9;
  --surface-muted: #f7f2e8;
  --ink: #1e293b;
  --ink-soft: #526072;
  --ink-muted: #6f7d8f;
  --line: rgba(30, 41, 59, 0.1);
  --line-strong: rgba(30, 41, 59, 0.18);
  --brand: #0f766e;
  --brand-strong: #115e59;
  --brand-soft: rgba(15, 118, 110, 0.1);
  --accent: #c98a1b;
  --accent-strong: #a16207;
  --accent-soft: rgba(201, 138, 27, 0.12);
  --success: #166534;
  --success-soft: rgba(22, 101, 52, 0.09);
  --danger: #b91c1c;
  --danger-soft: rgba(185, 28, 28, 0.08);
  --shadow-sm: 0 10px 24px rgba(15, 23, 42, 0.05);
  --shadow-md: 0 18px 42px rgba(15, 23, 42, 0.08);
  --shadow-lg: 0 26px 60px rgba(15, 23, 42, 0.1);
  --radius-xl: 30px;
  --radius-lg: 12px;
  --radius-md: 10px;
  --radius-sm: 8px;
  --radius-xs: 6px;
  --font-ui: "Plus Jakarta Sans", system-ui, sans-serif;
  --font-ar: "Cairo", "Alexandria", system-ui, sans-serif;
  --font-mono: "JetBrains Mono", "SFMono-Regular", Consolas, monospace;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
}

body {
  min-height: 100vh;
  background:
    radial-gradient(circle at top left, rgba(15, 118, 110, 0.12), transparent 24%),
    radial-gradient(circle at top right, rgba(201, 138, 27, 0.1), transparent 22%),
    linear-gradient(180deg, #fcfaf6 0%, var(--bg) 52%, #f2ede3 100%);
  color: var(--ink);
  font-family: var(--font-ui);
  line-height: 1.65;
  text-rendering: optimizeLegibility;
}

a {
  color: inherit;
}

img,
svg {
  max-width: 100%;
  height: auto;
}

button,
input,
textarea,
select {
  font: inherit;
}

:focus-visible {
  outline: 3px solid rgba(15, 118, 110, 0.28);
  outline-offset: 3px;
}

.container {
  width: min(1280px, calc(100% - 48px));
  margin-inline: auto;
}

.hero {
  padding: 2rem 0 1.4rem;
}

.hero .container {
  background:
    linear-gradient(140deg, rgba(255, 255, 255, 0.95), rgba(255, 250, 243, 0.92)),
    linear-gradient(180deg, rgba(15, 118, 110, 0.05), rgba(201, 138, 27, 0.05));
  border: 1px solid rgba(255, 255, 255, 0.5);
  border-radius: 16px;
  padding: 2.1rem;
  box-shadow: var(--shadow-lg);
}

.hero-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.6fr) minmax(280px, 0.95fr);
  gap: 1.25rem;
  align-items: stretch;
}

.hero-copy-block {
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.hero-kicker,
.section-kicker,
.topic-kicker,
.quiz-kicker,
.study-path-kicker,
.pdf-meta {
  letter-spacing: 0.13em;
  text-transform: uppercase;
  font-size: 0.75rem;
  font-weight: 800;
}

.hero-kicker,
.section-kicker,
.topic-kicker,
.quiz-kicker,
.study-path-kicker {
  color: var(--brand);
}

.hero h1 {
  margin-top: 0.7rem;
  font-size: clamp(2.2rem, 4.8vw, 4.55rem);
  line-height: 1.04;
  max-width: 12ch;
}

.hero-copy {
  margin-top: 1rem;
  max-width: 44rem;
  color: var(--ink-soft);
  font-size: 1.05rem;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.8rem;
  margin-top: 1.4rem;
}

.study-path-card {
  background: linear-gradient(180deg, rgba(248, 252, 251, 0.98), rgba(255, 248, 238, 0.95));
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: 1.25rem;
  box-shadow: var(--shadow-sm);
}

.study-path-list {
  display: grid;
  gap: 0.8rem;
  margin-top: 0.9rem;
}

.study-path-item {
  display: block;
  padding: 0.95rem 1rem;
  text-decoration: none;
  border-radius: var(--radius-sm);
  border: 1px solid rgba(15, 118, 110, 0.12);
  background: rgba(255, 255, 255, 0.84);
  transition: border-color 0.2s ease, transform 0.2s ease, box-shadow 0.2s ease;
}

.study-path-item strong {
  display: block;
  font-size: 0.98rem;
}

.study-path-item span {
  display: block;
  margin-top: 0.2rem;
  color: var(--ink-soft);
  font-size: 0.92rem;
}

.study-path-item:hover,
.study-path-item:focus-visible {
  border-color: rgba(15, 118, 110, 0.28);
  transform: translateY(-1px);
  box-shadow: var(--shadow-sm);
}

.sticky-nav {
  position: sticky;
  top: 0;
  z-index: 1000;
  backdrop-filter: blur(18px);
  background: rgba(252, 249, 243, 0.84);
  border-top: 1px solid rgba(255, 255, 255, 0.55);
  border-bottom: 1px solid var(--line);
}

.nav-shell {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.8rem 0;
}

.sticky-nav ul {
  list-style: none;
  display: flex;
  align-items: center;
  flex-wrap: nowrap;
  gap: 0.6rem;
  overflow-x: auto;
  scrollbar-width: thin;
}

.sticky-nav a {
  display: inline-flex;
  align-items: center;
  min-height: 2.6rem;
  padding: 0.65rem 0.95rem;
  text-decoration: none;
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--ink-soft);
  border-radius: 999px;
  transition: color 0.2s ease, background 0.2s ease;
}

.sticky-nav a:hover,
.sticky-nav a:focus-visible {
  color: var(--brand-strong);
  background: rgba(15, 118, 110, 0.08);
}

main {
  padding: 1.35rem 0 4rem;
}

section {
  margin-top: 2rem;
  scroll-margin-top: 5.5rem;
}

.dashboard-intro,
.section-heading {
  display: flex;
  justify-content: space-between;
  gap: 1.5rem;
  align-items: end;
  margin-bottom: 1.3rem;
}

.dashboard-intro h2,
.section-heading h2 {
  margin-top: 0.35rem;
  font-size: clamp(1.7rem, 3vw, 2.45rem);
  line-height: 1.12;
}

.dashboard-intro p,
.section-heading p {
  max-width: 38rem;
  color: var(--ink-soft);
}

.search-box {
  width: min(440px, 100%);
}

#search-input {
  width: 100%;
  min-height: 3.45rem;
  padding: 1rem 1.1rem;
  border-radius: 18px;
  border: 1px solid var(--line);
  background: var(--surface-strong);
  color: var(--ink);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.7);
}

#search-input::placeholder {
  color: var(--ink-muted);
}

#search-input:focus {
  outline: none;
  border-color: rgba(15, 118, 110, 0.38);
  box-shadow: 0 0 0 4px rgba(15, 118, 110, 0.08);
}

.search-status {
  padding-top: 0.5rem;
  color: var(--ink-soft);
  font-size: 0.92rem;
}

.dashboard-stats,
.exam-summary-grid,
.lecture-grid,
.mistakes-grid,
.labs-grid,
.cheat-sheet-grid,
.visualizer-grid,
.pdf-grid,
.other-results-grid {
  display: grid;
  gap: 1rem;
}

.dashboard-stats {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.stat-card,
.exam-summary-card,
.topic-card,
.mistake-card,
.comparison-card,
.viz-card,
.pdf-card,
.other-result-card,
#quiz-container,
.lab-card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-md);
}

.stat-card {
  position: relative;
  padding: 1.45rem;
  overflow: hidden;
}

.stat-card::after {
  position: absolute;
  top: 1rem;
  right: 1rem;
  width: 2.4rem;
  height: 2.4rem;
  display: grid;
  place-items: center;
  border-radius: 999px;
  background: var(--brand-soft);
  color: var(--brand-strong);
  font-size: 1rem;
  font-weight: 800;
}

.stat-card:nth-child(1)::after {
  content: "01";
}

.stat-card:nth-child(2)::after {
  content: "%";
}

.stat-card:nth-child(3)::after {
  content: "Q";
}

.stat-card h3 {
  font-size: 0.82rem;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--ink-muted);
}

.stat-card p {
  margin-top: 0.55rem;
  font-size: clamp(1.7rem, 2vw, 2rem);
  font-weight: 800;
  color: var(--brand-strong);
}

.progress-container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

.btn,
.btn-text,
.tab-btn,
.quiz-option {
  font: inherit;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.45rem;
  min-height: 2.9rem;
  padding: 0.85rem 1.15rem;
  border-radius: 999px;
  border: 1px solid transparent;
  text-decoration: none;
  cursor: pointer;
  font-weight: 700;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease, border-color 0.2s ease;
}

.btn:hover,
.btn:focus-visible {
  transform: translateY(-1px);
}

.btn-primary {
  background: var(--brand);
  color: #fff;
  box-shadow: 0 12px 24px rgba(15, 118, 110, 0.18);
}

.btn-primary:hover,
.btn-primary:focus-visible {
  background: var(--brand-strong);
}

.btn-secondary {
  background: rgba(255, 255, 255, 0.82);
  border-color: var(--line-strong);
  color: var(--ink);
}

.btn-secondary:hover,
.btn-secondary:focus-visible {
  border-color: rgba(15, 118, 110, 0.24);
  background: #fff;
}

.btn-ghost {
  background: rgba(255, 255, 255, 0.28);
  border-color: var(--line-strong);
  color: var(--ink-soft);
}

.btn-sm {
  min-height: 2.65rem;
  padding: 0.7rem 1rem;
}

#revision-mode-toggle {
  background: linear-gradient(180deg, #fff5de, #f8ebc7);
  border-color: rgba(201, 138, 27, 0.28);
  color: #6d4c0b;
  box-shadow: none;
}

#revision-mode-toggle:hover,
#revision-mode-toggle:focus-visible {
  background: #f6e7bb;
}

.btn-text {
  background: none;
  border: 0;
  color: var(--brand-strong);
  cursor: pointer;
  font-weight: 700;
}

.completed {
  background: var(--success);
  color: #fff;
}

.quick-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.9rem;
  margin-top: 1.1rem;
}

.lecture-grid {
  grid-template-columns: 1fr;
  gap: 1.5rem;
}

.topic-card {
  padding: 1.5rem;
}

.topic-header {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  align-items: start;
}

.topic-header h3 {
  margin-top: 0.35rem;
  font-size: 1.45rem;
  line-height: 1.22;
}

.priority {
  display: inline-flex;
  align-items: center;
  padding: 0.45rem 0.8rem;
  border-radius: 999px;
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.05em;
}

.priority-core,
.priority-high {
  background: rgba(15, 118, 110, 0.1);
  color: var(--brand-strong);
}

.priority-medium {
  background: var(--accent-soft);
  color: var(--accent-strong);
}

.topic-overview {
  margin-top: 1rem;
  font-weight: 600;
  color: var(--ink);
}

.topic-overview-ar {
  margin-top: 0.35rem;
}

.topic-grid,
.exam-mode-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.95rem;
  margin-top: 1.25rem;
}

.info-panel,
.key-idea-card,
.example-step,
.mistake-item,
.final-question-card,
.qa-item,
.command-block,
.step-card,
.question-style-card,
.exam-memory-block {
  background: rgba(255, 255, 255, 0.72);
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
}

.info-panel {
  padding: 1.05rem;
}

.info-panel h4,
.detail-section h4,
.viz-card h4 {
  margin-bottom: 0.6rem;
  font-size: 1rem;
}

.key-idea-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.9rem;
  margin-top: 1rem;
}

.key-idea-card {
  padding: 1rem;
  border-inline-start: 4px solid var(--accent);
}

.exam-memory-block {
  padding: 1rem;
  background: linear-gradient(180deg, rgba(255, 251, 235, 0.92), rgba(255, 255, 255, 0.82));
  border-color: rgba(201, 138, 27, 0.24);
}

.exam-memory-block ul {
  display: grid;
  gap: 0.5rem;
  padding-inline-start: 1.1rem;
}

.exam-memory-block li::marker {
  color: var(--accent-strong);
}

.question-style-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 0.75rem;
}

.question-style-card {
  padding: 0.85rem;
}

.question-style-card span {
  display: inline-flex;
  margin-bottom: 0.4rem;
  padding: 0.2rem 0.55rem;
  border-radius: var(--radius-xs);
  background: var(--brand-soft);
  color: var(--brand-strong);
  font-size: 0.78rem;
  font-weight: 800;
}

.detail-section {
  margin-top: 1.2rem;
}

.detail-section > h4 {
  margin-bottom: 0.75rem;
}

.section-title-row {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  align-items: baseline;
  margin-bottom: 0.75rem;
}

.section-title-row span {
  color: var(--ink-soft);
  font-size: 0.92rem;
}

.example-steps,
.mistakes-inline,
.question-list,
.command-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.9rem;
}

.command-list {
  gap: 0.85rem;
}

.example-step {
  display: grid;
  grid-template-columns: 56px 1fr;
  gap: 1rem;
  padding: 1rem;
}

.example-index,
.step-number {
  display: grid;
  place-items: center;
  width: 52px;
  height: 52px;
  border-radius: 16px;
  background: linear-gradient(180deg, rgba(15, 118, 110, 0.14), rgba(15, 118, 110, 0.08));
  color: var(--brand-strong);
  font-weight: 800;
}

.mistake-item,
.command-block,
.final-question-card,
.qa-item {
  padding: 1rem;
}

.mistake-item h5,
.final-question-card summary,
.qa-item summary {
  margin-bottom: 0.45rem;
}

.qa-item,
.final-question-card {
  transition: border-color 0.2s ease, background 0.2s ease;
}

.qa-item[open],
.final-question-card[open] {
  border-color: rgba(15, 118, 110, 0.24);
  background: rgba(255, 255, 255, 0.88);
}

.qa-item summary,
.final-question-card summary {
  cursor: pointer;
  font-weight: 700;
  list-style: none;
}

.qa-item summary::-webkit-details-marker,
.final-question-card summary::-webkit-details-marker {
  display: none;
}

.topic-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-top: 1.2rem;
}

.mistakes-grid {
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
}

.labs-grid {
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
}

.mistake-card {
  padding: 1.15rem;
}

.mistake-card h4 {
  margin-bottom: 0.65rem;
}

.lab-card {
  padding: 1.25rem;
}

.lab-card h4 {
  margin-bottom: 0.6rem;
}

.lab-focus {
  margin-top: 0.8rem;
  color: var(--ink-soft);
}

.final-questions-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 1rem;
}

.question-topic {
  margin: 0.55rem 0 0.25rem;
  color: var(--brand-strong);
  font-size: 0.92rem;
  font-weight: 700;
}

.exam-summary-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  margin-bottom: 1rem;
}

.exam-summary-card {
  padding: 1.2rem;
}

.cheat-sheet-grid {
  grid-template-columns: repeat(auto-fit, minmax(340px, 1fr));
}

.comparison-card {
  padding: 1.15rem;
}

.comparison-card h4 {
  margin-bottom: 0.75rem;
}

.comparison-card .exam-memory-block,
.comparison-card .question-style-block {
  margin: 0 0 0.85rem;
}

.table-responsive {
  overflow-x: auto;
  scrollbar-width: thin;
}

table {
  width: 100%;
  min-width: 280px;
  border-collapse: collapse;
  overflow: hidden;
  border-radius: 14px;
}

th,
td {
  border: 1px solid var(--line);
  padding: 0.8rem 0.75rem;
  text-align: left;
  vertical-align: top;
}

th {
  background: rgba(15, 118, 110, 0.09);
  color: var(--ink);
  font-size: 0.92rem;
}

tr:nth-child(even) td {
  background: rgba(247, 242, 232, 0.4);
}

.command-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-bottom: 1rem;
}

.tab-btn {
  padding: 0.8rem 1rem;
  border-radius: 999px;
  border: 1px solid var(--line-strong);
  background: rgba(255, 255, 255, 0.72);
  cursor: pointer;
  font-weight: 700;
  transition: background 0.2s ease, border-color 0.2s ease, color 0.2s ease;
}

.tab-btn:hover,
.tab-btn:focus-visible {
  border-color: rgba(15, 118, 110, 0.24);
}

.tab-btn.active {
  background: var(--brand);
  border-color: var(--brand);
  color: #fff;
}

.tab-pane {
  display: none;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 0.8rem;
}

.tab-pane.active {
  display: grid;
}

.command-block {
  padding: 1rem;
  background: linear-gradient(180deg, #142433, #1a2d3f);
  border-color: rgba(255, 255, 255, 0.05);
  color: #e5eef7;
}

.cmd-line {
  display: inline-block;
  font-family: var(--font-mono);
  font-size: 0.95rem;
  font-weight: 700;
  color: #8ee5d7;
  white-space: pre-wrap;
  word-break: break-word;
  user-select: text;
}

.cmd-line::before {
  content: ">";
  margin-inline-end: 0.55rem;
  color: #f7c869;
}

.cmd-desc {
  margin-top: 0.55rem;
  color: rgba(229, 238, 247, 0.82);
  font-size: 0.94rem;
}

.command-block p {
  margin-top: 0.45rem;
  color: rgba(229, 238, 247, 0.8);
  font-size: 0.9rem;
}

.command-block strong {
  color: #f7c869;
}

.optional-lab-badge {
  display: inline-flex;
  margin-top: 0.65rem;
  padding: 0.25rem 0.55rem;
  border-radius: var(--radius-xs);
  background: rgba(247, 200, 105, 0.12);
  color: #f7c869;
  font-size: 0.78rem;
  font-weight: 800;
}

.visualizer-grid {
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
}

.viz-card {
  padding: 1.2rem;
}

.step-visual-title {
  margin-bottom: 0.9rem;
  color: var(--brand-strong);
  font-weight: 800;
}

.step-card-grid {
  display: grid;
  gap: 0.8rem;
}

.step-card {
  display: grid;
  grid-template-columns: 56px 1fr;
  gap: 0.95rem;
  padding: 1rem;
  position: relative;
}

.step-card:not(:last-child)::after {
  content: "";
  position: absolute;
  inset-inline-start: 1.55rem;
  bottom: -0.95rem;
  width: 2px;
  height: 0.95rem;
  background: linear-gradient(180deg, rgba(15, 118, 110, 0.24), rgba(201, 138, 27, 0.12));
}

.step-card h5 {
  margin-bottom: 0.35rem;
}

.pdf-grid {
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
}

.pdf-card {
  display: grid;
  gap: 0.25rem;
  padding: 1.1rem;
  text-decoration: none;
}

.pdf-meta {
  color: var(--accent-strong);
}

.pdf-card strong {
  font-size: 1.05rem;
}

.pdf-card span:last-child {
  color: var(--ink-soft);
  font-weight: 600;
}

#quiz-container {
  padding: 1.45rem;
}

#quiz-question h3 {
  margin-top: 0.35rem;
  line-height: 1.35;
}

#quiz-options {
  display: grid;
  gap: 0.8rem;
  margin-top: 1rem;
}

.quiz-option {
  text-align: left;
  min-height: 3.6rem;
  padding: 1rem 1rem;
  border-radius: 18px;
  border: 1px solid var(--line-strong);
  background: #fff;
  cursor: pointer;
  transition: border-color 0.2s ease, background 0.2s ease, transform 0.2s ease;
}

.quiz-option:hover:enabled,
.quiz-option:focus-visible:enabled {
  border-color: rgba(15, 118, 110, 0.45);
  transform: translateY(-1px);
}

#quiz-feedback {
  display: none;
  margin-top: 1rem;
  padding: 1rem;
  border-radius: var(--radius-md);
  background: rgba(15, 118, 110, 0.06);
  border: 1px solid rgba(15, 118, 110, 0.14);
}

.quiz-feedback-correct {
  color: var(--success);
  font-weight: 800;
}

.quiz-feedback-wrong {
  color: var(--danger);
  font-weight: 800;
}

.quiz-controls {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-top: 1rem;
}

#quiz-next {
  display: none;
}

.quiz-option-correct {
  border-color: rgba(22, 101, 52, 0.5) !important;
  background: var(--success-soft) !important;
}

.quiz-option-wrong {
  border-color: rgba(185, 28, 28, 0.46) !important;
  background: var(--danger-soft) !important;
}

.quiz-feedback-arabic {
  margin-top: 0.55rem;
  border-top: 1px solid var(--line);
  padding-top: 0.55rem;
}

.quiz-finish-container {
  text-align: center;
}

.quiz-finish-score {
  font-size: 2.4rem;
  color: var(--brand-strong);
  font-weight: 800;
}

.other-results {
  margin-top: 1.2rem;
}

.other-results-grid {
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
}

.other-results h3 {
  margin-bottom: 0.8rem;
}

.other-result-card {
  display: block;
  padding: 1rem;
  text-decoration: none;
}

.other-result-card small {
  color: var(--brand-strong);
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.other-result-card h4 {
  margin: 0.45rem 0;
}

.other-result-card p {
  color: var(--ink-soft);
}

.mini-table {
  display: grid;
  gap: 0.6rem;
}

.mini-table-row {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.75rem 0.85rem;
  border-radius: 14px;
  background: rgba(247, 242, 232, 0.72);
  font-size: 0.92rem;
}

.mini-command-list {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.mini-command-list code {
  padding: 0.4rem 0.65rem;
  border-radius: 999px;
  background: rgba(15, 118, 110, 0.1);
  color: var(--brand-strong);
  font-family: var(--font-mono);
}

.exam-mode-footer {
  display: grid;
  gap: 0.5rem;
  margin-top: 1rem;
  padding: 1rem;
  border-radius: var(--radius-md);
  background: rgba(201, 138, 27, 0.09);
  border: 1px solid rgba(201, 138, 27, 0.18);
}

.topic-card-exam .topic-overview,
.topic-card-exam .topic-overview-ar,
.topic-card-exam .key-idea-list,
.topic-card-exam .detail-section {
  display: none;
}

.empty-state {
  grid-column: 1 / -1;
  text-align: center;
}

.arabic-text {
  font-family: var(--font-ar);
  direction: rtl;
  text-align: right;
  line-height: 1.9;
  font-weight: 600;
  color: var(--ink-soft);
}

.footer-shell {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  padding: 0 0 2.5rem;
  color: var(--ink-soft);
  font-size: 0.95rem;
}

.hidden {
  display: none !important;
}

body.revision-mode .hero .container {
  border-color: rgba(201, 138, 27, 0.22);
}

body.revision-mode .topic-card {
  background: rgba(255, 253, 248, 0.95);
}

@media (max-width: 1024px) {
  .dashboard-intro,
  .section-heading,
  .footer-shell {
    align-items: start;
    flex-direction: column;
  }

  .hero-layout {
    grid-template-columns: 1fr;
  }

  .dashboard-stats,
  .exam-summary-grid,
  .topic-grid,
  .exam-mode-grid {
    grid-template-columns: 1fr;
  }
}

@media (prefers-reduced-motion: reduce) {
  * {
    animation: none !important;
    transition: none !important;
    scroll-behavior: auto !important;
  }
}
