/*
 * Potensi Desa — Filter search + kategori
 */

.potensi-filter-card {
  background: #fff;
  border: 1px solid rgba(15, 23, 42, 0.06);
  border-radius: 20px;
  box-shadow: 0 10px 30px rgba(12, 84, 64, 0.06);
}

.potensi-filter-form {
  width: 100%;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

@media (min-width: 640px) {
  .potensi-filter-form {
    flex-direction: row;
    align-items: flex-end;
    gap: 1rem;
  }
}

.potensi-filter-form input[type="text"] {
  flex: 1;
  min-width: 0;
  padding: 0.6rem 1rem;
  border-radius: 12px;
  border: 1px solid #e2e8f0;
  font-size: 0.9375rem;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.potensi-filter-form input[type="text"]:focus {
  outline: none;
  border-color: #0c5440;
  box-shadow: 0 0 0 3px rgba(12, 84, 64, 0.12);
}

.potensi-filter-select {
  padding: 0.6rem 1rem;
  border-radius: 12px;
  border: 1px solid #e2e8f0;
  background: #fff;
  font-size: 0.9375rem;
  cursor: pointer;
  transition: border-color 0.2s ease;
  min-width: 180px;
}

.potensi-filter-select:focus {
  outline: none;
  border-color: #0c5440;
}

.potensi-filter-search-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.6rem 1rem;
  border-radius: 12px;
  border: none;
  cursor: pointer;
  font-weight: 700;
  font-size: 0.9375rem;
  color: #fff;
  background: linear-gradient(135deg, #0c5440, #0d6b54);
  box-shadow: 0 8px 18px rgba(12, 84, 64, 0.14);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
  flex-shrink: 0;
}

.potensi-filter-search-btn:hover {
  transform: translateY(-1px);
  box-shadow: 0 12px 26px rgba(12, 84, 64, 0.18);
}

.potensi-card-link {
  display: block;
  color: inherit;
  text-decoration: none;
}

.potensi-list-card {
  height: 100%;
}

.potensi-card-media {
  aspect-ratio: 16 / 10;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  background: linear-gradient(135deg, #f8fafc, #e6f5ef);
  border-bottom: 1px solid rgba(15, 23, 42, 0.06);
}

.potensi-card-media img {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: contain;
  padding: 0.5rem;
  transition: transform 0.25s ease;
}

.potensi-list-card:hover .potensi-card-media img {
  transform: scale(1.03);
}

.potensi-card-placeholder {
  width: 72px;
  height: 72px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 18px;
  color: #0c5444;
  background: rgba(255, 255, 255, 0.72);
  border: 1px solid rgba(12, 84, 68, 0.12);
  font-size: 2rem;
}

.potensi-detail-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 340px;
  gap: 1.5rem;
  align-items: start;
}

.potensi-detail-main,
.potensi-side-card {
  background: #fff;
  border: 1px solid rgba(15, 23, 42, 0.08);
  border-radius: 18px;
  box-shadow: 0 10px 30px rgba(12, 84, 64, 0.05);
}

.potensi-detail-main {
  overflow: hidden;
}

.potensi-detail-media {
  margin: 0;
  aspect-ratio: 16 / 9;
  background: #f1f5f9;
  overflow: hidden;
}

.potensi-detail-media img {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
}

.potensi-detail-media-empty {
  display: flex;
  align-items: center;
  justify-content: center;
  color: #94a3b8;
  font-size: 4rem;
}

.potensi-detail-body {
  padding: 1.5rem;
}

.potensi-detail-badge {
  display: inline-flex;
  align-items: center;
  padding: 0.35rem 0.75rem;
  border-radius: 999px;
  background: #e6f5ef;
  color: #0c5444;
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin-bottom: 0.9rem;
}

.potensi-detail-desc {
  margin-top: 1rem;
  color: #475569;
  font-size: 0.98rem;
  line-height: 1.85;
}

.potensi-detail-desc p {
  margin: 0 0 1rem;
}

.potensi-detail-side {
  display: grid;
  gap: 1rem;
  position: sticky;
  top: 92px;
}

.potensi-side-card {
  padding: 1.25rem;
}

.potensi-side-card h2 {
  margin: 0 0 1rem;
  color: #0f172a;
  font-size: 0.96rem;
  font-weight: 800;
}

.potensi-side-card dl {
  display: grid;
  gap: 0.85rem;
  margin: 0;
}

.potensi-side-card dl div {
  padding-bottom: 0.85rem;
  border-bottom: 1px solid #eef2f7;
}

.potensi-side-card dl div:last-child {
  padding-bottom: 0;
  border-bottom: 0;
}

.potensi-side-card dt {
  color: #64748b;
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.potensi-side-card dd {
  margin: 0.25rem 0 0;
  color: #0f172a;
  font-size: 0.92rem;
  font-weight: 600;
  line-height: 1.5;
}

.potensi-side-actions {
  display: grid;
  gap: 0.65rem;
  margin-top: 1.25rem;
}

.potensi-related-list {
  display: grid;
  gap: 0.65rem;
}

.potensi-related-item {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.65rem;
  border: 1px solid #eef2f7;
  border-radius: 12px;
  color: inherit;
  text-decoration: none;
  transition: border-color 0.18s ease, background 0.18s ease;
}

.potensi-related-item:hover {
  border-color: rgba(12, 84, 64, 0.22);
  background: #f8fafc;
}

.potensi-related-item img,
.potensi-related-icon {
  width: 54px;
  height: 54px;
  flex: 0 0 54px;
  border-radius: 10px;
  object-fit: cover;
  background: #f1f5f9;
}

.potensi-related-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #94a3b8;
}

.potensi-related-item strong {
  display: block;
  color: #0f172a;
  font-size: 0.86rem;
  line-height: 1.35;
}

.potensi-related-item small {
  display: block;
  margin-top: 0.18rem;
  color: #64748b;
  font-size: 0.74rem;
}

.potensi-side-empty {
  margin: 0;
  color: #64748b;
  font-size: 0.9rem;
}

@media (max-width: 900px) {
  .potensi-detail-grid {
    grid-template-columns: 1fr;
  }

  .potensi-detail-side {
    position: static;
  }
}

/* Detail potensi mengikuti struktur visual berita_detail.html */
.potensi-detail-page,
.potensi-detail-page *:not(i) {
  font-family: 'DM Sans', sans-serif;
}

.potensi-detail-page .bd-article-title,
.potensi-detail-page .berita-konten h1,
.potensi-detail-page .berita-konten h2,
.potensi-detail-page .berita-konten h3,
.potensi-detail-page .berita-konten h4 {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif !important;
}

.potensi-detail-page .bd-section-head h2,
.potensi-detail-page .bd-side-title {
  font-family: 'Bricolage Grotesque', sans-serif !important;
}

.potensi-detail-page .bd-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 340px;
  gap: 34px;
  align-items: start;
}

.potensi-detail-page .bd-main {
  min-width: 0;
}

.potensi-detail-page .bd-article-card {
  overflow: hidden;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  background: #fff;
  box-shadow: 0 18px 48px rgba(15, 23, 42, 0.07);
}

.potensi-detail-page .bd-article-header {
  padding: clamp(22px, 3vw, 34px) clamp(20px, 3.2vw, 36px) 20px;
  border-bottom: 1px solid #e2e8f0;
}

.potensi-detail-page .bd-article-kicker {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 0 10px;
  border-radius: 999px;
  color: #0d5c42;
  background: #f0faf5;
  border: 1px solid #d6efe1;
  font-size: 10.5px;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin-bottom: 12px;
}

.potensi-detail-page .bd-article-title {
  margin: 0;
  color: #0f172a;
  max-width: 920px;
  font-size: clamp(1.5rem, 2.6vw, 2.25rem);
  font-weight: 800;
  line-height: 1.12;
  letter-spacing: -0.025em;
}

.potensi-detail-page .bd-article-meta {
  display: inline-flex;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
  margin-top: 18px;
  padding: 8px 16px;
  background: #f8fafc;
  border: 1px solid #edf2f7;
  border-radius: 8px;
  color: #475569;
  font-size: 13px;
  font-weight: 500;
  box-shadow: 0 2px 8px rgba(15, 23, 42, 0.02);
}

.potensi-detail-page .bd-article-meta span {
  display: inline-flex;
  align-items: center;
  gap: 7px;
}

.potensi-detail-page .bd-article-meta span:not(:last-child)::after {
  content: '•';
  margin-left: 16px;
  color: #cbd5e1;
}

.potensi-detail-page .bd-article-meta i {
  color: #0d5c42;
  font-size: 13px;
}

.potensi-detail-page .bd-feature-image {
  display: grid;
  justify-items: center;
  align-items: center;
  margin: 18px 0 0;
  overflow: hidden;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  background: linear-gradient(135deg, #f8fafc, #eef7f2);
  height: clamp(260px, 42vw, 520px);
}

.potensi-detail-page .bd-feature-image img {
  width: 100% !important;
  height: 100% !important;
  max-height: none;
  aspect-ratio: auto !important;
  display: block;
  object-fit: contain;
  padding: 0.75rem;
}

.potensi-detail-page .bd-article-inner {
  padding: clamp(22px, 4vw, 46px);
}

.potensi-detail-page .berita-konten {
  color: #334155;
  font-size: 1.075rem;
  line-height: 1.86;
}

.potensi-detail-page .berita-konten p {
  margin: 0 0 1.25rem;
  color: #475569;
}

.potensi-detail-page .berita-konten p:last-child {
  margin-bottom: 0;
}

.potensi-detail-page .berita-konten h1,
.potensi-detail-page .berita-konten h2,
.potensi-detail-page .berita-konten h3,
.potensi-detail-page .berita-konten h4 {
  color: #0f172a;
  font-weight: 800;
  line-height: 1.25;
  letter-spacing: -0.02em;
  margin: 2rem 0 0.8rem;
}

.potensi-detail-page .berita-konten h2 {
  font-size: 1.6rem;
  padding-bottom: 0.45rem;
  border-bottom: 1px solid #e2e8f0;
}

.potensi-detail-page .berita-konten h3 {
  font-size: 1.32rem;
}

.potensi-detail-page .berita-konten a {
  color: #0d5c42;
  font-weight: 700;
  text-decoration: none;
  border-bottom: 1px solid rgba(13, 92, 66, 0.22);
}

.potensi-detail-page .berita-konten strong {
  color: #0f172a;
  font-weight: 800;
}

.potensi-detail-page .bd-related {
  margin-top: 32px;
  padding-top: 28px;
  border-top: 1px solid #e2e8f0;
}

.potensi-detail-page .bd-section-head {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 16px;
}

.potensi-detail-page .bd-eyebrow {
  margin: 0 0 3px;
  color: #0d5c42;
  font-size: 11px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.potensi-detail-page .bd-section-head h2 {
  margin: 0;
  color: #0f172a;
  font-size: 20px;
  font-weight: 800;
}

.potensi-detail-page .bd-related-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.potensi-detail-page .bd-related-card {
  display: grid;
  grid-template-columns: 112px minmax(0, 1fr);
  gap: 13px;
  padding: 12px;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  background: #fff;
  color: inherit;
  text-decoration: none;
  transition: transform 0.16s, box-shadow 0.16s, border-color 0.16s;
}

.potensi-detail-page .bd-related-card:hover {
  color: inherit;
  border-color: #b7d8c7;
  box-shadow: 0 14px 34px rgba(15, 23, 42, 0.08);
  transform: translateY(-2px);
}

.potensi-detail-page .bd-related-thumb {
  aspect-ratio: 4 / 3;
  overflow: hidden;
  border-radius: 10px;
  background: #eef2f7;
}

.potensi-detail-page .bd-related-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.potensi-detail-page .bd-related-title {
  margin: 0 0 6px;
  color: #0f172a;
  font-size: 14px;
  font-weight: 800;
  line-height: 1.36;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.potensi-detail-page .bd-related-card:hover .bd-related-title {
  color: #0d5c42;
}

.potensi-detail-page .bd-related-date {
  color: #64748b;
  font-size: 12px;
  font-family: 'DM Mono', monospace;
}

.potensi-detail-page .bd-sidebar {
  position: sticky;
  top: 92px;
}

.potensi-detail-page .bd-side-card {
  margin-bottom: 16px;
  padding: 18px;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  background: #fff;
  box-shadow: 0 12px 34px rgba(15, 23, 42, 0.05);
}

.potensi-detail-page .bd-side-title {
  display: flex;
  align-items: center;
  gap: 9px;
  margin: 0 0 14px;
  color: #0f172a;
  font-size: 15px;
  font-weight: 800;
}

.potensi-detail-page .bd-side-title::before {
  content: '';
  width: 3px;
  height: 18px;
  border-radius: 999px;
  background: #0d5c42;
}

.potensi-detail-page .potensi-info-list {
  display: grid;
  gap: 0;
  margin: 0;
}

.potensi-detail-page .potensi-info-list div {
  padding: 0.8rem 0;
  border-bottom: 1px solid #eef2f7;
}

.potensi-detail-page .potensi-info-list div:first-child {
  padding-top: 0;
}

.potensi-detail-page .potensi-info-list div:last-child {
  border-bottom: 0;
}

.potensi-detail-page .potensi-info-list dt {
  color: #64748b;
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.potensi-detail-page .potensi-info-list dd {
  margin: 0.25rem 0 0;
  color: #0f172a;
  font-size: 0.92rem;
  font-weight: 600;
  line-height: 1.5;
}

.potensi-detail-page .potensi-side-actions {
  display: grid;
  gap: 0.65rem;
  margin-top: 1.25rem;
}

.potensi-detail-page .bd-popular-list {
  display: grid;
  gap: 10px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.potensi-detail-page .bd-popular-link {
  display: grid;
  grid-template-columns: 82px minmax(0, 1fr);
  gap: 12px;
  align-items: center;
  color: inherit;
  text-decoration: none;
}

.potensi-detail-page .bd-popular-thumb {
  position: relative;
  aspect-ratio: 4 / 3;
  overflow: hidden;
  border-radius: 10px;
  background: #eef2f7;
  flex-shrink: 0;
}

.potensi-detail-page .bd-popular-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.18s;
}

.potensi-detail-page .bd-popular-link:hover .bd-popular-thumb img {
  transform: scale(1.05);
}

.potensi-detail-page .bd-popular-placeholder {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #94a3b8;
  font-size: 18px;
  background: linear-gradient(135deg, #f8fafc, #e2e8f0);
}

.potensi-detail-page .bd-popular-num {
  position: absolute;
  left: 6px;
  bottom: 6px;
  min-width: 26px;
  height: 22px;
  border-radius: 7px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #0d5c42;
  background: rgba(240, 250, 245, 0.92);
  border: 1px solid rgba(214, 239, 225, 0.95);
  font-family: 'DM Mono', monospace;
  font-size: 11px;
  font-weight: 800;
  backdrop-filter: blur(10px);
}

.potensi-detail-page .bd-popular-title {
  color: #334155;
  font-size: 13.5px;
  font-weight: 800;
  line-height: 1.42;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.potensi-detail-page .bd-popular-link:hover .bd-popular-title {
  color: #0d5c42;
}

.potensi-detail-page .bd-empty {
  margin: 0;
  padding: 13px 14px;
  color: #64748b;
  background: #f8fafc;
  border: 1px dashed #cbd5e1;
  border-radius: 10px;
  font-size: 13px;
}

.potensi-detail-page .bd-share-section {
  margin-top: 30px;
  padding-top: 20px;
  border-top: 1px dashed #e2e8f0;
}

.potensi-detail-page .bd-share-label {
  display: block;
  font-size: 14px;
  font-weight: 700;
  color: #334155;
  margin-bottom: 12px;
}

.potensi-detail-page .bd-share-buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.potensi-detail-page .bd-share-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 16px;
  border-radius: 8px;
  font-size: 13px;
  font-weight: 600;
  text-decoration: none !important;
  color: #fff !important;
  border: none;
  cursor: pointer;
  transition: transform 0.15s, opacity 0.15s;
}

.potensi-detail-page .bd-share-btn:hover {
  transform: translateY(-1px);
  opacity: 0.95;
}

.potensi-detail-page .bd-share-btn.facebook {
  background: #1877f2;
}

.potensi-detail-page .bd-share-btn.twitter {
  background: #0f1419;
}

.potensi-detail-page .bd-share-btn.whatsapp {
  background: #25d366;
}

.potensi-detail-page .bd-share-btn.copy-link {
  background: #64748b;
}

@media (max-width: 1024px) {
  .potensi-detail-page .bd-layout {
    grid-template-columns: 1fr;
  }

  .potensi-detail-page .bd-sidebar {
    position: static;
  }
}

@media (max-width: 720px) {
  .potensi-card-media {
    aspect-ratio: 16 / 11;
  }

  .potensi-detail-page .bd-feature-image {
    height: 280px;
  }

  .potensi-detail-page .bd-feature-image img {
    padding: 0.5rem;
  }

  .potensi-detail-page .bd-related-grid {
    grid-template-columns: 1fr;
  }
}
