/* =============================================
   Electrosoft System — Production Stylesheet
   ============================================= */

:root {
  /* Brand */
  --brand-blue:    #0057B8;
  --brand-blue2:   #003F8A;
  --brand-blue3:   #E8F0FC;
  --brand-green:   #00A651;
  --brand-green2:  #007A3D;
  --brand-green3:  #E6F5EC;

  /* Neutrals */
  --white:       #FFFFFF;
  --gray-50:     #F9FAFB;
  --gray-100:    #F3F4F6;
  --gray-200:    #E5E7EB;
  --gray-300:    #D1D5DB;
  --gray-400:    #9CA3AF;
  --gray-500:    #6B7280;
  --gray-600:    #4B5563;
  --gray-700:    #374151;
  --gray-800:    #1F2937;
  --gray-900:    #111827;

  /* Semantic */
  --success:   #059669;
  --success-bg:#DCFCE7;
  --danger:    #DC2626;
  --danger-bg: #FEE2E2;
  --warning:   #D97706;
  --warning-bg:#FEF3C7;
  --info:      #0284C7;
  --info-bg:   #E0F2FE;

  /* Typography */
  --text:       var(--gray-800);
  --text-muted: var(--gray-500);
  --heading:    var(--gray-900);

  /* Shadows */
  --shadow-xs: 0 1px 2px rgba(0,0,0,.05);
  --shadow-sm: 0 1px 3px rgba(0,0,0,.08), 0 1px 2px rgba(0,0,0,.05);
  --shadow:    0 4px 16px rgba(0,0,0,.08);
  --shadow-md: 0 6px 24px rgba(0,0,0,.10);
  --shadow-lg: 0 12px 40px rgba(0,0,0,.12);
  --shadow-xl: 0 24px 64px rgba(0,0,0,.15);

  /* Radius */
  --r-xs:   4px;
  --r-sm:   8px;
  --r:      12px;
  --r-lg:   16px;
  --r-xl:   24px;
  --r-full: 9999px;

  /* Transitions */
  --t: .22s cubic-bezier(.4,0,.2,1);
  --t-slow: .4s cubic-bezier(.4,0,.2,1);

  --font: 'Inter', 'Segoe UI', system-ui, -apple-system, sans-serif;
}

/* ---- Reset ---- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; font-size: 16px; }
body { font-family: var(--font); color: var(--text); background: var(--gray-50); line-height: 1.6; -webkit-font-smoothing: antialiased; }
a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }
ul, ol { list-style: none; }
button { font-family: var(--font); }
input, select, textarea { font-family: var(--font); }

/* ---- Typography ---- */
h1,h2,h3,h4,h5 { line-height: 1.2; font-weight: 700; color: var(--heading); }
h1 { font-size: clamp(1.75rem, 4vw, 2.75rem); }
h2 { font-size: clamp(1.4rem, 3vw, 2rem); }
h3 { font-size: 1.15rem; }

/* ---- Layout ---- */
.container    { max-width: 1200px; margin: 0 auto; padding: 0 1.5rem; }
.container-md { max-width: 960px;  margin: 0 auto; padding: 0 1.5rem; }
.container-sm { max-width: 760px;  margin: 0 auto; padding: 0 1.5rem; }

/* ===========================
   NAVBAR
   =========================== */
.navbar {
  background: var(--white);
  border-bottom: 1px solid var(--gray-200);
  position: sticky; top: 0; z-index: 900;
  box-shadow: var(--shadow-sm);
}
.navbar-inner {
  display: flex; align-items: center; justify-content: space-between;
  height: 68px; padding: 0 1.5rem; max-width: 1200px; margin: 0 auto;
  gap: 1.5rem;
}
.navbar-brand { display: flex; align-items: center; flex-shrink: 0; }
.navbar-brand img { height: 48px; width: auto; object-fit: contain; }

.navbar-links { display: flex; align-items: center; gap: .25rem; }
.navbar-links a {
  padding: .5rem .85rem; border-radius: var(--r-sm);
  font-size: .9rem; font-weight: 500; color: var(--gray-600);
  transition: all var(--t);
}
.navbar-links a:hover { background: var(--gray-100); color: var(--brand-blue); }
.navbar-links a.active { color: var(--brand-blue); background: var(--brand-blue3); font-weight: 600; }

.navbar-actions { display: flex; align-items: center; gap: .75rem; flex-shrink: 0; }

.navbar-burger {
  display: none; flex-direction: column; gap: 5px;
  cursor: pointer; padding: 6px; border: none; background: none;
}
.navbar-burger span { width: 22px; height: 2px; background: var(--gray-700); border-radius: 2px; transition: var(--t); display: block; }

.mobile-menu {
  display: none; position: fixed; inset: 68px 0 0 0;
  background: var(--white); z-index: 800; overflow-y: auto;
  padding: 1rem 1.5rem; border-top: 1px solid var(--gray-200);
  transform: translateX(100%); transition: transform var(--t-slow);
}
.mobile-menu.open { transform: translateX(0); }
.mobile-menu a {
  display: flex; align-items: center; gap: .75rem;
  padding: .9rem 0; font-size: 1rem; font-weight: 500; color: var(--gray-700);
  border-bottom: 1px solid var(--gray-100);
}
.mobile-menu a:hover { color: var(--brand-blue); }

/* ===========================
   BUTTONS
   =========================== */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .5rem;
  padding: .65rem 1.5rem; border-radius: var(--r-sm);
  font-size: .9rem; font-weight: 600; cursor: pointer; border: none;
  transition: all var(--t); white-space: nowrap; line-height: 1;
}
.btn-primary {
  background: var(--brand-blue); color: var(--white);
  box-shadow: 0 2px 8px rgba(0,87,184,.3);
}
.btn-primary:hover { background: var(--brand-blue2); box-shadow: 0 4px 16px rgba(0,87,184,.4); transform: translateY(-1px); }

.btn-green {
  background: var(--brand-green); color: var(--white);
  box-shadow: 0 2px 8px rgba(0,166,81,.3);
}
.btn-green:hover { background: var(--brand-green2); box-shadow: 0 4px 16px rgba(0,166,81,.4); transform: translateY(-1px); }

.btn-outline {
  background: transparent; color: var(--brand-blue);
  border: 2px solid var(--brand-blue);
}
.btn-outline:hover { background: var(--brand-blue3); }

.btn-white {
  background: var(--white); color: var(--brand-blue); font-weight: 700;
  box-shadow: var(--shadow-md);
}
.btn-white:hover { box-shadow: var(--shadow-lg); transform: translateY(-1px); }

.btn-ghost { background: transparent; color: var(--gray-600); }
.btn-ghost:hover { background: var(--gray-100); color: var(--gray-800); }

.btn-danger { background: var(--danger); color: #fff; }
.btn-danger:hover { background: #b91c1c; }

.btn-sm  { padding: .45rem 1rem; font-size: .82rem; }
.btn-lg  { padding: .85rem 2rem; font-size: 1rem; }
.btn-xl  { padding: 1rem 2.5rem; font-size: 1.05rem; }
.btn-block { width: 100%; }
.btn-icon { padding: .5rem; width: 36px; height: 36px; }

/* ===========================
   HERO
   =========================== */
.hero {
  background: linear-gradient(135deg, #0a1628 0%, #0057B8 50%, #003F8A 100%);
  padding: 5rem 0 4rem; position: relative; overflow: hidden;
}
.hero::before {
  content: ''; position: absolute; inset: 0;
  background:
    radial-gradient(ellipse 80% 50% at 100% 0%, rgba(0,166,81,.18) 0%, transparent 60%),
    radial-gradient(ellipse 60% 40% at 0% 100%, rgba(0,87,184,.25) 0%, transparent 60%);
}
.hero::after {
  content: ''; position: absolute; inset: 0; opacity: .04;
  background-image: url("data:image/svg+xml,%3Csvg width='40' height='40' viewBox='0 0 40 40' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='%23fff' fill-opacity='1' fill-rule='evenodd'%3E%3Ccircle cx='3' cy='3' r='1.5'/%3E%3C/g%3E%3C/svg%3E");
}
.hero-inner { position: relative; z-index: 1; display: grid; grid-template-columns: 1fr 420px; gap: 4rem; align-items: center; }
.hero-content {}
.hero-eyebrow {
  display: inline-flex; align-items: center; gap: .5rem;
  background: rgba(255,255,255,.12); border: 1px solid rgba(255,255,255,.2);
  color: rgba(255,255,255,.9); padding: .35rem 1rem; border-radius: var(--r-full);
  font-size: .78rem; font-weight: 600; letter-spacing: .5px; text-transform: uppercase;
  margin-bottom: 1.25rem;
}
.hero h1 { color: var(--white); font-size: clamp(1.9rem, 4vw, 3rem); line-height: 1.15; margin-bottom: 1.1rem; }
.hero h1 .accent { color: #5BDFB0; }
.hero-desc { color: rgba(255,255,255,.75); font-size: 1.05rem; line-height: 1.7; margin-bottom: 2rem; max-width: 500px; }
.hero-cta { display: flex; gap: 1rem; flex-wrap: wrap; }

.hero-stats {
  display: flex; gap: 0; margin-top: 3rem; padding-top: 2rem;
  border-top: 1px solid rgba(255,255,255,.12);
}
.hero-stat { flex: 1; text-align: center; padding: 0 1rem; }
.hero-stat + .hero-stat { border-left: 1px solid rgba(255,255,255,.12); }
.hero-stat .num { font-size: 1.6rem; font-weight: 800; color: var(--white); }
.hero-stat .lbl { font-size: .75rem; color: rgba(255,255,255,.55); text-transform: uppercase; letter-spacing: .5px; margin-top: .2rem; }

.hero-card {
  background: var(--white); border-radius: var(--r-xl);
  box-shadow: var(--shadow-xl); overflow: hidden; position: relative;
}
.hero-card-img {
  aspect-ratio: 16/9; background: linear-gradient(135deg, var(--brand-blue3), var(--brand-green3));
  display: flex; align-items: center; justify-content: center; font-size: 5rem; overflow: hidden;
}
.hero-card-img img { width: 100%; height: 100%; object-fit: cover; }
.hero-card-body { padding: 1.5rem; }
.hero-card-body h4 { font-size: .95rem; margin-bottom: .35rem; }
.hero-card-meta { display: flex; align-items: center; justify-content: space-between; }
.hero-card-price { font-size: 1.25rem; font-weight: 800; color: var(--brand-blue); }
.hero-card-badge {
  position: absolute; top: 1rem; right: 1rem;
  background: var(--brand-green); color: #fff;
  padding: .3rem .8rem; border-radius: var(--r-full);
  font-size: .75rem; font-weight: 700;
}
.floating-badge {
  position: absolute; background: var(--white); border-radius: var(--r);
  box-shadow: var(--shadow-lg); padding: .75rem 1rem;
  display: flex; align-items: center; gap: .6rem;
  font-size: .82rem; font-weight: 600;
}
.floating-badge.b1 { bottom: 1.5rem; left: -1.5rem; }
.floating-badge.b2 { top: 1.5rem; right: -1.5rem; }
.floating-badge .dot { width: 8px; height: 8px; border-radius: 50%; flex-shrink: 0; }

/* ===========================
   SECTIONS
   =========================== */
.section { padding: 4rem 0; }
.section-sm { padding: 2.5rem 0; }
.section-lg { padding: 6rem 0; }

.section-head { margin-bottom: 2.5rem; }
.section-head.center { text-align: center; }
.section-head h2 { margin-bottom: .5rem; }
.section-head p { color: var(--text-muted); font-size: 1rem; max-width: 520px; }
.section-head.center p { margin: 0 auto; }

.eyebrow {
  display: inline-block; font-size: .73rem; font-weight: 700; letter-spacing: 1px;
  text-transform: uppercase; color: var(--brand-blue);
  margin-bottom: .5rem;
}
.eyebrow::before { content: '—  '; }
.eyebrow::after  { content: '  —'; }

/* ===========================
   CATEGORY PILLS
   =========================== */
.category-bar {
  background: var(--white); border-bottom: 1px solid var(--gray-200);
  position: sticky; top: 68px; z-index: 800; box-shadow: var(--shadow-xs);
}
.category-bar-inner {
  display: flex; align-items: center; gap: .5rem;
  overflow-x: auto; padding: .85rem 1.5rem; max-width: 1200px; margin: 0 auto;
  scrollbar-width: none;
}
.category-bar-inner::-webkit-scrollbar { display: none; }
.cat-pill {
  display: flex; align-items: center; gap: .4rem;
  padding: .45rem 1.1rem; border-radius: var(--r-full); white-space: nowrap;
  font-size: .82rem; font-weight: 600; cursor: pointer; border: 1.5px solid var(--gray-200);
  background: var(--white); color: var(--gray-600); transition: all var(--t);
  flex-shrink: 0;
}
.cat-pill:hover { border-color: var(--brand-blue); color: var(--brand-blue); background: var(--brand-blue3); }
.cat-pill.active { background: var(--brand-blue); color: var(--white); border-color: var(--brand-blue); }
.cat-pill .icon { font-size: .95rem; }

/* ===========================
   SEARCH / FILTER BAR
   =========================== */
.filter-row {
  display: flex; gap: .75rem; align-items: center; flex-wrap: wrap; margin-bottom: 2rem;
}
.search-box {
  position: relative; flex: 1; min-width: 220px;
}
.search-box input {
  width: 100%; padding: .7rem 1rem .7rem 2.75rem;
  border: 1.5px solid var(--gray-200); border-radius: var(--r-sm);
  font-size: .9rem; background: var(--white); transition: border-color var(--t);
}
.search-box input:focus { outline: none; border-color: var(--brand-blue); box-shadow: 0 0 0 3px rgba(0,87,184,.1); }
.search-box .search-ico { position: absolute; left: .85rem; top: 50%; transform: translateY(-50%); color: var(--gray-400); font-size: 1rem; pointer-events: none; }
.filter-select {
  padding: .7rem 1rem; border: 1.5px solid var(--gray-200); border-radius: var(--r-sm);
  font-size: .875rem; color: var(--text); background: var(--white); cursor: pointer;
  transition: border-color var(--t);
}
.filter-select:focus { outline: none; border-color: var(--brand-blue); }
.results-count { font-size: .875rem; color: var(--text-muted); white-space: nowrap; }

/* ===========================
   COURSE CARDS
   =========================== */
.courses-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(295px, 1fr));
  gap: 1.5rem;
}

.course-card {
  background: var(--white); border-radius: var(--r);
  border: 1px solid var(--gray-200); overflow: hidden;
  display: flex; flex-direction: column;
  transition: all var(--t); cursor: pointer;
}
.course-card:hover {
  border-color: var(--brand-blue);
  box-shadow: var(--shadow-lg);
  transform: translateY(-4px);
}
.course-card:hover .card-thumb img { transform: scale(1.04); }

.card-thumb {
  position: relative; aspect-ratio: 16/9; overflow: hidden;
  background: linear-gradient(135deg, var(--brand-blue3), #e0efff);
}
.card-thumb img { width: 100%; height: 100%; object-fit: cover; transition: transform .4s; }
.thumb-placeholder {
  width: 100%; height: 100%;
  display: flex; align-items: center; justify-content: center;
  font-size: 3.5rem;
  background: linear-gradient(135deg, var(--brand-blue3), var(--brand-green3));
}
.card-level {
  position: absolute; top: .7rem; left: .7rem;
  background: rgba(0,0,0,.55); backdrop-filter: blur(4px);
  color: #fff; padding: .2rem .65rem; border-radius: var(--r-full);
  font-size: .7rem; font-weight: 600; letter-spacing: .3px;
}
.card-bestseller {
  position: absolute; top: .7rem; right: .7rem;
  background: #F59E0B; color: #fff;
  padding: .2rem .65rem; border-radius: var(--r-full);
  font-size: .68rem; font-weight: 700; letter-spacing: .3px; text-transform: uppercase;
}

.card-body { padding: 1.1rem 1.2rem; flex: 1; display: flex; flex-direction: column; }
.card-cat {
  font-size: .7rem; font-weight: 700; text-transform: uppercase; letter-spacing: .6px;
  color: var(--brand-blue); margin-bottom: .4rem;
}
.card-title { font-size: .95rem; font-weight: 700; line-height: 1.35; margin-bottom: .5rem; color: var(--heading); flex: 1; }
.card-instructor { font-size: .78rem; color: var(--text-muted); margin-bottom: .6rem; }

.card-rating { display: flex; align-items: center; gap: .4rem; margin-bottom: .5rem; }
.stars-val { font-size: .8rem; font-weight: 700; color: #D97706; }
.stars { color: #F59E0B; font-size: .78rem; letter-spacing: -1px; }
.stars-count { font-size: .75rem; color: var(--text-muted); }

.card-meta { display: flex; gap: 1rem; font-size: .76rem; color: var(--text-muted); }
.card-meta span { display: flex; align-items: center; gap: .3rem; }

.card-footer {
  padding: .9rem 1.2rem; border-top: 1px solid var(--gray-100);
  display: flex; align-items: center; justify-content: space-between; gap: .75rem;
}
.price-block {}
.price-now { font-size: 1.2rem; font-weight: 800; color: var(--heading); }
.price-was { font-size: .8rem; color: var(--text-muted); text-decoration: line-through; margin-left: .35rem; }

/* ===========================
   COURSE DETAIL PAGE
   =========================== */

/* Dark hero header */
.cd-hero {
  background: linear-gradient(135deg, #0a1628 0%, #0d2244 60%, #0a1628 100%);
  position: relative; overflow: hidden;
}
.cd-hero::before {
  content: ''; position: absolute; inset: 0;
  background: radial-gradient(ellipse 70% 60% at 80% 50%, rgba(0,87,184,.2) 0%, transparent 70%);
}
.cd-hero-inner {
  position: relative; z-index: 1;
  display: grid; grid-template-columns: 1fr 370px; gap: 3rem;
  align-items: start; padding: 3rem 0 2.5rem;
}
.cd-hero-left { color: var(--white); }
.cd-breadcrumb { display: flex; align-items: center; gap: .4rem; font-size: .78rem; color: rgba(255,255,255,.5); margin-bottom: 1rem; flex-wrap: wrap; }
.cd-breadcrumb a { color: rgba(255,255,255,.6); transition: color var(--t); }
.cd-breadcrumb a:hover { color: var(--white); }
.cd-breadcrumb .sep { color: rgba(255,255,255,.3); }

.cd-title { font-size: clamp(1.35rem, 3vw, 1.9rem); color: var(--white); font-weight: 700; line-height: 1.25; margin-bottom: .85rem; }
.cd-subtitle { font-size: .95rem; color: rgba(255,255,255,.7); margin-bottom: 1.1rem; line-height: 1.6; }

.cd-badges { display: flex; gap: .6rem; flex-wrap: wrap; margin-bottom: 1.1rem; }
.cd-badge {
  display: inline-flex; align-items: center; gap: .35rem;
  background: rgba(255,255,255,.1); border: 1px solid rgba(255,255,255,.15);
  color: rgba(255,255,255,.8); padding: .28rem .75rem; border-radius: var(--r-full);
  font-size: .75rem; font-weight: 500;
}
.cd-badge.new { background: rgba(0,166,81,.25); border-color: rgba(0,166,81,.4); color: #6BFFB8; }

.cd-rating-row { display: flex; align-items: center; gap: .85rem; margin-bottom: .75rem; flex-wrap: wrap; }
.cd-rating-val { font-size: 1.1rem; font-weight: 800; color: #F59E0B; }
.cd-stars { color: #F59E0B; font-size: .9rem; }
.cd-rating-count { font-size: .82rem; color: rgba(255,255,255,.5); }
.cd-students { font-size: .82rem; color: rgba(255,255,255,.55); }
.cd-instructor-line { font-size: .83rem; color: rgba(255,255,255,.55); }
.cd-instructor-line strong { color: rgba(255,255,255,.8); }

/* Purchase card */
.pcard {
  background: var(--white); border-radius: var(--r-lg);
  box-shadow: var(--shadow-xl); overflow: hidden;
  position: sticky; top: 80px;
}
.pcard-media {
  aspect-ratio: 16/9; background: linear-gradient(135deg, var(--brand-blue), var(--brand-green));
  display: flex; align-items: center; justify-content: center;
  font-size: 4rem; position: relative; overflow: hidden;
}
.pcard-media img { width: 100%; height: 100%; object-fit: cover; }
.pcard-play {
  position: absolute; width: 60px; height: 60px;
  background: rgba(255,255,255,.95); border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-size: 1.5rem; box-shadow: var(--shadow-lg);
  transition: transform var(--t); cursor: pointer;
}
.pcard-play:hover { transform: scale(1.1); }

.pcard-body { padding: 1.35rem; }
.pcard-price-row { margin-bottom: 1rem; }
.pcard-price { font-size: 2rem; font-weight: 800; color: var(--heading); line-height: 1; }
.pcard-price-orig { font-size: .9rem; color: var(--text-muted); text-decoration: line-through; margin-left: .4rem; }
.pcard-discount { display: inline-block; background: #DCFCE7; color: var(--success); padding: .2rem .6rem; border-radius: var(--r-full); font-size: .72rem; font-weight: 700; margin-top: .35rem; }
.pcard-timer { font-size: .78rem; color: var(--danger); font-weight: 600; margin-top: .35rem; }

/* Coupon section in pcard */
.coupon-section { margin: .9rem 0; }
.coupon-label { font-size: .78rem; font-weight: 700; color: var(--gray-600); margin-bottom: .4rem; display: flex; align-items: center; gap: .35rem; }
.coupon-row { display: flex; gap: .4rem; }
.coupon-input {
  flex: 1; padding: .65rem .9rem; border: 1.5px solid var(--gray-200);
  border-radius: var(--r-sm); font-size: .875rem; text-transform: uppercase; letter-spacing: 1px;
  transition: border-color var(--t);
}
.coupon-input:focus { outline: none; border-color: var(--brand-blue); box-shadow: 0 0 0 3px rgba(0,87,184,.1); }
.coupon-applied {
  background: var(--success-bg); border: 1px solid #A7F3D0;
  border-radius: var(--r-sm); padding: .65rem 1rem;
  display: flex; align-items: center; justify-content: space-between; margin-top: .5rem;
}
.coupon-applied-text { font-size: .82rem; color: var(--success); font-weight: 600; }
.coupon-remove { background: none; border: none; color: var(--danger); cursor: pointer; font-size: 1.1rem; font-weight: 700; padding: 0 .2rem; }
.coupon-msg { font-size: .78rem; margin-top: .35rem; }
.coupon-msg.err { color: var(--danger); }
.coupon-msg.ok  { color: var(--success); }

.pcard-enroll {
  width: 100%; padding: .95rem; border-radius: var(--r-sm);
  background: var(--brand-green); color: var(--white);
  border: none; font-size: 1rem; font-weight: 700; cursor: pointer;
  transition: all var(--t); display: flex; align-items: center; justify-content: center; gap: .5rem;
  box-shadow: 0 4px 16px rgba(0,166,81,.3);
}
.pcard-enroll:hover { background: var(--brand-green2); box-shadow: 0 6px 20px rgba(0,166,81,.4); transform: translateY(-1px); }

.pcard-guarantee { text-align: center; font-size: .75rem; color: var(--text-muted); margin-top: .65rem; }
.pcard-includes { margin-top: 1rem; border-top: 1px solid var(--gray-100); padding-top: 1rem; }
.pcard-includes h4 { font-size: .8rem; font-weight: 700; color: var(--gray-700); text-transform: uppercase; letter-spacing: .4px; margin-bottom: .6rem; }
.include-item { display: flex; align-items: center; gap: .55rem; font-size: .82rem; color: var(--text-muted); padding: .3rem 0; }
.include-item::before { content: '✓'; color: var(--brand-green); font-weight: 700; flex-shrink: 0; }

.pcard-share { margin-top: 1rem; padding-top: 1rem; border-top: 1px solid var(--gray-100); }
.pcard-share-label { font-size: .75rem; font-weight: 700; color: var(--gray-500); text-transform: uppercase; letter-spacing: .4px; margin-bottom: .4rem; }
.share-url-box {
  background: var(--gray-50); border: 1px solid var(--gray-200); border-radius: var(--r-sm);
  padding: .55rem .85rem; font-size: .72rem; font-family: monospace;
  color: var(--brand-blue); word-break: break-all; cursor: pointer;
  position: relative; padding-right: 3.5rem;
}
.share-copy-btn {
  position: absolute; right: .4rem; top: 50%; transform: translateY(-50%);
  background: var(--brand-blue); color: #fff; border: none; border-radius: var(--r-xs);
  padding: .2rem .5rem; font-size: .68rem; cursor: pointer; font-weight: 600;
}

/* ===========================
   COURSE CONTENT AREA
   =========================== */
.cd-body { padding: 2.5rem 0; }
.cd-layout { display: grid; grid-template-columns: 1fr 370px; gap: 3rem; align-items: start; }
.cd-main {}
.cd-sidebar { position: sticky; top: 80px; }

/* ---- Tabs ---- */
.tabs-nav {
  display: flex; gap: 0; border-bottom: 2px solid var(--gray-200);
  overflow-x: auto; scrollbar-width: none; margin-bottom: 2rem;
}
.tabs-nav::-webkit-scrollbar { display: none; }
.tab-btn {
  padding: .85rem 1.35rem; font-size: .88rem; font-weight: 600;
  color: var(--text-muted); border: none; background: none; cursor: pointer;
  border-bottom: 2.5px solid transparent; margin-bottom: -2px;
  white-space: nowrap; transition: all var(--t);
}
.tab-btn:hover:not(.active) { color: var(--heading); background: var(--gray-50); }
.tab-btn.active { color: var(--brand-blue); border-bottom-color: var(--brand-blue); }

.tab-pane { display: none; }
.tab-pane.active { display: block; }

/* What you'll learn box */
.learn-box {
  border: 1px solid var(--gray-200); border-radius: var(--r);
  padding: 1.5rem; margin-bottom: 1.75rem;
}
.learn-box h3 { font-size: 1.05rem; margin-bottom: 1.1rem; }
.learn-grid { display: grid; grid-template-columns: 1fr 1fr; gap: .6rem .75rem; }
.learn-item {
  display: flex; align-items: flex-start; gap: .5rem; font-size: .875rem; color: var(--text);
}
.learn-item::before { content: '✓'; color: var(--brand-green); font-weight: 700; flex-shrink: 0; margin-top: .15rem; font-size: .8rem; }

/* Description */
.description-block { font-size: .92rem; line-height: 1.8; color: var(--gray-700); }
.description-block p { margin-bottom: .85rem; }

/* Curriculum */
.curriculum-summary { font-size: .85rem; color: var(--text-muted); margin-bottom: 1.25rem; display: flex; gap: 1.5rem; flex-wrap: wrap; }
.curriculum-summary strong { color: var(--text); }
.accordion { display: flex; flex-direction: column; gap: .5rem; }
.acc-item { border: 1px solid var(--gray-200); border-radius: var(--r-sm); overflow: hidden; }
.acc-header {
  display: flex; align-items: center; justify-content: space-between;
  padding: .9rem 1.15rem; cursor: pointer; background: var(--gray-50);
  transition: background var(--t); user-select: none;
}
.acc-header:hover { background: var(--gray-100); }
.acc-header-left { display: flex; align-items: center; gap: .6rem; font-weight: 600; font-size: .88rem; }
.acc-header-right { display: flex; align-items: center; gap: .75rem; font-size: .78rem; color: var(--text-muted); }
.acc-chevron { transition: transform var(--t); color: var(--text-muted); }
.acc-item.open .acc-chevron { transform: rotate(180deg); }
.acc-item.open .acc-header { background: var(--brand-blue3); color: var(--brand-blue); }
.acc-body { display: none; }
.acc-item.open .acc-body { display: block; }
.acc-lesson {
  display: flex; align-items: center; justify-content: space-between;
  padding: .7rem 1.15rem; border-top: 1px solid var(--gray-100);
  font-size: .84rem; color: var(--text-muted);
}
.acc-lesson:hover { background: var(--gray-50); }
.acc-lesson-left { display: flex; align-items: center; gap: .6rem; }
.acc-lesson-icon { color: var(--brand-blue); font-size: .9rem; }
.acc-lesson-time { font-size: .75rem; color: var(--gray-400); }

/* Requirements */
.req-list { display: flex; flex-direction: column; gap: .65rem; }
.req-item { display: flex; align-items: flex-start; gap: .6rem; font-size: .88rem; color: var(--text); }
.req-item::before { content: '●'; color: var(--brand-blue); flex-shrink: 0; font-size: .5rem; margin-top: .55rem; }

/* Instructor */
.instructor-card { display: flex; gap: 1.5rem; align-items: flex-start; flex-wrap: wrap; }
.instructor-avatar {
  width: 90px; height: 90px; border-radius: 50%; flex-shrink: 0;
  background: linear-gradient(135deg, var(--brand-blue), var(--brand-green));
  display: flex; align-items: center; justify-content: center;
  color: #fff; font-size: 2.2rem; font-weight: 700;
}
.instructor-info h3 { font-size: 1.1rem; margin-bottom: .15rem; }
.instructor-title { color: var(--brand-blue); font-size: .85rem; font-weight: 600; margin-bottom: .6rem; }
.instructor-stats { display: flex; gap: 1.5rem; flex-wrap: wrap; font-size: .82rem; color: var(--text-muted); margin-bottom: .75rem; }
.instructor-stats span { display: flex; align-items: center; gap: .3rem; }
.instructor-bio { font-size: .88rem; color: var(--gray-600); line-height: 1.7; }

/* ===========================
   STATS BANNER
   =========================== */
.stats-band { background: var(--brand-blue); padding: 2.5rem 0; }
.stats-band-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 2rem; text-align: center; }
.stats-band-item .n { font-size: 2rem; font-weight: 800; color: var(--white); }
.stats-band-item .l { font-size: .78rem; color: rgba(255,255,255,.6); text-transform: uppercase; letter-spacing: .5px; margin-top: .2rem; }

/* ===========================
   ADMIN LAYOUT
   =========================== */
.admin-wrap { display: flex; min-height: 100vh; }
.sidebar {
  width: 256px; background: var(--gray-900); flex-shrink: 0;
  position: fixed; top: 0; left: 0; height: 100vh;
  overflow-y: auto; display: flex; flex-direction: column;
  transition: transform var(--t-slow); z-index: 1000;
}
.sidebar-brand {
  padding: 1.25rem 1.25rem 1.1rem;
  border-bottom: 1px solid rgba(255,255,255,.07);
  display: flex; align-items: center; gap: .75rem;
}
.sidebar-brand img { height: 34px; width: auto; object-fit: contain; background: #fff; border-radius: 6px; padding: 3px 8px; }
.sidebar-brand-text { font-size: .72rem; color: rgba(255,255,255,.35); text-transform: uppercase; letter-spacing: .5px; }

.sidebar-nav { flex: 1; padding: .75rem 0; }
.sidebar-section-label {
  padding: .9rem 1.25rem .3rem; font-size: .65rem; color: rgba(255,255,255,.25);
  font-weight: 700; letter-spacing: 1.2px; text-transform: uppercase;
}
.sidebar-link {
  display: flex; align-items: center; gap: .75rem;
  padding: .7rem 1.25rem; color: rgba(255,255,255,.55);
  font-size: .875rem; font-weight: 500; border-left: 3px solid transparent;
  transition: all var(--t);
}
.sidebar-link:hover { color: var(--white); background: rgba(255,255,255,.06); }
.sidebar-link.active { color: var(--white); background: rgba(0,87,184,.35); border-left-color: var(--brand-blue); }
.sidebar-link .ico { font-size: 1rem; width: 20px; text-align: center; flex-shrink: 0; }

.sidebar-footer { padding: 1rem 1.25rem; border-top: 1px solid rgba(255,255,255,.07); font-size: .75rem; color: rgba(255,255,255,.3); }

.admin-main { flex: 1; margin-left: 256px; display: flex; flex-direction: column; }
.admin-topbar {
  background: var(--white); border-bottom: 1px solid var(--gray-200);
  padding: 0 2rem; height: 64px; display: flex; align-items: center;
  justify-content: space-between; position: sticky; top: 0; z-index: 500;
  box-shadow: var(--shadow-xs);
}
.admin-topbar-left { display: flex; align-items: center; gap: 1rem; }
.admin-topbar h2 { font-size: 1rem; font-weight: 700; color: var(--heading); }
.admin-topbar-right { display: flex; align-items: center; gap: .75rem; }
.admin-avatar {
  width: 34px; height: 34px; border-radius: 50%;
  background: linear-gradient(135deg, var(--brand-blue), var(--brand-green));
  color: #fff; display: flex; align-items: center; justify-content: center;
  font-weight: 700; font-size: .875rem;
}
.admin-username { font-size: .875rem; font-weight: 600; color: var(--gray-700); }
.admin-content { padding: 2rem; flex: 1; }

/* ===========================
   ADMIN CARDS/WIDGETS
   =========================== */
.stats-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 1.25rem; margin-bottom: 2rem; }
.stat-card {
  background: var(--white); border-radius: var(--r); border: 1px solid var(--gray-200);
  padding: 1.35rem 1.5rem; display: flex; align-items: center; gap: 1rem;
}
.stat-icon {
  width: 48px; height: 48px; border-radius: var(--r-sm);
  display: flex; align-items: center; justify-content: center;
  font-size: 1.35rem; flex-shrink: 0;
}
.si-blue  { background: var(--brand-blue3); }
.si-green { background: var(--brand-green3); }
.si-orange{ background: #FEF3C7; }
.si-red   { background: var(--danger-bg); }
.stat-val { font-size: 1.65rem; font-weight: 800; line-height: 1; color: var(--heading); }
.stat-label { font-size: .75rem; color: var(--text-muted); margin-top: .2rem; }

.panel {
  background: var(--white); border-radius: var(--r); border: 1px solid var(--gray-200);
  overflow: hidden;
}
.panel-head {
  padding: 1rem 1.35rem; border-bottom: 1px solid var(--gray-200);
  display: flex; align-items: center; justify-content: space-between;
}
.panel-head h3 { font-size: .95rem; font-weight: 700; }
.panel-body { padding: 1.35rem; }

/* ===========================
   TABLE
   =========================== */
.table-wrap { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; font-size: .875rem; }
thead th {
  padding: .75rem 1rem; font-size: .72rem; font-weight: 700;
  color: var(--text-muted); text-transform: uppercase; letter-spacing: .5px;
  text-align: left; background: var(--gray-50); white-space: nowrap;
  border-bottom: 1px solid var(--gray-200);
}
tbody td { padding: .85rem 1rem; border-bottom: 1px solid var(--gray-100); vertical-align: middle; }
tbody tr:last-child td { border-bottom: none; }
tbody tr:hover td { background: var(--gray-50); }
.td-actions { display: flex; gap: .4rem; align-items: center; }

/* ===========================
   FORMS
   =========================== */
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 1.25rem; }
.form-row { display: grid; grid-template-columns: 1fr; gap: 1.25rem; }
.fg { display: flex; flex-direction: column; gap: .4rem; }
.fg.full { grid-column: 1 / -1; }
.fg.span2 { grid-column: span 2; }
label.fl { font-size: .82rem; font-weight: 600; color: var(--gray-700); }
.req { color: var(--danger); }
.form-hint { font-size: .75rem; color: var(--text-muted); }

.fi {
  padding: .7rem 1rem; border: 1.5px solid var(--gray-200);
  border-radius: var(--r-sm); font-size: .875rem; color: var(--text);
  background: var(--white); transition: all var(--t); width: 100%;
}
.fi:focus { outline: none; border-color: var(--brand-blue); box-shadow: 0 0 0 3px rgba(0,87,184,.1); }
textarea.fi { resize: vertical; min-height: 90px; }

/* File upload */
.upload-zone {
  border: 2px dashed var(--gray-300); border-radius: var(--r);
  padding: 2rem; text-align: center; cursor: pointer;
  transition: all var(--t); background: var(--gray-50);
  position: relative;
}
.upload-zone:hover, .upload-zone.drag { border-color: var(--brand-blue); background: var(--brand-blue3); }
.upload-zone input[type=file] { position: absolute; inset: 0; opacity: 0; cursor: pointer; width: 100%; height: 100%; }
.upload-icon { font-size: 2.5rem; margin-bottom: .5rem; }
.upload-text { font-size: .875rem; color: var(--text-muted); }
.upload-text strong { color: var(--brand-blue); }
.upload-sub { font-size: .75rem; color: var(--gray-400); margin-top: .25rem; }
.upload-preview { width: 100%; max-height: 160px; object-fit: cover; border-radius: var(--r-sm); margin-top: .75rem; display: none; }

/* Checkbox toggle */
.toggle-wrap { display: flex; align-items: center; gap: .6rem; cursor: pointer; }
.toggle-wrap input[type=checkbox] { width: 18px; height: 18px; accent-color: var(--brand-blue); cursor: pointer; }
.toggle-label { font-size: .875rem; font-weight: 500; color: var(--gray-700); }

/* ===========================
   BADGES
   =========================== */
.badge {
  display: inline-block; padding: .2rem .6rem; border-radius: var(--r-full);
  font-size: .7rem; font-weight: 700; letter-spacing: .3px;
}
.badge-green  { background: var(--success-bg); color: var(--success); }
.badge-red    { background: var(--danger-bg);  color: var(--danger); }
.badge-yellow { background: var(--warning-bg); color: var(--warning); }
.badge-blue   { background: var(--brand-blue3); color: var(--brand-blue); }
.badge-gray   { background: var(--gray-100); color: var(--gray-600); }

/* ===========================
   ALERTS
   =========================== */
.alert {
  padding: .85rem 1.15rem; border-radius: var(--r-sm); font-size: .875rem;
  margin-bottom: 1.25rem; border: 1px solid transparent;
  display: flex; align-items: flex-start; gap: .6rem;
}
.alert-success { background: var(--success-bg); border-color: #A7F3D0; color: #065F46; }
.alert-danger  { background: var(--danger-bg);  border-color: #FECACA; color: #991B1B; }
.alert-info    { background: var(--info-bg);    border-color: #BAE6FD; color: #075985; }
.alert-warning { background: var(--warning-bg); border-color: #FDE68A; color: #92400E; }

/* ===========================
   LOGIN
   =========================== */
.login-page {
  min-height: 100vh; display: grid; place-items: center; padding: 2rem;
  background: linear-gradient(135deg, var(--gray-900) 0%, #0a1628 50%, var(--brand-blue2) 100%);
}
.login-card {
  background: var(--white); border-radius: var(--r-xl);
  box-shadow: var(--shadow-xl); padding: 2.5rem; width: 100%; max-width: 400px;
}
.login-logo { text-align: center; margin-bottom: 2rem; }
.login-logo img { height: 60px; margin: 0 auto .75rem; }
.login-logo h2 { font-size: 1.15rem; margin-bottom: .2rem; }
.login-logo p { font-size: .82rem; color: var(--text-muted); }

/* ===========================
   TOAST
   =========================== */
.toast-wrap { position: fixed; bottom: 1.5rem; right: 1.5rem; z-index: 9999; display: flex; flex-direction: column; gap: .5rem; }
.toast {
  background: var(--gray-800); color: var(--white);
  padding: .8rem 1.15rem; border-radius: var(--r-sm); box-shadow: var(--shadow-lg);
  font-size: .85rem; max-width: 300px; display: flex; align-items: center; gap: .65rem;
  animation: toastIn .3s ease; border-left: 4px solid var(--brand-blue);
}
.toast.ok  { border-left-color: var(--brand-green); }
.toast.err { border-left-color: var(--danger); }
@keyframes toastIn { from { transform: translateX(110%); opacity: 0; } to { transform: translateX(0); opacity: 1; } }

/* ===========================
   FOOTER
   =========================== */
.footer { background: var(--gray-900); color: rgba(255,255,255,.55); }
.footer-main { padding: 3.5rem 0 2rem; }
.footer-grid { display: grid; grid-template-columns: 2.5fr 1fr 1fr 1fr; gap: 2.5rem; }
.footer-brand img { height: 44px; margin-bottom: 1rem; background: #fff; border-radius: 8px; padding: 4px 10px; object-fit: contain; }
.footer-brand p { font-size: .85rem; line-height: 1.7; }
.footer-col h4 { font-size: .8rem; font-weight: 700; color: var(--white); text-transform: uppercase; letter-spacing: .6px; margin-bottom: .9rem; }
.footer-col a { display: block; font-size: .845rem; color: rgba(255,255,255,.5); margin-bottom: .45rem; transition: color var(--t); }
.footer-col a:hover { color: var(--white); }
.footer-bottom { border-top: 1px solid rgba(255,255,255,.07); padding: 1.25rem 0; display: flex; align-items: center; justify-content: space-between; font-size: .8rem; flex-wrap: wrap; gap: .5rem; }

/* ===========================
   UTILS
   =========================== */
.text-center { text-align: center; }
.text-muted  { color: var(--text-muted); }
.text-blue   { color: var(--brand-blue); }
.text-green  { color: var(--brand-green); }
.text-danger { color: var(--danger); }
.fw-700 { font-weight: 700; }
.mt-1 { margin-top: .5rem; }  .mt-2 { margin-top: 1rem; }
.mt-3 { margin-top: 1.5rem; } .mt-4 { margin-top: 2rem; }
.mb-1 { margin-bottom: .5rem; } .mb-2 { margin-bottom: 1rem; }
.mb-3 { margin-bottom: 1.5rem; } .mb-4 { margin-bottom: 2rem; }
.hidden { display: none !important; }

.empty-state { text-align: center; padding: 4rem 2rem; color: var(--text-muted); }
.empty-state .empty-ico { font-size: 3.5rem; margin-bottom: 1rem; }
.empty-state h3 { color: var(--heading); margin-bottom: .5rem; }

.spinner { width: 18px; height: 18px; border: 2px solid rgba(255,255,255,.3); border-top-color: #fff; border-radius: 50%; animation: spin .7s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }

.divider { border: none; border-top: 1px solid var(--gray-200); margin: 1.5rem 0; }

/* ===========================
   RESPONSIVE
   =========================== */
@media (max-width: 1100px) {
  .hero-inner { grid-template-columns: 1fr; }
  .hero-card { display: none; }
  .cd-hero-inner { grid-template-columns: 1fr; }
  .pcard { position: static; }
  .cd-layout { grid-template-columns: 1fr; }
  .cd-sidebar .pcard { display: none; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 900px) {
  .stats-band-grid { grid-template-columns: repeat(2, 1fr); }
  .cd-hero-inner .pcard { display: block; margin-top: 1.5rem; }
}

@media (max-width: 768px) {
  .navbar-links { display: none; }
  .navbar-actions .btn-text { display: none; }
  .navbar-burger { display: flex; }
  .hero { padding: 3.5rem 0 2.5rem; }
  .hero-stats { flex-wrap: wrap; gap: 0; }
  .hero-stat { min-width: 50%; border-left: none !important; padding: .75rem 1rem; }
  .hero-stat:nth-child(2n) { border-left: 1px solid rgba(255,255,255,.12) !important; }
  .form-grid { grid-template-columns: 1fr; }
  .fg.span2 { grid-column: 1; }
  .learn-grid { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr; }
  .admin-sidebar { transform: translateX(-100%); }
  .admin-sidebar.open { transform: translateX(0); }
  .admin-main { margin-left: 0; }
  .admin-content { padding: 1.25rem; }
  .stats-grid { grid-template-columns: repeat(2, 1fr); }
  .admin-topbar { padding: 0 1.25rem; }
  .sidebar { transform: translateX(-100%); }
  .sidebar.open { transform: translateX(0); }
  .admin-main { margin-left: 0 !important; }
}

@media (max-width: 580px) {
  .stats-band-grid { grid-template-columns: repeat(2, 1fr); gap: 1.25rem; }
  .hero-cta { flex-direction: column; }
  .hero-cta .btn { width: 100%; justify-content: center; }
  .courses-grid { grid-template-columns: 1fr; }
  .stats-grid { grid-template-columns: 1fr; }
  .filter-row { flex-direction: column; }
  .search-box { width: 100%; }
}
