/* ============================================================
   Château de Sénergues — intégration du brief (brief site.pdf)
   Palette issue du PDF : beige #BDB0A3, noir, blanc sur photos
   Police du PDF : Aptos (fallback system)
   ============================================================ */

:root {
  --white: #ffffff;
  --beige: #bdb0a3;
  --beige-dark: #a89a8c;
  --ink: #111111;
  --paper: #ffffff;
  --overlay: rgba(0, 0, 0, 0.45);
  --font: "Aptos", "Segoe UI", "Helvetica Neue", Arial, sans-serif;
  --container: 1140px;
  --radius: 4px;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--font);
  color: var(--ink);
  background: var(--paper);
  font-size: 17px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

img {
  display: block;
  max-width: 100%;
  height: auto;
}

a {
  color: inherit;
}

.container {
  width: min(var(--container), 92%);
  margin-inline: auto;
}

/* ---------- Éléments communs ---------- */

.label {
  font-size: 17px;
  font-weight: 700;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--beige);
  margin-bottom: 18px;
}

h1, h2, h3 {
  font-weight: 700;
  line-height: 1.15;
}

.section {
  padding: 110px 0;
}

.btn {
  text-align: center;
  display: inline-block;
  padding: 14px 34px;
  border-radius: var(--radius);
  font-size: 14px;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  text-decoration: none;
  border: 2px solid transparent;
  cursor: pointer;
  transition: background-color 0.2s ease, color 0.2s ease, border-color 0.2s ease;
  margin:auto;
}

.btn--beige {
  background: var(--beige);
  color: #1c1a17;
}

.btn--beige:hover {
  background: var(--beige-dark);
}

.btn--ghost {
  border-color: rgba(255, 255, 255, 0.85);
  color: #ffffff;
  background: rgba(49, 49, 49, 0.647);
}

.btn--ghost:hover {
  background: rgba(255, 255, 255, 0.15);
}

.btn--dark {
  background: var(--ink);
  color: #ffffff;
}

.btn--dark:hover {
  background: #333333;
}

.btn--dark.is-copied {
  background: #2e7d32;
}

.btn--small {
  padding: 10px 22px;
  font-size: 12px;
}

.btn--large {
  padding: 18px 48px;
  font-size: 16px;
}

/* ---------- Hero ---------- */

.hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  color: #ffffff;
  background: url("img/hero.png") center / cover no-repeat #2b2b2b;
}

.hero__overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    to bottom,
    rgba(0, 0, 0, 0.55) 0%,
    rgba(0, 0, 0, 0.25) 40%,
    rgba(0, 0, 0, 0.55) 100%
  );
}

.fixed{
  background: rgb(246, 246, 246);
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 999;
  box-shadow: 0 0 10px rgba(0, 0, 0, 0.40);
}

.nav {
  position: relative;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: 14px;
  padding-bottom: 14px;
}
.nav__logo{
  text-decoration:none;
    display: inline-flex;
    text-decoration: none;
    align-items: center;
}
.nav__logo span{
  color:#121212;
  font-weight:700;
  margin-left:8px;
}

.nav__logo img {
  width: 40px;
  height: auto;
}

.nav__links {
  display: flex;
  align-items: center;
  gap: 28px;
}

.nav__links a:not(.btn) {
  color: #0f0f0f;
  text-decoration: none;
  font-size: 15px;
  font-weight: 600;
  letter-spacing: 0.04em;
}

.nav__links a:not(.btn):hover {
  color: var(--black);
  text-decoration: underline;
  text-underline-offset: 3px;
}

.hero__content {
  position: relative;
  z-index: 2;
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 64px 0 96px;
}

.hero__taglines {
  font-size: 22px;
  line-height: 1.55;
  margin-bottom: 28px;
  text-shadow: 0 1px 8px rgb(0, 0, 0);
}

.hero__title {
  font-size: clamp(2.4rem, 6vw, 4.6rem);
  text-transform: uppercase;
  letter-spacing: 0.02em;
  text-shadow: 0 2px 14px rgba(0, 0, 0, 0.55);
  margin-bottom: 40px;
}

.hero__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
}

/* ---------- Notre histoire ---------- */

.histoire__grid {
  display: grid;
  grid-template-columns: 0.8fr 1.2fr;
  gap: 64px;
  align-items: center;
}

.histoire h2 {
  font-size: clamp(1.6rem, 3vw, 2.2rem);
  margin-bottom: 24px;
}

.histoire__text p {
  margin-bottom: 18px;
  /*max-width: 56ch;*/
}

.histoire__video {
  margin-top: 8px;
}

.link-video {
  color: var(--beige-dark);
  font-weight: 600;
  text-decoration: underline;
  text-underline-offset: 3px;
}

.link-video:hover {
  color: var(--ink);
}

.histoire__media img,
.histoire__media video {
  width: 100%;
  border-radius: var(--radius);
  box-shadow: 0 18px 40px rgba(0, 0, 0, 0.18);
  background: #1c1a17;
}

/* ---------- Le projet ---------- */

.projet {
  background: #faf8f6;
}

.projet h2 {
  font-size: clamp(1.7rem, 3.2vw, 2.4rem);
  margin-bottom: 20px;
}

.projet__intro {
  max-width: 72ch;
  margin-bottom: 48px;
}

.projet__intro strong {
  font-weight: 700;
}

.projet__gallery,
.projet__gallery2 {
  display: grid;
  grid-template-columns: 1.6fr 1fr;
  gap: 20px;
  margin-bottom: 20px;
  align-items: stretch;
}

/* aspect-ratio sur le bloc principal = hauteur de référence pour toute
   la ligne du grid (Safari inclus). Les images en absolute inset:0
   remplissent ensuite le conteneur sans calcul de pourcentage. */
.projet__gallery-main {
  position: relative;
  aspect-ratio: 8 / 5;
  overflow: hidden;
  border-radius: var(--radius);
}

.projet__gallery-main img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.projet__gallery-side {
  display: grid;
  grid-template-columns: 1fr 1fr;
  grid-auto-rows: 1fr;
  gap: 20px;
}

/* Chaque tuile carrée force la hauteur de la colonne de droite,
   le grid parent étire ensuite le bloc principal à la même hauteur. */
.projet__gallery-side img {
  width: 100%;
  aspect-ratio: 1 / 1;
  object-fit: cover;
  border-radius: var(--radius);
}

.projet__gallery-side2 {
  display: grid;
  grid-template-rows: 1fr 1fr;
  gap: 20px;
}

.projet__gallery-side2 > * {
  position: relative;
  overflow: hidden;
  border-radius: var(--radius);
}

.projet__gallery-side2 img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.projet__banner {
  margin-top: 20px;
}

.projet__banner img {
  width: 100%;
  max-height: 420px;
  object-fit: cover;
}

/* ---------- Faites un don (blocs de la bannière) ---------- */

.don {
  padding-bottom:20px;
}

.don__head {
  text-align: center;
}

.don__title {
  font-size: clamp(2rem, 5vw, 3.4rem);
  text-transform: uppercase;
  letter-spacing: 0.02em;
}

.don__subtitle {
  font-size: clamp(1.1rem, 2.2vw, 1.5rem);
  font-weight: normal;
  margin-top: 10px;
  color:var(--beige);
}

.don__blocks {
  padding: 72px 0;
}

.don__grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 28px;
}

.don-card {
  text-align:left;
  background: rgb(227 223 216);
  border-radius: var(--radius);
  padding: 36px;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 18px;
  box-shadow: 0 14px 34px rgba(0, 0, 0, 0.18);
}

.don-card__brand {
  font-size: 15px;
  font-weight: 800;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  padding: 12px 0 12px 0;
}

.don-card__text {
  font-size: 18px;
  text-align: left;
}

.don-card__highlight {
  font-size: 18px;
  font-weight: 700;
}

.don-card__small {
  font-size: 12.5px;
  line-height: 1.5;
  color: #5c564f;
}

.form-msg {
  font-size: 14px;
  margin: 0;
  min-height: 1.2em;
}

.form-msg--ok {
  color: #2e7d32;
  font-size:18px;
}

.form-msg--err {
  color: #e2451a;
  font-size:18px;
}

.loader {
  display: inline-block;
  width: 14px;
  height: 14px;
  margin-right: 8px;
  vertical-align: -2px;
  border: 2px solid rgba(255, 255, 255, 0.35);
  border-top-color: #ffffff;
  border-radius: 50%;
  animation: loader-spin 0.7s linear infinite;
}

.loader[hidden] {
  display: none;
}

@keyframes loader-spin {
  to {
    transform: rotate(360deg);
  }
}

.form-consent {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  font-size: 13px;
  line-height: 1.4;
  color: #5c564f;
  cursor: pointer;
}

.form-consent input {
  margin-top: 2px;
  accent-color: #a2482f;
  flex-shrink: 0;
}

.btn--terracotta {
  background: #a2482f;
  color: #ffffff;
}

.btn--terracotta:hover {
  background: #8a3a24;
}

.btn--green {
  background: #3e503a;
  color: #ffffff;
}

.btn--green:hover {
  background: #324129;
}

/* ---------- Partage ---------- */

.partage{
  padding-top:30px;
}

.partage__inner {
  max-width: 760px;
  text-align: center;
}

.partage h2 {
  font-size: clamp(1.5rem, 3vw, 2.1rem);
  margin-bottom: 20px;
}

.partage p {
  margin-bottom: 32px;
}

/* ---------- CTA final ---------- */

.cta {
  position: relative;
  color: #ffffff;
  background: url("img/cta.jpg") center / cover no-repeat fixed #2b2b2b;
  text-align: center;
}

.cta__overlay {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.55);
}

.cta__content {
  position: relative;
  z-index: 2;
  padding: 120px 0;
  display: flex;
  flex-direction: column;
  align-items: center;
}
.cta__content2 {
  position: relative;
  z-index: 2;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.cta__tagline {
  font-size: 19px;
  margin-bottom: 24px;
  text-shadow: 0 1px 8px rgba(0, 0, 0, 0.6);
}

.cta__title {
  font-size: clamp(2rem, 5vw, 3.8rem);
  text-transform: uppercase;
  letter-spacing: 0.02em;
  text-shadow: 0 2px 14px rgba(0, 0, 0, 0.6);
  margin-bottom: 44px;
}

.cta__share {
  margin-top: 72px;
}

.cta__share-title {
  font-size: clamp(1.2rem, 2.4vw, 1.6rem);
  font-weight: 700;
  line-height: 1.4;
  margin-bottom: 24px;
}
.socials {
  list-style: none;
  display: flex;
  justify-content: center;
  gap: 14px;
  margin-bottom: 40px;
}

.socials a {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  border: 1.5px solid rgba(0, 0, 0, 0.8);
  color: #000000;
  transition: background-color 0.2s ease, color 0.2s ease, border-color 0.2s ease;
}

.socials a:hover {
  background: var(--beige);
  border-color: var(--beige);
  color: #1c1a17;
}

.cta__logo {
  width: 180px;
  height: auto;
  margin-top: 8px;
}

/* ---------- Footer ---------- */

.footer {
  background: #1c1a17;
  color: #d8d2cb;
  padding: 56px 0 32px;
  text-align: center;
}

.footer__logo {
  width: 140px;
  margin: 0 auto 20px;
}

.footer__links {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 24px;
  margin: 18px 0;
}

.footer__links a {
  color: #ffffff;
  text-decoration: none;
  font-size: 14px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.footer__links a:hover {
  color: var(--beige);
}

.footer__copy {
  font-size: 13px;
  color: #9b948c;
  margin-top: 24px;
}

/* ---------- Responsive ---------- */

@media (max-width: 860px) {
  .section {
    padding: 64px 0;
  }

  .nav__links {
    gap: 16px;
  }

  .nav__links a:not(.btn) {
    display: none;
  }

  .histoire__grid,
  .projet__gallery,
  .projet__gallery2,
  .don__grid {
    grid-template-columns: 1fr;
  }

  .don__blocks {
    padding: 48px 0;
  }

  .don-card {
    padding: 26px;
  }

  .projet__gallery-main {
    aspect-ratio: 4 / 3;
    width: 100%;
  }

  .projet__gallery-side {
    grid-template-columns: 1fr 1fr;
  }

  .projet__gallery-side img {
    aspect-ratio: 1 / 1;
  }

  /* side2 empilé en pleine largeur : chaque bloc a son propre ratio
     pour que les images en absolute aient un conteneur haut */
  .projet__gallery-side2 {
    grid-template-rows: none;
    grid-template-columns: 1fr;
  }

  .projet__gallery-side2 > * {
    aspect-ratio: 4 / 3;
  }

  .cta {
    background-attachment: scroll;
  }
}
.margin-t-20{
  margin-top:20px;
}

.fondation-logo{
  text-decoration:none;
  display:inline-flex;
  vertical-align:middle;
  align-items:center;
}

.don__full_grid{
  display:grid;
  grid-template-columns:1fr;
  gap:28px;
  align-items:center;
}
.don__full_grid .don-card{
  text-align:center;
}

.don__full_grid form{
  align-self:center;
  text-align:center;
}

.don__full_grid form .btn{
  margin-bottom:8px;

}

input[type="text"],
input[type="email"]{
  width:100%;
  padding:12px 16px;
  border-radius:var(--radius);
  border:1px solid #ccc;
  font-size:14px;
  margin-bottom:16px;
}

.form-consent{
  display:flex;
  align-items:flex-start;
  gap:8px;
  font-size:16px;
  line-height:1.4;
  color:#5c564f;
  cursor:pointer;
  margin-bottom:16px;
}

input[type="checkbox"]{
  width:18px;
  height:18px;
  margin-top:2px;
  margin-right:8px;
  accent-color: #a2482f;
  cursor:pointer;
}

/* ---------- Lightbox (popin galerie) ---------- */

/* Hover sur l'img (c'est elle qui reçoit clic + focus clavier via le JS).
   box-shadow supprimé : il était rogné par overflow:hidden du conteneur
   sur Safari. Un léger zoom à la place, coupé proprement par le parent. */
.projet__gallery img,
.projet__gallery2 img {
  cursor: zoom-in;
  transition: transform 0.25s ease, filter 0.25s ease;
}

.projet__gallery img:hover,
.projet__gallery2 img:hover {
  transform: scale(1.03);
  filter: brightness(1.05);
}

.projet__gallery img:focus-visible,
.projet__gallery2 img:focus-visible {
  outline: 3px solid var(--beige-dark);
  outline-offset: 2px;
}

.lightbox {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 1000;
  align-items: center;
  justify-content: center;
}

.lightbox.is-open {
  display: flex;
}

.lightbox__overlay {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.85);
}

.lightbox__content {
  position: relative;
  z-index: 2;
  max-width: min(1100px, 92vw);
  display: flex;
  flex-direction: column;
  align-items: center;
}

.lightbox.is-open .lightbox__content {
  animation: lightbox-in 0.2s ease;
}

@keyframes lightbox-in {
  from {
    opacity: 0;
    transform: scale(0.97);
  }
  to {
    opacity: 1;
    transform: none;
  }
}

.lightbox__img {
  max-width: 100%;
  max-height: 80vh;
  object-fit: contain;
  border-radius: var(--radius);
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.5);
  background: #1c1a17;
}

.lightbox__caption {
  color: #f0ece7;
  margin-top: 14px;
  font-size: 15px;
  text-align: center;
  max-width: 70ch;
}

.lightbox__close {
  position: absolute;
  top: 18px;
  right: 22px;
  z-index: 3;
  width: 44px;
  height: 44px;
  border: none;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.12);
  color: #ffffff;
  font-size: 28px;
  line-height: 1;
  cursor: pointer;
  transition: background-color 0.2s ease;
}

.lightbox__close:hover {
  background: rgba(255, 255, 255, 0.28);
}

.lightbox__nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  z-index: 3;
  width: 48px;
  height: 48px;
  border: none;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.12);
  color: #ffffff;
  font-size: 30px;
  line-height: 1;
  cursor: pointer;
  transition: background-color 0.2s ease;
}

.lightbox__nav:hover {
  background: rgba(255, 255, 255, 0.28);
}

.lightbox__nav--prev {
  left: 18px;
}

.lightbox__nav--next {
  right: 18px;
}

@media (max-width: 860px) {
  .lightbox__nav {
    width: 40px;
    height: 40px;
    font-size: 24px;
  }

  .lightbox__nav--prev {
    left: 8px;
  }

  .lightbox__nav--next {
    right: 8px;
  }

  .lightbox__close {
    top: 10px;
    right: 12px;
  }

  .lightbox__img {
    max-height: 72vh;
  }
}

.asteriks{
  width:100%;
  display:block;
  font-size: 12px;
  text-align:center;
}

.fondation-logo-hero{
  width:180px;
  margin-right:0;
  margin-left:auto;
  background-color:white;
  padding:6px 12px;
  display:inline-block;
}

.fondation-logo-hero-container{
  text-align:right;
  position:absolute;
  bottom:20px;
  right:20px;
}