/* Revision mini-site: small additions on top of ../shared.css (main site styles) */

a.nav-link { display: block; text-decoration: none; }
.nav-menu .nav-label { margin-top: 8px; text-transform: none; letter-spacing: .3px; font-size: 11px; line-height: 1.3; }

.content { padding-top: 28px; }
.section { margin-bottom: 32px; scroll-margin-top: 20px; }
.section-title { flex-wrap: wrap; line-height: 1.3; font-size: 24px; }

.page-head { margin: 0 0 22px 46px; }
.page-head h1 { font-size: 30px; color: var(--highlight-color); line-height: 1.25; }
.page-head h1 i { margin-right: 10px; }
.crumb { font-size: 14px; opacity: .75; margin-bottom: 4px; }
.crumb a { color: var(--highlight-color); text-decoration: none; }
.page-head .rev-p a, .rev-notes p a { color: var(--highlight-color); font-weight: 600; }
body.nav-hidden .page-head { margin-left: 56px; }

.topic-banner {
  margin: 36px 0 16px;
  padding: 10px 16px;
  border-radius: 8px;
  background: var(--table-header-bg);
  color: var(--highlight-color);
  font-size: 19px;
  font-weight: 700;
}
.topic-banner:first-of-type { margin-top: 0; }
.topic-code { opacity: .7; margin-right: 6px; }

/* one teaching note */
.subsection { padding-bottom: 18px; margin-bottom: 18px; border-bottom: 1px solid var(--table-border); }
.subsection:last-of-type { border-bottom: none; }
.syllabus-line {
  font-style: italic;
  opacity: .9;
  border-left: 3px solid var(--highlight-color);
  padding: 6px 12px;
  margin-bottom: 10px;
  background: var(--bg-color);
  border-radius: 0 6px 6px 0;
  font-size: 15px;
}
.note-code {
  font-style: normal;
  font-weight: 700;
  font-size: 12px;
  color: var(--highlight-color);
  margin-right: 6px;
  white-space: nowrap;
}
.rev-notes { font-size: 17px; }
.rev-p { margin: 8px 0; }
.rev-list { list-style: none; margin: 6px 0; }
.rev-list li { position: relative; padding-left: 20px; margin-bottom: 6px; }
.rev-list li:before { content: "•"; color: var(--highlight-color); font-weight: bold; position: absolute; left: 2px; }
.rev-list.ordered { counter-reset: step; }
.rev-list.ordered > li { counter-increment: step; padding-left: 26px; }
.rev-list.ordered > li:before { content: counter(step) "."; left: 0; }
.rev-list .rev-list { margin: 4px 0 0; }
.todo { opacity: .55; font-style: italic; }

code.ic {
  font-family: 'Courier New', monospace;
  background: var(--code-bg);
  padding: 1px 5px;
  border-radius: 4px;
  font-size: .92em;
}

.table-wrap { overflow-x: auto; margin: 10px 0; }
.table-wrap .comparison-table { margin-top: 0; font-size: 16px; }
.comparison-table th, .comparison-table td { padding: 9px 12px; vertical-align: top; }

.code-block { position: relative; }
.code-block pre { margin: 0; font-family: inherit; white-space: pre; }
.code-lang {
  position: absolute; top: 6px; right: 10px;
  font-size: 11px; font-weight: 700; letter-spacing: .5px; opacity: .55;
  font-family: 'Source Sans Pro', sans-serif;
}
.rev-diagram {
  text-align: left;
  white-space: pre;
  overflow-x: auto;
  font-size: 13px;
  line-height: 1.35;
  margin: 10px 0;
}
.diagram { overflow-x: auto; }
.diagram svg { color: var(--text-color); }

.exam-tip { margin: 10px 0; }
.exam-tip i { margin-right: 4px; }

/* practice links (added later per objective via practice.json) */
.practice-box {
  margin-top: 6px;
  padding: 12px 16px;
  border-radius: 8px;
  background: var(--bg-color);
  box-shadow: 0 1px 4px var(--shadow-color);
  display: flex; flex-wrap: wrap; align-items: center; gap: 10px;
}
.practice-title { font-weight: 700; color: var(--highlight-color); margin-right: 6px; }
.practice-link {
  text-decoration: none; color: var(--text-color);
  padding: 6px 12px; border-radius: 6px; background: var(--table-header-bg); font-weight: 600; font-size: 15px;
}
.practice-link:hover { color: var(--highlight-color); }

/* hub */
.hub-grid { margin-bottom: 40px; }
.hub-card { display: flex; flex-direction: column; }
.hub-head {
  font-size: 21px; font-weight: 700; color: var(--highlight-color);
  text-decoration: none; margin-bottom: 10px; display: flex; align-items: center; gap: 10px; flex-wrap: wrap;
}
.hub-head i { font-size: 22px; width: 26px; text-align: center; }
.hub-code { opacity: .7; }
.hub-list { list-style: none; }
.hub-list li { padding: 5px 0; border-bottom: 1px solid var(--table-border); font-size: 16px; display: flex; align-items: center; gap: 4px; }
.hub-list li:last-child { border-bottom: none; }
.hub-list a { color: var(--text-color); text-decoration: none; flex: 1; }
.hub-list a:hover { color: var(--highlight-color); }
.hub-list .count { font-size: 12px; opacity: .55; margin-left: 6px; }
body.hide-hl .hl-section.hub-card { display: none; }

/* ---------- phones and small tablets ---------- */
@media (max-width: 860px) {
  .container { display: block; }
  .nav-menu {
    position: fixed; top: 0; left: 0; bottom: 0;
    width: 82vw; min-width: 0; max-width: 320px;
    max-height: none; height: 100vh;
    padding-top: 64px;
  }
  .floating-nav-toggle { left: 12px; top: 12px; }
  .content, body.nav-hidden .content { padding: 64px 16px 32px; }
  .page-head, body.nav-hidden .page-head { margin-left: 0; }
  .page-head h1 { font-size: 24px; }
  .section { padding: 18px 16px; }
  .section-title { font-size: 20px; }
  .section-title i { display: none; }
  .two-column { flex-direction: column; gap: 0; }
  .app-grid, .ao-grid { grid-template-columns: 1fr; }
  .rev-notes { font-size: 16px; }
  .rev-diagram { font-size: 11px; }
}

/* long syllabus headings: keep as flowing text (shared.css uses flex) */
.section .section-title { display: block; }
.section .section-title i { margin-right: 10px; }
.section .section-title .ao-badge, .section .section-title .hl-badge { position: relative; top: -3px; }

/* Compare / Distinguish: how paired answers earn marks */
.paired-tip { margin: 0 0 18px; }
.term-entry .paired-tip { margin-top: 10px; }
.paired-tip a { color: var(--highlight-color); font-weight: 600; }
.paired-eg { margin-top: 8px; padding: 6px 10px; border-radius: 6px; }
.paired-eg i { width: 18px; }
.paired-eg.bad { background: rgba(231, 76, 60, .12); }
.paired-eg.bad i { color: #e74c3c; }
.paired-eg.good { background: rgba(46, 204, 113, .12); }
.paired-eg.good i { color: #27ae60; }
.eg-note { opacity: .65; font-size: 13px; white-space: nowrap; }
.paired-q { margin-top: 8px; font-size: 15px; }

/* Study tips (memory aids) – deliberately a different colour from syllabus content */
.study-tip {
  margin: 10px 0 4px;
  padding: 8px 12px;
  border-left: 4px solid #9b59b6;
  border-radius: 0 8px 8px 0;
  background: rgba(155, 89, 182, .12);
  font-size: 16px;
}
.study-tip .highlight { color: #8e44ad; }
body.dark-mode .study-tip { background: rgba(155, 89, 182, .18); }
body.dark-mode .study-tip .highlight { color: #c39bd3; }
.study-tip-label {
  display: inline-block;
  margin-right: 6px;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: .5px;
  text-transform: uppercase;
  color: #8e44ad;
}
body.dark-mode .study-tip-label { color: #c39bd3; }
