/* ============================================
   Prävalenzerhebung - Main Stylesheet
   ============================================ */

/* --------------------------------------------
   1. FONTS & BASE STYLES
   -------------------------------------------- */

@font-face {
  font-family: 'Area Normal';
  src: url('../assets/fonts/AreaNormal.woff2') format('woff2');
  font-weight: normal;
  font-style: normal;
  font-display: swap;
}

body {
  font-family: 'Area Normal', -apple-system, BlinkMacSystemFont, sans-serif;
  color: #212124;
  margin: 0;
  padding: 0;
}

/* --------------------------------------------
   2. UTILITY CLASSES
   -------------------------------------------- */

.text-accent {
  color: #3c76fb;
}

.section-spacing {
  padding: clamp(2rem, 5vw, 4rem) 0;
}

/* --------------------------------------------
   3. HERO SECTION
   -------------------------------------------- */

.hero-section {
  background: linear-gradient(to bottom, #f5faff, #C7D7FA);
  height: 100vh;
  height: 100dvh;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  position: relative;
  padding: 1rem;
  overflow: hidden;
}

.hero-text {
  text-align: center;
  margin-top: auto;
  margin-bottom: auto;
  flex-grow: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
}

.hero-text h1 {
  font-size: clamp(2.5rem, 8vw, 5rem);
  line-height: 1.1;
  font-weight: 800;
  margin-bottom: 0.5rem;
}

.hero-text .lead {
  font-size: clamp(1rem, 3vw, 1.4rem);
  font-weight: bold;
  margin-top: 0.5rem;
}

.project-subline {
  position: absolute;
  right: 1rem;
  bottom: 5rem;
  text-align: right;
  font-size: clamp(1rem, 2.5vw, 1.4rem);
}

.chevron-wrapper {
  text-align: center;
  padding-bottom: 1rem;
  flex-shrink: 0;
}

.chevron-wrapper img {
  width: clamp(50px, 10vw, 100px);
}

/* --------------------------------------------
   4. HEADER & NAVIGATION
   -------------------------------------------- */

.header-bar {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: clamp(1rem, 3vw, 2rem);
  padding-top: 1rem;
  flex-wrap: nowrap;
  flex-shrink: 0;
}

.header-bar .logo {
  height: clamp(60px, 10vw, 110px);
  width: auto;
}

.header-bar .bar-text {
  font-size: clamp(1rem, 2.2vw, 1.3rem);
  font-weight: 600;
  padding: 0 1.25rem;
  border-left: 2px solid #21212430;
  border-right: 2px solid #21212430;
  text-align: center;
  line-height: 1.3;
  white-space: nowrap;
}

.nav-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  width: 100%;
}

/* Desktop Navigation */
nav ul.nav {
  justify-content: center !important;
  flex-wrap: wrap;
  gap: 0.5rem;
}

nav ul.nav li a {
  font-weight: 500;
  font-size: clamp(0.9rem, 2.5vw, 1.3rem);
  white-space: nowrap;
  padding: 0.5rem 1rem;
  text-align: center;
  border-radius: 0.5rem;
  transition: background-color 0.3s ease;
}

nav ul.nav li a:hover {
  background-color: rgba(60, 118, 251, 0.1);
}

/* --------------------------------------------
   5. MOBILE NAVIGATION
   -------------------------------------------- */

.hamburger-btn {
  display: none;
  background: none;
  border: none;
  flex-direction: column;
  cursor: pointer;
  padding: 0.5rem;
  position: relative;
  z-index: 1001;
}

.hamburger-line {
  width: 25px;
  height: 3px;
  background-color: #212124;
  margin: 2px 0;
  transition: all 0.3s ease;
  border-radius: 2px;
}

.hamburger-btn.active .hamburger-line:nth-child(1) {
  transform: rotate(45deg) translate(5px, 5px);
}

.hamburger-btn.active .hamburger-line:nth-child(2) {
  opacity: 0;
}

.hamburger-btn.active .hamburger-line:nth-child(3) {
  transform: rotate(-45deg) translate(7px, -6px);
}

.mobile-nav-overlay {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.8);
  z-index: 1000;
  opacity: 0;
  transition: opacity 0.3s ease;
  pointer-events: none;
}

.mobile-nav-overlay.active {
  opacity: 1;
  pointer-events: auto;
}

.mobile-nav-menu {
  position: fixed;
  top: 0;
  right: -100%;
  width: 280px;
  height: 100%;
  background: linear-gradient(to bottom, #f5faff, #ffffff);
  box-shadow: -2px 0 10px rgba(0, 0, 0, 0.1);
  z-index: 1001;
  transition: right 0.3s ease;
  padding: 4rem 2rem 2rem 2rem;
  overflow-y: auto;
}

.mobile-nav-menu.active {
  right: 0;
}

.mobile-nav-menu ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

.mobile-nav-menu ul li {
  margin-bottom: 1rem;
}

.mobile-nav-menu ul li a {
  display: block;
  padding: 1rem;
  color: #212124;
  text-decoration: none;
  font-weight: 500;
  font-size: 1.1rem;
  border-radius: 0.5rem;
  transition: all 0.3s ease;
  background-color: rgba(255, 255, 255, 0.7);
}

.mobile-nav-menu ul li a:hover {
  background-color: #3c76fb;
  color: white;
  transform: translateX(5px);
}

/* --------------------------------------------
   6. INFO SECTION
   -------------------------------------------- */

.info-headline {
  color: #3c76fb;
  font-size: clamp(1.2rem, 3vw, 1.5rem);
  font-weight: bold;
}

.info-paragraph {
  font-size: clamp(1rem, 2.5vw, 1.2rem);
}

/* --------------------------------------------
   7. METHODEN SECTION
   -------------------------------------------- */

.methoden-section {
  background: linear-gradient(to bottom, #f5faff, #C7D7FA);
  padding: clamp(3rem, 8vw, 6rem) 1rem;
}

.methoden-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 2rem;
  align-items: center;
}

.methoden-box {
  background-color: white;
  border-radius: 1rem;
  padding: clamp(1.5rem, 4vw, 2rem);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.08);
  font-size: clamp(1rem, 2.5vw, 1.2rem);
}

.methoden-box p {
  margin-bottom: 1rem;
}

.methoden-title,
.leistungen-title {
  font-size: clamp(2rem, 6vw, 3rem);
  font-weight: 700;
  color: #3c76fb;
  text-align: center;
}

/* --------------------------------------------
   8. LEISTUNGEN SECTION
   -------------------------------------------- */

.leistungen-section {
  background-color: #ffffff;
  padding: clamp(3rem, 6vw, 5rem) 1rem;
}

.leistungen-box {
  background-color: #f5faff;
  border-radius: 1rem;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.05);
  padding: clamp(2rem, 5vw, 3rem);
}

.leistungen-box p {
  font-size: clamp(1rem, 2.2vw, 1.1rem);
  margin-bottom: 1rem;
}

/* --------------------------------------------
   9. TEILNAHME SECTION
   -------------------------------------------- */

.teilnahme-section {
  background: linear-gradient(to bottom right, #e9f1ff, #ffffff);
  padding: clamp(3rem, 6vw, 5rem) 1rem;
}

.teilnahme-title {
  color: #3c76fb;
  font-weight: 700;
  font-size: clamp(1.5rem, 4vw, 2rem);
  text-transform: uppercase;
}

.teilnahme-text {
  font-size: clamp(1.1rem, 3vw, 1.25rem);
  font-weight: 500;
  color: #212124;
}

/* --------------------------------------------
   10. VIDEO SECTION
   -------------------------------------------- */

.video-section {
  padding: clamp(3rem, 6vw, 5rem) 1rem;
}

.video-title {
  font-size: clamp(2rem, 5vw, 2.5rem);
  font-weight: 800;
}

.video-thumbnail {
  max-width: 100%;
  width: 100%;
}

.video-thumbnail img {
  max-width: 100%;
  height: auto;
}

/* --------------------------------------------
   11. DOWNLOADS SECTION
   -------------------------------------------- */

.downloads-section {
  background: linear-gradient(to bottom right, #e9f1ff, #ffffff);
  padding: clamp(3rem, 6vw, 5rem) 1rem;
}

.downloads-title {
  font-size: clamp(1.5rem, 4vw, 2rem);
  font-weight: 800;
  color: #3c76fb;
  text-transform: uppercase;
}

.downloads-subtitle {
  font-size: clamp(1.2rem, 3vw, 1.5rem);
  font-weight: 700;
  margin-bottom: 1rem;
}

.download-link {
  font-weight: 500;
  text-decoration: underline;
  color: #212124;
  display: inline-block;
  font-size: clamp(0.9rem, 2.2vw, 1rem);
}

.download-link:hover {
  color: #3c76fb;
  text-decoration: none;
}

/* --------------------------------------------
   12. FAQ SECTION
   -------------------------------------------- */

.faq-section {
  padding: clamp(3rem, 6vw, 5rem) 1rem;
}

.faq-title {
  font-size: clamp(2rem, 5vw, 2.5rem);
  font-weight: 800;
}

/* Accordion customizations - keep Bootstrap defaults intact */
.accordion-button {
  font-size: clamp(0.9rem, 2.2vw, 1rem) !important;
  padding: clamp(0.75rem, 2vw, 1rem) !important;
  cursor: pointer !important;
  -webkit-tap-highlight-color: rgba(0, 0, 0, 0.1);
}

.accordion-button:not(.collapsed) {
  cursor: pointer !important;
}

.accordion-body {
  font-size: clamp(0.9rem, 2.2vw, 1rem);
}

.accordion-header {
  cursor: pointer !important;
}

/* --------------------------------------------
   13. KONTAKT SECTION
   -------------------------------------------- */

.kontakt-section {
  background-color: #f2f2f2;
  padding: clamp(3rem, 6vw, 5rem) 1rem;
}

.kontakt-title {
  font-size: clamp(1.5rem, 4vw, 2rem);
  font-weight: 800;
  color: #3c76fb;
  text-transform: uppercase;
}

.kontakt-section a {
  color: #212124;
  text-decoration: underline;
  font-size: clamp(0.9rem, 2.2vw, 1rem);
}

.kontakt-section a:hover {
  color: #3c76fb;
}

.kontakt-section p {
  font-size: clamp(0.9rem, 2.2vw, 1rem);
}

/* ============================================
   14. RESPONSIVE MEDIA QUERIES
   ============================================ */

/* Mobile (max-width: 767px) */
@media (max-width: 767px) {
  .hero-section {
    height: 100vh;
    height: 100dvh; /* Dynamic viewport height for mobile browsers */
    text-align: center;
    padding: 0;
    overflow: hidden;
  }

  .hero-section .container {
    height: 100vh;
    height: 100dvh;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    padding: 1rem;
  }

  .nav-header {
    flex-shrink: 0;
    padding-top: 0;
  }

  .header-bar {
    flex-direction: column;
    align-items: center;
    gap: 0.25rem;
    padding-top: 0;
  }

  .header-bar .logo {
    height: 50px;
  }

  /* Hide second logo in header on mobile */
  .header-bar .logo:last-child {
    display: none;
  }

  .header-bar .bar-text {
    border-left: none;
    border-top: 1px solid rgba(33, 33, 36, 0.2);
    border-bottom: none;
    border-right: none;
    padding: 0.25rem 0 0 0;
    margin-bottom: 0;
    font-size: 0.85rem;
    max-width: 90%;
  }

  .hamburger-btn {
    display: flex;
    position: absolute;
    top: 1.5rem;
    right: 1rem;
  }

  .desktop-nav {
    display: none;
  }

  .mobile-nav-overlay {
    display: block;
  }

  .hero-text {
    text-align: center;
    margin: 0;
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    padding: 0;
    position: relative;
  }

  /* Add mobile logo before hero text */
  .hero-text::before {
    content: '';
    display: block;
    width: clamp(180px, 45vw, 260px);
    height: clamp(180px, 45vw, 260px);
    background-image: url('../img/logo.svg');
    background-size: contain;
    background-repeat: no-repeat;
    background-position: center;
    margin-bottom: 0.5rem;
    flex-shrink: 0;
  }

  .hero-text h1 {
    font-size: clamp(1.5rem, 6vw, 2rem);
    margin-bottom: 0.5rem;
    line-height: 1.2;
  }

  .hero-text .lead {
    margin-top: 0.25rem;
    font-size: clamp(0.9rem, 2.5vw, 1.1rem);
  }

  .project-subline {
    position: static;
    text-align: center;
    margin: 0;
    padding: 0.5rem 0;
    flex-shrink: 0;
    font-size: clamp(0.8rem, 2vw, 1rem);
  }

  .chevron-wrapper {
    margin: 0;
    padding-bottom: 1rem;
    flex-shrink: 0;
  }

  .chevron-wrapper img {
    width: 40px;
    animation: bounce 2s infinite;
  }

  @keyframes bounce {
    0%, 20%, 50%, 80%, 100% {
      transform: translateY(0);
    }
    40% {
      transform: translateY(-10px);
    }
    60% {
      transform: translateY(-5px);
    }
  }

  .methoden-grid {
    grid-template-columns: 1fr;
    text-align: center;
  }

  .methoden-box {
    order: 2;
  }

  .methoden-title {
    order: 1;
    margin-bottom: 2rem;
  }
}

/* Tablet (768px - 991px) */
@media (min-width: 768px) and (max-width: 991px) {
  .hero-text h1 {
    font-size: clamp(1.8rem, 7vw, 4rem);
    line-height: 1.1;
    font-weight: 800;
    word-break: break-word;
    hyphens: auto;
  }

  nav ul.nav li a {
    font-size: 1.1rem;
    padding: 0.5rem 0.75rem;
  }

  .hamburger-btn {
    display: none;
  }

  .mobile-nav-overlay {
    display: none;
  }
}

/* Desktop (min-width: 768px) */
@media (min-width: 768px) {
  .methoden-grid {
    grid-template-columns: 1fr 1fr;
  }

  .hamburger-btn {
    display: none;
  }

  .mobile-nav-overlay {
    display: none !important;
  }

  .desktop-nav {
    display: block;
  }
}

/* Very small screens (max-width: 480px) */
@media (max-width: 480px) {
  .hero-section {
    padding: 0.25rem;
  }

  .hero-text h1 {
    font-size: 1.6rem;
    line-height: 1.15;
  }

  .container {
    padding-left: 0.75rem;
    padding-right: 0.75rem;
  }

  .header-bar .logo {
    height: 60px;
  }

  .downloads-section .row {
    margin: 0;
  }

  .downloads-section .col-md-6 {
    padding: 1rem 0;
  }
}
