/* ========== RESET ========== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Poppins', sans-serif;
    background-color: #030303; 
    color: #fff;
    overflow-x: hidden;
}

h1, h2, h3, h4 {
    font-family: 'Bebas Neue', cursive;
    letter-spacing: 2px;
}

/* ========== HEADER ========== */
.site-header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
    background: transparent; 
    backdrop-filter: none;
    padding: 40px 5%; 
    display: flex;
    justify-content: flex-end; 
    align-items: center;
    transition: all 0.5s ease;
}

.main-nav {
    display: flex;
    gap: 50px; 
    list-style: none;
    margin: 0;
    padding: 0;
}

.main-nav a {
    color: #fff;
    text-decoration: none;
    font-family: 'Bebas Neue', cursive; 
    font-weight: 400; 
    font-size: 1.6rem; 
    letter-spacing: 2px;
    text-transform: uppercase;
    position: relative;
    padding-bottom: 5px;
    text-shadow: 0 4px 15px rgba(0,0,0,0.8); 
    transition: color 0.4s ease;
}

.main-nav a::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0%;
    height: 2px;
    background: #e63946;
    transition: width 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.main-nav a:hover {
    color: #e63946;
}

.main-nav a:hover::after {
    width: 100%;
}

.mobile-toggle {
    display: none;
    font-size: 28px;
    cursor: pointer;
    text-shadow: 0 4px 15px rgba(0,0,0,0.8);
}

/* ========== HERO COM VÍDEO E FADE BACKGROUND ========== */
.hero {
    position: relative;
    height: 100vh;
    width: 100%;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
}

.video-background {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 0;
    overflow: hidden;
    opacity: 0; 
    animation: fadeInVideo 3s ease 0.5s forwards; 
}

@keyframes fadeInVideo {
    0% { opacity: 0; }
    100% { opacity: 1; }
}

.video-background iframe {
    position: absolute;
    top: 50%;
    left: 50%;
    width: 100vw; 
    height: calc(100vw * 0.5625); 
    min-height: 100vh; 
    min-width: calc(100vh * 1.77777778); 
    transform: translate(-50%, -50%);
    pointer-events: none;
    border: none;
}

.vignette-left-right {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1; 
    pointer-events: none;
    background: 
        linear-gradient(to top, #030303 0%, rgba(3,3,3,0) 25%),
        radial-gradient(circle, rgba(3,3,3,0) 0%, rgba(3,3,3,0.5) 30%, rgba(3,3,3,0.9) 60%, rgba(3,3,3,1) 85%, #030303 100%);
}

.hero-content {
    position: relative;
    z-index: 2;
    padding: 0 20px;
    display: flex;
    flex-direction: column;
    align-items: center; 
    justify-content: center;
    width: 100%;
}

.hero-content h1 {
    font-family: 'Bebas Neue', cursive;
    font-size: 8.5rem; 
    margin-bottom: -10px; 
    letter-spacing: 12px; 
    margin-right: -12px; 
    color: #fff;
    text-shadow: 0 10px 40px rgba(0,0,0,0.8);
    opacity: 0; 
    animation: revealHeroName 1.5s cubic-bezier(0.16, 1, 0.3, 1) 0.3s forwards;
    line-height: 1;
    text-align: center;
    width: 100%; 
    display: block; 
}

@keyframes revealHeroName {
    0% { opacity: 0; transform: translateY(40px) scale(0.95); filter: blur(10px); }
    100% { opacity: 1; transform: translateY(0) scale(1); filter: blur(0); }
}

.hero-content p {
    font-size: 1.5rem; 
    font-weight: 300;
    margin-bottom: 40px;
    margin-top: 0;
    color: #ddd;
    letter-spacing: 5px;
    text-transform: uppercase;
    text-shadow: 0 4px 15px rgba(0,0,0,0.8);
    text-align: center;
    width: 100%;
    transform: translateX(2.5px);
}

/* ========== BOTÕES ========== */
.btn-group {
    display: flex;
    gap: 20px; 
    justify-content: center;
    align-items: center;
    flex-wrap: wrap;
    width: 100%;
}

.btn {
    padding: 14px 40px;
    border-radius: 50px;
    text-decoration: none;
    font-weight: 600;
    transition: all 0.5s cubic-bezier(0.16, 1, 0.3, 1);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    font-size: 0.95rem;
    letter-spacing: 1.5px;
}

.btn-primary {
    background: #e63946;
    color: #fff;
}

.btn-primary:hover {
    background: #fff;
    color: #e63946;
    transform: translateY(-3px);
    box-shadow: 0 10px 30px rgba(230,57,70,0.3);
}

.btn-secondary {
    border: 1px solid #e63946;
    color: #fff;
    background: rgba(0,0,0,0.3); 
    backdrop-filter: blur(5px);
}

.btn-secondary:hover {
    background: #e63946;
    color: #fff;
    transform: translateY(-3px);
}

/* ========== FILTROS FLUTUANTES NO HERO ========== */
.hero-filters {
    position: absolute;
    bottom: 50px; 
    left: 0;
    width: 100%;
    display: flex;
    justify-content: center;
    gap: 30px;
    flex-wrap: wrap;
    z-index: 3;
}

.filter-btn {
    background: transparent;
    border: none;
    padding: 5px 0;
    color: rgba(255, 255, 255, 0.5); 
    cursor: pointer;
    transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
    font-weight: 500;
    font-size: 0.9rem;
    letter-spacing: 2px;
    position: relative;
    text-shadow: 0 2px 10px rgba(0,0,0,0.8); 
}

.filter-btn::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 0%;
    height: 2px;
    background: #e63946;
    transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.filter-btn.active,
.filter-btn:hover {
    color: #fff;
}

.filter-btn.active::after,
.filter-btn:hover::after {
    width: 100%;
}

/* ========== TRABALHOS (GALERIA ACORDEÃO) ========== */
.trabalhos {
    position: relative;
    padding: 40px 0 80px 0; 
    background: #030303;
    min-height: 500px;
    width: 100%;
}

.trabalhos-grid {
    position: relative;
    display: flex;
    flex-direction: row;
    height: 72vh; 
    min-height: 480px;
    max-height: 720px;
    width: 100%;
    margin: 0;
    gap: 2px; 
    background: #030303;
    overflow: hidden;
}

.filter-animate {
    opacity: 0;
    animation: ultraSmoothFade 1.2s cubic-bezier(0.25, 1, 0.5, 1) forwards;
}

@keyframes ultraSmoothFade {
    0% { opacity: 0; transform: translateY(10px); }
    100% { opacity: 1; transform: translateY(0); }
}

.aristide-item {
    position: relative;
    cursor: pointer;
    flex: 1;
    min-width: 45px; 
    overflow: hidden;
    transition: flex 0.7s cubic-bezier(0.25, 1, 0.3, 1);
    background: #111;
}

.aristide-img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
    filter: grayscale(100%) brightness(35%); 
    transition: filter 0.7s cubic-bezier(0.25, 1, 0.3, 1), transform 0.7s cubic-bezier(0.25, 1, 0.3, 1);
}

.aristide-item:hover {
    flex: 9; 
}

.aristide-item:hover .aristide-img {
    filter: grayscale(0%) brightness(100%); 
    transform: scale(1.04); 
}

.aristide-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 60%;
    background: linear-gradient(to top, rgba(0,0,0,0.95), transparent);
    z-index: 1;
    opacity: 0;
    transition: opacity 0.7s ease;
}

.aristide-item:hover .aristide-overlay {
    opacity: 1;
}

/* ========== TEXTO CENTRALIZADO COM REVEAL DE BAIXO PARA CIMA ========== */
.aristide-info {
    position: absolute;
    bottom: 35px;
    left: 15px;
    right: 15px;
    z-index: 2;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    gap: 4px;
    pointer-events: none;
}

.aristide-cat {
    color: #e63946;
    font-size: 0.8rem;
    font-weight: 700;
    letter-spacing: 4px;
    text-transform: uppercase;
    text-shadow: 0 2px 6px rgba(0,0,0,0.8);
    opacity: 0;
    transform: translateY(18px);
    transition: opacity 0.5s cubic-bezier(0.16, 1, 0.3, 1), 
                transform 0.5s cubic-bezier(0.16, 1, 0.3, 1);
}

.aristide-item:hover .aristide-cat {
    opacity: 1;
    transform: translateY(0);
    transition-delay: 0.05s;
}

.aristide-title {
    color: #fff;
    font-size: 2.3rem;
    font-weight: 400; 
    letter-spacing: 2px;
    line-height: 1.1;
    text-shadow: 0 4px 15px rgba(0,0,0,0.8);
    white-space: nowrap; 
    overflow: hidden;
    text-overflow: ellipsis;
    text-transform: uppercase;
    display: flex;
    justify-content: center;
    align-items: center;
    max-width: 100%;
}

/* CARACTERE INDIVIDUAL: SURGINDO DE BAIXO PARA CIMA */
.aristide-char {
    display: inline-block;
    opacity: 0;
    transform: translateY(120%) scale(0.9);
    filter: blur(4px);
    transition: opacity 0.5s cubic-bezier(0.16, 1, 0.3, 1),
                transform 0.6s cubic-bezier(0.16, 1, 0.3, 1),
                filter 0.5s ease;
    will-change: transform, opacity, filter;
}

.aristide-item:hover .aristide-char {
    opacity: 1;
    transform: translateY(0) scale(1);
    filter: blur(0);
}

.aristide-play-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 3;
    opacity: 0;
    transition: opacity 0.5s ease;
}

.play-text {
    background: rgba(230, 57, 70, 0.95);
    color: #fff;
    font-family: 'Poppins', sans-serif;
    font-size: 0.85rem;
    font-weight: 700;
    letter-spacing: 2px;
    padding: 14px 36px;
    border-radius: 50px;
    transform: scale(0.8) translateY(15px);
    transition: all 0.5s cubic-bezier(0.16, 1, 0.3, 1);
    box-shadow: 0 10px 30px rgba(230, 57, 70, 0.4);
}

.aristide-item:hover .aristide-play-overlay {
    opacity: 1;
}

.aristide-item:hover .play-text {
    transform: scale(1) translateY(0);
}

/* ========== MODAL COM ANIMAÇÃO DE FADE SUAVE ========== */
.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 2000;
    justify-content: center;
    align-items: flex-start;
    padding: 40px 20px;
    overflow-y: auto !important;
    -webkit-overflow-scrolling: touch;
    
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.6s cubic-bezier(0.16, 1, 0.3, 1);
}

.modal::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: rgba(0, 0, 0, 0);
    backdrop-filter: blur(0px);
    -webkit-backdrop-filter: blur(0px);
    z-index: -1;
    transition: background 0.6s cubic-bezier(0.16, 1, 0.3, 1), 
                backdrop-filter 0.6s cubic-bezier(0.16, 1, 0.3, 1);
    pointer-events: none;
}

.modal.show {
    opacity: 1;
    pointer-events: auto;
}

.modal.show::before {
    background: rgba(0, 0, 0, 0.45); 
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
}

.modal-container {
    position: relative;
    width: 96vw;
    max-width: 1400px;
    min-height: auto;
    height: auto;
    margin: auto; 
    background: transparent;
    border: none;
    box-shadow: none;
    
    opacity: 0;
    transform: scale(0.97) translateY(25px);
    transition: opacity 0.6s cubic-bezier(0.16, 1, 0.3, 1), 
                transform 0.6s cubic-bezier(0.16, 1, 0.3, 1);
    will-change: opacity, transform;
}

.modal.show .modal-container {
    opacity: 1;
    transform: scale(1) translateY(0);
}

.modal-container.instagram-modal {
    max-width: 850px;
}

.modal-main-content {
    position: relative;
    width: 100%;
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
}

.modal-video {
    width: calc(100% - 340px);
    aspect-ratio: 16 / 9;
    max-height: none;
    height: auto;
    background: #000;
    position: relative;
    border-radius: 12px;
    border: 1px solid rgba(255,255,255,0.05); 
    overflow: hidden;
    box-shadow: 0 20px 60px rgba(0,0,0,0.8);
}

.modal-video iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100% !important;
    height: 100% !important;
    border: none;
}

.modal-video.instagram-layout {
    width: 100%;
    max-width: 450px; 
    height: 75vh; 
    min-height: 550px;
    aspect-ratio: auto;
    margin: 0; 
    background: transparent;
    border: none;
    box-shadow: none;
}

/* FICHA TÉCNICA (520PX) */
.modal-info {
    width: 320px;
    height: 520px;
    max-height: 100%;
    background: rgba(10, 10, 10, 0.85);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    padding: 22px;
    display: flex;
    flex-direction: column;
    gap: 12px;
    border-radius: 12px;
    border: 1px solid rgba(255, 255, 255, 0.08);
    box-shadow: 0 20px 60px rgba(0,0,0,0.8);
    overflow: hidden;
}

.reveal-wrap {
    overflow: hidden;
    display: block;
    padding-bottom: 2px; 
}

.reveal-text {
    display: block;
    transform: translateY(110%);
    transition: transform 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}

.modal.show .reveal-text {
    transform: translateY(0);
}

.modal-info-header h2 {
    font-family: 'Bebas Neue', cursive;
    font-size: 1.8rem;
    color: #fff;
    margin-bottom: 2px;
    font-weight: 400;
    letter-spacing: 1.5px;
    line-height: 1.1;
    text-transform: uppercase;
    text-shadow: 0 4px 10px rgba(0,0,0,0.5);
}

.modal-info-header .cat {
    color: #e63946;
    font-size: 0.7rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 2px;
}

.modal-client-year {
    display: flex;
    flex-direction: column;
    gap: 4px;
    padding: 8px 0;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.modal-client-year .client,
.modal-client-year .year {
    font-size: 0.8rem;
    color: #aaa;
}

.modal-client-year .client strong,
.modal-client-year .year strong {
    color: #fff;
}

.modal-info-scroll {
    flex: 1;
    overflow-y: auto !important; 
    padding-right: 8px;
    scrollbar-width: thin;
    scrollbar-color: #e63946 rgba(255,255,255,0.05);
}

.modal-info-scroll::-webkit-scrollbar {
    width: 4px;
}

.modal-info-scroll::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.05);
    border-radius: 10px;
}

.modal-info-scroll::-webkit-scrollbar-thumb {
    background: #e63946;
    border-radius: 10px;
}

.modal-info-scroll p {
    color: #bbb;
    font-size: 0.8rem;
    line-height: 1.5;
}

.close-modal {
    position: fixed; 
    top: 25px;
    right: 30px;
    font-size: 30px;
    color: #fff;
    cursor: pointer;
    z-index: 99999; 
    background: rgba(0, 0, 0, 0.8);
    border: 2px solid rgba(255,255,255,0.1);
    width: 50px;
    height: 50px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.close-modal:hover {
    background: #e63946;
    border-color: #e63946;
    color: #fff;
    transform: scale(1.1) rotate(90deg); 
}

/* ========== GALERIA DE FRAMES EM LARGURA TOTAL ========== */
.modal-frames-section {
    width: 100vw !important;
    position: relative;
    left: 50%;
    right: 50%;
    margin-left: -50vw !important;
    margin-right: -50vw !important;
    margin-top: 40px;
    padding: 0;
    z-index: 1;
}

.frames-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 4px;
    width: 100%;
}

.frame-item {
    position: relative;
    overflow: hidden;
    aspect-ratio: 16 / 9;
    cursor: pointer;
    background: #000;
    will-change: transform;
    transform: translateZ(0);
    backface-visibility: hidden;
}

.frame-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    filter: brightness(85%);
    transition: all 0.5s cubic-bezier(0.16, 1, 0.3, 1);
    content-visibility: auto;
    image-rendering: -webkit-optimize-contrast;
}

.frame-item:hover img {
    filter: brightness(110%);
    transform: scale(1.03);
}

/* ========== LIGHTBOX ========== */
.frames-lightbox {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    z-index: 10000;
    background: rgba(0, 0, 0, 0.95);
    backdrop-filter: blur(12px);
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.frames-lightbox.show {
    opacity: 1;
}

.lightbox-img-wrapper {
    position: relative;
    max-width: 90vw;
    max-height: 90vh;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.lightbox-img-wrapper img {
    max-width: 100%;
    max-height: 85vh;
    object-fit: contain;
    border-radius: 4px;
    box-shadow: 0 20px 60px rgba(0,0,0,0.9);
}

.lightbox-counter {
    margin-top: 15px;
    color: #aaa;
    font-size: 0.85rem;
    letter-spacing: 2px;
}

.lightbox-close {
    position: absolute;
    top: 25px;
    right: 30px;
    font-size: 35px;
    color: #fff;
    cursor: pointer;
    transition: all 0.3s ease;
    z-index: 10001;
}

.lightbox-close:hover {
    color: #e63946;
    transform: scale(1.1) rotate(90deg);
}

.lightbox-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.15);
    color: #fff;
    width: 55px;
    height: 55px;
    border-radius: 50%;
    font-size: 1.2rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    z-index: 10001;
}

.lightbox-btn:hover {
    background: #e63946;
    border-color: #e63946;
    transform: translateY(-50%) scale(1.1);
}

.prev-btn { left: 30px; }
.next-btn { right: 30px; }

/* ========== FOOTER ========== */
.footer {
    background: #030303;
    text-align: center;
    padding: 60px 5%;
    border-top: 1px solid #111;
}

.social-links a {
    color: #666;
    margin: 0 15px;
    transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
    display: inline-block;
}

.social-links a:hover {
    color: #fff;
    transform: translateY(-5px); 
}

.footer p {
    margin-top: 25px;
    font-size: 0.8rem;
    color: #444;
}

/* ========== RESPONSIVO (MOBILE E TABLET) ========== */
@media (max-width: 1024px) {
    .trabalhos-grid {
        height: auto;
        flex-direction: column;
        gap: 8px;
    }
    .aristide-item {
        width: 100%;
        height: 240px;
        flex: none;
    }
    .aristide-item:hover {
        flex: none;
        height: 280px;
    }
    .modal-main-content {
        flex-direction: column;
    }
    .modal-video {
        width: 100%;
    }
    .modal-info {
        width: 100%;
        height: 280px;
        margin-top: 20px;
    }
    .frames-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .aristide-title {
        font-size: 1.6rem;
    }
    .frames-grid {
        grid-template-columns: repeat(1, 1fr);
    }
}