/* ============================================================
   AI Directory Pro v4.0 — Complete Stylesheet
   ============================================================ */

@import url('https://fonts.googleapis.com/css2?family=Syne:wght@700;800&family=DM+Sans:wght@400;500;600&family=Inter:wght@400;500;600&family=Poppins:wght@400;500;600&display=swap');

:root {
  --aidp-primary:   #4f63d8;
  --aidp-dark:      #12122a;
  --aidp-green:     #22c55e;
  --aidp-amber:     #f59e0b;
  --aidp-purple:    #7c3aed;
  --aidp-card-bg:   #ffffff;
  --aidp-border:    #ededf5;
  --aidp-radius:    20px;
  --aidp-shadow:    0 8px 40px rgba(0,0,0,0.10);
  --aidp-font:      'DM Sans', sans-serif;
  --aidp-about-bg:       #ffffff;
  --aidp-about-text:     #374151;
  --aidp-about-title:    #12122a;
}

/* ── RESET ── */
.aidp-card-wrap *, .aidp-listing-wrap *, .aidp-cat-section *,
.aidp-grid-section *, .aidp-trending-wrap *, .aidp-sidebar *,
.aidp-about-wrap * { box-sizing: border-box; }

/* ── PAGE ── */
.aidp-single-wrap {
  padding: 40px 20px;
  min-height: 80vh;
  background: linear-gradient(135deg, #fef9f0 0%, #f0f4ff 50%, #fff5fb 100%);
}

/* Hide theme duplicate content areas */
.aidp-single-wrap .entry-content,
.aidp-single-wrap .post-content,
.aidp-single-wrap .site-main .entry-content { display: none !important; }

.aidp-section-title {
  font-family: 'Syne', sans-serif;
  font-size: 22px; font-weight: 800;
  color: var(--aidp-dark); margin: 0 0 20px;
}
.aidp-no-results { color: #999; font-size: 14px; padding: 20px; text-align: center; }

/* ══════════════════════════════════════════════════
   DETAIL CARD
══════════════════════════════════════════════════ */
.aidp-card-wrap {
  max-width: 980px; margin: 0 auto 24px;
  border-radius: var(--aidp-radius);
  overflow: hidden;
  box-shadow: var(--aidp-shadow);
  background: var(--aidp-card-bg);
}
.aidp-header {
  background: var(--aidp-card-bg);
  padding: 24px 32px;
  display: flex; align-items: center; gap: 18px;
  border: 1.5px solid var(--aidp-border);
  border-bottom: none; flex-wrap: wrap;
}
.aidp-logo { flex-shrink: 0; }
.aidp-logo-img {
  width: 64px; height: 64px; border-radius: 16px;
  object-fit: cover; display: block;
  box-shadow: 0 4px 16px rgba(0,0,0,0.12);
}
.aidp-logo-default {
  width: 64px; height: 64px; border-radius: 16px;
  background: linear-gradient(135deg, var(--aidp-primary), #0f9eff);
  display: flex; align-items: center; justify-content: center; font-size: 28px;
}
.aidp-meta { flex: 1; min-width: 180px; }
.aidp-name-row { display: flex; align-items: center; gap: 8px; margin-bottom: 6px; flex-wrap: wrap; }
.aidp-name {
  font-family: 'Syne', sans-serif; font-size: 26px; font-weight: 800;
  color: var(--aidp-dark); letter-spacing: -0.5px;
}
.aidp-vbadge {
  background: var(--aidp-amber); color: #fff;
  border-radius: 50%; width: 22px; height: 22px;
  display: flex; align-items: center; justify-content: center;
  font-size: 11px; font-weight: 700; flex-shrink: 0;
}
.aidp-tbadge {
  background: #fff3cd; color: #856404;
  border: 1px solid #ffc107; border-radius: 20px;
  padding: 2px 10px; font-size: 11px; font-weight: 600;
}
.aidp-rank-row { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.aidp-rank {
  background: #f1f1f8; color: #444;
  font-size: 12px; font-weight: 600;
  padding: 3px 10px; border-radius: 8px;
  border: 1.5px solid #e2e2ec;
}
.aidp-in { color: #999; font-size: 13px; }
.aidp-cat-link { color: var(--aidp-primary); font-size: 13px; font-weight: 500; text-decoration: none; }
.aidp-cat-link:hover { text-decoration: underline; }
.aidp-stars { display: flex; gap: 2px; }
.aidp-star { font-size: 15px; }
.aidp-star.full  { color: var(--aidp-amber); }
.aidp-star.half  { color: var(--aidp-amber); opacity: 0.6; }
.aidp-star.empty { color: #ddd; }
.aidp-hactions { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; flex-shrink: 0; }
.aidp-icon-btn {
  width: 40px; height: 40px; border-radius: 10px;
  border: 1.5px solid #374151;
  background: #1f2937;
  cursor: pointer; transition: all .2s;
  display: flex; align-items: center; justify-content: center;
  padding: 0; color: #f3f4f6;
  box-shadow: 0 2px 4px rgba(0,0,0,0.2);
}
.aidp-icon-btn svg { stroke: #f3f4f6 !important; fill: none; }
.aidp-icon-btn:hover {
  border-color: #3b82f6; background: #2563eb;
  transform: scale(1.05);
  box-shadow: 0 4px 12px rgba(37,99,235,0.4);
}
.aidp-icon-btn:hover svg { stroke: #fff !important; }
/* Bookmark active/saved */
.aidp-bookmark-btn.saved {
  background: #1d4ed8; border-color: #3b82f6;
}
.aidp-bookmark-btn.saved svg { stroke: #fff !important; fill: #fff !important; }
.aidp-visit-btn {
  background: var(--aidp-dark); color: #fff !important;
  border: none; border-radius: 12px; padding: 11px 22px;
  font-family: var(--aidp-font); font-size: 13px; font-weight: 700;
  cursor: pointer; text-decoration: none !important;
  display: inline-flex; align-items: center; gap: 6px;
  transition: all .2s; white-space: nowrap;
}
.aidp-visit-btn:hover { background: var(--aidp-primary); transform: translateY(-2px); box-shadow: 0 6px 20px rgba(79,99,216,.3); }

/* Rainbow bar */
.aidp-rainbow {
  height: 4px;
  background: linear-gradient(90deg, #ff6b6b, #ffd93d, #6bcb77, #4d96ff, #c77dff, #ff6b6b);
  background-size: 200% 100%;
  animation: aidp-rb 4s linear infinite;
}
@keyframes aidp-rb { 0%{background-position:0%} 100%{background-position:200%} }

/* Body */
.aidp-body {
  background: var(--aidp-card-bg);
  border: 1.5px solid var(--aidp-border);
  border-top: none; padding: 28px 32px;
  display: grid; grid-template-columns: 1fr 1fr; gap: 28px;
}
.aidp-left { display: flex; flex-direction: column; gap: 14px; }
.aidp-video-wrap { width: 100%; aspect-ratio: 16/9; border-radius: 14px; overflow: hidden; background: #0a0a1a; }
.aidp-video-wrap iframe { width: 100%; height: 100%; display: block; }
.aidp-video-ph {
  width: 100%; aspect-ratio: 16/9; border-radius: 14px; overflow: hidden;
  background: #0a0a1a; border: 2px solid #1a1a3a;
  display: flex; align-items: center; justify-content: center; position: relative;
}
.aidp-vglow {
  position: absolute; width: 200px; height: 200px;
  background: radial-gradient(circle, rgba(77,150,255,.35) 0%, transparent 70%);
  border-radius: 50%; top: 50%; left: 50%;
  transform: translate(-50%,-50%);
  animation: aidp-pulse 2.5s ease-in-out infinite;
}
@keyframes aidp-pulse {
  0%,100%{ transform:translate(-50%,-50%) scale(1); opacity:.6; }
  50%    { transform:translate(-50%,-50%) scale(1.3); opacity:1; }
}
.aidp-vtitle {
  font-family: 'Syne', sans-serif; font-size: 24px; font-weight: 800;
  color: #4d96ff; text-align: center; line-height: 1.3;
  padding: 20px; position: relative; z-index: 1;
}
.aidp-vplay {
  position: absolute; bottom: 14px; right: 14px;
  width: 34px; height: 34px;
  background: rgba(255,255,255,.15); border: 1.5px solid rgba(255,255,255,.3);
  border-radius: 50%; display: flex; align-items: center; justify-content: center;
  font-size: 12px; color: #fff;
}
.aidp-tags { display: flex; flex-wrap: wrap; gap: 8px; }
.aidp-tag {
  background: #f3f5ff; color: var(--aidp-primary);
  font-size: 12px; font-weight: 500;
  padding: 5px 12px; border-radius: 20px;
  border: 1px solid #dde2ff; cursor: pointer; transition: all .2s;
  display: inline-block;
}
.aidp-tag:hover { background: var(--aidp-primary); color: #fff; }
.aidp-right { display: flex; flex-direction: column; gap: 16px; }
.aidp-desc {
  font-size: 14px; line-height: 1.8; color: #555;
  background: #fafafe; border-radius: 12px;
  padding: 18px; border-left: 3px solid var(--aidp-primary);
  font-style: italic; margin: 0;
}
.aidp-learn-row { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.aidp-learn-lbl { font-weight: 600; color: #555; font-size: 13px; }
.aidp-learn-link {
  background: #f3f5ff; border: 1px solid #dde2ff;
  border-radius: 8px; padding: 5px 12px;
  font-size: 12px; font-weight: 600; color: var(--aidp-primary);
  text-decoration: none; transition: all .2s; display: inline-block;
}
.aidp-learn-link:hover { background: var(--aidp-primary); color: #fff; text-decoration: none; }
.aidp-badges { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.aidp-badge-totw {
  background: linear-gradient(135deg, var(--aidp-purple), #a855f7);
  color: #fff; border-radius: 12px; padding: 8px 14px;
  display: flex; align-items: center; gap: 8px;
}
.aidp-totw-title { font-weight: 700; text-transform: uppercase; letter-spacing: .5px; font-size: 10px; }
.aidp-totw-date  { font-size: 10px; opacity: .85; margin-top: 2px; }
.aidp-badge-ver {
  display: flex; align-items: center; gap: 5px;
  border: 1.5px solid var(--aidp-green); border-radius: 20px;
  padding: 5px 12px; font-size: 12px; font-weight: 600; color: #16a34a;
}
.aidp-badge-ups { font-size: 14px; font-weight: 700; color: var(--aidp-green); margin-left: auto; }
.aidp-badge-price { border-radius: 20px; padding: 5px 14px; font-size: 12px; font-weight: 700; white-space: nowrap; }
.aidp-badge-price.free       { background: #dcfce7; color: #166534; border: 1px solid #bbf7d0; }
.aidp-badge-price.freemium   { background: #fef9c3; color: #854d0e; border: 1px solid #fde68a; }
.aidp-badge-price.paid       { background: #fee2e2; color: #991b1b; border: 1px solid #fecaca; }
.aidp-badge-price.free-trial { background: #e0f2fe; color: #075985; border: 1px solid #bae6fd; }
.aidp-useful { display: flex; flex-direction: column; gap: 10px; }
.aidp-useful-title { font-size: 10px; font-weight: 700; text-transform: uppercase; letter-spacing: 1.5px; color: #aaa; }
.aidp-links-grid { display: flex; flex-wrap: wrap; gap: 8px; }
.aidp-ulink {
  display: inline-flex; align-items: center; gap: 6px;
  font-size: 12px; font-weight: 600; color: #333;
  text-decoration: none; padding: 6px 12px;
  border-radius: 10px; border: 1.5px solid #eee;
  background: #fafafa; transition: all .2s; white-space: nowrap;
}
.aidp-ulink.primary { color: var(--aidp-primary); border-color: #dde2ff; background: #f3f5ff; }
.aidp-ulink.aidp-affiliate { color: #b45309; border-color: #fde68a; background: #fffbeb; }
.aidp-ulink.aidp-affiliate:hover { background: #f59e0b; color: #fff; border-color: #f59e0b; text-decoration: none; }
.aidp-ulink:hover { border-color: var(--aidp-primary); background: #f3f5ff; color: var(--aidp-primary); transform: translateY(-1px); text-decoration: none; }
.aidp-upvote-bar {
  background: var(--aidp-card-bg);
  border: 1.5px solid var(--aidp-border); border-top: 1px solid #f0f0f8;
  padding: 14px 32px; display: flex; justify-content: flex-end;
}
.aidp-upvote-btn {
  background: var(--aidp-card-bg); border: 2px solid #e2e2ec;
  border-radius: 14px; padding: 10px 20px;
  font-family: 'Syne', sans-serif; font-size: 16px; font-weight: 700;
  color: var(--aidp-green); cursor: pointer; transition: all .2s;
  display: flex; align-items: center; gap: 6px;
}
.aidp-upvote-btn:hover { background: var(--aidp-green); color: #fff; border-color: var(--aidp-green); transform: translateY(-2px); }
.aidp-upvote-btn.voted { background: var(--aidp-green); color: #fff; border-color: var(--aidp-green); cursor: default; transform: none; }

/* ══════════════════════════════════════════════════
   ABOUT SECTION — Exactly like WordPress post content
══════════════════════════════════════════════════ */
.aidp-about-wrap {
  max-width: 980px;
  margin: 0 auto;
}
.aidp-about-section {
  background: var(--aidp-about-bg, #ffffff);
  border-radius: 16px;
  padding: 40px 48px;
  margin-bottom: 20px;
  border: 1.5px solid #ededf5;
  box-shadow: 0 2px 12px rgba(0,0,0,0.05);
}

/* ── WordPress-style content inside about section ── */
.aidp-about-content {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
  font-size: 16px;
  line-height: 1.85;
  color: var(--aidp-about-text, #3c3c3c);
}

/* Headings — exact WordPress style */
.aidp-about-content h1,
.aidp-about-content h2,
.aidp-about-content h3,
.aidp-about-content h4,
.aidp-about-content h5,
.aidp-about-content h6 {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
  font-weight: 700;
  line-height: 1.3;
  color: var(--aidp-about-title, #1a1a1a);
  margin: 28px 0 16px;
}
.aidp-about-content h1 { font-size: 32px; }
.aidp-about-content h2 { font-size: 26px; }
.aidp-about-content h3 { font-size: 22px; }
.aidp-about-content h4 { font-size: 18px; }

/* Paragraphs — WordPress wpautop style */
.aidp-about-content p {
  font-size: 16px;
  line-height: 1.85;
  color: var(--aidp-about-text, #3c3c3c);
  margin: 0 0 22px;
  font-weight: 400;
  word-break: break-word;
}
.aidp-about-content p:last-child { margin-bottom: 0; }

/* Lists */
.aidp-about-content ul,
.aidp-about-content ol {
  margin: 0 0 22px;
  padding-left: 28px;
}
.aidp-about-content li {
  font-size: 16px;
  line-height: 1.8;
  color: var(--aidp-about-text, #3c3c3c);
  margin-bottom: 6px;
}

/* Bold, italic */
.aidp-about-content strong { font-weight: 700; color: #1a1a1a; }
.aidp-about-content em { font-style: italic; }

/* Links */
.aidp-about-content a {
  color: var(--aidp-primary, #4f63d8);
  text-decoration: underline;
}
.aidp-about-content a:hover { text-decoration: none; }

/* Blockquote */
.aidp-about-content blockquote {
  border-left: 4px solid var(--aidp-primary, #4f63d8);
  margin: 0 0 22px;
  padding: 12px 20px;
  background: #f8f9ff;
  border-radius: 0 8px 8px 0;
  font-style: italic;
  color: #555;
}

/* Images */
.aidp-about-content img {
  max-width: 100%;
  height: auto;
  border-radius: 8px;
  margin: 8px 0;
}

/* Also style aidp-about-p (used by old content) */
.aidp-about-p {
  font-size: 16px !important;
  line-height: 1.85 !important;
  color: var(--aidp-about-text, #3c3c3c) !important;
  margin: 0 0 22px !important;
  font-weight: 400 !important;
  word-break: break-word;
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif !important;
}
.aidp-about-p:last-child { margin-bottom: 0 !important; }

/* ══════════════════════════════════════════════════
   LISTING
══════════════════════════════════════════════════ */
.aidp-listing-wrap { max-width: 980px; margin: 0 auto; }
.aidp-toolbar {
  display: flex; align-items: center; gap: 12px; margin-bottom: 24px; flex-wrap: wrap;
  background: #fff; padding: 16px 20px; border-radius: 14px;
  border: 1.5px solid #ededf5; box-shadow: 0 2px 12px rgba(0,0,0,0.05);
}
.aidp-search-wrap {
  display: flex; align-items: center; gap: 10px;
  background: #f6f8ff; border: 1.5px solid #ededf5;
  border-radius: 10px; padding: 8px 14px; flex: 1; min-width: 200px;
}
.aidp-search-input { border: none; background: transparent; outline: none; font-family: var(--aidp-font); font-size: 14px; width: 100%; color: var(--aidp-dark); }
.aidp-search-input::placeholder { color: #aaa; }
.aidp-filters { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.aidp-filter-sel { border: 1.5px solid #ededf5; border-radius: 10px; padding: 8px 14px; font-family: var(--aidp-font); font-size: 13px; background: #fff; cursor: pointer; color: var(--aidp-dark); outline: none; }
.aidp-filter-btn { border: 1.5px solid #ededf5; border-radius: 20px; padding: 6px 16px; font-family: var(--aidp-font); font-size: 13px; font-weight: 600; background: #fff; cursor: pointer; color: #666; transition: all .2s; }
.aidp-filter-btn:hover, .aidp-filter-btn.active { background: var(--aidp-primary); color: #fff; border-color: var(--aidp-primary); }
.aidp-list-card {
  background: #fff; border: 1.5px solid #ededf5; border-radius: 16px;
  padding: 18px 20px; display: flex; align-items: flex-start; gap: 16px;
  margin-bottom: 12px; transition: all .2s; position: relative; overflow: hidden;
}
.aidp-list-card:hover { border-color: var(--aidp-primary); box-shadow: 0 4px 20px rgba(79,99,216,.1); transform: translateY(-1px); }
.aidp-list-card.aidp-featured { border-color: var(--aidp-amber); background: linear-gradient(135deg,#fffdf5,#fff); }
.aidp-feat-ribbon {
  position: absolute; top: 12px; right: -18px;
  background: var(--aidp-amber); color: #fff;
  font-size: 10px; font-weight: 700;
  padding: 3px 28px; transform: rotate(35deg); letter-spacing: 1px;
}
.aidp-lc-logo { flex-shrink: 0; }
.aidp-lc-logo img { width: 52px; height: 52px; border-radius: 12px; object-fit: cover; display: block; box-shadow: 0 2px 8px rgba(0,0,0,.1); }
.aidp-lc-logo-ph { width: 52px; height: 52px; border-radius: 12px; background: linear-gradient(135deg,var(--aidp-primary),#0f9eff); display: flex; align-items: center; justify-content: center; font-size: 22px; }
.aidp-lc-body { flex: 1; min-width: 0; }
.aidp-lc-trow { display: flex; align-items: center; gap: 8px; margin-bottom: 6px; flex-wrap: wrap; }
.aidp-lc-title { font-family: 'Syne',sans-serif; font-size: 16px; font-weight: 700; color: var(--aidp-dark); text-decoration: none; }
.aidp-lc-title:hover { color: var(--aidp-primary); text-decoration: none; }
.aidp-vdot { background: var(--aidp-amber); color: #fff; border-radius: 50%; width: 18px; height: 18px; display: flex; align-items: center; justify-content: center; font-size: 9px; font-weight: 700; }
.aidp-trend-b { font-size: 14px; }
.aidp-new-b { background: var(--aidp-green); color: #fff; border-radius: 6px; padding: 1px 7px; font-size: 10px; font-weight: 700; }
.aidp-lc-desc { font-size: 13px; color: #666; line-height: 1.5; margin: 0 0 8px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.aidp-lc-meta { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.aidp-ltag { background: #f3f5ff; color: var(--aidp-primary); font-size: 11px; font-weight: 500; padding: 3px 10px; border-radius: 20px; border: 1px solid #dde2ff; }
.aidp-lc-actions { display: flex; flex-direction: column; align-items: flex-end; gap: 8px; flex-shrink: 0; }
.aidp-visit-sm { background: var(--aidp-dark); color: #fff !important; border-radius: 8px; padding: 7px 14px; font-size: 12px; font-weight: 600; text-decoration: none !important; white-space: nowrap; transition: all .2s; display: inline-block; }
.aidp-visit-sm:hover { background: var(--aidp-primary); }

/* ══════════════════════════════════════════════════
   CATEGORY GRID
══════════════════════════════════════════════════ */
.aidp-cat-section { max-width: 1200px; margin: 0 auto; }
.aidp-cat-grid { display: grid; gap: 20px; }
.aidp-cols-1 { grid-template-columns: 1fr; }
.aidp-cols-2 { grid-template-columns: repeat(2,1fr); }
.aidp-cols-3 { grid-template-columns: repeat(3,1fr); }
.aidp-cols-4 { grid-template-columns: repeat(4,1fr); }
.aidp-cat-card { background: #fff; border-radius: 16px; padding: 20px; border: 1.5px solid #ededf5; box-shadow: 0 2px 12px rgba(0,0,0,.05); transition: all .2s; }
.aidp-cat-card:hover { border-color: var(--aidp-primary); transform: translateY(-2px); }
.aidp-cat-header { display: flex; align-items: center; gap: 12px; margin-bottom: 16px; }
.aidp-cat-icon { width: 42px; height: 42px; background: var(--aidp-dark); border-radius: 12px; display: flex; align-items: center; justify-content: center; font-size: 20px; flex-shrink: 0; }
.aidp-cat-name { font-family: 'Syne',sans-serif; font-size: 15px; font-weight: 700; color: var(--aidp-dark); text-decoration: none; display: block; }
.aidp-cat-name:hover { color: var(--aidp-primary); text-decoration: none; }
.aidp-cat-count { font-size: 12px; color: #aaa; }
.aidp-subcat-list { list-style: none; margin: 0; padding: 0; }
.aidp-subcat-list li { display: flex; align-items: center; justify-content: space-between; padding: 7px 0; border-bottom: 1px solid #f5f5f8; }
.aidp-subcat-list li:last-child { border-bottom: none; }
.aidp-subcat-link { display: flex; align-items: center; gap: 6px; font-size: 13px; color: #555; text-decoration: none; }
.aidp-subcat-link:hover { color: var(--aidp-primary); text-decoration: none; }
.aidp-subcat-icon { color: #ccc; }
.aidp-subcat-count { font-size: 12px; color: #aaa; font-weight: 600; }
.aidp-cat-desc { font-size: 13px; color: #777; line-height: 1.6; margin: 0; }

/* ══════════════════════════════════════════════════
   GRID BOXES
══════════════════════════════════════════════════ */
.aidp-grid-section { max-width: 1200px; margin: 0 auto; }
.aidp-grid-wrap { display: grid; gap: 16px; }
.aidp-grid-box { background: #fff; border-radius: 16px; border: 1.5px solid #ededf5; overflow: hidden; box-shadow: 0 2px 12px rgba(0,0,0,.05); }
.aidp-grid-box-hdr { display: flex; align-items: center; gap: 10px; padding: 14px 16px; border-bottom: 1px solid #ededf5; background: #fafafe; }
.aidp-grid-cat-name { font-family: 'Syne',sans-serif; font-size: 14px; font-weight: 700; color: var(--aidp-dark); text-decoration: none; }
.aidp-grid-cat-name:hover { color: var(--aidp-primary); text-decoration: none; }
.aidp-grid-list { list-style: none; margin: 0; padding: 8px 0; }
.aidp-grid-item { display: flex; align-items: center; gap: 8px; padding: 7px 16px; transition: background .15s; }
.aidp-grid-item:hover { background: #f8f9ff; }
.aidp-gi-num { font-size: 12px; color: #aaa; width: 18px; flex-shrink: 0; font-weight: 600; }
.aidp-gi-logo { width: 22px; height: 22px; flex-shrink: 0; }
.aidp-gi-logo img { width: 22px; height: 22px; border-radius: 6px; object-fit: cover; display: block; }
.aidp-gi-logo span { font-size: 16px; }
.aidp-gi-title { flex: 1; font-size: 13px; color: var(--aidp-dark); text-decoration: none; font-weight: 500; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.aidp-gi-title:hover { color: var(--aidp-primary); text-decoration: none; }
.aidp-gi-ups { font-size: 11px; color: var(--aidp-green); font-weight: 600; white-space: nowrap; }
.aidp-gi-link { font-size: 13px; color: #ccc; text-decoration: none; flex-shrink: 0; }
.aidp-gi-link:hover { color: var(--aidp-primary); text-decoration: none; }
.aidp-grid-see-all { display: block; padding: 10px 16px; font-size: 12px; font-weight: 600; color: var(--aidp-primary); text-decoration: none; border-top: 1px solid #ededf5; transition: background .15s; }
.aidp-grid-see-all:hover { background: #f3f5ff; text-decoration: none; }

/* ══════════════════════════════════════════════════
   TRENDING + SIDEBAR
══════════════════════════════════════════════════ */
.aidp-trending-wrap { background: #fff; border-radius: 16px; border: 1.5px solid #ededf5; overflow: hidden; }
.aidp-box-title { font-family: 'Syne',sans-serif; font-size: 15px; font-weight: 700; color: var(--aidp-dark); margin: 0; padding: 14px 16px; border-bottom: 1px solid #ededf5; background: #fafafe; }
.aidp-trend-list { list-style: none; margin: 0; padding: 8px 0; }
.aidp-trend-item { display: flex; align-items: center; gap: 8px; padding: 8px 16px; transition: background .15s; }
.aidp-trend-item:hover { background: #f8f9ff; }
.aidp-ti-num { font-size: 12px; color: #aaa; width: 20px; font-weight: 600; }
.aidp-ti-logo { width: 24px; height: 24px; flex-shrink: 0; }
.aidp-ti-logo img { width: 24px; height: 24px; border-radius: 6px; object-fit: cover; display: block; }
.aidp-ti-logo span { font-size: 18px; }
.aidp-ti-title { flex: 1; font-size: 13px; font-weight: 500; color: var(--aidp-dark); text-decoration: none; }
.aidp-ti-title:hover { color: var(--aidp-primary); text-decoration: none; }
.aidp-ti-ups { font-size: 11px; color: var(--aidp-green); font-weight: 600; }
.aidp-ti-link { font-size: 13px; color: #ccc; text-decoration: none; }
.aidp-ti-link:hover { color: var(--aidp-primary); text-decoration: none; }
.aidp-sidebar-box { background: #fff; border-radius: 16px; border: 1.5px solid #ededf5; overflow: hidden; margin-bottom: 20px; }
.aidp-sidebar-title { font-family: 'Syne',sans-serif; font-size: 14px; font-weight: 700; color: var(--aidp-dark); margin: 0; padding: 14px 16px; border-bottom: 1px solid #ededf5; background: #fafafe; }
.aidp-small-card { display: flex; align-items: center; gap: 10px; padding: 10px 16px; border-bottom: 1px solid #f5f5f8; transition: background .15s; }
.aidp-small-card:last-child { border-bottom: none; }
.aidp-small-card:hover { background: #f8f9ff; }
.aidp-sc-logo { width: 32px; height: 32px; flex-shrink: 0; }
.aidp-sc-logo img { width: 32px; height: 32px; border-radius: 8px; object-fit: cover; display: block; }
.aidp-sc-logo-ph { width: 32px; height: 32px; border-radius: 8px; background: linear-gradient(135deg,var(--aidp-primary),#0f9eff); display: flex; align-items: center; justify-content: center; font-size: 16px; }
.aidp-sc-info { flex: 1; min-width: 0; }
.aidp-sc-title { font-size: 13px; font-weight: 600; color: var(--aidp-dark); text-decoration: none; display: block; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.aidp-sc-title:hover { color: var(--aidp-primary); text-decoration: none; }
.aidp-sc-desc { font-size: 11px; color: #aaa; display: block; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.aidp-sc-link { font-size: 14px; color: #aaa; text-decoration: none; flex-shrink: 0; }
.aidp-sc-link:hover { color: var(--aidp-primary); text-decoration: none; }

/* ══════════════════════════════════════════════════
   RESPONSIVE
══════════════════════════════════════════════════ */
@media (max-width: 768px) {
  .aidp-body { grid-template-columns: 1fr; padding: 20px; }
  .aidp-header { padding: 18px 20px; }
  .aidp-hactions { width: 100%; justify-content: flex-end; }
  .aidp-name { font-size: 20px; }
  .aidp-cols-4 { grid-template-columns: repeat(2,1fr); }
  .aidp-cols-3 { grid-template-columns: repeat(2,1fr); }
  .aidp-upvote-bar { padding: 14px 20px; }
  .aidp-toolbar { flex-direction: column; align-items: stretch; }
  .aidp-about-section { padding: 24px 20px; }
  .aidp-about-title { font-size: 20px !important; }
}
@media (max-width: 480px) {
  .aidp-cols-4, .aidp-cols-3, .aidp-cols-2 { grid-template-columns: 1fr; }
  .aidp-list-card { flex-wrap: wrap; }
  .aidp-lc-actions { width: 100%; justify-content: space-between; }
}

/* ══════════════════════════════════════════════════════════
   AI TOOL BOXES — AIxploria-style ranked list (Image design)
   Shortcode: [ai_tool_boxes]
══════════════════════════════════════════════════════════ */

.aidpb-wrap {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  max-width: 1300px;
  margin: 0 auto;
}

.aidpb-section-title {
  font-size: 22px;
  font-weight: 700;
  color: #1a1a2e;
  margin: 0 0 20px;
}

/* ── GRID ── */
.aidpb-grid {
  display: grid;
  gap: 18px;
}
.aidpb-cols-1 { grid-template-columns: 1fr; }
.aidpb-cols-2 { grid-template-columns: repeat(2, 1fr); }
.aidpb-cols-3 { grid-template-columns: repeat(3, 1fr); }
.aidpb-cols-4 { grid-template-columns: repeat(4, 1fr); }
.aidpb-cols-5 { grid-template-columns: repeat(5, 1fr); }
.aidpb-cols-6 { grid-template-columns: repeat(6, 1fr); }

/* ── BOX ── */
.aidpb-box {
  background: #ffffff;
  border-radius: 16px;
  border: 1.5px solid #e8eaf0;
  box-shadow: 0 2px 12px rgba(0,0,0,0.05);
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

/* ── BOX HEADER ── */
.aidpb-box-header {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 16px 18px 14px;
}

.aidpb-box-icon {
  font-size: 18px;
  flex-shrink: 0;
  line-height: 1;
}

.aidpb-box-title {
  font-size: 15px;
  font-weight: 700;
  color: #1a1a2e;
  text-decoration: none;
  letter-spacing: -0.1px;
}
.aidpb-box-title:hover { color: #4f63d8; text-decoration: none; }
a.aidpb-box-title { cursor: pointer; }

/* ── RAINBOW DIVIDER ── */
.aidpb-divider {
  height: 2.5px;
  background: linear-gradient(90deg, #ff6b9d, #ffd93d, #6bcb77, #4d96ff, #c77dff);
  background-size: 200% 100%;
  animation: aidpb-rainbow 5s linear infinite;
  margin-bottom: 6px;
}
@keyframes aidpb-rainbow {
  0%   { background-position: 0%; }
  100% { background-position: 200%; }
}

/* ── LIST ── */
.aidpb-list {
  list-style: none;
  margin: 0;
  padding: 6px 0;
  flex: 1;
  overflow-y: auto;
  max-height: 380px;
  /* Custom scrollbar */
  scrollbar-width: thin;
  scrollbar-color: #e2e8f0 transparent;
}
.aidpb-list::-webkit-scrollbar { width: 4px; }
.aidpb-list::-webkit-scrollbar-thumb { background: #e2e8f0; border-radius: 4px; }

/* ── LIST ITEM ── */
.aidpb-item {
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 7px 14px;
  transition: background 0.15s;
  cursor: default;
}
.aidpb-item:hover { background: #f8f9ff; }

.aidpb-item-num {
  font-size: 12px;
  color: #aaa;
  font-weight: 600;
  width: 20px;
  flex-shrink: 0;
  text-align: right;
}

/* ── TOOL LOGO ── */
.aidpb-item-logo {
  width: 26px;
  height: 26px;
  flex-shrink: 0;
  border-radius: 7px;
  overflow: hidden;
}
.aidpb-item-logo img {
  width: 26px;
  height: 26px;
  object-fit: cover;
  display: block;
  border-radius: 7px;
}
.aidpb-logo-ph {
  width: 26px;
  height: 26px;
  border-radius: 7px;
  background: linear-gradient(135deg, #4f63d8, #0f9eff);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  font-weight: 700;
  color: #fff;
  text-transform: uppercase;
}

/* ── TOOL NAME ── */
.aidpb-item-name {
  flex: 1;
  font-size: 13.5px;
  font-weight: 500;
  color: #2d2d3a;
  text-decoration: none;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  transition: color 0.15s;
}
.aidpb-item-name:hover { color: #4f63d8; text-decoration: none; }

/* Featured item name (Latest AI pink color like image) */
.aidpb-name-featured { color: #e91e8c !important; font-weight: 600 !important; }
.aidpb-name-featured:hover { color: #c2185b !important; }

/* ── EXTERNAL LINK ICON ── */
.aidpb-item-ext {
  flex-shrink: 0;
  color: #c8cce0;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 24px;
  height: 24px;
  border-radius: 6px;
  border: 1px solid #ededf5;
  background: #fafafe;
  transition: all 0.15s;
  text-decoration: none;
}
.aidpb-item-ext:hover {
  color: #4f63d8;
  border-color: #c5ceff;
  background: #f0f2ff;
  text-decoration: none;
}

/* Empty state */
.aidpb-empty {
  font-size: 13px;
  color: #aaa;
  padding: 16px;
  text-align: center;
}

/* ── SEE ALL BUTTON ── */
.aidpb-see-all {
  display: block;
  text-align: center;
  padding: 11px 16px;
  font-size: 13px;
  font-weight: 600;
  color: #555;
  text-decoration: none;
  border-top: 1.5px solid #f0f0f8;
  background: #fafafe;
  transition: all 0.15s;
  margin-top: auto;
}
.aidpb-see-all:hover {
  background: #f0f2ff;
  color: #4f63d8;
  text-decoration: none;
}

/* ── RESPONSIVE ── */
@media (max-width: 1100px) {
  .aidpb-cols-4 { grid-template-columns: repeat(2, 1fr); }
  .aidpb-cols-5 { grid-template-columns: repeat(3, 1fr); }
  .aidpb-cols-6 { grid-template-columns: repeat(3, 1fr); }
}
@media (max-width: 700px) {
  .aidpb-cols-2,
  .aidpb-cols-3,
  .aidpb-cols-4,
  .aidpb-cols-5,
  .aidpb-cols-6 { grid-template-columns: 1fr; }
}

/* ══════════════════════════════════════════════════
   FONT FIX — Tool name Arial Bold (no Syne)
══════════════════════════════════════════════════ */
.aidp-name {
  font-family: Arial, 'Helvetica Neue', sans-serif !important;
  font-size: 24px !important;
  font-weight: 700 !important;
  color: var(--aidp-dark);
  letter-spacing: -0.3px;
}
/* Also fix syne in other places */
.aidp-lc-title {
  font-family: Arial, 'Helvetica Neue', sans-serif !important;
  font-weight: 700 !important;
}
.aidpb-box-title, .aidpb-item-name {
  font-family: Arial, 'Helvetica Neue', sans-serif !important;
}

/* ══════════════════════════════════════════════════
   STARS — show rating number
══════════════════════════════════════════════════ */
.aidp-stars-wrap { display:inline-flex; align-items:center; gap:4px; }
.aidp-star-num {
  font-size: 12px;
  font-weight: 700;
  color: #f59e0b;
  background: #fef3c7;
  padding: 1px 6px;
  border-radius: 6px;
  margin-left: 2px;
}

/* ══════════════════════════════════════════════════
   SHARE DROPDOWN — Professional
══════════════════════════════════════════════════ */
.aidp-share-wrap {
  position: relative;
  display: inline-block;
}
.aidp-share-dropdown {
  display: none;
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  background: #fff;
  border: 1.5px solid #e2e8f0;
  border-radius: 12px;
  box-shadow: 0 8px 30px rgba(0,0,0,0.12);
  z-index: 999;
  min-width: 180px;
  padding: 6px;
  overflow: hidden;
}
.aidp-share-wrap.open .aidp-share-dropdown { display: block; }
.aidp-share-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 9px 12px;
  font-size: 13px;
  font-weight: 500;
  color: #374151;
  text-decoration: none;
  border-radius: 8px;
  border: none;
  background: transparent;
  width: 100%;
  cursor: pointer;
  font-family: inherit;
  transition: background 0.15s;
}
.aidp-share-item:hover { background: #f3f5ff; color: #4f46e5; text-decoration: none; }
.aidp-share-twitter:hover  { background: #e7f5fe; color: #1da1f2; }
.aidp-share-fb:hover       { background: #e8f0fe; color: #1877f2; }
.aidp-share-wa:hover       { background: #e8fef0; color: #25d366; }
.aidp-share-linkedin:hover { background: #e8f2fb; color: #0a66c2; }

/* ══════════════════════════════════════════════════
   GRID CARD — Grok Imagine exact style
══════════════════════════════════════════════════ */
.aidpg-grid {
  display: grid;
  gap: 18px;
}
.aidpg-cols-2 { grid-template-columns: repeat(2,1fr); }
.aidpg-cols-3 { grid-template-columns: repeat(3,1fr); }
.aidpg-cols-4 { grid-template-columns: repeat(4,1fr); }
.aidpg-cols-5 { grid-template-columns: repeat(5,1fr); }
.aidpg-cols-6 { grid-template-columns: repeat(6,1fr); }

/* Card link wrapper */
.aidpg-card-link {
  text-decoration: none !important;
  display: block;
  color: inherit;
}

/* Card */
.aidpg-card {
  background: #fff;
  border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 4px 15px rgba(0,0,0,0.08);
  border: 1px solid #e5e7eb;
  font-family: 'Segoe UI', Arial, sans-serif;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  cursor: pointer;
}
.aidpg-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 12px 30px rgba(0,0,0,0.15);
}

.aidpg-card-body { padding: 18px; }

/* TOP META */
.aidpg-top-meta {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 14px;
  margin-bottom: 12px;
  gap: 6px;
}
.aidpg-pricing {
  display: flex;
  align-items: center;
  gap: 6px;
  font-weight: 600;
  color: #374151;
  font-size: 13px;
}
.aidpg-dot {
  width: 8px; height: 8px;
  border-radius: 50%;
  flex-shrink: 0;
}
.aidpg-stars-wrap2 {
  display: flex;
  align-items: center;
  gap: 1px;
}
.aidpg-stars-wrap2 .aidp-star { font-size: 14px; }
.aidpg-votes {
  display: flex;
  align-items: center;
  gap: 4px;
  color: #1f2937;
  font-weight: 700;
  font-size: 14px;
}
.aidpg-votes svg {
  width: 16px; height: 16px;
  fill: #1f2937;
  flex-shrink: 0;
}

/* DIVIDER */
.aidpg-hr {
  border: none;
  border-top: 1px solid #e5e7eb;
  margin: 0 0 16px;
}

/* TOOL HEADER */
.aidpg-tool-header { text-align: center; }
.aidpg-tool-title {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  margin-bottom: 10px;
  flex-wrap: wrap;
}
.aidpg-tool-logo {
  width: 38px; height: 38px;
  object-fit: contain;
  border-radius: 10px;
  flex-shrink: 0;
}
.aidpg-logo-ph {
  width: 38px; height: 38px;
  background: linear-gradient(135deg, #4f63d8, #0f9eff);
  border-radius: 10px;
  display: flex; align-items: center; justify-content: center;
  font-size: 16px; font-weight: 800; color: #fff;
  text-transform: uppercase; flex-shrink: 0;
}
.aidpg-tool-name {
  font-size: 20px;
  font-weight: 700;
  color: #1f2937;
  line-height: 1.2;
  font-family: Arial, sans-serif;
}
.aidpg-verified2 {
  color: #2196f3;
  font-size: 16px;
  font-weight: 700;
}

/* BLUE LINE under name */
.aidpg-blue-line {
  width: 130px;
  height: 2px;
  background: #2196f3;
  margin: 0 auto 16px;
  border-radius: 10px;
}

/* DESCRIPTION */
.aidpg-description {
  text-align: center;
  color: #374151;
  font-size: 14px;
  line-height: 1.7;
  margin-bottom: 20px;
  font-style: italic;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* VISIT BUTTON */
.aidpg-visit-btn {
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  gap: 8px !important;
  width: 140px !important;
  margin: 0 auto !important;
  padding: 11px 20px !important;
  background: linear-gradient(135deg, #5ea6f7, #3b82f6) !important;
  color: #fff !important;
  text-decoration: none !important;
  border-radius: 8px !important;
  font-weight: 700 !important;
  letter-spacing: 0.8px !important;
  font-size: 13px !important;
  transition: transform 0.3s, box-shadow 0.3s !important;
  font-family: Arial, sans-serif !important;
  position: relative;
  z-index: 5;
}
.aidpg-visit-btn:hover {
  transform: translateY(-2px) !important;
  box-shadow: 0 6px 20px rgba(59,130,246,0.4) !important;
  color: #fff !important;
  text-decoration: none !important;
}
.aidpg-visit-btn svg { stroke: #fff; flex-shrink: 0; }

/* ══════════════════════════════════════════════════
   RELATED TOOLS SECTION
══════════════════════════════════════════════════ */
.aidp-related-wrap {
  max-width: 980px;
  margin: 24px auto 0;
  padding: 0;
}
.aidp-related-title {
  font-family: Arial, 'Helvetica Neue', sans-serif !important;
  font-size: 20px !important;
  font-weight: 700 !important;
  color: #1a1a2e !important;
  margin: 0 0 16px !important;
  padding: 0 !important;
  border: none !important;
  display: flex;
  align-items: center;
  gap: 8px;
}

/* ══════════════════════════════════════════════════
   CATEGORY ARCHIVE PAGE
══════════════════════════════════════════════════ */
.aidp-cat-archive-wrap { max-width: 1300px; margin: 0 auto; padding: 40px 20px; }
.aidp-cat-archive-header { margin-bottom: 28px; }
.aidp-cat-archive-title {
  font-family: Arial, 'Helvetica Neue', sans-serif !important;
  font-size: 28px !important;
  font-weight: 700 !important;
  color: #1a1a2e !important;
  margin: 0 0 10px !important;
}
.aidp-cat-archive-desc { font-size: 15px; color: #64748b; margin: 0 0 10px; }
.aidp-cat-archive-count {
  background: #eef2ff; color: #4f46e5;
  font-size: 13px; font-weight: 600;
  padding: 4px 12px; border-radius: 20px;
  display: inline-block;
}

/* ══════════════════════════════════════════════════
   PAGINATION WITH NUMBERS
══════════════════════════════════════════════════ */
.aidp-pagination {
  margin: 40px 0 0;
  display: flex;
  justify-content: center;
}
.aidp-pagination .page-numbers {
  display: inline-flex;
  align-items: center;
  list-style: none;
  margin: 0;
  padding: 0;
  gap: 6px;
  flex-wrap: wrap;
  justify-content: center;
}
.aidp-pagination .page-numbers li { list-style: none; margin: 0; }
.aidp-pagination .page-numbers li a,
.aidp-pagination .page-numbers li span {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: 10px;
  font-size: 14px;
  font-weight: 600;
  font-family: Arial, sans-serif;
  text-decoration: none;
  border: 1.5px solid #e2e8f0;
  background: #fff;
  color: #374151;
  transition: all 0.2s;
}
.aidp-pagination .page-numbers li a:hover {
  border-color: #4f63d8;
  background: #f0f2ff;
  color: #4f63d8;
  text-decoration: none;
}
.aidp-pagination .page-numbers li span.current {
  background: #4f63d8;
  color: #fff;
  border-color: #4f63d8;
}
.aidp-pagination .page-numbers li a.prev,
.aidp-pagination .page-numbers li a.next {
  width: auto;
  padding: 0 16px;
  font-size: 13px;
}
.aidp-pagination .page-numbers li span.dots {
  border: none;
  background: transparent;
  color: #94a3b8;
}

/* ══════════════════════════════════════════════════
   RESPONSIVE
══════════════════════════════════════════════════ */
@media (max-width: 1100px) {
  .aidpg-cols-6 { grid-template-columns: repeat(4, 1fr); }
  .aidpg-cols-4 { grid-template-columns: repeat(3, 1fr); }
}
@media (max-width: 768px) {
  .aidpg-cols-6, .aidpg-cols-4, .aidpg-cols-3 { grid-template-columns: repeat(2, 1fr); }
  .aidp-share-dropdown { right: auto; left: 0; }
}
@media (max-width: 480px) {
  .aidpg-cols-6, .aidpg-cols-4, .aidpg-cols-3, .aidpg-cols-2 { grid-template-columns: repeat(2, 1fr); }
}
