/* Home listing/ad cards: approximately 10% larger without changing dashboard cards. */
#listingsGrid, #adsGrid, .home-page-v2 #listingsGrid, .home-page-v2 #adsGrid {
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 330px), 1fr)) !important;
  gap: clamp(14px, 1.35vw, 20px) !important;
}
#listingsGrid > .listing-card, #adsGrid > .listing-card {
  min-height: 1px;
}
#listingsGrid > .listing-card .listing-image,
#adsGrid > .listing-card .listing-image {
  height: clamp(154px, 22vw, 198px) !important;
}
#listingsGrid > .listing-card .listing-body,
#adsGrid > .listing-card .listing-body {
  padding: clamp(13px, 1.65vw, 19px) !important;
}
#listingsGrid > .listing-card .listing-title,
#adsGrid > .listing-card .listing-title {
  font-size: clamp(.92rem, 1.38vw, 1.08rem) !important;
  line-height: 1.5;
}
#listingsGrid > .listing-card .listing-actions,
#adsGrid > .listing-card .listing-actions {
  gap: 7px;
  padding-top: 11px;
}
@media (max-width: 700px) {
  #listingsGrid, #adsGrid, .home-page-v2 #listingsGrid, .home-page-v2 #adsGrid {
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    gap: 11px !important;
  }
  #listingsGrid > .listing-card .listing-image,
  #adsGrid > .listing-card .listing-image { height: clamp(132px, 39vw, 170px) !important; }
}
@media (max-width: 390px) {
  #listingsGrid, #adsGrid, .home-page-v2 #listingsGrid, .home-page-v2 #adsGrid {
    grid-template-columns: minmax(0, 1fr) !important;
  }
}

/* Full, readable request detail modal in user dashboard. */
#dashDetailModal .dash-detail-full { color: var(--text-color, #1f2937); }
#dashDetailModal .dash-detail-image { margin: 0 0 16px; border-radius: 12px; overflow: hidden; background: var(--surface-muted, #f1f5f9); }
#dashDetailModal .dash-detail-image img { display:block; width:100%; max-height:300px; object-fit:contain; }
#dashDetailModal .dash-detail-heading { display:flex; align-items:flex-start; justify-content:space-between; gap:16px; flex-wrap:wrap; margin-bottom:18px; }
#dashDetailModal .dash-detail-heading h3 { margin:0 0 8px; font-size:1.25rem; }
#dashDetailModal .dash-detail-badges { display:flex; gap:8px; align-items:center; flex-wrap:wrap; }
#dashDetailModal .dash-detail-main-price { color:var(--primary,#ea580c); font-size:1.2rem; font-weight:800; }
#dashDetailModal .dash-detail-section { border:1px solid var(--border-color,#e5e7eb); border-radius:12px; padding:14px; margin:14px 0; background:var(--surface-color,transparent); }
#dashDetailModal .dash-detail-section h4 { margin:0 0 12px; font-size:1rem; }
#dashDetailModal .dash-detail-grid { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:10px; }
#dashDetailModal .dash-detail-field { display:flex; flex-direction:column; gap:4px; min-width:0; padding:9px 10px; border-radius:8px; background:var(--surface-muted,rgba(148,163,184,.08)); }
#dashDetailModal .dash-detail-field span { color:var(--text-muted,#64748b); font-size:.78rem; }
#dashDetailModal .dash-detail-field strong { overflow-wrap:anywhere; font-size:.9rem; font-weight:650; }
#dashDetailModal .dash-detail-description { margin-top:12px; padding:12px; border-radius:8px; background:var(--surface-muted,rgba(148,163,184,.08)); }
#dashDetailModal .dash-detail-description p { white-space:pre-wrap; line-height:1.9; margin:8px 0 0; }
#dashDetailModal .dash-detail-footer { display:flex; justify-content:flex-end; gap:8px; position:sticky; bottom:-1px; padding:12px 0 0; background:var(--card-bg,#fff); }
#dashDetailModal .table-responsive { overflow-x:auto; }
#dashDetailModal .data-table { min-width:620px; width:100%; }
@media(max-width:600px) {
  #dashDetailModal .dash-detail-grid { grid-template-columns:1fr; }
  #dashDetailModal .dash-detail-heading { display:block; }
  #dashDetailModal .dash-detail-main-price { margin-top:10px; }
  #dashDetailModal .dash-detail-modal { max-height:94vh !important; margin:2vh auto !important; }
}
