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

html, body {
  height: 100%;
  font-family: Arial, sans-serif;
  background-color: #f9f9f9;
  overflow: hidden; /* pas de scroll */
}

/* ----- Header ----- */
header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: 60px;
  background-color: #f4f4f4;
  border-bottom: 2px solid #fff;
  box-shadow: 0 0px 0px rgba(0, 0, 0, 0.15);
  z-index: 1000;
  display: flex;
  align-items: center;
  padding: 0 20px;
}

.logo-container {
  display: flex;
  align-items: center;
  text-decoration: none;
  color: inherit;
}

header img {
  height: 40px;
  margin-right: 15px;
}

header h1 {
  font-size: 1.2rem;
  white-space: nowrap;
  color:#644013;
}

/* ----- Main ----- */
main {
  height: 100vh;
  display: flex;
  justify-content: center;
  align-items: flex-start;
  padding-top: 80px; /* 60px de header + 20px de marge */
}

/* ----- Grid ----- */
.grid {
  display: grid;
  gap: 10px;
  width: 85vmin;
  height: 85vmin;
  grid-template-columns: repeat(2, 1fr);
  grid-template-rows: repeat(2, 1fr);
}

/* ----- Grid items ----- */
.grid-item {
  background-color: #ddd;
  background-size: cover;
  background-position: center;
  position: relative;
  border-radius: 6px;
  overflow: hidden;
  cursor: pointer;
  transition: transform 0.3s ease, filter 0.3s ease;
  filter: grayscale(0);
  aspect-ratio: 1 / 1;
}

.grid-item:hover {
  transform: scale(1.02);
  filter: grayscale(100%);
}

/* Légende */
.caption {
  position: absolute;
  bottom: 0;
  width: 100%;
  background: rgba(0, 0, 0, 0.6);
  color: white;
  text-align: center;
  padding: 10px;
  opacity: 0;
  transition: opacity 0.4s ease;
  font-size: 1rem;
}

.grid-item:hover .caption {
  opacity: 1;
}
