* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html,
body {
  height: 100%;
}

body {
  font-family: "Segoe UI", Tahoma, Geneva, Verdana, sans-serif;
  line-height: 1.6;
  display: flex;
  flex-direction: column;
  background-color: rgba(245, 230, 208, 0.3);
  background-image: url("../background.webp");
  background-position: center calc(100% - 5rem);
  background-size: 320px auto;
  background-repeat: no-repeat;
  background-attachment: scroll;
}

main {
  flex: 1;
}

/* Navbar */
.navbar {
  background: linear-gradient(135deg, #8b6f47 0%, #ddb094 100%);
  color: white;
  padding: 1rem 0;
  position: sticky;
  top: 0;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
  z-index: 1000;
}

.navbar-content {
  display: flex;
  justify-content: space-between;
  align-items: center;
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 2rem;
}

.nav-links {
  display: flex;
  flex: 0 0 auto;
  list-style: none;
  gap: 2rem;
}

.nav-links a {
  color: white;
  text-decoration: none;
  transition: opacity 0.3s;
  position: relative;
}

.nav-links a:hover,
.nav-links a.active {
  opacity: 0.8;
}

.nav-links a.active::after {
  content: "";
  position: absolute;
  bottom: -5px;
  left: 0;
  right: 0;
  height: 2px;
  background: white;
}

/* Language Switcher */
.language-switcher {
  display: flex;
  flex: 0 0 auto;
  gap: 0.5rem;
}

.lang-btn {
  background: rgba(255, 255, 255, 0.2);
  color: white;
  border: 1px solid white;
  padding: 0.5rem 1rem;
  border-radius: 4px;
  cursor: pointer;
  transition: all 0.3s;
  font-weight: 500;
}

.lang-btn:hover {
  background: rgba(255, 255, 255, 0.3);
}

.lang-btn.active {
  background: white;
  color: #8b6f47;
}

/* Container */
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 2rem;
}

/* Hero Section */
.hero {
  background:
    linear-gradient(90deg, rgba(80, 55, 35, 0.55), rgba(80, 55, 35, 0.08)),
    url("../markensas.avif") center 20% / cover no-repeat;
  color: white;
  padding: 0;
  display: flex;
  align-items: stretch;
  position: relative;
  overflow: hidden;
  height: auto;
  min-height: 420px;
}

.hero-logo {
  align-self: stretch;
  height: auto;
  min-height: 420px;
  width: auto;
  object-fit: contain;
  margin-right: 2rem;
  position: relative;
  z-index: 1;
  -webkit-mask-image: linear-gradient(
    to right,
    rgba(0, 0, 0, 1) 0%,
    rgba(0, 0, 0, 0.5) 70%,
    rgba(0, 0, 0, 0) 100%
  );
  mask-image: linear-gradient(
    to right,
    rgba(0, 0, 0, 1) 0%,
    rgba(0, 0, 0, 0.5) 70%,
    rgba(0, 0, 0, 0) 100%
  );
  -webkit-mask-repeat: no-repeat;
  mask-repeat: no-repeat;
  -webkit-mask-size: 100% 100%;
  mask-size: 100% 100%;
}

.hero-content {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: flex-start;
  flex: 1;
  text-align: left;
  transform: translateY(55px);
}

.hero-content h1 {
  font-size: 1.3rem;
  margin-bottom: 1rem;
  animation: fadeInDown 0.8s ease;
  text-align: left;
}

.hero-content p {
  font-size: 1.3rem;
  opacity: 0.9;
  animation: fadeInUp 0.8s ease;
  text-align: left;
}

/* Info Section */
.info-section {
  padding: 4rem 2rem;
  background: #e6d5c3;
}

.about-section {
  background: #ecdfd2;
}

.info-section p {
  font-size: 1.1rem;
  text-align: center;
  max-width: 800px;
  margin: 0 auto;
  color: #666;
}

/* Page Header */
.page-header {
  background: linear-gradient(135deg, #a0826d 0%, #8b6f47 100%);
  color: white;
  padding: 3rem 2rem;
  text-align: center;
}

.page-header h1 {
  font-size: 2.5rem;
  margin-bottom: 1rem;
}

.page-header p {
  font-size: 1.1rem;
  opacity: 0.9;
}

/* Services Section */
.services-section {
  padding: 4rem 2rem;
  background:
    linear-gradient(
      to top,
      rgba(80, 55, 35, 0.78) 0%,
      rgba(80, 55, 35, 0.32) 55%,
      rgba(80, 55, 35, 0) 100%
    ),
    url("../pexels-nati-87264186-35203058.avif") center / cover no-repeat;
}

.location-section h2 {
  font-size: 1.1rem;
  text-align: center;
  max-width: 800px;
  margin: 0 auto 1rem;
  color: #8b6f47;
  font-weight: 700;
}

.locations-intro {
  max-width: 800px;
  margin: 0 auto 2rem;
  color: #666;
  font-size: 1.1rem;
  text-align: center;
}

.city-facilities-section {
  background: #ecdfd2;
}

.city-facilities-section h2 {
  max-width: 800px;
  margin: 0 auto 1rem;
  color: #8b6f47;
  font-size: 1.5rem;
  text-align: center;
}

.city-facilities-note {
  max-width: 800px;
  margin: 0 auto 2rem;
  color: #666;
  text-align: center;
}

.facility-groups {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 2rem;
  max-width: 1000px;
  margin: 0 auto;
}

.crematoria-group {
  max-width: 1000px;
  margin: 0 auto 2rem;
  background: white;
  padding: 1.5rem;
  border-radius: 8px;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

.crematoria-group h3 {
  margin-bottom: 1rem;
  color: #8b6f47;
  font-size: 1.1rem;
  text-align: center;
}

.crematoria-group ul {
  padding-left: 1.25rem;
  color: #666;
}

.crematoria-group li + li {
  margin-top: 0.5rem;
}

.facility-group {
  background: white;
  padding: 1.5rem;
  border-radius: 8px;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

.facility-group h3 {
  margin-bottom: 1rem;
  color: #8b6f47;
  font-size: 1.1rem;
  text-align: center;
}

.facility-group ul {
  padding-left: 1.25rem;
  color: #666;
}

.facility-group li + li {
  margin-top: 0.5rem;
}

.services-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 2rem;
}

.service-card {
  background: white;
  padding: 2rem;
  border-radius: 8px;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
  transition:
    transform 0.3s,
    box-shadow 0.3s;
}

.location-section .service-card {
  font-size: 1.1rem;
  text-align: center;
  color: #666;
}

.service-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 8px 12px rgba(0, 0, 0, 0.15);
}

.service-card h3 {
  color: #8b6f47;
  margin-bottom: 1rem;
  font-size: 1.3rem;
}

.service-card p {
  color: #666;
  line-height: 1.8;
}

.service-detail-section {
  padding: 2rem 2rem 4rem;
  background: #ecdfd2;
}

.service-detail-card {
  max-width: 800px;
  margin: 0 auto;
  padding: 2rem;
  background: white;
  border-radius: 8px;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

.service-detail-card h2 {
  margin-bottom: 1rem;
  color: #8b6f47;
  font-size: 1.5rem;
}

.service-detail-card p {
  color: #666;
  line-height: 1.8;
}

/* Contact Section */
.contact-section {
  padding: 4rem 2rem;
  background:
    linear-gradient(
      to top,
      rgba(230, 213, 195, 0.95) 0%,
      rgba(230, 213, 195, 0.55) 55%,
      rgba(230, 213, 195, 0.12) 100%
    ),
    url("../pexels-leeloothefirst-7121496.avif") center / cover no-repeat;
}

.contact-wrapper {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3rem;
  align-items: start;
}

.contact-form {
  background: white;
  padding: 2rem;
  border-radius: 8px;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

.form-group {
  margin-bottom: 1.5rem;
}

.form-group label {
  display: block;
  margin-bottom: 0.5rem;
  font-weight: 600;
  color: #333;
}

.form-group input,
.form-group textarea {
  width: 100%;
  padding: 0.8rem;
  border: 1px solid #ddd;
  border-radius: 4px;
  font-family: inherit;
  font-size: 1rem;
  transition: border-color 0.3s;
}

.form-group input:focus,
.form-group textarea:focus {
  outline: none;
  border-color: #8b6f47;
  box-shadow: 0 0 0 2px rgba(139, 111, 71, 0.1);
}

.submit-btn {
  background: linear-gradient(135deg, #8b6f47 0%, #6b5344 100%);
  color: white;
  padding: 0.8rem 2rem;
  border: none;
  border-radius: 4px;
  font-size: 1rem;
  font-weight: 600;
  cursor: pointer;
  transition:
    transform 0.3s,
    box-shadow 0.3s;
  width: 100%;
}

.submit-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(139, 111, 71, 0.4);
}

.contact-info {
  background: white;
  padding: 2rem;
  border-radius: 8px;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
  display: flex;
  flex-direction: column;
  align-items: stretch;
  justify-content: center;
  gap: 1.5rem;
  text-align: center;
}

.phone-contact {
  display: flex;
  flex-direction: column;
  align-items: center;
  width: 100%;
  gap: 0.75rem;
}

.phone-link {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  width: 100%;
  padding: 0 0.75rem;
  gap: 0.75rem;
  color: #8b6f47;
  font-size: 1.15rem;
  font-weight: 600;
  text-decoration: none;
  transition:
    color 0.3s,
    transform 0.3s;
}

.phone-link:hover,
.phone-link:focus-visible {
  color: #6b5344;
  transform: translateY(-2px);
}

.phone-icon,
.mail-icon,
.whatsapp-icon {
  width: 2rem;
  height: 2rem;
  flex: 0 0 2rem;
}

.phone-contact p {
  max-width: 22rem;
  margin: 0;
  color: #666;
}

.email-link {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  width: 100%;
  padding: 0 0.75rem;
  gap: 0.75rem;
  color: #8b6f47;
  font-size: 1.15rem;
  font-weight: 600;
  text-decoration: none;
  transition:
    color 0.3s,
    transform 0.3s;
}

.email-link:hover,
.email-link:focus-visible {
  color: #6b5344;
  transform: translateY(-2px);
}

.whatsapp-link {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  width: 100%;
  padding: 0 0.75rem;
  gap: 0.75rem;
  color: #477a52;
  font-size: 1.15rem;
  font-weight: 600;
  text-decoration: none;
  transition:
    color 0.3s,
    transform 0.3s;
}

.whatsapp-link:hover,
.whatsapp-link:focus-visible {
  color: #2f5d3a;
  transform: translateY(-2px);
}

.privacy-notice {
  margin-top: 1rem;
  color: #666;
  font-size: 0.9rem;
}

#form-status {
  min-height: 1.6em;
  margin-top: 1rem;
}

#form-status.sending {
  color: #666;
}

#form-status.success {
  color: #477a52;
}

#form-status.error {
  color: #9b3d32;
}

.bold {
  font-weight: 700;
  color: #8b6f47;
  margin-bottom: 1rem;
}

/* Footer */
footer {
  background: #333;
  color: white;
  text-align: center;
  padding: 2rem;
  margin-top: auto;
}

.footer-content p {
  margin: 0;
}

.privacy-footer-link {
  color: rgba(255, 255, 255, 0.75);
  font-size: inherit;
  text-decoration: none;
  transition: color 0.3s;
}

.privacy-footer-link:hover,
.privacy-footer-link:focus-visible {
  color: white;
  text-decoration: underline;
}

/* Animations */
@keyframes fadeInDown {
  from {
    opacity: 0;
    transform: translateY(-20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Responsive Design */
@media (max-width: 768px) {
  body {
    background-size: 220px auto;
  }

  .navbar-content {
    flex-wrap: wrap;
    gap: 1rem;
  }

  .nav-links {
    order: 3;
    flex-basis: 100%;
    gap: 1rem;
    font-size: 0.9rem;
  }

  .hero {
    flex-direction: column;
    padding: 2rem 2rem;
  }

  .hero-logo {
    display: none;
  }

  .hero-content {
    align-items: center;
    text-align: center;
    padding: 0 1rem;
    transform: none;
  }

  .hero-content h1,
  .hero-content p {
    font-size: 1rem;
    text-align: center;
  }

  .page-header h1 {
    font-size: 1.8rem;
  }

  .page-header p {
    font-size: 1rem;
  }

  .services-grid {
    grid-template-columns: 1fr;
  }

  .facility-groups {
    grid-template-columns: 1fr;
  }

  .contact-wrapper {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 480px) {
  .hero {
    padding: 1rem;
  }

  .hero-content h1,
  .hero-content p {
    font-size: 0.9rem;
  }

  .page-header h1 {
    font-size: 1.3rem;
  }

  .navbar-content {
    padding: 0 1rem;
  }

  .container {
    padding: 0 1rem;
  }

  .nav-links {
    gap: 0.5rem;
  }

  .language-switcher {
    gap: 0.3rem;
  }

  .lang-btn {
    padding: 0.4rem 0.8rem;
    font-size: 0.8rem;
  }
}
