/* === Reset === */
*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }

body {
    font-family: 'Segoe UI', system-ui, -apple-system, sans-serif;
    line-height: 1.7;
    color: #333;
    background: #fafaf8;
}

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

/* === Header === */
header {
    background: linear-gradient(135deg, #2d5a27, #4a8c3f);
    color: #fff;
    padding: 20px 0;
    position: sticky;
    top: 0;
    z-index: 100;
    box-shadow: 0 2px 10px rgba(0,0,0,0.15);
}

header .container { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 15px; }

.logo h1 { font-size: 1.6em; margin: 0; }
.slogan { font-size: 0.85em; opacity: 0.85; margin-top: 2px; }

nav ul { list-style: none; display: flex; gap: 20px; flex-wrap: wrap; }
nav a { color: #fff; text-decoration: none; font-weight: 500; padding: 5px 0; border-bottom: 2px solid transparent; transition: 0.2s; }
nav a:hover { border-bottom-color: #ffd700; }

/* === Hero === */
.hero {
    background: linear-gradient(135deg, #e8f5e9, #c8e6c9);
    padding: 60px 0;
    text-align: center;
}
.hero h2 { font-size: 2em; color: #2d5a27; margin-bottom: 15px; }
.hero p { font-size: 1.15em; max-width: 700px; margin: 0 auto; color: #555; }

/* === Secciones === */
section { padding: 50px 0; }
section h2 { font-size: 1.6em; color: #2d5a27; margin-bottom: 30px; text-align: center; }

/* === Grid cards === */
.grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 30px; }

.card {
    background: #fff;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 2px 15px rgba(0,0,0,0.08);
    transition: transform 0.2s, box-shadow 0.2s;
}
.card:hover { transform: translateY(-3px); box-shadow: 0 5px 25px rgba(0,0,0,0.12); }
.card img { width: 100%; height: 200px; object-fit: cover; background: #e8e8e8; }
.card h3 { padding: 15px 20px 5px; font-size: 1.15em; }
.card p { padding: 5px 20px 15px; color: #666; font-size: 0.95em; }
.card .btn { margin: 0 20px 20px; }

.btn {
    display: inline-block;
    background: #4a8c3f;
    color: #fff;
    padding: 10px 25px;
    border-radius: 6px;
    text-decoration: none;
    font-weight: 600;
    transition: background 0.2s;
}
.btn:hover { background: #2d5a27; }

/* === Categorías === */
.grid-categorias { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 15px; }

.categoria {
    display: block;
    background: #fff;
    border: 2px solid #c8e6c9;
    border-radius: 10px;
    padding: 25px;
    text-align: center;
    font-size: 1.15em;
    font-weight: 600;
    color: #2d5a27;
    text-decoration: none;
    transition: all 0.2s;
}
.categoria:hover { background: #e8f5e9; border-color: #4a8c3f; }

/* === Footer === */
footer {
    background: #1a3a17;
    color: #ddd;
    padding: 40px 0 20px;
    margin-top: 40px;
}
.footer-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); gap: 30px; margin-bottom: 30px; }
footer h4 { color: #ffd700; margin-bottom: 10px; font-size: 1.05em; }
footer ul { list-style: none; }
footer li { margin-bottom: 6px; }
footer a { color: #a5d6a7; text-decoration: none; }
footer a:hover { color: #ffd700; }
.copyright { text-align: center; border-top: 1px solid #2d5a27; padding-top: 20px; font-size: 0.85em; opacity: 0.7; }

/* === Páginas internas === */
.page-header { background: #e8f5e9; padding: 40px 0; text-align: center; }
.page-header h2 { margin-bottom: 10px; }
.page-header p { color: #666; max-width: 600px; margin: 0 auto; }

.contenido { padding: 40px 0; }
.contenido h3 { color: #2d5a27; margin-top: 30px; margin-bottom: 10px; }
.contenido p { margin-bottom: 15px; color: #555; }
.contenido ul, .contenido ol { margin-bottom: 15px; padding-left: 25px; color: #555; }
.contenido li { margin-bottom: 6px; }

/* === Productos (afiliados) === */
.producto {
    display: flex;
    gap: 25px;
    background: #fff;
    border-radius: 12px;
    padding: 25px;
    margin-bottom: 25px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.06);
    align-items: flex-start;
}
.producto-img { width: 180px; height: 180px; object-fit: cover; border-radius: 8px; background: #eee; flex-shrink: 0; }
.producto-info h3 { margin-bottom: 8px; }
.producto-info p { color: #666; font-size: 0.95em; margin-bottom: 12px; }
.precio { font-size: 1.3em; color: #2d5a27; font-weight: 700; }
.btn-amazon { display: inline-block; background: #ff9900; color: #fff; padding: 8px 20px; border-radius: 6px; text-decoration: none; font-weight: 600; transition: background 0.2s; }
.btn-amazon:hover { background: #e68a00; }

/* === Responsive === */
@media (max-width: 768px) {
    header .container { flex-direction: column; align-items: center; text-align: center; }
    nav ul { justify-content: center; }
    .hero h2 { font-size: 1.5em; }
    .producto { flex-direction: column; align-items: center; text-align: center; }
    .producto-img { width: 150px; height: 150px; }
}

@media (max-width: 480px) {
    .grid { grid-template-columns: 1fr; }
}
