/* ===========================================
   PAGES.CSS – Kirda Solutions
   Page-specific layouts for the fused design.
   =========================================== */

/* -------------------------------------
   SECTIONS – Full viewport height
   ------------------------------------- */
.section {
  padding-bottom: 2rem; /* Add spacing at the bottom of the section */
}

/* -------------------------------------
   SIDEBAR LABELS – Sticky behavior
   Each sidebar label sticks at the top
   when its section is in view.
   ------------------------------------- */
.sticky-label {
  position: sticky;
  top: 80px; /* matches navbar height */
  display: block;
  z-index: 2;
  font-size: 0.7rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--c-muted);
}

/* -------------------------------------
   HERO – Image contained in content-col
   ------------------------------------- */
.hero {
  margin-top: 0;
  padding: 0;
  border-bottom: 1px solid var(--c-border);
}

.hero {
  min-height: 100vh;
}

/* Hero sidebar: same as other sections */
.hero-sidebar {
  display: flex;
  align-items: flex-start;
  padding-top: 100px;
}

/* Hero image area: content-col with relative positioning */
.hero__image-area {
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: center;
  overflow: hidden;
  min-height: 100vh;
}

/* Background image – covers the content-col area only */
.hero__bg-image {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: left center;
  z-index: 0;
}

/* Gradient overlay: left-side white fade for text readability */
.hero__overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 1;
  background: linear-gradient(
    to right,
    rgba(255, 255, 255, 0.92) 0%,
    rgba(255, 255, 255, 0.85) 25%,
    rgba(255, 255, 255, 0.50) 50%,
    rgba(255, 255, 255, 0.10) 70%,
    rgba(255, 255, 255, 0) 100%
  );
}

/* Texture/Pattern overlay: Kirda brand structure overlapping the image */
.hero__struktur-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-image: url('../assets/images/home/kirda_struktur.png');
  background-size: 50%;
  background-repeat: no-repeat;
  background-position: bottom right;
  z-index: 1; /* Behind cards (z: 20) and text (z: 2) */
  pointer-events: none;
  opacity: 0.8;
}

@media (min-resolution: 2dppx) {
  .hero__struktur-overlay {
    background-image: url('../assets/images/home/kirda_struktur@2x.png');
  }
}

/* Content positioned bottom-left within the content-col */
.hero__content {
  position: relative;
  z-index: 2;
  max-width: 40vw;
  padding: 8rem 2rem 6rem 2rem;
}

/* Hero headline */
.hero__headline {
  font-family: var(--font-headline);
  font-size: clamp(3rem, 5vw, 5rem);
  font-weight: 700;
  line-height: 1.05;
  letter-spacing: -0.02em;
  color: var(--c-black);
  margin-bottom: 1.5rem;
}

.hero__headline .accent {
  color: var(--brand-petrol);
}

.hero__subtext {
  font-size: 1.375rem; /* 22px */
  line-height: 1.7;
  color: var(--c-deep-gray);
  margin-bottom: 2rem;
  max-width: 100%;
}

.hero__subtext-highlight {
  font-family: var(--font-headline);
  font-weight: 800;
  text-transform: lowercase;
}

.hero__cta-cluster {
  display: flex;
  align-items: center;
  gap: 2rem;
}

/* Scroll-down chevron at bottom-center of content area */
.hero__scroll-hint {
  position: absolute;
  bottom: 2rem;
  left: 50%;
  transform: translateX(-50%);
  z-index: 3;
  color: var(--c-muted);
  transition: color 0.3s ease, transform 0.3s ease;
  animation: hero-bounce 2s ease-in-out infinite;
}

.hero__scroll-hint:hover {
  color: var(--brand-petrol);
}

@keyframes hero-bounce {
  0%, 100% { transform: translateX(-50%) translateY(0); }
  50% { transform: translateX(-50%) translateY(6px); }
}

/* -------------------------------------
   SECTION CONTENT PADDING
   ------------------------------------- */
.section-content-padded {
  padding: 8rem 2rem;
}

.section-body {
  margin-top: 2rem;
  max-width: 680px;
}

/* -------------------------------------
   CTA SECTION CONTENT
   ------------------------------------- */
.cta-section__content {
  padding: 4rem 2rem;
  display: flex;
  flex-direction: column;
  justify-content: center;
  min-height: 50vh;
}

/* -------------------------------------
   RESPONSIVE: TABLET (max 1024px)
   ------------------------------------- */
@media (max-width: 1024px) {
  .hero__content {
    max-width: 500px;
  }

  .hero__headline {
    font-size: clamp(2.5rem, 5vw, 4rem);
  }

  .hero__subtext br {
    display: none;
  }

  .hero__cta-cluster {
    flex-direction: column;
    align-items: flex-start;
  }
}

/* -------------------------------------
   RESPONSIVE: MOBILE (max 768px)
   ------------------------------------- */
@media (max-width: 768px) {
  .section {
    min-height: auto;
  }

  .hero .section-inner {
    min-height: 100svh;
  }

  .hero__image-area {
    min-height: 100svh;
  }

  .hero__overlay {
    background: linear-gradient(
      to top,
      rgba(255, 255, 255, 0.95) 0%,
      rgba(255, 255, 255, 0.85) 40%,
      rgba(255, 255, 255, 0.3) 70%,
      rgba(255, 255, 255, 0) 100%
    );
  }

  .hero__content {
    padding: 0 1.5rem 5vh 1.5rem;
    max-width: 100%;
  }

  .hero__headline {
    font-size: clamp(2.2rem, 10vw, 3.5rem);
  }

  .hero__subtext {
    font-size: 1rem;
  }

  .hero__subtext br {
    display: none;
  }

  .section-content-padded {
    padding: 2rem 1.5rem;
  }

  .cta-section__content {
    padding: 2rem 1.5rem;
    min-height: 40vh;
  }
}

/* ===========================================
   PROCESS SECTION (WIE WIR ARBEITEN)
   =========================================== */
.process-section {
  background-color: var(--color-bg-primary);
}

.process-header {
  display: flex;
  flex-direction: column;
  gap: 2rem;
  margin-bottom: 4rem;
}

@media (min-width: 900px) {
  .process-header {
    flex-direction: row;
    align-items: flex-end;
    justify-content: flex-start;
    gap: 100px;
  }
  
  .process-header__left {
    flex: 0 1 auto;
    max-width: 50%;
  }
  
  .process-header__right {
    flex: 0 0 40%;
    max-width: 40%;
    padding-top: 1rem; /* Align slightly with the headline */
  }
}

.process-header__subtext {
  font-size: 1.375rem; /* 22px */
  line-height: 1.7;
  color: var(--c-deep-gray);
}

.process-header__headline {
  color: var(--brand-dunkelgruen);
  margin-bottom: 0;
}

.process-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 3rem;
  position: relative;
}

@media (min-width: 1100px) {
  .process-grid {
    grid-template-columns: repeat(4, 1fr);
    gap: 4rem;
  }
}

@media (min-width: 600px) {
  .process-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 1100px) {
  .process-grid {
    grid-template-columns: repeat(4, 1fr);
    gap: 4rem;
  }
}

.process-step {
  display: flex;
  flex-direction: column;
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.8s ease-out, transform 0.8s ease-out;
}

.process-step.is-visible {
  opacity: 1;
  transform: translateY(0);
}

.process-step__number-row {
  display: flex;
  align-items: center;
  margin-bottom: 1.5rem;
  position: relative;
  z-index: 1; /* Keep above the continuous grid line */
}

.process-step__number {
  font-family: var(--font-headline);
  font-size: 5rem;
  font-weight: 800;
  line-height: 1;
  margin-right: 1.5rem;
  background-color: var(--color-bg-primary); /* Masks the continuous line */
  padding-right: 0.5rem;
}

/* Colors for the numbers as per design */
.process-step:nth-child(1) .process-step__number { color: var(--brand-petrol); }
.process-step:nth-child(2) .process-step__number { color: var(--brand-hellgruen); }
.process-step:nth-child(3) .process-step__number { color: var(--brand-dunkelblau); }
.process-step:nth-child(4) .process-step__number { color: var(--brand-pfirsich); }

.process-step__line {
  flex-grow: 1;
  height: 1px;
  background-color: var(--c-border);
  position: relative;
}

.process-step__line::after {
  content: "";
  position: absolute;
  right: 0;
  top: 50%;
  transform: translateY(-50%);
  width: 16px;
  height: 16px;
  border-radius: 50%;
}

/* Dots get the same color as the numbers */
.process-step:nth-child(1) .process-step__line::after { background-color: var(--brand-petrol); }
.process-step:nth-child(2) .process-step__line::after { background-color: var(--brand-hellgruen); }
.process-step:nth-child(3) .process-step__line::after { background-color: var(--brand-dunkelblau); }
.process-step:nth-child(4) .process-step__line::after { background-color: var(--brand-pfirsich); }

.process-step__title {
  font-family: var(--font-headline);
  font-size: 1.5rem;
  font-weight: 800;
  color: var(--brand-dunkelgruen);
  margin-bottom: 1rem;
  text-transform: lowercase;
}

.process-step__text {
  color: var(--c-deep-gray);
  line-height: 1.6;
}

/* ===========================================
   TEAM SECTION (WER WIR SIND)
   =========================================== */
.team-layout {
  display: flex;
  flex-direction: column;
  gap: 3rem;
}

.team-layout__image img {
  width: 100%;
  height: auto;
  display: block;
  border-radius: var(--radius-xl, 16px);
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.8s ease-out, transform 0.8s ease-out;
}

.team-layout__image img.is-visible {
  opacity: 1;
  transform: translateY(0);
}

@media (min-width: 900px) {
  .team-layout {
    flex-direction: row;
    align-items: flex-start;
    gap: 5%;
  }
  
  .team-layout__image {
    flex: 0 0 40%;
    max-width: 40%;
  }
  
  .team-layout__content {
    flex: 0 0 55%;
    max-width: 55%;
  }

/* ===========================================
   KONTAKT SECTION (Formular)
   =========================================== */
.contact-section {
  background-color: var(--brand-dunkelblau);
  color: var(--brand-weissgrau);
  position: relative;
}

.contact-layout {
  display: flex;
  flex-direction: column;
  gap: 4rem;
  position: relative;
  z-index: 2;
}

.contact-headline {
  color: var(--brand-weissgrau);
  margin-bottom: 2rem;
}

.contact-info {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.5rem;
  margin-bottom: 3rem;
  font-size: var(--text-sm);
  color: rgba(240, 243, 245, 0.8);
}

.contact-info a {
  color: inherit;
  text-decoration: none;
  transition: color var(--transition-fast);
}

.contact-info a:hover {
  color: var(--brand-hellgruen);
}

.contact-form__row {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  margin-bottom: 1rem;
}

.contact-form__input {
  width: 100%;
  padding: 1rem 1.25rem;
  border-radius: var(--radius-md, 8px);
  border: none;
  background-color: #f8f9fa; /* slightly offwhite or white */
  color: var(--c-black);
  font-family: var(--font-body);
  font-size: var(--text-base);
}

.contact-form__input::placeholder {
  color: var(--c-muted);
}

.contact-form__textarea {
  resize: vertical;
  min-height: 120px;
}

.contact-form__select {
  appearance: none;
  background-image: url('data:image/svg+xml;charset=US-ASCII,%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%22292.4%22%20height%3D%22292.4%22%3E%3Cpath%20fill%3D%22%234A637C%22%20d%3D%22M287%2069.4a17.6%2017.6%200%200%200-13-5.4H18.4c-5%200-9.3%201.8-12.9%205.4A17.6%2017.6%200%200%200%200%2082.2c0%205%201.8%209.3%205.4%2012.9l128%20127.9c3.6%203.6%207.8%205.4%2012.8%205.4s9.2-1.8%2012.8-5.4L287%2095c3.5-3.5%205.4-7.8%205.4-12.8%200-5-1.9-9.2-5.5-12.8z%22%2F%3E%3C%2Fsvg%3E');
  background-repeat: no-repeat;
  background-position: right 1.25rem top 50%;
  background-size: 0.65rem auto;
}

.contact-form__footer {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
  margin-top: 2rem;
  align-items: flex-start;
}

.contact-form__submit {
  background: transparent;
  color: var(--brand-weissgrau);
  border: 1px solid var(--brand-weissgrau);
  padding: 0.75rem 2.5rem;
  border-radius: var(--radius-full);
  font-family: var(--font-body);
  font-weight: 600;
  cursor: pointer;
  transition: all var(--transition-fast);
  white-space: nowrap;
}

.contact-form__submit:hover {
  background: var(--brand-weissgrau);
  color: var(--brand-dunkelblau);
}

.contact-form__privacy {
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
  font-size: 0.75rem;
  color: rgba(240, 243, 245, 0.7);
  line-height: 1.4;
  cursor: pointer;
}

.contact-form__privacy input {
  margin-top: 0.2rem;
  cursor: pointer;
}

.contact-form__privacy a {
  color: var(--brand-hellgruen);
  text-decoration: underline;
}

.contact-layout__image {
  width: 100%;
  height: auto;
  border-radius: var(--radius-xl, 16px);
  object-fit: cover;
}

@media (min-width: 768px) {
  .contact-info {
    grid-template-columns: 1fr 1fr;
  }
  
  .contact-form__row {
    flex-direction: row;
  }
}

@media (min-width: 1024px) {
  .contact-layout {
    flex-direction: row;
    align-items: flex-start;
    gap: 6rem;
  }
  
  .contact-layout__form-area {
    flex: 0 0 55%;
    max-width: 55%;
  }
  
  .contact-layout__image-area {
    flex: 0 0 35%;
    max-width: 35%;
  }
  
  .contact-form__footer {
    flex-direction: row;
    align-items: center;
  }
  
  .contact-form__privacy {
    max-width: 400px;
  }
  
  /* Make the image taller to match screenshot aspect ratio */
  .contact-layout__image {
    aspect-ratio: 3 / 4;
    border-radius: 40px; /* larger radius as per screenshot */
  }
}

/* ===========================================
   TEAM CARDS GRID (Kontaktseite)
   =========================================== */
.team-cards-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 3rem;
  max-width: 1000px;
  margin: 0;
}

@media (min-width: 768px) {
  .team-cards-grid {
    grid-template-columns: 1fr 1fr;
  }
}

.team-card {
  display: flex;
  flex-direction: column;
  border-radius: 30px;
  background-color: var(--brand-dunkelblau); /* Panel background */
  overflow: hidden;
  align-self: start;
}

.team-card__image-wrapper {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  overflow: hidden;
}

.team-card__image {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.team-card__overlay {
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 60%;
  background: linear-gradient(to top, rgba(0,0,0,0.8), transparent);
}

.team-card__header {
  position: absolute;
  bottom: 1.5rem;
  left: 1.5rem;
  display: flex;
  align-items: center;
  gap: 1rem;
}

.team-card__toggle {
  width: 50px;
  height: 50px;
  background-color: var(--brand-pfirsich);
  border-radius: 12px;
  display: flex;
  justify-content: center;
  align-items: center;
  border: none;
  cursor: pointer;
  color: #fff;
  transition: transform 0.3s ease;
}

.team-card__toggle--static {
  cursor: default;
}

.team-card__arrow {
  transition: transform 0.3s ease;
}

.team-card.is-open .team-card__arrow {
  transform: rotate(90deg);
}

.team-card__name {
  color: #fff;
  font-family: var(--font-display);
  font-size: 1.75rem;
  font-weight: 600;
}

.team-card__content {
  display: grid;
  grid-template-rows: 0fr;
  transition: grid-template-rows 0.3s ease;
}

.team-card.is-open .team-card__content {
  grid-template-rows: 1fr;
}

.team-card__details {
  overflow: hidden;
  padding: 0 1.5rem; 
  color: var(--brand-weissgrau);
  font-size: var(--text-sm);
  display: flex;
  flex-direction: column;
  gap: 1rem;
  transition: padding 0.3s ease;
}

.team-card.is-open .team-card__details {
  padding: 1.5rem;
}

.team-card__details a {
  color: var(--brand-hellgruen);
  text-decoration: none;
}}

/* =========================================
   LEGAL PAGES (Impressum & Datenschutz)
   ========================================= */
.legal-text {
  color: var(--brand-dunkelblau);
  font-size: 1.125rem;
}
.legal-text h2 {
  font-size: 1.75rem;
  margin-top: 3.5rem;
  margin-bottom: 1.5rem;
  color: var(--brand-dunkelblau);
  font-weight: 600;
}
.legal-text h3 {
  font-size: 1.35rem;
  margin-top: 2.5rem;
  margin-bottom: 1rem;
  color: var(--brand-dunkelblau);
  font-weight: 500;
}
.legal-text h4 {
  font-size: 1.15rem;
  margin-top: 2rem;
  margin-bottom: 1rem;
  color: var(--brand-dunkelblau);
  font-weight: 500;
}
.legal-text p {
  margin-bottom: 1.5rem;
  line-height: 1.6;
}
.legal-text a {
  color: var(--brand-dunkelblau);
  text-decoration: underline;
  transition: color 0.3s ease;
}
.legal-text a:hover {
  color: var(--brand-gruen);
}
.legal-text ul {
  margin-bottom: 1.5rem;
  padding-left: 1.5rem;
}
.legal-text li {
  margin-bottom: 0.5rem;
  line-height: 1.6;
}
