/* ============================================
   SINGLE POST — Fluentz Templates
   Prefix: .fluentz-posts-*
   ============================================ */

body.single-post {
  background: #fefeff !important;
}

.fluentz-posts-wrapper {
  --fp-purple: #7b2bbe;
  --fp-purple-mid: #9b4fd8;
  --fp-purple-light: #c084f5;
  --fp-purple-tint: #f5eeff;
  --fp-purple-tint2: #ede0ff;
  --fp-purple-dark: #5a1f8c;
  --fp-text: #1a1025;
  --fp-text-mid: #111111;
  --fp-text-soft: #7e6e94;
  --fp-text-faint: #b0a3c0;
  --fp-border: #e8e0f0;
  --fp-border-mid: #d8ccec;
  --fp-bg: #f9f7fc;
  --fp-bg-card: #ffffff;

  font-family: "Plus Jakarta Sans", "Mulish", sans-serif;
  line-height: 1.7;
  color: var(--fp-text);
}

/* Wrapper */
.fluentz-posts-wrapper {
  max-width: 1050px;
  margin: 0 auto;
  padding: 16px 24px 100px;
  box-sizing: border-box;
}

.fluentz-posts-wrapper *,
.fluentz-posts-wrapper *::before,
.fluentz-posts-wrapper *::after {
  box-sizing: border-box;
}

/* Breadcrumb */
.fluentz-posts-breadcrumb {
  display: flex;
  align-items: center;
  gap: 7px;
  margin-left: 10px;
  margin-bottom: 20px;
  font-size: 14px;
  font-weight: 600;
  color: var(--fp-text-faint);
  font-family: "Mulish", sans-serif;
  letter-spacing: 0.02em;
}
.fluentz-posts-breadcrumb a {
  color: var(--fp-purple-mid);
  text-decoration: none;
  transition: color 0.2s;
}
.fluentz-posts-breadcrumb a:hover {
  color: var(--fp-purple);
  text-decoration: none;
}
.fluentz-posts-breadcrumb .sep {
  color: var(--fp-border-mid);
}
.fluentz-posts-breadcrumb-title {
  color: var(--fp-text-soft);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  min-width: 0;
}

/* Layout grid */
.fluentz-posts-layout {
  display: block;
}

/*  MAIN CARD  */
.fluentz-posts-card {
  background: var(--fp-bg-card);
  border: 1px solid var(--fp-border);
  border-radius: 10px;
  overflow: hidden;
  box-shadow:
    0 1px 3px rgba(123, 43, 190, 0.06),
    0 12px 40px rgba(123, 43, 190, 0.07),
    0 2px 8px rgba(0, 0, 0, 0.04);
  animation: fpRise 0.55s cubic-bezier(0.22, 1, 0.36, 1) both;
}
@keyframes fpRise {
  from {
    opacity: 0;
    transform: translateY(18px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Featured image */
.fluentz-posts-featured {
  width: 100%;
  aspect-ratio: 16/7;
  overflow: hidden;
  position: relative;
}
.fluentz-posts-featured img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.7s ease;
}
.fluentz-posts-card:hover .fluentz-posts-featured img {
  transform: scale(1.02);
}
.fluentz-posts-featured::after {
  content: "";
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 50%;
  background: linear-gradient(to top, rgba(255, 255, 255, 0.6), transparent);
}

/* Card body */
.fluentz-posts-card-body {
  padding: 40px 44px 48px;
}

/* Title */
.fluentz-posts-card .fluentz-posts-title {
  font-family: "Plus Jakarta Sans", "Mulish", sans-serif;
  font-size: 32px !important;
  font-weight: 700;
  line-height: 1.22;
  color: var(--fp-text);
  margin-bottom: 22px;
  letter-spacing: -0.025em;
}

/* Meta bar */
.fluentz-posts-meta-bar {
  display: flex;
  flex-direction: row !important;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px 14px;
  margin-bottom: 16px;
  padding-bottom: 28px;
  border-bottom: 1.5px solid var(--fp-border);
  font-size: 13px;
}
.fluentz-posts-meta-date {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: 13.5px;
  font-weight: 600;
  color: var(--fp-text-mid);
}
.fluentz-posts-meta-date i,
.fluentz-posts-meta-date svg {
  color: var(--fp-purple-mid);
  flex-shrink: 0;
  font-size: 13px;
}
.fluentz-posts-meta-author {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 13.5px;
  font-weight: 700;
  color: var(--fp-text);
  text-decoration: none;
}
.fluentz-posts-meta-author i,
.fluentz-posts-meta-author svg {
  color: var(--fp-purple-mid);
  flex-shrink: 0;
  font-size: 13px;
}

/* Content */
.fluentz-posts-content p {
  font-size: 16px;
  line-height: 2rem;
  font-weight: 400;
  color: var(--fp-text-mid);
  margin-bottom: 24px;
}
.fluentz-posts-content h2 {
  font-family: "Plus Jakarta Sans", "Mulish", sans-serif;
  font-size: 24px;
  font-weight: 800;
  color: var(--fp-text);
  margin: 40px 0 16px;
  letter-spacing: -0.02em;
  padding-left: 18px;
  position: relative;
}
.fluentz-posts-content h2::before {
  content: "";
  position: absolute;
  left: 0;
  top: 4px;
  bottom: 4px;
  width: 3.5px;
  background: linear-gradient(
    to bottom,
    var(--fp-purple),
    var(--fp-purple-light)
  );
  border-radius: 4px;
}
.fluentz-posts-content h3 {
  font-size: 18px;
  font-weight: 700;
  color: var(--fp-text);
  margin: 32px 0 12px;
}
.fluentz-posts-content a {
  color: var(--fp-purple);
  text-decoration: underline;
  text-underline-offset: 3px;
  text-decoration-color: var(--fp-purple-light);
}
.fluentz-posts-content a:hover {
  text-decoration-color: var(--fp-purple);
}
.fluentz-posts-content blockquote {
  margin: 14px 0;
  padding: 12px 26px;
  background: var(--fp-purple-tint);
  border-left: 4px solid var(--fp-purple);
  border-radius: 0 12px 12px 0;
  font-family: "Plus Jakarta Sans", "Mulish", sans-serif;
  font-size: 18px;
  font-style: italic;
  color: var(--fp-text-mid);
  line-height: 1.7;
}
.fluentz-posts-content img {
  max-width: 100% !important;
  border-radius: 12px;
  margin: 28px auto;
  border: 1px solid var(--fp-border);
  box-shadow: 0 4px 20px rgba(123, 43, 190, 0.08);
  display: block;
}
.fluentz-posts-content ul,
.fluentz-posts-content ol {
  padding-left: 22px;
  margin-bottom: 22px;
}
.fluentz-posts-content li {
  font-size: 15px;
  color: var(--fp-text-mid);
  line-height: 1.9rem;
  margin-bottom: 8px;
}
.fluentz-posts-content li::marker {
  color: var(--fp-purple);
}
.fluentz-posts-content code {
  background: var(--fp-purple-tint);
  color: var(--fp-purple-dark);
  padding: 2px 7px;
  border-radius: 5px;
  font-family: monospace;
  font-size: 0.875em;
  border: 1px solid var(--fp-purple-tint2);
}
.fluentz-posts-content pre {
  background: #1a1025;
  border-radius: 12px;
  padding: 24px;
  overflow-x: auto;
  margin: 28px 0;
}
.fluentz-posts-content pre code {
  background: none;
  border: none;
  color: #c084f5;
  font-size: 14px;
}

/* ===== DYNAMIC BANNER ===== */
.fluentz-posts-banner {
  margin: 32px 0;
}
.fluentz-posts-banner a {
  display: block;
  border-radius: 12px;
  overflow: hidden;
  transition: opacity 0.3s ease;
}
.fluentz-posts-banner a:hover {
  opacity: 0.9;
}
.fluentz-posts-content .fluentz-posts-banner-img {
  width: 100% !important;
  max-width: 760px !important;
  height: auto;
  display: block;
  border-radius: 0 !important;
  margin: 32px auto !important;
  border: none !important;
  box-shadow: none !important;
}

/* ===== STICKY BUTTON BAR ===== */
.fluentz-posts-sticky-bar {
  position: sticky;
  bottom: 0;
  z-index: 99;
  padding: 14px 0;
  pointer-events: none;
}

.fluentz-posts-sticky-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  width: 100%;
  padding: 13px 24px;
  background: linear-gradient(135deg, #7b2bbe, #9b4fd8);
  color: #fff !important;
  border-radius: 10px;
  font-family: "Plus Jakarta Sans", "Mulish", sans-serif;
  font-size: 17px;
  font-weight: 600;
  letter-spacing: 0.02em;
  text-decoration: none !important;
  overflow: hidden;
  white-space: nowrap;
  cursor: pointer;
  position: relative;
  pointer-events: auto;
  transition: all 0.2s ease-in;
  box-shadow:
    0 6px 24px rgba(123, 43, 190, 0.35),
    0 2px 6px rgba(123, 43, 190, 0.15);
  animation: fpStickyFadeIn 0.5s cubic-bezier(0.22, 1, 0.36, 1) both;
}
@keyframes fpStickyFadeIn {
  from {
    opacity: 0;
    transform: translateY(12px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}
.fluentz-posts-sticky-btn:hover {
  background: linear-gradient(135deg, rgb(103, 35, 162), #8c48c4);
  color: #fff !important;
  text-decoration: none !important;
  transform: translateY(-2px);
  box-shadow:
    0 10px 22px rgba(123, 43, 190, 0.45),
    0 3px 10px rgba(123, 43, 190, 0.2);
}
.fluentz-posts-sticky-btn:active {
  transform: translateY(1px) scale(0.98) !important;
  box-shadow: 0 2px 8px rgba(123, 43, 190, 0.2);
}

/* Text */
.fluentz-posts-sticky-btn-text {
  color: #fff;
}

/* Icon */
.fluentz-posts-sticky-btn-icon {
  font-size: 18px !important;
  color: #fff;
  line-height: 1;
  display: inline-flex;
  align-items: center;
  height: 1em;
}

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

/* --- Tablet & small desktop --- */
@media (max-width: 880px) {
  .fluentz-posts-card-body {
    padding: 28px 24px 36px;
  }
  .fluentz-posts-title {
    font-size: clamp(22px, 4vw, 30px);
    margin-bottom: 18px;
  }
  .fluentz-posts-meta-bar {
    gap: 8px 14px;
    margin-bottom: 28px;
    padding-bottom: 20px;
  }
  .fluentz-posts-breadcrumb-title {
    max-width: 180px;
  }
}

/* --- Mobile --- */
@media (max-width: 480px) {
  .fluentz-posts-wrapper {
    padding: 12px 14px 90px;
  }
  .fluentz-posts-breadcrumb {
    font-size: 12px;
    margin-left: 4px;
    gap: 5px;
    margin-bottom: 14px;
  }
  .fluentz-posts-card {
    border-radius: 8px;
  }
  .fluentz-posts-card-body {
    padding: 22px 18px 28px;
  }
  .fluentz-posts-title {
    font-size: 22px;
    line-height: 1.3;
    margin-bottom: 14px;
  }
  .fluentz-posts-meta-bar {
    gap: 6px;
    margin-bottom: 22px;
    padding-bottom: 16px;
    font-size: 12px;
  }
  .fluentz-posts-meta-date,
  .fluentz-posts-meta-author {
    font-size: 12px;
  }
  .fluentz-posts-content p {
    font-size: 14.5px;
    line-height: 1.8rem;
    margin-bottom: 18px;
  }
  .fluentz-posts-content h2 {
    font-size: 19px;
    margin: 28px 0 10px;
    padding-left: 14px;
  }
  .fluentz-posts-content h3 {
    font-size: 16px;
    margin: 22px 0 8px;
  }
  .fluentz-posts-content li {
    font-size: 14px;
    line-height: 1.7rem;
  }
  .fluentz-posts-content blockquote {
    padding: 10px 18px;
    font-size: 15px;
    margin: 12px 0;
  }
  .fluentz-posts-content img {
    width: 100% !important;
    margin: 18px auto;
    border-radius: 8px;
  }
  .fluentz-posts-content pre {
    padding: 16px;
    border-radius: 8px;
    font-size: 13px;
  }
  .fluentz-posts-author-box {
    padding: 20px;
    gap: 14px;
    border-radius: 10px;
    margin-top: 32px;
  }
  .fluentz-posts-author-avatar,
  .fluentz-posts-author-avatar-img {
    width: 48px;
    height: 48px;
  }
  .fluentz-posts-author-name {
    font-size: 14px;
  }
  .fluentz-posts-author-bio {
    font-size: 12.5px;
  }
  .fluentz-posts-featured {
    aspect-ratio: 16/8;
  }
  .fluentz-posts-sticky-btn {
    bottom: 16px;
    padding: 11px 28px;
    font-size: 13.5px;
    gap: 8px;
  }
  .fluentz-posts-sticky-btn-icon {
    width: 22px;
    height: 22px;
    font-size: 11px;
  }
  .fluentz-posts-banner {
    margin: 22px 0;
  }
  .fluentz-posts-banner a {
    border-radius: 8px;
  }
}

/* --- Very small mobile --- */
@media (max-width: 360px) {
  .fluentz-posts-wrapper {
    padding: 10px 10px 85px;
  }
  .fluentz-posts-card-body {
    padding: 18px 14px 24px;
  }
  .fluentz-posts-title {
    font-size: 18px;
  }
  .fluentz-posts-content p {
    font-size: 14px;
    line-height: 1.7rem;
  }
}

/* ===== POPUP BANNER ===== */
.fpop-overlay {
  position: fixed;
  inset: 0;
  z-index: 99999;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(0, 0, 0, 0.6);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  opacity: 0;
  visibility: hidden;
  transition:
    opacity 0.3s ease,
    visibility 0.3s ease;
}
.fpop-overlay.fpop-visible {
  opacity: 1;
  visibility: visible;
}

.fpop-modal {
  position: relative;
  max-width: 520px;
  width: 90%;
  border-radius: 16px;
  overflow: hidden;
  box-shadow:
    0 20px 60px rgba(0, 0, 0, 0.4),
    0 4px 16px rgba(123, 43, 190, 0.2);
  transform: scale(0.9) translateY(20px);
  transition: transform 0.35s cubic-bezier(0.22, 1, 0.36, 1);
}
.fpop-overlay.fpop-visible .fpop-modal {
  transform: scale(1) translateY(0);
}

.fpop-close {
  position: absolute;
  top: 10px;
  right: 10px;
  width: 36px;
  height: 36px;
  border: none;
  border-radius: 50%;
  background: rgba(0, 0, 0, 0.55);
  color: #fff;
  font-size: 22px;
  line-height: 1;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 2;
  transition:
    background 0.2s,
    transform 0.2s;
}
.fpop-close:hover {
  background: rgba(0, 0, 0, 0.8);
  transform: scale(1.1);
}

.fpop-link {
  display: block;
  line-height: 0;
}

.fpop-image {
  width: 100%;
  height: auto;
  display: block;
  border-radius: 0 !important;
  margin: 0 !important;
  border: none !important;
  box-shadow: none !important;
}

@media (max-width: 480px) {
  .fpop-modal {
    max-width: 92%;
    border-radius: 12px;
  }
  .fpop-close {
    top: 6px;
    right: 6px;
    width: 32px;
    height: 32px;
    font-size: 20px;
  }
}