/* ===================================
   BLOG PAGE STYLES - Light Theme (matches nissuu.css)
   =================================== */

/* Blog Content Layout */
.blog-content {
  max-width: 860px;
  margin: 0 auto;
  padding: 2rem 1.5rem 4rem;
  font-size: 1rem;
  line-height: 1.8;
  color: var(--color-text, #0F172A);
}

/* Author Avatar */
.author-avatar {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  object-fit: cover;
  border: 2px solid var(--color-border, #E5E7EB);
}

.author-avatar-large {
  width: 72px;
  height: 72px;
  border-radius: 50%;
  object-fit: cover;
  border: 2px solid var(--color-border, #E5E7EB);
  flex-shrink: 0;
}

/* Headings */
.blog-content h2 {
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--color-text, #0F172A);
  margin-top: 2.5rem;
  margin-bottom: 1rem;
  letter-spacing: -0.02em;
  scroll-margin-top: 80px;
}

.blog-content h3 {
  font-size: 1.125rem;
  font-weight: 600;
  color: var(--color-text, #0F172A);
  margin-top: 1.75rem;
  margin-bottom: 0.75rem;
  scroll-margin-top: 80px;
}

.blog-content h4 {
  font-size: 1rem;
  font-weight: 600;
  color: var(--color-text, #0F172A);
  margin-top: 1.25rem;
  margin-bottom: 0.5rem;
}

.blog-content h5 {
  font-size: 0.9375rem;
  font-weight: 600;
  color: var(--color-text, #0F172A);
  margin-bottom: 0.5rem;
}

.blog-content p {
  margin-bottom: 1.125rem;
  color: var(--color-text, #0F172A);
}

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

.blog-content li {
  margin-bottom: 0.5rem;
  color: var(--color-text, #0F172A);
}

.blog-content strong {
  color: var(--color-text, #0F172A);
  font-weight: 600;
}

/* Author Box */
.author-box {
  background: #F8FAFC;
  border-left: 3px solid var(--color-primary, #4CC9F0);
  padding: 1.25rem 1.5rem;
  margin: 1.75rem 0;
  border-radius: 0 1rem 1rem 0;
  border-top: 1px solid var(--color-border, #E5E7EB);
  border-right: 1px solid var(--color-border, #E5E7EB);
  border-bottom: 1px solid var(--color-border, #E5E7EB);
}

.author-box p {
  margin: 0;
  color: var(--color-text, #0F172A);
  font-size: 0.9rem;
  line-height: 1.7;
}

.author-box strong {
  color: var(--color-text, #0F172A);
}

/* Table of Contents */
.table-of-contents {
  background: #F8FAFC;
  border: 1px solid var(--color-border, #E5E7EB);
  padding: 1.25rem 1.5rem;
  border-radius: 1rem;
  margin: 1.75rem 0;
}

.table-of-contents h4 {
  color: var(--color-text, #0F172A);
  margin-bottom: 0.875rem;
  font-weight: 600;
  font-size: 0.9375rem;
}

.table-of-contents ul {
  margin-bottom: 0;
  padding-left: 0;
  list-style: none;
}

.table-of-contents ul li {
  margin-bottom: 0.375rem;
  padding-left: 1.25rem;
  position: relative;
}

.table-of-contents ul li::before {
  content: "→";
  position: absolute;
  left: 0;
  color: var(--color-primary, #4CC9F0);
  font-weight: 600;
}

.table-of-contents a {
  color: #334155;
  text-decoration: none;
  font-size: 0.875rem;
  transition: color 0.2s;
}

.table-of-contents a:hover {
  color: var(--color-primary, #4CC9F0);
}

/* Key Takeaway Box */
.key-takeaway {
  background: linear-gradient(135deg, rgba(76, 201, 240, 0.08), rgba(128, 237, 153, 0.08));
  border: 1px solid rgba(76, 201, 240, 0.25);
  padding: 1.25rem 1.5rem;
  margin: 1.75rem 0;
  border-radius: 1rem;
}

.key-takeaway h5 {
  color: var(--color-text, #0F172A);
  margin-bottom: 0.75rem;
  font-size: 0.9375rem;
}

.key-takeaway p,
.key-takeaway ul {
  color: var(--color-text, #0F172A);
  margin-bottom: 0;
  font-size: 0.9rem;
}

.key-takeaway ul {
  padding-left: 1.25rem;
  margin-top: 0.5rem;
}

.key-takeaway li {
  margin-bottom: 0.375rem;
  color: var(--color-text, #0F172A);
}

/* Section Divider */
.section-divider {
  border: 0;
  height: 1px;
  background: var(--color-border, #E5E7EB);
  margin: 2.5rem 0;
}

/* Chart Container (stats block) */
.chart-container {
  margin: 1.75rem 0;
  padding: 1.25rem;
  background: #F8FAFC;
  border-radius: 1rem;
  border: 1px solid var(--color-border, #E5E7EB);
}

/* External Links */
.external-link {
  color: var(--color-primary, #4CC9F0);
  text-decoration: none;
  border-bottom: 1px solid rgba(76, 201, 240, 0.4);
  transition: all 0.2s;
}

.external-link:hover {
  color: #3BA8D0;
  border-bottom-color: #3BA8D0;
}

/* ===================================
   TABLE STYLES
   =================================== */

.blog-content .table {
  width: 100%;
  margin: 1.5rem 0;
  font-size: 0.875rem;
  border-collapse: collapse;
  background: #fff;
  color: var(--color-text, #0F172A);
}

.table-responsive {
  border-radius: 1rem;
  border: 1px solid var(--color-border, #E5E7EB);
  overflow: hidden;
  margin: 1.5rem 0;
}

.table-responsive .table {
  margin: 0;
}

.blog-content .table thead th {
  background: #F8FAFC;
  color: var(--color-text, #0F172A) !important;
  font-weight: 600;
  font-size: 0.8125rem;
  padding: 0.875rem 1rem;
  border-bottom: 2px solid var(--color-border, #E5E7EB);
  text-align: left;
  white-space: nowrap;
}

.blog-content .table tbody td {
  padding: 0.75rem 1rem;
  border-bottom: 1px solid var(--color-border, #E5E7EB);
  color: var(--color-text, #0F172A) !important;
  vertical-align: middle;
  background: #fff !important;
}

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

.blog-content .table tbody tr:hover td {
  background: #F8FAFC !important;
  color: var(--color-text, #0F172A) !important;
}

.blog-content .table tbody td strong {
  color: var(--color-text, #0F172A) !important;
}

/* table-dark override to light */
.blog-content .table-dark thead,
.blog-content .table.table-dark thead {
  background: linear-gradient(90deg, rgba(76, 201, 240, 0.13), rgba(128, 237, 153, 0.13));
}

.blog-content .table-dark thead th,
.blog-content .table.table-dark thead th {
  color: var(--color-text, #0F172A) !important;
  background: transparent !important;
  border-bottom: 2px solid var(--color-border, #E5E7EB);
}

.blog-content .table-dark tbody tr,
.blog-content .table.table-dark tbody tr {
  background: #fff !important;
}

.blog-content .table-dark tbody td,
.blog-content .table.table-dark tbody td {
  color: var(--color-text, #0F172A) !important;
  background: transparent !important;
}

/* table-hover */
.blog-content .table-hover tbody tr:hover td {
  background: #F1F5F9 !important;
  color: var(--color-text, #0F172A) !important;
}

/* table-bordered */
.blog-content .table-bordered th,
.blog-content .table-bordered td {
  border: 1px solid var(--color-border, #E5E7EB);
}

/* table-striped */
.blog-content .table-striped tbody tr:nth-of-type(odd) td {
  background: #F8FAFC !important;
}

.blog-content .table-striped tbody tr:nth-of-type(even) td {
  background: #fff !important;
}

/* ===================================
   ACCORDION (FAQ)
   =================================== */

.accordion {
  --bs-accordion-bg: #fff;
  --bs-accordion-border-color: var(--color-border, #E5E7EB);
  --bs-accordion-btn-bg: #fff;
  --bs-accordion-active-bg: #F8FAFC;
  --bs-accordion-btn-color: var(--color-text, #0F172A);
  --bs-accordion-active-color: var(--color-text, #0F172A);
}

.accordion-item {
  background: #fff;
  border: 1px solid var(--color-border, #E5E7EB);
  margin-bottom: 0.5rem;
  border-radius: 1rem !important;
  overflow: hidden;
}

.accordion-button {
  color: var(--color-text, #0F172A);
  font-weight: 600;
  font-size: 0.9375rem;
  padding: 1rem 1.25rem;
  background: #fff;
}

.accordion-button:not(.collapsed) {
  background: linear-gradient(90deg, rgba(76, 201, 240, 0.08), rgba(128, 237, 153, 0.08));
  color: var(--color-text, #0F172A);
  box-shadow: none;
}

.accordion-button:focus {
  box-shadow: none;
  border-color: rgba(76, 201, 240, 0.3);
}

.accordion-button::after {
  filter: none;
}

.accordion-body {
  color: var(--color-text, #0F172A);
  padding: 1rem 1.25rem;
  background: #F8FAFC;
  font-size: 0.9rem;
  line-height: 1.7;
}

/* ===================================
   BUTTONS
   =================================== */

.blog-content .btn-primary {
  background: var(--color-accent, #F72585);
  border: none;
  padding: 0.75rem 1.75rem;
  font-weight: 600;
  border-radius: 1rem;
  color: #fff;
  transition: all 0.2s;
}

.blog-content .btn-primary:hover {
  opacity: 0.9;
  transform: translateY(-1px);
  color: #fff;
}

.blog-content .btn-outline-secondary {
  border: 1px solid var(--color-border, #E5E7EB);
  color: #334155;
  background: #fff;
  padding: 0.75rem 1.5rem;
  font-weight: 500;
  border-radius: 1rem;
  transition: all 0.2s;
}

/* Badge overrides for blog header */
.blog-page .nissuu-badge-secondary {
  color: #334155;
  background: #F1F5F9;
}

.blog-page .nissuu-badge-primary {
  color: #0369a1;
  background: rgba(76, 201, 240, 0.18);
}

.blog-content .btn-outline-secondary:hover {
  background: #F8FAFC;
  color: var(--color-text, #0F172A);
}

/* ===================================
   UTILITY
   =================================== */

.border-top {
  border-top: 1px solid var(--color-border, #E5E7EB) !important;
}

.text-muted {
  color: var(--color-text-muted, #64748B) !important;
}

/* ===================================
   RESPONSIVE
   =================================== */

@media (max-width: 768px) {
  .blog-content {
    padding: 1.5rem 1rem 3rem;
    font-size: 0.9375rem;
  }

  .blog-content h2 {
    font-size: 1.25rem;
    margin-top: 2rem;
  }

  .blog-content h3 {
    font-size: 1.0625rem;
  }

  .blog-content .table thead th,
  .blog-content .table tbody td {
    padding: 0.625rem 0.75rem;
    font-size: 0.8125rem;
  }

  .author-box,
  .table-of-contents,
  .key-takeaway,
  .chart-container {
    padding: 1rem 1.125rem;
  }

  .accordion-button,
  .accordion-body {
    padding: 0.875rem 1rem;
  }

  .author-avatar {
    width: 38px;
    height: 38px;
  }

  .author-avatar-large {
    width: 56px;
    height: 56px;
  }
}

@media (max-width: 576px) {
  .blog-content .table thead th,
  .blog-content .table tbody td {
    padding: 0.5rem 0.625rem;
    font-size: 0.75rem;
  }
}
