:root {
  --color-white: #ffffff;
  --color-light-green: #a6b272;
  --color-medium-green: #7e9358;
  --color-dark-green: #325643;
  --color-light-beige: #dbc693;
  --color-medium-beige: #dba77d;
  --color-light-pink: #d17c7c;
  --color-dark-brown: #5b4548;
  --color-deep-purple: #4c4c66;
  --color-mediunm-blue: #357883;
  --color-highlight: #cc9145;
  --color-background: var(--color-dark-green);
  --color-text: var(--color-light-beige);
  --color-accent: var(--color-light-pink);
}

@font-face {
	font-family: 'brioche-regular';
	src: url('fonts/brioche-regular-webfont.woff2') format('woff2'),
				url('fonts/brioche-regular-webfont.woff') format('woff'),
				url('fonts/brioche-regular.otf') format('opentype');
	font-weight: normal;
	font-style: normal;
}

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

body {
	font-family: 'Open Sans', sans-serif;
	margin: 0;
	padding: 0;
	background-color: var(--color-background);
	color: var(--color-text);
	line-height: 1.6;
	display: flex;
	flex-direction: column;
	min-height: 100vh;
}


h1, h2, h3, .carousel-caption h5 {
  font-family: 'brioche-regular';
	text-shadow: 0 2px 4px rgba(0, 0, 0, 0.8);
}

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
}

header {
  background-color: var(--color-deep-purple);
}

nav {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.logo img {
  height: 50px;
  width: auto;
}

nav ul {
  list-style-type: none;
  display: flex;
  gap: 30px;
  align-items: center;
}

nav ul li a {
  text-decoration: none;
  color: var(--color-white);
  font-size: 16px;
  letter-spacing: 1px;
  transition: color 0.3s;
  text-transform: uppercase;
}

nav ul li a:hover {
  color: var(--color-accent);
}

.instagram-icon {
  display: flex;
  align-items: center;
  justify-content: center;
}

.instagram-icon svg {
  width: 24px;
  height: 24px;
  transition: transform 0.3s ease;
}

.instagram-icon:hover svg {
  transform: scale(1.2);
}

/* CARRUSEL */
.carousel {
  background-color: var(--color-light-green);
}
.carousel-item img {
  object-fit: cover;
  height: 100%
}
.carousel-caption h5,
.carousel-caption p {
  color: var(--color-white);
  text-shadow: 2px 2px 4px rgba(0,0,0,0.8);
}

.cta-button {
  background-color: var(--color-deep-purple);
  color: var(--color-white);
  padding: 12px 30px;
  font-size: 18px;
  text-decoration: none;
  text-transform: uppercase;
  letter-spacing: 1px;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
  border: none;
  border-radius: 4px;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.25);
}

.cta-button:hover {
  transform: translateY(-3px);
  box-shadow: 0 6px 10px rgba(0, 0, 0, 0.25);
  background-color: var(--color-accent);
}

.featured-books {
    padding: 80px 0;
    background-color: var(--color-mediunm-blue);
}

.featured-books h2 {
    text-align: center;
    font-size: 36px;
    margin-bottom: 60px;
    text-transform: uppercase;
    letter-spacing: 2px;
    color: var(--color-white);
}


.book-item {
    position: relative;
    aspect-ratio: 2 / 2;
    overflow: hidden;
    transition: transform 0.3s;

    h4 {
        text-align: center;
        color: var(--color-white);
    }
}

.book-item:hover {
    transform: translateY(-5px);
}

.book-item img {
    width: 100%;
    object-fit: cover;
    transition: transform 0.3s;
}

.book-item:hover img {
    transform: scale(1.05);
}


footer {
    text-align: center;
    padding: 40px 0;
    font-size: 14px;
    background-color: var(--color-dark-brown);
    color: var(--color-light-beige);
}

.book-fragment {
  background-color: var(--color-dark-green);
  color: var(--color-white);
  padding: 60px 20px;
  border-top: 5px solid var(--color-medium-beige);
  border-bottom: 5px solid var(--color-medium-beige);
  margin: 20px 0;
}

.fragment-text {
  font-size: 20px;
  font-style: italic;
  line-height: 1.8;
  color: var(--color-white);
  margin-bottom: 20px;
  position: relative;
}

.blockquote-footer {
  color: var(--color-white);
  font-weight: bold;
  font-size: 18px;
  margin-top: 20px;
  text-align: right;
}

.section-divider {
  height: 1px;
  background-color: rgba(255, 255, 255, 0.2);
  margin: 40px 0;
}

.book-panel {
  background-color: rgba(255, 255, 255, 0.05); /* sutil */
  padding: 20px;
  border-radius: 8px;
}
.book-panel:hover {
  background-color: rgba(255, 255, 255, 0.1); /* un poco más marcado al hover */
}

.books-timeline {
  background-color: var(--color-dark-green);
  color: var(--color-light-beige);
}

h3 {
  font-family: 'brioche-regular';
  color: var(--color-light-beige);
}

p {
  font-size: 16px; 
  line-height: 1.6;
}

/* Estilos de tu botón cta */
.cta-button {
  background-color: var(--color-deep-purple);
  color: var(--color-white);
  border: none;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.cta-button:hover {
  transform: translateY(-3px);
  box-shadow: 0 6px 10px rgba(0, 0, 0, 0.25);
  background-color: var(--color-accent);
}

/* Ajustar imágenes */
.libro-img {
  max-width: 80%; /* o 100% según prefieras */
  height: auto;
}

main {
	flex: 1;
}

.highlight-text {
	font-family: 'brioche-regular', serif;
	font-size: 24px;
	color: var(--color-text); /* Cambia esto al color que prefieras */
	text-align: center;
	margin-bottom: 10px;
}

.decorative-divider {
	height: 2px;
	max-width: 100px;
	background-color: var(--color-text);
	margin: 0 auto 20px auto;
}

.book-cover {
	max-width: 400px;
	box-shadow: 0 8px 16px rgba(0, 0, 0, 0.6);
	border-radius: 10px;
}

p {
	font-size: 18px;
	line-height: 1.8;
}

@media (max-width: 768px) {
    nav {
        flex-direction: column;
        gap: 20px;
    }

    nav ul {
        flex-direction: column;
        align-items: center;
    }

    .hero h1 {
        font-size: 48px;
    }

    .hero p {
        font-size: 18px;
    }

    .book-grid {
        grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    }
}

#backToTop {
  position: fixed;
  bottom: 20px;
  right: 20px;
  display: none;
  background-color: #343a40;
  border: none;
  border-radius: 50%;
  padding: 10px 15px;
  font-size: 20px;
  color: white;
  cursor: pointer;
  z-index: 1000;
  transition: opacity 0.3s ease-in-out;
}
