/* Reset & Base */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: 'Arial', sans-serif;
  line-height: 1.6;
  color: #333;
}

a {
  text-decoration: none;
  color: inherit;
}

.container {
  width: 90%;
  max-width: 1200px;
  margin: 0 auto;
}

/* Header */
header {
  background-color: rgb(0, 64, 128);
  color: white;
  padding: 15px 0;
}

header .container {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.logo {
  font-size: 1.8rem;
  font-weight: bold;
  white-space: nowrap;
}

nav ul {
  list-style: none;
  display: flex;
  gap: 25px;
}

nav ul li a {
  color: white;
  font-weight: 500;
  transition: color 0.3s;
}

nav ul li a:hover {
  color: #ffcc00;
}

/* Responsive Mobile Menu */
@media (max-width: 768px) {
  header .container {
    flex-direction: column;
    gap: 10px;
  }

  nav ul {
    gap: 15px;
  }

  .logo {
    font-size: 1.6rem;
  }
}

/* HERO SECTION */
.hero {
  width: 100%;
  height: 70vh;
  background: url('images/hero-asturias.png') center center/cover no-repeat;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
}

/* Dark transparent layer for readability */
.hero-overlay {
  background: rgba(0, 0, 0, 0);
  /* adjustable */
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
}

/* Hero text box */
.hero-content {
  max-width: 700px;
  background: rgba(0, 64, 128, 0.359);
  padding: 40px 50px;
  border-radius: 15px;
  text-align: center;
}

.hero h1 {
  color: #fff;
  font-size: 2.8rem;
  margin-bottom: 15px;
}

.hero p {
  color: #eee;
  font-size: 1.2rem;
  margin-bottom: 25px;
}

.btn-primary {
  display: inline-block;
  padding: 12px 28px;
  background: rgb(225, 245, 110);
  /* Idealista green */
  color: rgb(0, 0, 0);
  text-decoration: none;
  border-radius: 8px;
  font-weight: 600;
  transition: 0.3s ease;
}

.btn-primary:hover {
  background: rgb(158, 179, 38);
  /* Slightly darker green */
}

/* HERO ANIMATIONS */
@keyframes fadeSlideUp {
  0% {
    opacity: 0;
    transform: translateY(30px);
  }

  100% {
    opacity: 1;
    transform: translateY(0);
  }
}

.hero-content {
  max-width: 700px;
  background: rgba(0, 64, 128, 0.359);
  padding: 40px 50px;
  border-radius: 15px;
  text-align: center;

  /* Add animation */
  animation: fadeSlideUp 1s ease forwards;
}

/* Staggered animation for h1, p, and button */
.hero-content h1 {
  color: #fff;
  font-size: 2.8rem;
  margin-bottom: 15px;
  opacity: 0;
  animation: fadeSlideUp 1s ease forwards;
  animation-delay: 0.2s;
}

.hero-content p {
  color: #eee;
  font-size: 1.2rem;
  margin-bottom: 25px;
  opacity: 0;
  animation: fadeSlideUp 1s ease forwards;
  animation-delay: 0.5s;
}

.btn-primary {
  display: inline-block;
  padding: 12px 28px;
  background: rgb(225, 245, 110);
  color: rgb(0, 0, 0);
  text-decoration: none;
  border-radius: 8px;
  font-weight: 600;
  transition: 0.3s ease;

  opacity: 0;
  animation: fadeSlideUp 1s ease forwards;
  animation-delay: 0.8s;
}

.btn-primary:hover {
  background: rgb(158, 179, 38);
}



/* MOBILE OPTIMIZATION */
@media (max-width: 768px) {
  .hero-content {
    padding: 25px;
    width: 90%;
  }

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

  .hero p {
    font-size: 1rem;
  }
}


/* About Section */
.about {
  padding: 60px 0;
  background-color: #f5f5f5;
}

.about h2 {
  text-align: center;
  margin-bottom: 20px;
  font-size: 2rem;
}

.about p {
  max-width: 800px;
  margin: 0 auto;
  text-align: center;
  font-size: 1.1rem;
}

/* Scroll Animation Base State */
.about-text {
  opacity: 0;
  transform: translateY(40px);
  transition: opacity 0.8s ease-out, transform 0.8s ease-out;
}

/* Activated When Visible */
.about-text.visible {
  opacity: 1;
  transform: translateY(0);
}


/* Why Asturias Section */
.why-asturias {
  padding: 60px 0;
  background-color: #ffffff;
}

.why-asturias h2 {
  text-align: center;
  margin-bottom: 40px;
  font-size: 2rem;
  color: #004080;
}

.why-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 25px;
}

.why-card {
  background-color: #f4f7ff;
  border: 1px solid #dfe5ff;
  padding: 25px;
  border-radius: 10px;
  text-align: center;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.why-card h3 {
  color: #004080;
  margin-bottom: 10px;
  font-size: 1.2rem;
}

.why-card p {
  font-size: 1rem;
  color: #333;
}

/* Hover effect */
.why-card:hover {
  transform: translateY(-5px);
  box-shadow: 0px 6px 16px rgba(0, 0, 0, 0.12);
}

.reveal {
  opacity: 0;
  transform: translateY(40px);
  transition: opacity 0.8s ease-out, transform 0.8s ease-out;
}

.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

/* Responsive design */
@media (max-width: 992px) {
  .why-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 600px) {
  .why-grid {
    grid-template-columns: 1fr;
  }

  .why-card {
    padding: 20px;
  }
}



/* CONTACT SECTION */
.contact {
  width: 100%;
  padding: 50px 20px;
  text-align: center;
  background-color: #f8f8f8;
  /* light background to stand out */
  position: relative;
}

/* Horizontal lines */
.contact::before,
.contact::after {
  content: "";
  display: block;
  width: 80%;
  max-width: 600px;
  height: 2px;
  background-color: #ccc;
  margin: 20px auto;
}

/* Contact text */
.contact h2 {
  font-size: 2rem;
  margin-bottom: 15px;
}

.contact p {
  font-size: 1.1rem;
  margin-bottom: 10px;
}

.contact a {
  text-decoration: none;
  transition: color 0.3s ease;
}

.contact a:hover {
  color: #000000;
  /* darker green on hover */
}

/* MOBILE OPTIMIZATION */
@media (max-width: 768px) {
  .contact {
    padding: 40px 15px;
  }

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

  .contact p {
    font-size: 1rem;
  }

  .contact::before,
  .contact::after {
    width: 90%;
  }
}

/* Footer */
footer {
  background-color: #004080;
  color: white;
  text-align: center;
  padding: 20px 0;
}

/* WhatsApp Floating Button */
.whatsapp-button {
  position: fixed;
  bottom: 25px;
  right: 25px;
  background-color: #25D366;
  width: 60px;
  height: 60px;
  border-radius: 50%;
  display: flex;
  justify-content: center;
  align-items: center;
  box-shadow: 0px 4px 8px rgba(0, 0, 0, 0.3);
  z-index: 999;
  transition: transform 0.3s ease, background-color 0.3s ease;
}

.whatsapp-button img {
  width: 35px;
  height: auto;
}

.whatsapp-button:hover {
  transform: scale(1.1);
  background-color: #1ebe5c;
}




.hero h2,
.hero p {
  color: #fff;
}


/* --- COOKIE BANNER --- */
.cookie-banner {
  position: fixed;
  bottom: 0;
  left: 0;
  width: 100%;
  background: #ffffff;
  border-top: 2px solid #ccc;
  padding: 20px;
  text-align: center;
  z-index: 9999;
  display: none;
  box-shadow: 0px -4px 12px rgba(0, 0, 0, 0.08);
}

.cookie-banner p {
  margin-bottom: 15px;
  color: #333;
}

.cookie-buttons button {
  padding: 10px 16px;
  margin: 5px;
  border: none;
  border-radius: 5px;
  cursor: pointer;
  font-weight: 600;
}

#cookie-accept {
  background: #1e3a8a;
  color: white;
}

#cookie-reject {
  background: #d9534f;
  color: white;
}

#cookie-settings-btn {
  background: #f0f0f0;
  color: #333;
}

/* --- COOKIE CONFIG MODAL --- */
.cookie-modal {
  display: none;
  position: fixed;
  z-index: 10000;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.45);
  justify-content: center;
  align-items: center;
}

.cookie-modal-content {
  background: white;
  padding: 30px;
  border-radius: 10px;
  width: 90%;
  max-width: 450px;
}

.cookie-option {
  display: block;
  margin: 15px 0;
}

.cookie-modal-buttons {
  text-align: right;
  margin-top: 20px;
}

.cookie-modal-buttons button {
  padding: 10px 16px;
  border: none;
  border-radius: 5px;
  margin-left: 10px;
  cursor: pointer;
  font-weight: 600;
}

#save-cookie-settings {
  background: #1e3a8a;
  color: white;
}

#close-cookie-settings {
  background: #ccc;
}

/* RESPONSIVE */
@media (max-width: 600px) {
  .cookie-banner p {
    font-size: 0.9rem;
  }
}