html {
  scroll-behavior: smooth;
}

:root {
  --cor-primaria: #004a99;
  --cor-secundaria: #ddd;
  --cor-destaque: #ffffff;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: 'Segoe UI', sans-serif;
  background-color: var(--cor-destaque);
  color: var(--cor-primaria);
}

header {
    background-color: #004a99;
    color: #f8f9fa;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 2rem 2rem;
    flex-wrap: wrap;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.15);
}

.nome-escola {
  font-size: 1.5rem;
  font-weight: bold;
  padding: 0.5rem 1rem;
}

.logo-central {
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  z-index: 1000;
}

.logo-central img {
  width: 125px;
  height: 125px;
  object-fit: contain;
}

/* MENU LATERAL SEMPRE CONTROLADO PELO BOTÃO */
#menu-lateral {
  position: fixed;
  top: 0;
  left: -250px;
  width: 250px;
  height: 100%;
  background-color: #004a99b0;
  transition: left 0.3s ease-in-out;
  padding-top: 5rem;
  z-index: 999;
}

#menu-lateral.show {
  left: 0;
}

#menu-lateral ul {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
  padding: 1rem 2rem;
}

#menu-lateral a {
  text-decoration: none;
  color: #ffffff;
  font-weight: bold;
}


/* CONTEÚDO DA PÁGINA */
.hero {
  text-align: center;
  background-color: var(--cor-destaque);
  color: var (--cor-primaria);
  padding: 3rem 1rem;
}

.hero img {
  max-width: 100%;
  height: auto;
  margin-top: 1.5rem;
  border-radius: 10px;
}

.modalidades {
  padding: 2rem;
  background-color: var(--cor-destaque);
  text-align: center;
}

.cards {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 2rem;
  margin-top: 2rem;
}

.card {
  width: 250px;
  border: 2px solid var(--cor-destaque);
  border-radius: 10px;
  overflow: hidden;
  background-color: var(--cor-destaque);
  color: var(--cor-destaque);
}

.card img {
  width: 100%;
  height: 150px;
  object-fit: cover;
}

.card h3 {
  margin: 1rem 0;
}

.galeria {
  padding: 2rem;
  background-color: var(--cor-primaria);
  color: var(--cor-destaque);
  text-align: center;
}

.grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 1rem;
  margin-top: 2rem;
}

.grid img {
  width: 100%;
  border-radius: 10px;
  object-fit: cover;
}

.menu-topo {
  margin-left: auto;
  display: flex;
  align-items: center;
}

.menu-topo ul {
  display: flex;
  gap: 2rem;
  list-style: none;
}

.menu-topo a {
  text-decoration: none;
  color: var(--cor-destaque);
  font-weight: bold;
  transition: color 0.2s ease-in-out;
}

.menu-topo a:hover {
  color: var(--cor-destaque);
}

/* BOTÃO HAMBURGUER BONITO */
.hamburguer {
  width: 40px;
  /* maior largura */
  height: 30px;
  /* maior altura */
  background: none;
  border: none;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 5px;
  z-index: 1001;
}

.hamburguer span {
  display: block;
  height: 4px;
  /* linha mais grossa */
  width: 100%;
  background-color: var(--cor-secundaria);
  border-radius: 2px;
  transition: all 0.3s ease;
}

/* Estado de X */
.hamburguer.ativo span:nth-child(1) {
  transform: rotate(45deg) translate(7px, 7px);
}

.hamburguer.ativo span:nth-child(2) {
  opacity: 0;
}

.hamburguer.ativo span:nth-child(3) {
  transform: rotate(-45deg) translate(7px, -7px);
}


footer {
  background-color: var(--cor-primaria);
  color: var(--cor-destaque);
  padding: 1rem;
  text-align: center;
}

.footer-top {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
}

.footer-top img {
  width: 50px;
  height: auto;
  padding-left: 10px;
}

.nome-footer {
  font-weight: bold;
  font-size: 1.1rem;
}

.direitos {
  margin-top: 5px;
  font-size: 0.9rem;
}

.footer-contatos {
  display: flex;
  flex-direction: column;
  margin-top: 8px;
  gap: 4px;
}

.footer-contatos a {
  color: var(--cor-destaque);
  text-decoration: none;
}

.footer-contatos a:hover {
  text-decoration: underline;
}

.trofeus {
  background-color: var(--cor-destaque);
  color: var(--cor-primaria);
  padding: 2rem;
  text-align: center;
}

.trofeus h2 {
  margin-bottom: 1.5rem;
}

.grid-trofeus {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 1rem;
}

.trofeu-item img {
  width: 100%;
  height: 150px;
  object-fit: cover;
  border-radius: 10px;
}

.trofeu-item p {
  margin-top: 0.5rem;
  font-weight: bold;
}

.footer-contatos a {
  display: flex;
  align-items: center;
  gap: 8px;
}

.footer-contatos img {
  width: 20px;
  height: 20px;
}

.carousel {
  position: relative;
  max-width: 600px;
  margin: auto;
  overflow: hidden;
}

.carousel-images {
  display: flex;
  transition: transform 0.5s ease-in-out;
}

.carousel-images img {
  width: 100%;
  flex-shrink: 0;
  border-radius: 10px;
}

.carousel button {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: rgba(0, 0, 0, 0.5);
  border: none;
  color: white;
  font-size: 2rem;
  padding: 0.5rem;
  cursor: pointer;
}

.carousel .prev {
  left: 10px;
}

.carousel .next {
  right: 10px;
}

.carousel {
  position: relative;
  max-width: 600px;
  margin: 2rem auto;
  overflow: hidden;
}

.carousel-images {
  display: flex;
  transition: transform 0.5s ease-in-out;
}

.carousel-images img {
  width: 100%;
  flex-shrink: 0;
  border-radius: 10px;
}

.carousel button {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: rgba(0, 0, 0, 0.5);
  border: none;
  color: white;
  font-size: 2rem;
  padding: 0.5rem;
  cursor: pointer;
  z-index: 10;
}

.carousel .prev {
  left: 10px;
}

.carousel .next {
  right: 10px;
}

.carrossel-container {
  display: flex;
  justify-content: center;
  gap: 20px;
  flex-wrap: wrap;
}

.carousel {
  position: relative;
  width: 300px;
  height: 200px;
  overflow: hidden;
  border-radius: 10px;
}

.carousel-images {
  display: flex;
  transition: transform 0.5s ease-in-out;
}

.carousel-images img {
  width: 300px;
  height: 200px;
  object-fit: cover;
  flex-shrink: 0;
}

.carousel button {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: rgba(255, 255, 255, 0.7);
  border: none;
  color: var(--cor-primaria);
  font-size: 1.5rem;
  padding: 0.6rem;
  cursor: pointer;
  z-index: 10;
  border-radius: 50%;
  box-shadow: 0px 2px 6px rgba(0, 0, 0, 0.2);
  transition: background 0.3s ease, transform 0.2s ease;
}

.carousel button:hover {
  background: var(--cor-primaria);
  color: white;
  transform: translateY(-50%) scale(1.1);
}

/* Reaproveitar layout da galeria para Modalidades e Troféus */
.modalidades .carrossel-container,
.trofeus .carrossel-container {
  display: flex;
  justify-content: center;
  gap: 20px;
  flex-wrap: wrap;
  align-items: center;
}

.carousel button {
  background: none;
  border: none;
  color: var(--cor-primaria);
  font-size: 2rem;
  cursor: pointer;
  z-index: 10;
  transition: color 0.3s ease;
}

.carousel button:hover {
  color: var(--cor-destaque);
}

.carousel .prev {
  left: 5px;
}

.carousel .next {
  right: 5px;
}

/* Remove botões da galeria */
.galeria .carousel button {
  display: none !important;
}

/* GALERIA - deixar imagens maiores e com mais espaçamento */
.galeria .grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 20px;
  /* mais espaçamento */
  margin-top: 2rem;
}

.galeria .grid img {
  width: 100%;
  height: 220px;
  /* aumenta o tamanho */
  border-radius: 12px;
  object-fit: cover;
  transition: transform 0.3s ease;
}

.galeria .grid img:hover {
  transform: scale(1.05);
}

footer {
  background: linear-gradient(135deg, #004a99, #002b5c);
  color: var(--cor-destaque);
  padding: 2.5rem 1rem;
  text-align: center;
}

.footer-conteudo {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 15px;
}

.footer-logo {
  width: 70px;
  height: auto;
  border-radius: 50%;
  box-shadow: 0px 4px 12px rgba(0, 0, 0, 0.3);
}

.footer-nome {
  font-size: 1.4rem;
  font-weight: bold;
  margin: 0;
}

.footer-links {
  display: flex;
  gap: 20px;
  margin-top: 10px;
}

.footer-links a {
  color: var(--cor-destaque);
  text-decoration: none;
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 1rem;
  transition: transform 0.2s ease, color 0.2s ease;
}

.footer-links a:hover {
  transform: scale(1.1);
  color: #ffdd57;
}

.direitos {
  margin-top: 20px;
  font-size: 0.85rem;
  opacity: 0.8;
}

/* ==================== MOBILE (até 600px) ==================== */
@media (max-width: 600px) {
  header {
    display: flex;
    flex-direction: row; /* mantém horizontal */
    justify-content: space-between;
    align-items: center;
    padding: 0.8rem 1rem 2.5rem; /* espaço extra para a logo */
    position: fixed;
  }

  /* Botão hambúrguer */
  .hamburguer {
    width: 35px;
    height: auto;
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 6px;
    margin: 0;
    order: 0;
  }

  .hamburguer span {
    height: 5px;
    border-radius: 3px;
  }

  /* Nome da escola */
  .nome-escola {
    font-size: 1rem;
    position: absolute;        /* fixa dentro do header */
    top: 58px;                 /* desce */
    left: 50%;                 /* centraliza */
    transform: translateX(-50%);
    margin: 2;
    text-align: center;
    font-weight: bold;
    white-space: nowrap;   /* impede o texto de quebrar */
  }

  /* Logo central */
  .logo-central {
    position: absolute;
    top: -10px;                /* ajusta a altura */
    left: 50%;
    transform: translateX(-50%);
    margin: 0;
    order: 1;
  }

  .logo-central img {
    width: 100px;
    height: 100px;
  }
   .menu-topo {
    display: block;
    width: 100%;
    margin-top: 70px;            /* encosta mais no header */
    overflow-x: auto;            /* arrastar pro lado */
    white-space: nowrap;
    -webkit-overflow-scrolling: touch;
    background-color: var(--cor-primaria);
    padding: 0.1rem 0;           /* altura mínima */
    line-height: 1;              /* compacta ainda mais */
  }

  /* Esconde barra de rolagem mas mantém scroll */
  .menu-topo::-webkit-scrollbar {
    display: none;
  }
  .menu-topo {
    -ms-overflow-style: none;
    scrollbar-width: none;
  }

  .menu-topo ul {
    display: inline-flex;
    gap: 0.8rem;                 /* espaçamento menor */
    padding: 0 0.5rem;
    list-style: none;
  }

  .menu-topo a {
    display: inline-block;
    color: var(--cor-destaque);
    text-decoration: none;
    font-weight: 600;
    font-size: 0.85rem;          /* fonte menor */
    padding: 0.2rem 0.4rem;      /* só um respiro */
  }

  .menu-topo a:hover {
    color: #ffdd57;
  }

  #menu-lateral {
    width: 200px;
  }
}

/* Container do switch */
.theme-switch-container {
  margin-top: 2rem;
  padding-top: 2rem;
  border-top: 1px solid rgba(0, 74, 153, 0.1);
}

.theme-switch {
  display: flex;
  align-items: center;
  gap: 1rem;
  cursor: pointer;
  user-select: none;
}

.theme-switch input {
  display: none;
}

/* Botão deslizante */
.slider {
  width: 50px;
  height: 26px;
  background-color: #ccc;
  border-radius: 26px;
  position: relative;
  transition: var(--transition-medium);
}

.slider::before {
  content: "";
  position: absolute;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background-color: white;
  top: 2px;
  left: 2px;
  transition: var(--transition-medium);
}

/* Quando ativo */
input:checked + .slider {
  background-color: var(--main-color);
}
input:checked + .slider::before {
  transform: translateX(24px);
}

/* Texto ao lado */
.theme-label {
  color: var(--text-color);
  font-weight: 500;
}

