body {
    margin: 0;
    font-family: "Overlock", cursive;
    background-image: linear-gradient(45deg, #7c9885, #b5b682);
    text-align: center;
    min-height:100vh;
}
#page {
	min-height:100vh;
	display:flex; 
	flex-direction:column;
}

#content {
	flex-grow: 1;
    justify-content: center;
}

#header {
    font-family: "Caveat", cursive;
    padding: 5px;
    text-align: center;
    background: #313b3f;
    color: white;
    font-size: 2em;
}
#header a {
    text-decoration: none;
    color: white;
} 
#header img {
     padding-left: 12px;
     padding-right: 12px;
} 
*, *::before, *::after {
    box-sizing: border-box;
}

article {
    --img-scale: 1.001;
    --title-color: black;
    position: relative;
    border-radius: 16px;
    border: 2px solid #4b6d4d;
    box-shadow: none;
    background: #fff;
    transform-origin: center;
    transition: all 0.4s ease-in-out;
    overflow: hidden;
}

article a::after {
    position: absolute;
    inset-block: 0;
    inset-inline: 0;
    cursor: pointer;
    content: "";
}

article h2 {
    margin: 10px 0 10px 0;
    font-size: 1.1rem;
    letter-spacing: 0.05em;
    color: var(--title-color);
    transition: color 0.3s ease-out;
}

figure {
    margin: 0;
    padding: 0;
    overflow: hidden;
}

article img {
    max-width: 100%;
    transform-origin: center;
    transform: scale(var(--img-scale));
    transition: transform 0.4s ease-in-out;
}

.article-body {
    padding: 12px;
}

article a {
    text-decoration: none;
    color: #28666e;
}

article a:focus {
    outline: 1px dotted #28666e;
}

article:has(:hover, :focus) {
    --img-scale: 1.1;
    --title-color: #28666e;
    box-shadow: rgba(0, 0, 0, 0.16) 0px 10px 36px 0px, rgba(0, 0, 0, 0.06) 0px 0px 0px 1px;
}

.cartes {
    display: grid;
    max-width: 900px;
    margin-inline: auto;
    padding-inline: 6px;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 24px;
}

@media screen and (max-width: 960px) {
  article {
    container: card/inline-size;
  }
  .article-body p {
    display: none;
  }
  .player-container {
      width: 340px;
  } 
}

@container card (min-width: 380px) {
    .carte-wrapper {
    display: grid;
    grid-template-columns: 100px 1fr;
    gap: 16px;
  }
  .carte-body {
    padding-left: 0;
  }
  figure {
    width: 100%;
    height: 100%;
    overflow: hidden;
  }
  figure img {
    height: 100%;
    aspect-ratio: 1;
    object-fit: cover;
  }
}

.grille1 {
    display: grid;
    grid-template-columns: repeat(auto-fill, 400px);
    gap: 10px;
    justify-content: center;
    margin-bottom: 10px;
}
.grille1 img {
    border-radius: 15px;
    border: 2px solid #4b6d4d;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.2);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.grille1 img:hover {
    transform: scale(1.03);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
}

.grille2 {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 10px;
    justify-content: center;
    margin-bottom: 10px;
    margin: 10px;
    border-radius: 15px;
}
.grille2 img {
    border-radius: 15px;
    border: 2px solid #4b6d4d;
}

.grille3 {
    margin-top: 10px;
    display: inline-block;
    padding: 10px;
    border: 2px solid #ccc;
    border-radius: 15px;
    box-shadow: 2px 2px 10px rgba(0, 0, 0, 0.2);
    background-color:  #f9fce0;
    font-size: 1.5rem;
    min-width: 340px;
    max-width: 900px;
    width: 80%;
    height: 80%;
}

.grille4 {
    display: grid;
    grid-template-columns: repeat(auto-fill, 500px);
    gap: 10px;
    justify-content: center;
    margin-bottom: 10px;
}

.grille-item {
    padding: 5px;
    border: 2px solid #4b6d4d;;
    border-radius: 15px;
    box-shadow: 2px 2px 10px rgba(0, 0, 0, 0.2);
    background-color:  #f9fce0;
}

#logo-lapeyriere {
    border-radius: 15px;
    border: 2px solid #4b6d4d;
    width: 100px;
    height: 100px;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.2);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

#logo-lapeyriere:hover {
    transform: scale(1.03);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
}

.df-ui-btn.df-ui-share {
    display: none;
}

.df-ui-btn.df-ui-download {
    display: none;
}

.df-ui-btn.df-ui-pagemode {
    display: none;
}

#footer {
    font-family: "Caveat", cursive;
    padding: 5px;
    text-align: center;
    background: #313b3f;
    color: white;
    font-size: 1.2rem;
    width: 100%;
}

.popup-overlay {
    display: none;
    position: fixed;
    top: 0; left: 0;
    width: 100%; height: 100%;
    background: rgba(0, 0, 0, 0.8);
    justify-content: center;
    align-items: center;
    z-index: 1000;
}

.popup-content {
    position: relative;
    width: 80%;
    max-width: 800px;
}

.popup-content video {
    width: 100%;
    height: auto;
    border-radius: 10px;
}

.close-btn {
    position: absolute;
    top: 10px; right: 10px;
    font-size: 24px;
    color: white;
    cursor: pointer;
}