/*
Theme Name: Edu Learn Theme
Theme URI: https://example.com/edu-learn
Author: Your Name
Author URI: https://example.com
Description: A modern, responsive educational theme for programming tutorials (HTML, CSS, PHP, MySQL).
Version: 1.0
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: edu-learn
Tags: education, tutorial, responsive, modern, programming
*/

/* ---------- RESET ---------- */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: "Inter", sans-serif;
  line-height: 1.8;
  background-color: #f9f9fc;
  color: #333;
}

/* ---------- CONTAINER ---------- */
.container {
  width: 90%;
  max-width: 1200px;
  margin: 0 auto;
}

/* ---------- HEADER ---------- */
header {
  background-color: #512da8;
  color: #fff;
  padding: 1.5rem 0;
  text-align: center;
}

header h1 {
  font-size: 2rem;
  font-weight: 700;
}

nav.main-menu {
  margin-top: 1rem;
}

nav.main-menu a {
  color: #fff;
  text-decoration: none;
  margin: 0 12px;
  font-weight: 500;
}

nav.main-menu a:hover {
  text-decoration: underline;
}

/* ---------- SUB MENU (Courses) ---------- */
nav.sub-menu {
  background: #fff;
  border-bottom: 2px solid #d1c4e9;
  padding: 0.7rem 0;
}

nav.sub-menu a {
  color: #4527a0;
  text-decoration: none;
  font-weight: 600;
  margin: 0 10px;
}

nav.sub-menu a:hover {
  color: #311b92;
}

/* ---------- HERO / INTRO ---------- */
section.intro {
  text-align: center;
  padding: 3rem 0;
  background: linear-gradient(135deg, #ede7f6, #fff);
}

section.intro h1 {
  font-size: 2.5rem;
  color: #311b92;
  margin-bottom: 0.8rem;
}

section.intro p {
  font-size: 1.1rem;
  color: #555;
}

/* ---------- COURSE CARDS ---------- */
.courses-list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 1.5rem;
  padding: 3rem 0;
}

.course-card {
  background: #fff;
  border-radius: 1rem;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.1);
  padding: 1.2rem;
  transition: all 0.3s ease;
}

.course-card:hover {
  box-shadow: 0 6px 12px rgba(0, 0, 0, 0.15);
  transform: translateY(-4px);
}

.course-card img {
  width: 100%;
  border-radius: 0.7rem;
  margin-bottom: 1rem;
}

.course-card h2 {
  font-size: 1.3rem;
  color: #311b92;
  margin-bottom: 0.5rem;
}

.course-card p {
  color: #555;
  font-size: 0.95rem;
  height: 213px;
}

/* ---------- LESSON LIST ---------- */
.lessons-list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 1.2rem;
  margin-top: 1.5rem;
}

.lesson-card {
  background: #fff;
  border: 1px solid #ddd;
  border-radius: 0.8rem;
  padding: 1rem;
  transition: 0.3s;
      display: flex;
    flex-direction: column;
    
}

.lesson-card:hover {
  border-color: #7e57c2;
  box-shadow: 0 4px 10px rgba(126, 87, 194, 0.1);
}

.lesson-card h3 {
  font-size: 1.1rem;
  color: #4527a0;
  margin-bottom: 0.4rem;
      height: 70px;
}

.lesson-card p {
  font-size: 0.9rem;
  color: #666;
  height: 200px;
}

/* ---------- CONTENT AREA ---------- */
.entry-content {
  background: #fff;
  padding: 2rem;
  border-radius: 1rem;
  box-shadow: 0 3px 8px rgba(0, 0, 0, 0.1);
  margin-top: 2rem;
}

.entry-content h2, .entry-content h3 {
  color: #311b92;
  margin-top: 1.5rem;
}

.entry-content pre {
  background: #f5f5f5;
  padding: 1rem;
  border-radius: 0.5rem;
  overflow-x: auto;
  font-family: "Source Code Pro", monospace;
}

/* ---------- BUTTONS ---------- */
.btn-back {
   
  margin-top: 1.5rem;
  background: #7e57c2;
  color: #fff;
  padding: 0.7rem 1.2rem;
  border-radius: 0.5rem;
  text-decoration: none;
  transition: 0.3s;
      display: flex !important;
    align-items: center;
    justify-content: center;
}

.btn-back:hover {
  background: #5e35b1;
  border:2px solid #fff;
  color:#FFF;
}

/* ---------- FOOTER ---------- */
footer {
  background: #311b92;
  color: #fff;
  text-align: center;
  padding: 1.5rem 0;
  margin-top: 3rem;
  font-size: 0.9rem;
}

/* ---------- RESPONSIVE ---------- */
@media (max-width: 768px) {
  header h1 {
    font-size: 1.6rem;
  }
  section.intro h1 {
    font-size: 1.8rem;
  }
  .course-card, .lesson-card {
    padding: 1rem;
  }
}






/*/////////////////////////*/

/* ---------- FOOTER ---------- */
.site-footer {
  background-color: #311b92;
  color: #fff;
  text-align: center;
  padding: 2rem 1rem;
  margin-top: 3rem;
  border-top: 3px solid #7e57c2;
}

.footer-menu {
  margin-bottom: 1rem;
}

.footer-menu .footer-nav {
  list-style: none;
  padding: 0;
}

.footer-menu .footer-nav li {
  display: inline-block;
  margin: 0 10px;
}

.footer-menu .footer-nav a {
  color: #d1c4e9;
  text-decoration: none;
  font-weight: 500;
}

.footer-menu .footer-nav a:hover {
  color: #fff;
}

.footer-copy {
  font-size: 0.9rem;
  margin-top: 1rem;
}

.footer-link {
  color: #d1c4e9;
  text-decoration: underline;
}

.footer-link:hover {
  color: #fff;
}


.section-title {
  font-size: 1.8rem;
  font-weight: 700;
  text-transform: uppercase;
  color: #311b92;
}



.lessons-section h2 {
  font-size: 1.6rem;
  font-weight: 700;
  color: #311b92;
}

.lesson-card {
  background: #fff;
  border: 1px solid #ddd;
  border-radius: 1rem;
  padding: 1rem;
  margin-bottom: 1rem;
  box-shadow: 0 2px 5px rgba(0,0,0,0.05);
  transition: 0.3s;
}

.lesson-card:hover {
  border-color: #7e57c2;
  box-shadow: 0 4px 12px rgba(126,87,194,0.1);
}

.lesson-title a {
  color: #4527a0;
  text-decoration: none;
}

.lesson-title a:hover {
  color: #311b92;
  text-decoration: underline;
}



.single-lesson .lesson-title {
  font-size: 2rem;
  font-weight: 700;
  color: #311b92;
}

.lesson-meta {
  font-size: 1rem;
  color: #555;
}

.lesson-content {
  font-size: 1.05rem;
  line-height: 1.8;
  color: #333;
}

.lesson-content pre {
  background: #f4f1fa;
  border: 1px solid #e0d7f7;
  padding: 1rem;
  border-radius: 10px;
  overflow-x: auto;
}

.lesson-content code {
  background: #ede7f6;
  padding: 0.2rem 0.4rem;
  border-radius: 4px;
}

.back-course a {
  background: #4527a0;
  color: #fff;
  padding: 0.7rem 1.5rem;
  border-radius: 30px;
  text-decoration: none;
  transition: 0.3s;
}

.back-course a:hover {
  background: #311b92;
}



.archive-courses {
  padding: 2rem 1rem;
}

.archive-courses .page-title {
  font-size: 2rem;
  font-weight: 700;
  color: #311b92;
}

.courses-list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 1.5rem;
}

.course-card {
  background: #fff;
  border: 1px solid #ddd;
  border-radius: 1rem;
  padding: 1rem;
  box-shadow: 0 2px 6px rgba(0,0,0,0.05);
  transition: 0.3s ease;
  text-align: center;
}

.course-card:hover {
  transform: translateY(-5px);
  border-color: #7e57c2;
}

.course-title a {
  color: #4527a0;
  font-weight: 600;
  text-decoration: none;
}

.course-title a:hover {
  color: #311b92;
  text-decoration: underline;
}

.course-excerpt {
  font-size: 0.95rem;
  color: #555;
  margin-top: 0.5rem;
}

.pagination a {
  background: #4527a0;
  color: #fff;
  padding: 0.5rem 1rem;
  border-radius: 30px;
  text-decoration: none;
  margin: 0 0.2rem;
  transition: 0.3s;
}

.pagination a:hover {
  background: #311b92;
}
.archive-lessons {
  padding: 2rem 1rem;
}

.archive-lessons .page-title {
  font-size: 2rem;
  font-weight: 700;
  color: #311b92;
}

.lessons-list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 1.5rem;
}

.lesson-card {
  background: #fff;
  border: 1px solid #ddd;
  border-radius: 1rem;
  padding: 1rem;
  box-shadow: 0 2px 6px rgba(0,0,0,0.05);
  transition: 0.3s ease;
}

.lesson-card:hover {
  border-color: #7e57c2;
  transform: translateY(-5px);
}

.lesson-title a {
  color: #4527a0;
  font-weight: 600;
  text-decoration: none;
}

.lesson-title a:hover {
  color: #311b92;
  text-decoration: underline;
}

.lesson-excerpt {
  font-size: 0.95rem;
  color: #555;
  margin-top: 0.5rem;
}

.lesson-course {
  font-size: 0.9rem;
  color: #777;
  margin-top: 0.5rem;
}

.pagination a {
  background: #4527a0;
  color: #fff;
  padding: 0.5rem 1rem;
  border-radius: 30px;
  text-decoration: none;
  margin: 0 0.2rem;
  transition: 0.3s;
}

.pagination a:hover {
  background: #311b92;
}
.course-card {
  background: #fff;
  border: 1px solid #ddd;
  border-radius: 1rem;
  padding: 1rem;
  text-align: center;
  box-shadow: 0 2px 6px rgba(0,0,0,0.05);
  transition: 0.3s ease;
}

.course-card:hover {
  border-color: #7e57c2;
  transform: translateY(-5px);
}

.course-thumb {
  border-radius: 0.8rem;
  width: 100%;
  height: auto;
  margin-bottom: 1rem;
}

.course-title a {
  color: #4527a0;
  font-weight: 600;
  font-size: 1.2rem;
  text-decoration: none;
}

.course-title a:hover {
  color: #311b92;
  text-decoration: underline;
}

.course-excerpt {
  font-size: 0.95rem;
  color: #555;
  margin-top: 0.5rem;
  min-height: 3rem;
}

.course-meta {
  margin-top: 0.8rem;
  font-size: 0.85rem;
  color: #777;
}

.course-meta span {
  margin: 0 5px;
}
.breadcrumb {
  font-size: 0.9rem;
  margin-bottom: 1rem;
  color: #555;
}
.breadcrumb a {
  color: #4527a0;
  text-decoration: none;
}
.breadcrumb a:hover {
  text-decoration: underline;
}

.course-lessons {
  margin-top: 2rem;
}
.lesson-section-title {
  font-size: 1.3rem;
  font-weight: 600;
  color: #311b92;
  margin-bottom: 1rem;
}
.lesson-list {
  list-style: none;
  padding: 0;
}
.lesson-item {
  margin-bottom: 0.6rem;
}
.lesson-item a {
  color: #4527a0;
  text-decoration: none;
  transition: color 0.3s;
}
.lesson-item a:hover {
  color: #311b92;
}
