/* =========================================
   HISTORIAS - ZEN MASTERPIECE (Evolution V3)
   ========================================= */

:root {
    --zen-gold: #c5a059;
    --zen-gold-muted: rgba(197, 160, 89, 0.6);
    --zen-bg: #ffffff;
    --zen-bg-soft: #fcfaf5;
    --zen-dark: #0d0e10;
    --zen-text: #1a1a1a;
    --zen-text-muted: #555555;
    --zen-border: rgba(0, 0, 0, 0.06);
}

.historia-zen {
    background-color: var(--zen-bg);
    color: var(--zen-text);
    font-family: 'Outfit', sans-serif;
    overflow-x: hidden;
    position: relative;
}

/* Texture Overlay */
.historia-zen::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3%3Ffilter id='noiseFilter'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.65' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noiseFilter)'/%3E%3C/svg%3E");
    opacity: 0.03;
    pointer-events: none;
    z-index: 9999;
}

/* Custom Scroll Progress */
.zen-scroll-progress {
    position: fixed;
    top: 0;
    left: 0;
    width: 0%;
    height: 3px;
    background: var(--zen-gold);
    z-index: 10000;
}

/* --- Hero Compacto --- */
.zen-hero {
    height: 60vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--zen-bg-soft);
    position: relative;
    padding: 0 5%;
}

.zen-hero-content {
    max-width: 1200px;
    z-index: 10;
    text-align: center;
}

.zen-eyebrow {
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 10px;
    color: var(--zen-gold);
    margin-bottom: 2rem;
    display: block;
    font-weight: 600;
}

.zen-hero h1 {
    font-family: 'Marcellus', serif;
    font-size: clamp(2.5rem, 6vw, 4.5rem);
    line-height: 1.1;
    color: var(--zen-dark);
    margin: 1.5rem 0;
}

.zen-hero h1 span {
    color: var(--zen-gold);
}

.zen-hero-line {
    width: 1px;
    height: 60px;
    background: linear-gradient(to bottom, var(--zen-gold), transparent);
    margin: 3rem auto 0;
}

/* --- Secciones --- */
.zen-section {
    padding: 120px 0;
    position: relative;
}

.bg-soft {
    background-color: var(--zen-bg-soft);
    background-image: none !important;
}

.zen-chapter {
    font-family: 'Marcellus', serif;
    font-size: 0.8rem;
    color: var(--zen-gold);
    border: 1px solid var(--zen-gold);
    padding: 8px 18px;
    border-radius: 50px;
    display: inline-block;
    margin-bottom: 2.5rem;
}

.zen-title {
    font-family: 'Marcellus', serif;
    font-size: clamp(2rem, 4.5vw, 3.5rem);
    line-height: 1.1;
    margin-bottom: 2.5rem;
    color: var(--zen-dark);
}

.zen-p {
    font-size: 1.1rem;
    line-height: 1.8;
    color: var(--zen-text-muted);
    margin-bottom: 1.5rem;
}

.zen-lead {
    font-size: 1.5rem;
    font-weight: 300;
    line-height: 1.5;
    color: var(--zen-dark);
}

/* --- Frames de Imagen --- */
.zen-img-frame {
    position: relative;
    padding-bottom: 110%;
    overflow: hidden;
    clip-path: polygon(0 0, 100% 0, 100% 90%, 0 100%);
    background: #eee;
}

.zen-img-frame img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    filter: grayscale(100%);
    transition: all 1s ease;
}

.zen-img-frame:hover img {
    filter: grayscale(0%);
    transform: scale(1.05);
}

/* --- Obras Cards --- */
.zen-obras-layout {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 30px;
}

.zen-obra-card {
    padding: 40px;
    background: #fff;
    border: 1px solid var(--zen-border);
    transition: all 0.4s;
}

.zen-obra-card:hover {
    border-color: var(--zen-gold);
    transform: translateY(-5px);
}

.zen-obra-card i {
    font-size: 1.4rem;
    color: var(--zen-gold);
    margin-bottom: 20px;
    display: block;
}

.zen-obra-card h4 {
    font-family: 'Marcellus', serif;
    font-size: 1.4rem;
    margin-bottom: 12px;
}

.zen-obra-card.featured {
    grid-column: span 2;
    border-left: 4px solid var(--zen-gold);
}

/* --- Stats Inmersivas (Dark Section) --- */
.zen-stats-wrap {
    background-color: #0d0e10 !important;
    background-image: none !important;
    /* Reset global gradient */
    padding: 140px 0;
    color: #ffffff !important;
    text-align: center;
    position: relative;
    z-index: 10;
    border-top: 1px solid rgba(197, 160, 89, 0.2);
}

.zen-stats-grid {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 60px;
    margin: 80px 0;
}

.zen-stat-item {
    min-width: 220px;
    padding: 20px;
}

.zen-stat-val {
    display: block;
    font-family: 'Marcellus', serif;
    font-size: clamp(3.5rem, 8vw, 6rem);
    color: #c5a059 !important;
    line-height: 1;
    margin-bottom: 20px;
    font-weight: 700;
    text-shadow: 0 4px 20px rgba(0, 0, 0, 0.5);
}

.zen-stat-label {
    display: block;
    letter-spacing: 2px;
    text-transform: uppercase;
    font-size: 0.85rem;
    color: #ffffff !important;
    opacity: 0.95;
    line-height: 1.5;
    font-weight: 400;
}

/* --- Botón Final --- */
.zen-btn {
    display: inline-flex;
    padding: 22px 55px;
    border: 1px solid var(--zen-gold);
    color: var(--zen-gold);
    text-transform: uppercase;
    letter-spacing: 4px;
    font-size: 0.8rem;
    font-weight: 600;
    transition: all 0.4s;
    text-decoration: none !important;
}

.zen-btn:hover {
    background: var(--zen-gold);
    color: white;
}

@media (max-width: 992px) {
    .zen-hero h1 {
        font-size: 2.2rem;
    }

    .zen-section {
        padding: 70px 0;
    }

    .zen-obras-layout {
        grid-template-columns: 1fr;
    }

    .zen-obra-card.featured {
        grid-column: auto;
    }

    .zen-stats-grid {
        gap: 20px;
    }
}