/* 1. GLOBAL STYLES AND RESET */

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    background-color: #191919; /* Dark default background for the home view */
    font-family: 'Cascadia Code', monospace;
    color: #dcdcdc; /* White text as base */
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    overflow-x: hidden; /* Prevents ugly horizontal scrolling bars */
}

/* 2. NAV BAR HEADER*/
.site-header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    padding: 1px 0; /* Menú más compacto para evitar que colisione de más */
    z-index: 1000;
    background-color: rgba(244, 102, 83, 0.12);
    backdrop-filter: blur(8px); /* Efecto cristal esmerilado */
    transition: background-color 0.3s ease, padding 0.3s ease, transform 0.3s ease-in-out;
}

.nav-menu {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
    padding: 0 5%;
    gap: 24px; /* minimum breathing room space-between can't shrink past */
    flex-wrap: nowrap;
}

/* LOGO */
.nav-logo-link {
    width: 80px;
    display: block;
    opacity: .4;
}

.nav-links-center {
    display: flex;
    justify-content: center;
    gap: 40px;
}

.nav-logo {
    width: 100%;
    height: auto;
    display: block;
}

.nav-link {
    color: #dcdcdc;
    text-decoration: none;
    font-size: 13px;
    font-weight: 400;
    letter-spacing: 1px;
    transition: color 0.3s ease;
}

.nav-link.active {
    color: #f46653 !important; /* Prioridad máxima para el color salmón cuando el enlace está activo */
}

/* NAV LINKS HOVER */
.nav-link:hover,
.nav-link:active {
    color: #f46653;
}

/* CONTACT isolated */
.contact {
    margin-left: 0;
    flex-shrink: 0; /* never let CONTACT itself get squeezed/wrapped */
}

/* NAV — TIGHTEN SPACING ON SMALLER SCREENS BEFORE THINGS COLLIDE */
@media (max-width: 900px) {
    .nav-links-center {
        gap: 20px;
    }
    .nav-link {
        font-size: 12px;
    }
}

/* 3. page: HOME - HERO SLIDER */

/* MAIN CONTAINER */

main {
    width: 100%;
}
.hero-slider-section {
    position: relative;
    width: 100%;
    height: 100vh;
    background-color: #191919;
    overflow: hidden;
}

/* GROUPING TRAY - SLIDER */
.slider-wrapper {
    width: 100%;
    height: 100%;
    position: relative;
}

/* INDIVIDUAL SLIDER */
.slide-item {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    transition: opacity 0.8s ease-in-out;
    z-index: 1;
}

.slide-item.active {
    opacity: 1;
    z-index: 2;
}

.slide-item img {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 100vw;
    height: 100vh; 
    object-fit: cover;
}
/* NAV DOTS */
.slider-dots {
    position: absolute;
    bottom: 80px;
    left: 50%;
    transform: translate(-50%);
    display: flex;
    gap: 15px;
    z-index: 5;
}

/* INDIVIDUAL DOT STYLING */
.dot {
    width: 8px;
    height: 8px;
    background-color: transparent;
    border: 1px solid #f46653;
    border-radius: 50%;
    cursor: pointer;
    transition: all 0.3s ease;
}

.dot.active {
    background-color: #f46653;
    transform: scale(1.2);
    opacity: 1;
}

/* SCREEN CREDITS */
.slider-credits {
    position: absolute;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 5;
}

.credits-text {
    font-size: 11px;
    color: #f46653;
    letter-spacing: 1px;
}

/* 4. PAGE: ABOUT SECTION */

.about-section {
    position: relative;
    width: 100%;
    height: 100vh;
    background-color: #dcdcdc;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 0 8%;
    overflow: hidden;
}

/* SALMON GLOW */
.about-section::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 42%;
    transform: translate(-50%, -50%);
    width: 550px;
    height: 550px;
    background: radial-gradient(circle, rgba(244, 102, 83, 0.45) 0%, rgba(244, 102, 83, 0) 70%);
    pointer-events: none;
    z-index: 1;
}

/* FLEX CONTAINER (IMAGE + TEXT) */
.about-container {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 60px;
    max-width: 1100px;
    width: 100%;
    z-index: 2;
}

/* PORTRAIT */
.about-portrait {
    flex: 1;
    display: flex;
    justify-content: flex-end;
    opacity: .75;
}

.about-portrait img {
    max-width: 420px;
    width: 100%;
    height: auto;
    display: block;
    mix-blend-mode: multiply;
}

/* TEXT */
.about-text {
    flex: 1.2;
}

.about-text p {
    color: #191919;
    font-size: 14px;
    line-height: 1.8;
    letter-spacing: 0.5px;
    max-width: 520px;
}

/* CREDITS */
.about-credits {
    position: absolute;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 5;
}

/* RESPONSIVE DESIGN FOR SMALL SCREENS */
@media (max-width: 900px) {
    .about-container {
        flex-direction: column;
        text-align: center;
        gap: 30px;
    }

    .about-portrait {
        justify-content: center;
    }

    .about-portrait img {
        max-width: 280px;
    }

    .about-text p {
        font-size: 13px;
    }
}

/* 5. HEADER ADAPTATION FOR LIGHT SECTIONS */

.site-header.light-theme .nav-link {
    color: #191919;
}

.site-header.light-theme .nav-link:hover,
.site-header.light-theme .nav-link.active {
    color: #f46653; /* Salmón en hover y activo */
}
/* ==========================================
   GALLERY and LIGHTBOX (ALHENA)
   ========================================== */

/* WHITE BG FOR GALLERY */
.gallery-body {
    background-color: #dcdcdc;
    min-height: 100vh;
    color: #191919;
}

.gallery-page-container {
    position: relative;
    overflow: hidden;
    padding: 130px 6% 40px;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    justify-content: space-between;
}

.gallery-glow {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 650px;
    height: 650px;
    background: radial-gradient(circle, rgba(244, 102, 83, 0.4) 0%, rgba(244, 102, 83, 0) 70%);
    pointer-events: none;
    z-index: 0;
}

/* RENDER GRID (6 equal columns) */
.gallery-grid {
    position: relative;
    z-index: 1;
    display: grid;
    grid-template-columns: repeat(6, 1fr);
    gap: 12px;
    margin-bottom: 50px;
}

.gallery-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    filter: grayscale(100%);
    transition: filter 0.5s ease, opacity 0.3s ease, transform 0.3s ease;
}

.gallery-item:hover img {
    filter: grayscale(0%);
    opacity: 0.85;
    transform: scale(1.02);
}

/* BARRA INFERIOR DE NAVEGACIÓN Y TÍTULO */
.gallery-footer-info {
    display: flex;
    justify-content: center;
    align-items: center;
    position: relative;
    margin-bottom: 30px;
}

.gallery-title {
    font-family: 'Cascadia Code', monospace;
    font-size: 16px;
    font-weight: 400;
    color: #191919;
    letter-spacing: 1px;
    text-transform: uppercase;
}

.next-project-link {
    position: absolute;
    right: 0;
    font-family: 'Cascadia Code', monospace;
    color: #191919;
    text-decoration: none;
    font-size: 13px;
    letter-spacing: 1px;
    transition: color 0.3s ease;
}

.next-project-link:hover {
    color: #f46653;
}

.gallery-credits {
    text-align: center;
}

.gallery-credits .credits-text {
    font-family: 'Cascadia Code', monospace;
    font-size: 13px;
    color: #f46653;
}

/* ==========================================
   LIGHTBOX MODAL (VISOR DE PANTALLA COMPLETA)
   ========================================== */

/* Se oculta por defecto hasta dar clic a una imagen */
.lightbox-modal {
    display: none; 
    position: fixed;
    inset: 0;
    background: rgba(25, 25, 25, 0.92);
    backdrop-filter: blur(5px);
    z-index: 10000;
    justify-content: space-between;
    align-items: center;
    padding: 0 40px;
}

/* Clase que activa JavaScript para mostrarlo */
.lightbox-modal.active {
    display: flex;
}

.lightbox-content {
    max-width: 80vw;
    max-height: 85vh;
    display: flex;
    justify-content: center;
    align-items: center;
}

.lightbox-content img {
    max-width: 100%;
    max-height: 85vh;
    object-fit: contain;
    box-shadow: 0 10px 30px rgba(25, 25, 25, 0.5);
}

.lightbox-arrow {
    background: none;
    border: none;
    color: #dcdcdc;
    font-size: 24px;
    cursor: pointer;
    padding: 20px;
    transition: color 0.3s ease, transform 0.2s ease;
}

.lightbox-arrow:hover {
    color: #f46653;
    transform: scale(1.2);
}

.lightbox-close {
    position: absolute;
    top: 30px;
    right: 40px;
    color: #dcdcdc;
    font-size: 32px;
    cursor: pointer;
    transition: color 0.3s ease;
}

.lightbox-close:hover {
    color: #f46653;
}

/* RESPONSIVE */
@media (max-width: 1024px) {
    .gallery-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (max-width: 600px) {
    .gallery-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* ==========================================
   PROJECTS SECTION (#projects)
   ========================================== */

.projects-section {
    position: relative;
    width: 100%;
    min-height: 100vh;
    background-color: #dcdcdc; /* Mismo fondo claro que About */
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    padding: 120px 8% 60px;
    overflow: hidden;
}

/* SALMON GLOW CENTERED */
.projects-glow {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 650px;
    height: 650px;
    background: radial-gradient(circle, rgba(244, 102, 83, 0.4) 0%, rgba(244, 102, 83, 0) 70%);
    pointer-events: none;
    z-index: 1;
}

.projects-container {
    position: relative;
    z-index: 2;
    width: 100%;
    max-width: 1250px;
}

/* GRILLA DE 4 COLUMNAS */
.projects-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 35px;
    align-items: center;
}

.project-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-decoration: none;
    cursor: pointer;
}

.project-card.coming-soon {
    cursor: default;
}

/* VERTICAL FRAME */
.project-thumb-wrapper {
    width: 100%;
    height: 480px;
    background-color: transparent;
    overflow: hidden;
}

/* Bnw RENDER -> COLOR EN HOVER */
.project-thumb-wrapper img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    filter: grayscale(100%);
    transition: filter 0.5s ease, transform 0.5s ease;
}

.active-project:hover img {
    filter: grayscale(0%);
    transform: scale(1.02);
}

/* DOTTED PLACEHOLDERS */
.project-thumb-wrapper.placeholder {
    border: 1px dashed rgba(25, 25, 25, 0.15);
}

.project-label {
    margin-top: 22px;
    font-family: 'Cascadia Code', monospace;
    font-size: 14px;
    color: #191919;
    letter-spacing: 1px;
}

.projects-credits {
    position: absolute;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 2;
}

.projects-credits .credits-text {
    font-family: 'Cascadia Code', monospace;
    font-size: 11px;
    color: #f46653;
}

/* RESPONSIVE */
@media (max-width: 1024px) {
    .projects-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    .project-thumb-wrapper {
        height: 380px;
    }
}

@media (max-width: 600px) {
    .projects-grid {
        grid-template-columns: 1fr;
    }
}

/* Ocultar/Mostrar la barra de navegación al hacer scroll */
.site-header {
    transition: transform 0.3s ease-in-out;
}

.site-header.hide {
    transform: translateY(-100%);
}

/* ==========================================
   SERVICES SECTION (#services)
   ========================================== */

.services-section {
    position: relative;
    width: 100%;
    min-height: 100vh;
    background-color: #dcdcdc;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    padding: 120px 6% 60px;
    overflow: hidden;
}

/* RESPLANDOR SALMÓN CENTRADO */
.services-glow {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 650px;
    height: 650px;
    background: radial-gradient(circle, rgba(244, 102, 83, 0.4) 0%, rgba(244, 102, 83, 0) 70%);
    pointer-events: none;
    z-index: 1;
}

.services-container {
    position: relative;
    z-index: 2;
    width: 100%;
    max-width: 1350px;
    display: flex;
    flex-direction: column;
    gap: 50px;
}

/* GRILLA DE 5 COLUMNAS PARA LAS IMÁGENES */
.services-grid {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 20px;
    align-items: center;
}

.service-card {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.service-card .service-thumb-wrapper {
    width: 100%;
    height: 360px;
    background-color: transparent;
    overflow: hidden;
}

/* EFECTO DE IMAGEN (mantiene tu estilo actual) */
.service-card .service-thumb-wrapper img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    filter: grayscale(100%);
    transition: filter 0.5s ease, transform 0.5s ease;
}

.service-card:hover .service-thumb-wrapper img {
    filter: grayscale(0%);
    transform: scale(1.02);
}

.service-label {
    margin-top: 15px;
    font-family: 'Cascadia Code', monospace;
    font-size: 13px;
    color: #191919;
    letter-spacing: 1px;
    text-align: center;
}

/* GRILLA DE PASOS / WORKFLOW (4 COLUMNAS) */
.workflow-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 30px;
}

.workflow-item h3 {
    font-family: 'Cascadia Code', monospace;
    font-size: 13px;
    color: #191919;
    letter-spacing: 1px;
    margin-bottom: 10px;
}

.workflow-item p {
    font-family: 'Cascadia Code', monospace;
    font-size: 11px;
    color: #191919;
    line-height: 1.6;
    letter-spacing: 0.5px;
    opacity: 0.85;
}

.services-credits {
    position: absolute;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 2;
}

.services-credits .credits-text {
    font-family: 'Cascadia Code', monospace;
    font-size: 11px;
    color: #f46653;
}

/* RESPONSIVE PARA SERVICES */
@media (max-width: 1200px) {
    .services-grid {
        grid-template-columns: repeat(3, 1fr);
    }
    .workflow-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .services-grid {
        grid-template-columns: 1fr;
    }
    .workflow-grid {
        grid-template-columns: 1fr;
    }
}

.service-card .service-thumb-wrapper video {
    width: 100%;
    height: 100%;
    object-fit: cover;
    filter: grayscale(100%);
    transition: filter 0.5s ease, transform 0.5s ease;
}

.service-card:hover .service-thumb-wrapper video {
    filter: grayscale(0%);
    transform: scale(1.02);
}

/* ==========================================
   CORRECCIÓN: PROPORCIÓN RECTANGULAR EXTERIOR RENDER
   ========================================== */
.service-card.service-exterior .service-thumb-wrapper {
    height: 360px; /* Asegura la misma altura coherente o ajústala a tu gusto visual */
}

/* ==========================================
   CORRECCIÓN: HOVER PARA REAPARECER EL NAV MENU OCULTO
   ========================================== */
.site-header {
    transition: transform 0.3s ease-in-out;
}

.site-header.hide {
    transform: translateY(-100%);
}

/* Al poner el cursor arriba cuando está oculto, vuelve a mostrarse */
.site-header.hide:hover {
    transform: translateY(0);
}

/* ==========================================
   CONTACT SECTION (#contact)
   ========================================== */
.contact-section {
    position: relative;
    width: 100%;
    min-height: 100vh;
    background-color: #dcdcdc;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    padding: 120px 8% 60px;
    overflow: hidden;
}

.contact-glow {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 650px;
    height: 650px;
    background: radial-gradient(circle, rgba(244, 102, 83, 0.4) 0%, rgba(244, 102, 83, 0) 70%);
    pointer-events: none;
    z-index: 1;
}

.contact-container {
    position: relative;
    z-index: 2;
    width: 100%;
    max-width: 1000px;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
}

.contact-title {
    font-family: 'Cascadia Code', monospace;
    font-size: 32px;
    color: #f46653;
    font-weight: 400;
    margin-bottom: 25px;
    letter-spacing: 1px;
}

.contact-info {
    font-family: 'Cascadia Code', monospace;
    font-size: 13px;
    color: #191919;
    line-height: 1.8;
    margin-bottom: 40px;
    letter-spacing: 0.5px;
}

.contact-form {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 25px;
    width: 100%;
}

.form-inputs-left {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.contact-form input,
.contact-form textarea {
    width: 100%;
    background: rgba(255, 255, 255, 0.4);
    border: 1px solid rgba(25, 25, 25, 0.08);
    padding: 16px 20px;
    font-family: 'Cascadia Code', monospace;
    font-size: 13px;
    color: #191919;
    border-radius: 8px;
    outline: none;
    transition: border-color 0.3s ease, background 0.3s ease;
}

.contact-form input::placeholder,
.contact-form textarea::placeholder {
    color: #191919;
    opacity: 0.6;
}

.contact-form input:focus,
.contact-form textarea:focus {
    border-color: #f46653;
    background: rgba(255, 255, 255, .1);
}

.form-message-right textarea {
    height: 100%;
    resize: none;
}

.submit-btn {
    grid-column: span 2;
    justify-self: center;
    background-color: rgba(25, 25, 25, 0.06);
    border: 1px solid rgba(25, 25, 25, 0.15);
    padding: 12px 30px;
    font-family: 'Cascadia Code', monospace;
    font-size: 12px;
    color: #191919;
    letter-spacing: 1px;
    cursor: pointer;
    border-radius: 20px;
    transition: all 0.3s ease;
    margin-top: 10px;
}

.submit-btn:hover {
    background-color: #f46653;
    color: #dcdcdc;
    border-color: #f46653;
}

.contact-credits {
    position: absolute;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 2;
}

.contact-credits .credits-text {
    font-family: 'Cascadia Code', monospace;
    font-size: 11px;
    color: #f46653;
}

/* RESPONSIVE CONTACT */
@media (max-width: 768px) {
    .contact-form {
        grid-template-columns: 1fr;
    }
    .submit-btn {
        grid-column: span 1;
    }
}

/* REMOVE DEFAULT BACKGROUND FROM AUTO FILL */
input:-webkit-autofill,
input:-webkit-autofill:hover, 
input:-webkit-autofill:focus, 
textarea:-webkit-autofill,
textarea:-webkit-autofill:hover,
textarea:-webkit-autofill:focus {
    transition: background-color 5000s ease-in-out 0s;
    -webkit-text-fill-color: #000 !important; /* Puedes cambiar #000 por el color exacto de tu texto */
}

/* Contenedor derecho para alinear contacto e idiomas en una sola línea horizontal */
.nav-right {
    display: flex;
    flex-direction: row; /* Fuerza a que vayan en fila */
    align-items: center;
    gap: 1rem; /* Espacio entre el botón CONTACT y EN | ES */
}

/* Ajuste del selector de idiomas */
.language-selector {
    font-family: 'Cascadia Code', monospace;
    font-size: 0.65rem;
    letter-spacing: 0.1px;
    opacity: 0.5;
    transition: opacity 0.3s ease;
}

.language-selector:hover {
    opacity: 1;
}

.language-selector a {
    text-decoration: none;
    color: #f46653;
}

/* ==========================================
   360 TOUR LINK CARD STYLES
   ========================================== */
.gallery-item-360 {
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    width: 100%;
    height: 100%;
    min-height: 200px;
    background-color: #dcdcdc;
    text-decoration: none;
    transition: background-color 0.3s ease;
}

.gallery-item-360 span {
    display: block;
    width: 100%;
    font-family: 'Cascadia Code', monospace;
    font-size: 12px;
    font-weight: 500;
    color: #1a1a1a;
    letter-spacing: 1.5px;
    text-align: center;
    transition: color 0.25s ease, transform 0.25s ease;
}

.gallery-item-360:hover span {
    color: #f46653;
    transform: scale(1.05);
}

/* RESPONSIVE ADJUSTMENTS FOR TABLETS AND PHONES */
@media (max-width: 1024px) {
    .gallery-item-360 {
        min-height: 150px; /* Adjusts height nicely when grid switches to 3 or 2 columns */
    }
}

/* ==========================================
   AJUSTES FINALES: REDES SOCIALES Y RECAPTCHA
   ========================================== */

/* 1. Ocultar el badge flotante de reCAPTCHA */
.grecaptcha-badge { 
    visibility: hidden !important; 
}

/* 2. Alinear los iconos de redes sociales */
.social-media-wrapper {
    display: flex;
    justify-content: center;
    gap: 20px;
    margin-top: 40px; 
}

.social-media-wrapper img {
    width: 28px;
    height: 28px;
}

/* Quita el subrayado azul de los enlaces */
.social-media-wrapper a {
    text-decoration: none;
}

/* 3. Reorganizar créditos y reCAPTCHA */

/* Subimos los créditos reescribiendo la regla original */
.contact-credits {
    bottom: 50px; 
}

/* Anclamos el aviso de reCAPTCHA de forma absoluta debajo de los créditos */
.recaptcha-notice {
    position: absolute;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    width: 90%; /* Evita que el texto toque los bordes en móviles */
    font-size: 11px;
    color: #191919;
    text-align: center;
    font-family: 'Cascadia Code', monospace;
}

.recaptcha-notice a {
    color: #999;
    text-decoration: underline;
}
