* {
  box-sizing: border-box;
}

html, body {
  margin: 0;
  min-height: 100%;
}

body {
  min-height: 100vh;
  background: #eee8dc;
  color: #3d352c;
  font-family: Georgia, "Times New Roman", serif;
  padding: 30px 18px;
}

.book {
  position: relative;
  width: min(1100px, 100%);
  min-height: 650px;
  margin: 0 auto;
  background: #fffdf8;
  border-radius: 8px;
  box-shadow: 0 12px 35px rgba(0, 0, 0, .16);
  overflow: hidden;
}

/* Une recette à la fois */
.recipe {
  display: none;
  min-height: 650px;
  grid-template-columns: 48% 52%;
}

.recipe.active {
  display: grid;
  animation: appear .35s ease;
}

@keyframes appear {
  from {
    opacity: 0;
    transform: translateX(20px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

.recipe-image {
  padding: 10px;
  display: flex;
flex-direction: column; 
  align-items: center;
  justify-content: center;
  background: #f4eee3;
 position: relative; 
}

/* NOUVEAU : titre flottant au-dessus de l'image */
.recipe-title {
  position: absolute;
  top: 0px;
  left: 10px;
  right: 10px;
  z-index: 2;
  margin: 0;
  padding: 14px 20px;
  background: rgba(61, 53, 44, 0.55);   /* fond brun semi-transparent, ajuste l'opacité à ton goût */
  color: #fffdf8;
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(1.3rem, 3vw, 2rem);
  font-weight: normal;
  text-align: center;
  border-radius: 4px;
  text-shadow: 0 1px 4px rgba(0,0,0,.4);
}

.image-frame {
  position: relative;
  display: inline-flex;
  max-width: 100%;
  max-height: 585px;
 flex-shrink: 0;
}

.recipe-image img {
  display: block;
  width: auto;
  height: auto;
  max-width: 100%;
  max-height: 585px;
  object-fit: contain;
  border-radius: 4px;
}

.recipe-text {
  padding: 55px clamp(35px, 6vw, 75px);
  overflow-y: auto;
}
.signature {
  text-align: center;
}
.adroite { text-align: right; }
.aumilieu {
  display: block;
  text-align: center;
}



.page-number {
  color: #9a8569;
  font-size: .85rem;
  letter-spacing: .12em;
  margin-bottom: 12px;
}

h1 {
  margin: 0 0 28px;
  font-size: clamp(2rem, 4vw, 3.2rem);
  font-weight: normal;
  line-height: 1.05;
}

h2 {
  margin: 22px 0 8px;
  font-size: 1.50rem;
  font-weight: bold;
  color: #806a50;
}

p {
  margin: 0 0 12px;
  font-size: 1.02rem;
  line-height: 1.25;
}
.recette
{
  margin: 12 0 8px;
  font-size: 0.9rem;
  line-height: 1.15;
}


/* Petites flèches */
.nav {
  position: absolute;
  bottom: 15px;
  width: 38px;
  height: 38px;
  border: 0;
  border-radius: 50%;
  background: rgba(255, 253, 248, .85);
  color: #c20e08;
  font-family: Georgia, serif;
  font-size: 28px;
  line-height: 32px;
  cursor: pointer;
  z-index: 5;
  opacity: .65;
  transition: opacity .2s, transform .2s;
}

.nav:hover,
.nav:focus-visible {
  opacity: 1;
  transform: scale(1.08);
}

.prev {
  left: 15px;
}

.next {
  right: 15px;
}

.nav:disabled {
  opacity: .15;
  cursor: default;
  transform: none;
}

/* Tablette et téléphone */
@media (max-width: 700px) {
  
  body {
.recipe-title {
    padding: 10px 14px;
    font-size: 1.1rem;
  }
    padding: 12px;
  }

  .book {
    min-height: 0;
  }

  .recipe,
  .recipe.active {
    grid-template-columns: 1fr;
    min-height: 0;
  }

  .recipe-image {
    height: 45vh;
    min-height: 260px;
    max-height: 430px;
    padding: 18px;
  }

  .recipe-text {
    padding: 30px 28px 65px;
    overflow: visible;
  }

  .recipe-image img {
    max-height: 100%;
  }

  h1 {
    font-size: 2rem;
  }

  p {
    font-size: 1rem;
  }

  .nav {
    bottom: 10px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .recipe.active {
    animation: none;
  }

  .nav {
    transition: none;
  }
}
