/* ==========================================
   Algorithmics Omole - Course Details Styles
   ========================================== */

/* Note: Google Fonts (Poppins) is loaded non-blocking in each page's <head> */

:root {
  --purple: #6a11cb;
  --blue: #2575fc;
  --purple-light: #f0e6ff;
  --dark: #0d0d1a;
  --text: #2d2d3d;
  --muted: #6b7280;
  --card-bg: #fff;
  --gradient: linear-gradient(135deg, #6a11cb, #2575fc);
  --success: #059669;
  --error: #dc2626;
  --white: #ffffff;
}

*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: "Poppins", sans-serif;
  color: var(--text);
  background: #fafafa;
  overflow-x: hidden;
  padding-top: 80px; /* Offset for sticky navbar */
}

/* Navbar Style (matches landing page but simplified and consistent) */
.navbar {
  position: fixed;
  top: 0; left: 0; right: 0;
  background: rgba(255, 255, 255, 0.96);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid rgba(106, 17, 203, 0.08);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 40px;
  z-index: 9999;
  box-shadow: 0 4px 20px rgba(106, 17, 203, 0.05);
}
.nav-logo {
  height: 44px;
}
.nav-links {
  display: flex;
  gap: 32px;
  list-style: none;
}
.nav-links a {
  text-decoration: none;
  color: var(--text);
  font-weight: 500;
  font-size: 14px;
  transition: color 0.2s;
}
.nav-links a:hover {
  color: var(--purple);
}
.nav-cta {
  display: flex;
  gap: 12px;
  align-items: center;
}
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 22px;
  border-radius: 8px;
  font-family: inherit;
  font-weight: 600;
  font-size: 14px;
  cursor: pointer;
  text-decoration: none;
  border: none;
  transition: all 0.2s;
}
.btn-outline {
  background: transparent;
  border: 2px solid var(--purple);
  color: var(--purple);
}
.btn-outline:hover {
  background: var(--purple-light);
}
.btn-primary {
  background: var(--gradient);
  color: #fff;
  box-shadow: 0 4px 14px rgba(106, 17, 203, 0.3);
}
.btn-primary:hover {
  transform: translateY(-1px);
  box-shadow: 0 6px 20px rgba(106, 17, 203, 0.4);
}
.hamburger {
  display: none;
  flex-direction: column;
  gap: 5px;
  cursor: pointer;
  background: none;
  border: none;
  padding: 4px;
}
.hamburger span {
  width: 24px;
  height: 2px;
  background: var(--purple);
  border-radius: 2px;
  transition: all 0.3s;
}

/* Course Page Hero Section */
.course-hero {
  background: var(--gradient);
  color: var(--white);
  padding: 80px 40px;
  position: relative;
  overflow: hidden;
}
.course-hero-inner {
  max-width: 1200px;
  margin: 0 auto;
  position: relative;
  z-index: 2;
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  gap: 40px;
  align-items: center;
}
.course-hero-content h1 {
  font-size: clamp(32px, 4vw, 48px);
  font-weight: 800;
  line-height: 1.2;
  margin-bottom: 16px;
}
.course-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: rgba(255, 255, 255, 0.15);
  border: 1px solid rgba(255, 255, 255, 0.3);
  color: var(--white);
  border-radius: 100px;
  padding: 6px 16px;
  font-size: 13px;
  font-weight: 600;
  margin-bottom: 20px;
}
.course-hero-desc {
  font-size: 17px;
  line-height: 1.6;
  opacity: 0.9;
  margin-bottom: 30px;
}
.course-quick-stats {
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 16px;
  padding: 24px;
  backdrop-filter: blur(10px);
}
.stat-row {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 16px;
}
.stat-row:last-child {
  margin-bottom: 0;
}
.stat-icon {
  width: 40px;
  height: 40px;
  background: rgba(255, 255, 255, 0.2);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
}
.stat-text {
  font-size: 14px;
}
.stat-text strong {
  display: block;
  font-size: 16px;
}

/* Main Content Layout */
.course-body {
  padding: 80px 40px;
}
.course-body-inner {
  max-width: 1200px;
  margin: 0 auto;
}

/* Grid Override for sidebars */
.course-detail-layout {
  display: grid;
  grid-template-columns: 7fr 5fr;
  gap: 50px;
}

/* Sections */
.detail-section {
  background: var(--white);
  border: 1px solid #ede9fe;
  border-radius: 20px;
  padding: 40px;
  margin-bottom: 36px;
  box-shadow: 0 4px 10px rgba(106, 17, 203, 0.02);
}
.detail-section h2 {
  font-size: 24px;
  font-weight: 700;
  color: var(--dark);
  margin-bottom: 24px;
  display: flex;
  align-items: center;
  gap: 12px;
  border-bottom: 2px solid var(--purple-light);
  padding-bottom: 12px;
}

/* Curriculum list styling */
.curriculum-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 20px;
}
.curriculum-item {
  display: flex;
  gap: 16px;
  align-items: flex-start;
  padding: 16px;
  border-radius: 12px;
  background: #fbfbfb;
  border: 1px solid #f3f0ff;
  transition: all 0.2s;
}
.curriculum-item:hover {
  background: #fdfcff;
  border-color: var(--purple-light);
  transform: translateX(4px);
}
.curriculum-num {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: var(--purple-light);
  color: var(--purple);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 14px;
  flex-shrink: 0;
}
.curriculum-details h4 {
  font-size: 16px;
  color: var(--dark);
  margin-bottom: 4px;
  font-weight: 600;
}
.curriculum-details p {
  font-size: 14px;
  color: var(--muted);
  line-height: 1.6;
}

/* Learning outcomes & project grids */
.outcomes-grid, .projects-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 20px;
}
.outcome-card, .project-card {
  background: #faf9ff;
  border: 1px solid #ede9fe;
  border-radius: 12px;
  padding: 24px;
  transition: all 0.2s;
}
.outcome-card:hover, .project-card:hover {
  border-color: var(--purple);
  background: var(--white);
  box-shadow: 0 10px 25px rgba(106, 17, 203, 0.06);
}
.outcome-card h4, .project-card h4 {
  font-size: 16px;
  font-weight: 700;
  color: var(--dark);
  margin-bottom: 8px;
}
.outcome-card p, .project-card p {
  font-size: 13.5px;
  color: var(--muted);
  line-height: 1.6;
}

/* Schedule & Booking Section */
.sidebar-sticky {
  position: sticky;
  top: 100px;
}
.booking-card {
  background: var(--white);
  border: 1px solid #ede9fe;
  border-radius: 20px;
  padding: 30px;
  box-shadow: 0 10px 30px rgba(106, 17, 203, 0.05);
}
.booking-card h3 {
  font-size: 20px;
  color: var(--dark);
  margin-bottom: 16px;
  font-weight: 700;
}
.price-tag {
  font-size: 22px;
  color: var(--purple);
  font-weight: 800;
  margin-bottom: 20px;
  display: block;
}
.schedule-info {
  background: #fcfbfe;
  border: 1px solid #f3f0ff;
  border-radius: 12px;
  padding: 16px;
  margin-bottom: 24px;
}
.schedule-info p {
  font-size: 13.5px;
  line-height: 1.5;
  color: var(--text);
  margin-bottom: 10px;
}
.schedule-info p:last-child {
  margin-bottom: 0;
}
.schedule-info strong {
  display: block;
  color: var(--purple);
  margin-top: 2px;
}

/* Form Styles */
.form-group {
  margin-bottom: 16px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.form-group label {
  font-size: 12.5px;
  font-weight: 600;
  color: var(--dark);
}
.form-group input, .form-group select, .form-group textarea {
  width: 100%;
  padding: 12px 14px;
  border: 1px solid #e1e1e6;
  border-radius: 8px;
  outline: none;
  font-family: inherit;
  font-size: 13.5px;
  transition: all 0.2s;
}
.form-group input:focus, .form-group select:focus, .form-group textarea:focus {
  border-color: var(--purple);
  box-shadow: 0 0 0 3px rgba(106, 17, 203, 0.1);
}
.form-submit-btn {
  width: 100%;
  justify-content: center;
  padding: 14px;
  font-size: 15px;
  margin-top: 10px;
}
.form-message {
  margin-top: 15px;
  font-size: 13px;
  font-weight: 500;
  text-align: center;
}

/* Floating WhatsApp Widget */
.whatsapp-widget {
  position: fixed;
  bottom: 30px;
  right: 30px;
  background: #25d366;
  color: var(--white);
  width: 60px;
  height: 60px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 16px rgba(37, 211, 102, 0.4);
  z-index: 9999;
  text-decoration: none;
  transition: all 0.3s ease;
}
.whatsapp-widget:hover {
  transform: scale(1.1) translateY(-4px);
  box-shadow: 0 8px 24px rgba(37, 211, 102, 0.5);
}
.whatsapp-widget svg {
  width: 32px;
  height: 32px;
  fill: currentColor;
}

/* Footer (Matches primary landing page) */
footer {
  background: #08080f;
  padding: 60px 40px 30px;
  color: rgba(255, 255, 255, 0.72);
}
.footer-inner {
  max-width: 1200px;
  margin: 0 auto;
}
.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr;
  gap: 48px;
  margin-bottom: 48px;
}
.footer-logo {
  height: 44px;
  margin-bottom: 16px;
}
.footer-about {
  font-size: 14px;
  line-height: 1.7;
  max-width: 320px;
}
.footer-heading {
  color: #fff;
  font-size: 14px;
  font-weight: 700;
  margin-bottom: 18px;
  text-transform: uppercase;
  letter-spacing: 1px;
}
.footer-links {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.footer-links a {
  color: rgba(255, 255, 255, 0.72);
  font-size: 14px;
  text-decoration: none;
  transition: color 0.2s;
}
.footer-links a:hover {
  color: #fff;
  text-decoration: underline;
}
.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  padding-top: 24px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
}
.footer-copy {
  color: rgba(255, 255, 255, 0.72);
  font-size: 13px;
}
.footer-legal {
  display: flex;
  gap: 20px;
}
.footer-legal a {
  color: rgba(255, 255, 255, 0.72);
  font-size: 13px;
  text-decoration: none;
}
.footer-legal a:hover {
  color: #fff;
  text-decoration: underline;
}

/* ── RESPONSIVE ── */

/* Tablet (≤1024px) */
@media (max-width: 1024px) {
  .course-hero-inner {
    grid-template-columns: 1fr;
    text-align: center;
  }
  .course-badge {
    margin: 0 auto 20px;
  }
  .hero-btns {
    justify-content: center;
  }
  .course-detail-layout {
    grid-template-columns: 1fr;
  }
  .sidebar-sticky {
    position: static;
  }
  .outcomes-grid, .projects-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .footer-grid {
    grid-template-columns: 1fr 1fr;
  }
}

/* Mobile (≤768px) */
@media (max-width: 768px) {
  body {
    padding-top: 60px;
  }

  /* Navbar */
  .navbar {
    padding: 12px 16px;
  }
  .nav-logo {
    height: 36px;
  }
  .nav-links {
    display: none;
  }
  .hamburger {
    display: flex;
  }
  .nav-links.open {
    display: flex;
    flex-direction: column;
    position: fixed;
    top: 60px; left: 0; right: 0;
    background: #fff;
    padding: 16px 20px;
    border-bottom: 1px solid #eee;
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.1);
    gap: 14px;
    z-index: 9998;
  }
  /* Smaller CTA buttons in navbar on mobile */
  .nav-cta {
    gap: 8px;
  }
  .nav-cta .btn {
    padding: 7px 14px;
    font-size: 12px;
    border-radius: 6px;
  }
  .nav-cta .btn-outline {
    border-width: 1.5px;
  }

  /* Hero */
  .course-hero {
    padding: 48px 16px 56px;
  }
  .course-hero-content h1 {
    font-size: clamp(24px, 7vw, 36px);
  }
  .course-hero-desc {
    font-size: 15px;
  }
  .hero-btns {
    flex-direction: column;
    align-items: center;
  }
  .hero-btns .btn {
    width: 100%;
    max-width: 300px;
    justify-content: center;
    padding: 13px 20px;
    font-size: 15px;
  }
  .course-quick-stats {
    padding: 18px 16px;
  }

  /* Body & sections */
  .course-body {
    padding: 40px 16px;
  }
  .detail-section {
    padding: 22px 18px;
    border-radius: 14px;
    margin-bottom: 24px;
  }
  .detail-section h2 {
    font-size: 19px;
    margin-bottom: 18px;
  }

  /* Curriculum items */
  .curriculum-item {
    padding: 14px 12px;
    gap: 12px;
  }
  .curriculum-details h4 {
    font-size: 14px;
  }
  .curriculum-details p {
    font-size: 13px;
  }

  /* Outcomes & Projects */
  .outcomes-grid, .projects-grid {
    grid-template-columns: 1fr;
  }
  .outcome-card, .project-card {
    padding: 18px;
  }

  /* Booking card */
  .booking-card {
    padding: 22px 18px;
    border-radius: 14px;
  }
  .booking-card h3 {
    font-size: 18px;
  }

  /* Footer */
  .footer-grid {
    grid-template-columns: 1fr;
    gap: 28px;
  }
  .footer-bottom {
    flex-direction: column;
    text-align: center;
    gap: 16px;
  }
  .footer-legal {
    flex-wrap: wrap;
    justify-content: center;
    gap: 12px;
  }
  footer {
    padding: 48px 16px 24px;
  }

  /* WhatsApp widget */
  .whatsapp-widget {
    width: 52px;
    height: 52px;
    bottom: 20px;
    right: 16px;
  }
  .whatsapp-widget svg {
    width: 26px;
    height: 26px;
  }
}

/* Small phones (≤400px) */
@media (max-width: 400px) {
  .nav-cta .btn {
    padding: 6px 10px;
    font-size: 11px;
  }
  .course-hero-content h1 {
    font-size: 22px;
  }
  .course-badge {
    font-size: 11px;
    padding: 5px 12px;
  }
  .stat-row {
    gap: 10px;
  }
  .stat-text {
    font-size: 13px;
  }
  .stat-text strong {
    font-size: 14px;
  }
  .detail-section {
    padding: 18px 14px;
  }
  .detail-section h2 {
    font-size: 17px;
    gap: 8px;
  }
  .curriculum-num {
    width: 28px;
    height: 28px;
    font-size: 12px;
  }
}
