/* =====================================================
   ESTILOS PRINCIPALES DE CALCULA-FÁCIL.COM
   Paleta: 
   - Primario Oscuro: #1f2933 / #2f3e46 / #3a5a6a
   - Acento Naranja:  #e07a5f
   - Fondos:          #f8fafc / #eef3f7 / #f1f5f9
===================================================== */

/* =====================================================
   1️⃣ ESTILOS GENERALES DEL SITIO
===================================================== */
body {
    font-family: 'Inter', sans-serif;
    margin: 0;
    background: linear-gradient(180deg, #f8fafc 0%, #eef3f7 100%);
    color: #1f2933;
}

h1, h2, h3, h4 {
    font-weight: 600;
    letter-spacing: -0.5px;
}

p {
    line-height: 1.6;
    color: #4a5568;
}

.section-title {
    text-align: center;
    margin-bottom: 40px;
}

/* =====================================================
   2️⃣ NAVEGACIÓN (NAVBAR)
===================================================== */
.navbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 40px;
    background: white;
    box-shadow: 0 4px 15px rgba(0,0,0,0.05);
    position: sticky;
    top: 0;
    z-index: 1000;
}

.navbar.scrolled {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    box-shadow: 0 8px 25px rgba(0,0,0,0.08);
    padding: 10px 40px;
    transition: all 0.3s ease;
}

.logo {
    font-weight: 700;
    font-size: 30px;
    color: #2f3e46;
}

.menu {
    list-style: none;
    display: flex;
    gap: 25px;
    margin: 0;
    padding: 0;
}

.menu a {
    text-decoration: none;
    color: #1f2933;
    transition: 0.3s;
}

.menu a:hover {
    color: #e07a5f;
}

.nav-cta {
    background: #e07a5f;
    color: white;
    padding: 10px 18px;
    border-radius: 8px;
    text-decoration: none;
    transition: 0.3s;
}

.nav-cta:hover {
    background: #2f3e46;
}

/* ================= MENÚ DESPLEGABLE (DROPDOWN) ================= */
.dropdown {
    position: relative;
    display: inline-block;
}

.dropdown-content {
    display: none;
    position: absolute;
    background-color: white;
    min-width: 250px;
    box-shadow: 0 15px 35px rgba(0,0,0,0.08);
    border-radius: 14px;
    padding: 10px 0;
    z-index: 2000;
    top: 100%;
    left: 50%;
    transform: translateX(-50%);
    border: 1px solid #e2e8f0;
}

.dropdown-content::before {
    content: "";
    position: absolute;
    top: -6px;
    left: 50%;
    transform: translateX(-50%) rotate(45deg);
    width: 12px;
    height: 12px;
    background-color: white;
    border-top: 1px solid #e2e8f0;
    border-left: 1px solid #e2e8f0;
}

.dropdown:hover .dropdown-content {
    display: block;
    animation: fadeInDropdown 0.3s ease;
}

@keyframes fadeInDropdown {
    from { opacity: 0; transform: translate(-50%, 15px); }
    to { opacity: 1; transform: translate(-50%, 0); }
}

.dropdown-content a {
    color: #4a5568;
    padding: 10px 20px;
    text-decoration: none;
    display: block;
    font-size: 14px;
    transition: background 0.2s, color 0.2s;
    position: relative;
    z-index: 10;
}

.dropdown-content a:hover {
    background-color: #f8fafc;
    color: #3a5a6a;
    font-weight: 500;
}

.dropdown-category {
    padding: 15px 20px 5px 20px;
    font-size: 12px;
    font-weight: 700;
    color: #94a3b8;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    position: relative;
    z-index: 10;
}

/* =====================================================
   3️⃣ HERO (SECCIÓN PRINCIPAL SUPERIOR)
===================================================== */
.hero {
    background: linear-gradient(135deg, #1f2933 0%, #3a5a6a 100%);
    color: white;
    padding: 110px 20px;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.hero::before,
.hero::after {
    content: "";
    position: absolute;
    width: 400px;
    height: 400px;
    border-radius: 50%;
    filter: blur(120px);
    opacity: 0.2;
    animation: flotarFondo 8s infinite alternate ease-in-out;
}

.hero::before {
    background: #ffffff;
    top: -100px;
    left: -100px;
}

.hero::after {
    background: #90caf9;
    bottom: -150px;
    right: -150px;
    animation-delay: 2s;
}

@keyframes flotarFondo {
    0% { transform: translate(0,0); }
    100% { transform: translate(50px, 40px); }
}

.hero h2 {
    color: white;
    font-size: 32px;
    max-width: 750px;
    margin: 0 auto 20px auto;
}

.hero p {
    color: rgba(255, 255, 255, 0.85);
    font-size: 18px;
    margin-bottom: 30px;
}

.hero-button {
    background: white;
    color: #2f3e46;
    padding: 14px 28px;
    border-radius: 10px;
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s ease;
    display: inline-block;
}

.hero-button:hover {
    background: #e07a5f;
    color: white;
    transform: translateY(-3px);
    box-shadow: 0 8px 20px rgba(0,0,0,0.2);
}

.hero-button:active {
    transform: scale(0.96);
}

.hero-graphic {
    margin-top: 40px;
}

.hero-graphic img {
    width: 120px;
    opacity: 0.9;
    animation: flotar 3s ease-in-out infinite;
}

@keyframes flotar {
    0% { transform: translateY(0px); }
    50% { transform: translateY(-10px); }
    100% { transform: translateY(0px); }
}

/* =====================================================
   4️⃣ ESTADÍSTICAS Y COMO FUNCIONA
===================================================== */
.stats {
    display: flex;
    justify-content: center;
    gap: 50px;
    padding: 60px 20px;
    background: #f1f5f9;
    flex-wrap: wrap;
    text-align: center;
}

.stat-box h3 {
    font-size: 28px;
    margin: 0;
    color: #2f3e46;
}

.how-it-works {
    padding: 80px 20px;
    text-align: center;
}

.steps {
    display: flex;
    justify-content: center;
    gap: 40px;
    flex-wrap: wrap;
}

.step {
    background: rgba(255, 255, 255, 0.6);
    backdrop-filter: blur(10px);
    padding: 30px;
    border-radius: 18px;
    max-width: 280px;
    box-shadow: 0 10px 25px rgba(0,0,0,0.08);
    transition: 0.3s;
    border: 1px solid rgba(255, 255, 255, 0.4);
}

.step:hover {
    transform: translateY(-10px);
    box-shadow: 0 20px 40px rgba(0,0,0,0.12);
}

.step-number {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background: #e07a5f;
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    margin: 0 auto 15px auto;
}

/* =====================================================
   5️⃣ GRILLA DE HERRAMIENTAS (CARDS)
===================================================== */
.tools-section {
    padding: 80px 20px;
    text-align: center;
}

.category-title {
    text-align: left;
    max-width: 1000px;
    margin: 60px auto 25px auto;
    color: #2f3e46;
    font-size: 22px;
    border-bottom: 2px solid #eef3f7;
    padding-bottom: 15px;
    display: flex;
    align-items: center;
    gap: 10px;
}

@media (max-width: 1050px) {
    .category-title {
        margin-left: 20px;
        margin-right: 20px;
    }
}

.tools-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
    max-width: 1000px;
    margin: 20px auto 0 auto;
}

.tool-card {
    background: white;
    padding: 30px;
    border-radius: 20px;
    box-shadow: 0 8px 25px rgba(0,0,0,0.06);
    transition: transform 0.45s cubic-bezier(0.22, 1, 0.36, 1), box-shadow 0.45s cubic-bezier(0.22, 1, 0.36, 1);
    position: relative;
    overflow: hidden;
}

.tool-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 18px 35px rgba(0,0,0,0.12);
}

.tool-card::before {
    content: "";
    position: absolute;
    inset: 0;
    border-radius: 20px;
    background: linear-gradient(135deg, rgba(58,90,106,0.05), transparent);
    opacity: 0;
    transition: opacity 0.3s ease;
    pointer-events: none;
}

.tool-card:hover::before {
    opacity: 2;
}

.tool-icon {
    width: 80px;
    height: 80px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 25px auto;
    background: rgba(58, 90, 106, 0.08);
    border-radius: 50%;
    transition: all 0.4s ease;
}

.tool-icon svg {
    width: 38px;
    height: 38px;
    color: #e07a5f;
    transition: all 0.4s ease;
}

.tool-card:hover .tool-icon {
    background: #e07a5f;
    transform: scale(1.08);
}

.tool-card:hover .tool-icon svg {
    color: white;
    transform: scale(1.1);
}

.tool-button {
    display: inline-block;
    margin-top: 20px;
    background: white;
    color: #3a5a6a;
    padding: 12px 22px;
    border-radius: 8px;
    text-decoration: none;
    font-weight: 500;
    transition: all 0.2s ease;
    border: 1px solid #3a5a6a;
}

.tool-button:hover {
    background: white;
    color: #e07a5f;
    border: 1px solid #e07a5f;
}

.tool-button:active {
    transform: scale(0.96);
}

/* =====================================================
   6️⃣ BENEFICIOS 
===================================================== */
.beneficios {
    background: #eef3f7;
    padding: 100px 20px;
    text-align: center;
}

.container-beneficios {
    max-width: 1100px;
    margin: 0 auto;
}

.beneficios h2 {
    margin-bottom: 60px;
    color: #2f3e46;
    font-size: 28px;
}

.beneficios-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 40px;
}

.beneficio-item {
    background: transparent;
    padding: 20px;
    transition: transform 0.3s ease;
}

.beneficio-item:hover {
    transform: translateY(-5px);
}

.beneficio-icon {
    width: 70px;
    height: 70px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 25px auto;
    background: rgba(224, 122, 95, 0.15);
    border-radius: 50%;
    transition: all 0.3s ease;
}

.beneficio-icon svg {
    width: 32px;
    height: 32px;
    color: #e07a5f;
    transition: all 0.3s ease;
}

.beneficio-item:hover .beneficio-icon {
    background: #e07a5f;
    box-shadow: 0 10px 20px rgba(224, 122, 95, 0.3);
}

.beneficio-item:hover .beneficio-icon svg {
    color: white;
    transform: scale(1.1);
}

.beneficio-item h3 {
    font-size: 19px;
    margin-bottom: 12px;
    color: #1f2933;
    font-weight: 600;
}

.beneficio-item p {
    font-size: 15px;
    color: #4a5568;
    line-height: 1.6;
    margin: 0;
}

/* =====================================================
   7️⃣ CALL TO ACTION (CTA) Y FOOTER
===================================================== */
.final-cta {
    background: linear-gradient(135deg, #1f2933, #2f3e46);
    color: white;
    text-align: center;
    padding: 80px 20px;
    border-radius: 20px;
    margin: 80px 20px;
}

.final-cta h2 {
    font-size: 28px;
    margin-bottom: 25px;
    color: white;
}

/* (El CSS del Footer ahora está inyectado directamente en el HTML en tu index, 
    pero aquí dejamos las clases por si decides moverlas) */
footer p { margin: 10px 0; color: rgba(255, 255, 255, 0.85); font-size: 14px; }
footer a { color: rgba(255, 255, 255, 0.8); text-decoration: none; margin: 0 8px; font-size: 14px; transition: color 0.3s ease; }
footer a:hover { color: white; }


/* =====================================================
   8️⃣ COMPONENTES (MODALES, TOAST, BOTÓN ARRIBA)
===================================================== */
.modal {
    display: none;
    position: fixed;
    z-index: 2000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background: rgba(15, 23, 42, 0.55);
    backdrop-filter: blur(8px);
    animation: fadeBackground 0.3s ease;
}

.modal-content {
    background: rgba(255, 255, 255, 0.85);
    backdrop-filter: blur(15px);
    margin: 8% auto;
    padding: 45px;
    border-radius: 20px;
    width: 90%;
    max-width: 650px;
    box-shadow: 0 30px 60px rgba(0,0,0,0.25);
    position: relative;
    animation: scaleIn 0.35s ease;
}

.close {
    position: absolute;
    right: 20px;
    top: 15px;
    font-size: 26px;
    cursor: pointer;
}

#btnTop {
    position: fixed;
    bottom: 30px;
    right: 30px;
    background: white;
    color: #e07a5f;
    border: none;
    padding: 14px 18px;
    border-radius: 50%;
    font-size: 18px;
    cursor: pointer;
    box-shadow: 0 15px 30px rgba(0,0,0,0.2);
    display: none;
    transition: all 0.3s ease;
    z-index: 1500;
    border: 3px solid #e07a5f;
}

#btnTop:hover {
    background: #e07a5f;
    color: white;
    transform: translateY(-4px);
    border: 3px solid #e07a5f;
}

.toast {
    position: fixed;
    bottom: 90px;
    right: 30px;
    background: #1f2933;
    color: white;
    padding: 14px 20px;
    border-radius: 10px;
    box-shadow: 0 20px 40px rgba(0,0,0,0.2);
    opacity: 0;
    transform: translateY(20px);
    transition: all 0.3s ease;
    z-index: 1600;
}

.toast.show {
    opacity: 1;
    transform: translateY(0);
}

/* =====================================================
   9️⃣ ANIMACIONES GLOBALES
===================================================== */
.reveal {
    opacity: 0;
    transition: opacity 0.6s ease;
}

.reveal.active {
    opacity: 1;
}

@keyframes fadeBackground {
    from { background: rgba(15, 23, 42, 0); backdrop-filter: blur(0px); }
    to { background: rgba(15, 23, 42, 0.55); backdrop-filter: blur(8px); }
}

@keyframes scaleIn {
    from { transform: scale(0.95); opacity: 0; }
    to { transform: scale(1); opacity: 1; }
}