/* ========== VARIABLES ========== */
:root {
  --primary-color: #E10489;
  --primary-gradient: linear-gradient(103deg, #fc6668 0%, #E10489 100%);
  --heading-color: #002050;
  --body-bg: #ffffff;
  --muted: #6b6b6b;
  --max-width: 1200px;
  --header-height: 64px;
  --menu-width: 280px;

  /* Additional shared variables */
  --primary-bg: linear-gradient(103deg, #fc6668 0%, #E10489 100%);
  --primary-text: #002050;
}

/* ========== RESET ========== */
* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}
html, body {
  height: 100%;
}
body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  background: var(--body-bg);
  color: var(--heading-color);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* ========== CONTAINER & PAGE CONTENT ========== */
.container {
  width: 100%;
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0;
  background: #f9fafc;
}

.page-content {
  padding-top: calc(var(--header-height) + 12px);
  transition: transform 0.32s ease;
}

/* ========== LINKS ========== */
a {
  color: var(--heading-color);
  text-decoration: none;
}
a:hover {
  text-decoration: underline;
}

/* ========== HEADER ========== */
header {
  background: var(--primary-gradient);
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 999;
  color: white;
}

.header-container {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 60px;
}

.logo {
  font-size: 20px;
  font-weight: bold;
  color: white;
  text-decoration: none;
}

.nav-links {
  display: flex;
  gap: 24px;
}
.nav-links a {
  color: white;
  font-weight: 500;
}
.nav-links a:hover {
  text-decoration: underline;
}

/* Mobile icons layout */
.mobile-header {
  display: none;
  width: 100%;
  justify-content: space-between;
  align-items: center;
}

.hamburger, .search-icon {
  font-size: 30px;
  cursor: pointer;
  background: none;
  border: none;
  color: white;
}

/* Mobile menu slider */
.mobile-menu {
  position: fixed;
  top: 0;
  left: -250px; /* hidden initially */
  width: 250px;
  height: 100%;
  background: white;
  padding: 60px 20px;
  display: flex;
  flex-direction: column;
  gap: 16px;
  box-shadow: 2px 0 10px rgba(0,0,0,0.2);
  transition: left 0.3s ease-in-out;
  z-index: 1001;
}
.mobile-menu a {
  color: var(--heading-color);
  font-weight: 500;
  text-decoration: none;
}

/* Overlay */
.menu-overlay {
  display: none;
  position: fixed;
  top: 0; left: 0;
  width: 100%; height: 100%;
  background: rgba(0,0,0,0.4);
  z-index: 998;
}

.mobile-menu.active {
  left: 0;
}
.menu-overlay.active {
  display: block;
}

/* Responsive header */
@media (max-width: 768px) {
  .desktop-menu {
    display: none;
  }
  .mobile-header {
    display: flex;
  }
}

/* ========== FOOTER ========== */
.site-footer {
  background: var(--primary-gradient);
  color: var(--heading-color);
  font-family: inherit;
  margin-top: 20px;
}

.footer-container {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 20px;
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
}

.footer-logo img {
  height: 40px;
}

.footer-nav ul {
  list-style: none;
  display: flex;
  gap: 20px;
  margin: 0; padding: 0;
}

.footer-nav a {
  color: var(--heading-color);
  text-decoration: none;
  font-weight: 500;
}
.footer-nav a:hover {
  text-decoration: underline;
}

.footer-social a {
  color: var(--heading-color);
  margin-left: 15px;
  font-size: 1.2rem;
}

.footer-bottom {
  background-color: rgba(255,255,255,0.15);
  text-align: center;
  padding: 10px 0;
  font-size: 0.9rem;
}

/* Responsive footer */
@media (max-width: 768px) {
  .footer-container {
    flex-direction: column;
    align-items: center;
    text-align: center;
  }
  .footer-nav ul {
    flex-direction: column;
    gap: 10px;
    margin-top: 15px;
  }
  .footer-social {
    margin-top: 15px;
  }
}

/* ========== COMMON SECTIONS ========== */
.common-section {
  display: flex;
  max-width: var(--max-width);
  margin: 0 auto 20px auto;
  gap: 30px;
  padding: 0 15px;
}

/* Section Title */
.section-title {
  font-size: 1.8rem;
  color: var(--primary-text);
  margin-bottom: 25px;
  border-left: 4px solid var(--primary-color);
  padding-left: 10px;
  margin-top: 1rem;
  text-align: left;
}

/* Responsive section title */
@media (max-width: 768px) {
  .section-title {
    font-size: 1.2rem;
    margin-bottom: 20px;
    padding-left: 8px;
  }
}
@media (max-width: 480px) {
  .section-title {
    font-size: 1.2rem;
    margin-bottom: 18px;
    padding-left: 6px;
  }
}

/* ========== NEWS SECTION ========== */
.news-section {
  display: flex;
  max-width: var(--max-width);
  margin: 0 auto 30px auto;
  gap: 30px;
  padding: 0 15px;
}

.news-container {
  flex: 3;
}

.news-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 25px;
}

.news-card {
  background: white;
  border-radius: 12px;
  box-shadow: 0 2px 8px rgb(0 0 0 / 0.1);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: transform 0.2s ease;
}
.news-card:hover {
  transform: translateY(-5px);
}

.image-wrapper {
  position: relative;
  width: 100%;
  height: 160px;
  overflow: hidden;
  border-top-left-radius: 12px;
  border-top-right-radius: 12px;
  background-color: #eee;
}
.image-placeholder {
  position: absolute;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 37%, #f0f0f0 63%);
  background-size: 400% 100%;
  animation: loadingShimmer 1.2s ease infinite;
}
.image-wrapper img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  border-top-left-radius: 12px;
  border-top-right-radius: 12px;
}

/* News content */
.news-content {
  padding: 15px 18px 20px 18px;
  flex-grow: 1;
  display: flex;
  flex-direction: column;
}
.news-title {
  font-size: 1.2rem;
  color: var(--primary-text);
  margin-bottom: 5px;
  font-weight: 600;
  line-height: 1.3;
}
.news-date {
  font-size: 0.85rem;
  color: #666;
  margin-bottom: 12px;
}
.news-excerpt {
  font-size: 0.95rem;
  color: #444;
  flex-grow: 1;
  margin-bottom: 15px;
  overflow: hidden;
  text-overflow: ellipsis;
  max-height: 3.5em; /* approx 2 lines */
}

/* Read More Button */
.read-more {
  align-self: flex-start;
  background: var(--primary-gradient);
  color: white;
  padding: 8px 16px;
  border-radius: 20px;
  font-size: 0.9rem;
  font-weight: 600;
  text-decoration: none;
  transition: opacity 0.2s ease;
}
.read-more:hover,
.read-more:focus {
  opacity: 0.85;
}

.read-more1 {
  align-self: flex-start;
    color: var(--primary-color);
    padding: 5px 5px;
    font-size: 1rem;
    font-weight: 600;
    text-decoration: underline;
    transition: opacity 0.2s ease;
    font-style: italic;
}
.read-more1:hover,
.read-more1:focus {
  opacity: 0.85;
}

/* ========== PAGINATION ========== */
.pagination {
  display: inline-block;
  justify-content: center;
  gap: 10px;
  margin-top: 40px;
  flex-wrap: wrap;
}
.pagination a {
  display: inline-block;
  padding: 8px 14px;
  background: #f5f5f5;
  color: var(--primary-text);
  border-radius: 6px;
  font-weight: 600;
  text-decoration: none;
  min-width: 36px;
  text-align: center;
  user-select: none;
  transition: background 0.2s ease;
  border: 1px solid transparent;
}
.pagination a:hover {
  background: var(--primary-gradient);
  color: white;
  border-color: var(--primary-gradient);
}
.pagination a.active {
  background: var(--primary-gradient);
  color: white;
  border-color: var(--primary-gradient);
  cursor: default;
}
.pagination a.prev,
.pagination a.next {
  font-weight: 700;
}

/* Responsive pagination */
@media (max-width: 480px) {
  .pagination {
    gap: 6px;
  }
  .pagination a {
    padding: 6px 10px;
    min-width: 30px;
    font-size: 0.85rem;
  }
}

/* ========== FAQS ========== */
.faqs-section {
  margin: 0px 0;
  padding: 20px;
/*  background: #fff;*/
  border-radius: 10px;
  box-shadow: 0 3px 6px rgba(0,0,0,0.08);
}

.accordion {
  width: 100%;
}
.accordion-item {
  border-bottom: 1px solid #ddd;
}
.accordion-header {
  background: none;
  border: none;
  outline: none;
  width: 100%;
  text-align: left;
  padding: 15px;
  font-size: 1.2rem;
  font-weight: 600;
  color: var(--heading-color);
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.accordion-header::after {
  content: '+';
  font-size: 1.2rem;
  transition: transform 0.3s ease;
}
.accordion-header.active::after {
  transform: rotate(45deg);
}
.accordion-content {
  max-height: 0;
  overflow: hidden;
  transition: all 0.3s ease;
  padding: 0 15px;
  font-size: 0.95rem;
  line-height: 1.5;
  color: #444;
}
.accordion-content p {
  margin: 10px 0 15px;
}
.accordion-header.active + .accordion-content {
  max-height: 500px;
/*  padding: 10px 15px 15px;*/
}

/* FAQ Responsive */
@media (max-width: 768px) {
  .accordion-header {
    font-size: 1rem;
    padding: 12px;
  }
  .accordion-content {
    font-size: 0.9rem;
    padding: 0 12px;
  }
  .accordion-content p {
    margin: 8px 0 12px;
  }
}

/* ========== ARTICLES SIDEBAR LAYOUT ========== */
.articles-sidebar-layout {
  display: flex;
  max-width: var(--max-width);
  margin: 0 auto 60px auto;
  gap: 15px;
  padding: 30px 15px 0;
}

/* Articles list 75% */
.articles-list {
  flex: 2.5;
}

/* Article card */
.article-card {
  display: flex;
  background: white;
  border-radius: 12px;
  box-shadow: 0 2px 10px rgb(0 0 0 / 0.1);
  overflow: hidden;
  margin-bottom: 20px;
  transition: transform 0.2s ease;
}
.article-card:hover {
  transform: translateY(-5px);
}

/* Article text */
.article-text {
  flex: 2;
  padding: 10px 25px;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

/* Article title */
.article-title {
  font-size: 1.3rem;
  color: var(--primary-text);
  margin-bottom: 12px;
  font-weight: 600;
  line-height: 1.3;
}

/* Article excerpt */
.article-excerpt {
  color: #444;
  font-size: 1rem;
  flex-grow: 1;
  margin-bottom: 18px;
  line-height: 1.5;
  max-height: 5em;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* Read more button */
.article-text .read-more {
  align-self: flex-start;
  background: var(--primary-gradient);
  color: white;
  padding: 8px 18px;
  border-radius: 20px;
  font-weight: 600;
  font-size: 0.95rem;
  text-decoration: none;
  transition: opacity 0.2s ease;
}
.article-text .read-more:hover,
.article-text .read-more:focus {
  opacity: 0.85;
}

/* Article image wrapper */
.article-image-wrapper {
  flex: 1;
  position: relative;
/*  min-width: 180px;*/
/*  max-width: 280px;*/
  height: auto;
  overflow: hidden;
  background-color: #eee;
  height: 195px;
}

/* Image placeholder shimmer */
.article-image-wrapper .image-placeholder {
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 37%, #f0f0f0 63%);
  background-size: 400% 100%;
  animation: loadingShimmer 1.2s ease infinite;
}

/* Article image */
.article-image-wrapper img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

/* Responsive article cards */
@media (max-width: 768px) {
  .articles-sidebar-layout {
    flex-direction: column;
    padding: 0px;
  }
  .article-card {
    flex-direction: column;
  }
  .article-image-wrapper {
    position: relative;
    width: 100%;
    min-height: 160px;
    border-top-left-radius: 12px;
    border-top-right-radius: 12px;
    background-color: rgb(238, 238, 238);
    overflow: hidden;
  }
  .article-text {
    padding: 15px 20px;
  }
  .article-title {
    font-size: 1.1rem;
  }
  .article-excerpt {
    max-height: none;
  }
}
/* ========== ARTICLE DETAIL PAGE (DESKTOP) ========== */
.articles-detail {
  flex: 2.5;
  background: #fff;
  padding: 1.5rem 2rem;
  border-radius: 8px;
  box-shadow: 0 4px 10px rgba(0,0,0,0.1);
  color: var(--heading-color);
}

.articles-detail .article-title {
  font-size: 2.5rem;
  font-weight: 700;
  margin-bottom: 1rem;
  border-left: 4px solid var(--primary-color);
  padding-left: 12px;
}

.articles-detail .cover-image-wrapper {
  position: relative;
    width: 100%;
    /* margin-bottom: 1.5rem; */
    border-radius: 8px;
    overflow: hidden;
    /* box-shadow: 0 3px 8px rgba(0, 0, 0, 0.15); */
    /* background: #e0e0e0; */
    min-height: 300px;
    overflow: hidden;
    position: relative;
}

.articles-detail .image-placeholder {
  position: absolute;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 37%, #f0f0f0 63%);
  background-size: 400% 100%;
  animation: loadingShimmer 1.2s ease infinite;
}

.articles-detail .article-content {
  font-size: 1.15rem;
  line-height: 1.6;
  color: var(--primary-text);
  margin-top: 10px;
}

/* ===== ARTICLE DETAIL CONTENT (DESKTOP) ===== */
.articles-detail {
  flex: 2.5;
  background: #fff;
  padding: 1.5rem 2rem;
  border-radius: 8px;
  box-shadow: 0 4px 10px rgba(0,0,0,0.1);
  color: var(--primary-text);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  line-height: 1.6;
  font-size: 1.15rem;
}

/* Paragraphs */
.articles-detail p {
  margin-bottom: 1.2rem;
  color: #333;
}

/* Links */
.articles-detail a {
  color: var(--primary-color);
  text-decoration: underline;
  transition: color 0.3s ease;
}
.articles-detail a:hover,
.articles-detail a:focus {
  color: #fc6668;
  outline: none;
}

/* Headings inside article content */
.articles-detail h2,
.articles-detail h3,
.articles-detail h4 {
  color: var(--heading-color);
  margin-top: 2rem;
  margin-bottom: 1rem;
  font-weight: 700;
  line-height: 1.3;
}

/* Lists */
.articles-detail ul,
.articles-detail ol {
  margin-left: 1.5rem;
  margin-bottom: 1.5rem;
  color: #444;
  font-size: 1rem;
}

.articles-detail ul li,
.articles-detail ol li {
  margin-bottom: 0.5rem;
  line-height: 1.5;
}

/* Inline divs and other block containers */
.articles-detail div {
  margin-bottom: 1rem;
  color: #333;
}

/* Images inside article content */
.articles-detail img {
  max-width: 100%;
  height: auto;
  border-radius: 6px;
  margin: 1.5rem 0;
  display: block;
}

/* Blockquotes */
.articles-detail blockquote {
  border-left: 4px solid var(--primary-color);
  padding-left: 1rem;
  color: #555;
  font-style: italic;
  margin: 1.5rem 0;
  background: #f9f1f5;
  border-radius: 4px;
}


/* ===== ARTICLE DETAIL CONTENT (MOBILE) ===== */
@media (max-width: 768px) {
  .articles-detail {
    padding: 1rem;
    font-size: 1rem;       /* ~16px */
    line-height: 1.4;
  }

  /* Headings */
  .articles-detail h2,
  .articles-detail h3,
  .articles-detail h4 {
    margin: 1.5rem 0 0.8rem 0;
    font-size: 1.3rem;    /* ~21px */
    line-height: 1.3;
  }

  /* Text blocks */
  .articles-detail p,
  .articles-detail div,
  .articles-detail ul,
  .articles-detail ol,
  .articles-detail li {
    font-size: 0.95rem;   /* ~15px */
    margin-bottom: 1rem;
  }

  .articles-detail ul,
  .articles-detail ol {
    margin-left: 1.2rem;
  }

  /* Images */
  .articles-detail img {
    margin: 1rem 0;
    max-width: 100%;
    height: auto;
  }

  /* Blockquotes */
  .articles-detail blockquote {
    padding-left: 0.8rem;
    margin: 1rem 0;
    font-size: 0.9rem;    /* ~14px */
    line-height: 1.5;
  }
}




/* ========== ARTICLE DETAIL PAGE (MOBILE) ========== */
@media (max-width: 768px) {
  .articles-detail {
    padding: 1rem 1.2rem;
    box-shadow: 0 3px 6px rgba(0,0,0,0.07);
  }

  .articles-detail .article-title {
    font-size: 1.8rem;
    margin-bottom: 0.8rem;
    padding-left: 10px;
  }

  .articles-detail .cover-image-wrapper {
    min-height: 220px;
    margin-bottom: 1rem;
  }

  .articles-detail .article-content {
    font-size: 1rem;
    line-height: 1.4;
    margin-top: 8px;
  }
}


/* ========== QUIZ SECTION ========== */
.quiz-detail-section {
  flex: 2.5;
  background: #fff;
  padding: 1.5rem 2rem;
  border-radius: 8px;
  box-shadow: 0 3px 12px rgba(0,0,0,0.1);
}

.quiz-listing-section {
  flex: 1;
  background: #f9f9f9;
  border-radius: 8px;
  padding: 1rem 1.5rem;
  box-shadow: 0 3px 6px rgba(0,0,0,0.05);
  color: var(--primary-text);
}

/* Quiz card */
.quiz-card {
  background: white;
  border-radius: 12px;
  box-shadow: 0 2px 8px rgba(0,0,0,0.07);
  padding: 18px 20px;
  margin-bottom: 24px;
  transition: transform 0.2s ease;
  cursor: pointer;
}
.quiz-card:hover {
  transform: translateY(-4px);
}

/* Quiz title */
.quiz-title {
  font-size: 1.25rem;
  font-weight: 700;
  margin-bottom: 8px;
  color: var(--primary-text);
}

/* Quiz description */
.quiz-description {
  font-size: 1rem;
  color: #444;
  margin-bottom: 12px;
  line-height: 1.4;
}

/* Quiz options */
.quiz-option {
  display: block;
  background: #f0f0f0;
  border-radius: 8px;
  padding: 10px 14px;
  margin-bottom: 0px;
  cursor: pointer;
  font-size: 1rem;
  transition: background 0.2s ease;
  user-select: none;
}
.quiz-option:hover,
.quiz-option:focus {
  background: var(--primary-gradient);
  color: white;
  outline: none;
}
.quiz-option:focus {
  outline: 3px solid var(--primary-color);
  outline-offset: 2px;
}

/* Quiz submit button */
.quiz-btn {
  background: var(--primary-gradient);
  color: white;
  font-weight: 600;
  padding: 12px 22px;
  border-radius: 28px;
  border: none;
  cursor: pointer;
  font-size: 1rem;
  transition: opacity 0.25s ease;
  user-select: none;
  margin-top: 12px;
  display: inline-block;
}
.quiz-btn:hover,
.quiz-btn:focus {
  opacity: 0.85;
  outline: none;
}

/* ========== SIDEBAR ========== */
.sidebar {
  flex: 1;
  background: #f9f9f9;
  padding: 1rem 1.5rem;
  border-radius: 8px;
/*  box-shadow: 0 3px 6px rgba(0,0,0,0.05);*/
  color: var(--primary-text);
  font-size: 0.95rem;
  max-width: var(--menu-width);
}

/* ========== ANIMATIONS ========== */
@keyframes loadingShimmer {
  0% {
    background-position: -400% 0;
  }
  100% {
    background-position: 400% 0;
  }
}

/* ========== MEDIA QUERIES ========== */

/* Mobile adjustments */
@media (max-width: 768px) {
  .articles-sidebar-layout,
  .common-section,
  .news-section {
    flex-direction: column;
/*    padding: 0 12px;*/
  }
  .sidebar {
    max-width: 100%;
    margin-top: 20px;
  }
}

/* Smaller mobile */
@media (max-width: 480px) {
  .header-container {
    padding: 0 12px;
  }
  .container {
      padding: 0px;
  }
  .section-title {
    font-size: 1.2rem;
  }
  .quiz-card {
    padding: 14px 16px;
  }
  .quiz-btn {
    padding: 10px 18px;
  }
}


.sidebar {
  width: 100%;
  padding: 0 2px;
  box-sizing: border-box;
  min-width: 340px;
}

.sidebar .widget {
  background: white;
  border-radius: 12px;
  padding: 20px;
  margin-bottom: 30px;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
}

.sidebar .widget-title {
  font-size: 1.2rem;
  font-weight: 600;
  color: #002050;
  margin-bottom: 15px;
  border-left: 4px solid #E10489; /* matching primary color */
  padding-left: 10px;
}
 .widget {
  background: white;
  border-radius: 12px;
  padding: 20px;
  margin-bottom: 30px;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
}

 .widget-title {
  font-size: 1.2rem;
  font-weight: 600;
  color: #002050;
  margin-bottom: 15px;
  border-left: 4px solid #E10489; /* matching primary color */
  padding-left: 10px;
}

/* Search widget */
.sidebar .search-widget input[type="search"] {
  width: 100%;
  padding: 10px 15px;
  border: 1px solid #E10489;
  border-radius: 6px;
  font-size: 1rem;
  color: #002050;
  outline: none;
  transition: border-color 0.3s ease;
}

.sidebar .search-widget input[type="search"]:focus {
  border-color: #fc6668;
}

.sidebar .search-form {
  display: flex;
  gap: 8px;
}

.sidebar .search-form input[type="search"] {
  flex-grow: 1;
  padding: 8px 12px;
  border: 1px solid #ccc;
  border-radius: 4px;
  font-size: 1rem;
}

.sidebar .search-form button {
  background: var(--primary-bg);
  border: none;
  color: white;
  padding: 0 16px;
  border-radius: 4px;
  font-size: 1.2rem;
  cursor: pointer;
  transition: background 0.3s ease;
}

.sidebar .search-form button:hover {
  background: var(--primary-bg-hover, #e10489cc);
}

/* Tags widget */
.sidebar .tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.sidebar .tags a {
  display: inline-block;
  background: linear-gradient(103deg, #fc6668 0%, #E10489 100%);
  color: white;
  padding: 6px 12px;
  border-radius: 20px;
  font-size: 0.9rem;
  text-decoration: none;
  transition: background 0.3s ease;
}
 .tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

 .tags a {
  display: inline-block;
  background: linear-gradient(103deg, #fc6668 0%, #E10489 100%);
  color: white;
  padding: 6px 12px;
  border-radius: 20px;
  font-size: 0.9rem;
  text-decoration: none;
  transition: background 0.3s ease;
}

.sidebar .tags a:hover {
  background: #002050;
}
 .tags a:hover {
  background: #002050;
}

/* Categories & Recent Posts lists */
.sidebar .category-list,
.sidebar .recent-posts {
  list-style: none;
  padding-left: 0;
  margin: 0;
}

.sidebar .category-list li,
.sidebar .recent-posts li {
  margin-bottom: 10px;
}

.sidebar .category-list li a,
.sidebar .recent-posts li a {
  text-decoration: none;
  color: #002050;
  font-size: 1rem;
  transition: color 0.3s ease;
}

.sidebar .category-list li a:hover,
.sidebar .recent-posts li a:hover {
  color: #E10489;
}

/* ===== MOBILE RESPONSIVE ===== */
@media (max-width: 768px) {
  .sidebar {
    width: 100%;
/*    padding: 0 10px;*/
  }

  .sidebar .widget {
    padding: 15px;
    margin-bottom: 20px;
  }

  .sidebar .widget-title {
    font-size: 1.1rem;
    padding-left: 8px;
    margin-bottom: 12px;
  }
  .widget {
    padding: 15px;
    margin-bottom: 20px;
  }

   .widget-title {
    font-size: 1.1rem;
    padding-left: 8px;
    margin-bottom: 12px;
  }

  .sidebar .search-widget input[type="search"],
  .sidebar .search-form input[type="search"] {
    font-size: 0.95rem;
    padding: 8px 10px;
  }

  .sidebar .search-form button {
    font-size: 1rem;
    padding: 0 12px;
  }

  .sidebar .tags a {
    font-size: 0.85rem;
    padding: 5px 10px;
  }

   .tags a {
    font-size: 0.85rem;
    padding: 5px 10px;
  }

  .sidebar .category-list li a,
  .sidebar .recent-posts li a {
    font-size: 0.95rem;
  }
}

  /* Base: show everywhere */
.show-mobile,
.show-desktop,
.hide-mobile,
.hide-desktop {
  display: initial !important;
}

/* Mobile breakpoint */
@media (max-width: 767px) {
  .hide-mobile {
    display: none !important;
  }
  .show-mobile {
    display: initial !important;
  }
  .hide-desktop {
    display: initial !important;
  }
  .show-desktop {
    display: none !important;
  }
}

/* Desktop breakpoint */
@media (min-width: 768px) {
  .hide-desktop {
    display: none !important;
  }
  .show-desktop {
    display: initial !important;
  }
  .hide-mobile {
    display: initial !important;
  }
  .show-mobile {
    display: none !important;
  }
}

.ads-container {
    margin: 20px auto;
    text-align: center;
    /*min-height: 100px; /* placeholder space before ad loads */*/
    max-width: 100%;
}


/* ========== MOBILE OPTIMIZATION FOR ARTICLE TEXT ========= */
@media (max-width: 768px) {
  /* Uniform font-size for title, date, excerpt */
  .articles-detail .article-title,
  .articles-list .article-title,
  .article-card .article-title {
    font-size: 1.2rem;
    line-height: 1.2;
  }

  .articles-detail .news-date,
  .articles-list .news-date,
  .article-card .news-date {
    font-size: 0.9rem;
  }

  .articles-detail .news-excerpt,
  .articles-list .article-excerpt,
  .article-card .article-excerpt {
    font-size: 1rem;
    line-height: 1.5;
    max-height: none; /* allow full text for mobile */
  }
}


.ads-container {
  max-height: 300px; /* your expected slot height */
  overflow: hidden;
  transition: max-height 0.6s ease, opacity 0.6s ease, margin 0.6s ease;
}

.ads-container.collapsed {
  max-height: 0;
  opacity: 0;
  margin: 0 !important;
  display: none;
}

.category-funfact {
  font-size: 1.1rem;
  color: #555;
  margin-bottom: 0.5rem;
  font-style: italic;
}



    /* ========== FLEX GRID UTILITIES ========== */
    /* ========== FLEX GRID UTILITIES ========== */
    .flex-grid {
        display: flex;
        flex-wrap: wrap;
        margin: -8px; /* negative margin cancels padding */
    }
    .flex-grid > * {
        padding: 8px;
    }

    /* Equal columns */
    .col-1 {
        flex: 1 1 100%;
    }
    .col-2 {
        flex: 1 1 calc(50% - 16px);
    }
    .col-3 {
        flex: 1 1 calc(33.333% - 16px);
    }
    .col-4 {
        flex: 1 1 calc(25% - 16px);
    }

    /* Asymmetric widths */
    .col-75 {
        flex: 0 0 75%;
        max-width: 75%;
    }
    .col-25 {
        flex: 0 0 25%;
        max-width: 25%;
    }

    .col-66 {
        flex: 0 0 66.666%;
        max-width: 66.666%;
    } /* 2/3 */
    .col-33 {
        flex: 0 0 33.333%;
        max-width: 33.333%;
    } /* 1/3 */

    /* Responsive tweak: stack on mobile */
    @media (max-width: 768px) {
        .col-2,
        .col-3,
        .col-4,
        .col-25,
        .col-33,
        .col-66,
        .col-75 {
            flex: 1 1 100%;
            max-width: 100%;
        }
    }

    .kwizr-trivia {
        background: #fff;
        border: 1px solid #eee;
        border-radius: 10px;
        padding: 15px;
        margin: 20px 0;
        font-family: sans-serif;
        max-width: 100%;
        box-shadow: 0 2px 5px rgba(0, 0, 0, 0.05);
    }
    .kwizr-trivia h3 {
        font-size: 16px;
        margin-bottom: 10px;
        color: #e10489;
        display: flex;
        align-items: center;
        gap: 5px;
    }

    .kwizr-trivia .category-funfact {
        margin-bottom: 1.1rem;
    }
    .kwizr-trivia .question {
        font-size: 18px;
        margin-bottom: 12px;
        font-weight: bold;
        color: var(--primary-text);
    }
    .kwizr-trivia .options {
        display: flex;
        flex-direction: column;
        gap: 8px;
    }
    .kwizr-trivia .options button {
        padding: 10px;
        font-size: 14px;
        border: 1px solid #002050;
        border-radius: 8px;
        /* background: #f8f8f8; */
        cursor: pointer;
        text-align: left;
        /* transition: background 0.2s; */
        background-size: 26px;
        background: white;
        font-weight: 700;
        color: #002050;
    }
    .kwizr-trivia .options button:hover {
        background: #eee;
        color: var(--primary-color);
    }
    .kwizr-trivia .options button.correct {
        background: #d4edda;
        border-color: #28a745;
        color: #155724;
    }
    .kwizr-trivia .options button.wrong {
        background: #f8d7da;
        border-color: #dc3545;
        color: #721c24;
    }
    .kwizr-trivia .score {
        font-size: 14px;
        margin-top: 10px;
        font-weight: bold;
        text-align: center;
    }

    .quiz-grid {
        display: grid;
        grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
        gap: 1rem;
        padding: 1rem;
    }

    .quiz-card {
        background-color: #fff;
        border-radius: 8px;
        box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
        padding: 0.8rem 1rem;
        display: flex;
        align-items: center;
        justify-content: space-between;
        transition: transform 0.2s ease;
    }

    .quiz-card:hover {
        transform: translateY(-3px);
    }

    .quiz-title {
        font-size: 0.95rem;
        font-weight: 400;
        color: #333;
        margin: 0;
        flex: 1;
        margin-right: 0.5rem;
    }

    .quiz-button {
        background: linear-gradient(135deg, #f43676, #d82a61);
        color: #fff;
        padding: 0.4rem 0.8rem;
        border-radius: 4px;
        text-decoration: none;
        font-weight: 500;
        font-size: 0.85rem;
        white-space: nowrap;
        transition: background 0.2s ease, transform 0.2s ease;
    }

    .quiz-button:hover {
        background: linear-gradient(135deg, #d82a61, #b81f4f);
        transform: translateY(-2px);
        color: white;
    }

    @media (max-width: 500px) {
        .quiz-card {
            flex-direction: column;
            align-items: flex-start;
        }
        .quiz-title {
            margin-bottom: 0.5rem;
            margin-right: 0;
        }
        .quiz-button {
            align-self: end;
        }
    }

    /* ========== FLOAT UTILITIES ========== */
.readblock
{
    margin: 20px;
    text-align: center;
}
.news-trivia-box
{
    margin: 5px;
    min-height: 410px;
}

.top-performer-card {
  width: 100%;
  background: #fff;
  border-radius: 12px;
  box-shadow: 0 4px 16px rgba(0,0,0,0.1);
  padding: 20px;
  text-align: center;
}

.top-performer-card__title {
  font-size: 22px;
  font-weight: bold;
  margin-bottom: 5px;
  color: #333;
}

.top-performer-card__subtitle {
  font-size: 14px;
  color: #666;
  margin-bottom: 15px;
}

.top-performer-card__list {
  list-style: none;
  padding: 0;
  margin: 0 0 15px 0;
}

.top-performer-card__item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 8px 12px;
  border-radius: 8px;
  transition: background 0.2s ease;
  cursor: default;
}

.top-performer-card__item:hover {
  background: #f0f4ff;
}

.top-performer-card__rank {
  font-weight: bold;
  font-size: 16px;
  color: #555;
  width: 25px;
  text-align: center;
}

.top-performer-card__name {
  flex: 1;
  text-align: left;
  margin-left: 10px;
  font-size: 16px;
  color: #333;
}

.top-performer-card__points {
  font-weight: bold;
  color: var(--primary-color);
}

.top-performer-card__link {
  display: inline-block;
  margin-top: 10px;
  font-size: 14px;
  color: #007bff;
  text-decoration: none;
  font-weight: bold;
  transition: color 0.2s ease;
}

.top-performer-card__link:hover {
  color: #0056b3;
}


/*triviapage inline code*/

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

.categories-grid .category-card {
      background: #fff;
    padding: 1.2rem 1.2rem;
    border-radius: 10px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.categories-grid .category-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 8px 25px rgba(0,0,0,0.2);
}

.categories-grid .category-title {
  font-size: 1.2rem;
  font-weight: 700;
  margin-bottom: 0.5rem;
  color: var(--primary-color);
}

.categories-grid .category-funfact {
  font-size: 0.9rem;
  color: #555;
  margin-bottom: 0.5rem;
  font-style: italic;
}

.categories-grid .category-trending {
  font-size: 0.85rem;
  color: #888;
  margin-bottom: 1.5rem;
}

.categories-grid .category-actions {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
}

.categories-grid .btn {
  flex: 1;
  text-align: center;
  padding: 0.6rem 1rem;
  font-weight: 600;
  border-radius: 6px;
  text-decoration: none;
  transition: background-color 0.3s ease;
}

.categories-grid .btn-primary {
  background: var(--primary-color);
  color: white;
}

.categories-grid .btn-primary:hover {
  background: var(--primary-color-hover, #d9007f);
}

.categories-grid .btn-secondary {
  background: #e0e0e0;
  color: var(--primary-color);
}

.categories-grid .btn-secondary:hover {
  background: var(--primary-color);
  color: white;
}

/* Responsive tweaks */
@media (max-width: 600px) {
 .categories-grid .category-actions {
    flex-direction: column;
  }

 .categories-grid .btn {
    width: 100%;
    margin-bottom: 0.7rem;
  }

 .categories-grid .btn:last-child {
    margin-bottom: 0;
  }
}
/*trivia page end*/
/*trivia game*/
.kwizr-trivia {
    background: #fff;
    border: 1px solid #eee;
    border-radius: 10px;
    padding: 15px;
    margin: 20px 0;
    font-family: sans-serif;
    max-width: 100%;
    box-shadow: 0 2px 5px rgba(0,0,0,0.05);
}
.kwizr-trivia h3 {
    font-size: 16px;
    margin-bottom: 10px;
    color: #E10489;
    display: flex;
    align-items: center;
    gap: 5px;
}
.kwizr-trivia .question {
    font-size: 18px;
    margin-bottom: 12px;
    font-weight: bold;
    color:var(--primary-text);
}
.kwizr-trivia .options {
    display: flex;
    flex-direction: column;
    gap: 8px;
}
.kwizr-trivia .options button {
    padding: 10px;
    font-size: 14px;
    border: 1px solid #002050;
    border-radius: 8px;
    /* background: #f8f8f8; */
    cursor: pointer;
    text-align: left;
    /* transition: background 0.2s; */
    background-size: 26px;
    background: white;
    font-weight: 700;
    color: #002050;
}
.kwizr-trivia .options button:hover {
    background: #eee;
    color: var(--primary-color);
}
.kwizr-trivia .options button.correct {
    background: #d4edda;
    border-color: #28a745;
    color: #155724;
}
.kwizr-trivia .options button.wrong {
    background: #f8d7da;
    border-color: #dc3545;
    color: #721c24;
}
.kwizr-trivia .score {
    font-size: 14px;
    margin-top: 10px;
    font-weight: bold;
    text-align: center;
}
</style>

<style type="text/css">
.quiz-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 1rem;
  padding: 1rem;
}

.quiz-card {
  background-color: #fff;
  border-radius: 8px;
  box-shadow: 0 4px 12px rgba(0,0,0,0.05);
  padding: 0.8rem 1rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  transition: transform 0.2s ease;
}

.quiz-card:hover {
  transform: translateY(-3px);
}

.quiz-title {
  font-size: 0.95rem;
  font-weight: 400;
  color: #333;
  margin: 0;
  flex: 1;
  margin-right: 0.5rem;
}

.quiz-button {
  background: linear-gradient(135deg, #f43676, #d82a61);
  color: #fff;
  padding: 0.4rem 0.8rem;
  border-radius: 4px;
  text-decoration: none;
  font-weight: 500;
  font-size: 0.85rem;
  white-space: nowrap;
  transition: background 0.2s ease, transform 0.2s ease;
}

.quiz-button:hover {
  background: linear-gradient(135deg, #d82a61, #b81f4f);
  transform: translateY(-2px);
  color:white;
}

@media (max-width: 500px) {
  .quiz-card {
    flex-direction: column;
    align-items: flex-start;
  }
  .quiz-title {
    margin-bottom: 0.5rem;
    margin-right: 0;
  }
  .quiz-button {
    align-self: end;
  }
}
/*end of trivia game*/

  .quiz-loader-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(255, 255, 255, 0.9);
    display: none;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    z-index: 999;
    text-align: center;
    font-size: 1.2rem;
    color: #333;
    border-radius: 12px;
}

.quiz-loader-overlay .loader-circle {
    width: 50px;
    height: 50px;
    border: 5px solid #ccc;
    border-top-color: var(--primary-color);
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin-bottom: 12px;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}
.kwizr-trivia {
    position: relative;
}

.funfact-box {
  margin-top: 16px;
  padding: 14px 16px;
  background: #f9f9ff;
  border-left: 4px solid var(--primary-color);
  border-radius: 8px;
}

.funfact-heading {
  font-size: 1rem;
  font-weight: 600;
  margin-bottom: 6px;
  color: var(--primary-color);
}

.funfact-text {
  font-size: 0.95rem;
  color: var(--primary-text);
  line-height: 1.4;
}

/*archive page*/
.archive-section {
    padding: 30px 15px;
    display: flex;
    justify-content: center;
}
.archive-section .archive-container {
    max-width: 800px;
    width: 100%;
}
.archive-section .section-title {
    text-align: center;
    font-size: 28px;
    font-weight: 700;
    margin-bottom: 5px;
}
.archive-section .section-subtitle {
    text-align: center;
    font-size: 16px;
    color: #666;
    margin-bottom: 25px;
}

.archive-section .filter-card {
    background: #fff;
    border-radius: 16px;
    padding: 25px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.08);
}
.archive-section .filter-form {
    margin-bottom: 0;
}
.archive-section .filter-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
}
.archive-section .filter-item {
    display: flex;
    flex-direction: column;
    flex: 1;
    min-width: 180px;
}
.archive-section .filter-item label {
    font-weight: 600;
    margin-bottom: 6px;
    font-size: 14px;
}
.archive-section .filter-item select,
.archive-section .filter-item input[type="date"] {
    padding: 10px;
    border-radius: 8px;
    border: 1px solid #ddd;
    font-size: 14px;
}
.archive-section .filter-item select:focus,
.archive-section .filter-item input[type="date"]:focus {
    border-color: #e10489;
    outline: none;
    box-shadow: 0 0 0 2px rgba(225, 4, 137, 0.2);
}

.archive-section .filter-submit {
    display: flex;
    align-items: flex-end;
}
.archive-section .filter-btn {
    background: linear-gradient(135deg, #f43676, #d82a61);
    color: #fff;
    padding: 12px 22px;
    border: none;
    border-radius: 10px;
    cursor: pointer;
    font-size: 16px;
    font-weight: 600;
    transition: 0.2s ease-in-out;
    width: 100%;
}
.archive-section .filter-btn:hover {
    background: linear-gradient(135deg, #d82a61, #b81f4f);
    transform: translateY(-1px);
}
.archive-section .archive-results {
    margin-top: 25px;
    text-align: center;
}
.archive-section .info-card {
    display: inline-block;
    padding: 20px 25px;
    border-radius: 12px;
    background: #fff8fb;
    border: 1px solid #f5c2d7;
    box-shadow: 0 2px 6px rgba(0,0,0,0.05);
    font-size: 16px;
    font-weight: 500;
    color: #c10374;
}

/* Scoped styles for funfact hub (all selectors prefixed with .funfact-section) */
.funfact-section { padding: 20px; }
.funfact-section .funfact-container { max-width: 1100px; margin: 0 auto; }

/* Header */
.funfact-section .funfact-section__title { font-size: 24px; margin-bottom: 6px; color: #E10489; }
.funfact-section .funfact-section__subtitle { font-size: 15px; color: #666; margin-bottom: 18px; }

/* Filter Card */
.funfact-section .funfact-section__filter-card {
    background: #fff;
    border-radius: 12px;
    padding: 18px;
    box-shadow: 0 3px 10px rgba(0,0,0,0.06);
    margin-bottom: 20px;
}
.funfact-section .funfact-section__filter-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 14px;
}
.funfact-section .funfact-section__filter-item {
    display:flex;
    flex-direction: column;
    min-width: 160px;
    flex: 1 1 180px;
}
.funfact-section .funfact-section__filter-submit { display:flex; align-items:flex-end; justify-content:flex-end; }
.funfact-section .funfact-section__label { font-weight:600; margin-bottom:6px; font-size:13px; }
.funfact-section .funfact-section__select,
.funfact-section input[type="text"] {
    padding: 9px 10px;
    border-radius: 8px;
    border: 1px solid #e6e6e6;
    font-size: 14px;
}
.funfact-section .funfact-section__filter-btn {
    background: linear-gradient(135deg,#f43676,#d82a61);
    color:#fff;
    padding: 10px 16px;
    border-radius: 8px;
    border: none;
    cursor: pointer;
    font-weight: 600;
}
.funfact-section .funfact-section__filter-btn:hover { transform: translateY(-2px); }

/* Grid */
.funfact-section .funfact-section__grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 14px;
}

/* Card */
.funfact-section .funfact-card {
    background:#fff;
    border-radius:10px;
    padding:14px;
    box-shadow: 0 2px 6px rgba(0,0,0,0.06);
    transition: transform .18s ease, box-shadow .18s ease;
}
.funfact-section .funfact-card:hover { transform: translateY(-4px); box-shadow: 0 6px 18px rgba(0,0,0,0.08); }
.funfact-section .funfact-card p { font-size:15px; color:#333; margin:0 0 8px 0; }
.funfact-section .funfact-card .funfact-meta { font-size:12px; color:#666;margin-bottom:10px }

/* Load more */
.funfact-section .funfact-section__load-more-wrap { text-align:center; margin-top: 18px; }
.funfact-section .funfact-section__load-more-btn {
    background:#002050; color:#fff; padding:10px 18px; border-radius:8px; border:none; cursor:pointer;
}
.funfact-section .funfact-section__load-more-btn[disabled] { opacity:0.6; cursor:not-allowed; }
.funfact-section .funfact-section__load-more-btn:hover { background:#003580; }

/* Responsive tweaks */
@media (max-width: 640px) {
    .funfact-section .funfact-section__filter-grid { gap:10px; }
    .funfact-section .funfact-section__filter-submit { align-items:flex-start; }
}

/* Ensure consistent card layout */
.funfact-section .funfact-card {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    min-height: 180px; /* keeps cards aligned */
}

/* Footer aligned to bottom-right */
.funfact-section .funfact-card__footer {
    margin-top: auto;
    text-align: right;
}

/* Read More button style */
.funfact-section .funfact-card__read-more {
    display: inline-block;
    margin-top: 10px;
    padding: 6px 12px;
    background: #e10489;
    color: #fff;
    font-size: 13px;
    font-weight: 600;
    border-radius: 6px;
    text-decoration: none;
    transition: all 0.2s ease;
}
.funfact-section .funfact-card__read-more:hover {
    background: #c10374;
    transform: translateY(-2px);
}
