/* Basic reset */
/*
 * Import a modern Google font. Poppins provides clean, rounded letterforms
 * and works well for both headings and body text. Should the external
 * import fail, fall back to system fonts.
 */
@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@400;600;700&display=swap');

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  font-family: 'Poppins', 'Helvetica Neue', Arial, sans-serif;
}

body {
  color: #1f2937;
  line-height: 1.6;
}

/* Hero header */
.hero {
  background: linear-gradient(135deg, #3aa6d0 0%, #00c181 100%);
  color: white;
  text-align: center;
  padding: 4rem 2rem;
}

.hero .logo {
  width: 80px;
  height: 80px;
  margin-bottom: 1rem;
}

.hero h1 {
  font-size: 2.5rem;
  margin-bottom: 0.5rem;
}

.hero .tagline {
  font-size: 1.1rem;
  max-width: 600px;
  margin: 0 auto 1.5rem auto;
}

.hero .cta {
  display: inline-block;
  background: white;
  color: #00a86b;
  padding: 0.75rem 1.5rem;
  border-radius: 0.5rem;
  text-decoration: none;
  font-weight: bold;
  transition: background 0.3s;
}

.hero .cta:hover {
  background: #f8f9fa;
}

/* Features section */
.features {
  padding: 3rem 2rem;
  background: #f8f9fa;
}

.features h2 {
  text-align: center;
  margin-bottom: 2rem;
  font-size: 2rem;
}

.feature-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 1.5rem;
}

.feature-item {
  background: white;
  border-radius: 0.5rem;
  padding: 1.5rem;
  box-shadow: 0 2px 6px rgba(0,0,0,0.05);
}

.feature-item h3 {
  color: #009f72;
  margin-bottom: 0.5rem;
}

.feature-item p {
  font-size: 0.9rem;
  color: #4b5563;
}

/* Pricing section */
.pricing {
  padding: 3rem 2rem;
  background: white;
}

.pricing h2 {
  text-align: center;
  margin-bottom: 2rem;
  font-size: 2rem;
}

.pricing-grid {
  display: grid;
  gap: 2rem;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
}

.pricing-card {
  border: 1px solid #e5e7eb;
  border-radius: 0.5rem;
  padding: 1.5rem;
  text-align: center;
  box-shadow: 0 2px 6px rgba(0,0,0,0.05);
}

.pricing-card h3 {
  font-size: 1.5rem;
  margin-bottom: 0.5rem;
  color: #374151;
}

.pricing-card .price {
  font-size: 2rem;
  color: #00a86b;
  margin: 0.5rem 0;
  font-weight: bold;
}

.pricing-card ul {
  list-style: none;
  text-align: left;
  margin: 1rem 0 1.5rem 0;
}

.pricing-card li {
  margin-bottom: 0.5rem;
  color: #4b5563;
}

.pricing-card .btn {
  display: inline-block;
  background: linear-gradient(135deg, #3aa6d0 0%, #00c181 100%);
  color: white;
  padding: 0.75rem 1.5rem;
  border-radius: 0.5rem;
  text-decoration: none;
  font-weight: bold;
  transition: transform 0.2s, box-shadow 0.2s;
}

.pricing-card .btn:hover {
  transform: translateY(-3px);
  box-shadow: 0 4px 8px rgba(0,0,0,0.1);
}

/* CTA section */
.cta-section {
  text-align: center;
  padding: 3rem 2rem;
  background: #f8f9fa;
}

.cta-section h2 {
  font-size: 2rem;
  margin-bottom: 1rem;
}

.cta-section p {
  margin-bottom: 1.5rem;
  color: #4b5563;
}

.cta-section .btn {
  display: inline-block;
  background: linear-gradient(135deg, #3aa6d0 0%, #00c181 100%);
  color: white;
  padding: 0.75rem 1.5rem;
  border-radius: 0.5rem;
  text-decoration: none;
  font-weight: bold;
  transition: transform 0.2s, box-shadow 0.2s;
}

.cta-section .btn:hover {
  transform: translateY(-3px);
  box-shadow: 0 4px 8px rgba(0,0,0,0.1);
}

/* Footer */
footer {
  text-align: center;
  padding: 2rem 0;
  background: #1f2937;
  color: white;
  font-size: 0.875rem;
}

/* Sidebar navigation */
.sidebar {
  position: fixed;
  top: 0;
  left: 0;
  height: 100%;
  width: 260px;
  background: #1f2937;
  color: #ffffff;
  padding: 2rem 1rem;
  box-shadow: 2px 0 8px rgba(0, 0, 0, 0.1);
  transform: translateX(-100%);
  transition: transform 0.3s ease;
  z-index: 1000;
}

.sidebar.open {
  transform: translateX(0);
}

.sidebar button.sidebar-close {
  background: none;
  border: none;
  color: #ffffff;
  font-size: 1.5rem;
  position: absolute;
  top: 1rem;
  right: 1rem;
  cursor: pointer;
}

.sidebar ul {
  list-style: none;
  margin-top: 2rem;
}

.sidebar li {
  margin-bottom: 1rem;
}

.sidebar a.nav-link {
  color: #ffffff;
  text-decoration: none;
  font-size: 1rem;
  transition: color 0.2s;
}

.sidebar a.nav-link:hover,
.sidebar a.nav-link:focus {
  color: #00c181;
}

/* Sidebar toggle button */
.sidebar-toggle {
  position: fixed;
  top: 1rem;
  left: 1rem;
  z-index: 1100;
  background: #1f2937;
  color: #ffffff;
  border: none;
  padding: 0.5rem;
  border-radius: 4px;
  font-size: 1.5rem;
  cursor: pointer;
  box-shadow: 0 2px 4px rgba(0,0,0,0.2);
}

.sidebar-toggle:focus {
  outline: 2px solid #00c181;
}

/* About & courses sections */
.courses,
.about {
  padding: 3rem 2rem;
  background: #f8f9fa;
}

.courses h2,
.about h2 {
  text-align: center;
  margin-bottom: 1rem;
  font-size: 2rem;
}

.courses p,
.about p {
  max-width: 800px;
  margin: 0 auto;
  color: #4b5563;
  font-size: 1rem;
  line-height: 1.6;
}

/* E‑Book section */
.ebooks {
  padding: 3rem 2rem;
  background: white;
}

.ebooks h2 {
  text-align: center;
  margin-bottom: 1rem;
  font-size: 2rem;
}

.ebooks-intro {
  text-align: center;
  max-width: 700px;
  margin: 0 auto 2rem auto;
  color: #4b5563;
  font-size: 0.95rem;
}

.ebook-list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 1.5rem;
}

.ebook-item {
  border: 1px solid #e5e7eb;
  border-radius: 0.5rem;
  padding: 1rem;
  text-align: center;
  background: #f9fafb;
  box-shadow: 0 2px 4px rgba(0,0,0,0.04);
}

.ebook-item h3 {
  margin-bottom: 1rem;
  color: #374151;
  font-size: 1.2rem;
}

/* New styling for interactive book cards */
.ebook-card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 1.5rem;
  margin-top: 2rem;
}

.book-card {
  position: relative;
  width: 100%;
  height: 340px;
  perspective: 1000px;
  cursor: pointer;
}

.card-inner {
  position: absolute;
  width: 100%;
  height: 100%;
  transition: transform 0.8s;
  transform-style: preserve-3d;
}

.book-card.flipped .card-inner {
  transform: rotateY(180deg);
}

.card-front, .card-back {
  position: absolute;
  width: 100%;
  height: 100%;
  backface-visibility: hidden;
  border-radius: 0.5rem;
  overflow: hidden;
  box-shadow: 0 2px 6px rgba(0,0,0,0.05);
}

.card-front img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.card-back {
  background: #ffffff;
  padding: 1rem;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  transform: rotateY(180deg);
  color: #1f2937;
}

.card-back h3 {
  font-size: 1.2rem;
  margin-bottom: 0.5rem;
  text-align: center;
  color: #009f72;
}

.card-back p {
  font-size: 0.9rem;
  margin-bottom: 1rem;
  text-align: center;
  color: #4b5563;
}

.card-back .btn-buy {
  display: inline-block;
  background: linear-gradient(135deg, #3aa6d0 0%, #00c181 100%);
  color: white;
  padding: 0.6rem 1rem;
  border-radius: 0.4rem;
  text-decoration: none;
  font-weight: 600;
  transition: transform 0.2s, box-shadow 0.2s;
}

.card-back .btn-buy:hover {
  transform: translateY(-3px);
  box-shadow: 0 4px 8px rgba(0,0,0,0.1);
}