:root {
    /* Paleta de Colores Natural y Calmada */
    --primary-green: #5D8C68;
    /* Verde Bambú */
    --deep-teal: #2A4F4F;
    /* Texto y fondos oscuros */
    --soft-cream: #FDFBF7;
    /* Fondo principal */
    --warm-sand: #F2E8DC;
    /* Fondos secundarios */
    --accent-clay: #2cbbc6;
    /* Botones y acentos (Tierra) */
    --light-blue: #E8F1F2;
    /* Detalles sutiles */
    --brown: #D97C56;
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: 'Nunito', sans-serif;
    background-color: var(--soft-cream);
    color: var(--deep-teal);
    line-height: 1.6;
}

h1,
h2,
h3 {
    font-family: 'Lora', serif;
    color: var(--deep-teal);
}

a {
    text-decoration: none;
    color: inherit;
}

/* --- HEADER & NAV --- */
header {
    background-color: #fff;
    padding: 1rem 5%;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.03);
    position: sticky;
    top: 0;
    z-index: 1000;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    max-height: 45px;
    overflow: visible;
    font-size: 1.5rem;
    font-weight: 800;
    color: var(--primary-green);
    display: flex;
    align-items: flex-start;
    gap: 0.5rem;
}

.nav-links {
    display: flex;
    gap: 2rem;
    font-weight: 600;
}

.nav-links a:hover {
    color: var(--accent-clay);
}

.cta-button,
.cta-button-brown {
    color: white;
    height: fit-content;
    padding: 5px 20px;
    border-radius: 30px;
    font-weight: bold;
    transition: transform 0.2s, background-color 0.2s;
}

.cta-button {
    background-color: var(--accent-clay);
}

.cta-button-brown {
    background-color: var(--brown);
}

.cta-button:hover {
    background-color: var(--brown);
    transform: translateY(-2px);
}

/* --- HERO SECTION --- */
.hero {
    padding: 5rem 5%;
    display: flex;
    align-items: center;
    gap: 4rem;
    background: linear-gradient(135deg, var(--soft-cream) 0%, var(--warm-sand) 100%);
}

.hero-content {
    flex: 1;
}

.hero-content h1 {
    font-size: 3rem;
    line-height: 1.2;
    margin-bottom: 1.5rem;
}

.hero-content p {
    font-size: 1.2rem;
    margin-bottom: 2rem;
    color: #4a6363;
}

.hero-image {
    flex: 1;
    display: flex;
    justify-content: center;
    position: relative;
    max-width: 100%;
}

.hero-img-placeholder {
    width: 500px;
    max-width: 85%;
    height: 500px;
    border-radius: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
    background-image: url(/static/Portada%20Dientes.jpg);
    background-size: contain;
    background-repeat: no-repeat;
}

/* --- PHILOSOPHY SECTION (LOS 3 PILARES) --- */
.philosophy {
    padding: 4rem 5%;
    text-align: center;
    background-color: white;
}

.philosophy h2 {
    font-size: 2.2rem;
    margin-bottom: 1rem;
}

.subtitle {
    max-width: 700px;
    margin: 0 auto 3rem;
    color: #666;
}

.pillars-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 2rem;
    max-width: 1200px;
    margin: 0 auto;
}

.pillar-card {
    padding: 2rem;
    background-color: var(--soft-cream);
    border-radius: 15px;
    transition: transform 0.3s;
}

.pillar-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.05);
}

.icon {
    font-size: 2.5rem;
    margin-bottom: 1rem;
    display: block;
}

/* --- FEATURED BOOK (AYLA) --- */
.featured-book {
    padding: 5rem 5%;
    background-color: var(--light-blue);
    display: flex;
    align-items: center;
    gap: 4rem;
}

.book-cover-container {
    flex: 1;
    display: flex;
    justify-content: center;
}

.book-cover {
    width: 300px;
    height: fit-content;
    /* Proporción portada */
    background-color: #fff;
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.15);
    border-radius: 5px;
    transform: rotate(-3deg);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    color: var(--primary-green);
    border: 1px solid #eee;
}

.book-cover img {
    max-width: 100%;
    height: auto;
}

.book-info {
    flex: 1.5;
}

.badge {
    background-color: var(--primary-green);
    color: white;
    padding: 0.3rem 0.8rem;
    border-radius: 5px;
    font-size: 0.8rem;
    font-weight: bold;
    text-transform: uppercase;
    letter-spacing: 1px;
}

/* --- UPCOMING / CATALOG --- */
.catalog {
    padding: 5rem 5%;
    background-color: var(--soft-cream);
}

.catalog h2 {
    text-align: center;
    margin-bottom: 3rem;
}

.books-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 2rem;
    max-width: 1200px;
    margin: 0 auto;
}

.book-card {
    background: white;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.05);
    opacity: 0.7;
    /* Visualmente indica que aún no están disponibles, salvo que se active */
}

.book-card.active {
    opacity: 1;
    border: 2px solid var(--primary-green);
}

.book-card-img {
    height: 200px;
    background-color: #eee;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #999;
    height: fit-content;
    min-height: 285px;
}

.book-card-body {
    padding: 1.5rem;
}

.book-card h3 {
    font-size: 1.1rem;
    margin-bottom: 0.5rem;
}

.status {
    font-size: 0.8rem;
    font-weight: bold;
    color: var(--brown);
}

/* --- FOOTER --- */
footer {
    background-color: var(--deep-teal);
    color: #ccc;
    padding: 3rem 5%;
    text-align: center;
}

footer h3 {
    color: white;
    margin-bottom: 1rem;
}

.social-links {
    margin: 2rem 0;
    display: flex;
    justify-content: center;
    gap: 1.5rem;
}

/* RESPONSIVE */
@media (max-width: 768px) {

    .hero,
    .featured-book {
        flex-direction: column;
        text-align: center;
        gap: 2rem;
    }

    .hero-content h1 {
        font-size: 2rem;
    }

    .nav-links {
        display: none;
        /* En producción se usaría un menú hamburguesa */
    }

    .book-cover {
        width: 200px;
        height: 280px;
    }
}