/*
 * Institut für Diversity Management – statische Übergangsseite
 * Basis: Farben/Typo aus typo3conf/ext/diversityprovider/Resources/Public/.assets/sass
 */

/* Fonts (lokal, keine externen Ressourcen)
   _______________________________________________________ */
@font-face {
  font-display: swap;
  font-family: 'Barlow';
  font-style: normal;
  font-weight: 400;
  src: url('../fonts/barlow-v12-latin-regular.woff2') format('woff2');
}
@font-face {
  font-display: swap;
  font-family: 'Barlow';
  font-style: normal;
  font-weight: 500;
  src: url('../fonts/barlow-v12-latin-500.woff2') format('woff2');
}
@font-face {
  font-display: swap;
  font-family: 'Barlow';
  font-style: normal;
  font-weight: 700;
  src: url('../fonts/barlow-v12-latin-700.woff2') format('woff2');
}

/* Tokens
   _______________________________________________________ */
:root {
  --brand: #a9c938;
  --brand-hover: #8eb51a;
  --brand-light: #f0f5e0;
  --brand-text: #577310;      /* dunkles Markengrün für Text/Links, 5.4:1 auf Weiß */
  --secondary: #898786;
  --text: #4d4d4d;
  --heading: #000;
  --gray-light: #f2f2f2;
  --border: #d9d9d9;
  --white: #fff;
  --focus: #1e0f48;
  --container: 1140px;
  --gutter: 15px;
  --font: Barlow, "Helvetica Neue", Arial, sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol";
}

/* Reset / Base
   _______________________________________________________ */
*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  font-size: 14px;
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
}

@media (min-width: 576px) {
  html { font-size: 16px; }
}

@media (min-width: 768px) {
  html { font-size: 18px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition: none !important; }
}

body {
  margin: 0;
  background: var(--white);
  color: var(--text);
  font-family: var(--font);
  font-weight: 400;
  line-height: 1.5;
}

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

h1, h2, h3, h4 {
  margin: 0 0 .75rem;
  color: var(--heading);
  font-weight: 700;
  line-height: 1.2;
}

h1, .h1 { font-size: 2rem; }
h2, .h2 { font-size: 1.75rem; }
h3, .h3 { font-size: 1.4rem; }
h4, .h4 { font-size: 1.15rem; }

@media (min-width: 768px) {
  h1, .h1 { font-size: 2.2rem; }
  h2, .h2 { font-size: 1.9rem; }
  h3, .h3 { font-size: 1.5rem; }
}

p, ul, ol, blockquote, figure {
  margin: 0 0 1rem;
}

ul {
  padding-left: 1.2em;
}

li + li {
  margin-top: .25rem;
}

strong, b {
  font-weight: 700;
}

a {
  color: var(--brand-text);
  text-decoration: underline;
  text-underline-offset: .15em;
}

a:hover {
  color: var(--heading);
}

:focus-visible {
  outline: 3px solid var(--focus);
  outline-offset: 3px;
}

.visually-hidden {
  position: absolute !important;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.skip-link {
  position: absolute;
  top: -100px;
  left: var(--gutter);
  z-index: 10;
  padding: .5rem 1rem;
  background: var(--heading);
  color: var(--white);
  font-weight: 500;
}

.skip-link:focus {
  top: var(--gutter);
  color: var(--white);
}

/* Layout
   _______________________________________________________ */
.container {
  width: 100%;
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 var(--gutter);
}

.container--narrow {
  max-width: 900px;
}

.section {
  padding: 1rem 0 1.5rem;
}

.text-center { text-align: center; }

/* Header
   _______________________________________________________ */
.page-header {
  padding: 1rem 0 0;
}

.page-header__top {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem;
}

.brand {
  display: block;
  width: 220px;
  max-width: 70vw;
}

@media (min-width: 768px) {
  .page-header { padding-top: 1.5rem; }
  .brand { width: 300px; }
}

/* Sprungnavigation (Optik wie die bisherige Hauptnavigation) */
.main-nav {
  position: sticky;
  top: 0;
  z-index: 5;
  margin-top: 1rem;
  /* weißer Streifen unter der Leiste, bleibt auch im sticky-Zustand */
  padding-bottom: .75rem;
  background: var(--white);
}

.main-nav ul {
  display: flex;
  flex-wrap: wrap;
  margin: 0;
  padding: .25rem .5rem;
  list-style: none;
  background: var(--secondary);
}

.main-nav li + li {
  margin-top: 0;
}

.main-nav a {
  display: block;
  padding: .4rem .6rem;
  color: var(--white);
  font-weight: 500;
  text-decoration: none;
  text-transform: uppercase;
}

.main-nav a:hover {
  color: var(--white);
  text-decoration: underline;
}

.main-nav a:focus-visible {
  outline-color: var(--white);
  outline-offset: -3px;
}

@media (min-width: 768px) {
  .main-nav { margin-top: 1.5rem; }
  .main-nav a { padding: .5rem .75rem; font-size: 1.05rem; }
}

/* Platz für die sticky Navigation (mobil zweizeilig) */
[id] {
  scroll-margin-top: 6rem;
}

@media (min-width: 768px) {
  [id] { scroll-margin-top: 4.5rem; }
}

.meta-nav ul {
  display: flex;
  flex-wrap: wrap;
  margin: 0;
  padding: 0;
  list-style: none;
  font-size: .85rem;
}

.meta-nav li + li {
  margin-top: 0;
}

.meta-nav li + li::before {
  content: "|";
  padding: 0 .5rem;
  color: var(--secondary);
}

.meta-nav a {
  color: #6f6d6c;
  text-decoration: none;
}

.meta-nav a:hover,
.meta-nav a[aria-current="page"] {
  color: var(--heading);
  text-decoration: underline;
}

/* Hero
   _______________________________________________________ */
.hero {
  position: relative;
  margin: 0 0 2rem;
}

.hero img {
  width: 100%;
}

.hero figcaption {
  margin: 0;
  padding: .6rem 1rem;
  background: var(--brand);
  color: var(--white);
  font-size: 1.1rem;
  font-weight: 500;
}

@media (min-width: 768px) {
  .hero figcaption {
    position: absolute;
    right: 5%;
    bottom: 12%;
    max-width: 60%;
    padding: .6rem 1.2rem;
    font-size: 1.4rem;
  }
}

/* Hinweisbox
   _______________________________________________________ */
.notice {
  margin: 0 0 2rem;
  padding: 1.25rem 1.5rem;
  border-left: 8px solid var(--brand);
  background: var(--brand-light);
}

.notice h2 {
  font-size: 1.4rem;
}

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

/* Trenner mit Signet
   _______________________________________________________ */
.divider {
  height: 1px;
  margin: 2.5rem 0 3rem;
  border: 0;
  background: var(--secondary);
  overflow: visible;
  text-align: center;
}

.divider::after {
  content: "";
  display: inline-block;
  position: relative;
  top: -15px;
  width: 60px;
  height: 30px;
  background: var(--white) url('../img/divider.svg') no-repeat center / 45px 30px;
}

.divider--brand {
  background: var(--brand);
}

/* Buttons
   _______________________________________________________ */
.btn {
  display: inline-flex;
  align-items: stretch;
  max-width: 100%;
  background: var(--brand);
  color: var(--white);
  font-weight: 500;
  line-height: 1.4;
  text-align: left;
  text-decoration: none;
  transition: background-color .2s ease-in-out;
}

.btn:hover {
  background: var(--brand-hover);
  color: var(--white);
}

.btn__label {
  padding: .45rem 1rem;
}

.btn::after {
  content: "";
  flex: 0 0 2rem;
  border-left: 1px solid var(--white);
  /* Pfeil rechts */
  background: no-repeat center / .5rem url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 8 14'%3E%3Cpath d='M1 1l6 6-6 6' fill='none' stroke='%23fff' stroke-width='1.6'/%3E%3C/svg%3E");
}

.btn--block {
  display: flex;
  width: 100%;
  justify-content: space-between;
}

.btn-row {
  margin: 1.5rem 0 0;
}

/* Text + Bild
   _______________________________________________________ */
.media {
  display: grid;
  gap: 1.5rem 2rem;
}

@media (min-width: 768px) {
  .media {
    grid-template-columns: 2fr 1fr;
    align-items: start;
  }

  .media--image-left {
    grid-template-columns: 1fr 2fr;
  }

  .media--image-left .media__image {
    order: -1;
  }
}

.image-top {
  border-top: 8px solid var(--brand);
}

.image-top img {
  width: 100%;
}

/* Kundenlogos
   _______________________________________________________ */
.logo-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1rem;
  margin: 1.5rem 0 0;
  padding: 0;
  list-style: none;
}

.logo-grid li {
  margin: 0;
  border: 1px solid var(--border);
}

@media (min-width: 576px) {
  .logo-grid { grid-template-columns: repeat(3, 1fr); }
}

@media (min-width: 992px) {
  .logo-grid { grid-template-columns: repeat(5, 1fr); gap: 1.5rem; }
}

/* Kennzahl (Wikimedia)
   _______________________________________________________ */
.stat {
  margin: 0;
  color: var(--heading);
  font-weight: 700;
  line-height: 1.1;
}

.stat__value {
  display: block;
  font-size: 5rem;
  font-weight: 500;
}

.stat__label {
  display: block;
  font-size: 1.3rem;
}

/* Karten
   _______________________________________________________ */
.cards {
  display: grid;
  gap: 1.5rem;
  margin: 1.5rem 0 0;
  padding: 0;
  list-style: none;
}

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

.cards > li {
  margin: 0;
}

.card {
  display: flex;
  flex-direction: column;
  height: 100%;
  padding: 1rem 1rem 1.25rem;
  border-top: 8px solid var(--secondary);
  background: var(--gray-light);
}

.card img {
  width: 100%;
  aspect-ratio: 3 / 2;
  object-fit: cover;
  margin-bottom: 1rem;
}

.card h3 {
  font-size: 1.4rem;
  hyphens: auto;
}

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

/* Kontaktboxen */
.card--contact {
  position: relative;
  border-top-color: var(--brand);
  background: var(--brand-light);
}

.card--contact h3 {
  padding-right: 3.5rem;
  text-transform: uppercase;
}

.card__icon {
  position: absolute;
  top: -1.9rem;
  right: 1rem;
  width: 3.5rem;
  height: 3.5rem;
  padding: .8rem;
  border-radius: 50%;
  background: var(--brand);
  fill: var(--white);
}

.card--contact .btn {
  margin-top: auto;
}

.card--contact p {
  flex: 1 0 auto;
}

/* Veranstaltungen
   _______________________________________________________ */
.banner {
  margin: 0 0 1.5rem;
}

.banner img {
  width: 100%;
}

.facts {
  padding-left: 0;
  list-style: none;
}

.facts li {
  position: relative;
  padding-left: 1.6rem;
}

.facts li::before {
  content: "";
  position: absolute;
  top: .4em;
  left: 0;
  width: .8rem;
  height: .8rem;
  background: var(--brand);
  transform: rotate(45deg);
}

.programm {
  margin: 1rem 0;
}

.programm a {
  display: block;
}

.programm figcaption {
  margin-top: .5rem;
  font-size: .9rem;
}

details {
  margin: 0 0 1.5rem;
  border: 1px solid var(--border);
}

summary {
  padding: .75rem 1rem;
  background: var(--gray-light);
  color: var(--heading);
  font-weight: 500;
  cursor: pointer;
}

.details__body {
  padding: 1rem;
}

.details__body h4 {
  margin-top: 1.25rem;
}

.details__body h4:first-child {
  margin-top: 0;
}

.event {
  margin: 2rem 0 0;
  padding: 1.5rem;
  border-top: 8px solid var(--brand);
  background: var(--gray-light);
}

.event h4 {
  font-size: 1.3rem;
}

.event__date {
  color: var(--heading);
  font-weight: 700;
}

/* Testimonials
   _______________________________________________________ */
.quote {
  margin: 0 0 2rem;
  padding: 0 0 2rem;
  border-bottom: 1px solid var(--border);
}

.quote:last-child {
  border-bottom: 0;
}

.quote blockquote {
  position: relative;
  margin: 0 0 1rem;
  padding: 0 0 0 1.5rem;
  border-left: 4px solid var(--brand);
  font-size: 1.05rem;
}

.quote blockquote p:last-child {
  margin-bottom: 0;
}

.quote figcaption {
  color: var(--brand-text);
  text-align: right;
}

.quote--image {
  display: grid;
  gap: 1.5rem;
}

.quote--image img {
  width: 160px;
}

@media (min-width: 768px) {
  .quote--image {
    grid-template-columns: 220px 1fr;
  }

  .quote--image img {
    width: 100%;
  }
}

/* Rechtstexte
   _______________________________________________________ */
.legal {
  padding: 1rem 0 3rem;
}

.legal h1 {
  margin-bottom: 1.5rem;
}

.legal h2 {
  margin-top: 2rem;
  font-size: 1.4rem;
}

.legal h3 {
  margin-top: 1.5rem;
  font-size: 1.15rem;
}

.legal a {
  overflow-wrap: anywhere;
}

.back-link {
  display: inline-block;
  margin-bottom: 1.5rem;
}

/* Footer
   _______________________________________________________ */
.page-footer {
  margin-top: 3rem;
  padding: 2rem 0;
  /* abgedunkeltes $secondary – #898786 hätte mit Weiß nur 3.6:1 */
  background: #5e5c5b;
  color: var(--white);
  font-size: .9rem;
}

.page-footer .container {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 1rem 2rem;
}

.page-footer address {
  font-style: normal;
}

.page-footer a {
  color: var(--white);
}

.page-footer ul {
  display: flex;
  flex-wrap: wrap;
  gap: .5rem 1.5rem;
  margin: 0;
  padding: 0;
  list-style: none;
}

.page-footer li + li {
  margin-top: 0;
}

/* Print
   _______________________________________________________ */
@media print {
  .skip-link, .meta-nav, .divider, .btn::after { display: none; }
  .page-footer { background: none; color: #000; }
  .page-footer a { color: #000; }
}
