/* ============================================
   GTCargas Landing Page - Custom Styles
   ============================================ */

/* Variables CSS personalizadas - Colores corporativos GTCargas */
:root {
    --primary-green: #3ba848;
    --primary-green-dark: #2d8a38;
    --primary-green-light: #4AC959;
    --gt-green: #25D366;
    --gt-gray: #898A8B;
    --gray-900: #111827;
    --gray-800: #1f2937;
    --gray-700: #374151;
    --gray-600: #4b5563;
    --gray-500: #6b7280;
    --gray-400: #9ca3af;
    --gray-300: #d1d5db;
    --gray-200: #e5e7eb;
    --gray-100: #f3f4f6;
    --gray-50: #f9fafb;
}

/* Fuente Inter aplicada globalmente */
body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    scroll-behavior: smooth;
}

/* Navbar sticky con efecto de scroll */
#navbar {
    transition: all 0.3s ease;
}

#navbar.scrolled {
    background-color: rgba(255, 255, 255, 0.98);
    backdrop-filter: blur(10px);
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
}

/* Smooth scroll para navegación */
html {
    scroll-behavior: smooth;
}

/* Estilos para enlaces de navegación */
.nav-link {
    position: relative;
    transition: color 0.3s ease;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 0;
    height: 2px;
    background-color: var(--primary-green);
    transition: width 0.3s ease;
}

.nav-link:hover::after {
    width: 100%;
}

/* Animaciones personalizadas */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeInDown {
    from {
        opacity: 0;
        transform: translateY(-30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes pulse {
    0%, 100% {
        opacity: 1;
    }
    50% {
        opacity: 0.5;
    }
}

/* Efectos hover mejorados para cards */
.card-hover {
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.card-hover:hover {
    transform: translateY(-8px);
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
}

/* Botones con efecto de elevación */
.btn-elevate {
    transition: all 0.3s ease;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
}

.btn-elevate:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
}

.btn-elevate:active {
    transform: translateY(0);
}

/* Estilos para el formulario de contacto */
#contact-form input:focus,
#contact-form textarea:focus {
    outline: none;
    border-color: var(--primary-green);
    box-shadow: 0 0 0 3px rgba(74, 201, 89, 0.1);
}

/* Loading state para el formulario */
.form-loading {
    opacity: 0.6;
    pointer-events: none;
}

/* Estilos para secciones con fondo alternado */
section:nth-child(even) {
    background-color: var(--gray-50);
}

/* Mejoras de accesibilidad */
*:focus {
    outline: 2px solid var(--primary-green);
    outline-offset: 2px;
}

button:focus,
a:focus {
    outline: 2px solid var(--primary-green);
    outline-offset: 2px;
}

/* Animación para el menú móvil */
#mobile-menu {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease-out;
}

#mobile-menu.active {
    max-height: 500px;
    transition: max-height 0.3s ease-in;
}

/* Estilos para placeholders de logos de clientes */
.client-logo {
    filter: grayscale(100%);
    opacity: 0.6;
    transition: all 0.3s ease;
}

.client-logo:hover {
    filter: grayscale(0%);
    opacity: 1;
    transform: scale(1.05);
}

/* Mejoras responsive */
@media (max-width: 768px) {
    .container {
        padding-left: 1rem;
        padding-right: 1rem;
    }
    
    h1 {
        font-size: 2rem;
    }
    
    h2 {
        font-size: 1.75rem;
    }
}

/* Optimización de imágenes lazy loading */
img[loading="lazy"] {
    opacity: 0;
    transition: opacity 0.3s;
}

img[loading="lazy"].loaded {
    opacity: 1;
}

/* Estilos para el hero section */
#hero {
    background: linear-gradient(135deg, #f0fdf4 0%, #ffffff 50%, #f9fafb 100%);
    min-height: 90vh;
    display: flex;
    align-items: center;
}

/* Efecto de gradiente en CTA */
#cta {
    position: relative;
    overflow: hidden;
}

#cta::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, rgba(59, 168, 72, 0.95) 0%, rgba(74, 201, 89, 0.95) 100%);
    z-index: -1;
}

/* Mejoras de contraste para accesibilidad */
.text-gray-600 {
    color: #4b5563;
}

.text-gray-700 {
    color: #374151;
}

/* Animación suave para stats */
.stat-number {
    transition: transform 0.3s ease;
}

.stat-number:hover {
    transform: scale(1.1);
}

/* Estilos para el dashboard mockup */
.dashboard-card {
    background: linear-gradient(135deg, #ffffff 0%, #f8fafc 100%);
    border: 1px solid #e2e8f0;
}

/* Scrollbar personalizado (opcional, solo para webkit) */
::-webkit-scrollbar {
    width: 10px;
}

::-webkit-scrollbar-track {
    background: #f1f1f1;
}

::-webkit-scrollbar-thumb {
    background: var(--primary-green);
    border-radius: 5px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--primary-green-dark);
}

/* Prevención de layout shift */
img, video {
    max-width: 100%;
    height: auto;
}

/* Mejoras de performance */
* {
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* Transiciones suaves globales */
a, button {
    transition: all 0.3s ease;
}

/* Estilos para mensajes de éxito/error del formulario */
.form-message {
    padding: 1rem;
    border-radius: 0.5rem;
    margin-top: 1rem;
    display: none;
}

.form-message.success {
    background-color: #d1fae5;
    color: #065f46;
    border: 1px solid #6ee7b7;
    display: block;
}

.form-message.error {
    background-color: #fee2e2;
    color: #991b1b;
    border: 1px solid #fca5a5;
    display: block;
}
