/* 
   INDEX REVISTA HORIZONTAL - Versão de Luxo (Option A + C)
   Palette: #74060F (Red), #212D7B (Blue), #000000 (Black), #FFFFFF (White)
*/

@import url('https://fonts.googleapis.com/css2?family=Cormorant+Garamond:ital,wght@0,300;0,400;0,500;0,600;0,700;1,300;1,400;1,600&family=Manrope:wght@200;300;400;500;600;700&display=swap');

:root {
  --color-red: #74060F;
  --color-blue: #212D7B;
  --color-black: #000000;
  --color-white: #FFFFFF;
  --color-cream: #F5F2ED;
  
  --serif: 'Cormorant Garamond', serif;
  --sans: 'Manrope', sans-serif;
  
  --transition-smooth: all 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}

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

body {
  background-color: var(--color-cream);
  color: var(--color-black);
  font-family: var(--sans);
  overflow: hidden; /* We handle scroll via the horizontal container */
  -webkit-font-smoothing: antialiased;
}

/* --- HORIZONTAL CONTAINER --- */
.horizontal-container {
  display: flex;
  height: 100vh;
  width: 100vw;
  overflow-x: auto;
  overflow-y: hidden;
  scroll-snap-type: x mandatory;
  scroll-behavior: smooth;
  cursor: grab;
}

.horizontal-container:active {
  cursor: grabbing;
}

.horizontal-container::-webkit-scrollbar {
  height: 4px;
}

.horizontal-container::-webkit-scrollbar-track {
  background: var(--color-black);
}

.horizontal-container::-webkit-scrollbar-thumb {
  background: var(--color-red);
}

/* --- SECTIONS (SPREADS) --- */
.spread {
  flex: 0 0 100vw;
  height: 100vh;
  scroll-snap-align: start;
  position: relative;
  overflow: hidden;
  display: flex;
  flex-direction: row;
  align-items: stretch;
  justify-content: center;
  padding: 0;
}

.spread-wide {
  flex: 0 0 150vw; /* Double page spread */
}

/* --- SPLIT SCREEN IMAGE --- */
.spread-image {
  flex: 1;
  position: relative;
  height: 100vh;
  overflow: hidden;
}

.spread-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center top;
  transition: var(--transition-smooth);
}

.spread:hover .spread-image img {
  transform: scale(1.05);
}

/* --- TYPOGRAPHY --- */
h1, h2, h3 {
  font-family: var(--serif);
  font-weight: 300;
  line-height: 0.9;
}

.eyebrow {
  font-family: var(--sans);
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.4em;
  color: var(--color-red);
  margin-bottom: 2rem;
  display: block;
}

.display-title {
  font-size: clamp(3rem, 8vw, 8rem);
  text-transform: uppercase;
  font-style: italic;
  margin-bottom: 2rem;
  color: var(--color-black);
}

.spread-content {
  flex: 1;
  position: relative;
  z-index: 10;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 6rem;
  background-color: var(--color-cream);
}

.prose {
  font-size: 1.2rem;
  line-height: 1.6;
  font-weight: 400;
  max-width: 45ch;
  color: var(--color-black);
  text-align: justify;
  hyphens: auto;
}

.prose strong {
  color: var(--color-red);
  font-weight: 600;
}

/* --- BOOK COVER BLEND --- */
.book-wrapper {
  display: flex;
  align-items: center;
  justify-content: center;
}

.book-wrapper img.book-cover-blend {
  mix-blend-mode: multiply;
  object-fit: contain;
  filter: drop-shadow(0 15px 25px rgba(0,0,0,0.15));
  padding: 0;
  width: 90%;
  height: 90%;
}


/* --- MOSAIC (OPTION C) --- */
.mosaic-grid {
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  grid-template-rows: repeat(12, 1fr);
  width: 100%;
  height: 80vh;
  gap: 1.5rem;
}

.mosaic-item {
  position: relative;
  overflow: hidden;
  border: 1px solid rgba(0,0,0,0.05);
  background: var(--color-white);
}

.mosaic-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 20%; /* Adjusted to crop less heads */
  transition: var(--transition-smooth);
}

.mosaic-item:hover img {
  transform: scale(1.1);
}

.mosaic-text {
  grid-column: 1 / 6;
  grid-row: 2 / 10;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

/* --- SPECIFIC SPREADS --- */
.hero-spread {
  background-color: var(--color-cream);
}

.hero-spread .display-title {
  color: var(--color-black);
  position: relative;
}

.hero-spread .display-title span {
  color: var(--color-red);
}

/* --- NAVIGATION DOTS --- */
.nav-indicators {
  position: fixed;
  bottom: 2rem;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: 1rem;
  z-index: 100;
}

.dot {
  width: 40px;
  height: 2px;
  background: rgba(0,0,0,0.1);
  transition: var(--transition-smooth);
}

.dot.active {
  background: var(--color-red);
  width: 80px;
}

/* --- LOGO --- */
.header-logo {
  position: fixed;
  top: 2rem;
  left: 3rem;
  z-index: 100;
}

.header-logo img {
  height: 40px;
}

/* --- CTA BUTTON --- */
.btn-luxury {
  display: inline-block;
  padding: 1rem 3rem;
  background: var(--color-red);
  color: var(--color-white);
  text-decoration: none;
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.2em;
  font-weight: 700;
  margin-top: 3rem;
  transition: var(--transition-smooth);
  border: none;
}

.btn-luxury:hover {
  background: var(--color-white);
  color: var(--color-black);
}

/* --- REVEAL ANIMATIONS --- */
.reveal {
  opacity: 0;
  transform: translateY(30px);
  transition: var(--transition-smooth);
}

.spread.active .reveal {
  opacity: 1;
  transform: translateY(0);
}

.reveal-delay-1 { transition-delay: 0.2s; }
.reveal-delay-2 { transition-delay: 0.4s; }
.reveal-delay-3 { transition-delay: 0.6s; }

/* --- RESPONSIVE --- */
@media (max-width: 1024px) {
  body {
    overflow: auto !important; /* Allow native scroll on mobile */
  }
  .horizontal-container {
    flex-direction: column;
    overflow: visible;
    height: auto;
    scroll-snap-type: none; /* Better native feel */
  }
  .spread, .spread-wide {
    height: auto !important;
    min-height: 100vh;
    width: 100vw !important;
    flex: 0 0 auto;
    padding: 0 !important; /* Override inline paddings */
    flex-direction: column;
    scroll-snap-align: none;
  }
  .spread-content {
    padding: 4rem 2rem !important;
    height: auto;
    min-height: 50vh;
  }
  .spread-image {
    width: 100vw !important;
    height: 50vh !important;
    min-height: 50vh;
    border-radius: 0 !important;
  }
  .mosaic-grid {
    display: flex;
    flex-direction: column;
    height: auto;
    gap: 2rem;
    padding: 2rem;
  }
  .mosaic-text {
    order: -1; /* Always put text on top in mobile */
    margin-bottom: 2rem;
    grid-column: auto !important;
    grid-row: auto !important;
  }
  .mosaic-item {
    height: auto;
    min-height: 300px;
    width: 100%;
    grid-column: auto !important;
    grid-row: auto !important;
  }
  .mosaic-item img {
    height: 100%;
    width: 100%;
  }
  .book-wrapper {
    background: transparent;
    border: none;
    box-shadow: none;
    min-height: 400px;
  }
  .display-title {
    font-size: 3rem;
    line-height: 1;
  }
  .nav-indicators {
    display: none;
  }
  .header-logo {
    top: 1rem;
    left: 1.5rem;
  }
  .header-logo img {
    height: 30px;
  }
}

@media (max-width: 480px) {
  .display-title {
    font-size: 2.5rem;
  }
  .prose {
    font-size: 1rem;
  }
}
