    
    :root {
        --primary-color: #00bfff; /* Celeste similar al cielo */
        --secondary-color: #ffffff; /* Blanco */
        --accent-color1: #0038a8; /* Azul profundo */
        --accent-color2: #c8102e; /* Rojo vibrante */
        --text-color: #222;
        --background-color: #f9f9f9;
        --max-width: 1200px;
    }
    * { margin:0; padding:0; box-sizing: border-box; }
    body {
        font-family: Arial, sans-serif;
        line-height:1.6;
        background-color: var(--background-color);
        color: var(--text-color);
    }
    header {
        background-image: url('fondo-header.png');
        background-size: cover;
        background-position: center;
        color: var(--secondary-color);
        position: relative;
    }
    header::before {
        content:'';
        position:absolute;
        top:0; left:0; right:0; bottom:0;
        background: rgba(0,0,0,0.5);
    }
    nav {
        display:flex;
        justify-content: space-between;
        align-items:center;
        padding:1rem;
        max-width: var(--max-width);
        margin: 0 auto;
        position: relative;
        z-index:2;
    }
    nav .logo {
        font-size:1.5rem;
        font-weight:bold;
        color: var(--secondary-color);
    }
    nav ul {
        list-style: none;
        display:flex;
    }
    nav ul li {
        margin-left:1.5rem;
    }
    nav ul li a {
        text-decoration:none;
        color: var(--secondary-color);
        font-weight: 500;
        transition: color 0.3s ease;
    }
    nav ul li a:hover {
        color: var(--accent-color2);
    }
    /* Mobile nav */
    .menu-toggle {
        display:none;
        flex-direction: column;
        cursor:pointer;
    }
    .menu-toggle span {
        height:2px;
        width:25px;
        background: var(--secondary-color);
        margin:4px;
        transition: all 0.3s ease;
    }
    @media(max-width:768px) {
        nav ul {
            position:absolute;
            top:60px;
            right:0;
            background: rgba(0,0,0,0.8);
            flex-direction: column;
            width:200px;
            display:none;
        }
        nav ul.show {
            display:flex;
        }
        nav ul li {
            margin:1rem;
        }
        .menu-toggle {
            display:flex;
        }
    }
    .hero {
        padding: 4rem 1rem;
        text-align:center;
        max-width: var(--max-width);
        margin:0 auto;
        position: relative;
        z-index:2;
    }
    .hero h1 {
        font-size:2.5rem;
        margin-bottom:1rem;
    }
    .hero p {
        font-size:1.2rem;
        margin-bottom:2rem;
    }
    .btn {
        background: var(--accent-color1);
        color: var(--secondary-color);
        padding:0.7rem 1.5rem;
        border-radius:4px;
        text-decoration:none;
        font-weight:bold;
        transition: background 0.3s ease;
    }
    .btn:hover { background: var(--accent-color2); }
    section {
        padding:4rem 1rem;
        max-width: var(--max-width);
        margin:0 auto;
    }
    .section-title {
        text-align:center;
        margin-bottom:2rem;
        font-size:2rem;
        color: var(--accent-color1);
    }
    .skills-list {
        display:flex;
        flex-wrap:wrap;
        justify-content:center;
    }
    .objectives-list {
        list-style: disc;
        margin: 0 auto;
        max-width: 600px;
        padding-left: 1.5rem;
        text-align: left;
    }
    .objectives-list li {
        margin-bottom: 0.5rem;
    }
    .skill {
        background: var(--secondary-color);
        border:1px solid var(--primary-color);
        color: var(--accent-color1);
        border-radius:8px;
        padding:0.5rem 1rem;
        margin:0.5rem;
        flex:1 1 auto;
        text-align:center;
    }
    .projects {
        display:grid;
        /* Use auto-fit to adapt the number of columns to available space */
        grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
        gap:1.5rem;
        /* Force equal row heights so shorter cards stretch to match the tallest */
        grid-auto-rows: 1fr;
    }
    .project-card {
        background: var(--secondary-color);
        border-radius:8px;
        box-shadow:0 4px 6px rgba(0,0,0,0.1);
        overflow:hidden;
        transition:transform 0.2s ease;
        /* Flex layout so content stretches to fill height */
        display: flex;
        flex-direction: column;
    }
    .project-card:hover {
        transform: translateY(-5px);
    }
    .project-card img {
        width:100%;
        height:160px;
        object-fit: cover;
    }
    .project-card .content {
        padding:1rem;
    }
    /* Custom styling for project media sections */
    .project-media {
        height: 200px;
        display: flex;
        align-items: center;
        justify-content: center;
        position: relative;
        overflow: hidden;
    }
    /* 24N card uses the swirling background image */
    .media-24n {
        background: url('assets/bg-olas.jpg') center/cover no-repeat;
    }
    .media-24n::after {
        content: '';
        position: absolute;
        inset: 0;
        background: linear-gradient(0deg, rgba(0,0,0,0.25), rgba(0,0,0,0.25));
    }
    .project-media-title {
        position: relative;
        z-index: 1;
        color: #ffffff;
        font-weight: 700;
        font-size: 1.75rem;
        text-shadow: 0 2px 8px rgba(0,0,0,0.45);
    }

    /* Override header to use swirling background image and reduce height */
    header {
        background: url('assets/bg-olas.jpg') center/cover no-repeat;
        min-height: 48vh;
    }

    /* Compact hero padding */
    .hero {
        padding: 3rem 1rem;
    }

    /* Override the first project's media background (24Norte card) to use the swirling image */
    .projects .project-card:first-child .project-media {
        background-image: url('assets/bg-olas.jpg') !important;
        background-size: cover !important;
        background-position: center !important;
    }
    .projects .project-card:first-child .project-media::after {
        content: '';
        position: absolute;
        inset: 0;
        background: linear-gradient(0deg, rgba(0,0,0,0.25), rgba(0,0,0,0.25));
    }
    .projects .project-card:first-child .project-media span {
        position: relative;
        z-index: 1;
        font-size: 2rem;
        font-weight: bold;
        color: #ffffff;
        text-shadow: 0 2px 8px rgba(0,0,0,0.45);
    }
    /* Ensure embedded iframes (e.g., CodePen demos) scale properly within project cards */
    .project-card iframe {
        width: 100%;
        height: 280px;
        border: none;
        display: block;
    }
    .project-card h3 {
        margin-bottom:0.5rem;
    }
    .project-card p {
        font-size:0.95rem;
        margin-bottom:1rem;
    }
    .contact form {
        display:grid;
        grid-template-columns: 1fr;
        gap:1rem;
    }
    .contact input, .contact textarea {
        padding:0.7rem;
        border-radius:4px;
        border:1px solid var(--primary-color);
        font-size:1rem;
    }
    .contact button {
        width:200px;
        justify-self:center;
    }
    footer {
        background: var(--primary-color);
        color: var(--secondary-color);
        text-align:center;
        padding:1rem 0;
    }
    /* Animations on scroll (fade in) */
    .fade-in {
        opacity:0;
        transform: translateY(20px);
        transition: opacity 0.6s ease-out, transform 0.6s ease-out;
    }
    .fade-in.visible {
        opacity:1;
        transform: translateY(0);
    }
