/* ============================================================
   LuckyList 2026 listing card + detail page
   Override Sigma defaults to match Leolist UX quality.
   ============================================================ */

/* Listing container — switch from <ul> stacked to grid */
ul.list-items,
.listings,
.results-listings,
#listing-items,
.items-list {
  list-style: none !important;
  padding: 0 !important;
  margin: 0 !important;
  display: grid !important;
  grid-template-columns: 1fr;
  gap: 16px;
}

@media (min-width: 768px) {
  ul.list-items,
  .listings,
  .results-listings,
  #listing-items,
  .items-list {
    grid-template-columns: 1fr 1fr;
  }
}

@media (min-width: 1200px) {
  ul.list-items,
  .listings,
  .results-listings,
  #listing-items,
  .items-list {
    grid-template-columns: 1fr 1fr 1fr;
  }
}

/* Hide Sigma's old listing-card defaults that would conflict */
.ll-card * { box-sizing: border-box; }

/* The card itself */
.ll-card {
  list-style: none;
  background: #fff;
  border: 1px solid #e2e8f0;
  border-radius: 10px;
  overflow: hidden;
  transition: box-shadow .15s ease, transform .15s ease, border-color .15s ease;
  position: relative;
}
.ll-card:hover {
  box-shadow: 0 6px 18px rgba(0,0,0,.10);
  border-color: #cbd5e1;
  transform: translateY(-1px);
}
.ll-card-stub {
  border-color: #fbbf24;
}
.ll-card-stub:hover {
  border-color: #f59e0b;
}

.ll-card-link {
  display: grid;
  grid-template-columns: 200px 1fr;
  gap: 16px;
  padding: 12px;
  text-decoration: none !important;
  color: inherit !important;
}

@media (max-width: 480px) {
  .ll-card-link {
    grid-template-columns: 120px 1fr;
    gap: 12px;
    padding: 10px;
  }
}

/* Photo */
.ll-card-photo {
  position: relative;
  width: 100%;
  aspect-ratio: 1 / 1;
  overflow: hidden;
  border-radius: 8px;
  background: #f1f5f9;
}
.ll-card-photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.ll-card-photo-placeholder {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 100%;
  color: #94a3b8;
  font-size: 13px;
  font-family: Poppins, sans-serif;
}
.ll-card-corner-badge {
  position: absolute;
  top: 8px;
  left: 8px;
  background: #f59e0b;
  color: #fff;
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .5px;
  padding: 3px 8px;
  border-radius: 4px;
  font-family: Poppins, sans-serif;
}

/* Card body */
.ll-card-body {
  display: flex;
  flex-direction: column;
  gap: 4px;
  min-width: 0;
  padding: 4px 0;
}
.ll-card-headline {
  font-family: Poppins, sans-serif !important;
  font-size: 16px !important;
  font-weight: 700 !important;
  color: #1e293b !important;
  margin: 0 0 4px 0 !important;
  line-height: 1.3 !important;
  display: -webkit-box !important;
  -webkit-line-clamp: 2 !important;
  -webkit-box-orient: vertical !important;
  overflow: hidden !important;
  word-break: break-word;
}
.ll-card:hover .ll-card-headline {
  color: #1e40af !important;
}
.ll-card-meta {
  font-family: Poppins, sans-serif;
  font-size: 14px;
  color: #475569;
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
}
.ll-card-meta .ll-card-age {
  font-weight: 600;
  color: #0f172a;
}
.ll-card-loc {
  font-family: Poppins, sans-serif;
  font-size: 13px;
  color: #64748b;
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
  margin-top: 2px;
}
.ll-card-sep {
  color: #cbd5e1;
}
.ll-card-badges {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
  margin-top: 8px;
}
.ll-pill {
  display: inline-block;
  font-family: Poppins, sans-serif;
  font-size: 11px;
  font-weight: 600;
  padding: 3px 9px;
  border-radius: 999px;
  letter-spacing: .2px;
  white-space: nowrap;
}
.ll-pill-verified { background: #dcfce7; color: #14532d; }
.ll-pill-video    { background: #dbeafe; color: #1e3a8a; }
.ll-pill-rate     { background: #fef3c7; color: #78350f; }
.ll-pill-premium  { background: #ede9fe; color: #5b21b6; }
.ll-pill-stub     { background: #fff7ed; color: #c2410c; border: 1px solid #fed7aa; }

/* ============================================================
   Detail page (item.php) — two-column hero layout
   ============================================================ */

.ll-detail {
  display: grid;
  grid-template-columns: 1fr;
  gap: 24px;
  max-width: 1200px;
  margin: 0 auto;
  padding: 16px;
  font-family: Poppins, sans-serif;
}

@media (min-width: 900px) {
  .ll-detail {
    grid-template-columns: minmax(0, 1fr) 360px;
  }
}

.ll-detail-headline {
  font-family: Poppins, sans-serif;
  font-size: 26px;
  font-weight: 800;
  color: #0f172a;
  margin: 0 0 6px 0;
  line-height: 1.2;
  word-break: break-word;
}
.ll-detail-submeta {
  font-size: 13px;
  color: #64748b;
  margin: 0 0 14px 0;
}
.ll-back-link {
  display: inline-block;
  font-size: 13px;
  color: #1e40af;
  text-decoration: none;
  margin-bottom: 8px;
}
.ll-back-link:hover { text-decoration: underline; }

/* Hero photo */
.ll-detail-hero {
  width: 100%;
  aspect-ratio: 3 / 4;
  max-height: 700px;
  background: #f1f5f9;
  border-radius: 12px;
  overflow: hidden;
  position: relative;
}
.ll-detail-hero img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

/* Gallery strip below hero */
.ll-detail-gallery {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(90px, 1fr));
  gap: 8px;
  margin-top: 10px;
}
.ll-detail-gallery a {
  display: block;
  aspect-ratio: 1 / 1;
  border-radius: 6px;
  overflow: hidden;
  background: #f1f5f9;
}
.ll-detail-gallery img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

/* Right sidebar */
.ll-detail-sidebar {
  background: #fff;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  padding: 18px;
  position: sticky;
  top: 16px;
  align-self: start;
}
.ll-detail-sidebar h2 {
  font-size: 14px;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: #475569;
  margin: 0 0 12px 0;
  border-bottom: 2px solid #1e40af;
  padding-bottom: 6px;
}
.ll-detail-facts {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 6px 12px;
  margin-bottom: 16px;
  font-size: 14px;
}
.ll-detail-facts dt {
  color: #64748b;
  font-weight: 500;
}
.ll-detail-facts dd {
  margin: 0;
  color: #0f172a;
  font-weight: 600;
}

.ll-cta {
  display: block;
  width: 100%;
  padding: 12px 18px;
  border: 0;
  border-radius: 8px;
  font-family: Poppins, sans-serif;
  font-size: 15px;
  font-weight: 700;
  text-align: center;
  cursor: pointer;
  text-decoration: none !important;
  margin-bottom: 8px;
  transition: background .15s ease;
}
.ll-cta-primary {
  background: #16a34a;
  color: #fff !important;
}
.ll-cta-primary:hover { background: #15803d; }
.ll-cta-secondary {
  background: #1e40af;
  color: #fff !important;
}
.ll-cta-secondary:hover { background: #1e3a8a; }
.ll-cta-claim {
  background: #f59e0b;
  color: #fff !important;
}
.ll-cta-claim:hover { background: #d97706; }

.ll-stub-banner {
  background: linear-gradient(135deg, #fff7e6 0%, #ffe9b3 100%);
  border-left: 4px solid #f5a623;
  padding: 12px 14px;
  border-radius: 6px;
  margin-bottom: 16px;
  font-size: 13px;
  color: #78350f;
}
.ll-stub-banner strong { color: #b8530a; }

/* Description body */
.ll-detail-about {
  background: #fff;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  padding: 20px;
  margin-top: 16px;
  font-size: 15px;
  line-height: 1.6;
  color: #1e293b;
  grid-column: 1 / -1;
}
.ll-detail-about h2 {
  margin-top: 0;
  font-size: 18px;
  font-weight: 700;
  border-bottom: 2px solid #e2e8f0;
  padding-bottom: 8px;
  margin-bottom: 14px;
}

/* Hide stuff Sigma default that conflicts */
.ll-detail + .listing-card,
.ll-detail ~ .item-meta-fields,
.ll-detail ~ .ad-attributes {
  display: none;
}
