:root {
    --verde: #2D5016;
    --verde-oscuro: #1f3810;
    --naranja: #D97706;
    --naranja-oscuro: #B45309;
    --gris: #1F2937;
    --crema: #F9F7F4;
    --verde-claro: #E8F5E9;
    --rojo: #DC2626;
    --border: #E5E7EB;
    --muted: #6B7280;
    --card: #FFFFFF;
    --radius: 10px;
}

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body {
    font-family: 'Inter', system-ui, sans-serif;
    color: var(--gris);
    background: var(--crema);
    line-height: 1.5;
}
h1, h2, h3 { font-family: 'Sora', 'Inter', sans-serif; font-weight: 700; margin: 0 0 0.5rem; color: var(--gris); }
p { margin: 0 0 1rem; }
a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }
.container { max-width: 1200px; margin: 0 auto; padding: 0 1.25rem; }
.container-wide { max-width: 1600px; margin: 0 auto; padding: 0 1.5rem; }
.muted { color: var(--muted); font-size: 0.9rem; }
.center { text-align: center; }

/* Header */
.site-header { position: sticky; top: 0; z-index: 50; background: #fff; border-bottom: 1px solid var(--border); box-shadow: 0 2px 8px rgba(0,0,0,0.04); }
.header-inner { display: flex; align-items: center; justify-content: space-between; padding: 0.75rem 1.25rem; }
.logo { display: flex; align-items: center; gap: 0.6rem; font-family: 'Sora', sans-serif; font-weight: 700; font-size: 1.2rem; color: var(--verde); }
.nav-desktop { display: none; gap: 2rem; }
.nav-desktop a { font-size: 0.9rem; font-weight: 500; color: #374151; }
.nav-desktop a:hover { color: var(--naranja); }
.nav-toggle { background: none; border: none; font-size: 1.4rem; cursor: pointer; }
.nav-mobile { display: none; flex-direction: column; gap: 1rem; padding: 1rem 1.25rem; border-top: 1px solid var(--border); }
.nav-mobile.open { display: flex; }
@media (min-width: 768px) {
    .nav-desktop { display: flex; }
    .nav-toggle { display: none; }
}

/* Buttons */
.btn { display: inline-flex; align-items: center; gap: 0.5rem; padding: 0.7rem 1.4rem; border-radius: 8px; font-weight: 700; font-size: 0.95rem; border: none; cursor: pointer; }
.btn-orange { background: var(--naranja); color: #fff; }
.btn-orange:hover { background: var(--naranja-oscuro); }
.btn-green { background: var(--verde); color: #fff; }
.btn-green:hover { background: var(--verde-oscuro); }
.btn-outline { background: transparent; border: 1px solid var(--border); color: var(--gris); }
.btn-block { width: 100%; justify-content: center; }
.btn-lg { padding: 0.9rem 1.8rem; font-size: 1.05rem; }
.btn-sm { padding: 0.4rem 0.8rem; font-size: 0.8rem; }
.link-arrow { color: var(--naranja); font-weight: 600; }

/* Hero */
.hero { background: linear-gradient(to right, #15803d, var(--verde-oscuro)); border-bottom: 1px solid var(--border); }
.hero-inner { display: grid; gap: 2rem; padding: 3rem 1.25rem; align-items: center; }
.hero-content { color: #fff; }
.pill { display: inline-block; background: rgba(255,255,255,0.2); color: #fff; padding: 0.4rem 0.9rem; border-radius: 999px; font-size: 0.85rem; font-weight: 600; margin-bottom: 1rem; }
.hero-content h1 { font-size: 2.2rem; color: #fff; line-height: 1.15; }
.hero-content p { color: rgba(255,255,255,0.9); font-size: 1.05rem; margin-bottom: 1.5rem; }
.hero-collage { display: grid; grid-template-columns: repeat(3, 1fr); gap: 0.75rem; }
.collage-item { position: relative; border-radius: 8px; overflow: hidden; height: 120px; box-shadow: 0 4px 12px rgba(0,0,0,0.3); }
.collage-item img { width: 100%; height: 100%; object-fit: cover; }
.collage-item span { position: absolute; bottom: 0.4rem; left: 0.4rem; right: 0.4rem; color: #fff; font-size: 0.7rem; font-weight: 600; text-shadow: 0 1px 3px rgba(0,0,0,0.8); }
@media (min-width: 1024px) {
    .hero-inner { grid-template-columns: 1fr 1fr; padding: 5rem 1.25rem; }
    .hero-content h1 { font-size: 3.2rem; }
}

/* Sections */
.section { padding: 3rem 0; border-bottom: 1px solid var(--border); }
.section-white { background: #fff; }
.section-card { background: var(--card); }
.section-header { display: flex; align-items: center; justify-content: space-between; margin-bottom: 2rem; }

/* Categories */
.cat-scroll { display: flex; gap: 1rem; overflow-x: auto; padding-bottom: 0.5rem; }
.cat-card { flex-shrink: 0; width: 180px; background: var(--card); border: 1px solid var(--border); border-radius: var(--radius); padding: 1rem; transition: box-shadow .15s, border-color .15s; }
.cat-card:hover { box-shadow: 0 4px 14px rgba(0,0,0,0.08); border-color: var(--naranja); }
.cat-icon { font-size: 2rem; margin-bottom: 0.5rem; }

/* Feature cards */
.grid-2 { display: grid; gap: 1.5rem; }
@media (min-width: 640px) { .grid-2 { grid-template-columns: 1fr 1fr; } }
.feature-card { background: var(--card); border: 1px solid var(--border); border-radius: var(--radius); padding: 1.5rem; }
.feature-icon { width: 48px; height: 48px; border-radius: 8px; display: flex; align-items: center; justify-content: center; font-size: 1.4rem; margin-bottom: 1rem; }
.feature-icon-green { background: var(--verde-claro); }
.feature-icon-orange { background: #FEF3C7; }

/* Product grid / cards */
.grid-products { display: grid; gap: 1.25rem; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); }
.product-card { display: block; background: var(--card); border: 1px solid var(--border); border-radius: var(--radius); overflow: hidden; transition: box-shadow .15s, transform .15s; }
.product-card:hover { box-shadow: 0 8px 20px rgba(0,0,0,0.1); transform: translateY(-2px); }
.product-card-img { position: relative; aspect-ratio: 1; background: #fff; }
.product-card-img img { width: 100%; height: 100%; object-fit: contain; padding: 0.75rem; }
.badge { position: absolute; top: 0.5rem; font-size: 0.7rem; font-weight: 700; padding: 0.25rem 0.5rem; border-radius: 999px; color: #fff; }
.badge-orange { left: 0.5rem; background: var(--naranja); }
.badge-red { right: 0.5rem; background: var(--rojo); }
.product-card-body { padding: 0.9rem; }
.eyebrow { font-size: 0.7rem; font-weight: 600; text-transform: uppercase; letter-spacing: 0.05em; color: var(--naranja-oscuro); }
.product-card-body h3 { font-size: 0.95rem; margin: 0.3rem 0; line-height: 1.3; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.price { font-family: monospace; font-weight: 700; font-size: 1.2rem; color: var(--verde); }
.price small { font-weight: 400; font-size: 0.7rem; color: var(--muted); }
.price-big { font-family: monospace; font-weight: 700; font-size: 2.2rem; color: var(--verde); margin: 0.5rem 0; }
.meta { margin-top: 0.3rem; }

/* CTA final */
.cta-final { background: linear-gradient(to right, var(--naranja), var(--naranja-oscuro)); color: #fff; padding: 4rem 0; }
.cta-final h2 { color: #fff; }
.cta-final p { color: rgba(255,255,255,0.9); margin-bottom: 1.5rem; }

/* Catalog page */
.page-header { background: var(--card); border-bottom: 1px solid var(--border); padding: 2rem 0; }
.catalog-layout { display: grid; gap: 2rem; padding: 2rem 0; }
@media (min-width: 1024px) { .catalog-layout { grid-template-columns: 260px 1fr; } }
.filter-form { display: flex; flex-direction: column; gap: 0.5rem; margin-bottom: 1.5rem; }
.filter-form label { font-size: 0.85rem; font-weight: 600; margin-top: 0.5rem; }
.filter-form input, .filter-form select, .admin-search, .admin-table input, .admin-card input, .admin-card textarea {
    border: 1px solid var(--border); border-radius: 8px; padding: 0.55rem 0.75rem; font-size: 0.9rem; font-family: inherit; width: 100%;
}
.filter-categories label { font-size: 0.85rem; font-weight: 600; display: flex; align-items: center; gap: 0.4rem; margin-bottom: 0.5rem; }
.cat-filter-btn { display: block; width: 100%; text-align: left; padding: 0.55rem 0.9rem; border: 1px solid var(--border); border-radius: 8px; margin-bottom: 0.4rem; font-size: 0.85rem; }
.cat-filter-btn.active { background: var(--naranja); color: #fff; border-color: var(--naranja); }
.empty-state { text-align: center; padding: 4rem 1rem; background: var(--card); border: 1px solid var(--border); border-radius: var(--radius); }

/* Product detail */
.producto-page { padding: 2rem 0; }
.breadcrumb { display: flex; gap: 0.5rem; align-items: center; font-size: 0.85rem; color: var(--muted); margin-bottom: 1.5rem; }
.producto-grid { display: grid; gap: 2rem; }
@media (min-width: 1024px) { .producto-grid { grid-template-columns: 1fr 1fr; } }
.producto-img { border: 1px solid var(--border); border-radius: var(--radius); background: #fff; overflow: hidden; }
.producto-img img { width: 100%; height: 100%; object-fit: contain; padding: 1.5rem; }
.producto-meta { display: flex; gap: 1rem; flex-wrap: wrap; margin: 0.5rem 0 1rem; }

/* Páginas de política (envíos, devoluciones) */
.politica-contenido { line-height: 1.7; }
.politica-contenido p { margin: 0 0 1rem; }
.politica-contenido ul, .politica-contenido ol { margin: 0 0 1rem 1.25rem; }
.politica-contenido h2, .politica-contenido h3 { margin-top: 1.5rem; }

/* Admin */
.admin-topbar { background: var(--gris); border-bottom: 3px solid var(--naranja); }
.admin-topbar-inner { display: flex; align-items: center; justify-content: space-between; padding: 0.75rem 1.5rem; }
.admin-topbar .logo { color: #fff; font-size: 1rem; }
.admin-topbar .logo em { font-style: normal; font-weight: 400; color: #9CA3AF; margin-left: 0.4rem; font-size: 0.8rem; }
.admin-topbar-link { color: #D1D5DB; font-size: 0.85rem; font-weight: 600; }
.admin-topbar-link:hover { color: #fff; }
.admin-body { background: #f0f1f2; }
.admin-login { padding: 3rem 0; }
.admin-dashboard { padding: 2rem 0 4rem; }
.admin-login-card { max-width: 380px; margin: 0 auto; background: var(--card); border: 1px solid var(--border); border-radius: var(--radius); padding: 1.75rem; display: flex; flex-direction: column; gap: 0.75rem; box-shadow: 0 2px 8px rgba(0,0,0,0.06); }
.admin-login-card input { border: 1px solid var(--border); border-radius: 8px; padding: 0.6rem 0.8rem; }
.error-text { color: var(--rojo); font-size: 0.85rem; }
.success-text { color: #166534; background: var(--verde-claro); border: 1px solid #86efac; border-radius: 8px; padding: 0.6rem 1rem; font-weight: 600; margin-bottom: 1.5rem; display: inline-block; }

.admin-header { display: flex; align-items: flex-start; justify-content: space-between; margin-bottom: 1.5rem; gap: 1rem; flex-wrap: wrap; }
.admin-header h1 { font-size: 1.6rem; margin-bottom: 0.15rem; }

.admin-tabs { display: flex; gap: 0.4rem; border-bottom: 1px solid var(--border); margin-bottom: 1.75rem; flex-wrap: wrap; }
.admin-tabs .tab { padding: 0.65rem 1rem; font-weight: 600; font-size: 0.9rem; color: var(--muted); border-bottom: 2px solid transparent; border-radius: 8px 8px 0 0; transition: background .15s, color .15s; }
.admin-tabs .tab:hover { background: var(--verde-claro); color: var(--verde); }
.admin-tabs .tab.active { color: var(--naranja-oscuro); border-color: var(--naranja); background: #fff7ed; }

.admin-section-narrow { max-width: 720px; }
.admin-card { background: var(--card); border: 1px solid var(--border); border-radius: var(--radius); padding: 1.5rem 1.75rem; display: flex; flex-direction: column; gap: 0.4rem; margin-bottom: 1.5rem; box-shadow: 0 1px 3px rgba(0,0,0,0.04); }
.admin-card h2 { font-size: 1.1rem; margin-bottom: 0.25rem; }
.admin-card label { font-size: 0.85rem; font-weight: 600; margin-top: 0.75rem; color: #374151; }
.admin-card textarea { font-family: monospace; font-size: 0.85rem; resize: vertical; }

.admin-section-header { display: flex; align-items: center; justify-content: space-between; margin-bottom: 0.75rem; flex-wrap: wrap; gap: 0.75rem; }
.admin-section-header h2 { font-size: 1.2rem; margin: 0; }
.admin-save-bar { margin-top: 1.25rem; }

.admin-table-wrap { overflow-x: auto; border-radius: var(--radius); border: 1px solid var(--border); box-shadow: 0 1px 3px rgba(0,0,0,0.04); }
.admin-table { width: 100%; min-width: 900px; table-layout: fixed; border-collapse: collapse; background: var(--card); }
.admin-table thead tr:first-child th { background: #f3f4f6; font-weight: 700; }
.admin-table th, .admin-table td { padding: 0.65rem 0.85rem; border-bottom: 1px solid var(--border); font-size: 0.85rem; text-align: left; }
.admin-table td { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.admin-table th { white-space: nowrap; }
.admin-table tbody tr:hover { background: #fafaf9; }
.admin-table tbody tr:nth-child(even) { background: #fbfbfa; }
.admin-table tbody tr:nth-child(even):hover { background: #fafaf9; }
.admin-table input[type="text"], .admin-table input[type="number"], .admin-table select { width: 100%; box-sizing: border-box; font-size: 0.82rem; padding: 0.4rem 0.5rem; }
.admin-table-filtros th { padding-top: 0.4rem; padding-bottom: 0.6rem; background: #fff; }
.admin-table col.col-nombre { width: 20%; }
.admin-table col.col-categoria { width: 18%; }
.admin-table col.col-precio { width: 9%; }
.admin-table col.col-check { width: 7%; }
.admin-table col.col-desc { width: 20%; }
.admin-table col.col-precio-custom { width: 11%; }
.filtro-precio { display: flex; gap: 0.3rem; }
.filtro-precio input { min-width: 0; }

/* Footer */
.site-footer { background: var(--card); border-top: 1px solid var(--border); padding: 3rem 0 1.5rem; }
.footer-grid { display: grid; gap: 2rem; grid-template-columns: repeat(2, 1fr); margin-bottom: 2rem; }
.footer-grid h3 { font-size: 1rem; }
.footer-grid ul { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 0.5rem; font-size: 0.9rem; }
.footer-grid ul a { color: var(--muted); }
.footer-grid ul a:hover { color: var(--verde); }
.social-links { display: flex; gap: 0.6rem; }
.social-links a { width: 36px; height: 36px; border-radius: 50%; border: 1px solid var(--border); display: flex; align-items: center; justify-content: center; font-size: 0.75rem; font-weight: 700; color: var(--muted); }
.footer-bottom { border-top: 1px solid var(--border); padding-top: 1.5rem; display: flex; flex-direction: column; gap: 0.5rem; font-size: 0.85rem; color: var(--muted); }
@media (min-width: 640px) {
    .footer-grid { grid-template-columns: repeat(4, 1fr); }
    .footer-bottom { flex-direction: row; justify-content: space-between; }
}
