/* =========================================
   MODULAR STYLES: DATOCHAI DYNAMIC HOMEPAGE
   ========================================= */

/* ---------- 1. GLOBAL HOMEPAGE BASE ---------- */
.home-page-view {
  background-color: var(--color-surface-secondary);
  color: var(--color-text-primary);
  transition: background-color 0.3s ease, color 0.3s ease;
}

.home-page-view .datochai-container {
  padding-top: 60px;
  padding-bottom: 100px;
}

.home-section {
  margin-bottom: 100px;
}

/* Centering utilities */
.centered-content-wrapper {
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.section-desc,
.home-hero-desc {
  font-size: 1.1rem;
  color: var(--color-text-secondary);
  max-width: 800px;
  line-height: 1.7;
  margin-bottom: 40px;
}

.flex-centered {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 30px;
}

/* Glassmorphism card – works in both light/dark */
.glass-card {
  background: var(--color-surface-tertiary);
  border: 1px solid var(--color-border-secondary);
  border-radius: 16px;
  transition: transform 0.3s ease, border-color 0.3s ease, box-shadow 0.3s ease;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.04);
}

.glass-card:hover {
  transform: translateY(-5px);
  border-color: var(--color-accent);
  box-shadow: 0 12px 35px rgba(211, 47, 47, 0.1);
}

/* Section title with strict centering */
.section-title.centered {
  font-family: 'Degular Display', system-ui, sans-serif;
  font-size: 2.5rem;
  font-weight: 800;
  margin: 0 auto 15px auto !important;
  color: var(--color-text-primary);
  position: relative;
  padding-bottom: 15px;
  text-align: center;
}

.section-title.centered::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 60px;
  height: 4px;
  background: var(--color-accent);
  border-radius: 2px;
}

/* ---------- 2. HERO SECTION & COUNTDOWN TIMER ---------- */
.home-hero {
  margin-bottom: 100px;
  margin-top: 20px;
}

/* Eyebrow with SVG icon support */
.hero-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: var(--color-surface-tertiary);
  color: var(--color-accent);
  padding: 8px 16px;
  border-radius: 30px;
  font-size: 13px;
  font-weight: 700;
  margin-bottom: 25px;
  border: 1px solid var(--color-border-secondary);
  text-transform: uppercase;
}

.hero-eyebrow svg {
  width: 18px;
  height: 18px;
  fill: currentColor;
}

.home-main-h1 {
  font-size: 4rem;
  line-height: 1.1;
  margin: 0 auto 15px auto;
  font-weight: 800;
  color: var(--color-text-primary);
  text-align: center;
}

.hero-badge-title {
  font-size: 1.1rem;
  font-weight: 800;
  letter-spacing: 2px;
  color: var(--color-text-secondary);
  margin: 0 auto 35px auto;
  text-transform: uppercase;
  text-align: center;
}

/* CTA button – uses a scale that won’t overflow */
.hero-cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: var(--color-accent);
  color: #ffffff !important;
  padding: 16px 40px;
  border-radius: 50px;
  font-size: 1.1rem;
  font-weight: 800;
  text-decoration: none;
  box-shadow: 0 10px 25px rgba(211, 47, 47, 0.2);
  transition: all 0.3s ease;
  margin-bottom: 40px;
}

.hero-cta:hover {
  transform: translateY(-2px) scale(1.02);
  box-shadow: 0 15px 35px rgba(211, 47, 47, 0.4);
}

/* Countdown wrapper */
.datochai-countdown-wrapper {
  background: var(--color-surface-tertiary);
  border: 2px solid var(--color-accent);
  padding: 20px 40px;
  border-radius: 20px;
  margin: 0 auto 40px auto;
  display: inline-block;
}

.countdown-title {
  font-size: 14px;
  font-weight: 700;
  color: var(--color-text-secondary);
  margin-bottom: 15px;
  text-transform: uppercase;
  text-align: center;
}

.countdown-boxes {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 15px;
  flex-wrap: wrap;
}

.cd-box {
  display: flex;
  flex-direction: column;
  align-items: center;
}

.cd-number {
  font-size: 42px;
  font-weight: 800;
  font-family: monospace;
  color: var(--color-text-primary);
  background: var(--color-surface-secondary);
  padding: 10px 15px;
  border-radius: 12px;
  min-width: 80px;
  border: 1px solid var(--color-border-secondary);
}

.cd-label {
  font-size: 12px;
  margin-top: 8px;
  color: var(--color-text-secondary);
  text-transform: uppercase;
  font-weight: 600;
}

.cd-colon {
  font-size: 32px;
  font-weight: 800;
  color: var(--color-accent);
  margin-top: -25px;
}

/* =========================================
   HOMEPAGE – PREMIUM RESULT & PREDICTION CARDS (NEW UI)
   ========================================= */

/* ---------- 3.1 SHARED CARD OVERRIDES (applied to both grids) ---------- */

/* Merge inner hub/prediction wrappers so cards flow into our grid */
.home-results-grid .crc-home-grid,
.home-predictions-grid .matrix-grid {
  display: contents;
}

/* Outer wrappers – transparent, no extra styling */
.crc-home-grid .crc-ui-wrapper,
.matrix-grid .pred-ajax-container {
  background: transparent !important;
  border: none;
  box-shadow: none !important;
  display: flex;
  flex-direction: column;
  width: 100%;
}

/* ----- The Card itself (white background, rounded corners) ----- */
.crc-home-grid .crc-mobile-card,
.matrix-grid .crc-mobile-card {
  background: var(--color-surface-primary);
  border: 1px solid var(--color-border-secondary);
  border-radius: 16px;
  box-shadow: 0 4px 15px rgba(0,0,0,0.05);
  overflow: hidden;
  position: relative;
  height: 380px;
  width: 100%;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

/* Dark mode override for the card background */
body.dark-mode .crc-home-grid .crc-mobile-card,
body.dark-mode .matrix-grid .crc-mobile-card {
  background: var(--color-surface-primary);
  border-color: var(--color-border-primary);
}
body.dark-mode .crc-home-grid .crc-mobile-card:hover,
body.dark-mode .matrix-grid .crc-mobile-card:hover {
  box-shadow: 0 15px 35px rgba(0, 0, 0, 0.5);
}

/* Card‑only hover (does not affect the separate button) */
.crc-home-grid .crc-mobile-card:hover,
.matrix-grid .crc-mobile-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 15px 35px rgba(0, 0, 0, 0.1);
}

/* ----- Header & Meta ----- */
.crc-home-grid .crc-card-header,
.matrix-grid .crc-card-header {
  background: transparent;
  padding: 20px 10px 10px;
}
.crc-home-grid .crc-meta-row,
.matrix-grid .crc-meta-row {
  background: transparent;
  color: var(--color-text-primary);
  border-bottom: 1px solid var(--color-border-secondary);
  font-size: 12px;
  padding: 8px 15px;
}
body.dark-mode .crc-home-grid .crc-meta-row,
body.dark-mode .matrix-grid .crc-meta-row {
  color: var(--color-text-primary);
  border-bottom-color: var(--color-border-primary);
}

/* ----- Logo Circles ----- */
.crc-home-grid .crc-logo-container,
.matrix-grid .crc-logo-container {
  width: 55px;
  height: 55px;
  margin: 0 auto 10px auto;
  border-radius: 50%;
  background: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 4px;
  border: 2px solid #cc0000;           /* red for results */
  box-shadow: 0 0 10px rgba(204, 0, 0, 0.2);
}
/* Predictions use blue */
.matrix-grid .crc-logo-container {
  border-color: #0056b3;
  box-shadow: 0 0 10px rgba(0, 86, 179, 0.2);
}

/* Remove pagination bars */
.crc-home-grid .crc-pagination-bar,
.matrix-grid .crc-pagination-bar {
  display: none !important;
}

/* ===== THE BLUR FADE (Bottom 140px) ===== */
.crc-home-grid .crc-mobile-card::after,
.matrix-grid .crc-mobile-card::after {
  content: "";
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 140px;
  background: linear-gradient(to top, var(--color-surface-primary) 10%, rgba(255,255,255,0.7) 40%, transparent 100%);
  pointer-events: none;
  z-index: 2;
}
body.dark-mode .crc-home-grid .crc-mobile-card::after,
body.dark-mode .matrix-grid .crc-mobile-card::after {
  background: linear-gradient(to top, var(--color-surface-primary) 10%, rgba(30,30,30,0.7) 40%, transparent 100%);
}

/* ===== SEPARATED BUTTON AREA ===== */
.crc-home-grid .crc-download-action,
.matrix-grid .crc-download-action {
  margin-top: 20px;
  width: 100%;
  position: relative;
  z-index: 10;
}

.crc-home-grid .crc-btn-primary,
.matrix-grid .crc-btn-primary {
  display: flex;
  justify-content: center;
  align-items: center;
  width: 100%;
  padding: 14px 0;
  border-radius: 10px;
  font-size: 15px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  transition: all 0.3s ease;
  text-decoration: none;
  cursor: pointer;
}

/* Result Buttons – Red */
.crc-home-grid .crc-btn-primary {
  background: var(--color-accent);
  color: #ffffff;
  border: none;
  box-shadow: 0 4px 12px rgba(204, 0, 0, 0.2);
}
.crc-home-grid .crc-btn-primary:hover {
  background: var(--color-accent-dark);
  color: #ffffff;
  box-shadow: 0 6px 18px rgba(204, 0, 0, 0.4);
  transform: translateY(-2px);
}

/* Prediction Buttons – Blue */
.matrix-grid .crc-btn-primary {
  background: #0056b3;
  color: #ffffff;
  border: none;
  box-shadow: 0 4px 12px rgba(0, 86, 179, 0.2);
}
.matrix-grid .crc-btn-primary:hover {
  background: #004494;
  color: #ffffff;
  box-shadow: 0 6px 18px rgba(0, 86, 179, 0.4);
  transform: translateY(-2px);
}

/* ===== RESULT CARD RED HEADER ===== */
.crc-home-grid .crc-card-header {
  background: linear-gradient(135deg, var(--color-accent) 0%, var(--color-accent-dark) 100%);
  border-radius: 16px 16px 0 0;
  padding: 20px 10px 15px;
  border-bottom: none;
}
.crc-home-grid .crc-card-header * {
  color: #ffffff !important;
}
/* Subtle red tint on the meta row for results */
.crc-home-grid .crc-meta-row {
  background: #fcf0f0;
  border-bottom: 1px solid #f5d6d6;
}
body.dark-mode .crc-home-grid .crc-meta-row {
  background: #2a1212;
  border-bottom-color: #4a1c1c;
  color: #ffcccc;
}

/* ---------- 3.2 GRID LAYOUTS (Responsive columns) ---------- */
.home-results-grid,
.home-predictions-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 30px;
  margin-top: 30px;
}

@media (min-width: 601px) {
  .home-results-grid,
  .home-predictions-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}
@media (min-width: 1025px) {
  .home-results-grid,
  .home-predictions-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

/* ---------- 4. EXPERT CAROUSEL (3 cards on desktop) ---------- */
.expert-carousel-wrapper {
  position: relative;
  width: 100%;
  max-width: 1100px;
  margin: 0 auto;
  overflow: hidden;
}

.expert-carousel-track {
  display: flex;
  gap: 30px;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scroll-behavior: smooth;
  padding: 20px 5px;
  scrollbar-width: none;
  -ms-overflow-style: none;
}

.expert-carousel-track::-webkit-scrollbar {
  display: none;
}

.expert-slide {
  flex: 0 0 calc(33.333% - 20px);
  scroll-snap-align: start;
  padding: 40px 25px;
  text-align: center;
}

/* Avatar handling */
.custom-avatar {
  background-size: cover;
  background-position: center;
  width: 85px;
  height: 85px;
  border-radius: 50%;
  margin: 0 auto 20px auto;
  border: 3px solid var(--color-border-secondary);
}

.placeholder-avatar {
  background: var(--color-accent);
  color: #fff;
  width: 85px;
  height: 85px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 26px;
  font-weight: 800;
  margin: 0 auto 20px auto;
}

.exp-name {
  font-size: 1.2rem;
  font-weight: 800;
  margin-bottom: 10px;
  color: var(--color-text-primary);
}

.exp-bio {
  font-size: 0.95rem;
  color: var(--color-text-secondary);
  line-height: 1.6;
  margin: 0;
}

.carousel-controls {
  display: flex;
  justify-content: center;
  gap: 15px;
  margin-top: 15px;
}

.c-btn {
  background: var(--color-surface-tertiary);
  border: 1px solid var(--color-border-secondary);
  color: var(--color-text-primary);
  width: 45px;
  height: 45px;
  border-radius: 50%;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: all 0.3s ease;
}

.c-btn svg {
  width: 18px;
  height: 18px;
  fill: currentColor;
}

.c-btn:hover {
  background: var(--color-accent);
  color: #fff;
  border-color: var(--color-accent);
}

/* ---------- 5. METHODOLOGY / WHY US ---------- */
.highlight-desc {
  color: var(--color-accent);
  font-weight: 700;
}

.methodology-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 25px;
  width: 100%;
  max-width: 1100px;
  margin-top: 30px;
}

.meth-box {
  padding: 35px 25px;
  text-align: center;
}

/* Icon container – professional SVG usage */
.meth-icon {
  width: 40px;
  height: 40px;
  margin-bottom: 20px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: var(--color-accent);
}

.meth-icon svg {
  width: 100%;
  height: 100%;
  fill: currentColor;
}

.meth-box p {
  text-align: center;
  font-size: 0.95rem;
  color: var(--color-text-secondary);
  line-height: 1.7;
  margin: 0;
}

/* ---------- 6. EEAT DATA VISUALIZATION ---------- */
.charts-stack-container {
  display: flex;
  flex-direction: column;
  gap: 40px;
  width: 100%;
  max-width: 1000px;
  margin-top: 30px;
}

.full-width-card {
  padding: 40px;
  text-align: left;
}

.chart-block h4 {
  font-size: 1.3rem;
  font-weight: 800;
  margin-bottom: 15px;
  margin-top: 0;
  color: var(--color-text-primary);
}

/* Pie chart side‑by‑side */
.pie-layout {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 40px;
}

.pie-info-side {
  flex: 1;
}

.pie-info-side p {
  color: var(--color-text-secondary);
  font-size: 0.95rem;
  line-height: 1.6;
  margin-bottom: 20px;
}

.pie-legend-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.l-item {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 700;
  color: var(--color-text-primary);
}

.color-dot {
  width: 14px;
  height: 14px;
  border-radius: 50%;
}

.high .color-dot {
  background: var(--color-accent);
}

.confident .color-dot {
  background: #475569;
}

.neutral .color-dot {
  background: #1e293b;
}

.pie-visual-side {
  flex: 0 0 240px;
  display: flex;
  justify-content: center;
}

.pie-chart-mock {
  height: 220px;
  width: 220px;
  border-radius: 50%;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
  border: 6px solid var(--color-surface-tertiary);
}

/* Bar chart – 10 lotteries */
.bar-chart-block {
  text-align: center;
}

.bar-sub {
  color: var(--color-text-secondary);
  font-size: 0.95rem;
  margin-bottom: 40px;
}

.bar-chart-mock {
  display: flex;
  justify-content: space-around;
  align-items: flex-end;
  height: 320px;
  padding-bottom: 30px;
  border-bottom: 2px solid var(--color-border-secondary);
  overflow-x: auto;
  overflow-y: visible;
}

.bar-column {
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  align-items: center;
  width: 9%;
  height: 100%;
  min-width: 0;
}

.bar {
  width: 35px;
  background: var(--color-text-primary);
  border-radius: 4px 4px 0 0;
  transition: opacity 0.3s;
  height: var(--height);
}

.bar-column:nth-child(even) .bar {
  background: var(--color-accent);
}

.bar:hover {
  opacity: 0.7;
}

.b-val {
  font-size: 13px;
  font-weight: 800;
  color: var(--color-text-primary);
  margin-bottom: 8px;
}

.b-label {
  font-size: 11px;
  font-weight: 700;
  color: var(--color-text-secondary);
  margin-top: 15px;
  white-space: nowrap;
}

/* ---------- 7. SEO PROSE & RESPONSIBLE GAMING ---------- */
.seo-prose-content {
  padding: 40px;
  margin: 0 auto 40px auto;
  text-align: left;
  color: var(--color-text-secondary);
  font-size: 1.05rem;
  line-height: 1.8;
}

.responsible-gaming-block {
  display: flex;
  align-items: center;
  gap: 20px;
  width: 100%;
  margin: 0 auto;
  padding: 25px 30px;
  border-left: 5px solid #ef4444;
  text-align: left;
}

/* Icon container */
.rg-icon {
  width: 40px;
  height: 40px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #ef4444;
  flex-shrink: 0;
}

.rg-icon svg {
  width: 100%;
  height: 100%;
  fill: currentColor;
}

.rg-text h4 {
  color: #ef4444;
  font-size: 1.1rem;
  font-weight: 800;
  margin-bottom: 8px;
  margin-top: 0;
}

.rg-text p {
  color: var(--color-text-secondary);
  font-size: 0.95rem;
  margin: 0;
  line-height: 1.6;
}

/* ---------- 8. LATEST POSTS FEED ---------- */
.post-grid {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 25px;
  width: 100%;
}

/* Card styling */
.post-grid .datochai-post-card {
  width: calc(25% - 18.75px);
  text-align: left;
  display: flex;
  flex-direction: column;
  background: var(--color-surface-tertiary);
  border: 1px solid var(--color-border-secondary);
  border-radius: 10px;
  overflow: hidden;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.post-grid .datochai-post-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 10px 20px rgba(0, 0, 0, 0.05);
}

.post-card-thumbnail {
  display: block;
  width: 100%;
}

.post-card-thumbnail img,
.fallback-thumbnail {
  width: 100%;
  height: 190px;
  object-fit: cover;
}

.fallback-thumbnail {
  background: var(--color-border-secondary);
}

.post-card-content {
  padding: 20px;
  display: flex;
  flex-direction: column;
  flex-grow: 1;
}

.datochai-post-card h3.post-card-title {
  font-size: 16px !important;
  font-weight: 700 !important;
  margin: 0 0 15px 0 !important;
  line-height: 1.4 !important;
}

.datochai-post-card h3.post-card-title a {
  color: var(--color-text-primary);
  text-decoration: none;
  transition: color 0.2s ease;
}

.datochai-post-card h3.post-card-title a:hover {
  color: var(--color-accent);
}

.post-card-meta {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 12px;
  color: var(--color-text-secondary);
  margin-top: auto;
}

.post-interactions {
  display: flex;
  gap: 15px;
}

/* Interaction buttons – SVG inside */
.interact-btn {
  background: none;
  border: none;
  color: var(--color-text-secondary);
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: 12px;
  font-weight: 600;
  padding: 0;
  transition: color 0.2s ease;
}

.interact-btn svg {
  width: 14px;
  height: 14px;
  fill: currentColor;
}

.interact-btn:hover {
  color: var(--color-accent);
}

/* View all button */
.view-all-btn {
  display: inline-block;
  margin-top: 30px;
  padding: 14px 40px;
  background: transparent;
  border: 2px solid var(--color-accent);
  color: var(--color-text-primary);
  border-radius: 40px;
  font-size: 1rem;
  font-weight: 700;
  text-decoration: none;
  transition: all 0.3s ease;
}

.view-all-btn:hover {
  background: var(--color-accent);
  color: #fff;
}

/* ---------- 9. FAQ ACCORDION ---------- */
.faq-accordion-container {
  width: 100%;
  max-width: 800px;
  margin: 0 auto;
  text-align: left;
}

.faq-item {
  padding: 25px 30px;
  margin-bottom: 20px;
  cursor: pointer;
  border: 1px solid var(--color-border-secondary);
}

.faq-question {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--color-text-primary);
  margin: 0;
}

/* FAQ toggle icon – now a clean SVG container */
.faq-icon {
  width: 24px;
  height: 24px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: var(--color-accent);
  transition: transform 0.3s ease;
}

.faq-icon svg {
  width: 100%;
  height: 100%;
  fill: currentColor;
}

.faq-answer-wrapper {
  max-height: 0;
  overflow: hidden;
  opacity: 0;
  transition: max-height 0.4s ease, opacity 0.4s ease, padding 0.4s ease;
}

.faq-answer {
  font-size: 0.95rem;
  color: var(--color-text-secondary);
  line-height: 1.7;
  margin: 0;
}

/* Active state */
.faq-item.active {
  border-color: var(--color-accent);
}

.faq-item.active .faq-icon {
  transform: rotate(45deg);
}

.faq-item.active .faq-answer-wrapper {
  max-height: 500px;
  opacity: 1;
  padding-top: 15px;
}

/* ---------- 10. LOTTERY INTERNAL LINKING HUB (PILLAR BUTTONS) ---------- */
.lottery-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 15px;
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
}

.lottery-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--color-surface-tertiary);
  color: var(--color-text-primary);
  padding: 15px 10px;
  text-align: center;
  border-radius: 8px;
  font-weight: 600;
  font-size: 0.95rem;
  text-decoration: none;
  border: 1px solid rgba(128, 128, 128, 0.15);
  transition: all 0.3s ease;
  box-shadow: 0 4px 10px rgba(0,0,0,0.05);
}

.lottery-btn:hover {
  background: var(--color-accent);
  color: #ffffff;
  transform: translateY(-3px);
  box-shadow: 0 6px 15px rgba(0,0,0,0.15);
}

/* ── Utility: Text center ── */
.text-center {
  text-align: center;
}

/* ---------- 11. RESPONSIVE BREAKPOINTS ---------- */
@media (max-width: 1024px) {
  .home-main-h1 {
    font-size: 3rem;
  }

  .expert-slide {
    flex: 0 0 calc(50% - 15px);
  }

  .methodology-grid {
    grid-template-columns: 1fr;
    max-width: 600px;
    margin: 0 auto;
  }

  .pie-layout {
    flex-direction: column;
    text-align: center;
  }

  .pie-info-side {
    padding-right: 0;
  }

  .post-grid .datochai-post-card {
    width: calc(50% - 12.5px);
  }

  .lottery-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

@media (max-width: 768px) {
  .home-page-view {
    overflow-x: hidden;
  }

  .home-page-view .datochai-container {
    padding-top: 30px;
  }

  .home-main-h1 {
    font-size: 2.2rem;
  }

  .hero-eyebrow {
    font-size: 11px;
    padding: 6px 12px;
  }

  .expert-slide {
    flex: 0 0 100%;
  }

  .countdown-boxes {
    flex-wrap: wrap;
    justify-content: center;
  }

  .cd-number {
    font-size: 22px;
    min-width: 55px;
  }

  .cd-colon {
    font-size: 24px;
    margin-top: -15px;
  }

  .section-title.centered {
    font-size: 2rem;
  }

  .b-label {
    font-size: 9px;
    transform: rotate(-45deg);
    transform-origin: left top;
    margin-top: 25px;
  }

  .bar {
    width: 20px;
  }

  .bar-chart-mock {
    height: 280px;
    padding-bottom: 50px;
    overflow-x: auto;
  }

  .responsible-gaming-block {
    flex-direction: column;
    text-align: center;
    gap: 15px;
  }

  .rg-icon {
    margin: 0 auto;
  }

  .post-grid .datochai-post-card {
    width: 100%;
  }

  .lottery-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

/* =========================================
   UNIVERSAL DOWNLOAD BUTTON (Pillar + CPT)
   (Moved from old duplicate, now scoped to pillar pages only)
   ========================================= */
.datochai-download-btn,
.cpt-download-btn {
  width: 100%;
  margin-bottom: 30px;
  padding: 18px;
  background: var(--color-accent);
  color: #ffffff !important;
  border: none;
  border-radius: 10px;
  font-size: 16px;
  font-weight: 700;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  transition: background 0.3s ease, transform 0.3s ease, box-shadow 0.3s ease;
  box-shadow: 0 4px 15px rgba(211, 47, 47, 0.3);
}

button.datochai-download-btn,
button.cpt-download-btn {
  background: var(--color-accent) !important;
  color: #ffffff !important;
  border: none !important;
}

button.datochai-download-btn svg,
button.cpt-download-btn svg {
  stroke: currentColor;
}

.datochai-download-btn svg,
.cpt-download-btn svg {
  width: 20px;
  height: 20px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
}

.datochai-download-btn:hover,
.cpt-download-btn:hover {
  background: var(--color-accent);
  transform: translateY(-3px);
  box-shadow: 0 8px 25px rgba(211, 47, 47, 0.5);
}

.datochai-download-btn:active,
.cpt-download-btn:active {
  transform: translateY(0);
  box-shadow: 0 4px 15px rgba(211, 47, 47, 0.3);
}

/* ── Related posts (CPT) – show logos properly ── */
.related-strict-grid .datochai-post-card .post-card-thumbnail img,
.related-strict-grid .datochai-post-card .fallback-thumbnail {
  height: auto;
  max-height: 120px;
  object-fit: contain;
  padding: 10px;
  background: var(--color-surface-secondary);
}

/* ── Other lotteries widget (pillar pages) ── */
.lottery-grid-links {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 12px;
  margin-top: 15px;
}

.lottery-link-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 15px 10px;
  background: var(--color-surface-tertiary);
  border: 1px solid var(--color-border-secondary);
  border-radius: 10px;
  text-decoration: none;
  font-weight: 700;
  font-size: 0.95rem;
  color: var(--color-text-primary);
  transition: all 0.3s ease;
  text-align: center;
}

.lottery-link-card:hover {
  background: var(--color-accent);
  color: #ffffff;
  border-color: var(--color-accent);
  transform: translateY(-3px);
  box-shadow: 0 6px 15px rgba(211, 47, 47, 0.2);
}

.card-accent-bar {
  display: block;
  width: 40px;
  height: 4px;
  border-radius: 2px;
  margin-bottom: 10px;
  background: var(--color-accent);
}