/* --- HERO (Padrão) --- */
.hero {
    height: 50vh;
    position: relative;
    display: flex;
    align-items: center;
    color: white;
    text-align: center;
}

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

.hero-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    z-index: -2;
    transform: translateZ(0);
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(to right, rgba(0, 0, 0, 0.489), rgba(0, 0, 0, 0.445));
    z-index: -1;
}

.breadcrumb {
    color: var(--accent-color);
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 2px;
    font-size: 0.9rem;
}

.intro-section .col-img {
    display: flex;
    justify-content: center;
}

.portfolio-section {
    padding-bottom: 120px;
}

.portfolio-header {
    text-align: center;
    max-width: 800px;
    margin: 0 auto 60px auto;
}

.header-divider {
    width: 60px;
    height: 3px;
    background: var(--accent-color);
    margin: 20px auto;
}

.portfolio-header p {
    font-size: 1.1rem;
    color: var(--text-muted);
}

.portfolio-cols {
    display: flex;
    gap: 20px;
    margin-top: 40px;
    width: 100%;
}

.col-group {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.products-card {
    position: relative;
    border-radius: 6px;
    overflow: hidden;
    display: block;
    width: 100%;
    border: 1px solid var(--border-color);
    transition: transform .4s ease, box-shadow .4s ease;
}

.h-tall { height: 400px; }
.h-short { height: 240px; }

.card-bg {
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
    transition: transform 0.6s ease;
    will-change: transform;
}

.card-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(
        to top,
        rgba(13,27,42, 0.92) 0%,
        rgba(13,27,42, 0.45) 50%,
        transparent 95%
    );
    opacity: 0.9;
    transition: opacity 0.3s;
}

.card-details {
    position: absolute;
    bottom: 0;
    left: 0;
    padding: 25px;
    width: 100%;
    z-index: 2;
}

.card-details h3 {
    color: white;
    font-size: 1.5rem;
    margin-bottom: 5px;
    font-weight: 700;
}

.card-details p {
    color: rgba(255,255,255,0.85);
    font-size: 0.85rem;
    margin-top: 5px;
    opacity: 0.9;
}

/* Hovers */
.products-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 40px rgba(0,0,0,0.25);
}

.products-card:hover .card-bg { transform: scale(1.08); }
.products-card:hover .card-overlay { opacity: 0.7; }

/* Container principal do carrossel */
/* Container principal do carrossel */
.carousel-wrapper {
    position: relative;
    width: 100%;
    margin: 0 auto;
}

/* Esconde o que sai da tela e posiciona a trilha (O overflow fica só aqui agora) */
.carousel-track-container {
    overflow: hidden; 
    width: 100%;
}

/* Restante do CSS da trilha e slides... */
.carousel-track {
    display: flex;
    padding: 0;
    margin: 0;
    list-style: none;
    transition: transform 0.5s ease-in-out;
}

.carousel-slide {
    min-width: 100%;
    box-sizing: border-box;
}

/* Botões de navegação */
.carousel-button {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(0, 0, 0, 0);
    color: white;
    border: none;
    font-size: 24px;
    /* Ajuste de padding para deixar o botão bem redondo com o ícone */
    width: 45px;
    height: 45px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    z-index: 10;
    border-radius: 50%;
    transition: background 0.3s;
}

.carousel-button:hover {
    background: rgba(0, 0, 0, 0.8);
}

/* Jogando os botões para fora do container */
.carousel-button--left {
    left: 200px; /* Aumente ou diminua esse valor para afastar mais ou menos */
}

.carousel-button--right {
    right: 200px; /* Aumente ou diminua esse valor para afastar mais ou menos */
}

/* Indicadores (bolinhas) - Mantido igual */
.carousel-nav {
    display: flex;
    justify-content: center;
    padding: 20px 0;
    gap: 10px;
    margin-top: 15px;
}

.carousel-indicator {
    border: none;
    border-radius: 50%;
    width: 12px;
    height: 12px;
    background: var(--black);
    cursor: pointer;
    transition: background 0.3s;
}

.carousel-indicator.current-indicator {
    background: var(--accent-color);
}


/* Container que organiza a tela */
.catalogo-app-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 30px;
    padding: 40px 20px;
    width: 100%;
}

.catalogo-wrapper {
    position: relative;
    width: 100%;
    max-width: 1100px; /* Mantém o seu tamanho original grande */
    
    /* Substitua o 750 pela ALTURA (height) que está no seu JavaScript */
    aspect-ratio: 1100 / 750; 
    
    display: flex;
    justify-content: center;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.4);
    background-color: #fff; 
}

/* Estilo da folha */
.pagina {
    background-color: #ffffff;
    overflow: hidden;
    box-shadow: inset 5px 0 15px rgba(0,0,0,0.04);
}

/* A imagem dentro da folha (Cursor de clique ativado) */
.pagina img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    cursor: pointer; /* Mostra a mãozinha de botão */
}

/* --- Botões de Navegação --- */
.controles {
    display: flex;
    gap: 20px;
    z-index: 10;
}

.btn-navegacao {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 24px;
    background-color: var(--accent-color);
    color: var(text-dark);
    border: 1px solid var(--border-color);
    border-radius: 50px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
}

.btn-navegacao:hover {
    background-color: var(--accent-hover);
    transform: translateY(-2px);
}

/* --- TELA ESCURA DO MODAL (LIGHTBOX) --- */
.modal-imagem {
    display: none; 
    position: fixed;
    z-index: 9999; 
    left: 0;
    top: 0;
    width: 100vw;
    height: 100vh;
    background-color: rgba(0, 0, 0, 0.9);
    
    /* Centralizado por padrão */
    align-items: center;
    justify-content: center;
    overflow: auto; 
}

/* O SEGREDO DA NAVEGAÇÃO: Quando tem zoom, alinha ao topo para liberar a rolagem */
.modal-imagem.scroll-ativo {
    align-items: flex-start;
    justify-content: flex-start;
    padding: 20px; /* Dá uma pequena margem para a foto não colar na borda da tela */
}

/* A foto ajustada na tela */
.modal-conteudo {
    max-width: 90vw;
    max-height: 90vh;
    width: auto;
    height: auto;
    object-fit: contain; 
    box-shadow: 0 0 20px rgba(0,0,0,0.5);
    border-radius: 4px;
    cursor: zoom-in;
    transition: width 0.2s ease; /* Transição suave apenas na largura */
}

/* O ZOOM REAL (Igual nova guia) */
.modal-conteudo.zoomed {
    max-width: none;
    max-height: none;
    
    /* Força a imagem a ficar bem maior que a tela para garantir a rolagem */
    width: 150vw; 
    
    cursor: zoom-out;
}

/* Botão de Fechar */
.fechar-modal {
    position: fixed; /* Fica fixo na tela mesmo rolando a imagem */
    top: 20px;
    right: 35px;
    color: #f1f1f1;
    font-size: 40px;
    font-weight: bold;
    cursor: pointer;
    z-index: 10000; 
}

.fechar-modal:hover {
    color: var(--accent-color);
}

@media (max-width: 1150px) {
    .catalogo-wrapper {
        max-width: 550px; /* Cai exatamente para a metade (largura de 1 página) */
        
        /* Substitua o 750 pela ALTURA (height) do seu JavaScript */
        aspect-ratio: 550 / 750; 
    }

    /* Ajusta os botões para telas menores */
    .controles {
        width: 100%;
        justify-content: center;
        gap: 10px;
    }

    .btn-navegacao {
        padding: 10px 20px;
        font-size: 14px;
    }
}

@media (max-width: 768px) {
    .portfolio-section {
    padding-bottom: 50px;
    
}

    .carousel-wrapper {
        display: flex;
        flex-direction: column;
        align-items: center;
    }
    .carousel-track-container{
        width: 90%;
    }

    .carousel-button--left {
    left: 10px; /* Aumente ou diminua esse valor para afastar mais ou menos */
}

.carousel-button--right {
    right: 10px; /* Aumente ou diminua esse valor para afastar mais ou menos */
}
}

@media (max-width: 900px) {
    .h-tall { height: 320px; }
    .h-short { height: 200px; }
}

@media (max-width: 600px) {
    .portfolio-cols {
        flex-direction: column;
    }

    .h-tall, .h-short {
        height: 250px;
    }
}