/* VARIABLES DE SISTEMA DE DISEÑO */
:root {
    --olive: #556B2F;
    --olive-light: #f4f7f0;
    --accent: #FF5733;
    --black: #000000;
    --white: #ffffff;
    --text: #2d3436;
    --text-light: #636e72;
    --font-titles: 'Montserrat', sans-serif;
    --font-body: 'Open Sans', sans-serif;
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    --shadow: 0 10px 30px rgba(0,0,0,0.05);
    --gray-light: #f8f9fa;
}

/* RESET Y BASE */
* { margin: 0; padding: 0; box-sizing: border-box; }
body { font-family: var(--font-body); color: var(--text); line-height: 1.6; overflow-x: hidden; }
h1, h2, h3 { font-family: var(--font-titles); line-height: 1.2; }
a { text-decoration: none; color: inherit; transition: var(--transition); }
ul { list-style: none; }
img { max-width: 100%; display: block; }
.container { max-width: 1200px; margin: 0 auto; padding: 0 1.5rem; }

/* COMPONENTES GLOBALES: TOP BAR */
.top-bar { background: var(--black); color: var(--white); padding: 10px 0; font-size: 0.85rem; }
.top-bar .container { display: flex; justify-content: space-between; align-items: center; }
.top-bar a:hover { color: var(--accent); }

/* COMPONENTES GLOBALES: HEADER */
.main-header { background: rgba(255,255,255,0.95); backdrop-filter: blur(10px); position: sticky; top: 0; z-index: 1000; padding: 1rem 0; box-shadow: 0 2px 10px rgba(0,0,0,0.02); }
.nav-flex { display: flex; justify-content: space-between; align-items: center; }
.logo { font-size: 1.5rem; font-weight: 700; font-family: var(--font-titles); }
.logo span { color: var(--olive); }
.nav-menu ul { display: flex; gap: 1.5rem; }
.nav-menu a { font-weight: 600; font-size: 0.95rem; }
.nav-menu a:hover { color: var(--olive); }

/* BOTONES */
.btn { padding: 0.8rem 1.8rem; border-radius: 4px; display: inline-block; font-weight: 700; cursor: pointer; border: none; }
.btn-accent { background: var(--accent); color: var(--white); }
.btn-primary { background: var(--olive); color: var(--white); }
.btn-outline { border: 2px solid var(--olive); color: var(--olive); }
.btn:hover { transform: translateY(-3px); box-shadow: 0 10px 20px rgba(0,0,0,0.1); }


/* COMPONENTES GLOBALES: FOOTER & SUB-FOOTER */
.main-footer { padding: 5rem 0; background: #fafafa; border-top: 1px solid #eee; }
.footer-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); gap: 3rem; }
.sub-footer { background: var(--black); color: var(--white); padding: 15px 0; font-size: 0.8rem; }
.sub-flex { display: flex; justify-content: space-between; align-items: center; }

/* --- LAYOUT: INDEX (LANDING) --- */
.hero { padding: 6rem 0; background: var(--olive-light); }
.hero-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 4rem; align-items: center; }
.hero-text h1 { font-size: 3.5rem; margin-bottom: 1.5rem; }
.hero-text p { font-size: 1.2rem; color: var(--text-light); margin-bottom: 2.5rem; }
.hero-img img { border-radius: 40px; box-shadow: 20px 20px 0 var(--olive); }

.features { padding: 7rem 0; text-align: center; }
.feat-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 2.5rem; margin-top: 4rem; }
.feat-card { padding: 3rem; background: var(--olive-light); border-radius: 15px; }
.feat-card i { font-size: 3rem; color: var(--olive); margin-bottom: 1.5rem; }

.testimonials { padding: 6rem 0; background: var(--white); }
.testi-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 2rem; margin-top: 3rem; }
.testi-card { background: var(--white); padding: 2rem; border-left: 4px solid var(--olive); box-shadow: var(--shadow); border-radius: 0 8px 8px 0; }
.testi-text { font-style: italic; color: var(--text-light); margin-bottom: 1.5rem; font-size: 1.1rem; }
.testi-author { font-weight: 700; color: var(--text); display: flex; align-items: center; gap: 10px; }
.testi-author::before { content: ''; display: block; width: 30px; height: 2px; background: var(--accent); }



/* --- LAYOUT: PRODUCTOS (CATÁLOGO) --- */
.shop-layout { display: grid; grid-template-columns: 250px 1fr; gap: 3rem; padding: 4rem 0; }
.sidebar h3 { font-family: var(--font-titles); margin-bottom: 1.5rem; border-bottom: 2px solid var(--olive-light); padding-bottom: 5px; }
.filter-list li { margin-bottom: 10px; }
.filter-list a:hover, .filter-list a.active { color: var(--olive); font-weight: 700; }

.products-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 2rem; }
.prod-card { position: relative; overflow: hidden; transition: var(--transition); border-radius: 8px; border: 1px solid #eee; }
.prod-card:hover { border-color: var(--olive); transform: translateY(-5px); }
.prod-img { position: relative; overflow: hidden; height: 250px; }
.prod-img img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.6s ease; }
.prod-card:hover .prod-img img { transform: scale(1.1); }

.badge { position: absolute; top: 10px; left: 10px; background: var(--accent); color: white; padding: 3px 10px; font-size: 0.7rem; font-weight: 700; z-index: 2; }
.add-btn { position: absolute; bottom: -50px; width: 100%; background: var(--olive); color: white; padding: 12px; border: none; font-weight: 700; transition: var(--transition); }
.prod-card:hover .add-btn { bottom: 0; }

.prod-info { padding: 1.5rem; text-align: center; }
.prod-info h3 { font-size: 1rem; margin-bottom: 5px; }
.price { color: var(--accent); font-weight: 700; }

/* --- LAYOUT: CONTACTO --- */
.contact-layout { display: grid; grid-template-columns: 1fr 1.5fr; gap: 4rem; padding: 4rem 0; }
.contact-info h2 { margin-bottom: 1.5rem; color: var(--olive); }
.info-item { display: flex; align-items: flex-start; gap: 1rem; margin-bottom: 1.5rem; }
.info-item i { color: var(--accent); font-size: 1.2rem; margin-top: 5px; }
.map-placeholder { width: 100%; height: 200px; background: #eee; border-radius: 8px; display: flex; align-items: center; justify-content: center; color: #999; margin-top: 2rem; }

.contact-form { background: var(--white); padding: 2rem; border-radius: 10px; box-shadow: var(--shadow); }
.form-group { margin-bottom: 1.5rem; }
.form-group label { display: block; margin-bottom: 0.5rem; font-weight: 600; font-size: 0.9rem; }
.form-control { width: 100%; padding: 12px 15px; border: 1px solid #ddd; border-radius: 6px; font-family: var(--font-body); transition: var(--transition); background: var(--gray-light); }
.form-control:focus { outline: none; border-color: var(--olive); background: var(--white); box-shadow: 0 0 0 3px rgba(85, 107, 47, 0.1); }
textarea.form-control { resize: vertical; min-height: 120px; }

/* --- LAYOUT: BLOG --- */
.blog-layout { display: grid; grid-template-columns: 1fr 300px; gap: 3rem; padding: 4rem 0; }
.blog-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 2rem; }
.post-card { background: var(--white); border-radius: 8px; overflow: hidden; box-shadow: var(--shadow); transition: var(--transition); display: flex; flex-direction: column; }
.post-card:hover { transform: translateY(-5px); }
.post-img { height: 200px; position: relative; }
.post-img img { width: 100%; height: 100%; object-fit: cover; }
.post-cat { position: absolute; top: 10px; right: 10px; background: var(--white); color: var(--olive); padding: 4px 12px; border-radius: 20px; font-size: 0.75rem; font-weight: 700; }
.post-content { padding: 1.5rem; flex-grow: 1; display: flex; flex-direction: column; }
.post-content h3 { font-size: 1.2rem; margin-bottom: 0.8rem; color: var(--text); }
.post-meta { font-size: 0.8rem; color: var(--text-light); margin-bottom: 1rem; }
.post-excerpt { font-size: 0.9rem; color: var(--text-light); margin-bottom: 1.5rem; flex-grow: 1; }
.read-more { color: var(--accent); font-weight: 700; font-size: 0.9rem; position: relative; display: inline-block; }
.read-more::after { content: ''; position: absolute; bottom: -2px; left: 0; width: 0; height: 2px; background: var(--accent); transition: var(--transition); }
.post-card:hover .read-more::after { width: 100%; }

.sidebar-widget { background: var(--gray-light); padding: 1.5rem; border-radius: 8px; margin-bottom: 2rem; }
.sidebar-widget h4 { font-family: var(--font-titles); margin-bottom: 1rem; border-bottom: 2px solid #ddd; padding-bottom: 0.5rem; }
.cat-list li { border-bottom: 1px solid #eee; padding: 8px 0; }
.cat-list a:hover { color: var(--olive); padding-left: 5px; }

.newsletter-box { background: var(--olive); color: var(--white); padding: 3rem; text-align: center; border-radius: 10px; margin: 4rem 0; }
.newsletter-box h3 { color: var(--white); margin-bottom: 1rem; }
.newsletter-form { display: flex; gap: 10px; max-width: 500px; margin: 2rem auto 0; }
.newsletter-form input { flex: 1; padding: 12px; border-radius: 4px; border: none; }

/* --- LAYOUT: NOSOTROS --- */
.about-hero { background: url('https://images.unsplash.com/photo-1500937386664-56d1dfef3854?auto=format&fit=crop&q=80&w=1920') no-repeat center center/cover; padding: 8rem 0; text-align: center; color: var(--white); position: relative; }
.about-hero::before { content: ''; position: absolute; top: 0; left: 0; width: 100%; height: 100%; background: rgba(0,0,0,0.5); }
.about-hero .container { position: relative; z-index: 1; }
.about-hero h1 { font-size: 3rem; margin-bottom: 1rem; }

.mission-section { padding: 5rem 0; }
.mission-flex { display: grid; grid-template-columns: 1fr 1fr; gap: 4rem; align-items: center; }
.mission-img img { border-radius: 10px; box-shadow: 20px 20px 0 var(--olive-light); }
.mission-text h2 { color: var(--olive); margin-bottom: 1.5rem; }

.values-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 2rem; padding: 4rem 0; text-align: center; background: var(--olive-light); }
.value-item i { font-size: 2.5rem; color: var(--olive); margin-bottom: 1rem; }
.value-item h4 { margin-bottom: 0.5rem; }

.founder-quote { padding: 5rem 0; text-align: center; max-width: 800px; margin: 0 auto; }
.quote-box { font-size: 1.5rem; font-family: var(--font-titles); font-style: italic; color: var(--text); line-height: 1.6; position: relative; }
.quote-box::before { content: '"'; font-size: 5rem; color: var(--olive); opacity: 0.2; position: absolute; top: -40px; left: -20px; }
.founder-sign { margin-top: 2rem; font-family: 'Dancing Script', cursive; font-size: 2rem; color: var(--accent); }

/* --- LAYOUT: LEGAL --- */
.legal-page { padding: 4rem 0; max-width: 800px; margin: 0 auto; }
.legal-page h1 { text-align: center; margin-bottom: 3rem; color: var(--olive); }
.legal-content h2 { font-size: 1.5rem; margin-top: 2rem; margin-bottom: 1rem; }
.legal-content p { margin-bottom: 1rem; text-align: justify; }
.legal-content ul { list-style: disc; padding-left: 20px; margin-bottom: 1rem; }

/* RESPONSIVE */
@media (max-width: 992px) {
    .hero-text h1 { font-size: 2.5rem; }
    .shop-layout { grid-template-columns: 1fr; }
    .sidebar { order: 2; }
    .nav-menu, .header-action { display: none; } /* En un proyecto real aquí va el menú hamburguesa */
    
    .contact-layout { grid-template-columns: 1fr; }
    .blog-layout { grid-template-columns: 1fr; }
    .mission-flex { grid-template-columns: 1fr; }
    .newsletter-form { flex-direction: column; }
    
    /* Mobile First Adjustments for new elements */
    .testi-card { border-left: none; border-top: 4px solid var(--olive); border-radius: 8px; }
    .about-hero h1 { font-size: 2rem; }
}