/* ==========================================================================
   Maxim88Sports.vip — Global Stylesheet
   Light theme with green/gold accents matching Maxim88 brand
   ========================================================================== */

/* ==========================================================================
   1. DESIGN TOKENS (CSS Custom Properties)
   ========================================================================== */

:root {
  /* Backgrounds */
  --bg-primary:    #f5f5f7;
  --bg-secondary:  #eaeaef;
  --bg-card:       #ffffff;

  /* Accent colours */
  --accent-green:       #2E7D32;
  --accent-green-hover: #388E3C;
  --accent-gold:        #cda659;
  --accent-gold-hover:  #b8934a;

  /* Text */
  --text-primary:   #1a1a2e;
  --text-secondary: #555566;

  /* Borders */
  --border-color: #d8d8e0;

  /* Layout */
  --nav-height:    60px;
  --topbar-height: 32px;
  --max-width:     1280px;

  /* Radii */
  --radius:    8px;
  --radius-sm: 4px;
}

/* ==========================================================================
   2. RESET
   ========================================================================== */

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

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  font-family: 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
  background-color: var(--bg-primary);
  color: var(--text-primary);
  line-height: 1.6;
  font-size: 15px;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

a {
  color: var(--accent-green);
  text-decoration: none;
  transition: color 0.2s ease;
}

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

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

ul,
ol {
  list-style: none;
}

table {
  border-collapse: collapse;
  border-spacing: 0;
}

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

input,
select,
textarea {
  font-family: inherit;
}

/* ==========================================================================
   3. TOP BAR
   ========================================================================== */

.topbar {
  background-color: #000000;
  height: var(--topbar-height);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 24px;
  font-size: 12px;
  color: var(--text-secondary);
  z-index: 1100;
  position: relative;
}

.topbar__left {
  display: flex;
  align-items: center;
  gap: 16px;
}

.topbar__right {
  display: flex;
  align-items: center;
  gap: 12px;
}

.topbar__lang {
  display: flex;
  align-items: center;
  gap: 6px;
  color: var(--text-secondary);
  font-size: 12px;
  cursor: pointer;
  transition: color 0.2s;
}

.topbar__lang:hover {
  color: var(--text-primary);
}

.btn-join {
  display: inline-flex;
  align-items: center;
  background-color: var(--accent-green);
  color: #ffffff;
  padding: 4px 16px;
  border-radius: var(--radius-sm);
  font-size: 12px;
  font-weight: 600;
  text-decoration: none;
  border: none;
  transition: background-color 0.2s ease;
  cursor: pointer;
}

.btn-join:hover {
  background-color: var(--accent-green-hover);
  color: #ffffff;
}

.btn-login {
  display: inline-flex;
  align-items: center;
  background-color: transparent;
  color: #ffffff;
  padding: 4px 16px;
  border-radius: var(--radius-sm);
  font-size: 12px;
  font-weight: 600;
  text-decoration: none;
  border: 1px solid #ffffff;
  transition: background-color 0.2s ease, color 0.2s ease;
  cursor: pointer;
}

.btn-login:hover {
  background-color: rgba(255, 255, 255, 0.1);
  color: #ffffff;
}

/* ==========================================================================
   4. NAVBAR
   ========================================================================== */

.navbar {
  background-color: var(--accent-green);
  height: var(--nav-height);
  display: flex;
  align-items: center;
  padding: 0 24px;
  position: sticky;
  top: 0;
  z-index: 1000;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.4);
}

.navbar__inner {
  display: flex;
  align-items: center;
  width: 100%;
  max-width: var(--max-width);
  margin: 0 auto;
}

.navbar__logo img {
  height: 36px;
  width: auto;
  display: block;
}

.navbar__menu {
  display: flex;
  align-items: center;
  gap: 0;
  margin-left: 32px;
  list-style: none;
  height: var(--nav-height);
}

.navbar__menu a {
  color: #ffffff;
  font-size: 13px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  text-decoration: none;
  padding: 0 16px;
  display: flex;
  align-items: center;
  height: var(--nav-height);
  transition: background-color 0.2s ease;
  white-space: nowrap;
}

.navbar__menu a:hover {
  background-color: rgba(0, 0, 0, 0.15);
  color: #ffffff;
}

.navbar__menu a.active {
  background-color: rgba(0, 0, 0, 0.25);
  color: var(--accent-gold);
}

.navbar__actions {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-left: auto;
}

.navbar__hamburger {
  display: none;
  align-items: center;
  justify-content: center;
  font-size: 24px;
  color: #ffffff;
  cursor: pointer;
  margin-left: auto;
  background: none;
  border: none;
  padding: 4px 8px;
  line-height: 1;
}

/* ==========================================================================
   5. HERO
   ========================================================================== */

.hero {
  position: relative;
  height: 300px;
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  display: flex;
  align-items: center;
  padding: 0 48px;
  overflow: hidden;
}

.hero::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(
    to right,
    rgba(0, 0, 0, 0.85) 0%,
    rgba(0, 0, 0, 0.45) 100%
  );
  pointer-events: none;
}

.hero__content {
  position: relative;
  z-index: 1;
  max-width: 560px;
}

.hero__title {
  font-size: 36px;
  font-weight: 700;
  line-height: 1.2;
  color: #ffffff;
  margin-bottom: 12px;
  text-shadow: 0 2px 8px rgba(0,0,0,0.6);
}

.hero__subtitle {
  font-size: 16px;
  color: #e0e0e0;
  line-height: 1.5;
  text-shadow: 0 1px 4px rgba(0,0,0,0.5);
}

/* ==========================================================================
   6. LAYOUT
   ========================================================================== */

.container {
  max-width: var(--max-width);
  margin-left: auto;
  margin-right: auto;
  padding-left: 24px;
  padding-right: 24px;
}

.section {
  padding-top: 48px;
  padding-bottom: 48px;
}

.section__title {
  font-size: 24px;
  font-weight: 700;
  margin-bottom: 24px;
  color: var(--text-primary);
}

/* ==========================================================================
   7. CARDS
   ========================================================================== */

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

.card {
  background-color: var(--bg-card);
  border-radius: var(--radius);
  border: 1px solid var(--border-color);
  padding: 20px;
  transition: transform 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease;
  box-shadow: 0 2px 8px rgba(0,0,0,0.06);
}

.card:hover {
  transform: translateY(-3px);
  border-color: var(--accent-green);
  box-shadow: 0 8px 24px rgba(46, 125, 50, 0.12);
}

.card__header {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 12px;
}

.card__icon {
  width: 48px;
  height: 48px;
  flex-shrink: 0;
  object-fit: contain;
}

.card__title {
  font-size: 18px;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 4px;
}

.card__meta {
  font-size: 13px;
  color: var(--text-secondary);
}

.card__body {
  font-size: 14px;
  color: var(--text-secondary);
  line-height: 1.6;
  margin-bottom: 12px;
}

.card__footer {
  margin-top: 16px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

/* ==========================================================================
   8. TABLES
   ========================================================================== */

.data-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 14px;
}

.data-table thead {
  background-color: var(--bg-secondary);
}

.data-table th {
  font-size: 12px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--text-secondary);
  padding: 10px 16px;
  text-align: left;
  border-bottom: 2px solid var(--accent-green);
  white-space: nowrap;
}

.data-table td {
  padding: 10px 16px;
  border-bottom: 1px solid var(--border-color);
  color: var(--text-primary);
  vertical-align: middle;
}

.data-table tbody tr:hover {
  background-color: rgba(46, 125, 50, 0.08);
}

.sortable {
  cursor: pointer;
  user-select: none;
  transition: color 0.2s ease;
}

.sortable:hover {
  color: var(--accent-gold);
}

.sort-arrow {
  margin-left: 4px;
  font-size: 10px;
  opacity: 0.7;
}

/* ==========================================================================
   9. BUTTONS
   ========================================================================== */

.btn-cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background-color: var(--accent-gold);
  color: #000000;
  padding: 10px 24px;
  border-radius: var(--radius-sm);
  font-size: 14px;
  font-weight: 700;
  text-decoration: none;
  border: none;
  transition: background-color 0.2s ease, transform 0.1s ease;
  cursor: pointer;
  white-space: nowrap;
}

.btn-cta:hover {
  background-color: var(--accent-gold-hover);
  color: #000000;
  transform: translateY(-1px);
}

.btn-secondary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background-color: transparent;
  color: var(--accent-green);
  padding: 10px 24px;
  border-radius: var(--radius-sm);
  font-size: 14px;
  font-weight: 600;
  text-decoration: none;
  border: 1px solid var(--accent-green);
  transition: background-color 0.2s ease, color 0.2s ease;
  cursor: pointer;
  white-space: nowrap;
}

.btn-secondary:hover {
  background-color: var(--accent-green);
  color: #ffffff;
}

/* ==========================================================================
   10. BREADCRUMB
   ========================================================================== */

.breadcrumb {
  font-size: 13px;
  color: var(--text-secondary);
  padding-top: 16px;
  padding-bottom: 16px;
  background: var(--bg-secondary);
  border-bottom: 1px solid var(--border-color);
}

.breadcrumb__list {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0;
  list-style: none;
  margin: 0;
  padding: 0;
}

.breadcrumb__item {
  display: flex;
  align-items: center;
}

.breadcrumb__item:not(:last-child)::after {
  content: '›';
  margin: 0 10px;
  color: var(--text-secondary);
  opacity: 0.5;
  font-size: 14px;
}

.breadcrumb__item--active {
  color: var(--text-primary);
  font-weight: 500;
}

.breadcrumb a {
  color: var(--accent-green);
  text-decoration: none;
  transition: color 0.2s;
}

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

.breadcrumb__sep {
  color: var(--text-secondary);
  opacity: 0.5;
  font-size: 11px;
}

/* ==========================================================================
   11. FLOATING SIDEBAR
   ========================================================================== */

.floating-sidebar {
  position: fixed;
  right: 0;
  top: 50%;
  transform: translateY(-50%);
  display: flex;
  flex-direction: column;
  gap: 2px;
  z-index: 999;
}

.floating-sidebar__btn {
  background-color: var(--accent-green);
  color: #ffffff;
  padding: 12px 8px;
  font-size: 10px;
  font-weight: 600;
  width: 56px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  text-decoration: none;
  line-height: 1.3;
  gap: 4px;
  transition: background-color 0.2s ease;
  border-radius: 0;
}

.floating-sidebar__btn:first-child {
  border-radius: var(--radius-sm) 0 0 0;
}

.floating-sidebar__btn:last-child {
  border-radius: 0 0 0 var(--radius-sm);
}

.floating-sidebar__btn:hover {
  background-color: var(--accent-green-hover);
  color: #ffffff;
}

.floating-sidebar__btn .icon {
  font-size: 18px;
  line-height: 1;
}

/* ==========================================================================
   12. FOOTER
   ========================================================================== */

.footer {
  background-color: #1a1a2e;
  color: #B0B0B0;
  padding-top: 48px;
  border-top: 2px solid var(--accent-green);
}

.footer .footer__col-title {
  color: var(--accent-gold);
}

.footer .footer__links,
.footer .footer__links a {
  color: #B0B0B0;
}

.footer .footer__links a:hover {
  color: #fff;
}

.footer .footer__seo {
  color: #888;
  border-top-color: #2a2a3e;
}

.footer .footer__bottom {
  color: #888;
  border-top-color: #2a2a3e;
}

.footer .footer__sponsor {
  background-color: #1e1e2f;
}

.footer__grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 32px;
  padding-bottom: 32px;
}

.footer__col-title {
  font-size: 14px;
  font-weight: 600;
  color: var(--accent-gold);
  text-transform: uppercase;
  letter-spacing: 0.06em;
  margin-bottom: 16px;
}

.footer__links {
  display: flex;
  flex-direction: column;
  gap: 8px;
  font-size: 13px;
  color: var(--text-secondary);
}

.footer__links a {
  color: var(--text-secondary);
  text-decoration: none;
  transition: color 0.2s;
}

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

.footer__payments {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
}

.footer__payments img {
  height: 28px;
  width: auto;
  object-fit: contain;
}

.footer__sponsor {
  display: flex;
  align-items: center;
  gap: 16px;
  background-color: var(--bg-card);
  border-radius: var(--radius);
  padding: 16px;
  margin-top: 8px;
}

.footer__sponsor img {
  height: 64px;
  width: auto;
  object-fit: contain;
  flex-shrink: 0;
}

.footer__seo {
  padding-top: 32px;
  padding-bottom: 32px;
  font-size: 13px;
  line-height: 1.8;
  color: var(--text-secondary);
  border-top: 1px solid var(--border-color);
  margin-top: 32px;
}

.footer__bottom {
  text-align: center;
  padding-top: 24px;
  padding-bottom: 24px;
  border-top: 1px solid var(--border-color);
  font-size: 12px;
  color: var(--text-secondary);
}

/* ==========================================================================
   13. LOADING SKELETONS
   ========================================================================== */

@keyframes shimmer {
  0% {
    background-position: -800px 0;
  }
  100% {
    background-position: 800px 0;
  }
}

.skeleton {
  background: linear-gradient(
    90deg,
    var(--bg-card) 25%,
    var(--bg-secondary) 50%,
    var(--bg-card) 75%
  );
  background-size: 800px 100%;
  animation: shimmer 1.5s infinite linear;
  border-radius: var(--radius-sm);
}

.skeleton-text {
  height: 14px;
  border-radius: var(--radius-sm);
  margin-bottom: 8px;
}

.skeleton-title {
  height: 24px;
  width: 60%;
  border-radius: var(--radius-sm);
  margin-bottom: 12px;
}

.skeleton-card {
  height: 200px;
  border-radius: var(--radius);
}

.skeleton-table-row {
  height: 44px;
  border-radius: 0;
  margin-bottom: 1px;
}

/* ==========================================================================
   14. STAT BADGES
   ========================================================================== */

.stat-badge {
  display: inline-flex;
  align-items: center;
  padding: 4px 10px;
  border-radius: 12px;
  font-size: 12px;
  font-weight: 600;
  line-height: 1;
  white-space: nowrap;
}

.stat-badge--win {
  background-color: rgba(46, 125, 50, 0.2);
  color: #4caf50;
}

.stat-badge--loss {
  background-color: rgba(211, 47, 47, 0.2);
  color: #ef5350;
}

.stat-badge--draw {
  background-color: rgba(245, 210, 0, 0.2);
  color: #f5c518;
}

/* ==========================================================================
   15. FAQ
   ========================================================================== */

.faq__item {
  border-bottom: 1px solid var(--border-color);
}

.faq__question {
  padding-top: 16px;
  padding-bottom: 16px;
  font-size: 15px;
  font-weight: 600;
  color: var(--text-primary);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  user-select: none;
}

.faq__question:hover {
  color: var(--accent-green-hover);
}

.faq__arrow {
  flex-shrink: 0;
  font-size: 14px;
  transition: transform 0.3s ease;
  color: var(--text-secondary);
}

.faq__item.open .faq__arrow {
  transform: rotate(180deg);
}

.faq__answer {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.3s ease;
  font-size: 14px;
  color: var(--text-secondary);
  line-height: 1.7;
}

.faq__item.open .faq__answer {
  max-height: 500px;
  padding-bottom: 16px;
}

/* ==========================================================================
   16. RESPONSIVE
   ========================================================================== */

/* --- Tablet: ≤ 1024px --- */
@media (max-width: 1024px) {
  .footer__grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

/* --- Mobile: ≤ 768px --- */
@media (max-width: 768px) {
  /* Topbar */
  .topbar {
    padding: 0 12px;
    font-size: 11px;
  }

  /* Navbar */
  .navbar {
    padding: 0 12px;
  }

  .navbar__menu {
    display: none;
    flex-direction: column;
    position: absolute;
    top: calc(var(--topbar-height) + var(--nav-height));
    left: 0;
    width: 100%;
    background-color: var(--accent-green);
    margin-left: 0;
    height: auto;
    z-index: 999;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
  }

  .navbar__menu.open {
    display: flex;
  }

  .navbar__menu a {
    padding: 12px 24px;
    height: auto;
    width: 100%;
    font-size: 14px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  }

  .navbar__hamburger {
    display: flex;
  }

  /* Hero */
  .hero {
    height: 200px;
    padding: 0 24px;
  }

  .hero__title {
    font-size: 24px;
  }

  .hero__subtitle {
    font-size: 14px;
  }

  /* Layout */
  .container {
    padding-left: 16px;
    padding-right: 16px;
  }

  .section {
    padding-top: 32px;
    padding-bottom: 32px;
  }

  /* Cards */
  .card-grid {
    grid-template-columns: 1fr;
  }

  /* Footer */
  .footer__grid {
    grid-template-columns: 1fr;
    gap: 24px;
  }

  /* Floating sidebar */
  .floating-sidebar {
    display: none;
  }

  /* Tables */
  .data-table {
    font-size: 12px;
  }

  .data-table th,
  .data-table td {
    padding: 8px 10px;
  }
}

/* ─── 16a. CTA Section ───────────────────────────────────────────────────── */

.section--cta {
  background: linear-gradient(135deg, #1a2a1a, #1a1a2e);
  border-top: 2px solid var(--accent-gold);
  border-bottom: 2px solid var(--accent-gold);
  text-align: center;
  padding: 48px 0;
}

.section--cta .section__title {
  color: #cda659;
}

.section--cta .section__subtitle {
  color: #B0B0B0;
}

.container--center {
  text-align: center;
}

.btn-cta {
  display: inline-block;
  background: #cda659;
  color: #000;
  font-weight: 700;
  font-size: 16px;
  padding: 14px 40px;
  border-radius: var(--radius-sm);
  text-decoration: none;
  transition: background 0.2s, transform 0.2s;
}

.btn-cta:hover {
  background: #b8934a;
  transform: translateY(-2px);
}

/* ─── 16b. SEO Content Block ─────────────────────────────────────────────── */

.seo-content {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 32px 36px;
  max-width: 900px;
  margin: 0 auto;
}

.seo-content h3 {
  font-size: 18px;
  font-weight: 700;
  color: var(--accent-green);
  margin: 24px 0 10px;
  padding-bottom: 6px;
  border-bottom: 1px solid var(--border-color);
}

.seo-content h3:first-child {
  margin-top: 0;
}

.seo-content p {
  color: var(--text-secondary);
  font-size: 14px;
  line-height: 1.8;
  margin-bottom: 8px;
}

.seo-content strong {
  color: var(--text-primary);
}

@media (max-width: 768px) {
  .seo-content {
    padding: 20px;
  }
}

/* ─── 17. Article Styles ─────────────────────────────────────────────────── */

/* Hero tag badge */
.hero__tag {
  display: inline-block;
  background: var(--accent-green);
  color: #fff;
  font-size: 12px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 1px;
  padding: 4px 14px;
  border-radius: var(--radius-sm);
  margin-bottom: 12px;
}

/* Table of Contents */
.toc {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-left: 4px solid var(--accent-green);
  border-radius: var(--radius-md);
  padding: 28px 32px;
  box-shadow: 0 2px 8px rgba(0,0,0,0.06);
}

.toc__title {
  font-size: 18px;
  font-weight: 700;
  color: var(--accent-green);
  margin-bottom: 16px;
  text-transform: uppercase;
  letter-spacing: 1px;
}

.toc__list {
  list-style: none;
  padding-left: 0;
  margin: 0;
  counter-reset: toc-counter;
}

.toc__list li {
  margin-bottom: 8px;
  counter-increment: toc-counter;
  padding-left: 32px;
  position: relative;
}

.toc__list li::before {
  content: counter(toc-counter, decimal-leading-zero);
  position: absolute;
  left: 0;
  color: var(--accent-green);
  font-weight: 700;
  font-size: 13px;
}

.toc__list a {
  color: var(--text-secondary);
  text-decoration: none;
  font-size: 14px;
  transition: color 0.2s, padding-left 0.2s;
}

.toc__list a:hover {
  color: var(--accent-gold);
  padding-left: 4px;
}

/* Article wrapper — full width with subtle background pattern */
.article-content {
  width: 100%;
  line-height: 1.9;
  font-size: 16px;
}

/* Section divider between H2 sections */
.article-content h2 {
  font-size: 26px;
  font-weight: 700;
  color: var(--text-primary);
  margin: 48px 0 20px;
  padding: 16px 20px;
  background: linear-gradient(90deg, rgba(46,125,50,0.15), transparent);
  border-left: 4px solid var(--accent-green);
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
}

.article-content h2:first-child {
  margin-top: 0;
}

.article-content h3 {
  font-size: 20px;
  font-weight: 600;
  color: var(--accent-gold);
  margin: 32px 0 12px;
}

.article-content p {
  color: var(--text-secondary);
  font-size: 15.5px;
  margin-bottom: 18px;
  line-height: 1.85;
}

.article-content a {
  color: #2e7d32;
  text-decoration: none;
  border-bottom: 1px dashed rgba(46,125,50,0.4);
  transition: border-color 0.2s, color 0.2s;
}

.article-content a:hover {
  border-bottom-color: #2e7d32;
  border-bottom-style: solid;
  color: #388E3C;
}

.article-content ul,
.article-content ol {
  color: var(--text-secondary);
  font-size: 15.5px;
  padding-left: 0;
  margin-bottom: 20px;
  list-style: none;
}

.article-content ul li,
.article-content ol li {
  margin-bottom: 10px;
  line-height: 1.8;
  padding: 8px 16px 8px 20px;
  position: relative;
  background: var(--bg-secondary);
  border-radius: var(--radius-sm);
  border-left: 3px solid var(--accent-green);
}

.article-content strong {
  color: var(--text-primary);
}

.article-content blockquote {
  border-left: 4px solid var(--accent-gold);
  background: linear-gradient(135deg, rgba(30,30,47,0.8), rgba(42,26,10,0.4));
  padding: 20px 24px;
  margin: 24px 0;
  border-radius: 0 var(--radius-md) var(--radius-md) 0;
  font-style: italic;
  color: var(--text-secondary);
  font-size: 15px;
}

/* Related sports data widget */
.article-widget {
  background: linear-gradient(135deg, #e8f5e9, #f1f8e9);
  border: 1px solid var(--accent-green);
  border-radius: var(--radius-md);
  padding: 28px 32px;
  margin: 40px 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 16px;
  position: relative;
  overflow: hidden;
}

.article-widget::before {
  content: '';
  position: absolute;
  top: 0;
  right: 0;
  width: 200px;
  height: 100%;
  background: linear-gradient(135deg, transparent, rgba(46,125,50,0.08));
  pointer-events: none;
}

.article-widget__text {
  color: var(--text-primary);
  font-size: 16px;
  font-weight: 600;
}

.article-widget__text span {
  display: block;
  font-size: 13px;
  font-weight: 400;
  color: var(--text-secondary);
  margin-top: 4px;
}

/* Article CTA section */
.article-cta {
  background: linear-gradient(135deg, #1a2a1a, #1a1a2e);
  border: 1px solid var(--accent-gold);
  border-radius: var(--radius-md);
  padding: 48px;
  text-align: center;
  margin: 48px 0;
  position: relative;
  overflow: hidden;
}

.article-cta::before {
  content: '';
  position: absolute;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background: radial-gradient(circle at 30% 50%, rgba(205,166,89,0.05) 0%, transparent 50%);
  pointer-events: none;
}

.article-cta h2 {
  font-size: 26px;
  color: #cda659;
  margin-bottom: 12px;
  border: none !important;
  padding: 0 !important;
  background: none !important;
}

.article-cta p {
  color: #B0B0B0;
  font-size: 15px;
  margin-bottom: 24px;
}

/* Related articles grid */
.related-articles {
  margin: 40px 0;
}

.related-articles h2 {
  font-size: 22px;
  color: var(--text-primary);
  margin-bottom: 20px;
}

.related-articles .card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 20px;
}

/* ─── 18. Utility Classes ────────────────────────────────────────────────── */

.bg-secondary {
  background-color: var(--bg-secondary);
}

/* ─── 19. Explore Data Widget (articles) ─────────────────────────────────── */

.section .container--center .btn-secondary {
  display: inline-block;
  margin-top: 8px;
}

/* ─── 20. Article Listing Page ───────────────────────────────────────────── */

/* Category filter buttons */
#category-filters .btn-secondary {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  color: var(--text-secondary);
  transition: all 0.2s;
}

#category-filters .btn-secondary:hover,
#category-filters .btn-secondary.active {
  background: var(--accent-green);
  border-color: var(--accent-green);
  color: #fff;
}

/* Article listing cards — enhanced hover */
#articles-grid .card {
  display: flex;
  flex-direction: column;
  transition: transform 0.2s, box-shadow 0.2s;
}

#articles-grid .card:hover {
  transform: translateY(-4px);
  box-shadow: 0 8px 24px rgba(0,0,0,0.4);
}

#articles-grid .card .card__title {
  font-size: 17px;
  font-weight: 700;
  color: var(--text-primary);
}

#articles-grid .card .card__meta {
  color: var(--accent-gold);
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

#articles-grid .card .card__body {
  color: var(--text-secondary);
  font-size: 14px;
  line-height: 1.6;
  flex: 1;
}

#articles-grid .card .card__footer {
  margin-top: auto;
  padding-top: 12px;
}

#articles-grid .card .card__footer .btn-secondary {
  border-color: var(--accent-green);
  color: var(--accent-green);
  transition: all 0.2s;
}

#articles-grid .card:hover .card__footer .btn-secondary {
  background: var(--accent-green);
  color: #fff;
}

/* ─── 20b. Article Enhancements (Author Bio, Review Date, Tables, Callouts) */

/* Author bio box */
.author-bio {
  display: flex;
  align-items: center;
  gap: 16px;
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius);
  padding: 20px 24px;
  margin: 24px 0 32px;
}

.author-bio__avatar {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: var(--accent-green);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 22px;
  font-weight: 700;
  flex-shrink: 0;
}

.author-bio__info {
  flex: 1;
}

.author-bio__name {
  font-size: 15px;
  font-weight: 700;
  color: var(--text-primary);
}

.author-bio__role {
  font-size: 13px;
  color: var(--accent-green);
  margin-top: 2px;
}

.author-bio__desc {
  font-size: 13px;
  color: var(--text-secondary);
  margin-top: 6px;
  line-height: 1.5;
}

/* Article meta bar (date, reading time) */
.article-meta {
  display: flex;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
  font-size: 13px;
  color: var(--text-secondary);
  padding-bottom: 16px;
  margin-bottom: 24px;
  border-bottom: 1px solid var(--border-color);
}

.article-meta__item {
  display: flex;
  align-items: center;
  gap: 5px;
}

.article-meta__icon {
  font-size: 14px;
}

/* Key takeaway / callout box */
.callout-box {
  background: linear-gradient(135deg, rgba(46,125,50,0.08), rgba(46,125,50,0.03));
  border-left: 4px solid var(--accent-green);
  border-radius: 0 var(--radius) var(--radius) 0;
  padding: 20px 24px;
  margin: 28px 0;
}

.callout-box__title {
  font-size: 14px;
  font-weight: 700;
  color: var(--accent-green);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 10px;
}

.callout-box ul {
  margin: 0;
  padding-left: 20px;
}

.callout-box li {
  font-size: 14px;
  color: var(--text-primary);
  line-height: 1.7;
  margin-bottom: 4px;
}

/* Comparison table */
.comparison-table {
  width: 100%;
  border-collapse: collapse;
  margin: 24px 0;
  font-size: 14px;
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid var(--border-color);
}

.comparison-table thead th {
  background: var(--accent-green);
  color: #fff;
  font-weight: 600;
  text-align: left;
  padding: 12px 16px;
  font-size: 13px;
  text-transform: uppercase;
  letter-spacing: 0.3px;
}

.comparison-table tbody td {
  padding: 12px 16px;
  border-bottom: 1px solid var(--border-color);
  color: var(--text-primary);
  vertical-align: top;
}

.comparison-table tbody tr:nth-child(even) {
  background: var(--bg-secondary);
}

.comparison-table tbody tr:last-child td {
  border-bottom: none;
}

.comparison-table .check {
  color: var(--accent-green);
  font-weight: 700;
}

.comparison-table .cross {
  color: #999;
}

/* Pro/Con columns */
.pros-cons {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  margin: 24px 0;
}

.pros-cons__col {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius);
  padding: 20px;
}

.pros-cons__col--pro {
  border-top: 3px solid var(--accent-green);
}

.pros-cons__col--con {
  border-top: 3px solid #F44336;
}

.pros-cons__title {
  font-size: 14px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 12px;
}

.pros-cons__col--pro .pros-cons__title {
  color: var(--accent-green);
}

.pros-cons__col--con .pros-cons__title {
  color: #F44336;
}

.pros-cons ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

.pros-cons li {
  font-size: 14px;
  color: var(--text-primary);
  padding: 6px 0;
  padding-left: 20px;
  position: relative;
  line-height: 1.5;
}

.pros-cons__col--pro li::before {
  content: '+';
  position: absolute;
  left: 0;
  color: var(--accent-green);
  font-weight: 700;
}

.pros-cons__col--con li::before {
  content: '-';
  position: absolute;
  left: 2px;
  color: #F44336;
  font-weight: 700;
}

/* Step-by-step guide boxes */
.step-box {
  display: flex;
  gap: 16px;
  align-items: flex-start;
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius);
  padding: 20px;
  margin: 12px 0;
}

.step-box__number {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--accent-green);
  color: #fff;
  font-weight: 700;
  font-size: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.step-box__content h4 {
  font-size: 15px;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 6px;
}

.step-box__content p {
  font-size: 14px;
  color: var(--text-secondary);
  line-height: 1.6;
  margin: 0;
}

/* Live data embed widget in articles */
.live-data-embed {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius);
  padding: 20px;
  margin: 24px 0;
  overflow-x: auto;
}

.live-data-embed__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 16px;
}

.live-data-embed__title {
  font-size: 16px;
  font-weight: 700;
  color: var(--text-primary);
}

.live-data-embed__badge {
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  background: rgba(46,125,50,0.1);
  color: var(--accent-green);
  padding: 3px 10px;
  border-radius: 12px;
}

.live-data-embed .data-table {
  margin: 0;
}

/* Responsive for new components */
@media (max-width: 768px) {
  .author-bio {
    flex-direction: column;
    text-align: center;
  }
  .pros-cons {
    grid-template-columns: 1fr;
  }
  .comparison-table {
    font-size: 12px;
  }
  .comparison-table thead th,
  .comparison-table tbody td {
    padding: 8px 10px;
  }
  .step-box {
    flex-direction: column;
    align-items: center;
    text-align: center;
  }
}

/* ─── 21. Related Articles Section ───────────────────────────────────────── */

.related-articles .card,
.bg-secondary .card-grid .card {
  transition: transform 0.2s, box-shadow 0.2s;
}

.related-articles .card:hover,
.bg-secondary .card-grid .card:hover {
  transform: translateY(-4px);
  box-shadow: 0 8px 24px rgba(0,0,0,0.4);
}

.bg-secondary .card-grid .card .card__icon {
  font-size: 24px;
  margin-right: 12px;
}

.bg-secondary .card-grid .card .card__header {
  display: flex;
  align-items: flex-start;
}

.bg-secondary .card-grid .card .card__title {
  font-size: 16px;
  font-weight: 700;
  color: var(--text-primary);
}

.bg-secondary .card-grid .card .card__meta {
  color: var(--accent-gold);
  font-size: 12px;
  margin-top: 2px;
}

.bg-secondary .card-grid .card .card__body {
  color: var(--text-secondary);
  font-size: 14px;
  line-height: 1.6;
  margin-top: 12px;
}

/* ─── 22. Article Responsive ─────────────────────────────────────────────── */

@media (max-width: 768px) {
  .article-content h2 {
    font-size: 20px;
    margin: 28px 0 12px;
  }

  .article-cta {
    padding: 24px;
  }

  .article-widget {
    flex-direction: column;
    text-align: center;
  }

  .toc {
    padding: 16px 20px;
  }

  #articles-grid .card .card__title {
    font-size: 15px;
  }
}
