/* Hero Section */
.hero-section {
  filter: none;
  background-image: url("images/Background_Logo.jpg");
  background-position: center center;
  background-size: cover;
  background-repeat: no-repeat;
  padding: 60px 0 0 0;
  margin-top: 0;
  margin-bottom: 0;
}

.hero-section .container {
  min-height: 400px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 60px 20px;
}

/* Logo animation keyframes */
@keyframes logoScaleRotate {
  0% {
    transform: scale(0) rotate(180deg);
    opacity: 0;
  }
  100% {
    transform: scale(1) rotate(0deg);
    opacity: 1;
  }
}

.hero-section .logo {
  width: 537px;
  height: 355px;
  margin: 0 auto;
  animation: logoScaleRotate 1s ease-out forwards;
  transform-origin: center center;
  display: block;
}

@media (max-width: 1199px) {
  .hero-section .container {
    min-height: 425px;
  }
}

@media (max-width: 991px) {
  .hero-section .container {
    min-height: 326px;
  }
}

@media (max-width: 767px) {
  .hero-section .container {
    min-height: 245px;
  }
}

@media (max-width: 575px) {
  .hero-section .container {
    min-height: 37px;
  }

  .hero-section .logo {
    width: 340px;
    height: 225px;
  }
}

/* Intro Section */
.intro-section {
  padding: 60px 0;
  margin-top: 0;
  margin-bottom: 0;
}

.intro-section .container {
  text-align: center;
  padding: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.intro-section .intro-heading {
  font-weight: 700;
  font-size: 1.875rem;
  line-height: 1.3;
  margin: 0 0 20px 0;
  text-align: center;
  padding: 0 20px;
}

.intro-content {
  max-width: 900px;
  margin: 0 auto;
  text-align: center;
}

.intro-section .intro-text {
  font-size: 1.125rem;
  line-height: 1.6;
  margin: 0 0 15px 0;
  padding: 0 20px;
}

.intro-section .btn-primary {
  text-transform: uppercase;
  font-size: 0.875rem;
  letter-spacing: 1px;
  font-weight: 700;
  margin: 40px auto 0 auto;
  padding: 12px 135px;
  display: flex;
  align-items: center;
  justify-content: center;
  width: fit-content;
  max-width: 100%;
  box-sizing: border-box;
  white-space: nowrap;
  background-color: var(--primary-blue);
  color: #fff;
  border: none;
  border-radius: 50px;
  cursor: pointer;
  transition: background-color 0.3s ease, transform 0.2s ease;
  text-decoration: none;
  text-align: center;
  line-height: 1;
}

.intro-section .btn-primary:hover {
  background-color: var(--primary-orange);
  transform: translateY(-2px);
}

@media (max-width: 767px) {
  .intro-section .btn-primary {
    padding: 9px 30px 11px 30px;
    width: auto;
    max-width: calc(100% - 40px);
    margin-left: auto;
    margin-right: auto;
    white-space: nowrap;
  }
}

@media (max-width: 575px) {
  .intro-section .btn-primary {
    padding: 9px 20px 11px 20px;
    max-width: calc(100% - 20px);
  }
}

/* Section Headings */
.section-heading {
  background-position: 50% 50%, 50% 50%;
  background-repeat: no-repeat, no-repeat;
  background-image: linear-gradient(to bottom, rgba(0, 0, 0, 0.5), rgba(102, 102, 102, 0.5)), linear-gradient(to bottom, rgba(0, 0, 0, 1), rgba(0, 0, 0, 1));
  background-size: cover, cover;
  padding: 0;
  margin-top: 60px;
  margin-bottom: 0;
}

.section-heading .container {
  height: 100px;
  min-height: 100px;
  text-align: center;
  display: flex;
  align-items: center;
  justify-content: center;
}

.section-title {
  font-weight: 700;
  font-size: 3.75rem;
  margin: 0;
  text-align: center;
  width: fit-content;
}

.gallery-heading .section-title {
  color: var(--primary-orange);
}

.services-heading .section-title {
  color: var(--primary-orange);
}

.contact-heading .section-title {
  color: var(--primary-orange);
}

@media (max-width: 767px) {
  .section-heading {
    margin-top: 40px;
  }

  .section-title {
    font-size: 2.8125rem;
  }

  .gallery-section {
    padding: 40px 0;
  }

  .intro-section {
    padding: 40px 0;
  }
}

@media (max-width: 575px) {
  .section-heading {
    margin-top: 30px;
  }

  .section-title {
    font-size: 2.34375rem;
  }

  .gallery-section {
    padding: 30px 0;
  }

  .intro-section {
    padding: 30px 0;
  }

  .services-detail-section {
    padding: 30px 0;
  }
}

/* Gallery Section */
.gallery-section {
  background-image: none;
  padding: 60px 0;
  margin-top: 0;
  margin-bottom: 0;
}

.gallery-divider {
  width: 440px;
  height: 14px;
  --radius: 20px;
  margin: -7px auto 0;
  background-color: var(--primary-blue);
  border-radius: var(--border-radius);
}

.gallery-grid {
  display: grid;
  grid-template-columns: repeat(4, calc(25% - 15px));
  gap: 20px;
  margin-top: 0;
  margin-bottom: 0;
  min-height: 1177px;
}

.gallery-item {
  box-shadow: 5px 5px 16px 0 rgba(0,0,0,0.3);
  filter: none;
  border-radius: var(--border-radius);
  background-color: #fff;
  padding: 0 0 8px;
  opacity: 0;
  transform: scale(0.8);
  transition: opacity 0.6s ease-out, transform 0.6s ease-out, box-shadow 0.5s, filter 0.5s;
  overflow: hidden;
}
.gallery-item.fade-in {
  opacity: 1;
  transform: scale(1);
}

.gallery-image {
  height: auto;
  margin-top: 0;
  margin-bottom: 0;
  object-position: center;
  border-radius: var(--border-radius);
  width: 100%;
  object-fit: contain;
  cursor: pointer;
  border: 8px solid #000;
  border-left: none;
  border-right: none;
  border-top: none;
  display: block;
  aspect-ratio: auto;
}

@media (max-width: 991px) {
  .gallery-image {
    cursor: default;
    pointer-events: none;
  }
}

.gallery-item-title {
  transition-duration: 0.5s;
  margin: 7px 20px 0;
  font-weight: 700;
  font-size: 1rem;
  text-align: center;
}

@media (max-width: 1199px) {
  .gallery-grid {
    grid-gap: 20px;
    min-height: 969px;
  }

  .gallery-image {
    height: auto;
  }
}

@media (max-width: 991px) {
  .gallery-grid {
    grid-template-columns: repeat(2, calc(50% - 10px));
    min-height: 2969px;
  }

  .gallery-image {
    height: auto;
  }
}

@media (max-width: 767px) {
  .gallery-grid {
    grid-template-columns: 100%;
    grid-auto-columns: 100%;
  }

  .gallery-image {
    height: auto;
  }
}

@media (max-width: 575px) {
  .gallery-divider {
    width: 340px;
  }

  .gallery-grid {
    grid-template-columns: 100%;
  }

  .gallery-image {
    height: auto;
  }

  .gallery-item-title {
    font-weight: 400;
  }
}

/* Services Detail Section */
.services-detail-section {
  padding: 60px 0;
  margin-top: 0;
  margin-bottom: 0;
}

.services-detail-section .container {
  min-height: 964px;
}

.content-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 40px;
  margin-top: 0;
  margin-bottom: 0;
  align-items: start;
}

.content-text {
  padding: 0;
}

.content-title {
  font-weight: 700;
  font-size: 3.75rem;
  margin: 0;
}

.content-title .highlight {
  color: var(--primary-orange);
}

.content-description {
  margin: 0;
  margin-top: 30px;
}

/* Services Detail Section Animations */
.services-detail-section .content-text {
  opacity: 1;
  transform: none;
}

.services-detail-section .content-text.animate-in {
  opacity: 1;
  transform: none;
}

.services-detail-section .content-image {
  opacity: 1;
  transform: none;
}

.content-image {
  display: block;
  width: 100%;
  max-width: 100%;
  height: auto;
  margin: 0;
  object-fit: contain;
  aspect-ratio: 800 / 1000;
}

/* Scale container proportionally to keep elements together */
@media (max-width: 800px) {
  .content-image {
    width: 100%;
    max-width: 100%;
    aspect-ratio: 800 / 1000;
  }
}

.image-decoration {
  position: absolute;
  width: 30.75%;
  height: 30.75%;
  top: 3.3%;
  left: 3.75%;
  background-color: var(--primary-blue);
  border-radius: 50%;
  z-index: 1;
  aspect-ratio: 1;
}

.image-main {
  position: absolute;
  width: 63.75%;
  height: 63.75%;
  top: 12.8%;
  left: 14%;
  background-image: url("images/Soldat.jpg");
  background-position: 50% 50%;
  border-radius: 50%;
  background-size: cover;
  z-index: 2;
  aspect-ratio: 1;
}

.image-secondary {
  position: absolute;
  width: 34.875%;
  height: 34.875%;
  top: 47.2%;
  left: 3.75%;
  box-shadow: 5px 5px 18px 1px rgba(0,0,0,0.4);
  background-image: url("images/Bust.jpg");
  background-position: 50% 43.51%;
  background-size: cover;
  border-radius: 50%;
  z-index: 3;
  aspect-ratio: 1;
}

.image-accent {
  position: absolute;
  width: 14.25%;
  height: 14.25%;
  top: 68.4%;
  left: 53.5%;
  background-color: var(--primary-blue);
  border-radius: 50%;
  z-index: 3;
  aspect-ratio: 1;
}

.content-grid-reverse {
  grid-template-columns: 1fr 1fr;
  margin-top: 60px;
}

.content-grid-reverse .content-image {
  order: -1;
}

.content-grid-reverse .image-decoration {
  left: auto;
  right: 0;
}

.content-grid-reverse .image-main {
  background-image: url("images/Farbregal.jpg");
  left: 0;
  right: auto;
}

.content-grid-reverse .image-secondary {
  background-image: url("images/Screenshot.jpg");
  left: auto;
  right: 0;
}

.content-grid-reverse .image-accent {
  left: 134px;
  right: auto;
}

@media (max-width: 1199px) {
  .services-detail-section .container {
    min-height: 797px;
  }

  .content-text {
    padding: 0;
  }

  .content-title {
    font-size: 3.125rem;
  }

  .image-main {
    width: 470px;
    height: 470px;
  }

  .image-secondary {
    margin-top: -99px;
  }
}

@media (max-width: 991px) {
  .services-detail-section {
    padding: 40px 0;
  }

  .services-detail-section .container {
    min-height: auto;
  }

  .content-grid {
    grid-template-columns: 1fr;
    margin-top: 0;
    margin-bottom: 0;
    gap: 20px;
  }

  .content-grid-reverse {
    margin-top: 40px;
  }

  .content-text {
    padding: 20px;
  }

  .content-title {
    font-size: 2.5rem;
    word-break: break-word;
  }

  .content-image {
    width: 100%;
    height: auto;
    aspect-ratio: 800 / 1000;
  }

  .content-grid-reverse .content-image {
    order: 2;
  }

  .content-grid-reverse .content-text {
    order: 1;
  }
}

@media (max-width: 767px) {
  .services-detail-section {
    padding: 40px 0;
  }

  .services-detail-section .container {
    min-height: auto;
  }

  .content-grid {
    margin-top: 0;
    margin-bottom: 0;
    gap: 20px;
  }

  .content-grid-reverse {
    margin-top: 40px;
  }

  .content-text {
    padding: 20px;
  }

  .content-title {
    font-size: 2.5rem;
    word-break: break-word;
    line-height: 1.2;
  }
}

@media (max-width: 575px) {
  .services-detail-section {
    padding: 30px 0;
  }

  .services-detail-section .container {
    min-height: auto;
  }

  .content-grid {
    margin-top: 0;
    margin-bottom: 0;
    gap: 20px;
  }

  .content-grid-reverse {
    margin-top: 30px;
  }

  .content-text {
    padding: 15px;
  }

  .content-title {
    font-size: 2rem;
    word-break: break-word;
    line-height: 1.2;
  }

  .content-description {
    font-size: 0.9rem;
  }
}

/* Design Section */
.design-section .container {
  min-height: 1041px;
}

.design-section .content-text {
  padding: 0;
}

.design-section .content-title {
  margin: 0;
}

/* Design Section Animations */
.design-section .content-text {
  opacity: 0;
  transform: translateX(50px);
  transition: opacity 0.8s ease-out, transform 0.8s ease-out;
}

.design-section .content-text.animate-in {
  opacity: 1;
  transform: translateX(0);
}

.design-section .content-image {
  opacity: 1;
  transform: none;
}

@media (max-width: 1199px) {
  .design-section .container {
    min-height: 945px;
  }

  .design-section .content-text {
    padding: 0;
  }

  .design-section .content-title {
    font-size: 3.125rem;
  }
}

@media (max-width: 991px) {
  .design-section .container {
    min-height: 850px;
  }

  .design-section .content-text {
    padding: 0;
  }

  .design-section .content-title {
    font-size: 2.5rem;
  }
}

@media (max-width: 767px) {
  .design-section .container {
    min-height: 991px;
  }

  .design-section .content-text {
    padding: 0;
  }

  .design-section .content-title {
    font-size: 3.125rem;
  }
}

@media (max-width: 575px) {
  .design-section .content-text {
    padding: 0;
  }

  .design-section .content-title {
    font-size: 3rem;
  }
}

/* Contact Section */
.contact-section {
  background-color: var(--primary-blue);
  padding: 0;
  margin-top: 0;
  margin-bottom: 0;
}

.section-heading#contact {
  margin-bottom: 0;
}

.section-heading + .contact-section {
  margin-top: 0;
}

.contact-section .container {
  min-height: 244px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding-top: 0;
  margin-top: 0;
}

.contact-divider {
  width: 440px;
  height: 14px;
  --radius: 20px;
  margin: -7px auto 0;
  background-color: var(--primary-orange);
  border-radius: var(--border-radius);
}

.contact-info {
  margin: 0;
  text-align: center;
  color: #fff;
  display: block;
  width: 100%;
  max-width: 100%;
}

.contact-info a {
  color: #fff;
  text-decoration: underline;
  transition: opacity 0.3s ease;
}

.contact-info a:hover {
  opacity: 0.8;
}

@media (max-width: 575px) {
  .contact-divider {
    width: 340px;
  }
}

/* Gallery Dialogs */
.gallery-dialog {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  width: 100vw;
  height: 100vh;
  min-width: 100%;
  min-height: 100%;
  background-color: rgba(0, 0, 0, 0.85);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  z-index: 10000;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transition: opacity 0.3s ease;
  margin: 0;
  padding: 0;
}

.gallery-dialog.active {
  display: flex;
  opacity: 1;
}

.dialog-content {
  position: relative;
  max-width: 98vw;
  width: auto;
  margin: 5px auto;
  max-height: 98vh;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 5px;
  transition: opacity 0.3s ease;
}

.dialog-image {
  width: auto;
  height: auto;
  max-width: 96vw;
  max-height: 96vh;
  border-radius: 16px;
  display: block;
  object-fit: contain;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5), 0 0 0 1px rgba(255, 255, 255, 0.1);
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.1) 0%, rgba(255, 255, 255, 0.05) 100%);
  padding: 2px;
  background-color: rgba(255, 255, 255, 0.05);
}

.dialog-close {
  position: absolute;
  top: 8px;
  right: 8px;
  width: 44px;
  height: 44px;
  background-color: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border: none;
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3), 0 0 0 1px rgba(0, 0, 0, 0.1);
  z-index: 10001;
  transition: all 0.2s ease;
  opacity: 0.9;
}

.dialog-close:hover {
  background-color: #fff;
  transform: scale(1.1) rotate(90deg);
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.4), 0 0 0 1px rgba(0, 0, 0, 0.15);
  opacity: 1;
}

.dialog-close:active {
  transform: scale(1.05) rotate(90deg);
}

.dialog-close svg {
  width: 20px;
  height: 20px;
  fill: #333;
  transition: fill 0.2s ease;
}

.dialog-close:hover svg {
  fill: #000;
}

@media (max-width: 1199px) {
  .dialog-content {
    max-width: 98vw;
    padding: 5px;
  }
  .dialog-image {
    max-width: 96vw;
    max-height: 96vh;
  }
}

@media (max-width: 991px) {
  .dialog-content {
    max-width: 98vw;
    padding: 5px;
  }
  .dialog-image {
    max-width: 96vw;
    max-height: 96vh;
  }
}

@media (max-width: 767px) {
  .dialog-content {
    max-width: 98vw;
    padding: 8px;
  }
  .dialog-image {
    max-width: 95vw;
    max-height: 95vh;
    border-radius: 12px;
    padding: 2px;
  }
  .dialog-close {
    top: 6px;
    right: 6px;
    width: 38px;
    height: 38px;
  }
  .dialog-close svg {
    width: 18px;
    height: 18px;
  }
}

@media (max-width: 575px) {
  .dialog-content {
    max-width: 98vw;
    padding: 6px;
  }
  .dialog-image {
    max-width: 95vw;
    max-height: 95vh;
    border-radius: 10px;
    padding: 2px;
  }
  .dialog-close {
    top: 4px;
    right: 4px;
    width: 36px;
    height: 36px;
  }
  .dialog-close svg {
    width: 16px;
    height: 16px;
  }
}

/* Impressum Section */
.impressum-section {
  padding: 60px 0;
  margin-top: 0;
  margin-bottom: 0;
}

.impressum-section .container.impressum-content {
  max-width: 900px;
  padding: 0 20px;
  margin-top: 0;
  margin-bottom: 0;
}

.impressum-section h1:first-of-type {
  text-align: center;
  margin-bottom: 30px;
}

.impressum-section h1:not(:first-of-type) {
  border-top: 2px solid #ddd;
  padding-top: 40px;
  margin-top: 40px;
  text-align: center;
}

.impressum-section h1 {
  font-weight: 700;
  font-size: 2.5rem;
  margin: 0 0 30px 0;
  color: #333;
  line-height: 1.2;
}

.impressum-section h2 {
  font-weight: 700;
  font-size: 1.75rem;
  margin: 40px 0 20px 0;
  color: #333;
  line-height: 1.3;
}

.impressum-section h3 {
  font-weight: 700;
  font-size: 1.25rem;
  margin: 30px 0 15px 0;
  color: #333;
  line-height: 1.4;
}

.impressum-section h4 {
  font-weight: 700;
  font-size: 1.125rem;
  margin: 20px 0 10px 0;
  color: #333;
  line-height: 1.4;
}

.impressum-section p {
  font-size: 0.875rem;
  line-height: 1.8;
  color: #333;
  margin: 0 0 15px 0;
  text-align: left;
}

.impressum-section ul {
  margin: 15px 0;
  padding-left: 30px;
  list-style-type: disc;
}

.impressum-section li {
  font-size: 0.875rem;
  line-height: 1.8;
  color: #333;
  margin: 0 0 10px 0;
}

.impressum-section a {
  color: var(--primary-blue);
  text-decoration: underline;
}

.impressum-section a:hover {
  color: var(--primary-blue-hover);
}

@media (max-width: 767px) {
  .impressum-section .container.impressum-content {
    padding: 0 20px;
  }
  
  .impressum-section h1 {
    font-size: 2rem;
  }
  
  .impressum-section h2 {
    font-size: 1.5rem;
  }
  
  .impressum-section h3 {
    font-size: 1.125rem;
  }
  
  .impressum-section h4 {
    font-size: 1rem;
  }
  
  .impressum-section p,
  .impressum-section li {
    font-size: 0.8125rem;
  }
}
