:root {
  --hover-width: 40%;
  --other-width: 30%;
  --btn-left-hover: rgba(131, 158, 106, 1)  ;
  --btn-center-hover: rgba(131, 158, 106, 1);
  --btn-right-hover: rgba(131, 158, 106, 1);
}

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

body, html {
  height: 100%;
  font-family: 'Segoe UI', sans-serif;
  align-content: center;
}

.container {
  width: 100%;
  height: 100%;
  display: flex;
  position: relative;
  overflow: hidden;
  gap: .5rem;
  border: .5rem solid #fff;
}

.split {
  width: 33.33%;
  height: 100%;
  position: relative;
  transition: width 1s ease;
  background-size: cover;
  background-position: center;
  overflow: hidden;
  display: flex;
  justify-content: center;
  align-items: center;
}

.split::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  height: 100%;
  width: 100%;
  background-color: rgba(0, 0, 0, 0.3); /* dunkles Overlay */
  z-index: 1;
}

.split-desc {
  position: absolute;
  z-index: 2; /* Inhalt über dem Overlay */
  top: 35%;
  left: 50%;
  transform: translateX(-50%);
  text-align: center;
}

.split__title {
  font-size: 48px;
  color: #fff;
  margin-bottom: 20px;
  text-shadow: 0 0 8px #000;
  margin-bottom: 3rem;
}

.split__btn {
  padding: 15px 40px;
  border: 2px solid #fff;
  color: #fff;
  text-decoration: none;
  transition: 0.3s;
  background-color: transparent;
}

.split--left {
  background-image: url('img/ruhewald-nottensdorf-waldfriedhof.jpg');
}

.split--center {
  background-image: url('img/ruhewald-agathenburg-waldfriedhof.webp');
}

.split--right {
  background-image: url('img/rittergut-horneburg.jpg'); 
}

/* Hover States */
.active--left .split--left {
  width: var(--hover-width);
}
.active--left .split--center,
.active--left .split--right {
  width: var(--other-width);
}

.active--center .split--center {
  width: var(--hover-width);
}
.active--center .split--left,
.active--center .split--right {
  width: var(--other-width);
}

.active--right .split--right {
  width: var(--hover-width);
}
.active--right .split--left,
.active--right .split--center {
  width: var(--other-width);
}

/* Button Hover Colors */
.active--left .split__btn--left {
  background-color: var(--btn-left-hover);
  border: none;
}

.active--center .split__btn--center {
  background-color: var(--btn-center-hover);
  border: none;
}

.active--right .split__btn--right {
  background-color: var(--btn-right-hover);
  border: none;
}

/* Responsive */
@media (max-width: 1024px) {
  .container {
    flex-direction: column;
    max-height: 100vh
  }

  .split {
    width: 100% !important;
    height: 33.33%;
    justify-content: center;
    align-items: center;
  }
  
  .split-desc {
    top: auto;
    left: auto;
    transform: none;
    position: relative;
    text-align: center;
  }

  .split__title {
    font-size: 32px;
    margin-bottom: 2rem;
  }

  .split__btn {
    padding: 10px 25px;
  }

  /* Button Hover Colors */
.split__btn--left {
  background-color: var(--btn-left-hover);
  border: none;
}

.split__btn--center {
  background-color: var(--btn-center-hover);
  border: none;
}

.split__btn--right {
  background-color: var(--btn-right-hover);
  border: none;
}
}

/* Initialer Zustand – deaktiviert Hover-Effekt */
.container.disable-hover .split {
  transition: none !important;
}