/* Variables de Colores */
:root {
    --primary-color: #2e8b57;
    --primary-dark: #1e5b38;
    --secondary-color: #f39c12;
    --bg-light: #f9f9f9;
    --text-color: #333333;
    --card-bg: #ffffff;
    --shadow: 0 4px 6px rgba(0,0,0,0.1);
}

/* Reset de Estilos Básicos */
* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

body {
    color: var(--text-color);
    line-height: 1.6;
    background-color: #fff;
}

/* Encabezado */
.header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 2rem;
    background-color: var(--primary-color);
    color: white;
    position: sticky;
    top: 0;
    z-index: 100;
}

.logo {
    font-size: 1.5rem;
    font-weight: bold;
}

.nav a {
    color: white;
    text-decoration: none;
    margin-right: 1.5rem;
    font-weight: 500;
}

.nav a:hover {
    color: var(--secondary-color);
}

.cart-btn {
    background-color: var(--secondary-color);
    border: none;
    color: white;
    padding: 0.5rem 1rem;
    border-radius: 20px;
    cursor: pointer;
    font-weight: bold;
    transition: background 0.3s;
}

.cart-btn:hover {
    background-color: #e67e22;
}

/* Hero Section */
.hero {
    background: linear-gradient(rgba(0,0,0,0.5), rgba(0,0,0,0.5)), url('https://images.unsplash.com/photo-1450778869180-41d0601e046e?auto=format&fit=crop&w=1200&q=80') center/cover;
    height: 350px;
    display: flex;
    justify-content: center;
    align-items: center;
    color: white;
    text-align: center;
    padding: 0 1rem;
}

.hero h1 {
    font-size: 2.5rem;
    margin-bottom: 0.5rem;
}

/* Contenedores y Secciones */
.container {
    width: 90%;
    max-width: 1100px;
    margin: 2rem auto;
}

.padding-section {
    padding: 3rem 0;
}

.bg-light {
    background-color: var(--bg-light);
}

.section-title {
    text-align: center;
    margin-bottom: 2rem;
    color: var(--primary-color);
}

.text-center { text-align: center; }
.mb-2 { margin-bottom: 2rem; }
.mt-2 { margin-top: 2rem; }

/* Tarjetas y Grid */
.grid-cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 1.5rem;
}

.card {
    background-color: var(--card-bg);
    padding: 1.5rem;
    border-radius: 8px;
    box-shadow: var(--shadow);
}

.border-top-primary {
    border-top: 4px solid var(--primary-color);
}

.bg-accent {
    background-color: #eef9f2;
    border-left: 4px solid var(--primary-color);
}

.card h3 {
    margin-bottom: 0.8rem;
}

.card ul {
    list-style-position: inside;
}

/* Catálogo de Productos */
.products-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 1.5rem;
}

.product-card {
    background: white;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: var(--shadow);
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    text-align: center;
    padding: 1rem;
}

.product-card img {
    width: 100%;
    height: 180px;
    object-fit: cover;
    border-radius: 4px;
}

.product-card h4 {
    margin: 0.8rem 0 0.4rem;
}

.product-price {
    font-size: 1.2rem;
    font-weight: bold;
    color: var(--primary-color);
    margin-bottom: 1rem;
}

/* Botones */
.btn {
    padding: 0.6rem 1.2rem;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-weight: bold;
    text-decoration: none;
    display: inline-block;
}

.btn-hero {
    background-color: var(--secondary-color);
    color: white;
    margin-top: 1rem;
}

.btn-primary {
    background-color: var(--primary-color);
    color: white;
}

.btn-primary:hover {
    background-color: var(--primary-dark);
}

.btn-block {
    width: 100%;
}

/* Formulario */
.form-container {
    max-width: 600px;
    margin: 0 auto;
    background: white;
    padding: 2rem;
    border-radius: 8px;
    box-shadow: var(--shadow);
}

.form-group {
    margin-bottom: 1.2rem;
}

.form-group label {
    display: block;
    margin-bottom: 0.4rem;
    font-weight: bold;
}

.form-group input,
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 0.8rem;
    border: 1px solid #ccc;
    border-radius: 4px;
}

/* Modal del Carrito */
.modal {
    display: none;
    position: fixed;
    top: 0; left: 0;
    width: 100%; height: 100%;
    background-color: rgba(0,0,0,0.5);
    justify-content: center;
    align-items: center;
    z-index: 200;
}

.modal-content {
    background: white;
    padding: 2rem;
    border-radius: 8px;
    width: 90%;
    max-width: 500px;
    position: relative;
}

.close-btn {
    position: absolute;
    top: 10px;
    right: 15px;
    font-size: 1.5rem;
    cursor: pointer;
}

.cart-items {
    max-height: 250px;
    overflow-y: auto;
    margin: 1rem 0;
    border-top: 1px solid #eee;
    border-bottom: 1px solid #eee;
    padding: 0.5rem 0;
}

.cart-item {
    display: flex;
    justify-content: space-between;
    margin-bottom: 0.5rem;
}

.cart-summary {
    text-align: right;
    margin-top: 1rem;
}

/* Footer */
.footer {
    background-color: #222;
    color: white;
    text-align: center;
    padding: 1.5rem;
}