/* static/economic/resources/css/resources.css */

/* =========================================================
   Resources UI (Bootstrap-friendly)
   - légère, clean, compatible prod
   - gère : cards, badges, filtres, menu, et "disabled"
   ========================================================= */

/* ---------- Variables (optionnel) ---------- */
:root{
  --res-radius: 16px;
  --res-shadow: 0 8px 24px rgba(0,0,0,.08);
  --res-border: rgba(0,0,0,.08);
}

/* ---------- Liens "disabled" (utile quand URL absente en prod) ---------- */
a.disabled,
.nav-link.disabled,
.dropdown-item.disabled {
  pointer-events: none;
  opacity: .55;
  cursor: not-allowed;
  text-decoration: none !important;
}

/* ---------- Layout global de la section ---------- */
.resources-shell {
  min-height: 40vh;
}

/* ---------- Menu économique (resources) ---------- */
.navbar[aria-label*="Menu économique"]{
  -webkit-backdrop-filter: blur(6px);
  backdrop-filter: blur(6px);
}

.navbar .navbar-brand i {
  font-size: 1.05rem;
}

.navbar .nav-link {
  border-radius: 999px;
  padding: .45rem .8rem;
}

.navbar .nav-link.active {
  font-weight: 700;
}

/* Icons right zone */
.navbar .nav-link.position-relative i {
  font-size: 1.05rem;
}

/* badges (wishlist/cart) */
.navbar .badge.rounded-pill {
  font-size: .70rem;
  padding: .25rem .45rem;
}

/* ---------- Cards ---------- */
.card {
  border-radius: var(--res-radius);
  border-color: var(--res-border);
}

.card.shadow-sm {
  box-shadow: var(--res-shadow);
}

.card .card-title {
  line-height: 1.2;
}

.card .card-footer {
  background: transparent;
  border-top-color: var(--res-border);
}

/* ---------- Resource card specifics ---------- */
.resource-card .badge {
  border-radius: 999px;
  font-weight: 600;
}

.resource-card .card-text {
  margin-bottom: 1rem;
}

/* ---------- Buttons small polish ---------- */
.btn {
  border-radius: 999px;
}

.btn.btn-sm {
  padding: .35rem .75rem;
}

/* ---------- Filters (partials/_resource_filters.html) ---------- */
.resources-filters .form-control,
.resources-filters .form-select {
  border-radius: 14px;
}

.resources-filters .btn {
  border-radius: 14px;
}

/* ---------- Category pills (index categories quick filter) ---------- */
.resources-pills .btn {
  border-radius: 999px;
}

/* ---------- Detail page ---------- */
.resource-detail h1 {
  line-height: 1.25;
}

.resource-detail .lead {
  font-size: 1.05rem;
}

/* Documents list */
.resource-docs a {
  text-decoration: none;
}
.resource-docs a:hover {
  text-decoration: underline;
}

/* ---------- Dark mode (si ton site applique une classe, adapte si besoin) ---------- */
/* Si tu utilises data-bs-theme="dark" sur html/body, ceci marche direct */
[data-bs-theme="dark"] {
  --res-border: rgba(255,255,255,.12);
  --res-shadow: 0 10px 28px rgba(0,0,0,.35);
}

[data-bs-theme="dark"] .card,
[data-bs-theme="dark"] .navbar.bg-white {
  background-color: rgba(20,20,22,.92) !important;
}

[data-bs-theme="dark"] .navbar.bg-white .nav-link,
[data-bs-theme="dark"] .navbar.bg-white .navbar-brand {
  color: rgba(255,255,255,.92);
}

[data-bs-theme="dark"] .badge.bg-light {
  background: rgba(255,255,255,.10) !important;
  color: rgba(255,255,255,.92) !important;
  border: 1px solid rgba(255,255,255,.14) !important;
}

/* ---------- Responsive tweaks ---------- */
@media (max-width: 991.98px){
  .navbar .nav-link{
    border-radius: 12px;
  }
  .navbar .navbar-collapse{
    padding-top: .5rem;
  }
}
