/* 1. Variablen & Fonts */
:root {
  /* Farben */
  --c-bg: #ffffff;
  --c-text: #222222; /* Dunkleres Grau für besseren Kontrast */
  --c-text-inv: #ffffff;
  --c-primary: #000000;
  --c-secondary: #f8f9fa; /* Helleres Grau */

  /* Department Colors */
  --c-dept-info: #007bff;
  --c-dept-mech: #dc3545;
  --c-dept-el: #ffc107;
  --c-dept-aut: #28a745;
  --c-dept-log: #6c757d;

  /* Fonts */
  --f-main: 'Barlow Semi Condensed', sans-serif;
  --f-title: 'Italianno', cursive;
  --f-serif: 'Cardo', serif;

  /* Layout */
  --header-height: 80px;
}

body {
  font-family: var(--f-main);
  color: var(--c-text);
  background-color: var(--c-bg);
  font-size: 18px; /* Basis-Schriftgröße erhöht */
  line-height: 1.6;
}

/* 2. Utility & Layout */
.wrapper {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 1.5rem;
}

section {
  padding: 5rem 0;
}

hr {
  border: 0;
  height: 1px;
  background: #e0e0e0;
  margin: 3rem 0;
}

.title-font {
  font-family: var(--f-main);
  text-transform: uppercase;
  letter-spacing: 3px;
  font-weight: 700; /* Dicker für bessere Lesbarkeit */
  font-size: 4.3rem;
  margin-bottom: 3rem;
  text-align: center;
  color: var(--c-primary);
}

/* 3. Header & Navigation */
header {
  background: var(--c-primary);
  color: var(--c-text-inv);
  text-align: center;
  position: relative;
  overflow: hidden;
}

.hero {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  /* Logo Pfad relativ zum CSS Ordner */
  background-image: url('../img/system/logo.png');
  width: 100%;
  background-size: contain;
  background-repeat: no-repeat;
  background-position: center;
  padding-top: var(--header-height);
  background-origin: content-box;
}

.sticky-nav {
  position: sticky;
  top: 0;
  background: rgba(0,0,0,0.95);
  z-index: 1000;
  padding: 1.2rem 0;
  backdrop-filter: blur(8px);
  border-bottom: 1px solid #333;
  box-shadow: 0 2px 10px rgba(0,0,0,0.3);
}

.nav-links {
  display: flex;
  justify-content: center;
  gap: 2.5rem;
  font-weight: 700;
  text-transform: uppercase;
  font-size: 1.1rem;
  letter-spacing: 1px;
}

.nav-links a {
  color: var(--c-text-inv);
  text-decoration: none;
  transition: color 0.2s, transform 0.2s;
}

.nav-links a:hover {
  color: #ddd;
  transform: scale(1.05);
}

/* 4. VIP Section */
.section-vip {
  font-size: 2.0rem;
  background: var(--c-primary);
  color: var(--c-text-inv);
}

.section-vip h2 {
  font-size: 3.5rem;
}

.section-vip .title-font {
  color: var(--c-text-inv);
}

/* 5. Info Section - STYLED UP & FIXED WRAPPING */

.section-info {
  background-color: var(--c-bg);
}

.info-grid {
  display: flex; /* Flexbox statt Grid für besseres Zentrieren */
  flex-wrap: wrap; /* Erlaubt Umbruch */
  justify-content: center; /* ZENTRIERT Elemente in der neuen Zeile */
  gap: 2rem;
  align-items: stretch; /* Alle Karten gleich hoch */
}

/* Karten-Design für die Info-Boxen */
.info-grid > div {
  background: var(--c-secondary); /* Heller grauer Hintergrund */
  border-radius: 16px;
  padding: 3rem 2rem;
  flex: 1 1 300px; /* Basisbreite 300px, wächst und schrumpft */
  max-width: 380px; /* Nicht zu breit werden lassen */

  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;

  box-shadow: 0 4px 20px rgba(0,0,0,0.04);
  border: 1px solid rgba(0,0,0,0.05);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

/* Hover-Effekt für Interaktivität */
.info-grid > div:hover {
  transform: translateY(-8px);
  box-shadow: 0 12px 30px rgba(0,0,0,0.1);
  border-color: rgba(0,0,0,0.1);
}

/* Icons als "Badges" stylen */
.info-grid .material-icons {
  font-size: 2.5rem;
  margin-bottom: 1.5rem;
  color: var(--c-text-inv); /* Weißes Icon */
  background-color: var(--c-primary); /* Schwarzer Kreis */
  width: 80px;
  height: 80px;
  line-height: 80px; /* Vertikal zentrieren */
  border-radius: 50%;
  display: inline-block;
  box-shadow: 0 8px 15px rgba(0,0,0,0.2);
}

/* Typografie in den Karten */
.info-grid h2 {
  font-family: var(--f-main);
  font-size: 1.8rem;
  font-weight: 700;
  margin: 0;
  color: var(--c-text);
  line-height: 1.3;
}

/* Listen-Styling (Requirements) */
.info-grid ul {
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 0.8rem;
}

.info-grid ul li {
  font-size: 1.2rem;
  color: #555;
  font-weight: 500;
  line-height: 1.4;
}

/* Links in den Infos (z.B. Einverständniserklärung) */
.info-grid a {
  color: var(--c-primary);
  text-decoration: none;
  border-bottom: 2px solid rgba(0,0,0,0.1);
  transition: border-color 0.2s;
  font-weight: 700;
}

.info-grid a:hover {
  border-bottom-color: var(--c-primary);
}

.material-icons {
  font-size: 3.5rem;
  margin-bottom: 1.5rem;
  display: block;
  color: #333;
}

.graduates-grid {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 2rem;
}

.class-card {
  background: var(--c-secondary);
  border-radius: 12px;
  padding: 2rem;
  text-align: center;
  border-top: 6px solid #ccc;
  transition: transform 0.3s, box-shadow 0.3s;
  box-shadow: 0 4px 6px rgba(0,0,0,0.05);

  flex: 0 0 100%;
  width: 100%;
}

@media (min-width: 650px) {
  .class-card {
    flex: 0 0 calc(50% - 2rem);
    width: calc(50% - 2rem);
  }
}

@media (min-width: 1000px) {
  .class-card {
    flex: 0 0 calc(33.333% - 2rem);
    width: calc(33.333% - 2rem);
  }
}

.class-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 10px 15px rgba(0,0,0,0.1);
}

.class-card h3 {
  font-family: var(--f-main); /* Besser lesbar als Serif */
  font-weight: 700;
  font-size: 3.2rem; /* Deutlich größer */
  margin-bottom: 1.5rem;
  letter-spacing: 2px;
  color: #000;
}

.class-card ul li {
  font-size: 1.65rem; /* Namen größer */
  margin-bottom: 0.6rem;
  font-weight: 500;
}

/* Department Colors */
.dept-informatik { border-color: var(--c-dept-info); }
.dept-maschinenbau { border-color: var(--c-dept-mech); }
.dept-elektronik { border-color: var(--c-dept-el); }
.dept-automation { border-color: var(--c-dept-aut); }
.dept-logistik { border-color: var(--c-dept-log); }

/* 7. Sponsoren */
.sponsors-grid {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  gap: 4rem;
  margin-bottom: 4rem;
}

.sponsor-img {
  transition: filter 0.2s, transform 0.2s;
  max-width: 100%;
  height: auto;
  object-fit: contain; /* Verhindert Verzerren */
  display: block;
}

.sponsor-img:hover {
  transform: scale(1.05);
}

/* Größenanpassung */
.s-main .sponsor-img {
    max-height: 180px;
    width: auto;
}
.s-gold .sponsor-img {
    max-height: 120px;
    width: auto;
}
.s-silver .sponsor-img {
    max-height: 80px;
    width: auto;
}

.sponsoren-text {
    max-width: 800px;
    margin: 0 auto;
    line-height: 1.8;
    color: #666;
}

/* 8. Loader */
#loader {
  position: fixed;
  inset: 0;
  background: white;
  z-index: 9999;
  display: flex;
  justify-content: center;
  align-items: center;
  transition: opacity 0.5s;
}

.spinner {
  width: 60px;
  height: 60px;
  border: 6px solid #f3f3f3;
  border-top: 6px solid var(--c-primary);
  border-radius: 50%;
  animation: spin 1s linear infinite;
}

@keyframes spin {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

/* 9. Contact & Footer */
.contact-icons img {
  width: 40px;
  margin: 0 15px;
  transition: transform 0.2s;
}

.contact-icons img:hover {
  transform: scale(1.2);
}

footer {
  background: var(--c-primary);
  color: #aaa;
  text-align: center;
  padding: 3rem 1rem;
  font-size: 1rem;
}

@media (max-width: 768px) {
    .nav-links {
        gap: 1rem;
        font-size: 0.9rem;
    }
    .hero {
        min-height: 40vh;
        padding: 2rem;
    }
    .title-font {
        font-size: 3.9rem;
    }
}

.vip-grid {
  display: grid;
  gap: 3rem;
  text-align: center;
  grid-template-columns: 1fr;
  justify-content: center;
}

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

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

.contact-icons {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 20px;
  margin-top: 1rem;
}

.contact-icons img {
  width: 40px;
  transition: transform 0.2s;
  display: block;
}

.contact-icons img:hover {
  transform: scale(1.2);
}

footer {
  background: var(--c-primary);
  color: #aaa;
  text-align: center;
  padding: 3rem 1rem;
  font-size: 1rem;
}
