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

body {
  font-family: Inter, sans-serif;
  background: linear-gradient(180deg, #fff 0%, #f8f9ff 45%, #fff 100%);
  color: var(--text);
}

a {
  text-decoration: none;
  color: inherit;
}

button {
  font-family: inherit;
  border: none;
  cursor: pointer;
}

.page {
  max-width: 1440px;
  margin: auto;
  padding: 22px 42px 40px;
}

/* HEADER */

.header {
  display: flex;
  align-items: center;
  gap: 26px;
  margin-bottom: 28px;
}

.logo {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 245px;
}

.logo-icon {
  width: 44px;
  height: 44px;
  border-radius: 15px;
  /* background: linear-gradient(135deg, #6741ff, #00b7ff); */
  display: grid;
  place-items: center;
  color: white;
  font-weight: 900;
  font-size: 24px;
  box-shadow: 0 10px 22px rgba(91, 53, 245, .28);
}

.logo-icon img{
    width: 42px;
  height: 42px;
  border-radius: 50%;

}

.logo-text strong {
  display: block;
  font-size: 24px;
  line-height: 1;
  color: var(--navy);
}

.logo-text span {
  font-size: 11px;
  font-weight: 700;
  color: #555d82;
}

.nav-dropdown {
  position: relative;
}

.nav-btn {
  height: 52px;
  padding: 0 26px;
  background: var(--primary);
  color: white;
  border-radius: 10px;
  font-weight: 700;
  display: flex;
  align-items: center;
  gap: 10px;
  box-shadow: 0 12px 24px rgba(91, 53, 245, .25);
}

.nav-dropdown.open .nav-btn {
  background: var(--primary-dark);
}

.dropdown-menu {
  position: absolute;
  top: calc(100% + 8px);
  left: 0;
  min-width: 220px;
  background: white;
  border: 1px solid var(--border);
  border-radius: 14px;
  box-shadow: var(--shadow);
  padding: 10px;
  display: none;
  flex-direction: column;
  z-index: 100;
}

.nav-dropdown.open .dropdown-menu {
  display: flex;
}

.dropdown-menu a {
  padding: 12px 14px;
  border-radius: 10px;
  font-weight: 700;
  color: var(--navy);
}

.dropdown-menu a:hover {
  background: #f2f0ff;
  color: var(--primary);
}

.search {
  flex: 1;
  height: 52px;
  background: white;
  border: 1px solid var(--border);
  border-radius: 12px;
  display: flex;
  align-items: center;
  padding: 0 18px;
}

.search input {
  border: none;
  outline: none;
  flex: 1;
  font-size: 14px;
  color: var(--text);
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 18px;
  font-size: 14px;
  font-weight: 600;
}

.login-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(7, 13, 63, 0.6);
  backdrop-filter: blur(6px);
  display: none;
  align-items: center;
  justify-content: center;
  padding: 24px;
  z-index: 200;
}

.login-backdrop.open {
  display: flex;
}

.login-modal {
  width: min(92vw, 460px);
  background: white;
  border-radius: 24px;
  padding: 28px;
  box-shadow: 0 24px 60px rgba(7, 13, 63, 0.26);
  position: relative;
}

.close-modal {
  position: absolute;
  right: 16px;
  top: 16px;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: #f2f0ff;
  color: var(--primary);
  font-size: 22px;
  line-height: 1;
}

.login-modal h3 {
  font-size: 24px;
  color: var(--navy);
  margin-bottom: 8px;
}

.login-subtitle {
  color: var(--muted);
  font-size: 14px;
  margin-bottom: 20px;
}

.login-step {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.login-step.hidden {
  display: none;
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.form-group label {
  font-size: 13px;
  font-weight: 700;
  color: var(--navy);
}

.form-input {
  height: 48px;
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 0 14px;
  font-size: 14px;
  color: var(--text);
  outline: none;
}

.form-input:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(91, 53, 245, 0.12);
}

.login-actions {
  margin-top: 20px;
}

.login-submit {
  width: 100%;
  height: 50px;
  background: var(--primary);
  color: white;
  border-radius: 12px;
  font-weight: 800;
  box-shadow: 0 12px 24px rgba(91, 53, 245, 0.24);
}

.register {
  background: var(--primary);
  color: white;
  padding: 15px 24px;
  border-radius: 10px;
  font-weight: 700;
}

.cart {
  position: relative;
  font-size: 25px;
}

.cart span {
  position: absolute;
  right: -8px;
  top: -10px;
  width: 20px;
  height: 20px;
  background: var(--primary);
  color: white;
  font-size: 11px;
  border-radius: 50%;
  display: grid;
  place-items: center;
}

/* LAYOUT */

.top-grid {
  display: grid;
  grid-template-columns: 240px 1fr;
  gap: 24px;
}

.side-menu {
  background: white;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 20px;
  box-shadow: var(--shadow);
  height: fit-content;
}

.side-menu a {
  height: 58px;
  display: flex;
  align-items: center;
  gap: 14px;
  font-weight: 700;
  color: var(--navy);
  font-size: 14px;
  border-radius: 14px;
  padding: 0 14px;
}

.side-menu a:hover {
  background: #f2f0ff;
  color: var(--primary);
}

.side-menu i {
  font-style: normal;
  font-size: 21px;
  color: var(--primary);
}

/* HERO */

.hero {
  min-height: 420px;
  position: relative;
  overflow: hidden;
  background:
    radial-gradient(circle at 75% 30%, rgba(91, 53, 245, .18), transparent 32%),
    linear-gradient(135deg, #ffffff 0%, #f1f0ff 48%, #fff 100%);
  border: 1px solid var(--border);
  border-radius: 30px;
  box-shadow: var(--shadow);
  padding: 62px 56px;
  display: grid;
  grid-template-columns: 1.05fr .95fr;
  align-items: center;
}

.hero h1 {
  font-size: 58px;
  line-height: 1.08;
  letter-spacing: -2.5px;
  max-width: 680px;
  margin-bottom: 22px;
}

.hero h1 span {
  color: var(--primary);
}

.hero p {
  max-width: 600px;
  color: #404668;
  font-size: 18px;
  line-height: 1.7;
  margin-bottom: 28px;
}

.hero-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.hero-tags div {
  background: white;
  border: 1px solid #dddff6;
  color: var(--navy);
  padding: 14px 18px;
  border-radius: 14px;
  font-weight: 700;
  font-size: 13px;
  box-shadow: 0 10px 24px rgba(25, 30, 80, .06);
}

.hero-visual {
  height: 330px;
  border-radius: 28px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, .2), rgba(255, 255, 255, .9)),
    url("https://images.unsplash.com/photo-1522202176988-66273c2fd55f?q=80&w=1200&auto=format&fit=crop");
  background-size: cover;
  background-position: center;
  position: relative;
  overflow: hidden;
}

.free-badge {
  position: absolute;
  left: 30px;
  top: 28px;
  width: 145px;
  height: 145px;
  border-radius: 50%;
  background: #fff6a5;
  border: 4px solid #ffe74e;
  display: grid;
  place-items: center;
  text-align: center;
  font-weight: 900;
  color: var(--navy);
  transform: rotate(-8deg);
  box-shadow: 0 18px 30px rgba(0, 0, 0, .12);
}

.free-badge span {
  font-size: 20px;
  color: var(--primary);
  display: block;
}

/* TODAY COURSES */

.section {
  margin-top: 22px;
  background: white;
  border: 1px solid var(--border);
  border-radius: 24px;
  box-shadow: var(--shadow);
  padding: 24px;
}

.section-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 18px;
}

.section-title {
  font-size: 24px;
  font-weight: 900;
  letter-spacing: -.6px;
  color: var(--navy);
}

.section-title span {
  color: var(--primary);
}

.today-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 22px;
}

.lesson-card {
  border: 1px solid var(--border);
  border-radius: 18px;
  padding: 22px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: #fff;
}

.lesson-left {
  display: flex;
  align-items: center;
  gap: 18px;
}

.teacher {
  width: 62px;
  height: 62px;
  border-radius: 50%;
  object-fit: cover;
}

.lesson-time {
  font-size: 24px;
  font-weight: 900;
  color: var(--navy);
}

.live {
  display: inline-block;
  margin-left: 8px;
  padding: 5px 10px;
  border-radius: 6px;
  background: #ff1616;
  color: white;
  font-size: 11px;
  font-weight: 800;
}

.lesson-name {
  font-weight: 900;
  margin-top: 5px;
  color: var(--navy);
}

.lesson-desc {
  font-size: 13px;
  color: var(--muted);
  margin-top: 4px;
}

.join {
  background: var(--primary);
  color: white;
  padding: 15px 30px;
  border-radius: 10px;
  font-weight: 800;
  box-shadow: 0 12px 24px rgba(91, 53, 245, .24);
}

/* COURSE CARDS */

.tabs {
  display: flex;
  gap: 28px;
  font-weight: 700;
  color: var(--muted);
}

.tabs .active {
  color: var(--navy);
  position: relative;
}

.tabs .active::after {
  content: "";
  position: absolute;
  height: 3px;
  left: 0;
  right: 0;
  bottom: -10px;
  background: var(--primary);
  border-radius: 10px;
}

.course-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 30px;
}

.course-card {
  overflow: hidden;
  background: white;
  border: 1px solid var(--border);
  border-radius: 20px;
  box-shadow: 0 16px 35px rgba(23, 28, 80, .08);
}

.course-top {
  height: 190px;
  padding: 28px;
  color: white;
  position: relative;
}

/* .purple {
  background: linear-gradient(135deg, #6c38ff, #3724ad);
}

.green {
  background: linear-gradient(135deg, #19b36b, #08833f);
}

.blue {
  background: linear-gradient(135deg, #0b77d8, #063f89);
} */

.badge {
  font-size: 11px;
  font-weight: 900;
  color: #d7ff66;
  margin-bottom: 14px;
}

.course-top h3 {
  font-size: 58px;
  font-weight: 900;
  line-height: .9;
}

.course-top p {
  font-size: 18px;
  font-weight: 800;
  margin-top: 8px;
}

.course-meta {
  position: absolute;
  left: 28px;
  bottom: 22px;
  display: flex;
  gap: 18px;
  font-size: 13px;
  font-weight: 700;
}

.course-body {
  padding: 22px;
}

.course-body h4 {
  font-size: 16px;
  color: var(--primary);
  margin-bottom: 10px;
}

.course-body p {
  color: var(--muted);
  line-height: 1.5;
  font-size: 14px;
  margin-bottom: 22px;
}

.price-row {
  display: flex;
  justify-content: space-between;
  align-items: end;
}

.price {
  font-size: 24px;
  font-weight: 900;
  color: var(--navy);
}

.price small {
  display: block;
  font-size: 12px;
  color: var(--muted);
  font-weight: 600;
}

.cart-btn {
  width: 46px;
  height: 46px;
  border-radius: 12px;
  border: 1px solid #cfc7ff;
  color: var(--primary);
  background: white;
  font-size: 22px;
}

/* TESTIMONIALS */

.testimonial-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 22px;
}

.testimonial {
  border: 1px solid var(--border);
  border-radius: 18px;
  padding: 22px;
  background: white;
}

.testimonial p {
  font-size: 14px;
  line-height: 1.6;
  color: #3c4262;
  margin-bottom: 14px;
  font-weight: 600;
}

.stars {
  color: #ffb000;
  margin-bottom: 12px;
}

.user {
  display: flex;
  gap: 10px;
  align-items: center;
}

.user img {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  object-fit: cover;
}

.user strong {
  display: block;
  font-size: 13px;
}

.user span {
  font-size: 11px;
  color: var(--muted);
}

/* BOOKS */

.book-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 22px;
}

.book-card {
  border: 1px solid var(--border);
  border-radius: 18px;
  padding: 18px;
  background: white;
  display: grid;
  grid-template-columns: 90px 1fr;
  gap: 16px;
  align-items: center;
}

.book-cover {
  width: 90px;
  height: 120px;
  border-radius: 10px;
  background: linear-gradient(135deg, #3724ad, #ffce3a);
  display: grid;
  place-items: center;
  color: white;
  font-weight: 900;
  text-align: center;
  font-size: 22px;
}

.book-card h4 {
  font-size: 14px;
  line-height: 1.35;
  margin-bottom: 8px;
}

.book-card p {
  font-size: 12px;
  color: var(--muted);
  margin-bottom: 12px;
}

.old-price {
  font-size: 12px;
  color: #9ba0b8;
  text-decoration: line-through;
  margin-right: 8px;
}

.new-price {
  color: var(--primary);
  font-weight: 900;
}

/* BLOG */

.blog-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 22px;
}

.blog-card {
  border: 1px solid var(--border);
  border-radius: 18px;
  overflow: hidden;
  background: white;
}

.blog-card img {
  width: 100%;
  height: 120px;
  object-fit: cover;
}

.blog-content {
  padding: 15px;
}

.tag {
  display: inline-block;
  background: #eeeaff;
  color: var(--primary);
  padding: 4px 8px;
  border-radius: 8px;
  font-size: 11px;
  font-weight: 800;
  margin-bottom: 8px;
}

.blog-content h4 {
  font-size: 14px;
  line-height: 1.4;
  margin-bottom: 12px;
}

.blog-content small {
  color: var(--muted);
  font-size: 12px;
}

/* FOOTER */

.footer-top {
  margin-top: 26px;
  background: #f0efff;
  border: 1px solid var(--border);
  border-radius: 22px;
  padding: 24px 34px;
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  align-items: center;
  gap: 24px;
  font-weight: 700;
}

.footer {
  margin-top: 28px;
  padding-top: 30px;
  border-top: 1px solid var(--border);
  display: grid;
  grid-template-columns: 1.5fr repeat(4, 1fr);
  gap: 42px;
}

.footer h4 {
  font-size: 14px;
  margin-bottom: 18px;
  color: var(--navy);
}

.footer a {
  display: block;
  color: var(--muted);
  font-size: 14px;
  margin-bottom: 13px;
}

.footer-brand strong {
  display: block;
  font-size: 26px;
  color: var(--navy);
  margin-bottom: 10px;
}

.footer-brand p {
  color: var(--muted);
  max-width: 220px;
  line-height: 1.6;
}

.legal {
  border-top: 1px solid var(--border);
  margin-top: 34px;
  padding-top: 18px;
  display: flex;
  justify-content: space-between;
  color: #9094aa;
  font-size: 12px;
}

.payments {
  font-weight: 900;
  color: var(--blue);
  display: flex;
  gap: 20px;
}

/* RESPONSIVE */

@media (max-width: 1100px) {
  .top-grid {
    grid-template-columns: 1fr;
  }

  .side-menu {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
  }

  .hero {
    grid-template-columns: 1fr;
  }

  .course-grid,
  .testimonial-grid,
  .book-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .blog-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .today-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 760px) {
  .page {
    padding: 18px;
  }

  .header {
    flex-wrap: wrap;
  }

  .search {
    order: 5;
    width: 100%;
    flex: auto;
  }

  .side-menu {
    grid-template-columns: repeat(2, 1fr);
  }

  .hero {
    padding: 34px 24px;
  }

  .hero h1 {
    font-size: 38px;
  }

  .hero-visual {
    height: 240px;
  }

  .course-grid,
  .testimonial-grid,
  .book-grid,
  .blog-grid,
  .footer {
    grid-template-columns: 1fr;
  }

  .footer-top {
    grid-template-columns: 1fr;
  }

  .legal {
    flex-direction: column;
    gap: 16px;
  }
}