/* ── Opening intro paragraph ─────────────────────────────────────────
   Wraps the first paragraph before the first H2. Gives it visual
   weight and signals to readers that this is the article summary.
   ─────────────────────────────────────────────────────────────────── */

.post-intro {
  position: relative;
  margin: 0 0 32px;
  padding: 20px 22px 20px 26px;
  background: #f8fafc;
  border-left: 5px solid #1e293b;
  border-radius: 0 10px 10px 0;
  font-size: 16px;
  line-height: 1.75;
  color: #1e293b;
}

.post-intro strong {
  color: #0f172a;
}

/* ── Custom list styles ───────────────────────────────────────────────
   Applied via class so they do not bleed into theme navigation or
   widget lists. The model outputs these classes on every list.
   ─────────────────────────────────────────────────────────────────── */

/* Unordered list */
.post-list {
  list-style: none;
  margin: 18px 0 22px;
  padding: 0;
}

.post-list li {
  position: relative;
  padding: 10px 14px 10px 46px;
  margin-bottom: 6px;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  font-size: 15px;
  line-height: 1.6;
  color: #334155;
  transition: background 0.15s, border-color 0.15s;
}

.post-list li:hover {
  background: #f1f5f9;
  border-color: #cbd5e1;
}

.post-list li::before {
  content: '';
  position: absolute;
  left: 16px;
  top: 50%;
  transform: translateY(-50%);
  width: 16px;
  height: 16px;
  background: #1e293b;
  border-radius: 50%;
  flex-shrink: 0;
}

.post-list li::after {
  content: '';
  position: absolute;
  left: 21px;
  top: 50%;
  transform: translateY(-50%) rotate(45deg);
  width: 5px;
  height: 8px;
  border-right: 2px solid #fff;
  border-bottom: 2px solid #fff;
}

.post-list li strong {
  color: #0f172a;
  font-weight: 600;
}

/* Ordered list */
.post-list-ordered {
  list-style: none;
  counter-reset: post-ol-counter;
  margin: 18px 0 22px;
  padding: 0;
}

.post-list-ordered li {
  counter-increment: post-ol-counter;
  position: relative;
  padding: 12px 14px 12px 56px;
  margin-bottom: 8px;
  background: #fff;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  font-size: 15px;
  line-height: 1.6;
  color: #334155;
  transition: background 0.15s, border-color 0.15s;
}

.post-list-ordered li:hover {
  background: #f8fafc;
  border-color: #cbd5e1;
}

.post-list-ordered li::before {
  content: counter(post-ol-counter);
  position: absolute;
  left: 14px;
  top: 50%;
  transform: translateY(-50%);
  width: 28px;
  height: 28px;
  background: #1e293b;
  color: #fff;
  border-radius: 6px;
  font-size: 13px;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  line-height: 1;
}

.post-list-ordered li strong {
  color: #0f172a;
  font-weight: 600;
}

/* ── Rich Content Elements ───────────────────────────────────────────
   Injected by the standard blog post generator. Each element is
   self-contained so it renders cleanly in any WordPress theme.
   ─────────────────────────────────────────────────────────────────── */

/* Stat Callout — a single big number / stat with a supporting label  */
.post-stat-box {
  display: flex;
  align-items: center;
  gap: 20px;
  margin: 32px 0;
  padding: 24px 28px;
  background: #0f172a;
  border-radius: 12px;
  color: #fff;
  overflow: hidden;
  position: relative;
}

.post-stat-box::before {
  content: '';
  position: absolute;
  top: -20px;
  right: -20px;
  width: 120px;
  height: 120px;
  border-radius: 50%;
  background: rgba(255,255,255,0.04);
}

.post-stat-number {
  flex-shrink: 0;
  font-size: 48px;
  font-weight: 800;
  line-height: 1;
  color: #38bdf8;
  letter-spacing: -0.02em;
}

.post-stat-content {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.post-stat-label {
  font-size: 17px;
  font-weight: 600;
  color: #f1f5f9;
  line-height: 1.3;
}

.post-stat-source {
  font-size: 12px;
  color: #94a3b8;
  font-style: italic;
}

/* Pro Tip Box */
.post-pro-tip {
  display: flex;
  gap: 16px;
  margin: 28px 0;
  padding: 20px 22px;
  background: #f0fdf4;
  border: 1px solid #bbf7d0;
  border-left: 5px solid #16a34a;
  border-radius: 0 10px 10px 0;
}

.post-pro-tip-icon {
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  background: #16a34a;
  border-radius: 50%;
  color: #fff;
  font-size: 18px;
  font-weight: 800;
  line-height: 1;
}

.post-pro-tip-content {
  flex: 1;
}

.post-pro-tip-label {
  display: block;
  margin-bottom: 6px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: #16a34a;
}

.post-pro-tip-content p {
  margin: 0;
  font-size: 15px;
  line-height: 1.6;
  color: #14532d;
}

/* Warning / Watch Out Box */
.post-warning-box {
  display: flex;
  gap: 16px;
  margin: 28px 0;
  padding: 20px 22px;
  background: #fffbeb;
  border: 1px solid #fde68a;
  border-left: 5px solid #d97706;
  border-radius: 0 10px 10px 0;
}

.post-warning-icon {
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  background: #d97706;
  border-radius: 50%;
  color: #fff;
  font-size: 20px;
  font-weight: 800;
  line-height: 1;
}

.post-warning-content {
  flex: 1;
}

.post-warning-label {
  display: block;
  margin-bottom: 6px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: #b45309;
}

.post-warning-content p {
  margin: 0;
  font-size: 15px;
  line-height: 1.6;
  color: #78350f;
}

/* Comparison Table */
.post-comparison-table {
  margin: 32px 0;
  overflow-x: auto;
  border-radius: 10px;
  border: 1px solid #e2e8f0;
  box-shadow: 0 1px 6px rgba(0,0,0,0.06);
}

.post-comparison-table table {
  width: 100%;
  border-collapse: collapse;
  font-size: 14px;
  min-width: 380px;
}

.post-comparison-table th {
  padding: 14px 16px;
  background: #1e293b;
  color: #f1f5f9;
  font-weight: 700;
  font-size: 13px;
  text-align: left;
  white-space: nowrap;
}

.post-comparison-table th:first-child {
  border-radius: 9px 0 0 0;
}

.post-comparison-table th:last-child {
  border-radius: 0 9px 0 0;
}

.post-comparison-table td {
  padding: 13px 16px;
  border-bottom: 1px solid #f1f5f9;
  color: #374151;
  line-height: 1.5;
  vertical-align: top;
}

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

.post-comparison-table tr:nth-child(even) td {
  background: #f8fafc;
}

.post-comparison-table tr:hover td {
  background: #f1f5f9;
}

.post-comparison-table td strong {
  color: #1e293b;
}

/* CTA Strip — placed just before the FAQ */
.post-cta-strip {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  flex-wrap: wrap;
  margin: 40px 0;
  padding: 28px 32px;
  background: linear-gradient(135deg, #1e293b 0%, #0f172a 100%);
  border-radius: 14px;
  color: #fff;
}

.post-cta-strip-text {
  flex: 1;
  min-width: 180px;
}

.post-cta-strip-text strong {
  display: block;
  margin-bottom: 6px;
  font-size: 20px;
  font-weight: 700;
  color: #fff;
  line-height: 1.3;
}

.post-cta-strip-text p {
  margin: 0;
  font-size: 14px;
  color: #94a3b8;
  line-height: 1.5;
}

.post-cta-strip-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
  padding: 14px 26px;
  background: #38bdf8;
  color: #0c4a6e;
  font-size: 15px;
  font-weight: 700;
  border-radius: 8px;
  text-decoration: none;
  white-space: nowrap;
  transition: background 0.2s, transform 0.15s;
}

.post-cta-strip-btn:hover {
  background: #7dd3fc;
  color: #0c4a6e;
  text-decoration: none;
  transform: translateY(-1px);
}

/* ── Responsive tweaks ───────────────────────────────────────────── */
@media (max-width: 600px) {
  .post-stat-box {
    flex-direction: column;
    align-items: flex-start;
    gap: 10px;
  }
  .post-stat-number {
    font-size: 36px;
  }
  .post-cta-strip {
    flex-direction: column;
    text-align: center;
    padding: 24px 20px;
  }
  .post-cta-strip-text {
    min-width: 0;
  }
  .post-comparison-table {
    border-radius: 6px;
  }
}

/* FAQ Section Styling */
.faq-section {
  margin: 40px 0;
  border-top: 1px solid #e5e5e5;
  padding-top: 30px;
}

.faq-section h2 {
  margin-bottom: 25px;
  font-size: 24px;
  font-weight: 700;
}

.faq-item {
  margin-bottom: 15px;
  border: 1px solid #e5e5e5;
  border-radius: 8px;
  overflow: hidden;
}

.faq-question {
  padding: 15px 20px;
  background-color: #f9f9f9;
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: center;
  position: relative; /* Added position relative */
}

.faq-question h3 {
  margin: 0;
  font-size: 18px;
  font-weight: 600;
  color: #333;
  flex: 1;
  padding-right: 30px; /* Added padding to prevent text from overlapping with the toggle icon */
}

.faq-toggle {
  font-size: 24px;
  font-weight: bold;
  color: #4caf50;
  transition: transform 0.3s ease;
  position: absolute; /* Changed to absolute positioning */
  right: 20px; /* Fixed position from the right */
  top: 50%; /* Center vertically */
  transform: translateY(-50%); /* Center vertically */
  width: 20px; /* Fixed width */
  height: 20px; /* Fixed height */
  text-align: center; /* Center the text */
  line-height: 20px; /* Center the text vertically */
}

.faq-question.active .faq-toggle {
  color: #e53935;
}

.faq-answer {
  padding: 0;
  max-height: 0; /* Start with 0 height when collapsed */
  overflow: hidden;
  transition: all 0.3s ease;
}

.faq-question.active + .faq-answer {
  padding: 15px 20px;
  max-height: none !important; /* Use none instead of a fixed value */
  height: auto !important; /* Ensure height is auto */
}

.faq-answer p {
  margin: 0;
  line-height: 1.6;
}

/* Add schema markup for SEO */
.faq-section[itemscope] {
  margin-top: 40px;
}

/* ── AEO Content Components ──────────────────────────────────────────
   These classes are injected by the AEO content generator and render
   AEO posts visually distinct from standard SEO blog posts.
   ─────────────────────────────────────────────────────────────────── */

/* Direct Answer Box */
.aeo-answer-box {
  position: relative;
  margin: 0 0 36px;
  padding: 22px 24px 22px 28px;
  background: #f0f9ff;
  border-left: 5px solid #0ea5e9;
  border-radius: 0 10px 10px 0;
  box-shadow: 0 2px 12px rgba(14, 165, 233, 0.10);
}

.aeo-answer-box::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  bottom: 0;
  width: 5px;
  background: linear-gradient(180deg, #0ea5e9 0%, #38bdf8 100%);
  border-radius: 4px 0 0 4px;
}

.aeo-answer-label {
  display: inline-block;
  margin-bottom: 10px;
  padding: 3px 10px;
  background: #0ea5e9;
  color: #fff;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  border-radius: 20px;
}

.aeo-answer-box p {
  margin: 0;
  font-size: 16px;
  line-height: 1.65;
  color: #0c4a6e;
  font-weight: 500;
}

/* Fact List */
.aeo-fact-list {
  margin: 32px 0;
  padding: 22px 24px;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 10px;
}

.aeo-fact-list h2 {
  margin: 0 0 16px;
  font-size: 20px;
  color: #1e293b;
}

.aeo-fact-list ul {
  margin: 0;
  padding: 0;
  list-style: none;
}

.aeo-fact-list ul li {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 10px 0;
  border-bottom: 1px solid #e2e8f0;
  font-size: 15px;
  line-height: 1.55;
  color: #374151;
}

.aeo-fact-list ul li:last-child {
  border-bottom: none;
  padding-bottom: 0;
}

.aeo-fact-list ul li::before {
  content: '';
  flex-shrink: 0;
  margin-top: 6px;
  width: 8px;
  height: 8px;
  background: #0ea5e9;
  border-radius: 50%;
}

.aeo-fact-list ul li strong {
  color: #1e293b;
}

/* How-To Steps */
.aeo-how-to {
  margin: 32px 0;
  padding: 24px 24px 20px;
  background: #fff;
  border: 1px solid #e2e8f0;
  border-top: 4px solid #6366f1;
  border-radius: 0 0 10px 10px;
}

.aeo-how-to h2 {
  margin: 0 0 20px;
  font-size: 20px;
  color: #1e293b;
}

.aeo-how-to ol {
  margin: 0;
  padding: 0;
  list-style: none;
  counter-reset: aeo-step;
}

.aeo-how-to ol li {
  display: flex;
  align-items: flex-start;
  gap: 16px;
  padding: 14px 0;
  border-bottom: 1px solid #f1f5f9;
  font-size: 15px;
  line-height: 1.6;
  color: #374151;
  counter-increment: aeo-step;
}

.aeo-how-to ol li:last-child {
  border-bottom: none;
  padding-bottom: 0;
}

.aeo-how-to ol li::before {
  content: counter(aeo-step);
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 30px;
  height: 30px;
  background: #6366f1;
  color: #fff;
  font-size: 13px;
  font-weight: 700;
  border-radius: 50%;
  margin-top: 1px;
}

.aeo-how-to ol li strong {
  color: #4338ca;
}

/* FAQ Block */
.aeo-faq-block {
  margin: 36px 0 0;
  padding-top: 28px;
  border-top: 2px solid #e2e8f0;
}

.aeo-faq-block > h2 {
  margin: 0 0 20px;
  font-size: 22px;
  color: #1e293b;
}

.aeo-faq-item {
  margin-bottom: 4px;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  overflow: hidden;
}

.aeo-faq-question {
  margin: 0;
  padding: 16px 52px 16px 20px;
  font-size: 16px;
  font-weight: 600;
  color: #1e293b;
  background: #f8fafc;
  cursor: pointer;
  position: relative;
  transition: background 0.15s;
  user-select: none;
}

.aeo-faq-question::after {
  content: '+';
  position: absolute;
  right: 20px;
  top: 50%;
  transform: translateY(-50%);
  font-size: 22px;
  font-weight: 400;
  color: #6366f1;
  line-height: 1;
  transition: transform 0.2s;
}

.aeo-faq-question.aeo-open::after {
  content: '−';
}

.aeo-faq-question:hover {
  background: #f1f5f9;
}

.aeo-faq-answer {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.25s ease, padding 0.2s ease;
  padding: 0 20px;
}

.aeo-faq-answer.aeo-open {
  max-height: 500px;
  padding: 16px 20px;
}

.aeo-faq-answer p {
  margin: 0;
  font-size: 15px;
  line-height: 1.65;
  color: #475569;
}
