@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800&family=Zilla+Slab:wght@500;600;700&display=swap');

/* ==========================================================================
   Variables y Sistema de Diseño (InmoMach Premium)
   ========================================================================== */
:root {
    /* Paleta de Colores (Minimalist Light con acentos Rojos) */
    --bg-main: #ffffff;
    --bg-dark: #0a0a0a;
    --bg-alt: #faf9f6;             /* Beige pastel estilo Anthropic */
    --primary: #000000;            /* Negro minimalista para textos/botones */
    --primary-dark: #18181b;
    --primary-light: #f4f4f5;
    
    --accent: #dc2626;             /* Rojo corporativo de InmoMach */
    --accent-dark: #b91c1c;
    --accent-light: #fef2f2;

    --text-main: #27272a;          /* Gris oscuro para legibilidad */
    --text-dark: #09090b;
    --text-muted: #71717a;
    --border-color: #e4e4e7;
    
    /* Sombras */
    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
    --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
    
    /* Bordes y Anchos */
    --border-radius: 24px;
    --border-radius-sm: 12px;
    --max-width: 1200px;
    --header-height: 80px;
    --space-8: 2rem;
}

/* ==========================================================================
   Reseteo e Inicialización
   ========================================================================== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    scroll-padding-top: 100px; /* Margen superior al saltar a anclas para evitar que la cabecera fija tape el contenido */
}

/* Evitar conflicto de suavizado de scroll con la librería Lenis en páginas principales */
html:has(body script[src*="main.js"]) {
    scroll-behavior: auto !important;
}

body {
    font-family: 'Inter', system-ui, -apple-system, sans-serif;
    line-height: 1.6;
    color: var(--text-main);
    background-color: var(--bg-main);
    overflow-x: hidden;
    letter-spacing: -0.01em;
    opacity: 1; /* Visible por defecto para páginas sin animaciones */
}

/* Ocultar el body inicialmente para evitar parpadeos (FOUC) */
html.js-loading body {
    opacity: 0;
}

/* Tipografía */
h1, h2, h3, h4, h5, h6 {
    font-family: 'Zilla Slab', Georgia, serif;
    font-weight: 700;
    color: var(--text-dark);
    line-height: 1.2;
    letter-spacing: -0.02em;
}

p {
    font-family: 'Inter', sans-serif;
}

a {
    color: inherit;
    text-decoration: none;
    transition: color 0.2s ease, background 0.2s ease;
}

/* ==========================================================================
   Componentes Comunes
   ========================================================================== */
.container {
    width: 90%;
    max-width: var(--max-width);
    margin: 0 auto;
    position: relative;
}

/* Botones */
.btn, .btn-primary, .btn-secondary {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.8rem 1.8rem;
    font-family: 'Inter', sans-serif;
    font-weight: 600;
    border-radius: 99px;
    text-decoration: none !important;
    transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
    cursor: pointer;
    border: none;
    font-size: 0.95rem;
    gap: 8px;
}

.btn-primary {
    background-color: var(--primary) !important;
    color: #ffffff !important;
}

.btn-primary:hover {
    background-color: var(--primary-dark) !important;
    transform: translateY(-2px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
}

.btn-secondary {
    background-color: #ffffff !important;
    color: var(--primary) !important;
    border: 1px solid var(--border-color) !important;
}

.btn-secondary:hover {
    background-color: var(--primary-light) !important;
    transform: translateY(-2px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.05);
}

/* ==========================================================================
   Header & Navegación (Forzado a Light Mode con !important)
   ========================================================================== */
.site-header {
    position: fixed !important;
    top: 0 !important;
    width: 100% !important;
    z-index: 1000 !important;
    background: transparent !important;
    backdrop-filter: none !important;
    border-bottom: 1px solid transparent !important;
    padding: 1rem 0 !important;
    transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1) !important;
}

.site-header.scrolled {
    background: rgba(255, 255, 255, 0.95) !important;
    backdrop-filter: blur(10px) !important;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.03) !important;
    border-bottom: 1px solid rgba(0, 0, 0, 0.05) !important;
    padding: 0.75rem 0 !important;
}

/* Header CTA Button styling to match Index Page */
.site-header .header-cta a,
.site-header .header-cta .btn {
    background-color: #0a0a0a !important;
    color: #ffffff !important;
    border: none !important;
    font-weight: 600 !important;
    padding: 0.6rem 1.4rem !important;
    border-radius: 99px !important;
    text-decoration: none !important;
    font-size: 0.95rem !important;
    transition: opacity 0.2s, background-color 0.2s !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    box-shadow: none !important;
}

.site-header .header-cta a:hover,
.site-header .header-cta .btn:hover {
    opacity: 0.85 !important;
    background-color: #1a1a1a !important;
    color: #ffffff !important;
    transform: none !important;
}

.site-header .container {
    display: grid !important;
    grid-template-columns: 180px 1fr 180px !important;
    align-items: center !important;
}

.site-header .logo a {
    display: flex !important;
    align-items: center !important;
    gap: 10px !important;
    text-decoration: none !important;
    color: var(--primary) !important;
}

.site-header .logo img {
    height: 35px !important;
    display: block !important;
    content: url('../img/Logo web.png') !important;
}

footer .logo img,
.site-footer .logo img {
    content: url('../img/Nuevos/final negro ico.png') !important;
}

/* Fallback for older browsers */
@supports not (content: url('')) {
    .site-header .logo img[src$="Logo.png"] {
        filter: invert(1) !important;
    }
}

.site-header .logo span {
    font-family: 'Inter', sans-serif !important;
    font-size: 1.25rem !important;
    font-weight: 800 !important;
    letter-spacing: -0.02em !important;
    color: #0a0a0a !important;
}

.main-navigation {
    justify-self: center !important;
}

.main-navigation ul {
    display: flex !important;
    list-style: none !important;
    gap: 0.5rem !important; /* Gaps pequeños para layout redondeado */
    margin: 0 !important;
    padding: 0 !important;
    align-items: center !important;
}

.main-navigation a {
    text-decoration: none !important;
    color: #4b5563 !important; /* Gris elegante */
    font-weight: 600 !important;
    font-size: 0.95rem !important;
    padding: 0.6rem 1rem !important;
    border-radius: 99px !important;
    transition: all 0.2s ease !important;
}

.main-navigation a:hover,
.main-navigation li.active a {
    color: var(--primary) !important;
    background: var(--primary-light) !important;
}

/* Dropdown Menu */
.dropdown {
    position: relative !important;
}

.dropdown-chevron {
    width: 12px !important;
    height: 12px !important;
    margin-top: 1px !important;
    transition: transform 0.3s !important;
    stroke-width: 3 !important;
}

.dropdown:hover .dropdown-chevron {
    transform: rotate(180deg) !important;
}

.dropdown-menu {
    position: absolute !important;
    top: 100% !important;
    left: 0 !important;
    transform: translateY(10px) !important;
    background: rgba(255, 255, 255, 0.98) !important;
    backdrop-filter: blur(20px) !important;
    border: 1px solid rgba(0, 0, 0, 0.08) !important;
    border-radius: 16px !important;
    padding: 1.75rem 1rem !important;
    min-width: 180px !important;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.08) !important;
    opacity: 0 !important;
    visibility: hidden !important;
    transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1) !important;
    list-style: none !important;
    display: flex !important;
    flex-direction: column !important;
    gap: 0.25rem !important;
    z-index: 1010 !important;
}

.dropdown:hover .dropdown-menu {
    opacity: 1 !important;
    visibility: visible !important;
    transform: translateY(5px) !important;
}

.dropdown-menu a {
    color: #27272a !important;
    font-weight: 500 !important;
    font-size: 0.9rem !important;
    padding: 0.65rem 1.25rem !important;
    border-radius: 12px !important;
    display: flex !important;
    align-items: center !important;
    justify-content: space-between !important;
    gap: 6px !important;
    width: 100% !important;
    background: transparent !important;
    text-align: left !important;
    white-space: nowrap !important;
}

/* Chevron always at the end of dropdown items on desktop */
.dropdown-menu a svg {
    flex-shrink: 0 !important;
    order: 2 !important;
    opacity: 0.45 !important;
    transition: opacity 0.2s ease !important;
}

.dropdown-menu a:hover svg {
    opacity: 1 !important;
}

.dropdown-menu a:hover {
    background: var(--primary-light) !important;
    color: var(--accent) !important;
}

.main-navigation a.active,
.main-navigation li.active > a {
    color: var(--accent) !important;
    background: var(--primary-light) !important;
}

/* Hide mobile-specific elements on desktop */
.mobile-menu-cta {
    display: none !important;
}

.dropdown-menu a.active {
    color: var(--accent) !important;
    background: rgba(0, 0, 0, 0.04) !important;
    font-weight: 700 !important;
}

/* Hide mobile toggle icon on desktop */
.dropdown-toggle-icon {
    display: none;
}

/* ==========================================================================
   Menú Móvil Hamburguesa
   ========================================================================== */
.mobile-menu-btn {
    display: none;
    background: none;
    border: none;
    cursor: pointer;
    z-index: 1010;
    width: 30px;
    height: 24px;
    position: relative;
}

.mobile-menu-btn span {
    display: block;
    width: 100%;
    height: 2.5px;
    background-color: var(--primary);
    position: absolute;
    left: 0;
    transition: all 0.2s ease;
}

.mobile-menu-btn span:nth-child(1) { top: 0; }
.mobile-menu-btn span:nth-child(2) { top: 10px; }
.mobile-menu-btn span:nth-child(3) { top: 20px; }

@media (max-width: 1024px) {
    /* --- Header bar when menu is open --- */
    .site-header.menu-open {
        background: #ffffff !important;
        border-bottom: 1px solid #f4f4f5 !important;
    }

    /* --- Hamburger button: always right-aligned --- */
    .mobile-menu-btn {
        display: block !important;
        position: absolute !important;
        right: 1.5rem !important;
        top: 50% !important;
        transform: translateY(-50%) !important;
        z-index: 1010 !important;
    }

    .site-header.menu-open .mobile-menu-btn span:nth-child(1) {
        transform: translateY(10px) rotate(45deg) !important;
    }

    .site-header.menu-open .mobile-menu-btn span:nth-child(2) {
        opacity: 0 !important;
    }

    .site-header.menu-open .mobile-menu-btn span:nth-child(3) {
        transform: translateY(-10px) rotate(-45deg) !important;
    }
    
    /* --- Logo: always left-aligned --- */
    .site-header .logo {
        position: absolute !important;
        left: 1.5rem !important;
        transform: translateY(-50%) !important;
        top: 50% !important;
        z-index: 1010 !important;
    }
    
    /* --- Header container --- */
    .site-header .container {
        position: relative !important;
        min-height: 60px !important;
        display: flex !important;
        align-items: center !important;
    }
    
    /* --- Navigation: full-screen overlay from top --- */
    .main-navigation {
        position: fixed !important;
        top: 0 !important;
        left: 0 !important;
        width: 100% !important;
        height: 100vh !important;
        height: 100dvh !important;
        max-height: none !important;
        overflow-y: auto !important;
        background: #ffffff !important;
        z-index: 1005 !important;
        padding: 5.5rem 1.5rem 2rem !important;
        display: flex !important;
        flex-direction: column !important;
        box-sizing: border-box !important;
        
        /* Curtain descending animation */
        opacity: 1 !important;
        transform: translateY(-100%) !important;
        visibility: hidden !important;
        transition: transform 0.45s cubic-bezier(0.85, 0, 0.15, 1),
                    visibility 0.45s !important;
    }
    
    /* --- Navigation: visible state --- */
    .site-header.menu-open .main-navigation {
        opacity: 1 !important;
        transform: translateY(0) !important;
        pointer-events: auto !important;
        visibility: visible !important;
    }
    
    /* --- Staggered entry for menu items --- */
    .main-navigation > ul,
    .mobile-menu-cta {
        opacity: 0 !important;
        transform: translateY(20px) !important;
        transition: opacity 0.25s ease, transform 0.25s ease !important;
    }
    
    .site-header.menu-open .main-navigation > ul {
        opacity: 1 !important;
        transform: translateY(0) !important;
        transition: opacity 0.4s ease 0.35s, transform 0.4s cubic-bezier(0.16, 1, 0.3, 1) 0.35s !important;
    }
    
    .site-header.menu-open .mobile-menu-cta {
        opacity: 1 !important;
        transform: translateY(0) !important;
        transition: opacity 0.4s ease 0.45s, transform 0.4s cubic-bezier(0.16, 1, 0.3, 1) 0.45s !important;
    }
    
    /* --- Menu list layout --- */
    .main-navigation ul {
        flex-direction: column !important;
        align-items: stretch !important;
        gap: 0 !important;
    }
    
    /* --- Menu links: full-width with dividers --- */
    .main-navigation a {
        font-size: 1.15rem !important;
        font-weight: 500 !important;
        color: #0a0a0a !important;
        padding: 1.1rem 0 !important;
        border-bottom: 1px solid #f4f4f5 !important;
        border-radius: 0 !important;
        width: 100% !important;
        display: flex !important;
        align-items: center !important;
        justify-content: space-between !important;
        text-decoration: none !important;
    }
    
    .main-navigation > ul > li:last-child > a {
        border-bottom: none !important;
    }
    
    .main-navigation a:hover {
        background: transparent !important;
        color: #0a0a0a !important;
    }

    .main-navigation a.active,
    .main-navigation li.active > a {
        background: transparent !important;
        border-radius: 0 !important;
    }

    /* Active dropdown sub-item: only color, no box */
    .dropdown-menu a.active {
        background: transparent !important;
        border-radius: 0 !important;
        color: var(--accent) !important;
    }

    /* Hide chevrons on mobile */
    .main-navigation > ul > li.dropdown > a svg,
    .main-navigation > ul > li.dropdown > a .dropdown-chevron {
        display: none !important;
    }

    /* Custom plus/minus toggle icon for mobile */
    .dropdown-toggle-icon {
        position: relative;
        width: 16px;
        height: 16px;
        display: block !important;
        flex-shrink: 0;
    }

    .dropdown-toggle-icon::before,
    .dropdown-toggle-icon::after {
        content: '';
        position: absolute;
        background-color: #71717a;
        transition: transform 0.25s ease, background-color 0.25s ease;
    }

    /* Horizontal bar */
    .dropdown-toggle-icon::before {
        top: 7px;
        left: 0;
        width: 16px;
        height: 1.5px;
    }

    /* Vertical bar */
    .dropdown-toggle-icon::after {
        top: 0;
        left: 7px;
        width: 1.5px;
        height: 16px;
    }

    /* Turn plus into minus by rotating/scaling the vertical bar */
    .dropdown.expanded .dropdown-toggle-icon::after {
        transform: rotate(90deg) scaleY(0);
    }
    
    .dropdown.expanded > a {
        font-weight: 600 !important;
    }

    .dropdown.expanded .dropdown-toggle-icon::before {
        background-color: #0a0a0a;
    }
    
    /* --- Dropdown submenus inline accordion style --- */
    .dropdown-menu {
        position: static !important;
        transform: none !important;
        box-shadow: none !important;
        border: none !important;
        border-radius: 0 !important;
        backdrop-filter: none !important;
        -webkit-backdrop-filter: none !important;
        padding-left: 1rem !important;
        background: transparent !important;
        display: flex !important;
        flex-direction: column !important;
        
        /* Collapsed state */
        max-height: 0 !important;
        overflow: hidden !important;
        opacity: 0 !important;
        padding-top: 0 !important;
        padding-bottom: 0 !important;
        margin: 0 !important;
        visibility: hidden !important;
        transition: max-height 0.35s cubic-bezier(0.85, 0, 0.15, 1),
                    opacity 0.25s ease,
                    padding 0.35s ease !important;
    }

    .dropdown.expanded .dropdown-menu {
        max-height: 500px !important;
        opacity: 1 !important;
        padding-top: 0.5rem !important;
        padding-bottom: 0.5rem !important;
        visibility: visible !important;
    }

    .dropdown-menu a {
        padding: 0.75rem 0 !important;
        font-size: 1.05rem !important;
        border-bottom: none !important;
        flex-direction: row-reverse !important;
        justify-content: flex-end !important;
        gap: 10px !important;
        color: #374151 !important;
        border-radius: 0 !important;
    }
    
    /* --- CTA buttons at bottom of mobile menu --- */
    .mobile-menu-cta {
        display: flex !important;
        gap: 0.75rem !important;
        margin-top: auto !important;
        padding-top: 1.5rem !important;
        border-top: 1px solid #f4f4f5 !important;
        background: none !important;
    }

    .mobile-menu-cta a {
        flex: 1 !important;
        display: inline-flex !important;
        align-items: center !important;
        justify-content: center !important;
        padding: 0.75rem 1.2rem !important;
        font-size: 0.95rem !important;
        font-weight: 700 !important;
        border-radius: 99px !important;
        text-decoration: none !important;
        transition: all 0.2s ease !important;
        border-bottom: none !important;
        height: 48px !important;
        box-sizing: border-box !important;
    }

    .mobile-menu-cta .mobile-cta-outline {
        background-color: transparent !important;
        color: #0a0a0a !important;
        border: 1.5px solid #0a0a0a !important;
    }

    .mobile-menu-cta .mobile-cta-outline:hover {
        background-color: rgba(0, 0, 0, 0.05) !important;
        opacity: 0.95 !important;
    }

    .mobile-menu-cta .mobile-cta-filled {
        background-color: #dc2626 !important;
        color: #ffffff !important;
        border: none !important;
    }

    .mobile-menu-cta .mobile-cta-filled:hover {
        background-color: #b91c1c !important;
        opacity: 0.95 !important;
    }

    /* --- Hide the desktop header CTA on mobile --- */
    .header-cta {
        display: none !important;
    }
}

/* ==========================================================================
   Hero Section
   ========================================================================== */
.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    padding: 120px 0 80px;
    background: radial-gradient(circle at top right, #fff5f5 0%, var(--bg-main) 60%);
    position: relative;
    overflow: hidden;
}

.hero h1 {
    font-size: clamp(3rem, 6vw, 4.8rem);
    line-height: 1.1;
    margin-bottom: 2rem;
}

.hero p {
    font-size: clamp(1.1rem, 2vw, 1.35rem);
    color: var(--text-muted);
    margin-bottom: 3rem;
    max-width: 650px;
}

.btn-group {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
}

/* ==========================================================================
   Typewriter Animation
   ========================================================================== */
#typewriter {
    color: inherit;
    display: inline;
}

#typewriter::after {
    content: '|';
    display: inline-block;
    color: var(--accent);
    margin-left: 4px;
    animation: blink 0.9s infinite;
}

@keyframes blink {
    0%, 100% { opacity: 1; }
    50% { opacity: 0; }
}

@keyframes fadeInChar {
    from { opacity: 0; }
    to { opacity: 1; }
}

/* ==========================================================================
   Bento Grid & Cards
   ========================================================================== */
.bento-card {
    position: relative;
    border-radius: 24px;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.bento-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.08);
}

/* ==========================================================================
   How It Works / Steps
   ========================================================================== */
.step-card {
    transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.step-card:hover {
    transform: translateY(-5px);
}

/* ==========================================================================
   Asesoría / Secciones Alternas
   ========================================================================== */
.animate-on-scroll {
    transition: opacity 0.8s ease, transform 0.8s ease;
}

/* ==========================================================================
   App Download Section
   ========================================================================== */
.floating-phone-img {
    animation: floatPhone 6s ease-in-out infinite;
}

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

/* ==========================================================================
   Pricing Section (Anthropic Style)
   ========================================================================== */
.pricing-card {
    background: #f1ede7; /* Pastel Beige */
    border-radius: 24px;
    padding: var(--space-8);
    display: flex;
    flex-direction: column;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    border: 1px solid #e2ded5;
}

.pricing-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.05);
}

.pricing-badge {
    align-self: flex-start;
    background: #000000;
    color: #ffffff;
    font-size: 0.75rem;
    font-weight: 700;
    padding: 0.35rem 0.75rem;
    border-radius: 99px;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 1rem;
}

/* ==========================================================================
   FAQ Section
   ========================================================================== */
.faq-item {
    border-bottom: 1px solid var(--border-color);
    padding: 1.5rem 0;
    cursor: pointer;
}

.faq-icon {
    transition: transform 0.3s ease;
}

.faq-item.active .faq-icon {
    transform: rotate(180deg);
}

.faq-answer {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease-out;
}

.faq-item.active .faq-answer {
    max-height: 200px;
    margin-top: 1rem;
}

/* ==========================================================================
   Subpages Cards & Articles (Inquilinos, Trabajo, etc.)
   ========================================================================== */
.subcategory-card {
    background: #f1ede7;
    border: 1px solid rgba(0, 0, 0, 0.03);
    border-radius: 24px;
    padding: 2.5rem;
    box-shadow: 0 10px 30px rgba(0,0,0,0.02);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.subcategory-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 35px rgba(0,0,0,0.05);
}

.question-list {
    list-style: none;
    padding: 0;
    margin: 1.5rem 0 0;
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.question-item a {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1rem 1.25rem;
    background: #ffffff;
    border: 1.5px solid transparent;
    border-radius: 12px;
    text-decoration: none;
    color: #1a1a1a;
    font-weight: 500;
    font-size: 0.95rem;
    transition: all 0.2s ease;
    text-align: left;
}

.question-item a:hover {
    border-color: var(--accent);
    background: #fff8f8;
    color: var(--accent);
    transform: translateX(4px);
}

.question-item svg {
    flex-shrink: 0;
    transition: transform 0.2s ease;
}

.question-item a:hover svg {
    transform: translateX(3px);
}

.article-card {
    background: #faf8f5;
    border-radius: 20px;
    overflow: hidden;
    border: 1px solid #e2e8f0;
    display: flex;
    flex-direction: column;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.article-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.03);
}

.article-content {
    padding: 2rem;
    display: flex;
    flex-direction: column;
    flex-grow: 1;
}

.article-tag {
    color: var(--accent);
    font-size: 0.85rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 0.5rem;
}

.article-title {
    font-size: 1.35rem;
    color: var(--text-dark);
    margin-bottom: 1rem;
    line-height: 1.3;
}

.article-desc {
    color: var(--text-muted);
    font-size: 0.95rem;
    line-height: 1.6;
    margin-bottom: 1.5rem;
}

.article-link {
    margin-top: auto;
    text-decoration: none;
    color: var(--text-dark);
    font-weight: 700;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    transition: color 0.2s;
}

.article-link:hover {
    color: var(--accent);
}

/* ==========================================================================
   Single Article Layout & Typography
   ========================================================================== */
.support-article-title {
    font-family: 'Zilla Slab', Georgia, serif !important;
    font-size: clamp(2.4rem, 4.5vw, 3.4rem) !important;
    color: var(--text-dark) !important;
    line-height: 1.15 !important;
    margin-bottom: 1.5rem !important;
    font-weight: 700 !important;
    letter-spacing: -0.02em !important;
}

.support-article-meta {
    font-family: 'Inter', sans-serif !important;
    font-size: 0.95rem !important;
    color: var(--text-muted) !important;
    margin-bottom: 2rem !important;
}

.support-content {
    font-family: 'Inter', sans-serif !important;
}

.support-content h2 {
    font-family: 'Zilla Slab', Georgia, serif !important;
    font-size: clamp(1.6rem, 2.8vw, 2.1rem) !important;
    color: var(--text-dark) !important;
    font-weight: 700 !important;
    margin-top: 3.2rem !important;
    margin-bottom: 1.4rem !important;
    line-height: 1.3 !important;
    letter-spacing: -0.01em !important;
}

.support-content h3 {
    font-family: 'Zilla Slab', Georgia, serif !important;
    font-size: clamp(1.3rem, 2.2vw, 1.6rem) !important;
    color: var(--text-dark) !important;
    font-weight: 700 !important;
    margin-top: 2.6rem !important;
    margin-bottom: 1.1rem !important;
    line-height: 1.3 !important;
}

.support-content p {
    font-family: 'Inter', sans-serif !important;
    font-size: 1.15rem !important;
    line-height: 1.85 !important;
    color: #3f3f46 !important;
    margin-bottom: 2.2rem !important;
}

.support-content ol,
.support-content ul {
    margin-bottom: 1.8rem !important;
    padding-left: 1.75rem !important;
}

.support-content li {
    font-family: 'Inter', sans-serif !important;
    font-size: 1.05rem !important;
    line-height: 1.75 !important;
    color: #3f3f46 !important;
    margin-bottom: 0.8rem !important;
}

.support-content strong,
.support-content b {
    color: #0f0f10 !important;
    font-weight: 700 !important;
}


/* ==========================================================================
   Table of Contents (TOC) para artículos de Soporte
   ========================================================================== */
.toc-box {
    background: #faf9f6;
    border: 1px solid #e6e5df;
    border-radius: 16px;
    padding: 1.5rem;
    margin-bottom: 2rem;
}

.toc-box h3 {
    font-size: 1.1rem;
    margin-bottom: 1rem;
    color: var(--text-dark);
}

.toc-box ul {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.toc-box ul li a {
    color: var(--text-muted);
    font-size: 0.95rem;
    transition: color 0.2s;
    text-decoration: none;
}

.toc-box ul li a:hover {
    color: var(--accent) !important;
}

/* ==========================================================================
   Footer (Forzado a Light Mode con !important)
   ========================================================================== */
footer,
.site-footer {
    background: #faf9f6 !important;
    color: #52525b !important;
    border-top: 1px solid #e5e5e5 !important;
    padding: 4rem 0 2rem !important;
}

footer h4,
.site-footer h4,
footer .logo a,
.site-footer .logo a,
footer .logo a span,
.site-footer .logo a span,
footer a img + span,
.site-footer a img + span {
    color: #0a0a0a !important;
}

footer .logo img[src*="Logo.png"],
.site-footer .logo img[src*="Logo.png"],
footer a img[src*="Logo.png"],
.site-footer a img[src*="Logo.png"],
footer h3 img[src*="Logo.png"],
.site-footer h3 img[src*="Logo.png"] {
    filter: none !important; /* Evitar que el logo del footer se invierta */
}

footer a,
.site-footer a {
    color: #71717a !important;
    text-decoration: none !important;
}

footer a:hover,
.site-footer a:hover {
    color: #dc2626 !important; /* Rojo al pasar el cursor */
}

.footer-link,
footer ul li a,
footer div[style*="justify-content: flex-end"] a,
footer div[style*="justify-content:flex-end"] a {
    color: inherit !important;
    transition: color 0.2s ease, transform 0.2s ease;
}

.footer-link:hover,
footer ul li a:hover,
footer div[style*="justify-content: flex-end"] a:hover {
    color: var(--accent) !important;
}

.social-icon-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: #f4f4f5;
    color: #52525b !important;
    transition: all 0.2s ease;
}

.social-icon-link:hover {
    background: #000000;
    color: #ffffff !important;
    transform: translateY(-2px);
}

footer div[style*="border-top"],
.site-footer div[style*="border-top"] {
    border-top-color: #e5e5e5 !important;
}

/* === MOBILE FOOTER OPTIMIZATION === */
@media (max-width: 768px) {
    footer > .container:first-of-type,
    .site-footer > .container:first-of-type {
        grid-template-columns: 1fr !important;
        gap: 2rem !important;
    }
    
    footer .container:last-of-type,
    .site-footer .container:last-of-type {
        flex-direction: column !important;
        text-align: center;
        gap: 1.5rem !important;
    }
    
    footer .container:last-of-type div,
    .site-footer .container:last-of-type div {
        justify-content: center !important;
    }
}

/* ==========================================================================
   Scroll To Top Button
   ========================================================================== */
.scroll-to-top-btn {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: #000000;
    color: #ffffff;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    cursor: pointer;
    z-index: 999;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.scroll-to-top-btn.visible {
    opacity: 1;
    visibility: visible;
}

.scroll-to-top-btn:hover {
    transform: translateY(-3px);
    background: #1a1a1a;
}

/* Force dropdown padding unconditionally */
@media (min-width: 1025px) {
    body header .main-navigation ul li.dropdown ul.dropdown-menu {
        padding: 1.2rem 1rem !important;
    }

    body header .main-navigation ul li.dropdown ul.dropdown-menu a {
        padding: 0.6rem 1.25rem !important;
    }
}

/* ==========================================================================
   Article Related Links (Bottom of single articles)
   ========================================================================== */
.support-related {
    margin-top: 4rem;
    padding-top: 2rem;
    border-top: 1px solid #e6e5df;
}

.support-related .related-title {
    font-family: 'Zilla Slab', serif;
    font-size: 1.5rem;
    color: #0a0a0a;
    margin-bottom: 1.5rem;
}

.support-related .related-list {
    list-style: none !important;
    padding: 0 !important;
    margin: 0 !important;
    display: flex !important;
    flex-direction: column !important;
    gap: 1rem !important;
}

.support-related .related-list li a {
    display: flex !important;
    align-items: center !important;
    justify-content: space-between !important;
    padding: 1.25rem 1.5rem !important;
    background: #fafafa !important;
    border: 1px solid #e2e8f0 !important;
    border-radius: 12px !important;
    text-decoration: none !important;
    color: #1a1a1a !important;
    font-weight: 500 !important;
    font-size: 1rem !important;
    transition: all 0.2s ease !important;
}

.support-related .related-list li a:hover {
    border-color: #dc2626 !important;
    background: #fff8f8 !important;
    color: #dc2626 !important;
    transform: translateX(4px) !important;
}

.support-related .related-list li a .arrow-icon {
    font-size: 1.5rem !important;
    color: #a1a1aa !important;
    line-height: 1 !important;
    transition: transform 0.2s ease, color 0.2s ease !important;
}

.support-related .related-list li a:hover .arrow-icon {
    color: #dc2626 !important;
    transform: translateX(3px) !important;
}
