:root {
    --brand: #25a244;
    --brand-dark: #1f8a39;
    --brand-light: #e8f5ec;
    --accent: #f0a500;
    --ink: #1b2230;
    --muted: #6c757d;
}

body {
    font-family: 'Segoe UI', system-ui, -apple-system, sans-serif;
    color: var(--ink);
    background: #fafbfc;
}

.topbar {
    background: var(--brand);
    color: #fff;
    padding: 6px 0;
    font-size: 13px;
}
.topbar a { color: #fff; text-decoration: none; }
.topbar a:hover { text-decoration: underline; }

.navbar-brand { font-size: 18px; font-weight: 700; color: var(--ink) !important; }
.brand-badge {
    display: inline-block;
    width: 36px; height: 36px; border-radius: 8px;
    background: var(--brand); color: #fff; font-weight: 800;
    text-align: center; line-height: 36px;
    font-size: 15px;
}
.nav-link { font-weight: 600; color: var(--ink) !important; }
.nav-link.active { color: var(--brand) !important; }
.btn-cta {
    background: var(--brand); color: #fff !important;
    padding: 8px 18px !important; border-radius: 6px; font-weight: 700;
}
.btn-cta:hover { background: var(--brand-dark); }

/* ---- Hero ---- */
.hero {
    background: linear-gradient(135deg, #25a244 0%, #1b8031 100%);
    color: #fff;
    padding: 80px 0 60px;
    position: relative;
    overflow: hidden;
}
.hero::before {
    content: '';
    position: absolute; inset: 0;
    background-image: radial-gradient(circle at 80% 30%, rgba(255,255,255,0.12) 0%, transparent 50%);
}
.hero .container { position: relative; z-index: 1; }
.hero .badge-hero {
    display: inline-block; padding: 6px 14px;
    background: rgba(255,255,255,0.22);
    border-radius: 20px; font-size: 13px; font-weight: 600;
    margin-bottom: 20px;
}
.hero h1 {
    font-size: 3rem; font-weight: 800; line-height: 1.1; margin-bottom: 20px;
}
.hero p.lead { font-size: 1.2rem; opacity: 0.95; }
.hero .btn-primary {
    background: #fff; color: var(--brand); font-weight: 700;
    padding: 12px 30px; border: none; border-radius: 6px;
}
.hero .btn-primary:hover { background: #f1f1f1; color: var(--brand-dark); }
.hero .btn-outline {
    background: transparent; color: #fff; font-weight: 600;
    padding: 12px 30px; border: 2px solid #fff; border-radius: 6px;
    text-decoration: none;
}
.hero .btn-outline:hover { background: #fff; color: var(--brand); }

@media (max-width: 768px) {
    .hero { padding: 50px 0 40px; }
    .hero h1 { font-size: 2rem; }
}

/* ---- Hero media (imagen o icono) ---- */
.hero-media {
    background: rgba(255,255,255,0.1);
    border-radius: 20px;
    padding: 20px;
    backdrop-filter: blur(10px);
    overflow: hidden;
}
.hero-media-default { padding: 40px; }
.hero-media-img {
    max-width: 100%; max-height: 320px;
    width: auto; height: auto;
    border-radius: 12px; display: block; margin: 0 auto;
    object-fit: contain;
}

/* ---- Stats ---- */
.stats {
    background: #fff;
    padding: 30px 0;
    border-bottom: 1px solid #e9ecef;
}
.stat-item { text-align: center; padding: 10px; }
.stat-item .num { font-size: 2.2rem; font-weight: 800; color: var(--brand); line-height: 1; }
.stat-item .lbl { font-size: 13px; color: var(--muted); margin-top: 5px; }

/* ---- Sections ---- */
.section { padding: 70px 0; }
.section-sm { padding: 40px 0; }
.section-title {
    font-size: 2.2rem; font-weight: 800; margin-bottom: 10px; color: var(--ink);
}
.section-lead { color: var(--muted); margin-bottom: 40px; font-size: 1.05rem; }

/* ---- Product cards ---- */
.product-card {
    background: #fff; border: 1px solid #e9ecef; border-radius: 12px;
    padding: 24px; height: 100%; transition: all 0.2s;
    display: flex; flex-direction: column;
}
.product-card:hover { transform: translateY(-4px); box-shadow: 0 10px 30px rgba(0,0,0,0.07); border-color: var(--brand); }
.product-card .icon {
    width: 56px; height: 56px; border-radius: 12px;
    background: var(--brand-light); color: var(--brand);
    display: flex; align-items: center; justify-content: center;
    font-size: 24px; margin-bottom: 16px;
}
.product-card h3 { font-size: 1.25rem; font-weight: 700; margin-bottom: 4px; }
.product-card .subtitle { color: var(--muted); font-size: 14px; margin-bottom: 16px; }
.product-card .meta {
    border-top: 1px solid #f1f3f5; padding-top: 14px; margin-top: auto;
    display: grid; grid-template-columns: 1fr 1fr; gap: 8px; font-size: 13px;
}
.product-card .meta .label { color: var(--muted); font-size: 11px; text-transform: uppercase; }
.product-card .meta .value { font-weight: 700; }
.product-card .badge-cat {
    display: inline-block; padding: 3px 10px;
    background: var(--brand-light); color: var(--brand);
    border-radius: 12px; font-size: 11px; font-weight: 700;
    margin-bottom: 12px;
}

/* ---- Product image (cuando hay imagen en lugar de icono) ---- */
.product-image {
    width: 100%;
    height: 180px;
    border-radius: 12px;
    background-size: cover;
    background-position: center;
    background-color: var(--brand-light);
    margin-bottom: 16px;
}

/* ---- Carrusel del hero ---- */
.hero-carousel { position: relative; }
.hero-carousel .carousel-indicators {
    bottom: 10px; z-index: 10;
}
.hero-carousel .carousel-indicators button {
    width: 10px; height: 10px; border-radius: 50%;
    background-color: rgba(255,255,255,0.6) !important;
    border: none; opacity: 1;
}
.hero-carousel .carousel-indicators button.active {
    background-color: #fff !important;
}
.hero-carousel .carousel-control-prev,
.hero-carousel .carousel-control-next {
    width: 48px; z-index: 10;
}
.hero-carousel .hero { padding: 70px 0 80px; }

/* ---- CTA WhatsApp dentro de noticias ---- */
.news-wa-cta {
    background: linear-gradient(135deg, #25d36612, #25d3661f);
    border: 1px solid #25d36655;
    border-radius: 12px;
    padding: 20px;
}
.news-wa-cta h5 { color: #128c7e; font-weight: 700; }
.news-wa-cta .btn-success { background: #25d366; border-color: #25d366; }
.news-wa-cta .btn-success:hover { background: #128c7e; border-color: #128c7e; }

/* ---- Sucursales ---- */
.branch-card {
    background: #fff; border-radius: 12px; padding: 24px;
    border: 1px solid #e9ecef; height: 100%;
}
.branch-card h4 { font-weight: 700; margin-bottom: 6px; }
.branch-card .address { color: var(--muted); font-size: 14px; margin-bottom: 12px; }
.branch-card .contact { font-size: 14px; }
.branch-card .contact i { color: var(--brand); width: 18px; }

/* ---- Seguros ---- */
.insurance-card {
    background: #fff; border-radius: 12px; padding: 30px 24px;
    border: 2px solid #e9ecef; height: 100%; text-align: center;
    transition: all 0.2s;
}
.insurance-card:hover { border-color: var(--brand); transform: translateY(-3px); }
.insurance-card.featured { border-color: var(--accent); position: relative; }
.insurance-card.featured::before {
    content: 'MAS POPULAR';
    position: absolute; top: -12px; left: 50%; transform: translateX(-50%);
    background: var(--accent); color: #fff; padding: 4px 14px;
    border-radius: 12px; font-size: 11px; font-weight: 700;
}
.insurance-card .paquete-name {
    font-size: 14px; font-weight: 700; color: var(--muted); text-transform: uppercase; letter-spacing: 2px;
}
.insurance-card .price {
    font-size: 2.6rem; font-weight: 800; color: var(--brand); margin: 8px 0;
}
.insurance-card .price small { font-size: 14px; color: var(--muted); font-weight: 400; }
.insurance-card ul { list-style: none; padding: 0; margin: 20px 0; text-align: left; }
.insurance-card ul li { padding: 8px 0; border-bottom: 1px solid #f1f3f5; font-size: 14px; }
.insurance-card ul li i { color: var(--brand); margin-right: 8px; }
.insurance-card ul li:last-child { border-bottom: none; }

/* ---- Form ---- */
.form-section { background: #fff; border-radius: 12px; padding: 32px; box-shadow: 0 2px 14px rgba(0,0,0,0.04); }
.form-section label { font-weight: 600; font-size: 14px; margin-top: 12px; display: block; }
.form-section .form-control { padding: 10px 14px; border-radius: 6px; }
.form-section .btn-submit {
    background: var(--brand); color: #fff; padding: 12px 30px;
    border: none; border-radius: 6px; font-weight: 700; font-size: 15px;
    margin-top: 20px; width: 100%;
}
.form-section .btn-submit:hover { background: var(--brand-dark); }

/* ---- Simulador ---- */
.simulator {
    background: linear-gradient(135deg, #fef7e6 0%, #fff7d6 100%);
    border-radius: 16px; padding: 32px; border: 1px solid #f0d98a;
}
.simulator h3 { color: var(--accent); font-weight: 800; }
.sim-result {
    background: #fff; border-radius: 10px; padding: 20px; margin-top: 20px;
    border-left: 4px solid var(--brand);
}
.sim-result .cuota {
    font-size: 2rem; font-weight: 800; color: var(--brand);
}

/* ---- Footer ---- */
.footer {
    background: #1b2230;
    color: #fff;
    padding: 50px 0 30px;
    margin-top: 60px;
}
.footer a { text-decoration: none; }
.footer a:hover { color: #fff !important; }

/* ---- WA float ---- */
.wa-float {
    position: fixed; bottom: 24px; right: 24px; z-index: 999;
    width: 56px; height: 56px; border-radius: 50%;
    background: #25d366; color: #fff;
    display: flex; align-items: center; justify-content: center;
    font-size: 28px; text-decoration: none;
    box-shadow: 0 6px 20px rgba(37,211,102,0.4);
    transition: transform 0.2s;
}
.wa-float:hover { color: #fff; transform: scale(1.08); }

/* ---- Equipo ---- */
.team-card {
    background: #fff; border-radius: 16px; padding: 28px 20px;
    text-align: center; border: 1px solid #e9ecef; height: 100%;
    transition: all 0.2s;
}
.team-card:hover { transform: translateY(-4px); box-shadow: 0 12px 30px rgba(0,0,0,0.08); border-color: var(--brand); }
.team-photo {
    width: 140px; height: 140px; border-radius: 50%;
    object-fit: cover; margin: 0 auto 16px;
    border: 4px solid var(--brand-light); display: block;
}
.team-photo-placeholder {
    background: var(--brand-light); color: var(--brand);
    display: flex; align-items: center; justify-content: center;
    font-size: 50px;
}
.team-name { font-weight: 700; margin-bottom: 4px; }
.team-cargo {
    color: var(--brand); font-weight: 600;
    text-transform: uppercase; font-size: 13px;
    letter-spacing: 1px; margin-bottom: 12px;
}
.team-bio { color: var(--muted); font-size: 14px; }
.team-social {
    margin-top: 16px; display: flex;
    justify-content: center; gap: 10px;
}
.team-social a {
    width: 36px; height: 36px; border-radius: 50%;
    background: var(--brand-light); color: var(--brand);
    display: flex; align-items: center; justify-content: center;
    text-decoration: none; transition: all 0.2s;
}
.team-social a:hover { background: var(--brand); color: #fff; }

/* ---- Noticias ---- */
.news-card {
    background: #fff; border-radius: 12px;
    border: 1px solid #e9ecef; overflow: hidden;
    display: block; text-decoration: none; color: inherit;
    height: 100%; transition: all 0.2s;
}
.news-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 30px rgba(0,0,0,0.08);
    border-color: var(--brand); color: inherit; text-decoration: none;
}
.news-img {
    width: 100%; height: 200px;
    background-size: cover; background-position: center;
    background-color: var(--brand-light);
}
.news-img-placeholder {
    display: flex; align-items: center; justify-content: center;
    color: var(--brand); font-size: 50px;
}
.news-body { padding: 20px; }
.news-cat {
    display: inline-block; padding: 3px 10px;
    background: var(--brand-light); color: var(--brand);
    border-radius: 12px; font-size: 11px; font-weight: 700;
    text-transform: uppercase; letter-spacing: 1px; margin-bottom: 10px;
}
.news-titulo { font-weight: 700; margin-bottom: 8px; font-size: 1.1rem; }
.news-extracto {
    color: var(--muted); font-size: 14px;
    display: -webkit-box; -webkit-line-clamp: 3;
    -webkit-box-orient: vertical; overflow: hidden;
    margin-bottom: 12px;
}
.news-meta { color: var(--muted); font-size: 12px; }

.article-body img { max-width: 100%; height: auto; border-radius: 8px; margin: 16px 0; }
.article-body h2, .article-body h3 { color: var(--ink); margin-top: 28px; }
.article-body p { line-height: 1.7; }
.article-body ul, .article-body ol { line-height: 1.7; padding-left: 24px; }

/* ---- Alerts ---- */
.alert-ok { background: #e8f5ec; border-left: 4px solid var(--brand); color: #1b5e20; padding: 12px 16px; border-radius: 4px; }
.alert-err { background: #fff3f3; border-left: 4px solid #dc3545; color: #881c1c; padding: 12px 16px; border-radius: 4px; }

/* ---- Misc ---- */
.text-brand { color: var(--brand); }
.bg-brand { background: var(--brand); color: #fff; }

/* ---- Redes sociales (footer) ---- */
.redes-icon {
    display: inline-flex; align-items: center; justify-content: center;
    width: 44px; height: 44px; border-radius: 50%;
    background: rgba(255,255,255,0.12); color: #fff;
    transition: background 180ms ease, transform 180ms ease;
    text-decoration: none;
}
.redes-icon:hover {
    background: var(--brand); color: #fff;
    transform: translateY(-2px);
}
.redes-icon i { font-size: 20px; }

/* ---- Beneficios (cards icono + titulo + descripcion) ---- */
.beneficio-card {
    padding: 18px 12px; height: 100%;
    display: flex; flex-direction: column; align-items: center;
    text-align: center;
}
.beneficio-icon {
    width: 56px; height: 56px; border-radius: 50%;
    background: var(--brand-light, #e8f7f8); color: var(--brand);
    display: inline-flex; align-items: center; justify-content: center;
    font-size: 24px; margin-bottom: 12px;
    transition: transform 200ms ease;
}
.beneficio-card:hover .beneficio-icon { transform: scale(1.08); }
.beneficio-titulo {
    font-weight: 700; color: var(--ink);
    font-size: 14px; line-height: 1.3; margin-bottom: 6px;
}
.beneficio-desc { color: var(--muted); font-size: 12px; line-height: 1.4; }

/* ---- Medios de pago ---- */
.medios-pago-grid {
    display: grid; gap: 16px;
    grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
    align-items: stretch;
}
.medio-pago-card {
    background: #fff; border: 1px solid #e9ecef; border-radius: 12px;
    padding: 16px 12px; text-align: center;
    text-decoration: none; color: inherit;
    transition: transform 180ms ease, box-shadow 180ms ease;
    display: flex; flex-direction: column; align-items: center; justify-content: center;
}
a.medio-pago-card:hover {
    transform: translateY(-3px); box-shadow: 0 6px 18px rgba(0,0,0,0.08);
    border-color: var(--brand);
}
.medio-pago-logo {
    max-width: 100%; max-height: 60px; height: auto;
    object-fit: contain; margin-bottom: 8px;
}
.medio-pago-fallback { font-size: 32px; color: var(--brand); margin-bottom: 8px; }
.medio-pago-nombre { font-weight: 700; font-size: 13px; color: var(--ink); }
.medio-pago-desc { font-size: 11px; color: var(--muted); margin-top: 2px; }

/* ---- Galerias (nosotros.php) ---- */
.galeria-item {
    display: block; text-decoration: none; color: inherit;
    background: #fff; border: 1px solid #e9ecef; border-radius: 10px;
    overflow: hidden;
    transition: transform 200ms ease, box-shadow 200ms ease;
    height: 100%;
}
.galeria-item:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 22px rgba(0,0,0,0.10);
    color: inherit;
    text-decoration: none;
}
.galeria-img-wrap {
    width: 100%; aspect-ratio: 4 / 3;
    overflow: hidden; background: #f1f3f5;
}
.galeria-img {
    width: 100%; height: 100%; object-fit: cover;
    transition: transform 350ms ease;
}
.galeria-item:hover .galeria-img { transform: scale(1.04); }
.galeria-caption { padding: 10px 12px; }
.galeria-titulo { font-weight: 700; font-size: 14px; color: var(--ink); }
.galeria-desc { font-size: 12px; color: var(--muted); margin-top: 2px; line-height: 1.35; }

/* ---- Vacantes (bolsa de trabajo) ---- */
.vacante-meta {
    display: flex; gap: 16px; flex-wrap: wrap;
    color: rgba(255,255,255,0.85); font-size: 13px;
}
.vacante-meta span i { margin-right: 4px; }
.vacante-card {
    display: block; height: 100%;
    background: #fff; border: 1px solid #e9ecef; border-radius: 12px;
    padding: 0; text-decoration: none; color: inherit;
    overflow: hidden;
    transition: transform 200ms ease, box-shadow 200ms ease, border-color 200ms ease;
}
.vacante-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 22px rgba(0,0,0,0.10);
    border-color: var(--brand);
    text-decoration: none; color: inherit;
}
.vacante-card-body { padding: 18px 20px; }
.vacante-card-titulo {
    color: var(--ink); font-weight: 700;
    font-size: 17px; margin-bottom: 6px; line-height: 1.3;
}
.vacante-card-sub {
    color: var(--muted); font-size: 13px;
    line-height: 1.45; margin-bottom: 10px;
}
.vacante-card-meta {
    display: flex; gap: 12px; flex-wrap: wrap;
    color: var(--muted); font-size: 12px; margin-bottom: 8px;
}
.vacante-card-meta i { margin-right: 3px; }
.vacante-card-salario {
    background: #e8f5ec; color: #1b5e20;
    padding: 4px 10px; border-radius: 12px;
    display: inline-block; font-weight: 600; font-size: 12px;
    margin-bottom: 12px;
}
.vacante-card-cta {
    color: var(--brand); font-weight: 600;
    font-size: 13px;
}

/* ---- Directorio de negocios ---- */
.negocio-card {
    background: #fff; border: 1px solid #e9ecef; border-radius: 12px;
    overflow: hidden; height: 100%;
    transition: transform 200ms ease, box-shadow 200ms ease;
    display: flex; flex-direction: column;
}
.negocio-card:hover { transform: translateY(-3px); box-shadow: 0 8px 22px rgba(0,0,0,0.10); }
.negocio-img-wrap { position: relative; aspect-ratio: 16 / 9; background: #f1f3f5; overflow: hidden; }
.negocio-img { width: 100%; height: 100%; object-fit: cover; }
.negocio-img-fallback {
    width: 100%; height: 100%;
    display: flex; align-items: center; justify-content: center;
    font-size: 48px; color: #adb5bd;
}
.negocio-cat {
    position: absolute; top: 10px; left: 10px;
    background: rgba(0,0,0,0.7); color: #fff;
    padding: 3px 10px; font-size: 11px; font-weight: 600;
    border-radius: 12px; text-transform: uppercase; letter-spacing: 0.5px;
}
.negocio-body { padding: 14px 16px; flex-grow: 1; display: flex; flex-direction: column; }
.negocio-nombre {
    font-weight: 700; font-size: 16px; color: var(--ink);
    margin-bottom: 6px; line-height: 1.3;
}
.negocio-desc {
    color: var(--muted); font-size: 13px; line-height: 1.45;
    margin-bottom: 10px; flex-grow: 1;
}
.negocio-meta {
    color: var(--muted); font-size: 12px;
    margin-bottom: 10px; line-height: 1.6;
}
.negocio-meta i { margin-right: 4px; width: 12px; }
.negocio-actions { display: flex; gap: 6px; }
.negocio-actions .btn { padding: 4px 10px; }
