/* ══════════════════════════════════════════
   blog.css — Shared Blog Post Styles
   InstantToolsPro | /blog/assets/css/blog.css
   v2.0 — Fully Mobile Responsive
══════════════════════════════════════════ */

/* ── Animations ── */
@keyframes fadeUp {
  from { opacity:0; transform:translateY(18px); }
  to   { opacity:1; transform:translateY(0); }
}
@keyframes pulse {
  0%, 100% { transform:scale(1); opacity:1; }
  50%       { transform:scale(.7); opacity:.5; }
}

/* ══ HERO ══ */
.post-hero {
  background: #fff;
  border-bottom: 1px solid #f0f0f5;
  padding: 56px 24px 48px;
  text-align: center;
  position: relative;
  overflow: hidden;
  animation: fadeUp .5s ease both;
}
.post-hero::before {
  content: '';
  position: absolute;
  top: -60px; left: 50%;
  transform: translateX(-50%);
  width: 500px; height: 260px;
  background: radial-gradient(ellipse, rgba(255,77,77,.07) 0%, transparent 70%);
  pointer-events: none;
}
.post-hero-inner { position: relative; z-index: 1; }

/* Breadcrumb */
.post-breadcrumb {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
  font-size: .78rem;
  color: #9ca3af;
  margin-bottom: 16px;
  flex-wrap: wrap;
}
.post-breadcrumb a { color: #6b7280; text-decoration: none; transition: color .2s; }
.post-breadcrumb a:hover { color: #ff4d4d; }
.post-breadcrumb span { color: #d1d5db; }

.post-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: #fff5f5;
  border: 1px solid #ffd5d5;
  color: #ff4d4d;
  font-size: .74rem;
  font-weight: 700;
  letter-spacing: .07em;
  text-transform: uppercase;
  padding: 5px 14px;
  border-radius: 999px;
  margin-bottom: 16px;
}

.post-hero h1 {
  font-family: 'Sora', sans-serif;
  font-size: clamp(1.5rem, 4vw, 2.6rem);
  font-weight: 800;
  color: #111827;
  line-height: 1.2;
  margin: 0 0 18px;
  letter-spacing: -.02em;
  max-width: 720px;
  margin-left: auto;
  margin-right: auto;
}
.post-hero h1 span { color: #ff4d4d; }

.post-meta {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
  font-size: .82rem;
  color: #9ca3af;
  flex-wrap: wrap;
}
.post-meta-item { display: flex; align-items: center; gap: 5px; }

/* ══ LAYOUT ══ */
.post-wrap {
  max-width: 1100px;
  margin: 0 auto;
  padding: 40px 20px 72px;
  display: grid;
  grid-template-columns: 1fr 290px;
  gap: 40px;
  align-items: start;
}
.post-main {
  animation: fadeUp .5s .1s ease both;
  min-width: 0;
}

/* ══ TOC ══ */
.post-toc {
  background: #f9fafb;
  border: 1.5px solid #f0f0f5;
  border-left: 4px solid #ff4d4d;
  border-radius: 12px;
  padding: 18px 22px;
  margin-bottom: 32px;
}
.post-toc h4 {
  font-family: 'Sora', sans-serif;
  font-size: .88rem;
  font-weight: 700;
  color: #111827;
  margin: 0 0 12px;
  display: flex;
  align-items: center;
  gap: 8px;
}
.post-toc ol {
  margin: 0;
  padding-left: 18px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.post-toc ol li { font-size: .86rem; color: #6b7280; }
.post-toc ol li a { color: #374151; text-decoration: none; transition: color .2s; }
.post-toc ol li a:hover { color: #ff4d4d; }

/* ══ ARTICLE BODY ══ */
.post-body h2 {
  font-family: 'Sora', sans-serif;
  font-size: clamp(1.15rem, 3vw, 1.45rem);
  font-weight: 800;
  color: #111827;
  margin: 36px 0 12px;
  letter-spacing: -.01em;
  display: flex;
  align-items: center;
  gap: 10px;
}
.post-body h2::before {
  content: '';
  display: inline-block;
  width: 4px; height: 20px;
  background: #ff4d4d;
  border-radius: 2px;
  flex-shrink: 0;
}
.post-body h3 {
  font-family: 'Sora', sans-serif;
  font-size: clamp(1rem, 2.5vw, 1.1rem);
  font-weight: 700;
  color: #111827;
  margin: 24px 0 10px;
}
.post-body p {
  font-size: .96rem;
  color: #374151;
  line-height: 1.8;
  margin: 0 0 14px;
}
.post-body ul,
.post-body ol {
  margin: 0 0 16px;
  padding-left: 20px;
}
.post-body li {
  font-size: .94rem;
  color: #374151;
  line-height: 1.75;
  margin-bottom: 6px;
}
.post-body strong { color: #111827; }
.post-body a {
  color: #ff4d4d;
  text-decoration: none;
  font-weight: 500;
  border-bottom: 1px solid rgba(255,77,77,.3);
  transition: border-color .2s;
}
.post-body a:hover { border-color: #ff4d4d; }

/* ══ IMAGES ══ */
.post-img {
  margin: 22px 0;
  border-radius: 12px;
  overflow: hidden;
  border: 1.5px solid #f0f0f5;
  box-shadow: 0 4px 20px rgba(0,0,0,.06);
}
.post-img img { width: 100%; height: auto; display: block; }

.post-figure {
  margin: 22px 0;
  border-radius: 12px;
  overflow: hidden;
  border: 1.5px solid #f0f0f5;
  box-shadow: 0 4px 20px rgba(0,0,0,.06);
}
.post-figure img { width: 100%; height: auto; display: block; }
.post-figure figcaption {
  background: #f9fafb;
  border-top: 1px solid #f0f0f5;
  padding: 9px 14px;
  font-size: .81rem;
  color: #6b7280;
  text-align: center;
}

.post-img-compare {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin: 22px 0;
}

/* ── Tip / Note Boxes ── */
.post-tip {
  background: #fff5f5;
  border: 1.5px solid #ffd5d5;
  border-radius: 12px;
  padding: 14px 18px;
  margin: 18px 0;
  display: flex;
  gap: 12px;
  align-items: flex-start;
}
.post-tip p { margin: 0; font-size: .91rem; color: #7f1d1d; line-height: 1.6; }

.post-note {
  background: #f0fdf4;
  border: 1.5px solid #bbf7d0;
  border-radius: 12px;
  padding: 14px 18px;
  margin: 18px 0;
  display: flex;
  gap: 12px;
  align-items: flex-start;
}
.post-note p { margin: 0; font-size: .91rem; color: #14532d; line-height: 1.6; }
.post-tip-icon { font-size: 1.1rem; flex-shrink: 0; margin-top: 2px; }

/* ── Step Boxes ── */
.post-steps { display: flex; flex-direction: column; gap: 12px; margin: 18px 0 24px; }
.post-step {
  display: flex;
  gap: 14px;
  align-items: flex-start;
  background: #fff;
  border: 1.5px solid #f0f0f5;
  border-radius: 14px;
  padding: 16px 18px;
  transition: border-color .2s, box-shadow .2s;
}
.post-step:hover {
  border-color: #ffd5d5;
  box-shadow: 0 4px 14px rgba(255,77,77,.06);
}
.post-step-num {
  width: 34px; height: 34px;
  min-width: 34px;
  background: #ff4d4d;
  color: #fff;
  border-radius: 9px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: 'Sora', sans-serif;
  font-weight: 800;
  font-size: .88rem;
  flex-shrink: 0;
}
.post-step-content h4 {
  font-family: 'Sora', sans-serif;
  font-size: .95rem;
  font-weight: 700;
  color: #111827;
  margin: 0 0 5px;
}
.post-step-content p { font-size: .87rem; color: #6b7280; margin: 0; line-height: 1.6; }

/* ── Table — RESPONSIVE WRAPPER ── */
.post-table-wrap {
  width: 100%;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  margin: 20px 0 26px;
  border-radius: 12px;
  border: 1.5px solid #f0f0f5;
  /* Scroll hint on mobile */
  background:
    linear-gradient(to right, white 30%, rgba(255,255,255,0)),
    linear-gradient(to right, rgba(255,255,255,0), white 70%) 100% 0,
    radial-gradient(farthest-side at 0% 50%, rgba(0,0,0,.08), transparent),
    radial-gradient(farthest-side at 100% 50%, rgba(0,0,0,.08), transparent) 100% 0;
  background-repeat: no-repeat;
  background-size: 40px 100%, 40px 100%, 14px 100%, 14px 100%;
  background-attachment: local, local, scroll, scroll;
}
.post-table {
  width: 100%;
  min-width: 460px;
  border-collapse: collapse;
  font-size: .88rem;
  background: #fff;
}
.post-table th {
  background: #f9fafb;
  padding: 11px 14px;
  text-align: left;
  font-family: 'Sora', sans-serif;
  font-weight: 700;
  font-size: .79rem;
  color: #374151;
  text-transform: uppercase;
  letter-spacing: .05em;
  border-bottom: 1.5px solid #f0f0f5;
  white-space: nowrap;
}
.post-table td {
  padding: 11px 14px;
  color: #374151;
  border-bottom: 1px solid #f9fafb;
  vertical-align: middle;
}
.post-table tr:last-child td { border-bottom: none; }
.post-table tr:hover td { background: #fafafa; }
.check { color: #16a34a; font-weight: 700; }
.cross  { color: #dc2626; font-weight: 700; }

/* ── CTA Box ── */
.post-cta {
  background: linear-gradient(135deg, #fff5f5, #ffe8e8);
  border: 1.5px solid #ffd5d5;
  border-radius: 16px;
  padding: 24px;
  margin: 28px 0;
  display: flex;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
}
.post-cta-icon {
  width: 52px; height: 52px;
  min-width: 52px;
  background: #fff;
  border: 1.5px solid #ffd5d5;
  border-radius: 13px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  box-shadow: 0 2px 10px rgba(255,77,77,.10);
}
.post-cta-text { flex: 1; min-width: 160px; }
.post-cta-text h4 {
  font-family: 'Sora', sans-serif;
  font-size: .97rem;
  font-weight: 800;
  color: #111827;
  margin: 0 0 4px;
}
.post-cta-text p { font-size: .85rem; color: #6b7280; margin: 0; line-height: 1.5; }
.post-cta-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  background: #fff;
  color: #ffd5d5;
  font-weight: 700;
  font-size: .88rem;
  padding: 12px 20px;
  border-radius: 10px;
  text-decoration: none;
  transition: background .2s, transform .15s;
  white-space: nowrap;
  border-bottom: none !important;
}
.post-cta-btn:hover { background: #ffd5d5; transform: translateY(-1px); }

/* ── Tags ── */
.post-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 32px;
  padding-top: 22px;
  border-top: 1px solid #f0f0f5;
}
.post-tag {
  background: #f3f4f6;
  color: #374151;
  font-size: .77rem;
  font-weight: 600;
  padding: 5px 12px;
  border-radius: 999px;
  text-decoration: none;
  border-bottom: none !important;
  transition: background .2s, color .2s;
}
.post-tag:hover { background: #ff4d4d; color: #fff; }

/* ── Related Posts ── */
.post-related { margin-top: 44px; padding-top: 28px; border-top: 1.5px solid #f0f0f5; }
.post-related h3 {
  font-family: 'Sora', sans-serif;
  font-size: 1.05rem;
  font-weight: 800;
  color: #111827;
  margin: 0 0 16px;
}
.post-related-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.post-related-card {
  border: 1.5px solid #f0f0f5;
  border-radius: 12px;
  padding: 14px 16px;
  text-decoration: none;
  display: block;
  border-bottom: 1.5px solid #f0f0f5 !important;
  transition: border-color .2s, box-shadow .2s, transform .2s;
}
.post-related-card:hover {
  border-color: #ffd5d5 !important;
  box-shadow: 0 4px 14px rgba(255,77,77,.08);
  transform: translateY(-2px);
}
.post-related-card span {
  display: block;
  font-size: .72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .06em;
  color: #ff4d4d;
  margin-bottom: 5px;
}
.post-related-card h4 {
  font-family: 'Sora', sans-serif;
  font-size: .88rem;
  font-weight: 700;
  color: #111827;
  margin: 0;
  line-height: 1.4;
}

/* ══ SIDEBAR ══ */
.post-sidebar {
  position: sticky;
  top: 88px;
  display: flex;
  flex-direction: column;
  gap: 18px;
  animation: fadeUp .5s .2s ease both;
}
.sidebar-box {
  background: #fff;
  border: 1.5px solid #f0f0f5;
  border-radius: 16px;
  padding: 20px;
}
.sidebar-box h4 {
  font-family: 'Sora', sans-serif;
  font-size: .88rem;
  font-weight: 800;
  color: #111827;
  margin: 0 0 13px;
  display: flex;
  align-items: center;
  gap: 6px;
}
.sidebar-tool {
  background: linear-gradient(135deg, #fff5f5, #ffe8e8);
  border: 1.5px solid #ffd5d5;
}
.sidebar-tool-icon {
  width: 48px; height: 48px;
  background: #fff;
  border: 1.5px solid #ffd5d5;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 12px;
  box-shadow: 0 2px 10px rgba(255,77,77,.10);
}
.sidebar-tool p { font-size: .84rem; color: #6b7280; line-height: 1.6; margin: 0 0 14px; }
.sidebar-tool-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  background: #ff4d4d;
  color: #fff;
  font-weight: 700;
  font-size: .87rem;
  padding: 11px;
  border-radius: 10px;
  text-decoration: none;
  border-bottom: none !important;
  transition: background .2s;
  width: 100%;
  box-sizing: border-box;
}
.sidebar-tool-btn:hover { background: #e03c3c; }

.sidebar-facts { list-style: none; padding: 0; margin: 0; }
.sidebar-facts li {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 8px 0;
  font-size: .84rem;
  border-bottom: 1px solid #f3f4f6;
}
.sidebar-facts li:last-child { border-bottom: none; }
.sidebar-facts li span:first-child { color: #6b7280; }
.sidebar-facts li span:last-child { font-weight: 700; color: #111827; }

.sidebar-links { display: flex; flex-direction: column; gap: 8px; }
.sidebar-link {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  border-bottom: none !important;
  padding: 9px 11px;
  border-radius: 10px;
  background: #f9fafb;
  transition: background .2s;
}
.sidebar-link:hover { background: #fff5f5; }
.sidebar-link-icon {
  width: 30px; height: 30px;
  min-width: 30px;
  background: #fff5f5;
  border-radius: 7px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.sidebar-link span { font-size: .83rem; font-weight: 600; color: #374151; line-height: 1.3; }

/* ══════════════════════════════
   RESPONSIVE BREAKPOINTS
══════════════════════════════ */

/* Tablet — max 900px */
@media (max-width: 900px) {
  .post-wrap {
    grid-template-columns: 1fr;
    gap: 32px;
    padding: 32px 16px 60px;
  }
  .post-sidebar {
    position: static;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 14px;
  }
}

/* Mobile — max 640px */
@media (max-width: 640px) {
  .post-hero {
    padding: 36px 16px 28px;
  }
  .post-wrap {
    padding: 22px 14px 48px;
  }
  .post-sidebar {
    grid-template-columns: 1fr;
  }
  .post-related-grid {
    grid-template-columns: 1fr;
  }
  .post-img-compare {
    grid-template-columns: 1fr;
  }
  .post-cta {
    flex-direction: column;
    align-items: flex-start;
    padding: 18px;
    gap: 14px;
  }
  .post-cta-btn {
    width: 100%;
    box-sizing: border-box;
  }
  .post-step {
    padding: 13px 14px;
  }
  .post-toc {
    padding: 14px 16px;
  }
  .post-body h2 {
    flex-wrap: wrap;
  }
}

/* Small Mobile — max 400px */
@media (max-width: 400px) {
  .post-meta {
    gap: 10px;
    font-size: .76rem;
  }
  .post-body p,
  .post-body li {
    font-size: .91rem;
  }
  .post-step-num {
    width: 30px; height: 30px;
    min-width: 30px;
    font-size: .82rem;
  }
  .sidebar-facts li {
    font-size: .8rem;
  }
}
/* ══ FAQ Section ══ */
.post-body h3 + p,
.faq-section h3 + p {
  background: #f9fafb;
  border-left: 4px solid #ff4d4d;
  border-radius: 0 8px 8px 0;
  padding: 12px 16px;
  margin: 0 0 16px;
  color: #374151;
  font-size: .9rem;
  line-height: 1.7;
}

.faq-item {
  border: 1.5px solid #f0f0f5;
  border-radius: 12px;
  margin-bottom: 10px;
  overflow: hidden;
  transition: border-color .2s;
}
.faq-item:hover { border-color: #ff4d4d33; }

.faq-q {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 18px;
  background: #fff;
  border: none;
  cursor: pointer;
  font-size: .95rem;
  font-weight: 700;
  color: #111827;
  text-align: left;
  font-family: inherit;
  gap: 12px;
  transition: background .15s;
}
.faq-q:hover { background: #fff8f8; }

.faq-chevron {
  flex-shrink: 0;
  transition: transform .25s;
  color: #ff4d4d;
}
.faq-item.open .faq-chevron { transform: rotate(180deg); }

.faq-a {
  max-height: 0;
  overflow: hidden;
  transition: max-height .3s ease, padding .3s;
  background: #fff;
}
.faq-item.open .faq-a {
  max-height: 500px;
  padding: 0 18px 16px;
}
.faq-a p {
  color: #6b7280;
  font-size: .9rem;
  line-height: 1.75;
  margin: 0;
  border-left: none !important;
  background: none !important;
  padding: 0 !important;
}

/* H3 inside post-body as FAQ style */
.post-body h3 {
  font-size: 1.1rem;
  font-weight: 800;
  color: #111827;
  margin: 1.8em 0 .5em;
  padding-left: 12px;
  border-left: 3px solid #ff4d4d;
}

/* FAQ Override Fix */
.post-faq .faq-a {
  display: block !important;
  max-height: 0 !important;
  overflow: hidden !important;
  transition: max-height .3s ease, padding .3s !important;
  padding: 0 18px !important;
}
.post-faq .faq-item.open .faq-a {
  max-height: 500px !important;
  padding: 0 18px 16px !important;
}
