/* Content Engine Pro — Frontend CSS */

/* Review Card */
.cep-review-card {
  background: #fff;
  border: 1px solid #e2e8f0;
  border-radius: 10px;
  overflow: hidden;
  box-shadow: 0 2px 8px rgba(0,0,0,.06);
  max-width: 540px;
  margin: 1.5em 0;
}

.cep-review-card__header {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 18px 20px 14px;
  border-bottom: 1px solid #f1f5f9;
}

.cep-review-card__logo img { width: 48px; height: 48px; object-fit: contain; border-radius: 6px; }
.cep-review-card__title { margin: 0!important; font-size: 17px!important; font-weight: 700; line-height: 1.3; }
.cep-review-card__title a { color: inherit; text-decoration: none; }
.cep-review-card__type-badge { display: inline-block; margin-top: 4px; padding: 2px 8px; background: #dbeafe; color: #1e40af; border-radius: 99px; font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: .4px; }

.cep-review-card__rating { display: flex; align-items: center; gap: 10px; padding: 12px 20px; background: #f8fafc; border-bottom: 1px solid #f1f5f9; }
.cep-review-card__rating-num { font-size: 15px; font-weight: 700; color: #1e293b; }
.cep-review-card__price { margin-left: auto; font-size: 13px; color: #16a34a; font-weight: 600; }

.cep-review-card__body { padding: 18px 20px; }
.cep-review-card__pros, .cep-review-card__cons { margin-bottom: 12px; }
.cep-review-card__list-title { display: block; font-size: 12px; font-weight: 700; text-transform: uppercase; letter-spacing: .5px; margin-bottom: 6px; color: #64748b; }
.cep-review-card__pros .cep-review-card__list-title { color: #16a34a; }
.cep-review-card__cons .cep-review-card__list-title { color: #dc2626; }
.cep-review-card__body ul { margin: 0!important; padding: 0 0 0 16px!important; }
.cep-review-card__body ul li { font-size: 13px; color: #334155; margin-bottom: 4px; }
.cep-review-card__verdict { background: #f8fafc; border-radius: 6px; padding: 10px 14px; font-size: 13px; color: #475569; }

.cep-review-card__cta { padding: 14px 20px; border-top: 1px solid #f1f5f9; }

/* Compare Table */
.cep-compare-table { margin: 1.5em 0; }
.cep-compare-table__title { font-size: 20px; font-weight: 700; margin-bottom: 8px!important; }
.cep-compare-table__disclosure { font-size: 12px; color: #64748b; margin-bottom: 14px!important; }
.cep-compare-table__wrap { overflow-x: auto; border-radius: 8px; border: 1px solid #e2e8f0; }
.cep-compare-table__table { width: 100%; border-collapse: collapse; font-size: 14px; }
.cep-compare-table__table th { background: #f8fafc; padding: 12px 16px; text-align: left; font-size: 12px; text-transform: uppercase; letter-spacing: .5px; color: #64748b; border-bottom: 1px solid #e2e8f0; }
.cep-compare-table__table td { padding: 14px 16px; border-bottom: 1px solid #f1f5f9; }
.cep-compare-table__table tr:last-child td { border-bottom: none; }
.cep-compare-table__row--best { background: #eff6ff; }
.cep-compare-table__name { font-weight: 600; }
.cep-compare-table__best-badge { display: inline-block; padding: 1px 6px; background: #2563eb; color: #fff; border-radius: 4px; font-size: 10px; font-weight: 700; text-transform: uppercase; margin-bottom: 4px; }
.cep-compare-table__rating { font-size: 12px; font-weight: 600; color: #1e293b; }

/* Buttons */
.cep-btn { display: inline-block; padding: 10px 20px; border-radius: 6px; font-size: 14px; font-weight: 600; text-decoration: none; cursor: pointer; transition: all .15s; border: none; }
.cep-btn--primary { background: #2563eb; color: #fff; }
.cep-btn--primary:hover { background: #1d4ed8; color: #fff; }
.cep-btn--sm { padding: 6px 14px; font-size: 13px; }

/* Stars */
.cep-stars { display: inline-flex; gap: 1px; }
.cep-stars--sm .cep-star { font-size: 14px; }
.cep-star { color: #e2e8f0; font-size: 18px; line-height: 1; }
.cep-star--filled { color: #f59e0b; }


/* Affiliate link */
.cep-affiliate-link { color: #2563eb; font-weight: 500; text-decoration: underline; text-underline-offset: 2px; }

/* ═══════════════════════════════════════════════════════════════════════════
   SHARED REVIEW COMPONENTS
═══════════════════════════════════════════════════════════════════════════ */

.cep-reviews-page {
  --cep-rv-accent:  #7c3aed;
  --cep-rv-accent2: #db2777;
  --cep-rv-green:   #16a34a;
  --cep-rv-red:     #dc2626;
  --cep-rv-border:  #e2e8f0;
  --cep-rv-bg:      #f8fafc;
  --cep-rv-text:    #1e293b;
  --cep-rv-muted:   #64748b;
  font-family: inherit;
  color: var(--cep-rv-text);
}

/* Larger CTA button */
.cep-btn--lg { padding: 13px 28px; font-size: 15px; border-radius: 8px; }

/* Type badge — hard-coded fallback colours so it renders even outside .cep-reviews-page */
.cep-type-badge {
  display: inline-block;
  padding: 3px 10px;
  background: linear-gradient(135deg, #7c3aed 0%, #db2777 100%);
  background: linear-gradient(135deg, var(--cep-rv-accent, #7c3aed) 0%, var(--cep-rv-accent2, #db2777) 100%);
  color: #fff !important;
  border-radius: 99px;
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .5px;
  margin-bottom: 6px;
  text-decoration: none;
}
.cep-type-badge--sm { padding: 2px 8px; font-size: 10px; }

/* ═══════════════════════════════════════════════════════════════════════════
   REVIEWS ARCHIVE PAGE
═══════════════════════════════════════════════════════════════════════════ */

/* Hero banner */
.cep-reviews-archive__hero {
  background: linear-gradient(135deg, #4c1d95 0%, #7c3aed 45%, #db2777 100%);
  color: #fff;
  padding: 60px 20px;
  text-align: center;
}
.cep-reviews-archive__hero-inner { max-width: 600px; margin: 0 auto; }
.cep-reviews-archive__hero-eyebrow {
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  opacity: .75;
  margin: 0 0 10px;
}
.cep-reviews-archive__hero-title {
  font-size: clamp(28px, 5vw, 42px);
  font-weight: 800;
  margin: 0 0 12px !important;
  line-height: 1.15;
}
.cep-reviews-archive__hero-sub {
  font-size: 16px;
  opacity: .85;
  margin: 0;
}

/* Wrap */
.cep-reviews-archive__wrap { max-width: 1160px; margin: 0 auto; padding: 32px 20px 60px; }

/* Filter tabs */
.cep-reviews-filter {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 32px;
}
.cep-reviews-filter__tab {
  display: inline-block;
  padding: 7px 18px;
  border-radius: 99px;
  background: #f1f5f9;
  color: #475569;
  font-size: 13px;
  font-weight: 600;
  text-decoration: none;
  transition: background .15s, color .15s;
  border: 2px solid transparent;
}
.cep-reviews-filter__tab:hover { background: #e2e8f0; color: #1e293b; text-decoration: none; }
.cep-reviews-filter__tab.is-active {
  background: linear-gradient(135deg, var(--cep-rv-accent) 0%, var(--cep-rv-accent2) 100%);
  color: #fff;
  border-color: transparent;
}

/* Reviews grid */
.cep-reviews-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 24px;
  margin-bottom: 40px;
}
.cep-reviews-grid__card {
  display: flex;
  flex-direction: column;
  background: #fff;
  border: 1px solid var(--cep-rv-border);
  border-radius: 14px;
  overflow: hidden;
  text-decoration: none;
  color: inherit;
  transition: transform .2s, box-shadow .2s;
  box-shadow: 0 2px 8px rgba(0,0,0,.05);
}
.cep-reviews-grid__card:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 28px rgba(124,58,237,.14);
  text-decoration: none;
}

/* Thumbnail */
.cep-reviews-grid__thumb { position: relative; aspect-ratio: 16/9; overflow: hidden; }
.cep-reviews-grid__thumb img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform .3s; }
.cep-reviews-grid__card:hover .cep-reviews-grid__thumb img { transform: scale(1.04); }

/* Thumb badges */
.cep-reviews-grid__badge {
  position: absolute;
  top: 10px;
  left: 10px;
  padding: 3px 10px;
  border-radius: 99px;
  font-size: 10px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: .5px;
}
.cep-reviews-grid__badge--top  { background: #f59e0b; color: #fff; }
.cep-reviews-grid__badge--rec  { background: #22c55e; color: #fff; }

/* Card body */
.cep-reviews-grid__body { padding: 18px; flex: 1; display: flex; flex-direction: column; gap: 6px; }
.cep-reviews-grid__title { font-size: 16px; font-weight: 700; margin: 0 !important; line-height: 1.35; color: #1e293b; }
.cep-reviews-grid__rating { display: flex; align-items: center; gap: 6px; }
.cep-reviews-grid__score { font-size: 13px; font-weight: 700; color: #1e293b; }
.cep-reviews-grid__price { margin-left: auto; font-size: 12px; color: var(--cep-rv-green); font-weight: 600; }
.cep-reviews-grid__excerpt { font-size: 13px; color: #475569; margin: 0; flex: 1; line-height: 1.55; }
.cep-reviews-grid__cta {
  display: inline-block;
  margin-top: 8px;
  font-size: 13px;
  font-weight: 700;
  color: var(--cep-rv-accent);
  transition: gap .15s;
}
.cep-reviews-grid__card:hover .cep-reviews-grid__cta { text-decoration: underline; }

/* Empty state */
.cep-reviews-empty { text-align: center; padding: 60px 20px; color: #64748b; font-size: 16px; }

/* Pagination */
.cep-reviews-pagination { display: flex; flex-wrap: wrap; gap: 6px; justify-content: center; }
.cep-reviews-pagination .page-numbers {
  display: inline-flex; align-items: center; justify-content: center;
  min-width: 36px; height: 36px; padding: 0 10px;
  border-radius: 8px; border: 1px solid var(--cep-rv-border);
  font-size: 14px; font-weight: 600; text-decoration: none; color: #475569;
  transition: background .15s, color .15s;
}
.cep-reviews-pagination .page-numbers:hover { background: #f1f5f9; text-decoration: none; }
.cep-reviews-pagination .page-numbers.current {
  background: linear-gradient(135deg, var(--cep-rv-accent) 0%, var(--cep-rv-accent2) 100%);
  color: #fff; border-color: transparent;
}

/* ═══════════════════════════════════════════════════════════════════════════
   SINGLE REVIEW PAGE
═══════════════════════════════════════════════════════════════════════════ */

.cep-single-review { max-width: 800px; margin: 40px auto; padding: 0 24px 60px; }

/* Breadcrumb */
.cep-single-review__breadcrumb {
  display: flex; flex-wrap: wrap; align-items: center; gap: 6px;
  font-size: 13px; color: #64748b; margin-bottom: 28px;
}
.cep-single-review__breadcrumb a { color: var(--cep-rv-accent); text-decoration: none; }
.cep-single-review__breadcrumb a:hover { text-decoration: underline; }
.cep-single-review__breadcrumb span[aria-hidden] { color: #cbd5e1; }

/* Hero block */
.cep-single-review__hero {
  display: flex; gap: 24px; align-items: flex-start;
  background: #fff;
  border: 1px solid #e2e8f0;
  border: 1px solid var(--cep-rv-border, #e2e8f0);
  border-radius: 16px; padding: 28px; margin-bottom: 28px;
  box-shadow: 0 2px 4px rgba(0,0,0,.05), 0 8px 24px rgba(0,0,0,.08);
}
.cep-single-review__logo { flex-shrink: 0; }
.cep-single-review__logo img { width: 80px; height: 80px; object-fit: contain; border-radius: 12px; border: 1px solid var(--cep-rv-border); }
.cep-single-review__hero-info { flex: 1; min-width: 0; }
.cep-single-review__title { font-size: clamp(20px, 4vw, 28px); font-weight: 800; margin: 0 0 10px !important; line-height: 1.2; }

.cep-single-review__rating { display: flex; align-items: center; gap: 8px; margin-bottom: 16px; flex-wrap: wrap; }
.cep-single-review__score { font-size: 17px; font-weight: 800; color: #1e293b; }
.cep-single-review__price {
  padding: 3px 10px; background: #dcfce7; color: #15803d;
  border-radius: 99px; font-size: 12px; font-weight: 700;
}

.cep-single-review__disclosure { font-size: 11px; color: #94a3b8; margin: 8px 0 0; }

/* Score bar */
.cep-score-bar {
  display: flex; align-items: center; gap: 12px;
  margin-bottom: 28px;
}
.cep-score-bar__label { font-size: 13px; font-weight: 700; color: #475569; white-space: nowrap; }
.cep-score-bar__track {
  flex: 1; height: 10px; background: #e2e8f0; border-radius: 99px; overflow: hidden;
}
.cep-score-bar__fill {
  height: 100%;
  background: linear-gradient(90deg, #7c3aed 0%, #db2777 100%);
  background: linear-gradient(90deg, var(--cep-rv-accent, #7c3aed) 0%, var(--cep-rv-accent2, #db2777) 100%);
  border-radius: 99px;
  transition: width .6s ease;
}
.cep-score-bar__num { font-size: 14px; font-weight: 800; color: #1e293b; white-space: nowrap; }

/* Pros / Cons */
.cep-single-review__pros-cons {
  display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin-bottom: 32px;
}
@media (max-width: 580px) { .cep-single-review__pros-cons { grid-template-columns: 1fr; } }

.cep-pros-cons-box {
  border-radius: 12px; padding: 20px; border: 1px solid transparent;
}
.cep-pros-cons-box--pros { background: #f0fdf4; border-color: #bbf7d0; }
.cep-pros-cons-box--cons { background: #fff1f2; border-color: #fecdd3; }

.cep-pros-cons-box__heading {
  display: flex; align-items: center; gap: 7px;
  font-size: 14px; font-weight: 800; text-transform: uppercase; letter-spacing: .5px;
  margin: 0 0 12px !important;
}
.cep-pros-cons-box--pros .cep-pros-cons-box__heading { color: var(--cep-rv-green); }
.cep-pros-cons-box--cons .cep-pros-cons-box__heading { color: var(--cep-rv-red); }
.cep-pros-cons-box__icon { font-size: 16px; }

.cep-pros-cons-box ul { margin: 0 !important; padding: 0 0 0 18px !important; }
.cep-pros-cons-box li { font-size: 14px; color: #334155; margin-bottom: 6px; line-height: 1.5; }

/* Review content */
.cep-single-review__content { margin-bottom: 32px; line-height: 1.75; font-size: 1.05rem; }

/* Headings always clear floated images so they never appear beside an image column */
.cep-single-review__content h2,
.cep-single-review__content h3,
.cep-single-review__content h4 {
  clear: both;
  margin-top: 2em;
}

/* ── Content images — constrain, polish, prevent giant blanks ── */
.cep-single-review__content figure,
.cep-single-review__content .wp-block-image {
  margin: 32px auto !important;
  max-width: 100%;
  clear: both;
  display: block;
}

/* All <img> inside review content */
.cep-single-review__content figure img,
.cep-single-review__content .wp-block-image img,
.cep-single-review__content img {
  max-width: 100% !important;
  width: 100%;
  height: auto !important;
  max-height: 420px;
  object-fit: cover;
  object-position: center top;
  border-radius: 14px;
  display: block;
  box-shadow: 0 4px 20px rgba(0,0,0,.09);
}

/* Centre-aligned figures */
.cep-single-review__content .aligncenter,
.cep-single-review__content .wp-block-image.aligncenter {
  margin-left: auto !important;
  margin-right: auto !important;
  text-align: center;
}

/* Left / right floated editorial images */
.cep-single-review__content .alignleft {
  float: left;
  margin: 8px 28px 16px 0 !important;
  max-width: 45%;
}
.cep-single-review__content .alignright {
  float: right;
  margin: 8px 0 16px 28px !important;
  max-width: 45%;
}
.cep-single-review__content .alignleft img,
.cep-single-review__content .alignright img {
  width: 100%;
  max-height: 320px;
}
/* Clearfix after floats */
.cep-single-review__content::after {
  content: '';
  display: table;
  clear: both;
}

/* Captions */
.cep-single-review__content figcaption {
  text-align: center;
  font-size: 12.5px;
  color: #94a3b8;
  margin-top: 8px;
  font-style: italic;
  line-height: 1.4;
}

/* Broken / loading images — prevent empty giant blocks */
.cep-single-review__content img:not([src]),
.cep-single-review__content img[src=""] {
  display: none;
}

@media (max-width: 640px) {
  .cep-single-review__content .alignleft,
  .cep-single-review__content .alignright {
    float: none;
    max-width: 100%;
    margin: 20px auto !important;
  }
  .cep-single-review__banner { aspect-ratio: 16/9; }
}

/* Verdict box */
.cep-verdict-box {
  background: linear-gradient(135deg, #4c1d95 0%, #7c3aed 40%, #db2777 100%);
  color: #fff; border-radius: 16px; padding: 28px; margin-bottom: 32px;
}
.cep-verdict-box__header {
  display: flex; align-items: center; gap: 20px; margin-bottom: 14px;
}
.cep-verdict-box__score-wrap { display: flex; align-items: baseline; gap: 2px; }
.cep-verdict-box__score { font-size: 52px; font-weight: 900; line-height: 1; }
.cep-verdict-box__max { font-size: 20px; font-weight: 600; opacity: .7; }
.cep-verdict-box .cep-star { color: rgba(255,255,255,.35); font-size: 20px; }
.cep-verdict-box .cep-star--filled { color: #fbbf24; }
.cep-verdict-box__label { display: block; font-size: 13px; text-transform: uppercase; letter-spacing: 1px; opacity: .8; margin-top: 4px; }
.cep-verdict-box__text { font-size: 16px; line-height: 1.65; margin: 0; opacity: .95; }

/* Bottom CTA */
.cep-single-review__bottom-cta {
  display: flex; align-items: center; gap: 16px; flex-wrap: wrap;
  padding: 24px; background: var(--cep-rv-bg); border-radius: 12px;
  border: 1px solid var(--cep-rv-border); margin-bottom: 24px;
}
.cep-single-review__bottom-price { font-size: 13px; color: var(--cep-rv-green); font-weight: 600; }

/* Meta footer */
.cep-single-review__footer { font-size: 12px; color: #94a3b8; margin-top: 24px; padding-top: 16px; border-top: 1px solid var(--cep-rv-border); }

/* ═══════════════════════════════════════════════════════════════════════════
   RELATED REVIEWS
═══════════════════════════════════════════════════════════════════════════ */

.cep-related-reviews { background: #f8fafc; border-top: 1px solid var(--cep-rv-border); margin-top: 48px; padding: 48px 20px; }
.cep-related-reviews__inner { max-width: 800px; margin: 0 auto; }
.cep-related-reviews__title { font-size: 22px; font-weight: 800; margin: 0 0 24px !important; }
.cep-related-reviews__grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 16px; }
.cep-related-reviews__card {
  background: #fff; border: 1px solid var(--cep-rv-border);
  border-radius: 12px; overflow: hidden; text-decoration: none; color: inherit;
  transition: transform .2s, box-shadow .2s;
}
.cep-related-reviews__card:hover { transform: translateY(-3px); box-shadow: 0 8px 20px rgba(0,0,0,.08); text-decoration: none; }
.cep-related-reviews__thumb { aspect-ratio: 16/9; overflow: hidden; }
.cep-related-reviews__thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.cep-related-reviews__body { padding: 14px; }
.cep-related-reviews__body h3 { font-size: 14px; font-weight: 700; margin: 4px 0 8px !important; line-height: 1.3; }
.cep-related-reviews__score { font-size: 12px; font-weight: 700; color: #1e293b; margin-left: 4px; }

/* ═══════════════════════════════════════════════════════════════════════════
   HOMEPAGE REVIEWS SECTION
═══════════════════════════════════════════════════════════════════════════ */

.cep-homepage-reviews {
  margin: 48px 0;
  padding: 40px 0;
  border-top: 1px solid #e2e8f0;
}
.cep-homepage-reviews__header {
  display: flex; align-items: center; justify-content: space-between;
  gap: 12px; margin-bottom: 24px; flex-wrap: wrap;
}
.cep-homepage-reviews__title {
  font-size: clamp(20px, 3.5vw, 26px);
  font-weight: 800;
  margin: 0 !important;
  background: linear-gradient(135deg, var(--cep-rv-accent) 0%, var(--cep-rv-accent2) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}
.cep-homepage-reviews__see-all {
  font-size: 14px; font-weight: 700; color: var(--cep-rv-accent);
  text-decoration: none; white-space: nowrap;
  border: 2px solid var(--cep-rv-accent); border-radius: 99px;
  padding: 6px 16px; transition: background .15s, color .15s;
}
.cep-homepage-reviews__see-all:hover {
  background: var(--cep-rv-accent); color: #fff; text-decoration: none;
}
.cep-homepage-reviews__grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 20px;
}

/* Homepage review card */
.cep-hp-review-card {
  display: flex; flex-direction: column;
  background: #fff; border: 1px solid #e2e8f0;
  border-radius: 14px; overflow: hidden;
  text-decoration: none; color: inherit;
  transition: transform .2s, box-shadow .2s;
  box-shadow: 0 2px 8px rgba(0,0,0,.05);
}
.cep-hp-review-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 10px 24px rgba(124,58,237,.13);
  text-decoration: none;
}
.cep-hp-review-card__thumb { aspect-ratio: 16/9; overflow: hidden; }
.cep-hp-review-card__thumb img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform .3s; }
.cep-hp-review-card:hover .cep-hp-review-card__thumb img { transform: scale(1.04); }
.cep-hp-review-card__body { padding: 16px; display: flex; flex-direction: column; gap: 6px; }
.cep-hp-review-card__title { font-size: 15px; font-weight: 700; margin: 0 !important; color: #1e293b; line-height: 1.35; }
.cep-hp-review-card__rating { display: flex; align-items: center; gap: 5px; }
.cep-hp-review-card__score { font-size: 12px; font-weight: 700; color: #1e293b; }
.cep-hp-review-card__price { font-size: 12px; color: #16a34a; font-weight: 600; }

/* ═══════════════════════════════════════════════════════════════════════════
   RESPONSIVE ADJUSTMENTS
═══════════════════════════════════════════════════════════════════════════ */

@media (max-width: 640px) {
  .cep-single-review__hero { flex-direction: column; }
  .cep-single-review__logo img { width: 64px; height: 64px; }
  .cep-score-bar { flex-wrap: wrap; }
  .cep-verdict-box__score { font-size: 40px; }
  .cep-single-review__bottom-cta { flex-direction: column; align-items: flex-start; }
  .cep-reviews-grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 420px) {
  .cep-reviews-grid { grid-template-columns: 1fr; }
  .cep-homepage-reviews__grid { grid-template-columns: 1fr; }
}
