/* SAPD Academy — design system
   Navy/gold/paper palette shared with the recruitment site (same
   institution, same web presence). Source Serif for reading, Source Sans
   for everything else. Hard borders, minimal radius — deliberately not the
   rounded-card SaaS kit. See README's course-app section for the full
   design plan this implements. */

@font-face {
  font-family: "Source Sans 3";
  src: url("/fonts/source-sans-3-latin-400-normal.woff2") format("woff2");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Source Sans 3";
  src: url("/fonts/source-sans-3-latin-600-normal.woff2") format("woff2");
  font-weight: 600;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Source Sans 3";
  src: url("/fonts/source-sans-3-latin-700-normal.woff2") format("woff2");
  font-weight: 700;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Source Serif 4";
  src: url("/fonts/source-serif-4-latin-400-normal.woff2") format("woff2");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Source Serif 4";
  src: url("/fonts/source-serif-4-latin-400-italic.woff2") format("woff2");
  font-weight: 400;
  font-style: italic;
  font-display: swap;
}
@font-face {
  font-family: "Source Serif 4";
  src: url("/fonts/source-serif-4-latin-600-normal.woff2") format("woff2");
  font-weight: 600;
  font-style: normal;
  font-display: swap;
}

:root {
  --navy-deep: #0a1550;
  --navy-panel: #132a63;
  --paper: #ede9dc;
  --paper-white: #f7f5ec;
  --gold: #d4af37;
  --gold-deep: #b8952f;
  --alert: #a61c1c;
  --complete: #2f5d3a;
  --ink: #1c1c1c;
  --ink-muted: #5a5a52;
  --border: #c8c2ab;
  --sans: "Source Sans 3", Arial, sans-serif;
  --serif: "Source Serif 4", Georgia, serif;
  --focus-ring: 0 0 0 3px rgba(212, 175, 55, 0.55);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.5;
}

a {
  color: var(--navy-panel);
}
a:hover {
  color: var(--gold-deep);
}

a:focus-visible,
button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible {
  outline: none;
  box-shadow: var(--focus-ring);
}

@media (prefers-reduced-motion: reduce) {
  * {
    animation-duration: 0.01ms !important;
    transition-duration: 0.01ms !important;
  }
}

.site-header {
  background: var(--navy-deep);
  color: #fff;
  padding: 1rem 1.5rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 3px solid var(--gold);
}
.site-header .brand {
  font-weight: 700;
  font-size: 1.1rem;
  letter-spacing: 0.02em;
}
.site-header nav a {
  color: #fff;
  text-decoration: none;
  margin-left: 1.25rem;
  font-weight: 600;
  font-size: 0.9rem;
}
.site-header nav a:hover {
  color: var(--gold);
}

main {
  max-width: 960px;
  margin: 0 auto;
  padding: 2rem 1.5rem;
}

h1, h2, h3 {
  font-family: var(--sans);
  font-weight: 700;
  color: var(--navy-deep);
  margin-top: 0;
}
h1 {
  font-size: 1.6rem;
  border-bottom: 2px solid var(--gold);
  padding-bottom: 0.5rem;
}
h2 {
  font-size: 1.2rem;
}

.panel {
  background: var(--paper-white);
  border: 1px solid var(--border);
  border-radius: 2px;
  padding: 1.25rem;
  margin-bottom: 1.25rem;
}

table.catalog {
  width: 100%;
  border-collapse: collapse;
  background: var(--paper-white);
}
table.catalog th {
  background: var(--navy-panel);
  color: #fff;
  text-align: left;
  padding: 0.6rem 0.8rem;
  font-size: 0.8rem;
  font-weight: 600;
}
table.catalog td {
  padding: 0.6rem 0.8rem;
  border-bottom: 1px solid var(--border);
  vertical-align: top;
}
table.catalog tr:last-child td {
  border-bottom: none;
}
.badge-required {
  color: var(--alert);
  font-weight: 600;
  font-size: 0.85rem;
}
.status-complete {
  color: var(--complete);
  font-weight: 600;
}
.status-pending {
  color: var(--gold-deep);
  font-weight: 600;
}
.status-failed {
  color: var(--alert);
  font-weight: 600;
}

.lesson-layout {
  display: flex;
  gap: 2rem;
  align-items: flex-start;
}
.module-sidebar {
  width: 220px;
  flex-shrink: 0;
  background: var(--navy-panel);
  color: #fff;
  padding: 1rem;
  border-radius: 2px;
}
.module-sidebar ul {
  list-style: none;
  margin: 0;
  padding: 0;
}
.module-sidebar li {
  padding: 0.4rem 0;
  font-size: 0.9rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.15);
}
.module-sidebar li.active {
  color: var(--gold);
  font-weight: 600;
}
.lesson-content {
  flex: 1;
  max-width: 65ch;
  font-family: var(--serif);
  font-size: 1.05rem;
  line-height: 1.65;
}
.lesson-content h3 {
  font-family: var(--serif);
  font-weight: 600;
}

.quiz-question {
  margin-bottom: 1.5rem;
  padding-bottom: 1.5rem;
  border-bottom: 1px solid var(--border);
}
.quiz-question:last-of-type {
  border-bottom: none;
}
.quiz-question p.prompt {
  font-weight: 600;
  margin-bottom: 0.5rem;
}
.quiz-question label {
  display: block;
  padding: 0.35rem 0;
  cursor: pointer;
}

.btn {
  display: inline-block;
  font-family: var(--sans);
  font-weight: 600;
  font-size: 0.95rem;
  padding: 0.6rem 1.2rem;
  border: 1px solid var(--navy-deep);
  background: var(--navy-deep);
  color: #fff;
  border-radius: 2px;
  cursor: pointer;
  text-decoration: none;
}
.btn:hover {
  background: var(--navy-panel);
}
.btn-gold {
  background: var(--gold);
  border-color: var(--gold-deep);
  color: var(--navy-deep);
}
.btn-gold:hover {
  background: var(--gold-deep);
}

.btn-discord {
  background: #5865f2;
  border-color: #5865f2;
  color: #fff;
  font-size: 1.05rem;
  padding: 0.75rem 1.5rem;
}
.btn-discord:hover {
  background: #4752c4;
  border-color: #4752c4;
}

.login-hero {
  text-align: center;
  padding: 4rem 1.5rem;
}
.login-hero h1 {
  border-bottom: none;
  font-size: 1.8rem;
}

.dossier-table {
  width: 100%;
  border-collapse: collapse;
}
.dossier-table td {
  padding: 0.5rem 0.8rem;
  border-bottom: 1px solid var(--border);
}
.dossier-table td:first-child {
  font-weight: 600;
  width: 40%;
  color: var(--ink-muted);
}

@media (max-width: 700px) {
  .lesson-layout {
    flex-direction: column;
  }
  .module-sidebar {
    width: 100%;
  }
  main {
    padding: 1.25rem 1rem;
  }
}
