/* Variables */
:root {
  --primary-color: #005665;
  --primary-hover: #03a2ae;
  --secondary-color: #9ddbdf;
  --background-color: #cceeee;
  --accent-color: #9ddbdf;
  --text-color: #444444;
  --light-text: #ffffff;
  --shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
  --transition: all 0.3s ease;
  --border-radius: 10px;
  --page-transition: 0.5s;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

@font-face {
  font-family: "Franklin Gothic Heavy";
  src: url("https://db.onlinewebfonts.com/t/eb9a58973a13e15e4ec5723f2f6b5344.woff2") format("woff2");
  font-weight: normal;
  font-style: normal;
}

.intro-wrapper {
  height: 115vh; 
  width: 100%;
  position: relative;
  z-index: 1;
}

.intro-anim {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100vh;
  background-color: black;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 9999;
  overflow: hidden;
  transition: opacity 0.5s ease;
}

.intro-anim.hidden {
  opacity: 0;
  pointer-events: none;
}

.logo-patita {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  max-width: 300px;
  will-change: transform, opacity;
  transition: opacity 0.3s ease;
}

/* Cuando la animación está activa, ocultar el contenido */
body.intro-active header,
body.intro-active main,
body.intro-active footer {
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.5s ease;
}

body.intro-finished header,
body.intro-finished main,
body.intro-finished footer {
  opacity: 1;
  pointer-events: auto;
}

/*El header fijo en todas las páginas */
header {
  position: fixed !important;
  top: 0;
  left: 0;
  right: 0;
  z-index: 10000 !important;
  background: url("assets/fondo_web.png") repeat;
  color: var(--light-text);
  box-shadow: var(--shadow);
  transition: height 0.3s ease;
  pointer-events: auto !important;
}

main {
  flex: 1;
  padding: 2rem 1rem;
  max-width: 1200px;
  margin: 120px auto 0 auto;
  width: 100%;
}

/* Ajustes responsive para el margin-top del main */
@media (max-width: 1000px) {
  main {
    margin-top: 140px;
  }
}

@media (max-width: 480px) {
  main {
    margin-top: 100px;
  }
}

@media (max-width: 360px) {
  main {
    margin-top: 80px;
  }
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: "Franklin Gothic Heavy", "Segoe UI", Tahoma, Geneva, Verdana, sans-serif;
  background-color: var(--background-color);
  color: var(--text-color);
  line-height: 1.6;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  opacity: 0;
  animation: fadeIn 1s ease forwards;
}

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

.page-transition.active {
  transform: translateY(0);
}

.header-content {
  max-width: 1200px;
  margin: 0 auto;
  padding: 1rem;
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  flex-wrap: wrap;
  position: relative;
  transition: min-height 0.3s ease;
}

.logo-container {
  display: flex;
  align-items: flex-end;
  position: relative;
}

.gato-web {
  height: 70px;
  position: relative;
  bottom: -25px; /* Para que mi Reina se apoye en la línea inferior del header */
  z-index: 2;
  transition: height 0.3s ease, bottom 0.3s ease;
}

.logo {
  height: 100px;
  margin-left: 10px;
  transition: height 0.3s ease;
}

nav {
  display: flex;
  align-items: center;
}

.nav-links {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
}

.nav-button {
  color: var(--light-text);
  text-decoration: none;
  font-weight: bold;
  padding: 0.5rem 1rem;
  border-radius: var(--border-radius);
  transition: var(--transition);
  background-color: var(--primary-color);
}

.nav-button:hover {
  transform: scale(1.05);
  background-color: var(--primary-hover);
}

.menu-toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0.5rem;
  z-index: 1000;
  position: absolute;
  bottom: 1rem;
  right: 1rem;
}

.menu-toggle span {
  display: block;
  width: 25px;
  height: 3px;
  margin: 5px 0;
  background-color: var(--light-text);
  border-radius: 3px;
  transition: var(--transition);
}

.overlay {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.7);
  z-index: 90;
  opacity: 0;
  transition: opacity 0.3s ease;
}

.overlay.active {
  display: block;
  opacity: 1;
}

@keyframes slideUp {
  from {
    transform: translateY(20px);
    opacity: 0;
  }
  to {
    transform: translateY(0);
    opacity: 1;
  }
}

.hero {
  text-align: center;
  background: var(--accent-color);
  padding: 2rem;
  border-radius: var(--border-radius);
  margin-bottom: 2rem;
  box-shadow: var(--shadow);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}
.hero-img {
  max-width: 100%;
  height: auto;
  border-radius: var(--border-radius);
}

.hero:hover {
  transform: translateY(-5px);
  box-shadow: 0 6px 12px rgba(0, 0, 0, 0.15);
}

.hero h2 {
  margin-bottom: 1rem;
  font-size: 2rem;
  transition: font-size 0.3s ease;
}

.features {
  margin-bottom: 2rem;
}

.features h3 {
  margin-bottom: 1rem;
  text-align: center;
}

.features ul {
  list-style: none;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 1rem;
}

.features li {
  background: white;
  padding: 1.5rem;
  border-radius: var(--border-radius);
  box-shadow: var(--shadow);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.features li:hover {
  transform: translateY(-5px);
  box-shadow: 0 6px 12px rgba(0, 0, 0, 0.15);
}
.feature-card {
  position: relative;
  background: white;
  padding: 1.5rem;
  border-radius: var(--border-radius);
  box-shadow: var(--shadow);
  cursor: pointer;
  transition: transform 0.3s ease, box-shadow 0.3s ease;

  display: flex;
  align-items: center;
  justify-content: center; 
  flex-direction: column; 
}

.feature-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 6px 12px rgba(0, 0, 0, 0.15);
}

.feature-card h3 {
  color: #005665;
  text-align: center;
  width: 100%;
}

.feature-expand {
  max-height: 0;
  overflow: hidden;
  opacity: 0;
  transition: max-height 0.5s ease, opacity 0.5s ease;
}

.feature-card.active .feature-expand {
  max-height: 200px;
  opacity: 1;
  margin-top: 1rem;
}

.feature-button {
  display: inline-block;
  margin-top: 0.5rem;
  padding: 0.5rem 1rem;
  background-color: var(--primary-color);
  color: var(--light-text);
  border-radius: var(--border-radius);
  text-decoration: none;
  transition: background-color 0.3s ease;
}

.feature-button:hover {
  background-color: var(--primary-hover);
}


.content-section {
  margin-bottom: 2rem;
}
.content-card {
  background: white;
  padding: 2rem;
  border-radius: var(--border-radius);
  box-shadow: var(--shadow);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  animation: fadeIn 0.5s ease;
}

.content-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 6px 12px rgba(0, 0, 0, 0.15);
}

.content-card h2 {
  margin-bottom: 1rem;
  color: var(--primary-color);
}

.content-card h3 {
  margin: 1.5rem 0 0.5rem;
  color: var(--primary-color);
}

.content-card h4 {
  margin: 1.2rem 0 0.5rem;
  color: var(--primary-color);
}

.content-card ol,
.content-card ul {
  padding-left: 2rem;
  margin: 1rem 0;
}

.email-link {
  color: var(--primary-color);
  text-decoration: none;
  font-weight: bold;
  transition: var(--transition);
}

.email-link:hover {
  text-decoration: underline;
}

/* Footer */
footer {
  background: url("assets/fondo_web.png") repeat;
  color: var(--light-text);
  text-align: center;
  padding: 0.8rem 0.5rem;
  margin-top: auto;
  transition: padding 0.3s ease;
}

.footer-links {
  display: flex;
  justify-content: center;
  align-items: center;
  flex-wrap: nowrap;
  margin-bottom: 0.5rem;
}

.footer-button {
  color: var(--light-text);
  text-decoration: none;
  font-weight: bold;
  padding: 0.3rem 0.6rem;
  border-radius: var(--border-radius);
  transition: var(--transition);
  background-color: transparent;
  font-size: 0.85rem;
  white-space: nowrap;
}

.footer-button:hover {
  text-decoration: underline;
}

footer p {
  font-size: 0.8rem;
  transition: font-size 0.3s ease;
}

  footer {
  position: fixed;
  bottom: 0;
  left: 0;
  width: 100%;
  z-index: 99999;
}

/* Fondo oscurecido para cookies */
.cookie-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.4);
  z-index: 9998;
  display: none;
  opacity: 0;
  transition: opacity 0.3s ease;
}

.cookie-overlay.active {
  opacity: 1;
}

/* Banner cookies */
.cookie-banner {
  position: fixed;
  bottom: 30px;
  left: 50%;
  transform: translateX(-50%);
  background-color: #ffffff;
  color: #444444;
  border-radius: 12px;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
  padding: 20px;
  width: 90%;
  max-width: 500px;
  z-index: 9999;
  display: none;
  text-align: center;
  opacity: 0;
  transform: translateX(-50%) translateY(20px);
  transition: opacity 0.3s ease, transform 0.3s ease;
}

.cookie-banner.active {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}

.cookie-text {
  margin-bottom: 15px;
}

.cookie-link {
  color: #005665;
  font-weight: bold;
  text-decoration: underline;
}

.cookie-buttons {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 10px;
}

.cookie-buttons button {
  padding: 8px 16px;
  border-radius: 8px;
  font-size: 0.9rem;
  border: 1px solid #005665;
  background-color: #ffffff;
  color: #005665;
  cursor: pointer;
  transition: background-color 0.3s ease;
}

.cookie-buttons button:hover {
  background-color: #03a2ae;
  color: #ffffff;
}

.cookie-buttons .btn-primary {
  background-color: #005665;
  color: #ffffff;
}

.cookie-buttons .btn-primary:hover {
  background-color: #03a2ae;
}

/* Estilos para la tabla de cookies */
.cookie-table {
  width: 100%;
  border-collapse: collapse;
  margin: 1rem 0;
  font-size: 0.9rem;
}

.cookie-table th,
.cookie-table td {
  border: 1px solid #ddd;
  padding: 8px;
  text-align: left;
}

.cookie-table th {
  background-color: var(--accent-color);
  color: var(--text-color);
}

.cookie-table tr:nth-child(even) {
  background-color: #f9f9f9;
}

.cookie-table tr:hover {
  background-color: #f1f1f1;
}

/* Estilos para la página de configuración de cookies */
.cookie-preferences-banner {
  background-color: var(--accent-color);
  padding: 1rem;
  border-radius: var(--border-radius);
  margin: 1rem 0;
  text-align: center;
}

.cookie-config-button {
  padding: 8px 16px;
  border-radius: 8px;
  font-size: 0.9rem;
  border: 1px solid var(--primary-color);
  background-color: #ffffff;
  color: var(--primary-color);
  cursor: pointer;
  transition: background-color 0.3s ease;
  margin-top: 10px;
}

.cookie-config-button:hover {
  background-color: var(--primary-hover);
  color: #ffffff;
}

.cookie-config-button.primary {
  background-color: var(--primary-color);
  color: #ffffff;
}

.cookie-config-form {
  margin: 2rem 0;
}

.cookie-option {
  margin-bottom: 1.5rem;
  padding-bottom: 1.5rem;
  border-bottom: 1px solid #eee;
}

.cookie-option:last-child {
  border-bottom: none;
}

.cookie-option-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 0.5rem;
}

.cookie-switch {
  position: relative;
  display: inline-block;
  width: 50px;
  height: 24px;
}

.cookie-switch input {
  opacity: 0;
  width: 0;
  height: 0;
}

.cookie-switch label {
  position: absolute;
  cursor: pointer;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: #ccc;
  transition: .4s;
  border-radius: 34px;
}

.cookie-switch label:before {
  position: absolute;
  content: "";
  height: 16px;
  width: 16px;
  left: 4px;
  bottom: 4px;
  background-color: white;
  transition: .4s;
  border-radius: 50%;
}

.cookie-switch input:checked + label {
  background-color: var(--primary-color);
}

.cookie-switch input:checked + label:before {
  transform: translateX(26px);
}

.cookie-switch.disabled label {
  background-color: #aaa;
  cursor: not-allowed;
}

.cookie-config-buttons {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 2rem;
}

.cookie-info {
  margin-top: 2rem;
  padding-top: 1rem;
  border-top: 1px solid #eee;
  font-size: 0.9rem;
}

/* Responsive */
@media (max-width: 1000px) {
  .header-content {
    position: relative;
    min-height: 120px;
  }

  .logo-container {
    position: absolute;
    top: 1rem;
    left: 1rem;
    margin-bottom: 0;
  }

  .menu-toggle {
    display: block;
  }

  .menu-toggle.active span:nth-child(1) {
    transform: rotate(45deg) translate(5px, 5px);
  }

  .menu-toggle.active span:nth-child(2) {
    opacity: 0;
  }

  .menu-toggle.active span:nth-child(3) {
    transform: rotate(-45deg) translate(7px, -6px);
  }

  .nav-links {
    display: none;
    position: fixed;
    top: 0;
    right: 0;
    width: auto;
    height: auto;
    background-color: rgba(255, 255, 255, 0.6);
    backdrop-filter: blur(5px);
    flex-direction: column;
    padding: 5rem 2rem 2rem;
    z-index: 100;
    border-radius: 0 0 0 var(--border-radius);
    box-shadow: var(--shadow);
    transform: translateX(100%);
    transition: transform 0.3s ease;
  }

  .nav-links.active {
    display: flex;
    transform: translateX(0);
  }

  .nav-button {
    width: 100%;
    text-align: center;
  }

  .cookie-table {
    font-size: 0.8rem;
  }

  .cookie-option-header {
    flex-direction: column;
    align-items: flex-start;
  }

  .cookie-switch {
    margin-top: 0.5rem;
  }

  .cookie-config-buttons {
    flex-direction: column;
  }

  .cookie-config-button {
    width: 100%;
  }
}

@media (max-width: 1000px) {
  .header-content {
    min-height: 100px;
  }

  .gato-web {
    height: 60px;
    bottom: -12px;
  }

  .logo {
    height: 80px;
  }
}

@media (max-width: 480px) {
  .header-content {
    min-height: 80px;
  }

  .gato-web {
    height: 50px;
    bottom: -11px;
  }

  .logo {
    height: 60px;
  }

  .hero h2 {
    font-size: 1.5rem;
  }

  .footer-button {
    font-size: 0.75rem;
    padding: 0.2rem 0.4rem;
  }

  footer p {
    font-size: 0.7rem;
  }

  .cookie-table th,
  .cookie-table td {
    padding: 5px;
    font-size: 0.7rem;
  }
}

@media (max-width: 360px) {
  .header-content {
    min-height: 70px;
  }

  .gato-web {
    height: 40px;
    bottom: -10px;
  }

  .logo {
    height: 50px;
  }

  .footer-button {
    font-size: 0.65rem;
    padding: 0.15rem 0.3rem;
  }

  footer p {
    font-size: 0.6rem;
  }
}

.scroll-card-img {
  width: 300px;
  max-width: 100%;
  max-height: 100%;
  border-radius: var(--border-radius);
  box-shadow: var(--shadow);
}

.scroll-card-text {
  color: #444444;
  position: relative;
  z-index: 1; 
  text-align: center;
}

/* Escalado progresivo de fuentes */
.scroll-card h2 {
  font-size: clamp(1rem, 2vw, 2rem);
  margin-bottom: 1rem;
  color: var(--primary-color);
}

.scroll-card p {
  font-size: clamp(0.5rem, 1.8vw, 1rem);
  line-height: 1.6;
}

.scroll-card {
  position: relative;
  width: 100%;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  background-size: contain;
  background-repeat: no-repeat;
  background-position: center;
  padding: 2rem;
  overflow: hidden;
  opacity: 0;
  transform: scale(0.8);
  transition: none;
  transform-origin: center center;
  background-color: var(--background-color);
}

/* Texto dentro de la tarjeta */
.scroll-card .scroll-card-text {
  position: relative;
  z-index: 2;
  width: 100%;
  max-width: 700px;
  background: rgba(255, 255, 255, 0.9);
  padding: 2rem;
  border-radius: var(--border-radius);
  box-shadow: var(--shadow);
  text-align: center;
}

.scroll-card.visible::before {
  opacity: 1;
}

/* Activación visible */
.scroll-card.visible {
  opacity: 1;
  transform: scale(1);
}

.card-mision {
  background-image: url("assets/sobrenosmision.png");
}

.card-que-es {
  background-image: url("assets/sobrenosquees.png");
}

.card-idea {
  background-image: url("assets/sobrenosidea.png");
}

.card-sobre-nosotros-rei {
  background-image: url("assets/sobrenosreina.png");
}

.card-sobre-nosotros-aina {
  background-image: url("assets/sobrenosaina.png");
}

.card-sobre-nosotros-dani {
  background-image: url("assets/sobrenosdani.png");
}

/* Animación de sobre nosotros */
.sobre-anim {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100vh;
  background-color: var(--background-color);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 9999;
  overflow: hidden;
  transition: opacity 0.5s ease;
}

.sobre-current-image {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 80%;
  height: 80%;
  background-size: contain;
  background-repeat: no-repeat;
  background-position: center;
  will-change: transform, opacity;
  transition: opacity 0.3s ease;
}

/* Estilos para animaciones de página sobre */
.sobre-anim-element {
  will-change: transform, opacity, background-size;
  transition: opacity 0.3s ease, transform 0.1s ease;
}

body.sobre-page {
  overflow-x: hidden;
}

.scroll-card {
  min-height: 150vh;
}

/*Sobre - responsive */
.sobre-anim-element {
  will-change: transform, opacity;
  transition: opacity 0.3s ease, transform 0.2s ease;
}

.scroll-card {
  min-height: 120vh;
}

/* Responsive para móviles */
@media (max-width: 480px) {
  .scroll-card {
    min-height: 100vh;
  }

  .sobre-anim-element {
    background-size: cover !important;
  }
}

/* Responsive para tablets */
@media (max-width: 768px) {
  .scroll-card {
    min-height: 110vh;
  }
}

/* Asegurar que las imágenes se vean bien en pantallas pequeñas */
@media (max-width: 1024px) {
  .sobre-anim-element {
    background-attachment: scroll;
  }
}

/* Mejora la transición entre animaciones */
.sobre-anim-element {
  background-attachment: fixed;
}

body.sobre-page header,
body.sobre-page main,
body.sobre-page footer {
  transition: opacity 0.3s ease;
}

/* Responsive para móviles */
@media (min-width: 769px) {
  .scroll-card {
    flex-direction: column;
    justify-content: flex-start;
    padding-top: 4rem;
    padding-bottom: 4rem;
  }
  .scroll-card + .scroll-card {
    margin-top: 2rem;
  }
  .scroll-card::before {
    background: rgba(0, 0, 0, 0.1);
  }

  .scroll-card-img {
    width: 100%;
  }
  .scroll-card .scroll-card-text {
    padding: 1.5rem;
  }
}

.tutorial-hamburguesa {
  position: fixed;
  top: 150px;
  left: 20px;
  z-index: 999;
}

.tutorial-toggle {
  background: none;
  border: none;
  cursor: pointer;
  padding: 0.5rem;
}

.tutorial-toggle span {
  display: block;
  width: 25px;
  height: 3px;
  margin: 5px 0;
  background-color: var(--primary-color);
  border-radius: 3px;
  transition: var(--transition);
}

.tutorial-toggle.active span:nth-child(1) {
  transform: rotate(45deg) translate(5px, 5px);
}
.tutorial-toggle.active span:nth-child(2) {
  opacity: 0;
}
.tutorial-toggle.active span:nth-child(3) {
  transform: rotate(-45deg) translate(5px, -5px);
}

.tutorial-float-menu {
  display: none;
  flex-direction: column;
  background-color: rgba(255, 255, 255, 0.95);
  border-radius: var(--border-radius);
  box-shadow: var(--shadow);
  padding: 1rem;
  margin-top: 0.5rem;
}

.tutorial-float-menu.active {
  display: flex;
}

.tutorial-float-menu .nav-button {
  background-color: var(--accent-color);
  color: var(--text-color);
  margin: 0.2rem 0;
  font-size: 0.9rem;
}
