/* 
  Mexicana de Medios - Modern Design System
  minimalist, responsive, and vibrant orange tones
*/

@import url('https://fonts.googleapis.com/css2?family=Montserrat:wght@400;700&family=Inter:wght@300;400;500&display=swap');

:root {
    --primary: #FF5E00;
    --primary-light: #FF8533;
    --primary-dark: #E05200;
    --dark: #121212;
    --dark-accent: #1F1F1F;
    --white: #FFFFFF;
    --gray-light: #F9F9F9;
    --gray-mid: #EDEDED;
    --text-main: #2D2D2D;
    --text-muted: #666666;
    --transition: all 0.4s cubic-bezier(0.165, 0.84, 0.44, 1);
    --header-height: 80px;
}

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

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Inter', sans-serif;
    color: var(--text-main);
    background-color: var(--white);
    line-height: 1.6;
    overflow-x: hidden;
}

h1,
h2,
h3,
h4,
h5,
h6 {
    font-family: 'Montserrat', sans-serif;
    font-weight: 700;
    line-height: 1.2;
}

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

ul {
    list-style: none;
}

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

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
}

/* Utility Classes */
.section-padding {
    padding: 100px 0;
}

.text-orange {
    color: var(--primary);
}

.bg-orange {
    background-color: var(--primary);
}

.bg-dark {
    background-color: var(--dark);
    color: var(--white);
}

.reveal {
    opacity: 0;
    transform: translateY(30px);
    transition: var(--transition);
}

.reveal.active {
    opacity: 1;
    transform: translateY(0);
}

/* Header */
.header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: var(--header-height);
    display: flex;
    align-items: center;
    z-index: 1000;
    transition: var(--transition);
}

.header.scrolled {
    background: rgba(255, 255, 255, 0.8);
    backdrop-filter: blur(10px);
    height: 70px;
    box-shadow: 0 4px 30px rgba(0, 0, 0, 0.05);
}

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

.logo {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--white);
    /* White by default on hero */
    letter-spacing: -1px;
}

.header.scrolled .logo {
    color: var(--primary);
}

.nav-links {
    display: flex;
    gap: 2.5rem;
}

.nav-links a {
    font-size: 0.9rem;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 1px;
    position: relative;
    color: var(--white);
    /* Visible on hero */
}

.header.scrolled .nav-links a {
    color: var(--text-main);
}

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

.nav-links a:hover::after {
    width: 100%;
}

.nav-links a:hover {
    color: var(--primary);
}

/* Hero Section */
.hero {
    height: 100vh;
    display: flex;
    align-items: center;
    background: linear-gradient(135deg, rgba(18, 18, 18, 0.85) 0%, rgba(18, 18, 18, 0.4) 100%),
        url('https://images.unsplash.com/photo-1557804506-669a67965ba0?ixlib=rb-1.2.1&auto=format&fit=crop&w=1920&q=80');
    background-size: cover;
    background-position: center;
    color: var(--white);
    padding-top: var(--header-height);
}

.hero-content {
    max-width: 700px;
}

.hero h1 {
    font-size: 4rem;
    margin-bottom: 1.5rem;
}

.hero p {
    font-size: 1.2rem;
    margin-bottom: 2.5rem;
    opacity: 0.9;
    font-weight: 300;
}

.cta-button {
    display: inline-block;
    padding: 1rem 2.5rem;
    background-color: var(--primary);
    color: var(--white);
    border-radius: 50px;
    font-weight: 600;
    font-size: 1rem;
    border: 2px solid var(--primary);
}

.cta-button:hover {
    background-color: transparent;
    color: var(--primary);
}

/* Services Section */
.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 2rem;
    margin-top: 4rem;
}

.service-card {
    background: var(--gray-light);
    padding: 3rem 2rem;
    border-radius: 20px;
    transition: var(--transition);
    border: 1px solid var(--gray-mid);
}

.service-card:hover {
    transform: translateY(-10px);
    background: var(--white);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.05);
    border-color: var(--primary);
}

.service-card i {
    font-size: 2.5rem;
    color: var(--primary);
    margin-bottom: 1.5rem;
    display: block;
}

.service-card h3 {
    margin-bottom: 1rem;
}

.service-card p {
    color: var(--text-muted);
    font-size: 0.95rem;
}

/* Footer */
footer {
    padding: 80px 0 40px;
}

.footer-content {
    display: flex;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 3rem;
    margin-bottom: 3rem;
}

.footer-logo {
    max-width: 300px;
}

.footer-logo p {
    margin-top: 1rem;
    color: var(--text-muted);
}

.footer-links h4 {
    margin-bottom: 1.5rem;
    font-size: 1.1rem;
}

.footer-links ul li {
    margin-bottom: 0.8rem;
}

.footer-links ul li a {
    color: var(--text-muted);
}

.footer-links ul li a:hover {
    color: var(--primary);
    padding-left: 5px;
}

.footer-bottom {
    border-top: 1px solid var(--gray-mid);
    padding-top: 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    color: var(--text-muted);
    font-size: 0.9rem;
}

/* Mobile Menu */
.menu-toggle {
    display: none;
    flex-direction: column;
    gap: 6px;
    cursor: pointer;
    z-index: 1001;
    /* Ensure it stays above nav-links */
}

.menu-toggle span {
    width: 30px;
    height: 2px;
    background: var(--white);
    /* White by default on Hero */
    transition: var(--transition);
}

.header.scrolled .menu-toggle span {
    background: var(--primary);
}

/* X Transformation */
.menu-toggle.active span:nth-child(1) {
    transform: rotate(45deg) translate(6px, 6px);
    background: var(--primary);
    /* Always primary when open */
}

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

.menu-toggle.active span:nth-child(3) {
    transform: rotate(-45deg) translate(5px, -6px);
    background: var(--primary);
}

/* Media Queries */
@media (max-width: 991px) {
    .hero h1 {
        font-size: 3rem;
    }
}

@media (max-width: 768px) {
    .menu-toggle {
        display: flex;
    }

    .logo {
        color: var(--primary);
        /* Visibility over white mobile menu or standard mobile header */
    }

    .nav-links {
        position: fixed;
        top: 0;
        right: -100%;
        width: 80%;
        height: 100vh;
        background: var(--white);
        flex-direction: column;
        justify-content: center;
        align-items: center;
        transition: 0.5s ease;
        z-index: 999;
    }

    .nav-links.active {
        right: 0;
    }

    .nav-links a {
        font-size: 1.2rem;
        color: var(--text-main);
        /* Ensure visibility on white mobile background */
    }

    .hero h1 {
        font-size: 2.5rem;
    }

    .footer-content {
        flex-direction: column;
    }

    .footer-bottom {
        flex-direction: column;
        gap: 1rem;
        text-align: center;
    }
}