* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

@font-face {
    font-family: 'Jersey 25';
    src: url('../assets/fonts/Jersey25-Regular.ttf') format('truetype');
    font-weight: normal;
}

:root {
    --black: #050a0e;
    --dark: #0a1628;
    --teal: #0d3b3e;
    --cyan: #4ecdc4;
    --red: #e63946;
    --white: #f0f0f0;
    --font-main: 'Montserrat', sans-serif;
    --font-game: 'Jersey 25', sans-serif;
}

body {

    background-color: var(--black);
    background-image: url('../assets/images/hero-bg.jpg');
    background-size: cover;
    background-attachment: fixed;
    color: var(--white);
    font-family: var(--font-main);
    overflow-x: hidden;
}


/* NAVBAR */
nav {
    position: fixed;
    top: 0;
    width: 100%;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 40px;
    background: rgba(5, 10, 14, 0.9);
    backdrop-filter: blur(10px);
    z-index: 1000;
}

nav .logo img {
    height: 50px;
}

nav ul {
    display: flex;
    list-style: none;
    gap: 40px;
}

nav ul a {
    color: var(--white);
    text-decoration: none;
    font-size: 0.9rem;
    letter-spacing: 2px;
    transition: color 0.3s;
}

nav ul a:hover {
    color: var(--cyan);
}

nav .social-icons {
    display: flex;
    gap: 15px;
}

nav .social-icons a {
    display: flex;
    align-items: center;
    transition: opacity 0.3s, transform 0.3s;
}

nav .social-icons a img {
    width: 22px;
    height: 22px;
    object-fit: contain;
}

nav .social-icons a:hover {
    opacity: 0.7;
    transform: translateY(-2px);
}

.hidden {
    display: none;
}


/* SLIDER */
#hero {
    position: relative;
    width: 100%;
    height: 100vh;
    overflow: hidden;
}

.slide {
    position: absolute;
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
    opacity: 0;
    transition: opacity 1s ease;
}

.slide.active {
    opacity: 1;
    z-index: 1;
}

.slide[data-href] {
    cursor: pointer;
}

.slider-dots {
    position: absolute;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 10px;
    z-index: 10;
}

.dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: rgba(255,255,255,0.4);
    cursor: pointer;
    transition: background 0.3s;
}

.dot.active {
    background: var(--cyan);
}
/* STUDIO */
#studio {
    padding: 40px 60px;
    background: transparent;
}

.studio-content {
    max-width: 1100px;
    margin: 0 auto;
    display: flex;
    gap: 40px;
    align-items: center;
    background: rgba(11, 154, 164, 0.15);
    border-radius: 20px;
    padding: 50px 40px;
    border: 1px solid rgba(78, 205, 196, 0.15);
    backdrop-filter: blur(10px);
}

.studio-left {
    flex: 1;
}

.studio-left h2 {
    font-size: 2.2rem;
    font-weight: 800;
    margin-bottom: 15px;
    line-height: 1.2;
}

.studio-left p {
    font-size: 0.88rem;
    opacity: 0.8;
    line-height: 1.7;
    margin-bottom: 25px;
}

.studio-buttons {
    display: flex;
    gap: 15px;
}

.btn-primary {
    background: linear-gradient(135deg, #4ecdc4, #44b8f5);
    color: var(--black);
    border: none;
    padding: 10px 30px;
    border-radius: 25px;
    cursor: pointer;
    font-weight: 600;
    font-size: 0.95rem;
    transition: opacity 0.3s;
}

.btn-primary:hover {
    opacity: 0.85;
}

.btn-secondary {
    background: transparent;
    color: var(--white);
    border: 1px solid var(--cyan);
    padding: 10px 30px;
    border-radius: 25px;
    text-decoration: none;
    font-weight: 600;
    font-size: 0.95rem;
    transition: all 0.3s;
}

.btn-secondary:hover {
    background: rgba(78, 205, 196, 0.1);
}

.studio-right {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.card {
    background: rgba(13, 59, 62, 0.5);
    border-radius: 15px;
    padding: 20px 25px;
    display: flex;
    align-items: center;
    gap: 20px;
    border: 1px solid rgba(78, 205, 196, 0.2);
}

.card-icon {
    width: 60px;
    height: 60px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.card-icon img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.card-text h3 {
    font-size: 0.85rem;
    letter-spacing: 3px;
    color: var(--white);
    margin-bottom: 8px;
}

.card-text p {
    font-size: 0.8rem;
    opacity: 0.75;
    line-height: 1.5;
}

/* QUOTES */
#quotes {
    position: relative;
    height: 600px;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
}

.parallax-layer {
    position: absolute;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    pointer-events: none;
}

#layer-constellation-left img {
    position: absolute;
    left: 8%;
    top: 25%;
    width: 180px;
    opacity: 0.7;
}

#layer-constellation-right img {
    position: absolute;
    right: 8%;
    top: 20%;
    width: 160px;
    opacity: 0.7;
}

.quote-left {
    position: absolute;
    left: 5%;
    top: 62%;
    width: 220px;
    text-align: center;
    font-size: 0.8rem;
    opacity: 0.7;
    line-height: 1.6;
}

.quote-right {
    position: absolute;
    right: 5%;
    top: 62%;
    width: 220px;
    text-align: center;
    font-size: 0.8rem;
    opacity: 0.7;
    line-height: 1.6;
}
.quote-left p, .quote-right p {
    transition: opacity 0.5s ease;
}


/* PORTFOLIO */
#portfolio {
    padding: 80px 60px;
}

.portfolio-content {
    max-width: 1100px;
    margin: 0 auto;
}

.portfolio-content h2 {
    font-size: 1.8rem;
    margin-bottom: 40px;
    opacity: 0.9;
}

.portfolio-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 25px;
}

.portfolio-card {
    background: rgba(11, 154, 164, 0.1);
    border-radius: 15px;
    overflow: hidden;
    border: 1px solid rgba(78, 205, 196, 0.15);
    text-decoration: none;
    color: var(--white);
}

.portfolio-card.clickable {
    cursor: pointer;
    transition: transform 0.3s, border-color 0.3s;
}

.portfolio-card.clickable:hover {
    transform: translateY(-5px);
    border-color: var(--cyan);
}

.portfolio-card.disabled {
    opacity: 0.6;
    cursor: default;
}

.card-thumb {
    position: relative;
    overflow: hidden;
    aspect-ratio: 16/9;
}

.card-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 15px 15px 0 0;
}

.card-overlay {
    position: absolute;
    inset: 0;
    background: rgba(11, 154, 164, 0.7);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    letter-spacing: 2px;
    opacity: 0;
    transition: opacity 0.3s;
}

.portfolio-card.clickable:hover .card-overlay {
    opacity: 1;
}

.card-info {
    padding: 20px;
}

.card-type {
    font-size: 0.75rem;
    opacity: 0.6;
    letter-spacing: 2px;
    display: block;
    margin-bottom: 8px;
}

.card-info h3 {
    font-size: 1.1rem;
    margin-bottom: 6px;
}

.card-info p {
    font-size: 0.8rem;
    opacity: 0.6;
}

/* FOOTER */
footer {
    padding: 40px 60px 30px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 30px;
    border-top: 1px solid rgba(78, 205, 196, 0.15);
}

.back-to-top {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    text-decoration: none;
    color: var(--white);
    opacity: 0.6;
    transition: opacity 0.3s;
}

.back-to-top:hover {
    opacity: 1;
}

.back-to-top span {
    font-size: 1.5rem;
}

.back-to-top p {
    font-size: 0.75rem;
    letter-spacing: 3px;
}

.footer-bottom p {
    font-size: 0.75rem;
    opacity: 0.4;
    letter-spacing: 1px;
}

/* CONTACT POPUP */
#contact-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.7);
    backdrop-filter: blur(5px);
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
}

#contact-popup {
    background: rgba(8, 40, 50, 0.95);
    border: 1px solid rgba(78, 205, 196, 0.2);
    border-radius: 20px;
    padding: 50px 40px 40px;
    width: 550px;
    max-width: 90vw;
    display: flex;
    flex-direction: column;
    gap: 15px;
    position: relative;
}

#contact-popup h2 {
    text-align: center;
    font-size: 1.3rem;
    margin-bottom: 10px;
    opacity: 0.9;
}

#close-contact {
    position: absolute;
    top: 15px;
    right: 20px;
    background: transparent;
    border: none;
    color: var(--white);
    font-size: 1.2rem;
    cursor: pointer;
    opacity: 0.5;
    transition: opacity 0.3s;
}

#close-contact:hover {
    opacity: 1;
}

#contact-popup input,
#contact-popup textarea {
    background: rgba(11, 154, 164, 0.15);
    border: 1px solid rgba(78, 205, 196, 0.2);
    border-radius: 10px;
    padding: 15px 20px;
    color: var(--white);
    font-size: 0.9rem;
    outline: none;
    transition: border-color 0.3s;
}

#contact-popup input:focus,
#contact-popup textarea:focus {
    border-color: var(--cyan);
}

#contact-popup textarea {
    height: 150px;
    resize: none;
}

#contact-send {
    background: linear-gradient(135deg, #4ecdc4, #44b8f5);
    color: var(--black);
    border: none;
    padding: 14px;
    border-radius: 25px;
    cursor: pointer;
    font-weight: 700;
    letter-spacing: 2px;
    margin-top: 10px;
    transition: opacity 0.3s;
}

#contact-send:hover {
    opacity: 0.85;
}
#contact-overlay.hidden {
    display: none !important;
}

/* ============ NAVBAR RESPONSIVE ============ */

.nav-menu {
    display: flex;
    align-items: center;
    gap: 40px;
}

.nav-toggle {
    display: none;
    flex-direction: column;
    justify-content: center;
    gap: 5px;
    width: 32px;
    height: 32px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 0;
    z-index: 1100;
}

.nav-toggle span {
    display: block;
    width: 100%;
    height: 2px;
    background: var(--white);
    border-radius: 2px;
    transition: transform 0.3s ease, opacity 0.3s ease;
}

/* X cuando el menú está abierto */
nav.open .nav-toggle span:nth-child(1) {
    transform: translateY(7px) rotate(45deg);
}

nav.open .nav-toggle span:nth-child(2) {
    opacity: 0;
}

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

@media (max-width: 768px) {
    nav {
        padding: 15px 20px;
    }

    nav .logo img {
        height: 40px;
    }

    .nav-toggle {
        display: flex;
    }

    /* Menú colapsado: oculto fuera de pantalla */
    .nav-menu {
        position: fixed;
        top: 0;
        right: 0;
        height: 100vh;
        width: min(75vw, 320px);
        background: rgba(5, 10, 14, 0.97);
        backdrop-filter: blur(10px);
        flex-direction: column;
        justify-content: center;
        align-items: center;
        gap: 40px;
        transform: translateX(100%);
        transition: transform 0.35s ease;
        z-index: 1050;
    }

    nav.open .nav-menu {
        transform: translateX(0);
    }

    nav ul {
        flex-direction: column;
        gap: 30px;
        text-align: center;
    }

    nav ul a {
        font-size: 1.1rem;
    }

    nav .social-icons {
        gap: 25px;
    }

    nav .social-icons a img {
        width: 26px;
        height: 26px;
    }
}

/* ============ FOOTER RESPONSIVE ============ */

@media (max-width: 768px) {
    footer {
        padding: 35px 20px 25px;
    }
}

/* ============ LANDING — STUDIO / QUOTES / PORTFOLIO RESPONSIVE ============ */

@media (max-width: 768px) {

    /* STUDIO — las cards pasan de "al lado" a "debajo" del texto */
    .studio-content {
        flex-direction: column;
        padding: 35px 25px;
        gap: 25px;
    }

    .studio-left,
    .studio-right {
        width: 100%;
    }

    .studio-left h2 {
        font-size: 1.7rem;
    }

    .studio-buttons {
        flex-wrap: wrap;
    }

    /* QUOTES — el logo deja de ser un fondo gigante con texto encima;
       todo pasa a flujo vertical normal */
    #quotes {
        height: auto;
        flex-direction: column;
        padding: 60px 25px;
        gap: 30px;
    }

    /* las constelaciones decorativas estorban en mobile, se ocultan */
    #layer-constellation-left,
    #layer-constellation-right {
        display: none;
    }

    #layer-moon {
        position: relative;
        width: 100%;
        height: auto;
    }

    #layer-moon img {
        position: relative;
        max-width: 200px;
        margin: 0 auto;
    }

    .quote-left,
    .quote-right {
        position: relative;
        left: auto;
        right: auto;
        top: auto;
        width: 100%;
        max-width: 320px;
        margin: 0 auto;
    }

    /* PORTFOLIO — una columna */
    .portfolio-grid {
        grid-template-columns: 1fr;
    }
}

/* ============ HERO SLIDER RESPONSIVE ============ */

@media (max-width: 768px) {
    /* #hero ya no fuerza 100vh — con contain, el alto se ajusta a la
       proporción real de las imágenes (16:9), sin franjas negras extra */
    #hero {
        height: auto;
        aspect-ratio: 16 / 9;
        margin-top: 70px;
    }

    /* Las 3 imágenes tienen texto/UI quemado de borde a borde — cover
       siempre corta algo importante en mobile. contain muestra cada
       imagen completa; no-repeat evita el mosaico, y el color de fondo
       rellena cualquier franja residual si la proporción no calza exacto. */
    .slide {
        background-size: contain;
        background-repeat: no-repeat;
        background-color: var(--black);
    }
}
