/* Thème Pelican BATMAN : reprise du thème Drupal "aegan" (Quilltez), variante bleue.
   Autonome : pas de Bootstrap, pas de police distante. */

/* ---------- Base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: #eee url('../images/swirl-bg.png');
  font-family: 'Roboto', 'Helvetica Neue', Helvetica, Arial, sans-serif;
  font-size: 14px;
  line-height: 2em;
  color: #444;
}
h1, h2, h3, h4, h5, h6 {
  font-family: inherit;
  font-weight: 500;
  line-height: 1.1;
  margin: 20px 0 10px;
  color: #31B0D5;
}
h1 { font-size: 1.8em; }
h2 { font-size: 1.6em; }
h3 { font-size: 1.5em; }
h4 { font-size: 1.4em; }
h5 { font-size: 1.2em; }
h6 { font-size: 1em; }
h1 a, h2 a, h3 a, h4 a, h5 a, h6 a { color: #31B0D5; }
h1 a:hover, h2 a:hover, h3 a:hover, h4 a:hover, h5 a:hover, h6 a:hover { color: #5bc0de; }
p { margin: 0 0 10px; }
a { color: #005983; text-decoration: none; }
a:hover, a:focus, a:active { color: #003954; text-decoration: none; }
img { max-width: 100%; height: auto; vertical-align: middle; border: 0; }
hr { border: 0; border-top: 1px solid #555; margin: 20px 0; }
ul, ol { margin-top: 0; margin-bottom: 10px; }
.visually-hidden {
  position: absolute !important; width: 1px; height: 1px; overflow: hidden;
  clip: rect(1px, 1px, 1px, 1px); white-space: nowrap;
}
.skip-link:focus {
  position: static !important; width: auto; height: auto; clip: auto;
}
.align-center { display: block; margin-left: auto; margin-right: auto; }
.align-left { float: left; margin-right: 10px; }
.align-right { float: right; margin-left: 10px; }
.clearfix::after { content: ""; display: table; clear: both; }

/* ---------- Conteneur (équivalent .container Bootstrap 3) ---------- */
#page-wrapper {
  width: 100%;
  max-width: 1170px;
  margin: 0 auto;
  background-color: #fff;
}

/* ---------- En-tête ---------- */
#header-region {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 20px;
  padding: 20px;
}
#branding { display: flex; align-items: center; }
.site-logo img { height: 50px; width: auto; }
#sitename { margin-left: 10px; }
#sitename h2 { margin: 0; font-size: 1.6em; }
#site-slogan { margin: 0; line-height: 1.5em; }
.region-header-right img { display: block; }
.region-header-right p { display: none; }

/* ---------- Menu principal ---------- */
.navbar { background-color: #000; position: relative; z-index: 500; }
.navbar-toggle {
  display: none;
  margin: 8px 15px;
  padding: 9px 10px;
  border: 0;
  border-radius: 4px;
  background-color: #31B0D5;
  cursor: pointer;
}
.navbar-toggle .icon-bar {
  display: block; width: 22px; height: 2px; border-radius: 1px; background: #fff;
}
.navbar-toggle .icon-bar + .icon-bar { margin-top: 4px; }
.nav {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
}
.nav > li { border-right: 1px solid #333; }
.nav > li > a {
  display: block;
  padding: 10px 15px;
  line-height: 20px;
  color: #fff;
  text-transform: uppercase;
}
.nav > li > a:hover,
.nav > li > a:focus,
.nav > li > a.is-active {
  background-color: #31B0D5;
  color: #fff;
}

/* ---------- Corps : barre latérale + contenu ---------- */
#breadcrumb-region { padding: 20px; }
#main {
  display: flex;
  align-items: flex-start;
  padding: 20px 0;
}
#sidebar-first { flex: 0 0 25%; max-width: 25%; padding: 0 15px; }
#content { flex: 0 0 75%; max-width: 75%; padding: 0 15px; min-width: 0; }

.block { margin-bottom: 20px; }
.block .headline {
  display: block;
  margin: 10px 0 25px 0;
  border-bottom: 1px dotted #31B0D5;
}
.block .block-title {
  display: inline-block;
  margin: 0 0 -2px 0;
  padding-bottom: 5px;
  font-size: 1.3em;
  text-transform: uppercase;
  border-bottom: 2px solid #31B0D5;
}

.sidebar .block { border: 1px solid #000; }
.sidebar .headline { margin-top: 0; padding: 10px; background-color: #000; }
.sidebar .block-title {
  display: block;
  text-align: center;
  border: none;
  padding: 0;
  margin: 0;
  color: #fff;
}
.sidebar .block-content { padding: 0 10px 10px; }
.sidebar .views-row { padding: 2px 0; }

.page-title { margin-top: 0; }

/* ---------- Articles (teasers et pleine page) ---------- */
.node--view-mode-teaser {
  padding-bottom: 20px;
  border-bottom: 5px solid #ccc;
  margin-bottom: 20px;
}
.node--view-mode-teaser h2 { margin-top: 0; }
.node__meta { margin-bottom: 10px; color: #888; }
.node__links { list-style: none; margin: 10px 0 0; padding: 0; }
.node__links li { display: inline-block; padding: 0 10px 0 0; }
.node__links li a {
  padding: 5px;
  border-radius: 5px;
  background-color: #000;
  color: #fff;
}
.node__links li a::before {
  content: "\203A";
  color: #31B0D5;
  margin-right: 5px;
  font-weight: bold;
}
.node__links li a:hover { color: #5bc0de; }
.field--tags { margin-top: 15px; }
.field--tags .field__label { font-weight: bold; margin-right: 10px; }
.field--tags a { margin-right: 5px; }

/* Pagination */
.pager { list-style: none; padding: 0; margin: 20px 0; text-align: center; }
.pager li { display: inline-block; }
.pager li > a, .pager li > span {
  display: inline-block;
  padding: 15px 10px;
  line-height: 0;
  border: 1px solid #ddd;
  background-color: #fff;
}
.pager .is-active > span { background-color: #eee; }

/* ---------- Tableaux ---------- */
table {
  border-collapse: collapse;
  border-spacing: 0;
  margin-bottom: 15px;
  width: 100%;
  border: 1px solid #000;
}
th, tr, td { vertical-align: middle; }
tr:nth-child(odd) { background: #fff; }
tr:nth-child(even) { background: #d8d8d8; }
th { padding: 10px; background-color: #003954; color: #fff; }
th a, th a:hover { color: #fff; }
td { padding: 10px; }

/* ---------- Pied de page ---------- */
#footer {
  padding: 20px;
  background-color: #000;
  color: #fff;
}
#footer img { display: block; margin: 0 auto; }
#footer a { color: #31B0D5; }
#footer a:hover { color: #5bc0de; }
.credits { font-size: 0.9em; }

/* ---------- Retour en haut ---------- */
.btn-btt {
  position: fixed;
  right: 25px;
  bottom: 25px;
  z-index: 9999;
  width: 36px;
  height: 36px;
  line-height: 36px;
  text-align: center;
  border-radius: 50%;
  background-color: #31B0D5;
  color: #fff;
  font-size: 18px;
  box-shadow: 0 2px 10px rgba(0,0,0,.3), 0 0 1px rgba(0,0,0,.1),
              inset 0 1px 0 rgba(255,255,255,.25), inset 0 -1px 0 rgba(0,0,0,.15);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.5s;
}
.btn-btt.visible { opacity: 1; pointer-events: auto; }
.btn-btt:hover, .btn-btt:focus { color: #fff; background-color: #5bc0de; }

/* ---------- Mobile (< 768 px) ---------- */
@media (max-width: 767px) {
  #header-region { justify-content: center; }
  .navbar-toggle { display: block; }
  .nav { display: none; flex-direction: column; }
  .nav.open { display: flex; }
  .nav > li { border-right: none; border-top: 1px solid #333; }
  #main { flex-direction: column-reverse; }
  #sidebar-first, #content { flex: 1 1 100%; max-width: 100%; width: 100%; }
}
