/* ================================================
   TRANSPORTES FERNÁNDEZ - Estilos principales
   Diseño: Industrial moderno con toques premium
   ================================================ */

/* CSS Variables */
:root {
    /* Colores principales - basados en el morado de la marca */
    --color-primary: #4A3B8C;
    --color-primary-dark: #352A66;
    --color-primary-light: #6B5BAD;
    --color-accent: #C41E3A;
    --color-accent-light: #E8334F;
    
    /* Neutros */
    --color-dark: #1A1A2E;
    --color-gray-900: #2D2D44;
    --color-gray-700: #4A4A5E;
    --color-gray-500: #7A7A8E;
    --color-gray-300: #B8B8C8;
    --color-gray-100: #EAEAF0;
    --color-light: #F8F8FC;
    --color-white: #FFFFFF;
    
    /* Tipografía */
    --font-heading: 'Playfair Display', Georgia, serif;
    --font-body: 'DM Sans', -apple-system, BlinkMacSystemFont, sans-serif;
    
    /* Espaciado */
    --space-xs: 0.5rem;
    --space-sm: 1rem;
    --space-md: 1.5rem;
    --space-lg: 2rem;
    --space-xl: 3rem;
    --space-2xl: 5rem;
    --space-3xl: 8rem;
    
    /* Otros */
    --radius-sm: 4px;
    --radius-md: 8px;
    --radius-lg: 16px;
    --shadow-sm: 0 2px 8px rgba(26, 26, 46, 0.08);
    --shadow-md: 0 4px 20px rgba(26, 26, 46, 0.12);
    --shadow-lg: 0 8px 40px rgba(26, 26, 46, 0.16);
    --transition: 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    
    --header-height: 80px;
}

/* Reset & Base */
*, *::before, *::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    font-size: 16px;
}

body {
    font-family: var(--font-body);
    font-size: 1rem;
    line-height: 1.6;
    color: var(--color-gray-700);
    background-color: var(--color-white);
    overflow-x: hidden;
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

a {
    text-decoration: none;
    color: inherit;
    transition: var(--transition);
}

ul {
    list-style: none;
}

/* Container */
.container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 var(--space-md);
}

/* Typography */
h1, h2, h3, h4 {
    font-family: var(--font-heading);
    color: var(--color-dark);
    line-height: 1.2;
    font-weight: 700;
}

h1 { font-size: clamp(2.5rem, 5vw, 4rem); }
h2 { font-size: clamp(2rem, 4vw, 3rem); }
h3 { font-size: clamp(1.25rem, 2vw, 1.5rem); }
h4 { font-size: 1.125rem; }

p {
    margin-bottom: var(--space-sm);
}

strong {
    color: var(--color-dark);
    font-weight: 600;
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.875rem 2rem;
    font-family: var(--font-body);
    font-size: 0.9375rem;
    font-weight: 500;
    border-radius: var(--radius-md);
    border: 2px solid transparent;
    cursor: pointer;
    transition: var(--transition);
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.btn-primary {
    background: var(--color-primary);
    color: var(--color-white);
    border-color: var(--color-primary);
}

.btn-primary:hover {
    background: var(--color-primary-dark);
    border-color: var(--color-primary-dark);
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

.btn-secondary {
    background: transparent;
    color: var(--color-white);
    border-color: var(--color-white);
}

.btn-secondary:hover {
    background: var(--color-white);
    color: var(--color-primary);
}

.btn-outline {
    background: transparent;
    color: var(--color-primary);
    border-color: var(--color-primary);
}

.btn-outline:hover {
    background: var(--color-primary);
    color: var(--color-white);
}

.btn-white {
    background: var(--color-white);
    color: var(--color-primary);
    border-color: var(--color-white);
}

.btn-white:hover {
    background: var(--color-light);
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

/* Section Labels & Titles */
.section-label {
    display: inline-block;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.15em;
    color: var(--color-primary);
    margin-bottom: var(--space-sm);
    position: relative;
    padding-left: 3rem;
}

.section-label::before {
    content: '';
    position: absolute;
    left: 0;
    top: 50%;
    width: 2rem;
    height: 2px;
    background: var(--color-primary);
}

.section-title {
    margin-bottom: var(--space-lg);
}

.section-header {
    text-align: center;
    max-width: 600px;
    margin: 0 auto var(--space-2xl);
}

.section-header .section-label {
    padding-left: 0;
}

.section-header .section-label::before {
    display: none;
}

/* ================================================
   HEADER
   ================================================ */
.header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    height: var(--header-height);
    background: var(--color-white);
    z-index: 1000;
    transition: var(--transition);
}

.header.scrolled {
    box-shadow: var(--shadow-sm);
}

.header-content {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 100%;
}

.logo {
    display: flex;
    align-items: center;
}

.logo-img {
    height: 50px;
    width: auto;
}

.nav-list {
    display: flex;
    align-items: center;
    gap: var(--space-lg);
}

.nav-link {
    font-size: 0.9375rem;
    font-weight: 500;
    color: var(--color-gray-700);
    position: relative;
    padding: var(--space-xs) 0;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--color-primary);
    transition: var(--transition);
}

.nav-link:hover,
.nav-link.active {
    color: var(--color-primary);
}

.nav-link:hover::after,
.nav-link.active::after {
    width: 100%;
}

.nav-link--cta {
    background: var(--color-primary);
    color: var(--color-white) !important;
    padding: 0.625rem 1.25rem;
    border-radius: var(--radius-md);
}

.nav-link--cta::after {
    display: none;
}

.nav-link--cta:hover {
    background: var(--color-primary-dark);
    transform: translateY(-2px);
}

/* Mobile Menu Toggle */
.menu-toggle {
    display: none;
    flex-direction: column;
    justify-content: center;
    gap: 5px;
    width: 30px;
    height: 30px;
    background: none;
    border: none;
    cursor: pointer;
    z-index: 1001;
}

.menu-toggle span {
    display: block;
    width: 100%;
    height: 2px;
    background: var(--color-dark);
    transition: var(--transition);
}

.menu-toggle.active span:nth-child(1) {
    transform: translateY(7px) rotate(45deg);
}

.menu-toggle.active span:nth-child(2) {
    opacity: 0;
}

.menu-toggle.active span:nth-child(3) {
    transform: translateY(-7px) rotate(-45deg);
}

/* ================================================
   HERO
   ================================================ */
.hero {
    position: relative;
    min-height: 100vh;
    display: flex;
    align-items: center;
    padding-top: var(--header-height);
    overflow: hidden;
}

.hero-bg {
    position: absolute;
    inset: 0;
    z-index: -2;
}

.hero-bg img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.hero-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(
        135deg,
        rgba(26, 26, 46, 0.9) 0%,
        rgba(74, 59, 140, 0.75) 100%
    );
    z-index: -1;
}

.hero-content {
    position: relative;
    max-width: 700px;
    color: var(--color-white);
    padding: var(--space-2xl) 0;
}

.hero-subtitle {
    font-size: 0.875rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.2em;
    color: var(--color-gray-300);
    margin-bottom: var(--space-md);
    animation: fadeInUp 0.8s ease-out;
}

.hero-title {
    color: var(--color-white);
    margin-bottom: var(--space-md);
    animation: fadeInUp 0.8s ease-out 0.1s both;
}

.hero-title span {
    color: var(--color-gray-300);
    font-style: italic;
}

.hero-text {
    font-size: 1.125rem;
    color: var(--color-gray-300);
    margin-bottom: var(--space-xl);
    max-width: 500px;
    animation: fadeInUp 0.8s ease-out 0.2s both;
}

.hero-buttons {
    display: flex;
    flex-wrap: wrap;
    gap: var(--space-sm);
    animation: fadeInUp 0.8s ease-out 0.3s both;
}

.hero-scroll {
    position: absolute;
    bottom: var(--space-xl);
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: var(--space-sm);
    color: var(--color-gray-300);
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    animation: fadeIn 1s ease-out 0.5s both;
}

.hero-scroll-line {
    width: 1px;
    height: 60px;
    background: linear-gradient(to bottom, var(--color-gray-300), transparent);
    animation: scrollLine 2s ease-in-out infinite;
}

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

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

@keyframes scrollLine {
    0%, 100% { transform: scaleY(1); opacity: 1; }
    50% { transform: scaleY(0.5); opacity: 0.5; }
}

/* ================================================
   STATS
   ================================================ */
.stats {
    background: var(--color-primary);
    padding: var(--space-xl) 0;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: var(--space-lg);
}

.stat-item {
    text-align: center;
    color: var(--color-white);
}

.stat-number {
    display: block;
    font-family: var(--font-heading);
    font-size: clamp(2rem, 4vw, 3rem);
    font-weight: 700;
    margin-bottom: var(--space-xs);
}

.stat-label {
    font-size: 0.875rem;
    color: var(--color-gray-300);
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

/* ================================================
   ABOUT PREVIEW
   ================================================ */
.about-preview {
    padding: var(--space-3xl) 0;
    background: var(--color-light);
}

.about-preview-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: var(--space-2xl);
    align-items: center;
}

.about-preview-image {
    position: relative;
}

.about-preview-image img {
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-lg);
}

.about-preview-badge {
    position: absolute;
    bottom: -20px;
    right: -20px;
    background: var(--color-primary);
    color: var(--color-white);
    padding: var(--space-md) var(--space-lg);
    border-radius: var(--radius-md);
    text-align: center;
    box-shadow: var(--shadow-md);
}

.badge-number {
    display: block;
    font-family: var(--font-heading);
    font-size: 2rem;
    font-weight: 700;
}

.badge-text {
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--color-gray-300);
}

.about-preview-content p {
    margin-bottom: var(--space-md);
}

.check-list {
    margin: var(--space-lg) 0;
}

.check-list li {
    position: relative;
    padding-left: var(--space-lg);
    margin-bottom: var(--space-sm);
    color: var(--color-gray-700);
}

.check-list li::before {
    content: '✓';
    position: absolute;
    left: 0;
    color: var(--color-primary);
    font-weight: 700;
}

/* ================================================
   SERVICES PREVIEW
   ================================================ */
.services-preview {
    padding: var(--space-3xl) 0;
    background: var(--color-white);
}

.services-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: var(--space-lg);
}

.service-card {
    background: var(--color-white);
    border-radius: var(--radius-lg);
    overflow: hidden;
    box-shadow: var(--shadow-sm);
    transition: var(--transition);
}

.service-card:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-lg);
}

.service-card-image {
    height: 220px;
    overflow: hidden;
}

.service-card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: var(--transition);
}

.service-card:hover .service-card-image img {
    transform: scale(1.05);
}

.service-card-content {
    padding: var(--space-lg);
}

.service-card-content h3 {
    margin-bottom: var(--space-sm);
}

.service-card-content p {
    color: var(--color-gray-500);
    margin-bottom: 0;
}

.services-cta {
    text-align: center;
    margin-top: var(--space-2xl);
}

/* ================================================
   CTA
   ================================================ */
.cta {
    position: relative;
    padding: var(--space-3xl) 0;
    overflow: hidden;
}

.cta-bg {
    position: absolute;
    inset: 0;
    z-index: -2;
}

.cta-bg img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.cta-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(
        135deg,
        rgba(74, 59, 140, 0.95) 0%,
        rgba(26, 26, 46, 0.9) 100%
    );
    z-index: -1;
}

.cta-content {
    text-align: center;
    color: var(--color-white);
    max-width: 600px;
    margin: 0 auto;
}

.cta-content h2 {
    color: var(--color-white);
    margin-bottom: var(--space-md);
}

.cta-content p {
    color: var(--color-gray-300);
    font-size: 1.125rem;
    margin-bottom: var(--space-xl);
}

/* ================================================
   FOOTER
   ================================================ */
.footer {
    background: var(--color-dark);
    color: var(--color-gray-300);
    padding-top: var(--space-2xl);
}

.footer-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1fr;
    gap: var(--space-xl);
}

.footer-logo {
    height: 60px;
    margin-bottom: var(--space-md);
    filter: brightness(0) invert(1);
}

.footer-brand p {
    font-size: 0.9375rem;
    line-height: 1.7;
}

.footer h4 {
    color: var(--color-white);
    font-family: var(--font-body);
    font-size: 1rem;
    font-weight: 600;
    margin-bottom: var(--space-md);
}

.footer-contact li {
    display: flex;
    align-items: flex-start;
    gap: var(--space-sm);
    margin-bottom: var(--space-sm);
}

.footer-contact svg {
    flex-shrink: 0;
    margin-top: 2px;
    color: var(--color-primary-light);
}

.footer-contact a:hover {
    color: var(--color-white);
}

.footer-links a,
.footer-legal a {
    display: block;
    padding: var(--space-xs) 0;
    font-size: 0.9375rem;
}

.footer-links a:hover,
.footer-legal a:hover {
    color: var(--color-white);
    padding-left: var(--space-xs);
}

.footer-bottom {
    margin-top: var(--space-xl);
    padding: var(--space-md) 0;
    border-top: 1px solid var(--color-gray-700);
}

.footer-bottom p {
    font-size: 0.875rem;
    text-align: center;
    margin: 0;
}

/* ================================================
   PAGE HEADER (for internal pages)
   ================================================ */
.page-header {
    background: var(--color-primary);
    padding: calc(var(--header-height) + var(--space-2xl)) 0 var(--space-2xl);
    text-align: center;
    color: var(--color-white);
}

.page-header h1 {
    color: var(--color-white);
    margin-bottom: var(--space-sm);
}

.page-header p {
    color: var(--color-gray-300);
    font-size: 1.125rem;
    max-width: 600px;
    margin: 0 auto;
}

/* ================================================
   CONTENT SECTIONS
   ================================================ */
.content-section {
    padding: var(--space-2xl) 0;
}

.content-section.alt {
    background: var(--color-light);
}

/* Gallery Grid */
.gallery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: var(--space-md);
}

.gallery-item {
    border-radius: var(--radius-md);
    overflow: hidden;
    aspect-ratio: 4/3;
}

.gallery-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: var(--transition);
}

.gallery-item:hover img {
    transform: scale(1.05);
}

/* Contact Grid */
.contact-grid {
    display: grid;
    grid-template-columns: 1fr 1.5fr;
    gap: var(--space-2xl);
}

.contact-info-card {
    background: var(--color-light);
    padding: var(--space-xl);
    border-radius: var(--radius-lg);
}

.contact-info-card h3 {
    margin-bottom: var(--space-lg);
}

.contact-info-item {
    display: flex;
    align-items: flex-start;
    gap: var(--space-md);
    margin-bottom: var(--space-lg);
}

.contact-info-item svg {
    flex-shrink: 0;
    color: var(--color-primary);
    margin-top: 2px;
}

.contact-info-item strong {
    display: block;
    margin-bottom: var(--space-xs);
}

/* Forms */
.form-group {
    margin-bottom: var(--space-md);
}

.form-group label {
    display: block;
    font-weight: 500;
    margin-bottom: var(--space-xs);
    color: var(--color-dark);
}

.form-group input,
.form-group textarea,
.form-group select {
    width: 100%;
    padding: 0.875rem 1rem;
    font-family: var(--font-body);
    font-size: 1rem;
    border: 2px solid var(--color-gray-300);
    border-radius: var(--radius-md);
    background: var(--color-white);
    transition: var(--transition);
}

.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
    outline: none;
    border-color: var(--color-primary);
}

.form-group textarea {
    min-height: 150px;
    resize: vertical;
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: var(--space-md);
}

.form-checkbox {
    display: flex;
    align-items: flex-start;
    gap: var(--space-sm);
    cursor: pointer;
}

.form-checkbox input {
    width: auto;
    margin-top: 4px;
}

.form-checkbox span {
    font-size: 0.875rem;
    color: var(--color-gray-500);
}

.form-checkbox a {
    color: var(--color-primary);
    text-decoration: underline;
}

/* Legal Pages */
.legal-content {
    max-width: 800px;
    margin: 0 auto;
}

.legal-content h2 {
    font-size: 1.5rem;
    margin-top: var(--space-xl);
    margin-bottom: var(--space-md);
}

.legal-content h2:first-child {
    margin-top: 0;
}

.legal-content p,
.legal-content li {
    margin-bottom: var(--space-sm);
}

.legal-content ul,
.legal-content ol {
    padding-left: var(--space-lg);
    margin-bottom: var(--space-md);
}

/* ================================================
   RESPONSIVE
   ================================================ */
@media (max-width: 1024px) {
    .about-preview-grid,
    .contact-grid {
        grid-template-columns: 1fr;
        gap: var(--space-xl);
    }
    
    .about-preview-image {
        order: -1;
    }
    
    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .services-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .footer-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    :root {
        --header-height: 70px;
    }
    
    .menu-toggle {
        display: flex;
    }
    
    .nav {
        position: fixed;
        top: 0;
        right: -100%;
        width: 280px;
        height: 100vh;
        background: var(--color-white);
        padding: calc(var(--header-height) + var(--space-lg)) var(--space-lg) var(--space-lg);
        box-shadow: var(--shadow-lg);
        transition: var(--transition);
    }
    
    .nav.active {
        right: 0;
    }
    
    .nav-list {
        flex-direction: column;
        align-items: stretch;
        gap: 0;
    }
    
    .nav-link {
        display: block;
        padding: var(--space-md) 0;
        border-bottom: 1px solid var(--color-gray-100);
    }
    
    .nav-link--cta {
        margin-top: var(--space-md);
        text-align: center;
    }
    
    .services-grid {
        grid-template-columns: 1fr;
    }
    
    .stats-grid {
        grid-template-columns: 1fr 1fr;
        gap: var(--space-md);
    }
    
    .hero-buttons {
        flex-direction: column;
    }
    
    .btn {
        width: 100%;
    }
    
    .form-row {
        grid-template-columns: 1fr;
    }
    
    .footer-grid {
        grid-template-columns: 1fr;
        text-align: center;
    }
    
    .footer-contact li {
        justify-content: center;
    }
    
    .about-preview-badge {
        position: relative;
        bottom: auto;
        right: auto;
        display: inline-block;
        margin-top: var(--space-md);
    }
}

@media (max-width: 480px) {
    .stats-grid {
        grid-template-columns: 1fr;
    }
    
    .hero-scroll {
        display: none;
    }
}

/* ================================================
   UTILITIES
   ================================================ */
.text-center { text-align: center; }
.text-primary { color: var(--color-primary); }
.mb-0 { margin-bottom: 0; }
.mb-1 { margin-bottom: var(--space-sm); }
.mb-2 { margin-bottom: var(--space-md); }
.mb-3 { margin-bottom: var(--space-lg); }
