:root {
  --bg: #f7f3ea;
  --panel: #fffdf8;
  --ink: #1f1b16;
  --muted: #756b5d;
  --line: #eadfcd;
  --gold: #b27a2b;
  --green: #2f7d5b;
  --blue: #3f6f9f;
  --red: #a84f3f;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

* { box-sizing: border-box; }
body {
  margin: 0;
  color: var(--ink);
  background:
    linear-gradient(180deg, rgba(247,243,234,.94), rgba(247,243,234,1)),
    url("assets/default-course-cover-JYQ-6GtO.jpg") center top / cover fixed;
}

a { color: inherit; text-decoration: none; }
button, input { font: inherit; }

.site-nav {
  position: sticky;
  top: 0;
  z-index: 5;
  height: 68px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding: 0 32px;
  border-bottom: 1px solid rgba(234,223,205,.82);
  background: rgba(255,253,248,.9);
  backdrop-filter: blur(18px);
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 800;
}

.brand span {
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  border-radius: 8px;
  color: #fff;
  background: #1f1b16;
}

.nav-links {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 10px;
  color: var(--muted);
  font-size: 14px;
}

.nav-links a {
  padding: 8px 10px;
  border-radius: 8px;
}

.nav-links a:hover {
  color: var(--ink);
  background: #f1e8d8;
}

.shell {
  width: min(1180px, calc(100vw - 36px));
  margin: 0 auto;
  padding: 48px 0 80px;
}

.hero {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(280px, .8fr);
  gap: 28px;
  align-items: stretch;
  margin-bottom: 34px;
}

.hero-main, .hero-side, .section, .card {
  border: 1px solid var(--line);
  background: rgba(255,253,248,.94);
  box-shadow: 0 18px 45px rgba(84,63,32,.08);
}

.hero-main {
  min-height: 310px;
  padding: 42px;
  border-radius: 8px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.eyebrow {
  display: inline-flex;
  width: fit-content;
  padding: 6px 10px;
  border: 1px solid #e5d3b4;
  border-radius: 8px;
  color: #8a6123;
  background: #fff5df;
  font-size: 13px;
  font-weight: 700;
}

h1 {
  max-width: 780px;
  margin: 18px 0 14px;
  font-size: 48px;
  line-height: 1.08;
  letter-spacing: 0;
}

.lead {
  max-width: 760px;
  margin: 0;
  color: var(--muted);
  font-size: 17px;
  line-height: 1.8;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 28px;
}

.hero-actions a, .card-action {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 42px;
  padding: 0 16px;
  border-radius: 8px;
  border: 1px solid var(--line);
  color: var(--ink);
  background: #fffaf0;
  font-weight: 800;
}

.hero-actions a.primary, .card-action.primary {
  color: #fff;
  border-color: #1f1b16;
  background: #1f1b16;
}

.hero-side {
  padding: 26px;
  border-radius: 8px;
}

.metric-list {
  display: grid;
  gap: 12px;
  margin-top: 20px;
}

.metric {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  padding: 14px 0;
  border-bottom: 1px solid var(--line);
}

.metric:last-child { border-bottom: 0; }
.metric span { color: var(--muted); }
.metric strong { white-space: nowrap; }

.section {
  margin-top: 24px;
  padding: 28px;
  border-radius: 8px;
}

.section-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 20px;
}

.section-head h2 {
  margin: 0 0 6px;
  font-size: 28px;
  letter-spacing: 0;
}

.section-head p {
  margin: 0;
  color: var(--muted);
  line-height: 1.7;
}

.search-box {
  width: min(320px, 100%);
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 12px 14px;
  outline: none;
  background: #fff;
}

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

.grid.two { grid-template-columns: repeat(2, minmax(0, 1fr)); }

.course-card {
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255,253,248,.94);
  box-shadow: 0 18px 45px rgba(84,63,32,.08);
  display: flex;
  flex-direction: column;
  min-height: 340px;
}

.course-cover {
  display: block;
  aspect-ratio: 16 / 9;
  background: #efe4d1;
  overflow: hidden;
}

.course-cover img {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
  transition: transform .18s ease;
}

.course-card:hover .course-cover img { transform: scale(1.03); }

.course-body {
  flex: 1;
  padding: 18px;
  display: flex;
  flex-direction: column;
  gap: 11px;
}

.card {
  min-height: 230px;
  padding: 20px;
  border-radius: 8px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.card-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  color: var(--muted);
  font-size: 13px;
}

.tag {
  display: inline-flex;
  padding: 5px 8px;
  border-radius: 8px;
  color: #7c561d;
  background: #fff3da;
  font-size: 12px;
  font-weight: 800;
}

.tag.green { color: var(--green); background: #eaf7f0; }
.tag.blue { color: var(--blue); background: #eaf2fb; }
.tag.red { color: var(--red); background: #fff0ec; }

.card h3, .course-card h3 {
  margin: 0;
  font-size: 20px;
  line-height: 1.35;
  letter-spacing: 0;
}

.card p, .course-card p {
  margin: 0;
  color: var(--muted);
  line-height: 1.7;
}

.card ul {
  margin: 0;
  padding-left: 18px;
  color: var(--muted);
  line-height: 1.8;
}

.card-foot {
  margin-top: auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  color: #8a6123;
  font-size: 13px;
  font-weight: 700;
}

.card-action {
  min-height: 36px;
  padding: 0 12px;
  font-size: 13px;
}

.timeline {
  display: grid;
  gap: 14px;
}

.timeline-row {
  display: grid;
  grid-template-columns: 96px minmax(0, 1fr) 160px;
  gap: 18px;
  align-items: start;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fffaf2;
}

.timeline-row strong { font-size: 17px; }
.timeline-row p { margin: 6px 0 0; color: var(--muted); line-height: 1.65; }
.timeline-row em { color: var(--gold); font-style: normal; font-weight: 800; text-align: right; }

.empty {
  padding: 38px;
  border: 1px dashed #dcc8a8;
  border-radius: 8px;
  color: var(--muted);
  text-align: center;
  background: #fffaf0;
}

.footer-note {
  margin-top: 24px;
  color: var(--muted);
  font-size: 13px;
  text-align: center;
}

@media (max-width: 920px) {
  .site-nav { height: auto; padding: 14px 18px; align-items: flex-start; flex-direction: column; }
  .nav-links { justify-content: flex-start; }
  .shell { width: min(100% - 28px, 720px); padding-top: 28px; }
  .hero { grid-template-columns: 1fr; }
  h1 { font-size: 36px; }
  .hero-main { min-height: 0; padding: 28px; }
  .section-head { align-items: stretch; flex-direction: column; }
  .search-box { width: 100%; }
  .grid, .grid.two { grid-template-columns: 1fr; }
  .timeline-row { grid-template-columns: 1fr; }
  .timeline-row em { text-align: left; }
}
