/*
Theme Name: ak_gufler
Author: Wolfgang Schellnast
Author URI: https://www.wolfgangschellnast.com
Description: Responsive Theme for alphakanal
Version: 1.0
*/

* {
  box-sizing: border-box;
}

html {
  font-size: 18px;
  font-size: clamp(18px, 1.40625vw, 27px);
  --main-padding: 40px;
  --gap-margin: 15px;
}

body {
  font-family: "ABC", sans-serif;
  font-weight: 400;
  color: #000;
}

html,
body {
  height: 100%;
  margin: 0;
}

a {
  color: inherit;
  text-decoration: none;
}

h1 {
  font-size: 2rem;
  /* letter-spacing: -0.05em; */
  font-weight: 500;
  margin-bottom: 2rem;
}

h2 {
  font-size: 2rem;
  font-weight: 400;
}

h2.white {
  color: #fff;
}

.single-projects h2 {
  font-weight: 400;
  font-size: 1.2rem;
}

p {
  font-size: 1.1rem;
  margin: 0.7rem 0;
  line-height: 1.4;
}

.img-fluid {
  width: 100%;
  height: auto;
}

a.product-link {
  text-decoration: underline;
  margin-top: auto;
}

a.product-link:hover {
  text-decoration: none;
}

body.logo-white a.logo {
  color: white;
}

.page-template-page-home.logo-white a.info {
  color: white;
}

body.info-white a.info {
  color: white;
}

@media (max-width: 768px) {
  body.logo-white a.info {
    color: white;
  }
}

/* NAV */
nav.main {
  position: fixed;
  top: 0px;
  left: 0px;
  width: 100%;
  padding: 35px var(--main-padding) 0;

  display: flex;
  justify-content: space-between;
  z-index: 100;
}

nav.main a {
  font-size: 1.1rem;
}

nav.main a:not(.text-hover):hover {
  text-decoration: underline;
}

nav.main {
  opacity: 1;
  transition: opacity 0.3s ease;
}

nav.main.hidden {
  opacity: 0;
  pointer-events: none;
}

/* Text Hover on Logo */
.text-hover:hover {
  font-size: 0;
}

.text-hover:hover::before {
  content: attr(data-hover);
  font-size: 1.1rem;
}

/* Sections */
section {
  position: relative;
  min-height: 100dvh;
  display: flex;
  align-items: center;
  justify-content: center;

  /* jitter fix 
  will-change: transform;*/
}

section.header {
  overflow: hidden;
}

picture.bg {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: -1; /* Pushes it behind your content */

  /* IOS FIX */
  -webkit-touch-callout: none;
  -webkit-user-select: none;
  user-select: none;

  pointer-events: none; /* Ignores long-press entirely */
}

picture.bg img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;

  /* IOS FIX */
  -webkit-touch-callout: none;
  -webkit-user-select: none;
  user-select: none;
  pointer-events: none; /* Ignores long-press entirely */
}

section.description {
  display: grid;
  grid-template-columns: 1fr 1.2fr;
}

section.description.reversed {
  display: grid;
  grid-template-columns: 1.2fr 1fr;
}

section.description picture {
  display: block;
  width: 100%;
  height: 100%;
  overflow: hidden;
}

section.description picture img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  display: block;
}

section.galerie {
  position: relative;
  height: 100dvh;
  overflow: hidden;
  display: block;
}

.text-container {
  padding: 19vh 10vw 65px 70px;
  display: flex;
  flex-flow: column;
  justify-content: space-between;
  height: 100%;
  min-height: 500px;
}

.text-container.text-center {
  justify-content: center;
}

.title-container {
  padding: 85px var(--main-padding);
  text-align: center;
}

.text-container-single {
  /* padding: 85px 17%; */
  padding: 160px 17%;
  text-align: center;
}

.projects-nav {
  display: flex;
  /* justify-content: space-between; */
  justify-content: center;
  gap: 1.5rem;
  padding: 70px var(--main-padding);
  font-size: 1.1rem;
}

/* no top padding on marquee on single-projects page */
body.single-projects footer {
  padding-top: 0;
}

section.h100 {
  min-height: 100dvh;
  height: auto;
}

section.h100 .text-container {
  padding: 19vh 10vw 19vh 70px;
}

section.full-img {
  width: 100%;
  min-height: unset;
  height: 100dvh;
  overflow: hidden;
}

section.full-img picture {
  display: flex;
  width: 100%;
}

section.imprint-full {
  display: flex;
  flex-flow: column;
  justify-content: flex-start;
  align-items: flex-start;

  padding: 100px var(--main-padding) 0 0;
}

section.imprint-full div.inner {
  flex: 1;
  display: flex;
  justify-content: center;
  flex-flow: column;
  width: 50%;
  min-width: 320px;
  padding-left: var(--main-padding);
}

body.single-projects section,
body.page-id-7 section,
.title-container {
  margin-bottom: var(--gap-margin);
}

body.single-projects section:last-of-type,
body.page-id-7 section:last-of-type {
  margin-bottom: 0;
}

/* Embla Carousel Styles */
.embla {
  overflow: hidden;
  width: 100%;
  height: 100%;
  z-index: 0;
}

.embla__viewport {
  overflow: hidden;
  width: 100%;
  height: 100%;
}

.embla__container {
  display: flex;
  height: 100%;
  will-change: transform;
  margin-left: 0px;
  margin-right: var(--gap-margin);
}

.embla__slide {
  flex: 0 0 auto;
  height: 100%;
  display: flex;
  align-items: center;
  margin-right: var(--gap-margin);
}

.embla__img {
  width: auto;
  height: 100%;
  object-position: center;
  display: block;
}

section.galerie .galerie-counter {
  position: absolute;
  bottom: var(--main-padding);
  left: var(--main-padding);
  font-size: 1rem;
  color: #000;
  z-index: 1;
}

/* GSAP */
/* Basic reset */
body {
  margin: 0;
  padding: 0;
  overflow-x: hidden;
}

#smooth-wrapper {
  overflow-x: hidden;
  /*
  position: fixed;
  height: 100%;
  width: 100%;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0; */
}

#smooth-content {
  overflow: visible;
  width: 100%;

  /* jitter fix */
  will-change: transform;
}

/* MARQUEE ELEMENT */
.marquee-wrapper {
  width: 100%;
  overflow: hidden;
  padding: 0;
  font-family: sans-serif;
}

.marquee-content {
  display: flex;
  width: max-content; /* Critical: shrink-wraps the items */
  animation: scroll-left 25s linear infinite;
}

.marquee-wrapper:hover .marquee-content {
  animation-play-state: paused;
  cursor: pointer;
}

.marquee-item {
  white-space: nowrap;
  font-size: 1rem;
}

.marquee-item span {
  display: inline-block;
  margin: 0 1rem;
}

@keyframes scroll-left {
  0% {
    transform: translateX(0);
  }
  100% {
    /* Move exactly half the total width of the content container */
    transform: translateX(-50%);
  }
}

@media (prefers-reduced-motion: reduce) {
  .marquee-content {
    animation: none;
    white-space: normal;
  }
}

@media (max-width: 768px) {
  html {
    --main-padding: 30px;
  }

  .page-template-page-home h2 {
    font-size: 1.8rem;
  }

  section.description,
  section.description.reversed {
    height: unset;
    grid-template-columns: 1fr;
  }

  section {
    min-height: 100svh;
  }

  section.h100 {
    max-height: unset;
  }

  .text-container,
  section.h100 .text-container,
  .text-container-single {
    padding: var(--main-padding) var(--main-padding) 40px;
    min-height: unset;
    text-align: left;
  }

  .title-container p br,
  .text-container-single p br {
    display: none;
  }

  a.product-link {
    margin-top: 1.5rem;
  }

  section.galerie {
    height: 60vh;
    min-height: unset;
  }

  section.full-img {
    min-height: unset;
    height: auto;
  }

  section.imprint-full div.inner {
    width: 100%;
  }

  .projects-nav {
    justify-content: space-between;
    gap: unset;
  }

  /* EMBLA CAROUSEL */
  .embla__container {
    margin-right: 15px;
  }

  .embla__slide {
    margin-right: 15px;
  }

  section.header.has-mobile-img {
    height: auto;
    min-height: unset;
  }

  section.header.has-mobile-img picture.bg {
    position: relative;
    height: auto;
  }

  section.header.has-mobile-img picture.bg img {
    height: auto;
    object-fit: contain;
    display: flex;
  }
}

/* FOOTER */
footer {
  padding: 33px 0;
  font-size: 20px;
}

/* FONTS */
@font-face {
  font-display: block;
  font-family: "ABC";
  src:
    url(fonts/ABCMonumentGrotesk-Medium.woff2) format("woff2"),
    url(fonts/ABCMonumentGrotesk-Medium.woff) format("woff");

  font-weight: 500;
  font-style: normal;
}

@font-face {
  font-display: block;
  font-family: "ABC";
  src:
    url(fonts/ABCMonumentGrotesk-Regular.woff2) format("woff2"),
    url(fonts/ABCMonumentGrotesk-Regular.woff) format("woff");

  font-weight: 400;
  font-style: normal;
}
