/* VARIÁVEIS GLOBAIS E ESTILOS GERAIS */

:root {
    --bg-color: #13202d;
    --primary-green: #4d5b69;
    --text-light: #FFFFFF;
    --text-dark: #ffffff;
    --card-bg: #1A1A1A;
    --border-color: #101824;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html,
body {
    scroll-behavior: smooth;
}

body {
    font-family: 'Poppins', sans-serif;
    background-color: var(--bg-color);
    color: var(--text-light);
    overflow-x: hidden;
}

.container {
    max-width: 1100px;
    margin: 0 auto;
    padding: 0 20px;
}

section {
    padding: 80px 0;
    text-align: center;
}

h1,
h2,
h3,
h4 {
    font-family: 'Montserrat', sans-serif;
    font-weight: 700;
}

h2 {
    font-size: 36px;
    margin-bottom: 20px;
    color: var(--primary-green);
}

p {
    color: var(--text-dark);
    line-height: 1.7;
    max-width: 700px;
    margin: 0 auto 20px auto;
}

.btn {
    display: inline-block;
    padding: 12px 28px;
    border-radius: 5px;
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s ease;
}

.btn-primary {
    background-color: var(--primary-green);
    color: var(--bg-color);
}

.btn-primary:hover {
    background-color: #fff;
    transform: translateY(-3px);
}

.btn-secondary {
    background-color: transparent;
    color: var(--text-light);
    border: 2px solid var(--border-color);
}

.btn-secondary:hover {
    background-color: var(--primary-green);
    color: var(--bg-color);
    border-color: var(--primary-green);
    transform: translateY(-3px);
}

.fade-in {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.6s ease-out, transform 0.6s ease-out;
}

.fade-in.visible {
    opacity: 1;
    transform: translateY(0);
}


/* ESTILOS DAS SEÇÕES (ORDEM DE APARIÇÃO) */

/* HERO SECTION (TOPO) */
.hero {
    min-height: 90vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 20px;
}

.hero .logo {
    max-width: 450px;
    height: auto;
    margin-bottom: 30px;
}

.hero h1 {
    font-size: 42px;
    max-width: 800px;
    margin-bottom: 20px;
}

.hero p {
    margin-bottom: 30px;
}

.hero-buttons {
    display: flex;
    gap: 15px;
    justify-content: center;
}

/* SEÇÃO PROPÓSITO */
.philosophy-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
    margin-top: 50px;
    text-align: center;
}

.philosophy-item i {
    font-size: 40px;
    color: var(--primary-green);
    margin-bottom: 20px;
}

.philosophy-item h3 {
    margin-bottom: 10px;
    color: var(--text-light);
}

/* SEÇÃO ESTRUTURA (CARROSSEL) */
.swiper-container {
    width: 100%;
    max-width: 600px;
    height: 790px;
    margin: 40px auto 0 auto;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.4);
}

.swiper-slide {
    background-color: #000;
    text-align: center;
    display: flex;
    justify-content: center;
    align-items: center;
}

.swiper-slide img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.swiper-button-next,
.swiper-button-prev {
    color: var(--primary-green) !important;
    background-color: rgba(0, 0, 0, 0.4);
    width: 44px !important;
    height: 44px !important;
    border-radius: 50%;
    transition: background-color 0.3s ease;
    top: 65% !important;
    transform: translateY(-50%);
}

.swiper-button-next:hover,
.swiper-button-prev:hover {
    background-color: rgba(0, 0, 0, 0.7);
}

.swiper-button-next::after,
.swiper-button-prev::after {
    font-size: 18px !important;
    font-weight: 900;
}

.swiper-pagination-bullet {
    background-color: rgba(255, 255, 255, 0.5) !important;
    opacity: 1;
}

.swiper-pagination-bullet-active {
    background-color: var(--primary-green) !important;
}

/* SEÇÃO HORÁRIOS DE FUNCIONAMENTO */
.operating-hours {
    padding: 60px 0;
    background-color: var(--card-bg);
}

.hours-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
    margin-top: 40px;
}

.hour-item {
    text-align: center;
    padding: 20px;
}

.hour-item i {
    font-size: 36px;
    color: var(--primary-green);
    margin-bottom: 20px;
}

.hour-item h3 {
    font-size: 20px;
    color: var(--text-light);
    margin-bottom: 10px;
}

.hour-item p {
    font-size: 18px;
    font-weight: 600;
    color: var(--text-dark);
    margin: 0;
}

/* SEÇÃO MODALIDADES (IMAGEM ÚNICA) */
.modalidade-imagem-container {
    max-width: 900px;
    width: 100%;
    margin: 40px auto 0 auto;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.4);
}

.modalidade-imagem-container img {
    width: 100%;
    display: block;
}

/* SEÇÃO TREINADORES */
.trainers-images video {
    width: 100%;
    /* Define a proporção exata do vídeo (900x1080) */
    aspect-ratio: 900 / 1080;
    object-fit: cover;
    border-radius: 8px;
}

/* SEÇÃO LOCALIZAÇÃO */
.location-grid {
    display: grid;
    grid-template-columns: 1fr;
    /* Apenas uma coluna para dar destaque à imagem */
    gap: 40px;
    /* Espaço entre a imagem e o texto abaixo */
    justify-items: center;
    /* Centraliza os itens na grelha */
    text-align: center;
}

.location-grid picture {
    display: block;
    width: 100%;
    max-width: 1000px;
    /* Largura máxima igual à da galeria */
    background-color: #000;
    border-radius: 8px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
    aspect-ratio: 1280 / 800;
    /* Proporção correta da imagem (1280x800) */
    overflow: hidden;
}

.location-grid picture img {
    width: 100%;
    height: 100%;
    display: block;
    object-fit: cover;
}

.location-info h3 {
    margin-top: 20px;
    margin-bottom: 10px;
    color: var(--text-light);
}

.location-info p {
    margin: 0 auto 30px auto;
    /* Garante a centralização do parágrafo */
    max-width: none;
}

.location-info .btn {
    font-size: 20px;
    padding: 20px 45px;
    margin-top: 20px;
}

/* SEÇÃO VANTAGENS */
.advantages-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    /* Duas colunas de tamanho igual */
    gap: 50px;
    align-items: center;
    text-align: left;
    /* Alinha o texto à esquerda */
}

.advantages-text .tag {
    color: var(--primary-green);
    font-weight: 700;
    display: block;
    margin-bottom: 10px;
}

.advantages-text h2 {
    color: var(--text-light);
    /* Garante que o título seja branco */
    margin-bottom: 15px;
}

.advantages-text p {
    margin: 0;
    /* Remove a margem automática para alinhar à esquerda */
    max-width: none;
}

.advantages-list ul {
    list-style: none;
    /* Remove as bolinhas da lista */
    padding: 0;
}

.advantages-list li {
    font-size: 18px;
    margin-bottom: 20px;
    display: flex;
    /* Alinha o ícone e o texto */
    align-items: center;
}

/* --- SEÇÃO VANTAGENS --- */
.advantages-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    /* Duas colunas de tamanho igual */
    gap: 50px;
    align-items: center;
    text-align: left;
    /* Alinha o texto à esquerda nesta seção */
}

.advantages-text .tag {
    color: var(--primary-green);
    font-weight: 700;
    display: block;
    margin-bottom: 10px;
}

.advantages-text h2 {
    color: var(--text-light);
    /* Garante que o título seja branco */
    margin-bottom: 15px;
}

.advantages-text p {
    margin: 0;
    /* Remove a margem automática para alinhar à esquerda */
    max-width: none;
}

.advantages-list ul {
    list-style: none;
    /* Remove as bolinhas da lista */
    padding: 0;
}

.advantages-list li {
    font-size: 18px;
    margin-bottom: 20px;
    display: flex;
    /* Alinha o ícone e o texto */
    align-items: center;
}

/* Remove a margem do último item da lista */
.advantages-list li:last-child {
    margin-bottom: 0;
}

.advantages-list i {
    color: var(--primary-green);
    font-size: 24px;
    width: 40px;
    /* Garante alinhamento consistente dos ícones */
    margin-right: 15px;
}

/* SEÇÃO INSTAGRAM */
.instagram-icon {
    display: inline-block;
    margin-top: 20px;
    color: var(--text-light);
    font-size: 48px;
    border: 3px solid var(--border-color);
    border-radius: 50%;
    width: 100px;
    height: 100px;
    line-height: 100px;
    text-align: center;
    transition: all 0.3s ease;
}

.instagram-icon:hover {
    color: var(--primary-green);
    border-color: var(--primary-green);
    transform: scale(1.1);
}

/* SEÇÃO PLANOS (PRICING) */
.pricing-cards {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
    margin-top: 50px;
}

.pricing-card {
    background-color: var(--card-bg);
    padding: 40px;
    border-radius: 10px;
    border: 2px solid var(--border-color);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    display: flex;
    flex-direction: column;
}

.pricing-card p {
    flex-grow: 1;
}

.pricing-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 10px 20px rgba(0, 240, 120, 0.1);
}

.pricing-card h3 {
    font-size: 24px;
    margin-bottom: 20px;
}

.pricing-card .price {
    font-size: 48px;
    font-weight: 700;
    color: var(--primary-green);
    margin-bottom: 10px;
}

.price span {
    font-size: 16px;
    font-weight: 400;
    color: var(--text-dark);
}

.pricing-card.popular {
    position: relative;
    border-color: var(--primary-green);
    overflow: hidden;
}

.badge {
    position: absolute;
    top: 15px;
    right: -30px;
    background-color: var(--primary-green);
    color: var(--bg-color);
    padding: 5px 30px;
    transform: rotate(45deg);
    font-size: 12px;
    font-weight: 700;
}

/* SEÇÃO FAQ */
.faq-accordion {
    max-width: 800px;
    margin: 40px auto;
    text-align: left;
}

.faq-item {
    background-color: var(--card-bg);
    border-radius: 5px;
    margin-bottom: 10px;
    border: 1px solid var(--border-color);
}

.faq-question {
    width: 100%;
    padding: 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: none;
    border: none;
    color: var(--text-light);
    font-size: 18px;
    font-weight: 600;
    cursor: pointer;
}

.faq-question i {
    transition: transform 0.3s ease;
}

.faq-answer {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease-out, padding 0.3s ease;
}

.faq-answer p {
    padding: 0 20px 20px;
    text-align: left;
    margin: 0;
}

.faq-item.active .faq-question i {
    transform: rotate(180deg);
}

.faq-item.active .faq-answer {
    max-height: 200px;
}

/* RODAPÉ (FOOTER) */
.footer {
    padding: 80px 0;
    background-color: var(--card-bg);
    text-align: center;
}

.footer h2 {
    margin-bottom: 30px;
}


/* MEDIA QUERIES (RESPONSIVIDADE) */

/* --- AJUSTES PARA TABLETS --- */
@media (max-width: 992px) {
    .hours-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 30px;
    }
}

/* AJUSTES PARA TELEMÓVEIS */
@media (max-width: 767px) {
    h2 {
        font-size: 28px;
    }

    /* Hero Section */
    .hero {
        padding-left: 15px;
        padding-right: 15px;
    }

    .hero .logo {
        display: block;
        width: 85%;
        max-width: 280px;
        height: auto;
        box-sizing: border-box;
        margin-left: auto;
        margin-right: auto;
        margin-top: 60px;
        margin-bottom: 30px;
    }

    .hero h1 {
        font-size: 32px;
        max-width: 100%;
    }

    .hero-buttons {
        flex-direction: column;
        width: 80%;
        margin: 0 auto;
    }

    .btn {
        width: 100%;
    }

    /* Grids Gerais */
    .philosophy-grid,
    .pricing-cards,
    .hours-grid,
    .location-grid {
        grid-template-columns: 1fr;
    }

    /* Layout da Localização */
    .location-grid {
        text-align: center;
    }

    .location-info p {
        margin-left: auto;
        margin-right: auto;
    }

    /* Carrossel */
    .swiper-container {
        height: 420px;
    }

    /* Horários */
    .hours-grid {
        gap: 15px;
    }

    .operating-hours {
        padding: 50px 0;
    }

    /* Vantagens */
    .advantages-grid {
        grid-template-columns: 1fr;
        /* Muda para uma única coluna */
        text-align: center;
        /* Centraliza o texto no telemóvel */
        gap: 40px;
    }

    .advantages-text p {
        margin-left: auto;
        /* Centraliza o parágrafo novamente */
        margin-right: auto;
    }

    .advantages-list li {
        justify-content: center;
        /* Centraliza os itens da lista no telemóvel */
    }
}

/* BOTÃO E MODAL DE VÍDEO */
.btn-video {
    background: none;
    border: 2px solid var(--border-color);
    color: var(--text-light);
    padding: 12px 28px;
    font-size: 16px;
    font-weight: 600;
    border-radius: 5px;
    cursor: pointer;
    transition: all 0.3s ease;
    margin-top: 40px;
    /* Espaço entre o carrossel e o botão */
}

.btn-video:hover {
    background-color: var(--primary-green);
    color: var(--bg-color);
    border-color: var(--primary-green);
}

.modal {
    display: none;
    /* Escondido por padrão */
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.9);
    display: none;
    /* Alinhado com flex para centralizar */
    align-items: center;
    justify-content: center;
}

.modal-content {
    background-color: var(--card-bg);
    padding: 20px;
    border: 1px solid var(--border-color);
    width: 90%;
    max-width: 450px;
    /* Largura máxima para vídeo vertical */
    border-radius: 10px;
    position: relative;
}

.close-btn {
    color: #aaa;
    position: absolute;
    top: 10px;
    right: 25px;
    font-size: 35px;
    font-weight: bold;
    cursor: pointer;
}

.close-btn:hover {
    color: var(--text-light);
}

.video-wrapper {
    position: relative;
    width: 100%;
    height: 0;
    padding-top: 122.78%;
    background-color: #000;
}

.video-wrapper video {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
}

/*Vídeo Da Academia Responsividade*/
@media (min-width: 769px) {
    .trainers-images {
        /* Define uma largura máxima para a grelha em telas grandes */
        max-width: 900px;
        /* Centraliza a grelha que agora é mais estreita */
        margin-left: auto;
        margin-right: auto;
    }
}

/* AJUSTES PARA O CARROSSEL */

/* Para TABLETS (telas entre 769px e 1023px de largura) */
@media (min-width: 768px) and (max-width: 1023px) {
    .swiper-slide img {
        /* Força a exibição da imagem inteira, resolvendo o "zoom" */
        object-fit: contain !important;
    }
}

/* Para DESKTOPS (telas com 1024px de largura ou mais) */
@media (min-width: 1024px) {
    .swiper-slide img {
        /* Força o preenchimento total, resolvendo as "bordas pretas" */
        object-fit: cover !important;
    }
}