
html {
  scroll-padding-top: 70px; /* Hauteur approximative du menu sticky */
  scroll-behavior: smooth;
}

.sticky-top {
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  background-color: rgba(var(--bs-tertiary-bg-rgb), 0.95) !important;
  z-index: 1030; /* Légèrement plus haut que Bootstrap par défaut pour éviter tout conflit */
}

@media (max-width: 991.98px) {
  .navbar-collapse {
    max-height: calc(100vh - 70px);
    overflow-y: auto;
  }
}

/* Badge calendrier */
.date-badge{min-width:86px; border:1px solid #dee2e6; border-radius:8px; background:#dcf2ff; padding:.35rem .5rem;}
.date-badge .weekday{font-size:.95rem; line-height:1.1; color:#6c757d; text-transform:capitalize;}
.date-badge .day{font-size:2.2rem; line-height:1; font-weight:700;}
.date-badge .month{font-size:.95rem; line-height:1.1; color:#6c757d; text-transform:capitalize;}

/* Adaptation des cartes pour le mode sombre (pour faire ressortir l'ombre) */
[data-bs-theme="dark"] .card {
    background-color: #2b3035; /* Un peu plus clair que le fond */
    border-color: rgba(255, 255, 255, 0.15);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.5);
}

/* Effet de survol premium sur toutes les cartes du site */
.card {
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.card:hover {
    transform: translateY(-3px);
    box-shadow: 0 6px 15px rgba(0, 0, 0, 0.15) !important;
}
[data-bs-theme="dark"] .card:hover {
    box-shadow: 0 6px 15px rgba(0, 0, 0, 0.6) !important;
}

/* Adaptation de l'encart date pour le mode sombre */
[data-bs-theme="dark"] .date-badge {
    background: #102a43; /* Bleu très foncé */
    border-color: #243b53;
}
[data-bs-theme="dark"] .date-badge .weekday,
[data-bs-theme="dark"] .date-badge .month {
    color: #9fb3c8; /* Gris clair bleuté */
}
/* Le jour prendra nativement la couleur blanche du texte global du mode sombre */
.date-status{margin-top:.35rem; font-weight:600;}
.navbar-brand img {object-fit: contain; border-radius: 4px;}
@media (max-width: 767px) {
  .table-responsive thead {
        display: none; /* Cache les entêtes du tableau sur mobile */
  }
  .table-responsive tbody tr {
    display: block;
    margin-bottom: 1rem;
    border: 1px solid #dee2e6;
    border-radius: 8px;
    padding: 0.5rem;
    background: #fff;
  }
  .table-responsive tbody td {
    display: block;
    text-align: left !important;
    border: none;
    padding: 0.25rem 0.5rem;
  }
  /* On force la colonne actions à s'afficher comme une barre d'outils en bas de la carte */
  .table-responsive td:last-child {
    border-top: 1px solid #eee;
    margin-top: 0.5rem;
    padding-top: 0.75rem;
    display: flex;
    justify-content: center;
    gap: 5px;
  }
}

/* Masque l'alerte de version obsolète de CKEditor */
.cke_notification_warning {
  display: none !important;
}

/*Affichage d'un Airs et partitions */
.tune-card {
  border: 1px solid #e9ecef;
  border-radius: 10px;
  box-shadow: 0 1px 6px rgba(0, 0, 0, .05);
  overflow: hidden;
}

.section-title { font-size:1rem; font-weight:700; margin:1rem .2rem .5rem; }

.file-list { display:grid; grid-template-columns:1fr; gap:.6rem; }
@media (min-width: 576px) { .file-list { grid-template-columns: 1fr 1fr; } }
@media (min-width: 992px) { .file-list { grid-template-columns: 1fr 1fr 1fr; } }

/* On transforme la carte en conteneur relatif pour le lien */
.file-card {
  border: 1px solid #edf2f7;
  border-radius: 8px;
  padding: .6rem .7rem;
  background: #fff;
  box-shadow: 0 1px 4px rgba(0,0,0,.03);
  transition: background 0.2s, border-color 0.2s; /* Transition douce */
  cursor: pointer; /* Indique que c'est cliquable */
  text-decoration: none !important; /* Enlève le soulignement du lien parent */
}

.audio-box {
  border:1px solid #edf2f7;
  border-radius:8px;
  padding:.6rem .7rem;
  background:#fff;
  box-shadow:0 1px 4px rgba(0,0,0,.03);
}

.file-name {
  font-size: .92rem;
  color: #343a40;
}
.file-icon { font-size:1.1rem; }
.file-card:hover {
  background: #f0f7ff; /* Couleur un peu plus bleutée au survol */
  border-color: #0d6efd;
}

.audio-title a {
  font-size:.9rem; font-weight:600; color:#0d6efd; text-decoration:none;
}
.audio-title a:hover { text-decoration:underline; }

.back-zone { margin-top:1rem; text-align:right; }

/* Liste des Airs et partitions --- */

/* Grille plus dense */
.tunes-grid { row-gap: .5rem; }

/* Bandeau gradient (selon priorité) */
.tune-head {
  display: flex; align-items: center; gap: .5rem;
  padding: .45rem .65rem;
  color: #fff; font-weight: 600; font-size: .95rem; line-height:1.1;
}

/* Gradients par priorité */
.tune-A { background: linear-gradient(90deg, #052c65 0%, #0a58ca 100%); color: #fff !important; } /* bleu foncé */
.tune-B { background: linear-gradient(90deg, #0d6efd 0%, #6ea8fe 100%); color: #fff !important; } /* bleu moyen */
.tune-C { background: linear-gradient(90deg, #9ec5fe 0%, #cfe2ff 100%); color: #052c65 !important; } /* bleu clair */

/* Icône compact */
.tune-icon { font-size: 1.1rem; opacity: .95; }

/* Corps compact */
.tune-body { padding: .6rem .7rem; }
.tune-title { margin: 0; font-size: .95rem; font-weight: 700; }
.tune-desc { margin: .25rem 0 .5rem; font-size: .85rem; color: #6c757d; line-height: 1.2; }

/* Bas de carte fin */
.tune-foot { display:flex; justify-content: space-between; align-items:center; padding: .5rem .7rem; border-top: 1px solid #f1f3f5; }
.tune-chip { width:8px; height:8px; border-radius: 50%; display:inline-block; }

/* Bouton "Voir" très compact */
.btn-voir { padding: .15rem .5rem; font-size: .8rem; }

/* Pagination compacte */

/* Animation pour le bouton menu (hamburger) */
@keyframes pulseMenu {
  0% { box-shadow: 0 0 0 0 rgba(13, 110, 253, 0.4); }
  70% { box-shadow: 0 0 0 10px rgba(13, 110, 253, 0); }
  100% { box-shadow: 0 0 0 0 rgba(13, 110, 253, 0); }
}
.pulse-menu {
  animation: pulseMenu 2.5s infinite;
}

/* Animation pour l'icône gâteau d'anniversaire */
@keyframes cakeBounce {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-3px); }
}
.animate-cake {
  display: inline-block;
  animation: cakeBounce 2s ease-in-out infinite;
}

/* Barre d'action centrée */
.actions-bar{display:flex;justify-content:center;align-items:center;gap:.5rem;flex-wrap:wrap;width:100%;margin-top:.5rem}

/* Halos d'ancienneté (Premium) - 3-4 ans: Bronze, 5-9 ans: Silver, 10+ ans: Gold */
.halo-gold { 
  box-shadow: 0 0 24px 8px rgba(255, 215, 0, 0.6) !important; 
  border: 4px solid #FFD700 !important; 
}
.halo-silver { 
  box-shadow: 0 0 24px 8px rgba(148, 163, 184, 0.7) !important; 
  border: 4px solid #94a3b8 !important; 
}
.halo-bronze { 
  box-shadow: 0 0 24px 8px rgba(205, 127, 50, 0.6) !important; 
  border: 4px solid #CD7F32 !important; 
}

/* Effet surélevé constant pour les membres avec halo */
.member-photo.halo-gold, .member-photo.halo-silver, .member-photo.halo-bronze,
.profile-photo.halo-gold, .profile-photo.halo-silver, .profile-photo.halo-bronze {
  transform: translateY(-5px);
  z-index: 5;
  transition: transform 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}