/* ==========================================================================
   EduNova Style CSS
   ========================================================================== */

/* 1. Imports
   ========================================================================== */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700&family=Plus+Jakarta+Sans:wght@500;600;700;800&display=swap');
@import url('colors/scheme-01.css');

/* 2. Base & Resets
   ========================================================================== */
*,
*::before,
*::after {
  box-sizing: border-box;
}

html,
body {
  font-family: var(--font-body);
  color: var(--text-color);
  background-color: var(--surface);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
  max-width: 100%;
}

main {
  overflow-x: hidden;
  max-width: 100%;
}

/* 3. Typography
   ========================================================================== */
h1,
h2,
h3,
h4,
h5,
h6 {
  font-family: var(--font-heading);
  color: var(--heading-color);
  font-weight: 700;
  margin-top: 0;
  margin-bottom: 1rem;
  line-height: 1.2;
}

h1 {
  font-size: clamp(2.5rem, 5vw, 4rem);
}

h2 {
  font-size: clamp(2rem, 4vw, 3rem);
}

h3 {
  font-size: clamp(1.5rem, 3vw, 2rem);
}

h4 {
  font-size: 1.25rem;
}

a {
  color: var(--primary-color);
  text-decoration: none;
  transition: var(--transition);
}

a:hover {
  color: var(--primary-dark);
}

p {
  margin-bottom: 1.5rem;
}

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

/* 4. Buttons
   ========================================================================== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  font-family: var(--font-heading);
  font-weight: 600;
  padding: 0.8rem 2rem;
  border-radius: var(--radius-pill);
  border: none;
  transition: var(--transition);
  cursor: pointer;
  position: relative;
  overflow: hidden;
  z-index: 1;
}

.btn-primary {
  background: var(--primary-color);
  color: var(--surface);
  box-shadow: var(--shadow-soft);
}

.btn-primary:hover {
  background: var(--primary-dark);
  color: var(--surface);
  transform: translateY(-2px);
  box-shadow: 0 15px 35px rgba(91, 75, 255, 0.2);
}

.btn-outline-primary {
  background: transparent;
  color: var(--primary-color);
  border: 2px solid var(--primary-color);
}

.btn-outline-primary:hover {
  background: var(--primary-color);
  color: var(--surface);
}

.btn-white {
  background: var(--surface);
  color: var(--heading-color);
  box-shadow: var(--shadow-sm);
}

.btn-white:hover {
  background: var(--bg-soft);
  color: var(--primary-color);
  transform: translateY(-2px);
}

/* 5. Header & Navigation
   ========================================================================== */
.site-header {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 1030;
  transition: var(--transition);
}

.site-header.sticky {
  background: rgba(255, 255, 255, 0.9);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  box-shadow: var(--shadow-sm);
  padding-top: 0;
  padding-bottom: 0;
}

/* Topbar */
.topbar {
  background: var(--secondary-color);
  color: var(--surface);
  font-size: 0.875rem;
  padding: 0.5rem 0;
}

.topbar a {
  color: var(--surface);
  opacity: 0.8;
}

.topbar a:hover {
  opacity: 1;
}

.topbar .dropdown-toggle::after {
  vertical-align: middle;
}

/* Navbar */
.navbar {
  padding: 1rem 0;
  transition: var(--transition);
}

.site-header.sticky .navbar {
  padding: 0.5rem 0;
}

.navbar-brand {
  font-family: var(--font-heading);
  font-weight: 800;
  font-size: 1.5rem;
  color: var(--heading-color);
}

.navbar-brand span {
  color: var(--primary-color);
}

.nav-link {
  font-weight: 600;
  color: var(--heading-color);
  padding: 0.5rem 1rem !important;
}

.nav-link:hover,
.nav-link.active {
  color: var(--primary-color);
}

/* Multi-level Dropdown for Desktop */
@media (min-width: 992px) {
  .dropdown:hover>.dropdown-menu {
    display: block;
    margin-top: 0;
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
  }

  .dropdown-menu {
    display: block;
    opacity: 0;
    visibility: hidden;
    transform: translateY(10px);
    transition: var(--transition);
    border: none;
    border-radius: var(--radius-sm);
    box-shadow: var(--shadow-soft);
    padding: 1rem;
  }

  .dropdown-submenu {
    position: relative;
  }

  .dropdown-submenu:hover>.dropdown-menu {
    top: 0;
    left: 100%;
    margin-top: -1rem;
  }
}

/* 6. Hero Section
   ========================================================================== */
.hero-area {
  min-height: 100vh;
  display: flex;
  align-items: center;
  position: relative;
  background: var(--gradient-hero);
  padding-top: 120px;
  overflow: hidden;
}

.hero-bg-shapes {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: -1;
  overflow: hidden;
}

.shape-blob {
  position: absolute;
  background: var(--gradient-primary);
  opacity: 0.1;
  border-radius: var(--radius-blob-1);
  filter: blur(40px);
}

.hero-badge {
  display: inline-block;
  background: rgba(91, 75, 255, 0.1);
  color: var(--primary-color);
  padding: 0.5rem 1rem;
  border-radius: var(--radius-pill);
  font-weight: 600;
  font-size: 0.875rem;
  margin-bottom: 1.5rem;
}

.hero-title {
  font-size: clamp(2.6rem, 6vw, 5rem);
  font-weight: 800;
  margin-bottom: 1.5rem;
  line-height: 1.1;
  word-break: break-word;
  hyphens: auto;
}

.text-gradient {
  background: var(--gradient-primary);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  position: relative;
  display: inline-block;
}

.typed-text {
  color: var(--accent-color);
  -webkit-text-fill-color: var(--accent-color);
}

.hero-text {
  font-size: 1.125rem;
  color: var(--text-color);
  margin-bottom: 2rem;
  max-width: 500px;
}

.hero-buttons {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
  margin-bottom: 3rem;
}

.social-proof {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.avatars {
  display: flex;
}

.avatars img {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  border: 2px solid var(--surface);
  margin-left: -10px;
  object-fit: cover;
}

.avatars img:first-child {
  margin-left: 0;
}

.proof-text {
  font-size: 0.875rem;
  font-weight: 600;
}

.stars {
  color: var(--highlight-color);
  font-size: 1rem;
}

/* Hero Right Side */
.hero-image-wrapper {
  position: relative;
  width: 100%;
  height: 100%;
  min-height: 500px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.hero-main-img {
  width: 80%;
  border-radius: var(--radius-blob-1);
  box-shadow: var(--shadow-soft);
  animation: blobFloat 8s ease-in-out infinite;
}

@keyframes blobFloat {
  0% {
    border-radius: var(--radius-blob-1);
    transform: translateY(0);
  }

  50% {
    border-radius: var(--radius-blob-2);
    transform: translateY(-20px);
  }

  100% {
    border-radius: var(--radius-blob-1);
    transform: translateY(0);
  }
}

.floating-card {
  position: absolute;
  background: rgba(255, 255, 255, 0.9);
  backdrop-filter: blur(10px);
  padding: 1rem;
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-soft);
  display: flex;
  align-items: center;
  gap: 0.8rem;
  font-weight: 600;
  color: var(--heading-color);
}

.card-1 {
  top: 10%;
  right: 0;
  animation: float 5s ease-in-out infinite;
}

.card-2 {
  bottom: 20%;
  left: 0;
  animation: float 6s ease-in-out infinite 1s;
}

.card-3 {
  top: 50%;
  right: -10%;
  animation: float 4s ease-in-out infinite 2s;
}

@keyframes float {
  0% {
    transform: translateY(0px);
  }

  50% {
    transform: translateY(-15px);
  }

  100% {
    transform: translateY(0px);
  }
}

/* Bottom Wave & Mouse Scroll */
.hero-bottom {
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
}

.hero-bottom svg {
  display: block;
  width: 100%;
  height: auto;
}

.scroll-indicator {
  position: absolute;
  bottom: 30px;
  left: 50%;
  transform: translateX(-50%);
  width: 30px;
  height: 50px;
  border: 2px solid var(--text-color);
  border-radius: 20px;
  display: flex;
  justify-content: center;
  opacity: 0.7;
}

.scroll-indicator::before {
  content: '';
  width: 6px;
  height: 6px;
  background: var(--text-color);
  border-radius: 50%;
  margin-top: 10px;
  animation: scrollDown 2s infinite;
}

@keyframes scrollDown {
  0% {
    transform: translateY(0);
    opacity: 1;
  }

  100% {
    transform: translateY(15px);
    opacity: 0;
  }
}

/* Stats Bar */
.stats-bar {
  background: rgba(255, 255, 255, 0.8);
  backdrop-filter: blur(15px);
  border-radius: var(--radius-lg);
  padding: 2rem;
  box-shadow: var(--shadow-lift);
  transform: translateY(-50%);
  position: relative;
  z-index: 10;
}

.stat-item h3 {
  font-size: 2.5rem;
  color: var(--primary-color);
  margin-bottom: 0.5rem;
}

.stat-item p {
  margin-bottom: 0;
  font-weight: 600;
  color: var(--text-color);
}

/* 7. Sections (General)
   ========================================================================== */
section {
  padding: 80px 0;
  position: relative;
  scroll-margin-top: 100px;
}

.section-title {
  text-align: center;
  margin-bottom: 3rem;
}

.section-title span {
  color: var(--primary-color);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 2px;
  display: block;
  margin-bottom: 0.5rem;
}

/* Categories */
.category-card {
  background: var(--surface);
  border-radius: var(--radius-lg);
  padding: 2rem;
  text-align: center;
  box-shadow: var(--shadow-sm);
  transition: var(--transition);
  border: 1px solid var(--border-color);
  display: block;
  color: var(--heading-color);
}

.category-card:hover {
  transform: translateY(-10px);
  box-shadow: var(--shadow-soft);
  border-color: transparent;
  color: var(--primary-color);
}

.cat-icon {
  width: 80px;
  height: 80px;
  background: var(--bg-soft);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 1.5rem;
  font-size: 2rem;
  color: var(--primary-color);
  transition: var(--transition);
}

.category-card:hover .cat-icon {
  background: var(--primary-color);
  color: var(--surface);
}

.category-card h5 {
  font-weight: 700;
  margin-bottom: 0;
  font-size: 1rem;
  word-break: break-word;
  hyphens: auto;
}

/* Courses */
.course-card {
  background: var(--surface);
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  transition: var(--transition);
  border: 1px solid var(--border-color);
  height: 100%;
  display: flex;
  flex-direction: column;
}

.course-card:hover {
  transform: translateY(-10px);
  box-shadow: var(--shadow-soft);
}

.course-img {
  position: relative;
  overflow: hidden;
}

.course-img img {
  width: 100%;
  aspect-ratio: 4/3;
  object-fit: cover;
  transition: var(--transition);
}

.course-card:hover .course-img img {
  transform: scale(1.05);
}

.course-badge {
  position: absolute;
  top: 1rem;
  left: 1rem;
  background: var(--surface);
  color: var(--primary-color);
  padding: 0.3rem 0.8rem;
  border-radius: var(--radius-pill);
  font-size: 0.8rem;
  font-weight: 600;
  z-index: 2;
}

.course-price-badge {
  position: absolute;
  top: 1rem;
  right: 1rem;
  background: var(--primary-color, #0A1060);
  color: #ffffff;
  padding: 0.38rem 0.85rem;
  border-radius: var(--radius-pill, 50px);
  font-size: 0.875rem;
  font-weight: 700;
  box-shadow: 0 4px 14px rgba(10, 16, 96, 0.22);
  z-index: 2;
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  line-height: 1.2;
  letter-spacing: -0.01em;
}

.course-price-badge del.old-price {
  text-decoration: line-through;
  color: rgba(255, 255, 255, 0.65);
  font-size: 0.775rem;
  font-weight: 500;
}

.course-price-badge span.current-price {
  color: #ffffff;
  font-size: 0.925rem;
  font-weight: 700;
}


.course-content {
  padding: 1.5rem;
  display: flex;
  flex-direction: column;
  flex-grow: 1;
}

.course-meta {
  display: flex;
  justify-content: space-between;
  font-size: 0.875rem;
  color: var(--text-color);
  margin-bottom: 1rem;
}

.course-title {
  font-size: 1.25rem;
  margin-bottom: 1rem;
}

.course-title a {
  color: var(--heading-color);
}

.course-title a:hover {
  color: var(--primary-color);
}

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

.course-price {
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--primary-color);
}

.course-price del {
  font-size: 0.875rem;
  color: var(--text-color);
  margin-right: 0.5rem;
  font-weight: 400;
}

/* Features (Bento Grid) */
.bento-card {
  background: var(--bg-soft);
  border-radius: var(--radius-lg);
  padding: 2rem;
  height: 100%;
  transition: var(--transition);
}

.bento-card:hover {
  background: var(--surface);
  box-shadow: var(--shadow-soft);
}

.bento-icon {
  font-size: 2.5rem;
  color: var(--accent-color);
  margin-bottom: 1rem;
}

/* Forms */
.form-control,
.form-select {
  border-radius: var(--radius-md);
  padding: 0.8rem 1.2rem;
  border: 1px solid var(--border-color);
  transition: var(--transition);
  background-color: var(--bg-soft);
}

.form-control:focus,
.form-select:focus {
  background-color: var(--surface);
  border-color: var(--primary-color);
  box-shadow: 0 0 0 0.25rem rgba(91, 75, 255, 0.15);
}

/* Preloader */
.preloader {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: var(--surface);
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: opacity 0.5s ease;
}

.loader-content {
  text-align: center;
}

.loader-text {
  font-family: var(--font-heading);
  font-size: 2rem;
  font-weight: 800;
  color: var(--primary-color);
  margin-bottom: 1rem;
}

.loader-progress {
  width: 200px;
  height: 4px;
  background: var(--bg-soft);
  border-radius: var(--radius-pill);
  overflow: hidden;
  margin: 0 auto;
}

.loader-bar {
  height: 100%;
  width: 0;
  background: var(--primary-color);
  animation: load 1s ease forwards;
}

@keyframes load {
  100% {
    width: 100%;
  }
}

/* Scroll Progress */
.scroll-progress {
  position: fixed;
  top: 0;
  left: 0;
  width: 0%;
  height: 4px;
  background: var(--gradient-primary);
  z-index: 9999;
}

/* Reveal Animations */
.reveal {
  opacity: 0;
  transform: translateY(30px);
  transition: all 0.8s ease;
}

.reveal.active {
  opacity: 1;
  transform: translateY(0);
}

.reveal-left {
  opacity: 0;
  transform: translateX(-50px);
  transition: all 0.8s ease;
}

.reveal-left.active {
  opacity: 1;
  transform: translateX(0);
}

.reveal-right {
  opacity: 0;
  transform: translateX(50px);
  transition: all 0.8s ease;
}

.reveal-right.active {
  opacity: 1;
  transform: translateX(0);
}

.reveal-zoom {
  opacity: 0;
  transform: scale(0.9);
  transition: all 0.8s ease;
}

.reveal-zoom.active {
  opacity: 1;
  transform: scale(1);
}

/* Back to top */
.back-to-top {
  position: fixed;
  bottom: 30px;
  right: 30px;
  width: 50px;
  height: 50px;
  background: var(--primary-color);
  color: var(--surface);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  opacity: 0;
  visibility: hidden;
  transition: var(--transition);
  box-shadow: var(--shadow-soft);
  z-index: 999;
  border: none;
  cursor: pointer;
}

.back-to-top.active {
  opacity: 1;
  visibility: visible;
}

.back-to-top:hover {
  background: var(--primary-dark);
  color: var(--surface);
  transform: translateY(-5px);
}

/* Marquee */
.marquee-wrapper {
  overflow: hidden;
  white-space: nowrap;
  position: relative;
}

.marquee-content {
  display: inline-block;
  animation: marquee 20s linear infinite;
}

.marquee-wrapper:hover .marquee-content {
  animation-play-state: paused;
}

@keyframes marquee {
  0% {
    transform: translateX(0);
  }

  100% {
    transform: translateX(-50%);
  }
}

/* Pagination */
.pagination {
  justify-content: center;
  gap: 0.5rem;
  margin-top: 3rem;
}

.page-item .page-link {
  border: none;
  background: var(--bg-soft);
  color: var(--heading-color);
  border-radius: 50% !important;
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 600;
  transition: var(--transition);
}

.page-item:first-child .page-link,
.page-item:last-child .page-link {
  border-radius: var(--radius-pill) !important;
  width: auto;
  padding: 0 1.5rem;
}

.page-item.active .page-link,
.page-link:hover {
  background: var(--primary-color);
  color: var(--surface);
}

/* Empty State */
.empty-state {
  text-align: center;
  padding: 4rem 0;
}

.empty-state img {
  max-width: 300px;
  margin: 0 auto 2rem;
}

/* Footer */
.site-footer {
  background: var(--secondary-color);
  color: rgba(255, 255, 255, 0.7);
  padding-top: 80px;
}

.footer-widget h4 {
  color: var(--surface);
  margin-bottom: 1.5rem;
}

.footer-widget ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

.footer-widget ul li {
  margin-bottom: 0.8rem;
}

.footer-widget ul li a {
  color: rgba(255, 255, 255, 0.7) !important;
}

.footer-widget ul li a:hover {
  color: var(--primary-color);
  padding-left: 5px;
}

.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  padding: 1.5rem 0;
  margin-top: 4rem;
  text-align: center;
}

/* Responsive */
@media (max-width: 991.98px) {
  .hero-area {
    padding-top: 100px;
    overflow: hidden;
  }

  .stats-bar {
    transform: none;
    margin-top: 3rem;
  }

  .navbar-collapse {
    background: var(--surface);
    padding: 1rem;
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-soft);
    margin-top: 1rem;
  }

  .floating-card {
    display: none !important;
  }

  /* Prevent horizontal animation overflow on mobile/tablet */
  .reveal-left,
  .reveal-right {
    transform: translateY(30px);
  }

  .reveal-left.active,
  .reveal-right.active {
    transform: translateY(0);
  }
}

@media (max-width: 767.98px) {
  .topbar {
    display: none !important;
  }

  .hero-title {
    font-size: 2.2rem;
  }

  .hero-text {
    font-size: 1rem;
  }

  .hero-image-wrapper {
    min-height: auto;
    margin-top: 2rem;
  }
}

/* Swiper Pagination Styling */
.swiper-pagination-bullet {
    width: 10px;
    height: 10px;
    background: var(--heading-color);
    opacity: 0.3;
    transition: all 0.3s ease;
}
.swiper-pagination-bullet-active {
    width: 25px;
    border-radius: 5px;
    background: var(--primary-color);
    opacity: 1;
}
.testimonials-slider {
    padding-bottom: 60px !important;
}
.testimonials-slider .swiper-pagination {
    bottom: 0 !important;
}
.testimonials-slider .swiper-wrapper {
    align-items: stretch;
}
.testimonials-slider .swiper-slide {
    height: auto;
}
.testimonials-slider .card {
    height: 100%;
}
.testimonials-slider img.rounded-circle {
    flex-shrink: 0;
    width: 60px !important;
    height: 60px !important;
    min-width: 60px;
    min-height: 60px;
    max-width: 60px;
    max-height: 60px;
    object-fit: cover;
}

/* Premium Accordion Styling */
.accordion-item {
    border: 1px solid rgba(0,0,0,0.05) !important;
    transition: all 0.3s ease;
}
.accordion-item:hover {
    box-shadow: 0 10px 30px rgba(0,0,0,0.08) !important;
    transform: translateY(-3px);
}
.accordion-button {
    box-shadow: none !important;
    background-color: transparent !important;
    color: var(--heading-color) !important;
    padding: 1.5rem !important;
}
.accordion-button:not(.collapsed) {
    color: var(--primary-color) !important;
    background-color: transparent !important;
}
.accordion-button:not(.collapsed)::after {
    filter: brightness(0) saturate(100%) invert(13%) sepia(87%) saturate(3023%) hue-rotate(222deg) brightness(85%) contrast(106%);
}
.accordion-body {
    padding: 0 1.5rem 1.5rem 1.5rem !important;
}

@media (prefers-reduced-motion: reduce) {
  * {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}

/* Sidebar Sticky Card (Breathing room below fixed header) */
.sidebar-sticky-card {
    position: -webkit-sticky !important;
    position: sticky !important;
    top: 145px !important;
    margin-top: 1.5rem !important;
    z-index: 20;
    transition: top 0.25s ease;
}

html[style*="margin-top"] .sidebar-sticky-card,
body.admin-bar .sidebar-sticky-card {
    top: 165px !important;
}

@media (max-width: 991.98px) {
    .sidebar-sticky-card {
        position: static !important;
        margin-top: 2rem !important;
    }
}