/* =========================
   Base / helpers
========================= */
:root {
  --green: #7BA428;
  --dark: #333;
  --light: #fff;
  --bg: #eee;
  --border: #ddd;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  background: var(--bg) url("assets/header_outer.jpg") repeat-x;
  color: var(--dark);
  font-family: Arial, Helvetica, sans-serif;
  font-size: 15px;
}

a:link, a:visited { color: var(--green); }
a:hover, a:active, a:focus {
  background: #669933;
  color: #fff;
  text-decoration: none;
}

.sr-only {
  position: absolute;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0,0,0,0);
  white-space: nowrap; border: 0;
}

/* =========================
   Layout wrapper (remplace beez5 layout.css)
========================= */
#all { border: 0 !important; }
#back { padding-bottom: 20px; }

#header,
#contentarea,
#footer-sub {
  max-width: 1030px;
  margin: 0 auto;
}

/* =========================
   Header
========================= */
#header { background: #fff; }

.logoheader {
  border-top: 0;
  background: #fff;
  color: #555;
}

h1#logo {
  margin: 0.5em 20px 10px 20px;
  font-size: 3em;
}

#logo span {
  color: #555 !important;
  margin-top: 6px;
  font-size: 0.4em !important;
  letter-spacing: 1px;
}

#header-image {
  min-height: 20px;
  background: #eee;
  padding: 0;
}
#header-image img {
  width: 100%;
  height: auto;
  display: block;
}

/* Skiplinks */
#header ul.skiplinks {
  width: 100%;
  text-align: left;
  background: none;
  padding: 0;
  margin: 0;
  list-style: none;
}
.skiplinks li { display: inline; }
#header ul.skiplinks li a.u2 {
  position: absolute;
  left: -9999px;
  top: 0;
}
#header ul.skiplinks li a.u2:focus,
#header ul.skiplinks li a.u2:active {
  left: 10px !important;
  top: 0px !important;
  z-index: 999999 !important;
  display: block;
  width: 14em;
  padding: 8px 10px;
  background: #333 !important;
  color: #fff !important;
  border: 1px solid #fff;
}

/* Menu */
#header ul.menu {
  margin: 0 !important;
  padding: 0;
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 0;
  background: linear-gradient(to bottom, #f8f8f8, #e8e8e8);
  border-top: 3px solid var(--green);
  border-bottom: 2px solid #ccc;
  box-shadow: 0 2px 5px rgba(0,0,0,0.1);
}

#header ul.menu li { 
  border: 0;
  flex: 1 1 auto;
  text-align: center;
}

#header ul.menu li a:link,
#header ul.menu li a:visited {
  display: block;
  color: #333;
  background: transparent;
  padding: 12px 8px;
  font-weight: bold;
  text-transform: uppercase;
  font-size: 0.75em;
  letter-spacing: 0.5px;
  transition: all 0.3s ease;
  border-right: 1px solid #d5d5d5;
  text-decoration: none;
}

#header ul.menu li:last-child a {
  border-right: 0;
}

#header ul.menu li a:hover,
#header ul.menu li a:active,
#header ul.menu li a:focus {
  color: #fff;
  background: var(--green);
  transform: translateY(-2px);
  box-shadow: 0 3px 8px rgba(0,0,0,0.15);
  text-decoration: none;
}

#header ul.menu li.active a:link,
#header ul.menu li.active a:visited {
  color: #fff;
  background: var(--green);
  border-right: 1px solid #6a9320;
  box-shadow: inset 0 2px 4px rgba(0,0,0,0.2);
  text-decoration: none;
}

/* line: font + search */
#line {
  text-align: right;
  margin-top: 15px;
  margin-bottom: 10px;
  padding: 0 20px;
  display: flex;
  justify-content: flex-end;
  gap: 12px;
  align-items: center;
  flex-wrap: wrap;
}

#fontsize { color: #444; display: inline-flex; gap: 6px; }

.font-btn {
  border: 1px solid #ddd;
  background: #f5f5f5;
  color: #444;
  padding: 6px 10px;
  cursor: pointer;
}
.font-btn:hover { background: #555; color: #fff; }

.search { display: inline-flex; gap: 6px; align-items: center; }
.search .inputbox {
  background: #fff !important;
  border: 1px solid #ccc;
  padding: 7px 10px;
}
.search .inputbox:focus { border: 2px solid #000; outline: none; }

.search .button {
  border: 1px solid #999;
  background: #664335 url("assets/searchbutton.png");
  color: #fff;
  padding: 7px 10px;
  cursor: pointer;
}

/* =========================
   Content
========================= */
#contentarea {
  background: #fff url("assets/box1.png") repeat-x;
  padding: 15px 20px 30px;
}

#breadcrumbs { color: #555; margin-bottom: 10px; }
#breadcrumbs .breadcrumbs { font-size: 0.95rem; }
#breadcrumbs span a:link,
#breadcrumbs span a:visited {
  background: #fff;
  color: var(--green);
}
#breadcrumbs span a:hover,
#breadcrumbs span a:active,
#breadcrumbs span a:focus {
  background: var(--green);
  color: #fff;
}

#main { min-height: 300px; }

#main h1 {
  color: #444;
  border-bottom: 1px solid #ddd;
  font-family: Arial, Helvetica, sans-serif; /* si tu veux Titillium Maps, mets la font en assets */
  font-size: 1.25rem;      /* au lieu d'un énorme h1 */
  line-height: 1.35;
  margin: 10px 0;
  border-bottom: 1px solid #ddd;
}

#main h2 {
  color: var(--green);
  font-family: Arial, Helvetica, sans-serif;
  font-size: 1.05rem;
  line-height: 1.35;
  margin: 14px 0 10px;
}

.item-page h2 a { color: var(--green); }
.item-page h2 a:hover { color: #fff !important; }

/* Paragraphes avec espacement */
#main p {
  margin: 3em 0;
}

/* Espacement pour les br */
br {
  display: block;
  content: "";
  margin: 0.5em 0;
}

/* Google Maps iframe */
iframe[src*="google.com/maps"] {
  border: 2px solid var(--border);
  border-radius: 8px;
  box-shadow: 0 4px 6px rgba(0,0,0,0.1);
}

/* =========================
   Photo Gallery
========================= */
.photo-gallery {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
  gap: 20px;
  margin: 30px 0;
  padding: 0;
}

.photo-item {
  position: relative;
  overflow: hidden;
  border-radius: 8px;
  box-shadow: 0 2px 8px rgba(0,0,0,0.1);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  background: #f5f5f5;
  cursor: pointer;
  animation: photoFadeIn 0.5s ease forwards;
  opacity: 0;
}

@keyframes photoFadeIn {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.photo-item:hover {
  transform: translateY(-5px);
  box-shadow: 0 4px 16px rgba(0,0,0,0.2);
}

.photo-item img {
  width: 100%;
  height: 250px;
  object-fit: cover;
  display: block;
  transition: transform 0.3s ease;
}

.photo-item:hover img {
  transform: scale(1.05);
}

.photo-caption {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  background: rgba(0,0,0,0.7);
  color: #fff;
  padding: 8px 12px;
  font-size: 0.85em;
  text-align: center;
  opacity: 0;
  transition: opacity 0.3s ease;
}

.photo-item:hover .photo-caption {
  opacity: 1;
}

/* Lightbox */
.lightbox {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.9);
  z-index: 10000;
  justify-content: center;
  align-items: center;
  animation: fadeIn 0.3s ease;
}

.lightbox.active {
  display: flex;
}

@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

.lightbox-content {
  position: relative;
  max-width: 90%;
  max-height: 90%;
  animation: zoomIn 0.3s ease;
}

@keyframes zoomIn {
  from { transform: scale(0.8); }
  to { transform: scale(1); }
}

.lightbox-content img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  display: block;
}

.lightbox-close {
  position: absolute;
  top: -40px;
  right: 0;
  background: var(--green);
  color: #fff;
  border: none;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  font-size: 24px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.3s ease;
  font-weight: bold;
  line-height: 1;
}

.lightbox-close:hover {
  background: #669933;
  transform: rotate(90deg);
}

/* Bouton "Charger plus" */
.load-more-container {
  text-align: center;
  margin: 30px 0;
}

.load-more-btn {
  background: var(--green);
  color: #fff;
  border: none;
  padding: 12px 30px;
  font-size: 1em;
  border-radius: 5px;
  cursor: pointer;
  transition: all 0.3s ease;
  font-weight: bold;
}

.load-more-btn:hover {
  background: #669933;
  transform: translateY(-2px);
  box-shadow: 0 4px 8px rgba(0,0,0,0.2);
}

.load-more-btn:disabled {
  background: #ccc;
  cursor: not-allowed;
  transform: none;
}

/* =========================
   Footer
========================= */
#footer {
  background: #333 url("assets/tabs_back.png") repeat-x;
  color: #fff;
  padding: 14px 20px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
}
#footer a:link, #footer a:visited { color: #fff; }

.admin-btn {
  display: inline-block;
  padding: 8px 16px;
  background: rgba(255, 255, 255, 0.1);
  color: #fff;
  text-decoration: none;
  border-radius: 4px;
  font-size: 13px;
  border: 1px solid rgba(255, 255, 255, 0.2);
  transition: all 0.3s;
}

.admin-btn:hover {
  background: rgba(255, 255, 255, 0.2);
  border-color: rgba(255, 255, 255, 0.3);
  transform: translateY(-2px);
}

/* =========================
   Responsive
========================= */
@media (max-width: 700px) {
  #header ul.menu { padding: 0 10px; }
  #header ul.menu li a { border-right: 0; border-bottom: 1px solid #eee; }
  #line { justify-content: center; }
  
  iframe[src*="google.com/maps"] {
    height: 300px;
  }

  .photo-gallery {
    grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    gap: 10px;
  }

  .photo-item img {
    height: 150px;
  }

  .lightbox-content {
    max-width: 95%;
    max-height: 95%;
  }

  .lightbox-close {
    top: 10px;
    right: 10px;
    width: 35px;
    height: 35px;
    font-size: 20px;
  }
}

