/* --- 1. RESET & BASE --- */
* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    /* Define a tipografia Univers como base para todo o site */
    font-family: "Univers LT Std", Univers, "Helvetica Neue", Helvetica, Arial, sans-serif;
    background-color: #ffffff;
    color: #000;
    overflow-y: auto;
}

/* --- 2. NAVIGATION (AJUSTADA) --- */
nav {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    padding: 40px 70px; /* Alinhamento lateral consistente */
    display: flex;
    justify-content: space-between; 
    align-items: center;
    background: rgba(255, 255, 255, 0.95);
    z-index: 1000;
}

.nav-links {
    display: flex;
    gap: 30px;
}

nav a {
    text-decoration: none;
    color: #000;
    font-size: 13px;
    letter-spacing: 0.02em;
    opacity: 0.4;
    transition: opacity 0.3s ease;
    font-family: "Univers LT Std", Univers, sans-serif;
}

nav a:hover, nav a.active {
    opacity: 1;
}

.nav-logo {
    text-decoration: none;
    color: #000;
    font-size: 13px;
    font-weight: 500;
    opacity: 1 !important;
    white-space: nowrap;
}

/* --- 3. MODULAR MASONRY GRID (Work Page) --- */
.gallery-container {
    padding: 140px 70px 60px 70px;
    max-width: 1800px;
    width: 100%;
}

.modular-grid {
    column-count: 3; /* Grid de 3 colunas para desktop */
    column-gap: 20px;
    width: 100%;
}

.grid-item {
    display: inline-block;
    width: 100%;
    height: auto; 
    margin-bottom: 20px;
    break-inside: avoid;
    cursor: zoom-in;
    transition: opacity 0.3s ease;
    vertical-align: top;
}

.grid-item:hover {
    opacity: 0.9;
}

/* --- 4. LIGHTBOX (VISUALIZER) --- */
#visualizer {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(255, 255, 255, 0.98);
    z-index: 3000;
    cursor: zoom-out;
    justify-content: center;
    align-items: center;
}

.visualizer-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    max-width: 90%;
    max-height: 90%;
}

#visualizer img {
    max-width: 100%;
    max-height: 80vh;
    object-fit: contain;
}

#visualizer-caption {
    margin-top: 20px;
    font-size: 13px;
    color: #000;
    text-align: center;
}

/* --- WORK PAGE: LIST VIEW FIX --- */
.index-wrapper {
    padding: 140px 70px 60px 70px; /* Mantém o alinhamento com a nav */
}

.list-container {
    border-top: 1px solid #000; /* Linha superior principal */
}

.list-item {
    border-bottom: 1px solid #000; /* Linha entre projetos */
    padding: 0; /* Remove padding interno que causava o erro */
    margin: 0;
}

.list-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    /* Ajuste este valor para controlar a distância exata entre o texto e a linha */
    padding: 20px 0; 
    font-size: 13px;
    text-transform: uppercase;
    letter-spacing: 0.02em;
}

.project-name { width: 20%; font-weight: 600; }
.project-desc { width: 60%; text-transform: none; opacity: 0.8; }
.project-year { width: 20%; text-align: right; opacity: 0.5; }

/* Galeria de imagens */
.list-gallery {
    padding-bottom: 40px; /* Espaço após as imagens antes da próxima linha */
}

.gallery-inner {
    display: flex;
    gap: 15px;
    overflow-x: auto;
    scrollbar-width: none;
}

.gallery-inner::-webkit-scrollbar { display: none; }

.gallery-inner img {
    height: 400px; /* Altura consistente conforme o exemplo */
    width: auto;
    display: block;
}

/* --- 6. INFORMATION PAGE (About) --- */
.info-wrapper {
    padding: 120px 70px 50px 70px; 
    max-width: 1200px;
    display: flex;
    flex-direction: column;
    gap: 30px;
}

.bio p {
    font-size: 13px;
    line-height: 1.6;
    max-width: 600px;
    color: #000;
}

.about-image {
    width: 35%;
    max-width: 800px;
    height: auto;
    margin-bottom: 10px;
    display: block;
}

.about-links {
    display: flex;
    flex-direction: column;
    gap: 5px;
    margin-bottom: 20px;
}

.about-links a {
    text-decoration: none;
    color: #000000;
    font-size: 15px; /* Tamanho de header pequeno */
    font-weight: 600;
    font-family: "Univers LT Std", Univers, sans-serif;
    transition: opacity 0.3s ease;
}

.about-links a:hover {
    opacity: 0.5;
}

/* --- TRANSITION & LIST VIEW --- */
.page-fade {
    animation: fadeInPage 0.8s ease forwards;
}

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

.index-wrapper {
    padding: 140px 70px 60px 70px;
}

.list-container {
    border-top: 1px solid #000; /* Linha superior do exemplo */
}

.list-item {
    border-bottom: 1px solid #000000; /* Linha sutil entre projetos */
    padding-bottom: 40px;
    margin-bottom: 20px;
}

.list-header {
    display: flex;
    justify-content: space-between; /* Alinhamento Nome | Descrição | Ano */
    align-items: baseline;
    padding: 15px 0;
    font-size: 13px;
    letter-spacing: 0.02em;
}

.project-name {
    width: 20%;
    font-weight: 500;
    text-transform: uppercase;
}

.project-desc {
    width: 60%;
    text-align: left;
    opacity: 0.8;
}

.project-year {
    width: 10%;
    text-align: right;
    opacity: 0.5;
}

/* --- VISUALIZAÇÃO DE TRABALHOS (GALERIA) --- */
.list-gallery {
    margin-top: 10px;
    width: 100%;
}

.gallery-inner {
    display: flex;
    gap: 15px;
    overflow-x: auto;
    scrollbar-width: none; /* Esconde scroll no Firefox */
}

.gallery-inner::-webkit-scrollbar {
    display: none; /* Esconde scroll no Chrome/Safari */
}

.gallery-inner img {
    height: 400px; /* Altura fixa para manter o alinhamento */
    width: auto;
    object-fit: cover;
    background: #f0f0f0;
}

/* --- MOBILE --- */
@media (max-width: 768px) {
    .list-header {
        flex-direction: column;
        gap: 5px;
    }
    .project-name, .project-desc, .project-year {
        width: 100%;
        text-align: left;
    }
    .gallery-inner img {
        height: 250px;
    }
}

/* --- 7. MEDIA QUERIES (Mobile) --- */
@media (max-width: 1024px) {
    .modular-grid { column-count: 2; }
}

@media (max-width: 768px) {
    nav { padding: 20px; }
    .nav-links { gap: 15px; }
    
    .gallery-container, .index-wrapper, .info-wrapper { 
        padding: 100px 20px; 
    }
    
    .modular-grid { column-count: 1; }

    .list-header { 
        flex-direction: column; 
        gap: 5px; 
    }
    
    .project-name, .project-desc, .project-year { 
        width: 100%; 
        text-align: left; 
    }

    .gallery-inner img { height: 250px; }
    .about-image { width: 100%; }
}