/**
 * Oran Hoy - Minimal CSS
 * Solo estilos que NO se pueden hacer con Tailwind
 * Todo lo demÃ¡s usa clases de Tailwind en el HTML
 */

/* ================================
   1. CSS VARIABLES (Design Tokens)
   Usados por algunos componentes custom
   ================================ */
:root {
    /* Transitions */
    --transition-fast: 150ms ease;
    --transition: 200ms ease;
    --transition-slow: 300ms ease;

    /* Z-index scale */
    --z-dropdown: 100;
    --z-sticky: 200;
    --z-fixed: 300;
    --z-modal-backdrop: 400;
    --z-modal: 500;

    /* Border Radius */
    --radius-lg: 0.75rem;
    --radius-full: 9999px;
}

/* ================================
   2. BASE RESETS
   Complementa Tailwind Preflight
   ================================ */
html {
    scroll-behavior: smooth;
    -webkit-tap-highlight-color: transparent;
}

body {
    font-family: 'Inter', system-ui, -apple-system, sans-serif;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* ================================
   3. NAV ACTIVE & SCROLL EFFECTS
   ================================ */
/* Nav link activo */
.active-nav-link {
    background-color: #eff6ff;
    color: #2563eb !important;
    position: relative;
}

.active-nav-link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 60%;
    height: 2px;
    background: linear-gradient(90deg, #3b82f6, #60a5fa);
    border-radius: 2px;
}

/* Header scrolled - mÃ¡s compacto */
.header-scrolled #header-inner {
    height: 3rem !important;
}

.header-scrolled {
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
}

/* ================================
   5. PREMIUM BUSINESS CARDS
   Tarjetas destacadas con borde gradiente
   ================================ */

/* Tarjeta destacada - borde gradiente animado */
.card-destacada {
    position: relative;
    background: linear-gradient(135deg, #0ea5e9, #38bdf8, #0ea5e9);
    padding: 3px;
    border-radius: 1rem;
    box-shadow: 0 8px 30px rgba(14, 165, 233, 0.3), 0 4px 15px rgba(56, 189, 248, 0.25);
}

.card-destacada::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, #06b6d4, #3b82f6, #8b5cf6, #06b6d4);
    background-size: 300% 300%;
    border-radius: 1rem;
    animation: gradientShift 4s ease infinite;
    z-index: -1;
}

.card-destacada .card-inner {
    background: white;
    border-radius: 0.875rem;
    overflow: hidden;
    height: 100%;
}

@keyframes gradientShift {
    0%, 100% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
}

/* Badge Destacado Premium */
.badge-destacado {
    background: linear-gradient(135deg, #06b6d4, #3b82f6);
    box-shadow: 0 4px 15px rgba(6, 182, 212, 0.4);
}

/* BotÃ³n Ver MinipÃ¡gina */
.btn-minipagina {
    background: linear-gradient(135deg, #0ea5e9, #38bdf8);
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(14, 165, 233, 0.3);
}

.btn-minipagina:hover {
    background: linear-gradient(135deg, #0284c7, #0ea5e9);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(14, 165, 233, 0.4);
}

/* BotÃ³n WhatsApp mejorado */
.btn-whatsapp {
    background: linear-gradient(135deg, #25D366, #128C7E);
    box-shadow: 0 4px 15px rgba(37, 211, 102, 0.3);
    transition: all 0.3s ease;
}

.btn-whatsapp:hover {
    background: linear-gradient(135deg, #20bd5a, #0d7362);
    transform: translateY(-1px);
    box-shadow: 0 6px 20px rgba(37, 211, 102, 0.4);
}

/* BotÃ³n Ver Info mejorado */
.btn-ver-info {
    border: 2px solid #e2e8f0;
    transition: all 0.3s ease;
}

.btn-ver-info:hover {
    border-color: #3b82f6;
    color: #3b82f6;
    background: #eff6ff;
}

/* ================================
   6. MOBILE MENU OVERLAY
   AnimaciÃ³n slide-in que no es posible con Tailwind solo
   ================================ */
.mobile-menu-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.5);
    z-index: var(--z-modal-backdrop);
    opacity: 0;
    visibility: hidden;
    transition: all var(--transition);
}

.mobile-menu-overlay.active {
    opacity: 1;
    visibility: visible;
}

.mobile-menu {
    position: fixed;
    top: 0;
    right: 0;
    bottom: 0;
    width: 100%;
    max-width: 320px;
    background: white;
    z-index: var(--z-modal);
    transform: translateX(100%);
    transition: transform var(--transition-slow);
    overflow-y: auto;
}

.mobile-menu-overlay.active .mobile-menu {
    transform: translateX(0);
}

/* Mobile Menu Internal Styles */
.mobile-menu-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1rem;
    border-bottom: 1px solid #e5e7eb;
}

.mobile-menu-header .logo {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    text-decoration: none;
    font-weight: 700;
    font-size: 1.25rem;
    color: #2563eb;
}

.mobile-menu-header .logo-icon {
    width: 1.5rem;
    height: 1.5rem;
    stroke: #3b82f6;
    stroke-width: 2;
}

.mobile-menu-header .logo-hoy {
    color: #3b82f6;
}

.mobile-menu-close {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 2.5rem;
    height: 2.5rem;
    background: #f1f5f9;
    border: none;
    border-radius: 9999px;
    cursor: pointer;
    color: #475569;
}

.mobile-menu-nav {
    padding: 1rem;
}

.mobile-menu-link {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.875rem 1rem;
    text-decoration: none;
    font-size: 1rem;
    font-weight: 500;
    color: #475569;
    border-radius: 0.75rem;
    transition: all 150ms ease;
}

.mobile-menu-link:hover {
    background: #f1f5f9;
    color: #2563eb;
}

.mobile-menu-link.active {
    background: #eff6ff;
    color: #2563eb;
}

.mobile-menu-icon {
    width: 1.25rem;
    height: 1.25rem;
    flex-shrink: 0;
}

.mobile-menu-divider {
    height: 1px;
    background: #e5e7eb;
    margin: 0.75rem 0;
}

.mobile-menu-label {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.75rem 1rem;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: #64748b;
}

.mobile-menu-cta {
    background: linear-gradient(135deg, #eff6ff, #fef3c7);
    color: #1d4ed8 !important;
    font-weight: 600;
}

/* Badges for mobile menu */
.badge-soon {
    display: inline-flex;
    padding: 0.125rem 0.5rem;
    font-size: 0.625rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: #f59e0b;
    background: #fef3c7;
    border-radius: 9999px;
    margin-left: auto;
}

.badge-free {
    display: inline-flex;
    padding: 0.125rem 0.5rem;
    font-size: 0.625rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: #10b981;
    background: #d1fae5;
    border-radius: 9999px;
    margin-left: auto;
}

/* ================================
   4. HERO FULLSCREEN
   Background image con overlay - no posible solo con Tailwind
   ================================ */
.hero-fullscreen {
    position: relative;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    background: url('../imgs/inicio.webp') center/cover no-repeat;
    /* Fallback color if image missing */
    background-color: #1a2e1a;
    color: white;
    text-align: center;
    padding: 2rem 0;
    overflow: hidden;
}




/* Mobile: altura reducida para que quepa entre header y nav */
@media (max-width: 767px) {
    .hero-fullscreen {
        min-height: 70vh;
        padding: 1rem 0;
    }
}

.hero-bg-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg,
            rgba(0, 0, 0, 0.55) 0%,
            rgba(0, 0, 0, 0.5) 70%,
            rgba(0, 0, 0, 0.75) 100%);
    z-index: 1;
}

.hero-fullscreen .container {
    position: relative;
    z-index: 2;
}

/* ================================
   5. INFINITE SCROLL ANIMATION
   AnimaciÃ³n de scroll infinito para servicios
   ================================ */
.services-scroll-wrapper {
    position: relative;
    overflow: hidden;
    padding: 1rem 0;
}

/* Fade gradients en los bordes */
.services-scroll-wrapper::before,
.services-scroll-wrapper::after {
    content: '';
    position: absolute;
    top: 0;
    bottom: 0;
    width: 60px;
    z-index: 10;
    pointer-events: none;
}

.services-scroll-wrapper::before {
    left: 0;
    background: linear-gradient(to right, white 0%, transparent 100%);
}

.services-scroll-wrapper::after {
    right: 0;
    background: linear-gradient(to left, white 0%, transparent 100%);
}

.services-scroll-track {
    display: flex;
    gap: 0.75rem;
    animation: scroll-infinite 25s linear infinite;
    width: max-content;
}

.services-scroll-track:hover {
    animation-play-state: paused;
}

@keyframes scroll-infinite {
    0% {
        transform: translateX(0);
    }

    100% {
        transform: translateX(-50%);
    }
}

/* ================================
   6. DROPDOWN HOVER
   Comportamiento hover para dropdown del nav
   ================================ */
.nav-dropdown {
    position: relative;
}

.nav-dropdown-menu {
    position: absolute;
    top: 100%;
    left: 0;
    min-width: 200px;
    background: white;
    border: 1px solid #e2e8f0;
    border-radius: var(--radius-lg);
    box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.1);
    padding: 0.5rem;
    opacity: 0;
    visibility: hidden;
    transform: translateY(8px);
    transition: all var(--transition);
    z-index: var(--z-dropdown);
}

.nav-dropdown:hover .nav-dropdown-menu {
    opacity: 1;
    visibility: visible;
    transform: translateY(4px);
}

/* ================================
   7. SCROLL INDICATOR ANIMATION
   ================================ */
@keyframes bounce {

    0%,
    20%,
    50%,
    80%,
    100% {
        transform: translateX(-50%) translateY(0);
    }

    40% {
        transform: translateX(-50%) translateY(-8px);
    }

    60% {
        transform: translateX(-50%) translateY(-4px);
    }
}

.hero-scroll-indicator {
    position: absolute;
    bottom: 2rem;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
    color: rgba(255, 255, 255, 0.7);
    font-size: 0.8125rem;
    animation: bounce 2s infinite;
}

/* Mobile: ajustar posiciÃ³n */
@media (max-width: 767px) {
    .hero-scroll-indicator {
        bottom: 6rem;
        /* Above mobile nav */
    }

    .hero-scroll-indicator span {
        display: none;
    }
}

/* ================================
   8. PAGE WRAPPER
   Estructura base de pÃ¡gina
   ================================ */
.page-wrapper {
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

/* Padding bottom para mobile nav */
@media (max-width: 767px) {
    .page-wrapper {
        padding-bottom: 4.5rem;
    }
}

/* ================================
   9. CONTAINER (Boxed Layout)
   Ancho restringido para mÃ¡rgenes laterales estilo App
   ================================ */
.container {
    width: 100%;
    margin-left: auto;
    margin-right: auto;
    padding-left: 1.25rem;
    padding-right: 1.25rem;

    /* Forzamos el ancho mÃ¡ximo para el efecto "Boxed" */
    max-width: 1280px !important;
}

@media (min-width: 640px) {
    .container {
        padding-left: 2rem;
        padding-right: 2rem;
    }
}

@media (min-width: 1024px) {
    .container {
        padding-left: 3rem;
        padding-right: 3rem;
    }
}

@media (min-width: 1280px) {
    .container {
        padding-left: 4rem;
        padding-right: 4rem;
    }
}
/* ================================
   10. SKELETON LOADING
   Efecto de carga (esqueleto)
   ================================ */
.skeleton {
    background: #f1f5f9;
    background: linear-gradient(90deg, #f1f5f9 25%, #e2e8f0 50%, #f1f5f9 75%);
    background-size: 200% 100%;
    animation: shimmer 1.5s infinite;
    border-radius: 0.5rem;
}

@keyframes shimmer {
    0% { background-position: 200% 0; }
    100% { background-position: -200% 0; }
}

/* ================================
   11. SCROLL REVEAL ANIMATION
   Animación de entrada suave
   ================================ */
.card-animate {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.6s ease-out, transform 0.6s ease-out;
    will-change: opacity, transform;
}

.card-animate.visible {
    opacity: 1;
    transform: translateY(0);
}

/* Stagger delay para hijos si es necesario */
.card-animate:nth-child(1) { transition-delay: 0ms; }
.card-animate:nth-child(2) { transition-delay: 50ms; }
.card-animate:nth-child(3) { transition-delay: 100ms; }
.card-animate:nth-child(4) { transition-delay: 150ms; }
