/* StudyWaala Custom CSS & AdSense Optimizations */
@import url('https://fonts.googleapis.com/css2?family=Plus+Jakarta+Sans:wght@400;500;600;700;800&family=Noto+Sans+Devanagari:wght@400;500;600;700&display=swap');

:root {
  --primary: #4f46e5;
  --primary-hover: #4338ca;
  --secondary: #06b6d4;
  --accent: #f59e0b;
  --dark: #0f172a;
  --gray-bg: #f8fafc;
  --card-border: #e2e8f0;
}

body {
  font-family: 'Plus Jakarta Sans', 'Noto Sans Devanagari', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  color: #1e293b;
  background-color: var(--gray-bg);
  line-height: 1.7;
}

/* Reading Progress Bar */
#reading-progress {
  position: fixed;
  top: 0;
  left: 0;
  height: 4px;
  background: linear-gradient(90deg, #4f46e5, #06b6d4, #f59e0b);
  width: 0%;
  z-index: 9999;
  transition: width 0.1s ease-out;
}

/* AdSense Unit Containers - Clean & Natural (No Blank Grey Placeholders) */
.ad-slot {
  background: transparent;
  border: none;
  margin: 1rem 0;
  padding: 0;
  text-align: center;
  position: relative;
  overflow: hidden;
  display: block;
  width: 100%;
}

.ad-label {
  display: none; /* Hidden until ad is loaded to prevent "Under Construction" review penalty */
}

/* When Google AdSense fills the unit, style the container */
.ad-slot:has(ins[data-ad-status="filled"]) .ad-label {
  display: block;
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #94a3b8;
  margin-bottom: 0.3rem;
}

.ad-slot-leaderboard {
  max-width: 728px;
  margin-left: auto;
  margin-right: auto;
}

/* Article Typography */
.article-content h2 {
  font-size: 1.65rem;
  font-weight: 700;
  color: #0f172a;
  margin-top: 2rem;
  margin-bottom: 1rem;
  padding-bottom: 0.4rem;
  border-bottom: 2px solid #e2e8f0;
}

.article-content h3 {
  font-size: 1.3rem;
  font-weight: 600;
  color: #1e293b;
  margin-top: 1.5rem;
  margin-bottom: 0.75rem;
}

.article-content p {
  margin-bottom: 1.25rem;
  font-size: 1.05rem;
  color: #334155;
}

.article-content ul, .article-content ol {
  margin-bottom: 1.25rem;
  padding-left: 1.5rem;
}

.article-content li {
  margin-bottom: 0.5rem;
  color: #334155;
}

.article-content blockquote {
  border-left: 4px solid var(--primary);
  background-color: #eef2ff;
  padding: 1rem 1.25rem;
  border-radius: 0 8px 8px 0;
  margin: 1.5rem 0;
  font-style: italic;
  color: #3730a3;
}

/* Highlight boxes for tips */
.tip-box {
  background: #ecfdf5;
  border: 1px solid #a7f3d0;
  border-left: 4px solid #10b981;
  padding: 1rem 1.25rem;
  border-radius: 6px;
  margin: 1.5rem 0;
}

.key-takeaway-box {
  background: #eff6ff;
  border: 1px solid #bfdbfe;
  border-left: 4px solid #3b82f6;
  padding: 1rem 1.25rem;
  border-radius: 6px;
  margin: 1.5rem 0;
}

/* Table of Contents */
.toc-box {
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 10px;
  padding: 1.25rem;
  margin: 1.5rem 0;
  box-shadow: 0 1px 3px rgba(0,0,0,0.05);
}

.toc-box ul {
  list-style-type: none;
  padding-left: 0;
  margin-bottom: 0;
}

.toc-box li {
  margin-bottom: 0.4rem;
}

.toc-box a {
  color: #4f46e5;
  text-decoration: none;
  font-size: 0.95rem;
  transition: all 0.2s;
}

.toc-box a:hover {
  text-decoration: underline;
  color: #312e81;
}

/* Cookie Consent Banner */
#cookie-banner {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  background: #0f172a;
  color: #f8fafc;
  padding: 1rem;
  z-index: 10000;
  box-shadow: 0 -4px 10px rgba(0,0,0,0.15);
  display: none;
}
