/* ============================================================
   DESIGN TOKENS
============================================================ */
:root {
  --green-900: #052e16;
  --green-800: #14532d;
  --green-700: #15803d;
  --green-600: #16a34a;
  --green-500: #22c55e;
  --green-400: #4ade80;
  --green-300: #86efac;
  --theme-transition: 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 16px;
  --radius-xl: 20px;
  --nav-h: 60px;
}

/* ============================================================
   DARK THEME
============================================================ */
[data-theme="dark"] {
  --bg-base: #060a07;
  --bg-surface: #0a1009;
  --bg-card: rgba(11, 18, 12, 0.88);
  --bg-card-hover: rgba(16, 26, 17, 0.96);
  --bg-glass: rgba(6, 10, 7, 0.75);
  --bg-overlay: rgba(0, 0, 0, 0.68);
  --bg-input: rgba(8, 14, 9, 0.95);

  --border: rgba(34, 197, 94, 0.1);
  --border-mid: rgba(34, 197, 94, 0.22);
  --border-bright: rgba(34, 197, 94, 0.42);
  --border-focus: rgba(34, 197, 94, 0.68);

  --text-primary: #dff0e1;
  --text-secondary: #8fad93;
  --text-muted: #455e47;
  --text-dim: #2d3d2e;

  --accent: #22c55e;
  --accent-hover: #16a34a;
  --accent-glow: rgba(34, 197, 94, 0.14);
  --accent-glow-md: rgba(34, 197, 94, 0.22);
  --accent-glow-lg: rgba(34, 197, 94, 0.32);
  --accent-dark: #15803d;

  --nav-bg: rgba(6, 10, 7, 0.9);
  --shadow-card:
    0 4px 24px rgba(0, 0, 0, 0.55), 0 0 0 1px rgba(34, 197, 94, 0.06);
  --shadow-card-hover:
    0 12px 40px rgba(0, 0, 0, 0.7), 0 0 0 1px rgba(34, 197, 94, 0.18);
  --shadow-glow: 0 0 32px rgba(34, 197, 94, 0.18);

  --badge-beginner: rgba(5, 46, 22, 0.9);
  --badge-beginner-txt: #4ade80;
  --badge-inter: rgba(28, 25, 23, 0.9);
  --badge-inter-txt: #fb923c;
  --badge-advanced: rgba(12, 10, 9, 0.9);
  --badge-advanced-txt: #f87171;
}

/* ============================================================
   LIGHT THEME
============================================================ */
[data-theme="light"] {
  --bg-base: #f2faf4;
  --bg-surface: #e7f4ea;
  --bg-card: rgba(255, 255, 255, 0.9);
  --bg-card-hover: rgba(255, 255, 255, 0.99);
  --bg-glass: rgba(242, 250, 244, 0.85);
  --bg-overlay: rgba(5, 46, 22, 0.55);
  --bg-input: #fff;

  --border: rgba(21, 128, 61, 0.14);
  --border-mid: rgba(21, 128, 61, 0.28);
  --border-bright: rgba(21, 128, 61, 0.45);
  --border-focus: rgba(21, 128, 61, 0.72);

  --text-primary: #052e16;
  --text-secondary: #166534;
  --text-muted: #4a7a55;
  --text-dim: #9bbfa3;

  --accent: #15803d;
  --accent-hover: #14532d;
  --accent-glow: rgba(21, 128, 61, 0.12);
  --accent-glow-md: rgba(21, 128, 61, 0.18);
  --accent-glow-lg: rgba(21, 128, 61, 0.28);
  --accent-dark: #14532d;

  --nav-bg: rgba(242, 250, 244, 0.92);
  --shadow-card:
    0 2px 16px rgba(5, 46, 22, 0.08), 0 0 0 1px rgba(21, 128, 61, 0.08);
  --shadow-card-hover:
    0 8px 32px rgba(5, 46, 22, 0.14), 0 0 0 1px rgba(21, 128, 61, 0.2);
  --shadow-glow: 0 0 32px rgba(21, 128, 61, 0.14);

  --badge-beginner: #dcfce7;
  --badge-beginner-txt: #14532d;
  --badge-inter: #fff7ed;
  --badge-inter-txt: #9a3412;
  --badge-advanced: #fef2f2;
  --badge-advanced-txt: #991b1b;
}

/* ============================================================
   RESET & BASE
============================================================ */
*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
  font-size: 16px;
  -webkit-text-size-adjust: 100%;
}

body {
  font-family: "DM Sans", sans-serif;
  background-color: var(--bg-base);
  color: var(--text-primary);
  transition:
    background-color var(--theme-transition),
    color var(--theme-transition);
  overflow-x: hidden;
  line-height: 1.6;
  /* Ensure body starts below fixed nav on mobile */
  padding-top: 0;
}

::selection {
  background: var(--accent);
  color: #fff;
}
a {
  color: inherit;
  text-decoration: none;
}
img {
  display: block;
  max-width: 100%;
}
button {
  cursor: pointer;
  font-family: inherit;
}

h1,
h2,
h3,
h4 {
  font-family: "Exo 2", sans-serif;
  line-height: 1.15;
  letter-spacing: -0.02em;
}

/* ============================================================
   LAYOUT
============================================================ */
.container {
  width: 100%;
  max-width: 1400px;
  margin: 0 auto;
  padding: 0 1rem;
}

@media (min-width: 640px) {
  .container {
    padding: 0 1.5rem;
  }
}
@media (min-width: 1024px) {
  .container {
    padding: 0 2rem;
  }
}

.section {
  padding: 4rem 0;
}
@media (min-width: 768px) {
  .section {
    padding: 6rem 0;
  }
}

.section-header {
  text-align: center;
  margin-bottom: 2.5rem;
}
@media (min-width: 768px) {
  .section-header {
    margin-bottom: 3.5rem;
  }
}

.section-tag {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-family: "Exo 2", sans-serif;
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 0.75rem;
}
.section-tag::before,
.section-tag::after {
  content: "";
  display: block;
  height: 1px;
  width: 22px;
  background: var(--accent);
  opacity: 0.45;
}

.section-title {
  font-size: clamp(1.6rem, 5vw, 3rem);
  font-weight: 800;
  color: var(--text-primary);
  margin-bottom: 0.75rem;
}

.section-desc {
  font-size: clamp(0.88rem, 2.5vw, 1rem);
  color: var(--text-muted);
  max-width: 520px;
  margin: 0 auto;
  font-weight: 300;
  line-height: 1.7;
}

/* ============================================================
   NAVIGATION — mobile-first
============================================================ */
#main-nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  height: var(--nav-h);
  display: flex;
  align-items: center;
  padding: 0 1rem;
  background: var(--nav-bg);
  backdrop-filter: blur(20px) saturate(160%);
  -webkit-backdrop-filter: blur(20px) saturate(160%);
  border-bottom: 1px solid var(--border);
  transition:
    background var(--theme-transition),
    border-color var(--theme-transition);
}

@media (min-width: 640px) {
  #main-nav {
    padding: 0 1.5rem;
  }
}

.nav-inner {
  width: 100%;
  max-width: 1400px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
}

.nav-logo {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  flex-shrink: 0;
  transition: opacity 0.2s;
}
.nav-logo:hover {
  opacity: 0.8;
}

.nav-logo img {
  height: 36px;
  width: auto;
  object-fit: contain;
}

/* Logo text hidden on mobile, visible ≥540px */
.nav-logo-text {
  display: none;
}

@media (min-width: 540px) {
  .nav-logo-text {
    display: block;
    font-family: "Exo 2", sans-serif;
    font-weight: 900;
    font-size: 0.92rem;
    color: var(--text-primary);
    letter-spacing: 0.01em;
    white-space: nowrap;
  }
  .nav-logo-text span {
    color: var(--accent);
  }
}

/* Nav links: hidden on mobile, visible ≥1024px */
.nav-links {
  display: none;
  list-style: none;
  gap: 1.75rem;
}
@media (min-width: 1024px) {
  .nav-links {
    display: flex;
  }
}

.nav-links a {
  font-size: 0.86rem;
  font-weight: 500;
  color: var(--text-secondary);
  transition: color 0.2s;
  position: relative;
  padding-bottom: 2px;
}
.nav-links a::after {
  content: "";
  position: absolute;
  left: 0;
  right: 100%;
  bottom: -2px;
  height: 2px;
  background: var(--accent);
  transition: right 0.28s ease;
  border-radius: 1px;
}
.nav-links a:hover {
  color: var(--accent);
}
.nav-links a:hover::after {
  right: 0;
}

.nav-controls {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

/* Enrolled badge: hidden below 480px */
.enrolled-badge {
  display: none;
  align-items: center;
  gap: 0.35rem;
  background: var(--accent-glow);
  border: 1px solid var(--border-bright);
  color: var(--accent);
  font-size: 0.72rem;
  font-weight: 600;
  font-family: "Exo 2", sans-serif;
  padding: 0.28rem 0.65rem;
  border-radius: 100px;
  white-space: nowrap;
}
@media (min-width: 480px) {
  .enrolled-badge {
    display: flex;
  }
}

.enrolled-badge.bump {
  animation: bump 0.35s ease;
}
@keyframes bump {
  0% {
    transform: scale(1);
  }
  50% {
    transform: scale(1.2);
  }
  100% {
    transform: scale(1);
  }
}
.enrolled-count {
  font-weight: 800;
  font-size: 0.85rem;
}

/* Icon buttons — 44px tap target */
.icon-btn {
  min-width: 44px;
  min-height: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--border-mid);
  background: transparent;
  color: var(--text-secondary);
  border-radius: var(--radius-sm);
  transition:
    background 0.2s,
    border-color 0.2s,
    color 0.2s;
  flex-shrink: 0;
}
.icon-btn:hover {
  background: var(--accent-glow);
  border-color: var(--border-bright);
  color: var(--accent);
}

/* Mobile menu button: visible by default */
#mobile-menu-btn {
  display: flex;
}
@media (min-width: 768px) {
  #mobile-menu-btn {
    display: none !important;
  }
}

/* Nav CTA: hidden on mobile */
.nav-cta {
  display: none !important;
}
@media (min-width: 768px) {
  .nav-cta {
    display: inline-flex !important;
  }
}

/* Primary button */
.btn-primary {
  min-height: 44px;
  padding: 0 1.4rem;
  background: var(--accent);
  color: #fff;
  font-family: "Exo 2", sans-serif;
  font-weight: 700;
  font-size: 0.86rem;
  letter-spacing: 0.03em;
  border: none;
  border-radius: var(--radius-sm);
  transition:
    background 0.2s,
    transform 0.18s,
    box-shadow 0.2s;
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  white-space: nowrap;
}
.btn-primary:hover {
  background: var(--accent-hover);
  transform: translateY(-1px);
  box-shadow: 0 6px 20px var(--accent-glow-md);
}
.btn-primary:active {
  transform: translateY(0);
}

/* Outline button */
.btn-outline {
  min-height: 44px;
  padding: 0 1.4rem;
  background: transparent;
  color: #fff;
  font-family: "Exo 2", sans-serif;
  font-weight: 700;
  font-size: 0.86rem;
  letter-spacing: 0.03em;
  border: 1px solid rgba(255, 255, 255, 0.3);
  border-radius: var(--radius-sm);
  transition:
    background 0.2s,
    border-color 0.2s;
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  white-space: nowrap;
}
.btn-outline:hover {
  background: rgba(255, 255, 255, 0.09);
  border-color: rgba(255, 255, 255, 0.55);
}

/* ============================================================
   MOBILE MENU DRAWER
============================================================ */
.mobile-menu-overlay {
  position: fixed;
  inset: 0;
  z-index: 999;
  background: rgba(0, 0, 0, 0.72);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s;
}
.mobile-menu-overlay.open {
  opacity: 1;
  pointer-events: all;
}

.mobile-menu {
  position: fixed;
  top: 0;
  right: 0;
  height: 100%;
  width: min(300px, 82vw);
  background: var(--bg-surface);
  border-left: 1px solid var(--border-mid);
  z-index: 1000;
  padding: 0 0 2rem;
  display: flex;
  flex-direction: column;
  transform: translateX(100%);
  transition: transform 0.32s cubic-bezier(0.4, 0, 0.2, 1);
  overflow-y: auto;
}
.mobile-menu.open {
  transform: translateX(0);
}

.mobile-menu-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 1.25rem;
  height: var(--nav-h);
  border-bottom: 1px solid var(--border);
  flex-shrink: 0;
}

.mobile-menu-logo {
  font-family: "Exo 2", sans-serif;
  font-weight: 900;
  font-size: 0.88rem;
  color: var(--text-primary);
}
.mobile-menu-logo span {
  color: var(--accent);
}

.mobile-close-btn {
  min-width: 40px;
  min-height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: transparent;
  border: 1px solid var(--border-mid);
  border-radius: var(--radius-sm);
  color: var(--text-muted);
  transition:
    color 0.2s,
    border-color 0.2s;
}
.mobile-close-btn:hover {
  color: var(--accent);
  border-color: var(--border-bright);
}

.mobile-nav-links {
  display: flex;
  flex-direction: column;
  padding: 1rem 1.25rem 0;
  gap: 0.15rem;
}

.mobile-close-link {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  padding: 0.85rem 0.75rem;
  font-family: "Exo 2", sans-serif;
  font-size: 1rem;
  font-weight: 700;
  color: var(--text-secondary);
  border-radius: var(--radius-sm);
  transition:
    color 0.2s,
    background 0.2s;
}
.mobile-close-link:hover {
  color: var(--accent);
  background: var(--accent-glow);
}

.mobile-menu-divider {
  height: 1px;
  background: var(--border);
  margin: 0.75rem 1.25rem;
}

.mobile-apply-link {
  display: block;
  margin: 0.5rem 1.25rem 0;
  padding: 0.9rem 1.1rem;
  background: var(--accent);
  color: #fff !important;
  font-family: "Exo 2", sans-serif;
  font-size: 0.9rem;
  font-weight: 700;
  border-radius: var(--radius-sm);
  text-align: center;
  transition: background 0.2s;
}
.mobile-apply-link:hover {
  background: var(--accent-hover);
}

/* ============================================================
   MOTION PAUSE BUTTON
============================================================ */
#motion-btn {
  position: fixed;
  bottom: 1.25rem;
  left: 1rem;
  z-index: 900;
  min-width: 44px;
  min-height: 44px;
  background: var(--bg-card);
  border: 1px solid var(--border-mid);
  color: var(--text-muted);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  transition:
    color 0.2s,
    border-color 0.2s,
    background 0.2s;
  box-shadow: var(--shadow-card);
}
#motion-btn:hover {
  color: var(--accent);
  border-color: var(--border-bright);
  background: var(--accent-glow);
}

/* ============================================================
   HERO — mobile-first
============================================================ */
.hero {
  position: relative;
  min-height: 100svh;
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  overflow: hidden;
  padding-top: var(--nav-h);
}

.hero-bg-fallback {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(
      ellipse 100% 70% at 15% 35%,
      rgba(21, 128, 61, 0.16) 0%,
      transparent 60%
    ),
    radial-gradient(
      ellipse 70% 90% at 85% 75%,
      rgba(5, 46, 22, 0.28) 0%,
      transparent 55%
    ),
    radial-gradient(
      ellipse 50% 50% at 50% 50%,
      rgba(34, 197, 94, 0.04) 0%,
      transparent 70%
    ),
    linear-gradient(160deg, #030705 0%, #040b05 50%, #060e07 100%);
  animation: bgPulse 9s ease-in-out infinite alternate;
  z-index: 0;
}

@keyframes bgPulse {
  from {
    filter: brightness(1);
  }
  to {
    filter: brightness(1.07);
  }
}

.hero-circuit {
  position: absolute;
  inset: 0;
  z-index: 1;
  opacity: 0.06;
  pointer-events: none;
}

#hero-video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: 2;
  opacity: 0;
  transition: opacity 1.4s ease;
}
#hero-video.loaded {
  opacity: 1;
}

.hero-overlay {
  position: absolute;
  inset: 0;
  background: var(--bg-overlay);
  backdrop-filter: blur(1px);
  z-index: 3;
}

.hero-content {
  position: relative;
  z-index: 4;
  text-align: center;
  max-width: 860px;
  width: 100%;
  padding: 0 1.25rem;
}

.hero-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  background: var(--accent-glow-md);
  border: 1px solid var(--border-bright);
  color: var(--accent);
  font-size: 0.65rem;
  font-family: "Exo 2", sans-serif;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  padding: 0.32rem 0.9rem;
  border-radius: 100px;
  margin-bottom: 1.25rem;
  opacity: 0;
  animation: fadeUp 0.7s 0.3s forwards;
}

.hero-title {
  font-size: clamp(2rem, 9vw, 5.5rem);
  font-weight: 900;
  color: #fff;
  margin-bottom: 0.4em;
  opacity: 0;
  animation: fadeUp 0.7s 0.5s forwards;
  line-height: 1.08;
}

.accent-word {
  color: var(--green-400);
  position: relative;
}
.accent-word::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: -4px;
  height: 3px;
  background: linear-gradient(90deg, var(--green-500), transparent);
  border-radius: 2px;
}

.hero-sub {
  font-size: clamp(0.88rem, 3vw, 1.15rem);
  color: rgba(255, 255, 255, 0.65);
  max-width: 540px;
  margin: 0 auto 2rem;
  font-weight: 300;
  opacity: 0;
  animation: fadeUp 0.7s 0.7s forwards;
  line-height: 1.7;
}

.hero-cta-group {
  display: flex;
  gap: 0.75rem;
  flex-wrap: wrap;
  justify-content: center;
  opacity: 0;
  animation: fadeUp 0.7s 0.9s forwards;
}

.hero-btn {
  height: 48px;
  padding: 0 1.6rem;
  font-size: 0.9rem;
}

.hero-scroll-hint {
  position: absolute;
  bottom: 1.75rem;
  left: 50%;
  transform: translateX(-50%);
  z-index: 4;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.35rem;
  opacity: 0;
  animation: fadeUp 0.7s 1.2s forwards;
}
.hero-scroll-hint span {
  font-size: 0.6rem;
  letter-spacing: 0.12em;
  color: rgba(255, 255, 255, 0.35);
  text-transform: uppercase;
  font-family: "Exo 2", sans-serif;
}
.scroll-mouse {
  width: 22px;
  height: 34px;
  border: 2px solid rgba(255, 255, 255, 0.2);
  border-radius: 11px;
  display: flex;
  justify-content: center;
  padding-top: 5px;
}
.scroll-wheel {
  width: 3px;
  height: 7px;
  background: var(--accent);
  border-radius: 2px;
  animation: scrollWheel 1.7s ease-in-out infinite;
}
@keyframes scrollWheel {
  0% {
    opacity: 1;
    transform: translateY(0);
  }
  100% {
    opacity: 0;
    transform: translateY(12px);
  }
}

/* ============================================================
   STATS BAR
============================================================ */
.stats-bar {
  background: var(--bg-surface);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  padding: 1.75rem 0;
}

.stats-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1.25rem;
}
@media (min-width: 480px) {
  .stats-grid {
    grid-template-columns: repeat(4, 1fr);
  }
}

.stat-item {
  text-align: center;
}
.stat-number {
  font-family: "Exo 2", sans-serif;
  font-size: clamp(1.6rem, 5vw, 2.4rem);
  font-weight: 900;
  color: var(--accent);
  line-height: 1;
}
.stat-label {
  font-size: 0.7rem;
  color: var(--text-muted);
  margin-top: 0.3rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-weight: 500;
}

/* ============================================================
   FILTER BAR
============================================================ */
.filter-bar {
  display: flex;
  flex-wrap: nowrap;
  gap: 0.5rem;
  justify-content: flex-start;
  margin-bottom: 2rem;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
  padding-bottom: 4px;
}
.filter-bar::-webkit-scrollbar {
  display: none;
}

@media (min-width: 640px) {
  .filter-bar {
    flex-wrap: wrap;
    justify-content: center;
    overflow-x: visible;
    margin-bottom: 2.75rem;
  }
}

.filter-btn {
  min-height: 40px;
  padding: 0 1.1rem;
  border: 1px solid var(--border-mid);
  background: transparent;
  color: var(--text-secondary);
  font-family: "Exo 2", sans-serif;
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  border-radius: var(--radius-sm);
  transition: all 0.2s;
  white-space: nowrap;
  flex-shrink: 0;
}
.filter-btn.active,
.filter-btn:hover {
  background: var(--accent-glow);
  border-color: var(--border-bright);
  color: var(--accent);
}
.filter-btn.active {
  background: var(--accent-glow-md);
  box-shadow: 0 0 0 1px var(--border-bright);
}

/* ============================================================
   SEARCH BAR
============================================================ */
.search-wrap {
  max-width: 440px;
  width: 100%;
  margin: 0 auto 1.75rem;
  position: relative;
}

.search-input {
  width: 100%;
  height: 48px;
  background: var(--bg-card);
  border: 1px solid var(--border-mid);
  border-radius: var(--radius-md);
  padding: 0 1rem 0 3rem;
  color: var(--text-primary);
  font-family: "DM Sans", sans-serif;
  font-size: 0.9rem;
  outline: none;
  -webkit-appearance: none;
  appearance: none;
  transition:
    border-color 0.2s,
    box-shadow 0.2s;
}
.search-input:focus {
  border-color: var(--border-bright);
  box-shadow: 0 0 0 3px var(--accent-glow);
}
.search-input::placeholder {
  color: var(--text-muted);
}

.search-icon {
  position: absolute;
  left: 1rem;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-muted);
  pointer-events: none;
}

/* ============================================================
   COURSE GRID
============================================================ */
.courses-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.25rem;
}
@media (min-width: 480px) {
  .courses-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}
@media (min-width: 900px) {
  .courses-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}
@media (min-width: 1280px) {
  .courses-grid {
    grid-template-columns: repeat(4, 1fr);
  }
}

/* ============================================================
   COURSE CARD — dark-mode polished
============================================================ */
.course-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  box-shadow: var(--shadow-card);
  transition:
    transform 0.32s cubic-bezier(0.34, 1.56, 0.64, 1),
    border-color 0.28s,
    box-shadow 0.28s,
    background 0.28s;
  /* Scroll-reveal state */
  opacity: 0;
  transform: translateY(28px);
  /* Prevent layout shift while loading */
  will-change: transform, opacity;
}

.course-card.is-visible {
  opacity: 1;
  transform: translateY(0);
  transition:
    opacity 0.55s ease,
    transform 0.55s cubic-bezier(0.34, 1.56, 0.64, 1),
    border-color 0.28s,
    box-shadow 0.28s,
    background 0.28s;
}

/* Touch devices: no hover lift (avoids sticky states) */
@media (hover: hover) {
  .course-card:hover {
    transform: translateY(-5px) scale(1.01);
    border-color: var(--border-bright);
    box-shadow: var(--shadow-card-hover), var(--shadow-glow);
    background: var(--bg-card-hover);
  }
}

.card-img-wrap {
  position: relative;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  background: var(--bg-surface);
}

/* Subtle green tint overlay for dark mode card images */
[data-theme="dark"] .card-img-wrap::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(
    to bottom,
    transparent 40%,
    rgba(6, 10, 7, 0.65) 100%
  );
  z-index: 2;
  pointer-events: none;
}

.card-img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
  z-index: 1;
}
@media (hover: hover) {
  .course-card:hover .card-img {
    transform: scale(1.06);
  }
}

.card-img-icon {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2.8rem;
  background: linear-gradient(135deg, var(--bg-surface), var(--bg-base));
  z-index: 0;
}

.card-duration-chip {
  position: absolute;
  bottom: 0.6rem;
  right: 0.6rem;
  background: rgba(0, 0, 0, 0.76);
  color: #fff;
  font-size: 0.66rem;
  font-weight: 600;
  font-family: "Exo 2", sans-serif;
  padding: 0.22rem 0.55rem;
  border-radius: 5px;
  backdrop-filter: blur(6px);
  letter-spacing: 0.05em;
  z-index: 3;
  border: 1px solid rgba(255, 255, 255, 0.08);
}

.card-body {
  padding: 1.1rem;
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
}

.card-top-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
}

.difficulty-badge {
  font-family: "Exo 2", sans-serif;
  font-size: 0.6rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 0.2rem 0.55rem;
  border-radius: 100px;
}
.badge-beginner {
  background: var(--badge-beginner);
  color: var(--badge-beginner-txt);
}
.badge-intermediate {
  background: var(--badge-inter);
  color: var(--badge-inter-txt);
}
.badge-advanced {
  background: var(--badge-advanced);
  color: var(--badge-advanced-txt);
}

.card-id {
  font-family: "Exo 2", sans-serif;
  font-size: 0.6rem;
  font-weight: 600;
  color: var(--text-dim);
  letter-spacing: 0.1em;
}

.card-title {
  font-family: "Exo 2", sans-serif;
  font-size: 0.98rem;
  font-weight: 700;
  color: var(--text-primary);
  line-height: 1.3;
}

.card-instructor {
  font-size: 0.75rem;
  color: var(--text-muted);
  display: flex;
  align-items: center;
  gap: 0.35rem;
}
.card-instructor svg {
  flex-shrink: 0;
}

.card-divider {
  height: 1px;
  background: var(--border);
  margin: 0.1rem 0;
}

.card-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  margin-top: auto;
  padding-top: 0.3rem;
}

.card-price {
  font-family: "Exo 2", sans-serif;
  font-weight: 800;
  font-size: 1rem;
  color: var(--accent);
  line-height: 1;
}
.card-price span {
  font-size: 0.62rem;
  font-weight: 400;
  color: var(--text-muted);
}

.register-btn {
  min-width: 90px;
  min-height: 38px;
  padding: 0 0.9rem;
  background: var(--accent);
  color: #fff;
  border: none;
  border-radius: var(--radius-sm);
  font-family: "Exo 2", sans-serif;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  transition:
    background 0.2s,
    transform 0.15s,
    box-shadow 0.2s;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.3rem;
  position: relative;
  overflow: hidden;
  white-space: nowrap;
}
.register-btn:hover:not(:disabled) {
  background: var(--accent-hover);
  transform: translateY(-1px);
  box-shadow: 0 4px 14px var(--accent-glow-md);
}
.register-btn:active:not(:disabled) {
  transform: translateY(0);
}
.register-btn.enrolled {
  background: var(--badge-beginner);
  color: var(--badge-beginner-txt);
  cursor: default;
  border: 1px solid rgba(74, 222, 128, 0.22);
}
[data-theme="light"] .register-btn.enrolled {
  background: #dcfce7;
  color: #14532d;
}

/* Ripple effect */
.btn-ripple {
  position: absolute;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.35);
  width: 0;
  height: 0;
  transform: translate(-50%, -50%);
  animation: ripple 0.5s linear;
  pointer-events: none;
}
@keyframes ripple {
  to {
    width: 200px;
    height: 200px;
    opacity: 0;
  }
}

/* Just-enrolled pulse */
@keyframes successPulse {
  0% {
    box-shadow:
      var(--shadow-card),
      0 0 0 0 rgba(34, 197, 94, 0.45);
  }
  70% {
    box-shadow:
      var(--shadow-card),
      0 0 0 18px rgba(34, 197, 94, 0);
  }
  100% {
    box-shadow: var(--shadow-card);
  }
}
.course-card.just-enrolled {
  animation: successPulse 0.7s ease-out;
}

/* ============================================================
   TOAST
============================================================ */
#toast-container {
  position: fixed;
  bottom: 1.25rem;
  right: 1rem;
  z-index: 9999;
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
  pointer-events: none;
  max-width: calc(100vw - 2rem);
}

.toast {
  display: flex;
  align-items: center;
  gap: 0.7rem;
  background: var(--bg-surface);
  border: 1px solid var(--border-bright);
  border-radius: var(--radius-md);
  padding: 0.85rem 1.1rem;
  min-width: 240px;
  max-width: 320px;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.38);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  animation: toastIn 0.38s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
  pointer-events: all;
}

/* Dark mode toast gets a subtle left accent bar */
[data-theme="dark"] .toast {
  border-left: 3px solid var(--accent);
}

.toast.dismiss {
  animation: toastOut 0.28s ease forwards;
}

@keyframes toastIn {
  from {
    opacity: 0;
    transform: translateX(50px) scale(0.92);
  }
  to {
    opacity: 1;
    transform: translateX(0) scale(1);
  }
}
@keyframes toastOut {
  from {
    opacity: 1;
    transform: translateX(0) scale(1);
  }
  to {
    opacity: 0;
    transform: translateX(50px) scale(0.92);
  }
}

.toast-icon {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: var(--accent-glow);
  color: var(--accent);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  font-size: 1rem;
}

.toast-text {
  flex: 1;
  min-width: 0;
}
.toast-title {
  font-family: "Exo 2", sans-serif;
  font-weight: 700;
  font-size: 0.8rem;
  color: var(--text-primary);
}
.toast-body {
  font-size: 0.72rem;
  color: var(--text-muted);
  margin-top: 0.1rem;
  line-height: 1.4;
}

/* ============================================================
   INTERNSHIP SECTION
============================================================ */
.internship-section {
  background: var(--bg-surface);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}

.internship-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.25rem;
}
@media (min-width: 600px) {
  .internship-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}
@media (min-width: 1100px) {
  .internship-grid {
    grid-template-columns: repeat(4, 1fr);
  }
}

.internship-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 1.35rem 1.25rem;
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  transition:
    border-color 0.28s,
    transform 0.28s,
    box-shadow 0.28s;
  opacity: 0;
  transform: translateY(22px);
}
.internship-card.is-visible {
  opacity: 1;
  transform: translateY(0);
  transition:
    opacity 0.55s ease,
    transform 0.55s ease,
    border-color 0.28s;
}
@media (hover: hover) {
  .internship-card:hover {
    border-color: var(--border-bright);
    transform: translateY(-4px);
    box-shadow: var(--shadow-glow);
  }
}

.internship-cat {
  font-family: "Exo 2", sans-serif;
  font-size: 0.62rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 0.5rem;
}

.internship-title {
  font-family: "Exo 2", sans-serif;
  font-size: 0.98rem;
  font-weight: 800;
  color: var(--text-primary);
  margin-bottom: 0.9rem;
  line-height: 1.3;
}

.internship-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.78rem;
}
.internship-table th {
  text-align: left;
  padding: 0.35rem 0.4rem;
  font-family: "Exo 2", sans-serif;
  font-size: 0.6rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-muted);
  border-bottom: 1px solid var(--border);
}
.internship-table td {
  padding: 0.45rem 0.4rem;
  border-bottom: 1px solid var(--border);
  color: var(--text-secondary);
  line-height: 1.4;
}
.internship-table td:last-child {
  font-family: "Exo 2", sans-serif;
  font-weight: 700;
  color: var(--accent);
  text-align: right;
  white-space: nowrap;
}
.internship-table tr:last-child td {
  border-bottom: none;
}

/* ============================================================
   ABOUT / CERTIFICATE SECTION
============================================================ */
.about-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 2.5rem;
  align-items: center;
}
@media (min-width: 768px) {
  .about-grid {
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
  }
}

.about-text h2 {
  font-size: clamp(1.5rem, 4vw, 2.4rem);
  font-weight: 800;
  color: var(--text-primary);
  margin-bottom: 1rem;
  line-height: 1.2;
}
.about-text p {
  color: var(--text-muted);
  font-size: 0.92rem;
  margin-bottom: 1rem;
  font-weight: 300;
  line-height: 1.7;
}

.cert-features {
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
  margin-top: 1.4rem;
}
.cert-feature {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  font-size: 0.88rem;
  color: var(--text-secondary);
}
.cert-feature-icon {
  width: 30px;
  height: 30px;
  border-radius: var(--radius-sm);
  background: var(--accent-glow);
  border: 1px solid var(--border-bright);
  color: var(--accent);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

/* Certificate visual card */
.cert-card-visual {
  background: var(--bg-card);
  border: 1px solid var(--border-bright);
  border-radius: var(--radius-xl);
  padding: 2rem 1.75rem;
  text-align: center;
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  box-shadow: var(--shadow-card);
  position: relative;
  overflow: hidden;
}

/* Glow blob behind cert card in dark mode */
[data-theme="dark"] .cert-card-visual::before {
  content: "";
  position: absolute;
  top: -30%;
  left: -20%;
  width: 70%;
  height: 70%;
  background: radial-gradient(
    ellipse,
    var(--accent-glow-md) 0%,
    transparent 70%
  );
  pointer-events: none;
}

.cert-logo-line {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
  margin-bottom: 1.25rem;
  flex-wrap: wrap;
}

.cert-partner-badge {
  background: var(--accent-glow);
  border: 1px solid var(--border-bright);
  color: var(--accent);
  font-family: "Exo 2", sans-serif;
  font-weight: 800;
  font-size: 0.8rem;
  padding: 0.35rem 0.9rem;
  border-radius: var(--radius-sm);
}
.cert-partner-badge--unipod {
  color: #38bdf8;
  border-color: rgba(56, 189, 248, 0.38);
  background: rgba(56, 189, 248, 0.07);
}

.cert-divider {
  height: 1px;
  background: linear-gradient(
    90deg,
    transparent,
    var(--border-bright),
    transparent
  );
  margin: 1.25rem 0;
}

.cert-seal {
  width: 72px;
  height: 72px;
  border-radius: 50%;
  border: 2px solid var(--border-bright);
  background: var(--accent-glow);
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 0.9rem;
  overflow: hidden;
}

.cert-title-text {
  font-family: "Exo 2", sans-serif;
  font-weight: 800;
  font-size: 1.05rem;
  color: var(--text-primary);
}
.cert-subtitle-text {
  font-size: 0.75rem;
  color: var(--text-muted);
  margin-top: 0.3rem;
  line-height: 1.5;
}

/* ============================================================
   CONTACT / FOOTER
============================================================ */
.contact-section {
  background: var(--bg-surface);
  border-top: 1px solid var(--border);
}

.contact-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 2rem;
}
@media (min-width: 600px) {
  .contact-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}
@media (min-width: 1024px) {
  .contact-grid {
    grid-template-columns: repeat(4, 1fr);
  }
}

.contact-col h4 {
  font-family: "Exo 2", sans-serif;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text-primary);
  margin-bottom: 1.1rem;
  padding-bottom: 0.55rem;
  border-bottom: 1px solid var(--border);
}

.contact-col ul {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
}
.contact-col ul li a {
  font-size: 0.82rem;
  color: var(--text-muted);
  transition: color 0.2s;
}
.contact-col ul li a:hover {
  color: var(--accent);
}

.contact-info-list {
  display: flex;
  flex-direction: column;
  gap: 0.7rem;
}
.contact-info-item {
  display: flex;
  align-items: flex-start;
  gap: 0.55rem;
  font-size: 0.82rem;
  color: var(--text-muted);
  line-height: 1.5;
}
.contact-info-item svg {
  flex-shrink: 0;
  color: var(--accent);
  margin-top: 2px;
}

.footer-bottom {
  margin-top: 2.5rem;
  padding-top: 1.75rem;
  border-top: 1px solid var(--border);
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  justify-content: space-between;
  align-items: center;
  font-size: 0.75rem;
  color: var(--text-muted);
}

.footer-links {
  display: flex;
  gap: 1.25rem;
}
.footer-bottom a {
  color: var(--text-muted);
  transition: color 0.2s;
}
.footer-bottom a:hover {
  color: var(--accent);
}

/* ============================================================
   EMPTY STATE
============================================================ */
.empty-state {
  grid-column: 1 / -1;
  text-align: center;
  padding: 3.5rem 1rem;
  color: var(--text-muted);
}
.empty-state .empty-icon {
  font-size: 2.5rem;
  margin-bottom: 1rem;
}
.empty-state h3 {
  font-family: "Exo 2", sans-serif;
  font-size: 1.1rem;
  color: var(--text-secondary);
  margin-bottom: 0.4rem;
}

/* ============================================================
   ANIMATIONS
============================================================ */
@keyframes fadeUp {
  from {
    opacity: 0;
    transform: translateY(18px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}
@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}
.spinner {
  width: 16px;
  height: 16px;
  border: 2px solid transparent;
  border-top-color: currentColor;
  border-radius: 50%;
  animation: spin 0.6s linear infinite;
}

/* ============================================================
   REDUCED MOTION
============================================================ */
@media (prefers-reduced-motion: reduce) {
  .course-card,
  .internship-card {
    opacity: 1;
    transform: none;
    transition: border-color 0.2s;
  }
  .hero-eyebrow,
  .hero-title,
  .hero-sub,
  .hero-cta-group,
  .hero-scroll-hint {
    opacity: 1;
    animation: none;
  }
  .hero-bg-fallback {
    animation: none;
  }
  .scroll-wheel {
    animation: none;
  }
}
