/* Google Fonts Request: Inter */
@import url("https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&display=swap");

:root {
  --primary-color: #6366f1;
  --primary-hover: #4f46e5;
  --secondary-color: #ec4899;
  --dark-bg: #111827;
  --light-bg: #f9fafb;
  --card-bg: #ffffff;
  --text-main: #1f2937;
  --text-muted: #6b7280;
  --gradient-main: linear-gradient(135deg, #6366f1 0%, #a855f7 100%);
  --body-bg: #f9fafb; /* Default light bg */
  --shadow-sm: 0 1px 2px 0 rgb(0 0 0 / 0.05);
  --shadow-md: 0 4px 6px -1px rgb(0 0 0 / 0.1), 0 2px 4px -2px rgb(0 0 0 / 0.1);
  --shadow-lg: 0 10px 15px -3px rgb(0 0 0 / 0.1),
    0 4px 6px -4px rgb(0 0 0 / 0.1);
  --shadow-lg: 0 10px 15px -3px rgb(0 0 0 / 0.1),
    0 4px 6px -4px rgb(0 0 0 / 0.1);
  --shadow-xl: 0 20px 25px -5px rgb(0 0 0 / 0.1),
    0 8px 10px -6px rgb(0 0 0 / 0.1);
}

/* Color Themes */
[data-color="emerald"] {
  --primary-color: #10b981;
  --primary-hover: #059669;
  --secondary-color: #34d399;
  --gradient-main: linear-gradient(135deg, #10b981 0%, #34d399 100%);
  --btn-shadow: rgba(16, 185, 129, 0.4);
}
[data-color="rose"] {
  --primary-color: #f43f5e;
  --primary-hover: #e11d48;
  --secondary-color: #fb7185;
  --gradient-main: linear-gradient(135deg, #f43f5e 0%, #fb7185 100%);
  --btn-shadow: rgba(244, 63, 94, 0.4);
}
[data-color="amber"] {
  --primary-color: #f59e0b;
  --primary-hover: #d97706;
  --secondary-color: #fbbf24;
  --gradient-main: linear-gradient(135deg, #f59e0b 0%, #fbbf24 100%);
  --btn-shadow: rgba(245, 158, 11, 0.4);
}
[data-color="sky"] {
  --primary-color: #0ea5e9;
  --primary-hover: #0284c7;
  --secondary-color: #38bdf8;
  --gradient-main: linear-gradient(135deg, #0ea5e9 0%, #38bdf8 100%);
  --btn-shadow: rgba(14, 165, 233, 0.4);
}

[data-theme="dark"] {
  --light-bg: #111827;
  --dark-bg: #f9fafb;
  --card-bg: #1f2937;
  --text-main: #f9fafb;
  --text-muted: #9ca3af;
  --invert-filter: invert(1);
  /* Default Dark Gradient (Indigo-ish deep) */
  --body-bg: linear-gradient(135deg, #0f172a 0%, #1e1b4b 100%);
}

/* Dark Mode Theme Gradients */
[data-theme="dark"][data-color="emerald"] {
  --body-bg: linear-gradient(135deg, #022c22 0%, #064e3b 100%);
}
[data-theme="dark"][data-color="rose"] {
  --body-bg: linear-gradient(135deg, #4c0519 0%, #881337 100%);
}
[data-theme="dark"][data-color="amber"] {
  --body-bg: linear-gradient(135deg, #451a03 0%, #78350f 100%);
}
[data-theme="dark"][data-color="sky"] {
  --body-bg: linear-gradient(135deg, #0c4a6e 0%, #075985 100%);
}

[data-theme="dark"] .bg-light {
  background-color: var(--light-bg) !important;
}
[data-theme="dark"] .bg-white {
  background-color: var(--card-bg) !important;
}
[data-theme="dark"] .text-secondary,
[data-theme="dark"] .text-muted {
  color: var(--text-muted) !important;
}
[data-theme="dark"] .navbar.scrolled {
  background: rgba(31, 41, 55, 0.9) !important;
}
[data-theme="dark"] .border-bottom {
  border-color: rgba(255, 255, 255, 0.1) !important;
}
[data-theme="dark"] .list-group-item {
  background: var(--card-bg);
  color: var(--text-main);
  border-color: rgba(255, 255, 255, 0.1);
}
[data-theme="dark"] .feature-item,
[data-theme="dark"] .testimonial-card,
[data-theme="dark"] .blog-card,
[data-theme="dark"] .modal-content {
  background-color: var(--card-bg);
  border-color: rgba(255, 255, 255, 0.1) !important;
}
[data-theme="dark"] .img-invertable {
  /* For non-transparent logos if any */
  filter: invert(1);
}
/* Ensure dark text on badges remains readable or adjust */
[data-theme="dark"] .text-bg-light {
  background-color: #374151 !important;
  color: #f3f4f6 !important;
}

/* Fix text visibility in dark mode */
[data-theme="dark"] .text-black,
[data-theme="dark"] h1,
[data-theme="dark"] h2,
[data-theme="dark"] h3,
[data-theme="dark"] h4,
[data-theme="dark"] h5,
[data-theme="dark"] h6 {
  color: #f9fafb !important;
}

[data-theme="dark"] p {
  color: #e5e7eb;
}

body {
  font-family: "Inter", sans-serif;
  color: var(--text-main);
  background: var(--body-bg) !important;
  background-attachment: fixed !important;
  scroll-behavior: smooth;
  overflow-x: hidden;
}

/* Custom Scrollbar */
::-webkit-scrollbar {
  width: 10px;
}
::-webkit-scrollbar-track {
  background: var(--light-bg);
}
::-webkit-scrollbar-thumb {
  background: #cbd5e1;
  border-radius: 5px;
}
::-webkit-scrollbar-thumb:hover {
  background: #94a3b8;
}

/* Navbar Glassmorphism */
.navbar {
  transition: all 0.3s ease;
  padding: 1rem 0;
}
.navbar.scrolled {
  background: rgba(255, 255, 255, 0.8) !important;
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  box-shadow: var(--shadow-md);
  padding: 0.8rem 0;
}

.navbar-brand img {
  width: 120px;
  transition: transform 0.3s ease;
}
.navbar-brand:hover img {
  transform: scale(1.05);
}

.nav-link {
  font-weight: 500;
  color: var(--text-main) !important;
  transition: color 0.2s ease;
}
.nav-link:hover,
.nav-link.active {
  color: var(--primary-color) !important;
}

/* Buttons */
.btn {
  font-weight: 500;
  border-radius: 9999px; /* Pill shape */
  padding: 0.5rem 1.5rem;
  transition: all 0.3s ease;
  border: none;
}
.btn-primary-gradient {
  background: var(--gradient-main);
  color: white;
  box-shadow: 0 4px 6px -1px var(--btn-shadow, rgba(99, 102, 241, 0.4));
}
.btn-primary-gradient:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 15px -3px var(--btn-shadow, rgba(99, 102, 241, 0.5));
  color: white;
}
.feature-item {
  transition: all 0.3s ease;
  border: 1px solid rgba(0, 0, 0, 0.05) !important;
  box-shadow: var(--shadow-sm);
}
.feature-item:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-xl);
  border-color: rgba(99, 102, 241, 0.2) !important;
}

.feature-item img {
  width: 50px;
  height: auto;
  transition: transform 0.3s ease;
}
.feature-item:hover img {
  transform: scale(1.1) rotate(5deg);
}

.main-header {
  padding-top: 50px;
  padding-bottom: 80px;
  background: radial-gradient(circle at top right, #e0e7ff 0%, transparent 40%);
}

.subcribe {
  position: relative;
  background-image: url(./img/subscribe.jpg); /* Fallback */
  background: linear-gradient(rgba(0, 0, 0, 0.7), rgba(0, 0, 0, 0.7)),
    url(./img/subscribe.jpg);
  background-size: cover;
  background-position: center;
  border-radius: 20px;
  margin: 2rem 0;
}

/* Course Cards */
.list-group-item {
  border: none;
  background: white;
  border-radius: 12px !important;
  margin-bottom: 1rem;
  box-shadow: var(--shadow-sm);
  transition: all 0.3s ease;
}
.list-group-item-action:hover {
  background-color: white;
  transform: translateY(-3px);
  box-shadow: var(--shadow-lg);
  z-index: 1;
}
.list-group-item img {
  object-fit: cover;
  height: 100%;
  min-height: 180px;
}

.brand-icon img {
  width: 120px;
  filter: grayscale(100%);
  opacity: 0.7;
  transition: all 0.3s;
}
.brand-icon img:hover {
  filter: grayscale(0%);
  opacity: 1;
}

.copy-right {
  color: #9ca3af;
  background-color: #0f172a;
}
.text-bg-dark {
  background-color: #1e293b !important;
}

.blur-filter {
  backdrop-filter: blur(8px);
  background-color: rgba(255, 255, 255, 0.8);
  border-top: 1px solid rgba(0, 0, 0, 0.1);
}

/* Stats Section */
.stat-item {
  transition: transform 0.3s ease;
}
.stat-item:hover {
  transform: translateY(-5px);
}
.counter {
  font-family: "Inter", sans-serif;
  letter-spacing: -1px;
}
/* Testimonials */
.testimonial-card {
  transition: all 0.3s ease;
  background-color: var(--card-bg);
}
.testimonial-card:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-lg);
}

/* Back to Top Button */
#btn-back-to-top {
  position: fixed;
  bottom: 80px; /* Above mobile sticky footer if present, or just appropriate spacing */
  right: 20px;
  display: none;
  z-index: 9999;
  width: 50px;
  height: 50px;
  padding: 0;
  display: inline-flex;
  justify-content: center;
  align-items: center;
  box-shadow: var(--shadow-lg);
  opacity: 0;
  visibility: hidden;
  transition: all 0.3s ease;
}

#btn-back-to-top.show {
  opacity: 1;
  visibility: visible;
}

@media (min-width: 768px) {
  /* Partners */
  .grayscale-hover {
    transition: all 0.3s ease;
  }
  .grayscale-hover i {
    transition: all 0.3s ease;
    color: #9ca3af; /* muted default */
    opacity: 0.7;
  }
  .grayscale-hover div:hover i {
    color: var(--text-main);
    opacity: 1;
    transform: scale(1.2);
    filter: drop-shadow(0 0 10px rgba(99, 102, 241, 0.3)); /* Glow effect */
  }

  /* Instructors */
  .instructor-card:hover img {
    transform: scale(1.05);
    transition: transform 0.3s ease;
  }
  .instructor-card:hover .social-links {
    opacity: 1;
  }

  /* Pricing */
  .scale-card {
    transform: scale(1.05);
    z-index: 2;
    border-width: 2px !important;
  }
}

@media (max-width: 768px) {
  .scale-card {
    transform: scale(1);
    z-index: 1;
  }
}
/* Pricing Hover Effect */
#pricing .card {
  transition: all 0.3s ease;
  border: 2px solid transparent !important;
}
#pricing .card.border-primary {
  border-color: var(--primary-color) !important;
}
#pricing .card:hover {
  border-color: var(--primary-color) !important;
  transform: translateY(-5px);
  box-shadow: var(--shadow-xl);
}

/* FAQ Accordion */
.accordion-button:not(.collapsed) {
  color: var(--primary-color);
  background-color: rgba(99, 102, 241, 0.05);
  box-shadow: none;
}
.accordion-button:focus {
  box-shadow: none;
  border-color: rgba(99, 102, 241, 0.1);
}

/* Certificate */
.certificate-img {
  transition: transform 0.5s ease;
  transform: perspective(1000px) rotateY(-5deg) rotateX(2deg);
}
.certificate-img:hover {
  transform: perspective(1000px) rotateY(0deg) rotateX(0deg) scale(1.02);
}

/* Blog */
.blog-card {
  transition: transform 0.3s ease;
}
.blog-card:hover {
  transform: translateY(-5px);
}
.stretched-link::after {
  position: absolute;
  top: 0;
  right: 0;
  bottom: 0;
  left: 0;
  z-index: 1;
  content: "";
}

/* Cookie Banner */
#cookie-banner {
  animation: slideUp 0.5s ease-out;
}
@keyframes slideUp {
  from {
    transform: translateY(100%);
  }
  to {
    transform: translateY(0);
  }
}

/* Modal */
.modal-content {
  border-radius: 1rem;
  border: none;
}
.modal-header {
  border-bottom: 1px solid rgba(0, 0, 0, 0.05);
}
