/* Personnalisation Bus de Cannes */

/* Conserver les proportions des images insérées dans le contenu. */
.field--name-body img {
  max-width: 100%;
  height: auto;
}

/* Bandeau supérieur inspiré du site de production. */
header[role="banner"] > nav.navbar {
  background-color: #1d84c3;
  background-image: linear-gradient(to bottom, #055a8e 0%, #1d84c3 100%);
  color: #ffffff;
}

header[role="banner"] > nav.navbar a {
  color: #ffffff;
}

/* Dimensions du bandeau supérieur. */
header[role="banner"] > nav.navbar {
  min-height: 88px;
  padding-top: 12px;
  padding-bottom: 12px;
}

/* Utiliser toute la largeur du bandeau. */
header[role="banner"] > nav.navbar > .d-flex {
  width: 100%;
}

/* Ajustement largeur colonne gauche / contenu sur grand écran. */
@media (min-width: 992px) {
  main[role="main"] .row > .order-2.order-lg-1 {
    width: 16%;
  }

  main[role="main"] .row > .order-1.order-lg-2 {
    width: 84%;
  }
}

/* Espacement plus compact des articles en mode teaser. */
.node--view-mode-teaser h2 {
  margin-bottom: 0.5rem;
}

.node--view-mode-teaser .node__meta {
  margin-bottom: 0.75rem;
}

.node--view-mode-teaser .node__content p {
  margin-bottom: 0.5rem;
}

.node--view-mode-teaser .links {
  margin-top: 0.25rem;
  margin-bottom: 0.75rem;
}

/* Espacement compact et uniforme des teasers de la page d'accueil. */
.views-row .node--view-mode-teaser h2 {
  margin-top: 0;
  margin-bottom: 0.35rem;
}

.views-row .node--view-mode-teaser .node__meta {
  margin: 0 0 0.5rem 0;
}

.views-row .node--view-mode-teaser .node__submitted {
  margin: 0;
}

.views-row .node--view-mode-teaser .node__content {
  margin: 0;
}

.views-row .node--view-mode-teaser .node__content p {
  margin: 0 0 0.4rem 0;
}

.views-row .node--view-mode-teaser .node__links {
  margin: 0 0 0.75rem 0;
}

.views-row .node--view-mode-teaser .links {
  margin: 0;
}

/* Pavés légers pour les blocs de la colonne gauche. */
@media (min-width: 992px) {
  main[role="main"] .order-2.order-lg-1 .block {
    background: #f7f7f4;
    border: 1px solid #eeeeea;
    padding: 1rem 1.25rem;
    margin-bottom: 1.25rem;
  }
}

/* Pavés des menus de la colonne gauche. */
@media (min-width: 992px) {
  .region-sidebar-first > nav,
  .region-sidebar-first > div {
    background: #f7f7f4;
    border: 1px solid #eeeeea;
    padding: 0.8rem 1rem;
    margin-bottom: 1.25rem;
  }
}

/* Pavé Accueil uniquement. */
main[role="main"] article.node--type-page.node--view-mode-teaser {
    background-color: #f7f7f5;
    border: 1px solid #e5e5e2;
    padding: 14px 16px;
    margin-bottom: 18px;
}

/* Resserrement autour de "Soumis par" dans les résumés. */
main[role="main"] article.node--view-mode-teaser .node__meta {
    margin-top: 6px;
    margin-bottom: 6px;
}

main[role="main"] article.node--view-mode-teaser .node__submitted {
    margin-top: 0;
    margin-bottom: 0;
}

/* Resserrement vertical des articles en mode résumé. */
main[role="main"] article.node--type-article.node--view-mode-teaser > h2 {
    margin-bottom: 8px;
}

main[role="main"] article.node--type-article.node--view-mode-teaser .node__meta {
    margin: 0 0 8px 0 !important;
}

main[role="main"] article.node--type-article.node--view-mode-teaser .node__content p {
    margin-top: 0;
    margin-bottom: 8px;
}

/* Resserrement final des résumés. */
main[role="main"] article.node--type-article.node--view-mode-teaser > h2 {
    margin-bottom: 2px !important;
}

main[role="main"] article.node--type-article.node--view-mode-teaser .node__meta {
    margin: 0 0 2px 0 !important;
}

main[role="main"] article.node--type-article.node--view-mode-teaser .node__content {
    margin-top: 0 !important;
}

/* Présentation du logo et du titre dans le bandeau. */
header[role="banner"] .site-logo img {
    width: 85px;
    height: auto;
}

header[role="banner"] .navbar-brand {
    gap: 16px;
}

header[role="banner"] .site-title {
    font-size: 28px;
    font-weight: 400;
    text-transform: none;
    letter-spacing: 0;
}

/* Slogan dans le bandeau */
.site-slogan {
  color: #fff;
  font-size: 1rem;
  font-style: italic;
  margin-top: 0.2rem;
}

/* Compatibilité anciens contenus Drupal (2019) */
.node__content figure.align-left,
.node__content figure.align-right {
  float: none;
  display: block;
  max-width: 100%;
  margin-left: 0;
  margin-right: 0;
}

.node__content figure img {
  max-width: 100%;
  height: auto;
}

/* Légendes des anciennes figures Drupal */
.node__content figure.align-left figcaption,
.node__content figure.align-right figcaption {
  display: block;
  width: 100%;
  max-width: 100%;
  float: none;
}

/* Ajustement typographie pour affichage à 100 % */
@media (min-width: 992px) {
  main[role="main"] h2 { font-size: 1.75rem; }
  main[role="main"] .sidebar h2, main[role="main"] aside h2 { font-size: 1.75rem; }
}

@media (min-width: 992px) {
  main[role="main"] .region-sidebar-first h2 { font-size: 1.5rem; }
}

@media (min-width: 992px) {
  #block-buscannes-page-title h1 { font-size: 2.25rem; }
}

/* Menu colonne gauche : plus compact */
@media (min-width: 992px) {
  main[role="main"] .region-sidebar-first .nav-link {
    font-size: 0.95rem;
    padding-top: 0.35rem;
    padding-bottom: 0.35rem;
  }
}

/* Menu colonne gauche : espacement final */
@media (min-width: 992px) {
  main[role="main"] .region-sidebar-first .nav-link {
    padding-top: 0.20rem;
    padding-bottom: 0.20rem;
  }
}
