/* ========================================
   FM IT Consulting - Stylesheet
   ======================================== */

/* Fonts */
@font-face {
  font-family: 'Roboto';
  src: url('../assets/fonts/Roboto-Light.woff2') format('woff2');
  font-weight: 300;
  font-style: normal;
  font-display: swap;
}

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

/* CSS Variables / Design Tokens */
:root {
  --color-primary: #0eb2c2;
  --color-bg-dark: #202325;
  --color-bg-dark-end: #363c3e;
  --color-bg-footer: #404040;
  --color-text-light: #bfbfbf;
  --color-white: #ffffff;

  --font-heading: 'Roboto', sans-serif;
  --font-paragraph: 'Roboto', sans-serif;
  --font-button: 'Roboto', sans-serif;

  --fs-h1: 5rem;        /* 80px */
  --fs-h2: 2.75rem;     /* 44px */
  --fs-h3: 2.25rem;     /* 36px */
  --fs-h6: 1.5rem;      /* 24px */
  --fs-paragraph: 1.25rem;   /* 20px */
  --fs-paragraph-sm: 1rem;   /* 16px */
  --fs-button: 1.25rem;      /* 20px */
  --fs-display: 3.25rem;     /* 52px */

  --border-radius: 1.5rem;
  --border-width: 0.125rem;

  --spacing-section: 7.5rem;    /* 120px - gap between sections */
  --spacing-inner: 3.75rem;     /* 60px - gap between title and content (half of section) */
  --spacing-page-x: 2.75rem;   /* horizontal page padding */

  --fill-0: #0eb2c2;
}

/* Reset */
*,
*::before,
*::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  font-size: 16px;
  color-scheme: dark;
}

body {
  font-family: var(--font-paragraph);
  font-weight: 300;
  color: var(--color-text-light);
  background: linear-gradient(to right, var(--color-bg-dark), var(--color-bg-dark-end) 86%);
  line-height: 1.5;
  overflow-x: hidden;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

a {
  text-decoration: none;
  color: inherit;
}

h1,
h2,
h3,
h4 {
  text-wrap: balance;
}

.skip-link {
  position: absolute;
  top: 1rem;
  left: 1rem;
  z-index: 200;
  padding: 0.75rem 1rem;
  border: var(--border-width) solid var(--color-primary);
  border-radius: 0.75rem;
  background-color: var(--color-bg-dark);
  color: var(--color-white);
  transform: translateY(-200%);
  transition: transform 0.2s ease;
}

.skip-link:focus-visible {
  transform: translateY(0);
}

a:focus-visible {
  outline: var(--border-width) solid var(--color-primary);
  outline-offset: 0.25rem;
}

/* ========================================
   Header
   ======================================== */
.header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-right: 3.5rem;
  width: 100%;
  position: relative;
  z-index: 100;
}

.header__logo {
  display: block;
  padding: 1.5rem 1.5rem 1.5rem 2.5rem;
}

.header__logo-img {
  height: 8rem;
  width: auto;
}

.header__nav {
  display: flex;
  gap: 3.5rem;
  align-items: center;
}

.header__nav-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  touch-action: manipulation;
  transition: opacity 0.3s ease;
}

.header__nav-icon img {
  height: 1.75rem;
  width: auto;
}

.header__nav-icon:hover {
  opacity: 0.7;
}

/* ========================================
   Hero
   ======================================== */
.hero {
  width: 100%;
  height: 52.5rem;
  position: relative;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
}

.hero__image-wrapper {
  position: absolute;
  inset: 0;
  overflow: hidden;
}

.hero__image-wrapper img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.hero__content {
  position: absolute;
  bottom: 6.5rem;
  left: 3rem;
  display: flex;
  flex-direction: column;
  gap: 2rem;
  max-width: 80%;
}

.hero__title-wrapper {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  padding-bottom: 1rem;
}

.hero__title {
  font-family: var(--font-heading);
  font-weight: 300;
  font-size: var(--fs-h1);
  line-height: 1.5;
  color: var(--color-white);
  white-space: normal;
  max-inline-size: 22ch;
}

/* ========================================
   Section Spacing
   ======================================== */
.section {
  margin-top: var(--spacing-section);
}

.section-title {
  font-family: var(--font-heading);
  font-weight: 300;
  font-size: var(--fs-h2);
  line-height: 1.5;
  color: var(--color-primary);
  opacity: 0.9;
  padding: 0 var(--spacing-page-x);
  margin-bottom: var(--spacing-inner);
}

/* ========================================
   Section: Text-Bild (H2 + Beschreibung)
   ======================================== */
.text-bild {
  display: flex;
  gap: 5rem;
  align-items: flex-start;
  padding: 0 var(--spacing-page-x);
  width: 100%;
}

.text-bild__image {
  flex: 1;
  min-width: 0;
}

.text-bild__image img {
  width: 100%;
  height: auto;
  display: block;
}

.text-bild__content {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
}

.text-bild__text {
  font-size: var(--fs-paragraph);
}

.text-bild__text p {
  margin-bottom: 1.25rem;
}

.text-bild__text p:last-child {
  margin-bottom: 0;
}

/* ========================================
   Section: Team
   ======================================== */
.team {
  display: flex;
  gap: 3rem;
  padding: 0 var(--spacing-page-x);
}

.team__card {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: 3rem 2rem;
  border-radius: var(--border-radius);
  background: rgba(255, 255, 255, 0.03);
}

.team__avatar {
  width: 12rem;
  height: 12rem;
  border-radius: 50%;
  overflow: hidden;
  margin-bottom: 2rem;
}

.team__avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.team__name {
  font-family: var(--font-heading);
  font-weight: 300;
  font-size: var(--fs-h6);
  color: var(--color-primary);
  margin-bottom: 1.25rem;
}

.team__text {
  font-size: var(--fs-paragraph);
  line-height: 1.5;
}

/* ========================================
   Section: Leistungen (Services Grid)
   ======================================== */
.leistungen {
  padding: 0 var(--spacing-page-x);
  width: 100%;
}

.leistungen__grid {
  display: flex;
  gap: 2rem;
  align-items: flex-start;
  margin-bottom: 3rem;
}

.leistungen__grid:last-child {
  margin-bottom: 0;
}

.leistungen__item {
  display: flex;
  gap: 2rem;
  align-items: flex-start;
  flex: 1;
  min-width: 0;
}

.leistungen__icon {
  width: 5rem;
  height: 5rem;
  flex-shrink: 0;
  border-radius: 0.5rem;
  overflow: hidden;
}

.leistungen__icon img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.leistungen__item-content {
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
  line-height: 1.5;
}

.leistungen__item-title {
  font-family: var(--font-heading);
  font-weight: 300;
  font-size: var(--fs-h6);
  color: var(--color-primary);
}

.leistungen__item-text {
  font-size: var(--fs-paragraph);
}

/* ========================================
   Section: CTA (with background image)
   ======================================== */
.cta {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 3rem;
  align-items: center;
  justify-content: center;
  padding: 8rem var(--spacing-page-x);
  overflow: hidden;
}

.cta__bg {
  position: absolute;
  inset: 0;
  z-index: 0;
}

.cta__bg img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.cta__bg::after {
  content: '';
  position: absolute;
  inset: 0;
  background: rgba(32, 35, 37, 0.6);
}

.cta__text {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
  align-items: center;
  text-align: center;
  max-width: 75rem;
  width: 100%;
  font-family: var(--font-heading);
  font-weight: 300;
  color: var(--color-white);
  line-height: 1.5;
}

.cta__subtitle {
  font-size: var(--fs-h3);
}

.cta__title {
  font-size: var(--fs-display);
}

.cta__description {
  font-size: var(--fs-h3);
}

.cta__buttons {
  position: relative;
  z-index: 1;
  display: flex;
  gap: 3rem;
  align-items: center;
  justify-content: center;
}

.cta__btn {
  display: flex;
  gap: 1rem;
  align-items: center;
  justify-content: center;
  padding: 1.25rem 2.5rem;
  border: var(--border-width) solid var(--color-primary);
  border-radius: var(--border-radius);
  background: transparent;
  cursor: pointer;
  touch-action: manipulation;
  transition: background-color 0.3s ease;
}

.cta__btn:hover {
  background-color: rgba(14, 178, 194, 0.15);
}

.cta__btn-icon {
  display: flex;
  align-items: center;
  justify-content: center;
}

.cta__btn-icon img {
  height: 1.5rem;
  width: auto;
}

.cta__btn-text {
  font-family: var(--font-button);
  font-weight: 400;
  font-size: var(--fs-button);
  color: var(--color-white);
  white-space: nowrap;
}

/* ========================================
   Footer Main
   ======================================== */
.footer-main {
  display: flex;
  gap: 5rem;
  align-items: flex-start;
  padding: 4rem var(--spacing-page-x);
  width: 100%;
}

.footer-main__logo {
  flex-shrink: 0;
}

.footer-main__logo-img {
  height: 8rem;
  width: auto;
}

.footer-main__info {
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}

.footer-main__company {
  font-size: var(--fs-h6);
  color: var(--color-primary);
}

.footer-main__address {
  font-style: normal;
  font-size: var(--fs-paragraph-sm);
}

.footer-main__address p + p {
  margin-top: 1rem;
}

.footer-main__address a {
  color: var(--color-primary);
  transition: opacity 0.3s ease;
}

.footer-main__address a:hover {
  opacity: 0.7;
}

/* ========================================
   Footer Bottom
   ======================================== */
.footer-bottom {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1.5rem var(--spacing-page-x);
  width: 100%;
  background-color: var(--color-bg-footer);
}

.footer-bottom__text {
  font-family: var(--font-paragraph);
  font-weight: 300;
  font-size: 0.875rem;
  line-height: 1.5;
  color: var(--color-text-light);
  text-align: center;
}

.footer-bottom__text a {
  color: var(--color-text-light);
  transition: color 0.3s ease;
}

.footer-bottom__text a:hover {
  color: var(--color-primary);
}

/* ========================================
   Legal Content (Impressum, Datenschutz)
   ======================================== */
.legal-content {
  padding: 0 var(--spacing-page-x);
  max-width: 60rem;
  font-family: var(--font-paragraph);
  font-weight: 300;
  font-size: var(--fs-paragraph);
  line-height: 1.7;
  color: var(--color-text-light);
}

.legal-content h3 {
  font-family: var(--font-heading);
  font-weight: 300;
  font-size: var(--fs-h6);
  color: var(--color-primary);
  margin-top: 2.5rem;
  margin-bottom: 1rem;
}

.legal-content h4 {
  font-family: var(--font-heading);
  font-weight: 300;
  font-size: var(--fs-paragraph);
  color: var(--color-primary);
  opacity: 0.8;
  margin-top: 1.5rem;
  margin-bottom: 0.75rem;
}

.legal-content p {
  margin-bottom: 1rem;
}

.legal-content ul {
  margin-bottom: 1rem;
  padding-left: 1.5rem;
}

.legal-content li {
  margin-bottom: 0.25rem;
}

.legal-content a {
  color: var(--color-primary);
  text-decoration: underline;
  text-underline-offset: 0.15em;
}

/* ========================================
   Responsive
   ======================================== */
@media (max-width: 75rem) {
  :root {
    --fs-h1: 3.5rem;
    --fs-h2: 2rem;
    --fs-h3: 1.75rem;
    --fs-h6: 1.25rem;
    --fs-paragraph: 1.0625rem;
    --fs-paragraph-sm: 0.9375rem;
    --fs-button: 1.0625rem;
    --fs-display: 2.25rem;
    --spacing-section: 5rem;
    --spacing-inner: 2.5rem;
  }

  .hero {
    height: 30rem;
  }

  .hero__content {
    max-width: 90%;
  }

  .text-bild {
    gap: 3rem;
  }

  .leistungen__grid {
    flex-wrap: wrap;
  }

  .leistungen__item {
    flex: 0 0 calc(50% - 1rem);
  }

  .header__logo-img {
    height: 6rem;
  }

  .header__logo {
    padding: 1.25rem 1.25rem 1.25rem 2rem;
  }

  .footer-main__logo-img {
    height: 6rem;
  }
}

@media (max-width: 48rem) {
  :root {
    --fs-h1: 2.5rem;
    --fs-h2: 1.75rem;
    --fs-h3: 1.375rem;
    --fs-h6: 1.125rem;
    --fs-paragraph: 1rem;
    --fs-paragraph-sm: 0.875rem;
    --fs-button: 1rem;
    --fs-display: 1.75rem;
    --spacing-section: 3.5rem;
    --spacing-inner: 1.75rem;
    --spacing-page-x: 1.25rem;
  }

  .header {
    padding-right: var(--spacing-page-x);
  }

  .header__logo {
    padding: 1rem;
  }

  .header__logo-img {
    height: 4rem;
  }

  .footer-main__logo-img {
    height: 4rem;
  }

  .header__nav {
    gap: 1.5rem;
  }

  .header__nav-icon img {
    height: 1.25rem;
  }

  .hero {
    height: 22rem;
  }

  .hero__content {
    bottom: 2rem;
    left: var(--spacing-page-x);
    right: var(--spacing-page-x);
    max-width: none;
  }

  .text-bild {
    flex-direction: column;
    gap: 2rem;
  }

  .leistungen__grid {
    flex-direction: column;
  }

  .leistungen__item {
    flex: 1;
  }

  .team {
    flex-direction: column;
  }

  .team__avatar {
    width: 8rem;
    height: 8rem;
  }

  .cta {
    padding: 4rem var(--spacing-page-x);
  }

  .cta__buttons {
    flex-direction: column;
    gap: 1rem;
  }

  .footer-main {
    flex-direction: column;
    gap: 2rem;
  }
}
