/* =============================================
   Ocho Fuentes — style.css
   ============================================= */

/* --- Variables --- */
:root {
    --primary:   #20419C;
    --secondary: #FF8500;
    --text:      #1B0E00;
    --white:     #ffffff;
    --gray-bg:   #ebebeb;
    --font:      'Satoshi-Variable', sans-serif;
}

/* --- Reset & Base --- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body { font-family: var(--font); color: var(--text); background: var(--white); overflow-x: hidden; }
img  { max-width: 100%; height: auto; }
a    { text-decoration: none; color: inherit; }

/* =============================================
   TOPBAR — sticky con transparencia
   ============================================= */
.topbar {
    position: sticky;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1100;
    background: rgba(17, 17, 17, 0.80);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    padding: 7px 0;
    font-size: 13px;
    color: #ccc;
    transition: background 0.35s ease, box-shadow 0.35s ease, padding 0.35s ease;
}

.topbar.scrolled {
    background: rgba(10, 10, 10, 0.96);
    box-shadow: 0 2px 16px rgba(0,0,0,0.35);
    padding: 5px 0;
}

.topbar a { color: #ccc; transition: color 0.2s; }
.topbar a:hover { color: var(--white); }

.topbar .social-icons { display: flex; align-items: center; gap: 14px; }
.topbar .social-icons a { font-size: 15px; }

.topbar .contact-info a {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 13px;
}

/* =============================================
   NAVBAR
   ============================================= */
.navbar-main {
    position: sticky;
    top: 36px; /* altura del topbar */
    left: 0;
    width: 100%;
    z-index: 1090;
    background: var(--white);
    padding: 10px 0;
    box-shadow: 0 2px 12px rgba(0,0,0,0.08);
    transition: top 0.35s ease, box-shadow 0.35s ease, padding 0.35s ease;
}

.navbar-main.scrolled {
    top: 30px;
    box-shadow: 0 4px 24px rgba(0,0,0,0.13);
}

/* Espacio para compensar los elementos fixed */
.navbar-offset {
    height: calc(36px + 72px); /* topbar + navbar */
}

.navbar-main .logo img {
    height: 52px;
    width: auto;
    object-fit: contain;
}

.navbar-main .nav-links {
    display: flex;
    align-items: center;
    gap: 8px;
    list-style: none;
    margin: 0;
    padding: 0;
}

.navbar-main .nav-links li a {
    font-weight: 500;
    font-size: 15px;
    color: var(--text);
    padding: 8px 16px;
    border-radius: 6px;
    transition: color 0.2s, background 0.2s;
}

.navbar-main .nav-links li a:hover {
    color: var(--primary);
    background: rgba(32,65,156,0.06);
}

.navbar-main .nav-links li a.btn-donde {
    background: var(--secondary);
    color: var(--white);
    padding: 9px 22px;
    border-radius: 50px;
    font-weight: 700;
    transition: background 0.2s, transform 0.15s;
}

.navbar-main .nav-links li a.btn-donde:hover {
    background: #e07600;
    transform: translateY(-1px);
}

/* Hamburger */
.navbar-toggler-custom {
    border: none;
    background: none;
    cursor: pointer;
    padding: 4px;
    display: none;
    flex-direction: column;
    gap: 5px;
}

.navbar-toggler-custom span {
    display: block;
    width: 26px;
    height: 2px;
    background: var(--text);
    border-radius: 2px;
    transition: all 0.3s;
}

@media (max-width: 991px) {
    .navbar-toggler-custom { display: flex; }

    .nav-links-wrapper {
        display: none;
        width: 100%;
        padding: 12px 0 6px;
    }

    .nav-links-wrapper.open { display: block; }

    .navbar-main .nav-links {
        flex-direction: column;
        align-items: flex-start;
        gap: 4px;
    }

    .navbar-main .nav-links li { width: 100%; }
    .navbar-main .nav-links li a { display: block; width: 100%; }
    .navbar-main .nav-links li a.btn-donde {
        display: inline-block;
        width: auto;
        margin-top: 8px;
    }
}

/* =============================================
   HERO
   ============================================= */
.hero {
    position: relative;
    background: var(--primary);
    overflow: hidden;
    min-height: 520px;
}

/* Bloque naranja diagonal derecha */
.hero::after {
    content: '';
    position: absolute;
    top: 0; right: 0;
    width: 42%;
    height: 100%;
    background: var(--secondary);
    clip-path: polygon(18% 0%, 100% 0%, 100% 100%, 0% 100%);
    z-index: 0;
}

.hero-inner {
    position: relative;
    z-index: 3;
    padding: 60px 0 110px;
}

/* Chips */
.hero-chips {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 28px;
}

.hero-chip {
    background: rgba(255,255,255,0.15);
    color: var(--white);
    border: 1px solid rgba(255,255,255,0.35);
    border-radius: 50px;
    padding: 5px 16px;
    font-size: 12px;
    font-weight: 600;
    letter-spacing: 0.5px;
    text-transform: uppercase;
    backdrop-filter: blur(4px);
}

.hero-img-texto {
    max-width: 420px;
    width: 100%;
}

.hero-img-producto {
    position: relative;
    z-index: 4;
    max-width: 100%;
    filter: drop-shadow(0 20px 40px rgba(0,0,0,0.25));
    animation: float 4s ease-in-out infinite;
}

@keyframes float {
    0%, 100% { transform: translateY(0); }
    50%       { transform: translateY(-12px); }
}

/* Decorativos */
.hero-deco { position: absolute; pointer-events: none; z-index: 4; }
.hero-deco.estrella-1 { top: 12%; left: 5%; width: 50px; animation: spin-slow 12s linear infinite; }
.hero-deco.estrella-2 { bottom: 20%; left: 38%; width: 36px; animation: spin-slow 18s linear infinite reverse; }
.hero-deco.lineas     { bottom: 18%; left: 2%; width: 120px; opacity: 0.6; }

@keyframes spin-slow {
    from { transform: rotate(0deg); }
    to   { transform: rotate(360deg); }
}

/* Indicadores */
.hero-indicators {
    position: absolute;
    bottom: 70px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 8px;
    z-index: 5;
}

.hero-indicators button {
    width: 10px; height: 10px;
    border-radius: 50%;
    border: 2px solid rgba(255,255,255,0.5);
    background: transparent;
    cursor: pointer;
    padding: 0;
    transition: all 0.3s;
}

.hero-indicators button.active {
    background: var(--white);
    border-color: var(--white);
    transform: scale(1.2);
}

/* Wave hero → gris */
.hero-wave {
    position: absolute;
    bottom: -2px; left: 0;
    width: 100%;
    z-index: 2;
    line-height: 0;
}

.hero-wave svg { display: block; width: 100%; }

/* Slide */
.hero-slide { display: none; animation: fadeInSlide 0.6s ease; }
.hero-slide.active { display: block; }

@keyframes fadeInSlide {
    from { opacity: 0; transform: translateY(10px); }
    to   { opacity: 1; transform: translateY(0); }
}

@media (max-width: 767px) {
    .hero::after { clip-path: none; width: 100%; height: 45%; top: auto; bottom: 0; }
    .hero-inner  { padding: 40px 0 90px; text-align: center; }
    .hero-chips  { justify-content: center; }
    .hero-img-texto  { max-width: 280px; margin: 0 auto 24px; display: block; }
    .hero-img-producto { max-width: 260px; margin: 0 auto; display: block; }
    .hero-deco { display: none; }
}

/* =============================================
   SECCIÓN PRODUCTOS
   ============================================= */
.section-productos {
    position: relative;
    background: var(--white);
    padding: 0;
    overflow: visible;
}

/* Ondas */
.productos-wave { width: 100%; line-height: 0; display: block; }
.productos-wave svg { display: block; width: 100%; height: 110px; }

/* Contenido entre ondas */
.productos-content {
    background: var(--gray-bg);
    padding: 30px 0 60px;
}

/* Wrapper carrusel */
.productos-carousel-wrapper {
    position: relative;
    display: flex;
    align-items: center;
}

/* Flechas */
.productos-arrow {
    flex-shrink: 0;
    width: 46px; height: 46px;
    border-radius: 50%;
    border: 2px solid #ddd;
    background: var(--white);
    color: #999;
    font-size: 18px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.25s;
    z-index: 10;
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
}

.productos-arrow:hover { border-color: var(--primary); color: var(--primary); box-shadow: 0 4px 16px rgba(32,65,156,0.15); }
.productos-arrow.prev { left: -24px; }
.productos-arrow.next { right: -24px; }

/* Track */
.productos-track-outer { overflow: hidden; flex: 1; padding: 40px 10px 20px; }
.productos-track {
    display: flex;
    gap: 24px;
    transition: transform 0.5s cubic-bezier(0.4,0,0.2,1);
    align-items: center;
}

/* Card */
.producto-card {
    flex: 0 0 calc(33.333% - 16px);
    border-radius: 20px;
    padding: 28px 28px 32px;
    position: relative;
    background: var(--secondary);
    color: var(--white);
    text-decoration: none;
    display: block;
    transition: background 0.35s ease, transform 0.35s ease, box-shadow 0.35s ease;
    min-height: 320px;
    overflow: visible;
}

.producto-card.active {
    background: var(--primary);
    transform: scale(1.04);
    box-shadow: 0 20px 50px rgba(32,65,156,0.25);
    z-index: 2;
}

.producto-card-img {
    position: absolute;
    top: -30px; right: -10px;
    width: 52%;
    max-width: 200px;
    object-fit: contain;
    filter: drop-shadow(0 8px 20px rgba(0,0,0,0.2));
    transform: rotate(8deg);
    transition: transform 0.4s cubic-bezier(0.34,1.56,0.64,1);
    pointer-events: none;
}

.producto-card:hover .producto-card-img { transform: rotate(15deg) scale(1.12); }
.producto-card:hover { background: var(--primary); box-shadow: 0 20px 50px rgba(32,65,156,0.2); }
.producto-card.active:hover { background: var(--secondary); }

.producto-card-body { padding-top: 60px; }

.producto-card-nombre {
    font-size: 26px;
    font-weight: 800;
    line-height: 1.15;
    margin-bottom: 6px;
    color: var(--white);
}

.producto-card-divider {
    width: 36px; height: 3px;
    background: rgba(255,255,255,0.5);
    border-radius: 2px;
    margin: 12px 0 16px;
}

.producto-card-desc {
    font-size: 14px;
    line-height: 1.65;
    color: rgba(255,255,255,0.88);
    margin: 0;
}

/* Dots */
.productos-dots { display: flex; justify-content: center; gap: 8px; margin-top: 32px; }
.productos-dots button {
    width: 10px; height: 10px;
    border-radius: 50%;
    border: 2px solid #bbb;
    background: transparent;
    cursor: pointer;
    padding: 0;
    transition: all 0.3s;
}
.productos-dots button.active { background: var(--primary); border-color: var(--primary); transform: scale(1.2); }

@media (max-width: 991px) { .producto-card { flex: 0 0 calc(50% - 12px); } }
@media (max-width: 600px)  {
    .producto-card { flex: 0 0 85%; }
    .productos-arrow.prev { left: -16px; }
    .productos-arrow.next { right: -16px; }
}

/* =============================================
   FOOTER
   ============================================= */
.footer {
    background: linear-gradient(to bottom, rgba(32,65,156,0.95), rgba(10,20,60,0.99));
    padding: 60px 0 32px;
}

.footer-inner {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 18px;
}

.footer-logo img {
    height: 64px;
    width: auto;
    filter: none;
}

.footer-social { display: flex; gap: 16px; }
.footer-social a {
    color: rgba(255,255,255,0.7);
    font-size: 20px;
    transition: color 0.2s, transform 0.2s;
}
.footer-social a:hover { color: var(--secondary); transform: translateY(-2px); }

.footer-credits { color: rgba(255,255,255,0.5); font-size: 13px; margin: 0; }
.footer-credits strong { color: var(--secondary); }
.footer-copy    { color: rgba(255,255,255,0.4); font-size: 12px; margin: 0; }
.footer-address { color: rgba(255,255,255,0.35); font-size: 12px; margin: 0; }

/* =============================================
   UTILIDADES
   ============================================= */
.section-py { padding: 80px 0; }
.text-primary-custom   { color: var(--primary); }
.text-secondary-custom { color: var(--secondary); }

/* =============================================
   NAVBAR — estático (no fixed)
   ============================================= */
.navbar-main {
    position: static !important;
    top: auto !important;
}

/* Quitar offset ya que navbar no es fixed */
.navbar-offset {
    display: none !important;
}
