/*
Theme Name: Edugic News (Euronews Style - Fully Responsive Mobile & Desktop)
Theme URI: https://edugic.com
Author: Antigravity AI
Author URI: https://edugic.com
Description: A modern, ultra-fast news magazine theme inspired by Euronews. Features multi-source feeds, auto-internal linking, 100% mobile-friendly responsive layout.
Version: 4.0.0
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: edugic-news
*/

:root {
  --primary-color: #0b1f3a;
  --accent-color: #0056b3;
  --live-red: #e61b23;
  --text-dark: #1e293b;
  --text-muted: #596579;
  --bg-light: #f8fafc;
  --card-bg: #ffffff;
  --border-color: #e2e8f0;
  --font-main: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen, Ubuntu, Cantarell, "Helvetica Neue", sans-serif;
  --font-serif: Georgia, Cambria, "Times New Roman", Times, serif;
}

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

html, body {
  width: 100%;
  overflow-x: hidden;
}

body {
  font-family: var(--font-main);
  color: var(--text-dark);
  background-color: var(--bg-light);
  line-height: 1.6;
  -webkit-text-size-adjust: 100%;
  -webkit-font-smoothing: antialiased;
}

a {
  color: inherit;
  text-decoration: none;
  transition: color 0.2s ease;
}

a:hover {
  color: var(--accent-color);
}

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

.container {
  width: 100%;
  max-width: 1240px;
  margin: 0 auto;
  padding: 0 16px;
}

@media (min-width: 768px) {
  .container {
    padding: 0 24px;
  }
}

/* =========================================================
   TOP LIVE BAR
   ========================================================= */
.edugic-top-bar {
  background: #06111f;
  color: #fff;
  font-size: 13px;
  border-bottom: 1px solid rgba(255,255,255,0.1);
  padding: 7px 0;
}
.top-bar-inner {
  display: flex;
  align-items: center;
  gap: 12px;
}
.live-badge {
  background: var(--live-red);
  color: #fff;
  font-weight: 800;
  padding: 2px 7px;
  border-radius: 3px;
  text-transform: uppercase;
  font-size: 11px;
  letter-spacing: 0.5px;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  flex-shrink: 0;
}
.live-dot {
  width: 6px;
  height: 6px;
  background: #fff;
  border-radius: 50%;
  animation: pulse 1.5s infinite;
}
@keyframes pulse {
  0% { opacity: 1; }
  50% { opacity: 0.3; }
  100% { opacity: 1; }
}
.ticker-content {
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
  flex: 1;
  font-size: 13px;
}
.top-date-display {
  font-size: 12px;
  opacity: 0.75;
  white-space: nowrap;
}
@media (max-width: 640px) {
  .top-date-display {
    display: none;
  }
  .ticker-content {
    font-size: 12px;
  }
}

/* =========================================================
   MAIN HEADER & RESPONSIVE NAVIGATION
   ========================================================= */
.edugic-header {
  background: #ffffff;
  border-bottom: 2px solid var(--border-color);
  position: sticky;
  top: 0;
  z-index: 1000;
  box-shadow: 0 1px 4px rgba(0,0,0,0.03);
}
.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 0;
  position: relative;
}
.site-logo {
  font-size: 24px;
  font-weight: 900;
  letter-spacing: -0.5px;
  color: var(--primary-color);
  text-transform: uppercase;
  display: inline-flex;
  align-items: center;
}
.site-logo span {
  color: var(--accent-color);
}
@media (min-width: 768px) {
  .site-logo {
    font-size: 28px;
  }
}

/* HAMBURGER TOGGLE (MOBILE ONLY) */
.mobile-menu-toggle {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  width: 28px;
  height: 20px;
  background: transparent;
  border: none;
  cursor: pointer;
  padding: 0;
  z-index: 1001;
}
.mobile-menu-toggle span {
  width: 100%;
  height: 3px;
  background-color: var(--primary-color);
  border-radius: 3px;
  transition: all 0.3s ease-in-out;
}
.mobile-menu-toggle.active span:nth-child(1) {
  transform: translateY(8px) rotate(45deg);
}
.mobile-menu-toggle.active span:nth-child(2) {
  opacity: 0;
}
.mobile-menu-toggle.active span:nth-child(3) {
  transform: translateY(-8px) rotate(-45deg);
}

@media (min-width: 900px) {
  .mobile-menu-toggle {
    display: none;
  }
}

/* NAVIGATION (MOBILE DRAWER VS DESKTOP BAR) */
.main-nav {
  position: absolute;
  top: 100%;
  left: 0;
  width: 100%;
  background: #ffffff;
  border-bottom: 2px solid var(--accent-color);
  box-shadow: 0 8px 16px rgba(0,0,0,0.1);
  display: none;
  flex-direction: column;
  padding: 12px 0;
}
.main-nav.open {
  display: flex;
}

.main-nav ul {
  list-style: none;
  display: flex;
  flex-direction: column;
  width: 100%;
}
.main-nav li {
  border-bottom: 1px solid #f1f5f9;
}
.main-nav li:last-child {
  border-bottom: none;
}
.main-nav a {
  display: block;
  padding: 12px 20px;
  font-weight: 700;
  font-size: 15px;
  text-transform: uppercase;
  color: #1e293b;
}
.main-nav a:hover,
.main-nav .current-menu-item a {
  background-color: #f8fafc;
  color: var(--accent-color);
}

@media (min-width: 900px) {
  .main-nav {
    position: static;
    width: auto;
    background: transparent;
    border-bottom: none;
    box-shadow: none;
    display: flex !important;
    padding: 0;
  }
  .main-nav ul {
    flex-direction: row;
    gap: 22px;
  }
  .main-nav li {
    border-bottom: none;
  }
  .main-nav a {
    padding: 6px 0;
    font-size: 14px;
    position: relative;
  }
  .main-nav a:hover {
    background: transparent;
  }
}

/* =========================================================
   HOMEPAGE: HERO MAGAZINE SECTION
   ========================================================= */
.hero-magazine {
  padding: 20px 0 28px;
}
.hero-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 20px;
}
@media (min-width: 900px) {
  .hero-grid {
    grid-template-columns: 1.8fr 1fr;
    gap: 28px;
  }
}

.lead-card {
  background: var(--card-bg);
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 2px 10px rgba(0,0,0,0.06);
  display: flex;
  flex-direction: column;
}
.lead-card .card-thumb {
  position: relative;
  aspect-ratio: 16 / 9;
  width: 100%;
  overflow: hidden;
  background: #e2e8f0;
}
.lead-card .card-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.4s ease;
}
.lead-card:hover .card-thumb img {
  transform: scale(1.03);
}
.lead-card .card-body {
  padding: 16px 18px 20px;
}
@media (min-width: 768px) {
  .lead-card .card-body {
    padding: 24px;
  }
}
.cat-tag {
  display: inline-block;
  background: #e6f0fa;
  color: var(--accent-color);
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  padding: 3px 8px;
  border-radius: 3px;
  margin-bottom: 8px;
  letter-spacing: 0.5px;
}
.lead-card h2 {
  font-size: 20px;
  line-height: 1.3;
  font-weight: 800;
  margin-bottom: 10px;
  color: var(--primary-color);
}
@media (min-width: 768px) {
  .lead-card h2 {
    font-size: 26px;
  }
}
.lead-card p {
  color: var(--text-muted);
  font-size: 14px;
  line-height: 1.6;
  margin-bottom: 8px;
}
@media (min-width: 768px) {
  .lead-card p {
    font-size: 15px;
  }
}
.card-date {
  font-size: 12px;
  color: #94a3b8;
  display: block;
}

/* Side Top Stories */
.side-stories {
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.section-heading {
  font-size: 17px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  border-left: 4px solid var(--accent-color);
  padding-left: 10px;
  margin-bottom: 14px;
  color: var(--primary-color);
}
.side-card {
  display: flex;
  gap: 12px;
  background: var(--card-bg);
  padding: 10px;
  border-radius: 6px;
  box-shadow: 0 1px 5px rgba(0,0,0,0.04);
  transition: transform 0.2s ease;
  align-items: center;
}
.side-card:hover {
  transform: translateY(-2px);
}
.side-card .card-thumb {
  width: 95px;
  height: 65px;
  border-radius: 4px;
  overflow: hidden;
  flex-shrink: 0;
  background: #e2e8f0;
}
@media (min-width: 768px) {
  .side-card .card-thumb {
    width: 110px;
    height: 75px;
  }
}
.side-card .card-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.side-card .card-body {
  flex: 1;
  min-width: 0;
}
.side-card h3 {
  font-size: 13px;
  font-weight: 700;
  line-height: 1.35;
  margin-bottom: 4px;
  overflow: hidden;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}
@media (min-width: 768px) {
  .side-card h3 {
    font-size: 14px;
  }
}

/* =========================================================
   HOMEPAGE: LATEST NEWS GRID
   ========================================================= */
.news-grid-section {
  padding: 20px 0 40px;
}
.grid-4-cols {
  display: grid;
  grid-template-columns: 1fr;
  gap: 16px;
}
@media (min-width: 600px) {
  .grid-4-cols {
    grid-template-columns: repeat(2, 1fr);
    gap: 18px;
  }
}
@media (min-width: 960px) {
  .grid-4-cols {
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
  }
}

.standard-card {
  background: var(--card-bg);
  border-radius: 6px;
  overflow: hidden;
  box-shadow: 0 1px 6px rgba(0,0,0,0.04);
  display: flex;
  flex-direction: column;
}
.standard-card .card-thumb {
  aspect-ratio: 16 / 10;
  width: 100%;
  background: #e2e8f0;
  overflow: hidden;
}
.standard-card .card-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.3s;
}
.standard-card:hover .card-thumb img {
  transform: scale(1.04);
}
.standard-card .card-body {
  padding: 14px;
  flex: 1;
  display: flex;
  flex-direction: column;
}
.standard-card h3 {
  font-size: 15px;
  font-weight: 700;
  line-height: 1.4;
  margin-bottom: 6px;
  flex: 1;
}

/* =========================================================
   SINGLE ARTICLE VIEW (RESPONSIVE 1200 - 2500 WORDS)
   ========================================================= */
.single-article-wrap {
  padding: 24px 0 48px;
  background: #ffffff;
}
@media (min-width: 768px) {
  .single-article-wrap {
    padding: 36px 0 60px;
  }
}

.article-header {
  max-width: 860px;
  margin: 0 auto 20px;
}
.article-header h1 {
  font-size: 24px;
  line-height: 1.28;
  font-weight: 800;
  margin: 10px 0 14px;
  color: #0b1f3a;
  letter-spacing: -0.3px;
  word-break: break-word;
}
@media (min-width: 768px) {
  .article-header h1 {
    font-size: 36px;
  }
}

.article-meta {
  color: var(--text-muted);
  font-size: 13px;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 12px;
  padding-bottom: 16px;
  border-bottom: 1px solid #e2e8f0;
}
@media (min-width: 768px) {
  .article-meta {
    font-size: 14px;
  }
}

.article-featured-image {
  max-width: 920px;
  margin: 0 auto 24px;
  border-radius: 6px;
  overflow: hidden;
  box-shadow: 0 4px 15px rgba(0,0,0,0.06);
}
@media (min-width: 768px) {
  .article-featured-image {
    margin: 0 auto 36px;
    border-radius: 8px;
  }
}
.article-featured-image img {
  width: 100%;
  max-height: 500px;
  object-fit: cover;
}

/* ARTICLE BODY TYPOGRAPHY */
.article-content {
  max-width: 860px;
  margin: 0 auto;
  font-size: 16px;
  line-height: 1.8;
  color: #1e293b;
  word-break: break-word;
}
@media (min-width: 768px) {
  .article-content {
    font-size: 18px;
    line-height: 1.85;
  }
}

.article-content p {
  margin-bottom: 20px;
}
@media (min-width: 768px) {
  .article-content p {
    margin-bottom: 24px;
  }
}

.article-content h2 {
  font-size: 21px;
  font-weight: 800;
  color: #0b1f3a;
  margin: 32px 0 14px;
  padding-top: 10px;
  border-top: 1px solid #f1f5f9;
}
@media (min-width: 768px) {
  .article-content h2 {
    font-size: 26px;
    margin: 40px 0 16px;
  }
}

.article-content h3 {
  font-size: 18px;
  font-weight: 700;
  color: #1e293b;
  margin: 26px 0 12px;
}
@media (min-width: 768px) {
  .article-content h3 {
    font-size: 21px;
    margin: 32px 0 14px;
  }
}

/* SMART INTERNAL LINKING CALLOUT BOX */
.edugic-related-story {
  margin: 28px 0;
  padding: 16px 20px;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-left: 4px solid var(--accent-color);
  border-radius: 6px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  transition: all 0.2s ease;
}
.edugic-related-story:hover {
  background: #f0f7ff;
  border-color: #bcd9ff;
  transform: translateX(3px);
}
.related-label {
  font-size: 11px;
  font-weight: 800;
  text-transform: uppercase;
  color: var(--accent-color);
  letter-spacing: 0.6px;
}
.related-link {
  font-size: 16px;
  font-weight: 700;
  color: #0b1f3a;
  line-height: 1.4;
}
.related-link:hover {
  color: var(--accent-color);
  text-decoration: underline;
}

/* Contextual internal link highlights inside text */
.article-content a.internal-context-link {
  color: var(--accent-color);
  font-weight: 600;
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
}
.article-content a.internal-context-link:hover {
  color: #0b1f3a;
}

/* KEY HIGHLIGHTS BOX (RESPONSIVE) */
.edugic-highlights-box {
  background: #f0f7ff;
  border: 1px solid #c7e0ff;
  border-left: 4px solid var(--accent-color);
  border-radius: 6px;
  padding: 16px 18px;
  margin: 0 0 24px;
}
@media (min-width: 768px) {
  .edugic-highlights-box {
    border-left-width: 5px;
    border-radius: 8px;
    padding: 22px 26px;
    margin: 0 0 32px;
  }
}
.edugic-highlights-box h3 {
  font-size: 16px;
  text-transform: uppercase;
  color: #004b99;
  margin-top: 0;
  margin-bottom: 12px;
  letter-spacing: 0.5px;
}
@media (min-width: 768px) {
  .edugic-highlights-box h3 {
    font-size: 18px;
  }
}
.edugic-highlights-box ul {
  list-style: none;
  padding-left: 0;
  margin: 0;
}
.edugic-highlights-box li {
  position: relative;
  padding-left: 20px;
  margin-bottom: 8px;
  font-size: 14px;
  line-height: 1.55;
  color: #1e3a5f;
}
@media (min-width: 768px) {
  .edugic-highlights-box li {
    padding-left: 24px;
    margin-bottom: 10px;
    font-size: 16px;
  }
}
.edugic-highlights-box li::before {
  content: "✔";
  position: absolute;
  left: 0;
  color: var(--accent-color);
  font-weight: bold;
}

/* STYLIZED PULLQUOTE */
.edugic-pullquote {
  margin: 28px 0;
  padding: 18px 20px;
  background: #f8fafc;
  border-left: 4px solid #0b1f3a;
  border-radius: 0 6px 6px 0;
  font-family: var(--font-serif);
  font-style: italic;
  font-size: 17px;
  line-height: 1.6;
  color: #0f172a;
}
@media (min-width: 768px) {
  .edugic-pullquote {
    margin: 36px 0;
    padding: 24px 30px;
    font-size: 21px;
    border-radius: 0 8px 8px 0;
  }
}
.edugic-pullquote cite {
  display: block;
  font-family: var(--font-main);
  font-style: normal;
  font-size: 13px;
  font-weight: 700;
  color: #64748b;
  margin-top: 10px;
  text-transform: uppercase;
}

/* INLINE ARTICLE FIGURE */
.edugic-inline-figure {
  margin: 28px 0;
  border-radius: 6px;
  overflow: hidden;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
}
@media (min-width: 768px) {
  .edugic-inline-figure {
    margin: 36px 0;
    border-radius: 8px;
  }
}
.edugic-inline-figure img {
  width: 100%;
  max-height: 400px;
  object-fit: cover;
}
.edugic-inline-figure figcaption {
  padding: 8px 14px;
  font-size: 12px;
  color: #64748b;
  font-style: italic;
  background: #f8fafc;
  border-top: 1px solid #e2e8f0;
}
@media (min-width: 768px) {
  .edugic-inline-figure figcaption {
    padding: 10px 16px;
    font-size: 13px;
  }
}

/* TIMELINE (RESPONSIVE) */
.edugic-timeline {
  margin: 28px 0;
  padding: 18px;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 6px;
}
@media (min-width: 768px) {
  .edugic-timeline {
    margin: 36px 0;
    padding: 24px;
    border-radius: 8px;
  }
}
.edugic-timeline h3 {
  margin-top: 0;
  margin-bottom: 16px;
  color: #0b1f3a;
}
.timeline-item {
  position: relative;
  padding-left: 22px;
  padding-bottom: 16px;
  border-left: 2px solid #cbd5e1;
}
.timeline-item:last-child {
  border-left: 2px solid transparent;
  padding-bottom: 0;
}
.timeline-item::before {
  content: "";
  position: absolute;
  left: -6px;
  top: 4px;
  width: 10px;
  height: 10px;
  background: var(--accent-color);
  border-radius: 50%;
}
.timeline-date {
  font-weight: 700;
  font-size: 12px;
  color: var(--accent-color);
  text-transform: uppercase;
  margin-bottom: 2px;
}
.timeline-text {
  font-size: 14px;
  line-height: 1.5;
  color: #334155;
}

/* FAQ BOX (RESPONSIVE) */
.edugic-faq-box {
  margin: 32px 0 24px;
  background: #f1f5f9;
  border-radius: 6px;
  padding: 18px;
  border: 1px solid #cbd5e1;
}
@media (min-width: 768px) {
  .edugic-faq-box {
    margin: 40px 0 30px;
    border-radius: 8px;
    padding: 24px;
  }
}
.edugic-faq-box h3 {
  margin-top: 0;
  margin-bottom: 14px;
  color: #0b1f3a;
}
.faq-item {
  margin-bottom: 14px;
  padding-bottom: 12px;
  border-bottom: 1px solid #e2e8f0;
}
.faq-item:last-child {
  border-bottom: 0;
  margin-bottom: 0;
  padding-bottom: 0;
}
.faq-question {
  font-size: 15px;
  font-weight: 700;
  color: #0f172a;
  margin-bottom: 4px;
}
@media (min-width: 768px) {
  .faq-question {
    font-size: 17px;
  }
}
.faq-answer {
  font-size: 14px;
  line-height: 1.6;
  color: #475569;
}
@media (min-width: 768px) {
  .faq-answer {
    font-size: 15px;
  }
}

/* SOURCE ATTRIBUTION */
.source-attribution {
  margin-top: 28px;
  padding: 14px 18px;
  background: #f1f5f9;
  border-left: 4px solid var(--accent-color);
  font-size: 13px;
  color: #475569;
  border-radius: 4px;
}
@media (min-width: 768px) {
  .source-attribution {
    margin-top: 36px;
    padding: 18px 24px;
    font-size: 14px;
  }
}

/* =========================================================
   FOOTER (RESPONSIVE)
   ========================================================= */
.edugic-footer {
  background: #081628;
  color: #94a3b8;
  padding: 36px 0 20px;
  margin-top: 40px;
}
@media (min-width: 768px) {
  .edugic-footer {
    padding: 48px 0 24px;
    margin-top: 50px;
  }
}
.footer-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 24px;
  padding-bottom: 24px;
  border-bottom: 1px solid rgba(255,255,255,0.1);
}
@media (min-width: 768px) {
  .footer-grid {
    grid-template-columns: 2fr 1fr 1fr;
    gap: 32px;
    padding-bottom: 32px;
  }
}
.footer-col h4 {
  color: #fff;
  font-size: 15px;
  margin-bottom: 12px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}
.footer-col ul {
  list-style: none;
}
.footer-col li {
  margin-bottom: 8px;
}
.footer-col a {
  color: #94a3b8;
  font-size: 14px;
}
.footer-col a:hover {
  color: #38bdf8;
}
.footer-bottom {
  padding-top: 20px;
  text-align: center;
  font-size: 12px;
}
