/* ==========================================================================
   Backlogrs Cursos — design system
   Reaproveita a identidade visual de backlogrs.ao (mesmas cores e fontes)
   para que a plataforma de cursos pareça parte da mesma marca, não um
   produto à parte.
   ========================================================================== */

:root {
  --ink: #090f1f;
  --night: #070c19;
  --paper: #f3f1ea;
  --blue: #1658ff;
  --lime: #caff37;
  --muted: #707481;
  --white: #fff;
  --line: rgba(9, 15, 31, 0.1);
  --shadow: 0 20px 45px rgba(9, 15, 31, 0.08);
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: 'DM Sans', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  background: var(--paper);
  color: var(--ink);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3 {
  font-family: 'Manrope', sans-serif;
  font-weight: 800;
  line-height: 1.15;
  margin: 0 0 12px;
}

a { color: inherit; text-decoration: none; }

img { max-width: 100%; display: block; }

/* ---------- Header ---------- */

header.site-header {
  position: sticky;
  top: 0;
  z-index: 40;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 18px clamp(20px, 5vw, 56px);
  background: rgba(243, 241, 234, 0.88);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
}

.brand {
  display: flex;
  align-items: center;
  gap: 8px;
  width: max-content;
}

.brand-symbol {
  display: flex;
  gap: 2px;
  height: 23px;
  width: 24px;
  transform: skew(-12deg);
  flex-shrink: 0;
}

.brand-symbol i {
  display: block;
  width: 6px;
  height: 100%;
  background: var(--lime);
}

.brand-symbol i:nth-child(2) { height: 74%; margin-top: 6px; }
.brand-symbol i:nth-child(3) { height: 48%; margin-top: 12px; }

.brand strong {
  font-family: 'Manrope', sans-serif;
  font-weight: 800;
  font-size: 20px;
  letter-spacing: -1px;
  color: var(--ink);
}

.brand strong span { color: var(--blue); }

.brand small {
  font-family: 'DM Sans', sans-serif;
  font-weight: 600;
  font-size: 11px;
  letter-spacing: 1px;
  text-transform: uppercase;
  color: var(--muted);
  border-left: 1px solid var(--line);
  margin-left: 2px;
  padding-left: 10px;
}

.header-nav {
  display: flex;
  align-items: center;
  gap: 22px;
  font-size: 14px;
  font-weight: 600;
}

.header-nav a.ghost {
  color: var(--muted);
}

.header-nav a.ghost:hover { color: var(--ink); }

/* ---------- Hero ---------- */

.hero {
  background: var(--night);
  color: var(--white);
  padding: clamp(48px, 8vw, 96px) clamp(20px, 5vw, 56px) clamp(56px, 9vw, 104px);
  position: relative;
  overflow: hidden;
}

.hero::after {
  content: '';
  position: absolute;
  right: -120px;
  top: -120px;
  width: 420px;
  height: 420px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(202, 255, 55, 0.18), transparent 70%);
  pointer-events: none;
}

.hero-inner {
  max-width: 780px;
  position: relative;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 1.2px;
  text-transform: uppercase;
  color: var(--lime);
  margin-bottom: 18px;
}

.eyebrow::before {
  content: '';
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--lime);
}

.hero h1 {
  font-size: clamp(30px, 5vw, 48px);
  color: var(--white);
  max-width: 14ch;
}

.hero h1 em {
  font-style: normal;
  color: var(--lime);
}

.hero p.lead {
  font-size: clamp(16px, 2vw, 19px);
  color: rgba(255, 255, 255, 0.72);
  max-width: 56ch;
  margin: 0 0 28px;
}

.hero-cta {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  background: var(--lime);
  color: var(--ink);
  font-weight: 700;
  font-size: 15px;
  padding: 14px 24px;
  border-radius: 999px;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.hero-cta:hover {
  transform: translateY(-2px);
  box-shadow: 0 14px 30px rgba(202, 255, 55, 0.25);
}

.tech-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 30px;
  position: relative;
}

.tech-chips span {
  font-size: 12.5px;
  font-weight: 600;
  color: rgba(255, 255, 255, 0.75);
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 999px;
  padding: 7px 14px;
  background: rgba(255, 255, 255, 0.04);
}

/* ---------- Learning track / roadmap ---------- */

.track {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
}

.track-item {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 20px;
  position: relative;
}

.track-item .track-num {
  font-family: 'Manrope', sans-serif;
  font-weight: 800;
  font-size: 13px;
  color: var(--blue);
  margin-bottom: 10px;
  display: block;
}

.track-item.locked .track-num { color: var(--muted); }

.track-item h4 {
  font-family: 'Manrope', sans-serif;
  font-weight: 700;
  font-size: 15px;
  margin: 0 0 8px;
}

.track-item p {
  font-size: 13px;
  color: var(--muted);
  margin: 0 0 14px;
}

.track-badge {
  display: inline-block;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.4px;
  text-transform: uppercase;
  padding: 4px 10px;
  border-radius: 999px;
}

.track-badge.live { background: rgba(22, 88, 255, 0.1); color: var(--blue); }
.track-badge.soon { background: rgba(9, 15, 31, 0.06); color: var(--muted); }

@media (max-width: 860px) {
  .track { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 520px) {
  .track { grid-template-columns: 1fr; }
}

/* ---------- Trust / client logos ---------- */

.trust-section {
  background: var(--white);
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  padding: 40px 0 46px;
}

.trust-head {
  text-align: center;
  max-width: 640px;
  margin: 0 auto 24px;
  padding: 0 20px;
}

.trust-head p {
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 1px;
  text-transform: uppercase;
  color: var(--muted);
  margin: 0;
}

.trust-scroller {
  position: relative;
  width: 100%;
  overflow: hidden;
  -webkit-mask-image: linear-gradient(to right, transparent 0, #000 64px, #000 calc(100% - 64px), transparent 100%);
  mask-image: linear-gradient(to right, transparent 0, #000 64px, #000 calc(100% - 64px), transparent 100%);
}

.trust-track {
  display: flex;
  align-items: center;
  gap: 22px;
  width: max-content;
  animation: trust-scroll 26s linear infinite;
}

.trust-scroller:hover .trust-track { animation-play-state: paused; }

.trust-card {
  flex: 0 0 auto;
  width: 168px;
  height: 84px;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 12px 16px;
}

.trust-card img {
  max-width: 100%;
  max-height: 48px;
  filter: grayscale(100%);
  opacity: 0.7;
}

@keyframes trust-scroll {
  from { transform: translateX(0); }
  to { transform: translateX(-50%); }
}

@media (prefers-reduced-motion: reduce) {
  .trust-track { animation: none; }
  .trust-scroller { overflow-x: auto; }
}

/* ---------- Sections / catalog ---------- */

main.page {
  max-width: 1120px;
  margin: 0 auto;
  padding: clamp(44px, 6vw, 72px) clamp(20px, 5vw, 56px) 90px;
}

.section-head {
  max-width: 640px;
  margin: 0 0 36px;
}

.section-head p.kicker {
  color: var(--muted);
  font-size: 15px;
  margin: 0;
}

.courses-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 24px;
}

.course-card {
  background: var(--white);
  border-radius: 20px;
  overflow: hidden;
  border: 1px solid var(--line);
  box-shadow: var(--shadow);
  display: flex;
  flex-direction: column;
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.course-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 28px 55px rgba(9, 15, 31, 0.14);
}

.course-thumb {
  height: 148px;
  background: linear-gradient(135deg, var(--blue), #0c2f8f 55%, var(--ink));
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

.course-thumb::before {
  content: '';
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 20% 20%, rgba(202, 255, 55, 0.35), transparent 45%),
    radial-gradient(circle at 85% 80%, rgba(255, 255, 255, 0.12), transparent 40%);
}

.course-thumb .mono {
  position: relative;
  font-family: 'Manrope', sans-serif;
  font-weight: 800;
  font-size: 34px;
  color: var(--white);
  letter-spacing: 1px;
}

.course-body {
  padding: 22px 22px 24px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  flex: 1;
}

.course-tag {
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.6px;
  text-transform: uppercase;
  color: var(--blue);
}

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

.course-desc {
  color: var(--muted);
  font-size: 14.5px;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
  margin: 0;
  flex: 1;
}

.course-meta {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13.5px;
  color: var(--ink);
  margin-top: 4px;
}

.avatar {
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: var(--ink);
  color: var(--white);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 11px;
  font-weight: 700;
  flex-shrink: 0;
}

.course-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 14px;
  padding-top: 16px;
  border-top: 1px solid var(--line);
}

.price-tag {
  font-family: 'Manrope', sans-serif;
  font-weight: 800;
  font-size: 19px;
  color: var(--ink);
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-family: inherit;
  font-weight: 700;
  font-size: 14.5px;
  border-radius: 999px;
  padding: 12px 20px;
  border: none;
  cursor: pointer;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.btn-primary {
  background: var(--blue);
  color: var(--white);
}

.btn-primary:hover { transform: translateY(-1px); box-shadow: 0 12px 24px rgba(22, 88, 255, 0.28); }

.btn-block { width: 100%; }

.btn-secondary {
  background: var(--white);
  color: var(--ink);
  border: 1px solid var(--line);
}

.btn-secondary:hover { border-color: var(--blue); color: var(--blue); }

.btn-sm { padding: 8px 14px; font-size: 13px; }

.btn:disabled { opacity: 0.55; cursor: not-allowed; transform: none !important; box-shadow: none !important; }

.empty-state {
  border: 1px dashed var(--line);
  border-radius: 16px;
  padding: 40px;
  text-align: center;
  color: var(--muted);
  background: var(--white);
}

/* ---------- Footer ---------- */

footer.site-footer {
  background: var(--night);
  color: rgba(255, 255, 255, 0.7);
  padding: 36px clamp(20px, 5vw, 56px);
  font-size: 13.5px;
}

footer.site-footer .footer-row {
  max-width: 1120px;
  margin: 0 auto;
  display: flex;
  flex-wrap: wrap;
  gap: 12px 24px;
  align-items: center;
  justify-content: space-between;
}

footer.site-footer a.ghost {
  color: rgba(255, 255, 255, 0.85);
  font-weight: 600;
}

footer.site-footer .fine-print {
  max-width: 1120px;
  margin: 18px auto 0;
  padding-top: 18px;
  border-top: 1px solid rgba(255, 255, 255, 0.12);
  color: rgba(255, 255, 255, 0.5);
  font-size: 12.5px;
  line-height: 1.6;
}

/* ---------- Course / checkout page ---------- */

.breadcrumb {
  font-size: 13.5px;
  color: var(--muted);
  margin-bottom: 18px;
}

.breadcrumb a:hover { color: var(--blue); }

.course-layout {
  display: grid;
  grid-template-columns: 1.6fr 1fr;
  gap: 32px;
  align-items: start;
}

.course-main h1 {
  font-size: clamp(24px, 3.4vw, 32px);
  max-width: 22ch;
}

.course-main .lead {
  color: var(--muted);
  font-size: 16px;
  max-width: 62ch;
}

.instructor-row {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 18px 0 26px;
  font-size: 14.5px;
}

.instructor-row .avatar { width: 34px; height: 34px; font-size: 13px; }

.panel {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: 18px;
  padding: 26px;
  margin-bottom: 22px;
}

.panel h2 {
  font-size: 17px;
}

.includes-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.includes-list li {
  display: flex;
  gap: 10px;
  font-size: 14.5px;
  color: var(--ink);
}

.includes-list li::before {
  content: '✓';
  color: var(--blue);
  font-weight: 700;
  flex-shrink: 0;
}

/* Stepper */

.stepper {
  display: flex;
  gap: 8px;
  margin-bottom: 22px;
}

.stepper .step {
  flex: 1;
  text-align: center;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.3px;
  text-transform: uppercase;
  color: var(--muted);
  padding-bottom: 10px;
  border-bottom: 3px solid var(--line);
  transition: color 0.2s ease, border-color 0.2s ease;
}

.stepper .step.active,
.stepper .step.done {
  color: var(--ink);
  border-color: var(--blue);
}

.stepper .step.done { color: var(--blue); }

/* Sticky purchase card */

.purchase-card {
  position: sticky;
  top: 96px;
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: 20px;
  padding: 26px;
  box-shadow: var(--shadow);
}

.purchase-card .price-big {
  font-family: 'Manrope', sans-serif;
  font-weight: 800;
  font-size: 30px;
  margin-bottom: 4px;
}

.purchase-card .price-note {
  color: var(--muted);
  font-size: 13px;
  margin-bottom: 20px;
}

.field { margin-bottom: 16px; }

.field label {
  display: block;
  font-size: 13.5px;
  font-weight: 600;
  margin-bottom: 6px;
  color: var(--ink);
}

.field input,
.field select {
  width: 100%;
  padding: 12px 14px;
  border: 1px solid var(--line);
  border-radius: 10px;
  font-size: 14.5px;
  font-family: inherit;
  background: var(--paper);
  color: var(--ink);
}

.field input:focus,
.field select:focus {
  outline: none;
  border-color: var(--blue);
  background: var(--white);
}

.status-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 12px;
  border-radius: 999px;
  font-size: 12.5px;
  font-weight: 700;
}

.status-pending_payment { background: rgba(202, 255, 55, 0.25); color: #5c6b00; }
.status-paid { background: rgba(22, 88, 255, 0.12); color: var(--blue); }
.status-completed { background: rgba(9, 15, 31, 0.08); color: var(--ink); }

.payment-instructions {
  background: var(--paper);
  border-radius: 12px;
  padding: 16px;
  font-size: 14px;
  line-height: 1.6;
  margin: 14px 0;
}

.payment-instructions strong { color: var(--blue); }

.notice {
  font-size: 13px;
  color: var(--muted);
  border-left: 3px solid var(--line);
  padding-left: 12px;
  margin: 16px 0;
}

@media (max-width: 860px) {
  .course-layout {
    grid-template-columns: 1fr;
  }
  .purchase-card {
    position: static;
    order: -1;
  }
}

/* ---------- Admin ---------- */

.admin-shell {
  max-width: 1120px;
  margin: 0 auto;
  padding: clamp(32px, 5vw, 56px) clamp(20px, 5vw, 56px) 90px;
}

table.data-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 13.5px;
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: 14px;
  overflow: hidden;
}

table.data-table th,
table.data-table td {
  text-align: left;
  padding: 12px 14px;
  border-bottom: 1px solid var(--line);
}

table.data-table th {
  background: var(--paper);
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: var(--muted);
}

table.data-table tr:last-child td { border-bottom: none; }
