/* ══════════════════════════════════════════════
   EMISA 2027 – Stylesheet
   RWTH Aachen Corporate Design
   Primary Blue: #00549F | Secondary: #407FB7
   Font: system stack with RWTH feel
   ══════════════════════════════════════════════ */

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

:root {
  --blue:       #00549F;
  --blue-75:    #407FB7;
  --blue-50:    #8EBAE5;
  --blue-10:    #E8F1FA;
  --black:      #1A1A1A;
  --gray-dark:  #3D3D3D;
  --gray-mid:   #6B6B6B;
  --gray-light: #F4F7FB;
  --border:     #D8E4F0;
  --white:      #ffffff;
  --font:       'Segoe UI', Arial, 'Helvetica Neue', Helvetica, sans-serif;
  --max-w:      1100px;
  --radius:     4px;
  --shadow:     0 2px 8px rgba(0,84,159,0.10);
}

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

body {
  font-family: var(--font);
  color: var(--black);
  background: var(--white);
  line-height: 1.65;
  margin: 0;
  padding: 0;
}

a { color: var(--blue); text-decoration: none; }
a:hover { text-decoration: underline; }

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

/* ── Header ── */
.site-header {
  background: var(--white);
  border-bottom: 3px solid var(--blue);
  position: sticky;
  top: 0;
  z-index: 100;
  box-shadow: 0 2px 6px rgba(0,0,0,0.08);
}

.header-inner {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 0.75rem 1.5rem;
  display: flex;
  align-items: center;
  gap: 1rem;
}

.logo-left, .logo-right {
  flex-shrink: 0;
  display: flex;
  align-items: center;
}
.logo-right { margin-left: auto; }

/* Logo <img> sizing — adjust max-height to taste once real files are in place */
.logo-img {
  display: block;
  width: auto;
  object-fit: contain;
}
.logo-img--emisa {
  height: 52px;   /* GI EMISA Fachgruppe logo */
  max-width: 180px;
}
.logo-img--rwth {
  height: 52px;   /* RWTH Aachen logo */
  max-width: 200px;
}

.header-title {
  flex: 1;
  text-align: center;
}

.site-name {
  display: block;
  font-size: 1.4rem;
  font-weight: 700;
  color: var(--blue);
  letter-spacing: 0.04em;
  text-decoration: none;
  line-height: 1.1;
}
.site-name:hover { text-decoration: none; color: var(--blue-75); }

.site-subtitle {
  display: block;
  font-size: 0.78rem;
  color: var(--gray-mid);
  letter-spacing: 0.03em;
  margin-top: 2px;
}

/* ── Nav ── */
.main-nav {
  background: var(--blue);
}

.main-nav ul {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 0 1.5rem;
  display: flex;
  list-style: none;
  gap: 0;
}

.main-nav ul li a {
  display: block;
  padding: 0.65rem 1.25rem;
  color: rgba(255,255,255,0.88);
  font-size: 0.88rem;
  font-weight: 500;
  letter-spacing: 0.03em;
  border-bottom: 3px solid transparent;
  text-decoration: none;
  transition: background 0.15s, color 0.15s;
}

.main-nav ul li a:hover,
.main-nav ul li a.active {
  background: rgba(255,255,255,0.12);
  color: var(--white);
  border-bottom-color: var(--white);
}

/* ── Hero ── */
.hero { position: relative; }

.hero-image-wrap {
  position: relative;
  height: 480px;
  overflow: hidden;
  /* background-image is set inline on the element in index.html so you can
     easily change just the filename without touching the CSS.
     background-color shows as a fallback while the image loads (or if it fails). */
  background-color: #003470;
  background-size: cover;
  background-position: center 40%;
  background-repeat: no-repeat;
}

/* Hidden <img> kept only for SEO / screen-readers; not rendered visually */
.hero-img-hidden {
  display: none;
}

.hero-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    to right,
    rgba(0,30,70,0.78) 0%,
    rgba(0,50,110,0.55) 55%,
    rgba(0,30,70,0.20) 100%
  );
}

.hero-text {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: stretch;
}

.hero-text-inner {
  display: flex;
  flex-direction: column;
  justify-content: center;
  width: 100%;
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 2.5rem 1.5rem;
  color: var(--white);
}

.hero-eyebrow {
  font-size: 0.85rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--blue-50);
  margin-bottom: 0.6rem;
  font-weight: 600;
}

.hero-text h1 {
  font-size: clamp(1.5rem, 3.5vw, 2.4rem);
  font-weight: 700;
  line-height: 1.2;
  margin-bottom: 0.75rem;
  color: var(--white);
  text-shadow: 0 1px 4px rgba(0,0,0,0.4);
}

.hero-location {
  font-size: 1rem;
  color: rgba(255,255,255,0.85);
  margin-bottom: 1.5rem;
  letter-spacing: 0.02em;
}

.hero-cta-row {
  display: flex;
  gap: 0.75rem;
  flex-wrap: wrap;
}

/* ── Buttons ── */
.btn {
  display: inline-block;
  padding: 0.6rem 1.4rem;
  border-radius: var(--radius);
  font-size: 0.9rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  cursor: pointer;
  text-decoration: none;
  transition: background 0.15s, border-color 0.15s, color 0.15s;
}

.btn-primary {
  background: var(--blue);
  color: var(--white);
  border: 2px solid var(--blue);
}
.btn-primary:hover {
  background: #004a8f;
  border-color: #004a8f;
  text-decoration: none;
  color: var(--white);
}

.btn-outline {
  background: transparent;
  color: var(--white);
  border: 2px solid rgba(255,255,255,0.75);
}
.btn-outline:hover {
  background: rgba(255,255,255,0.15);
  border-color: var(--white);
  text-decoration: none;
  color: var(--white);
}

.btn-blue {
  background: var(--blue);
  color: var(--white);
  border: 2px solid var(--blue);
}
.btn-blue:hover {
  background: #004a8f;
  border-color: #004a8f;
  text-decoration: none;
  color: var(--white);
}

/* ── Container ── */
.container {
  width: 100%;
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 0 1.5rem;
  box-sizing: border-box;
}

/* ── Section headings shared ── */
h2 {
  font-size: 1.55rem;
  font-weight: 700;
  color: var(--blue);
  margin-bottom: 1rem;
}

h3 {
  font-size: 1.1rem;
  font-weight: 600;
  color: var(--black);
  margin-bottom: 0.5rem;
}

/* ── Welcome section ── */
.welcome-section {
  padding: 3rem 0 2rem;
  border-bottom: 1px solid var(--border);
}

.welcome-text p {
  max-width: 800px;
  color: var(--gray-dark);
  margin-bottom: 0.9rem;
  font-size: 1.01rem;
}

/* ── Cards ── */
.cards-section {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 1.25rem;
  padding: 2.5rem 0;
  border-bottom: 1px solid var(--border);
}

.info-card {
  background: var(--white);
  border: 1px solid var(--border);
  border-top: 4px solid var(--blue);
  border-radius: var(--radius);
  padding: 1.4rem 1.3rem;
  box-shadow: var(--shadow);
  transition: box-shadow 0.15s, transform 0.15s;
}
.info-card:hover {
  box-shadow: 0 4px 16px rgba(0,84,159,0.16);
  transform: translateY(-2px);
}

.card-icon { font-size: 1.6rem; margin-bottom: 0.6rem; }
.info-card h3 { color: var(--blue); margin-bottom: 0.3rem; }
.info-card p { font-size: 0.93rem; color: var(--gray-dark); }
.card-sub { color: var(--gray-mid) !important; margin-top: 0.35rem; font-size: 0.85rem !important; }
.card-link {
  display: inline-block;
  margin-top: 0.75rem;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--blue);
}

/* ── Topics ── */
.topics-section {
  padding: 2.5rem 0;
  border-bottom: 1px solid var(--border);
}

.topics-intro {
  max-width: 780px;
  color: var(--gray-dark);
  margin-bottom: 1.4rem;
}

.topics-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 0.6rem;
}

.topic-item {
  background: var(--blue-10);
  border-left: 3px solid var(--blue);
  padding: 0.55rem 0.85rem;
  border-radius: 0 var(--radius) var(--radius) 0;
  font-size: 0.88rem;
  color: var(--gray-dark);
}

/* ── About ── */
.about-section {
  padding: 2.5rem 0 3rem;
  display: grid;
  grid-template-columns: 1fr 280px;
  gap: 3rem;
}

.about-text p {
  color: var(--gray-dark);
  margin-bottom: 0.9rem;
  font-size: 0.97rem;
}

.about-links h3 { color: var(--blue); }
.about-links ul {
  list-style: none;
  margin-top: 0.75rem;
}
.about-links li {
  padding: 0.4rem 0;
  border-bottom: 1px solid var(--border);
  font-size: 0.9rem;
}
.about-links li:last-child { border-bottom: none; }

/* ── Page hero (sub-pages) ── */
.page-hero {
  background: var(--blue);
  color: var(--white);
  padding: 2.8rem 1.5rem;
  text-align: center;
}
.page-hero h1 {
  font-size: clamp(1.5rem, 3vw, 2.2rem);
  font-weight: 700;
  color: var(--white);
  margin-bottom: 0.5rem;
}
.page-hero p {
  color: rgba(255,255,255,0.82);
  font-size: 1rem;
}

/* ── Content page layout ── */
.page-content {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 2.5rem 1.5rem 3.5rem;
}

.page-content h2 {
  margin-top: 2rem;
  margin-bottom: 0.75rem;
}
.page-content h2:first-child { margin-top: 0; }

.page-content p {
  color: var(--gray-dark);
  margin-bottom: 0.9rem;
  font-size: 0.97rem;
  max-width: 800px;
}

/* ── Coming soon box ── */
.coming-soon {
  background: var(--blue-10);
  border: 1px solid var(--blue-50);
  border-left: 4px solid var(--blue);
  border-radius: var(--radius);
  padding: 1.5rem 1.75rem;
  margin: 1.5rem 0;
  max-width: 680px;
}
.coming-soon h3 { color: var(--blue); margin-bottom: 0.4rem; }
.coming-soon p { color: var(--gray-dark); font-size: 0.94rem; margin-bottom: 0.5rem; }
.coming-soon p:last-child { margin-bottom: 0; }

/* ── Program table ── */
.program-day {
  margin-bottom: 2.5rem;
}
.program-day h3 {
  background: var(--blue);
  color: var(--white);
  padding: 0.6rem 1rem;
  border-radius: var(--radius) var(--radius) 0 0;
  font-size: 1rem;
}
.program-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.9rem;
}
.program-table tr {
  border-bottom: 1px solid var(--border);
}
.program-table tr:last-child { border-bottom: none; }
.program-table td {
  padding: 0.6rem 1rem;
  vertical-align: top;
  color: var(--gray-dark);
}
.program-table td:first-child {
  width: 110px;
  color: var(--blue);
  font-weight: 600;
  white-space: nowrap;
}
.program-table tr.tbd td { color: var(--gray-mid); font-style: italic; }
.program-table tr:nth-child(even) { background: var(--blue-10); }

/* ── Venue ── */
.venue-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2rem;
  align-items: start;
  margin: 1.5rem 0;
}
.venue-image-wrap {
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow);
}
.venue-image-wrap img {
  width: 100%;
  height: 280px;
  object-fit: cover;
}
.venue-details { font-size: 0.93rem; }
.venue-details p { margin-bottom: 0.65rem; color: var(--gray-dark); }
.venue-details strong { color: var(--black); }
.map-link {
  display: inline-block;
  margin-top: 0.75rem;
  padding: 0.5rem 1.1rem;
  background: var(--blue);
  color: var(--white);
  border-radius: var(--radius);
  font-size: 0.88rem;
  font-weight: 600;
  text-decoration: none;
}
.map-link:hover { background: #004a8f; text-decoration: none; color: var(--white); }

/* ── Footer ── */
.site-footer {
  background: var(--blue);
  color: rgba(255,255,255,0.85);
  margin-top: 0;
}

.footer-inner {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 2.5rem 1.5rem 1.5rem;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 2rem;
}

.footer-col strong {
  display: block;
  color: var(--white);
  font-size: 0.9rem;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  margin-bottom: 0.6rem;
}
.footer-col p {
  font-size: 0.84rem;
  line-height: 1.5;
  margin-bottom: 0.4rem;
}
.footer-col a { color: var(--blue-50); }
.footer-col a:hover { color: var(--white); }

.footer-bottom {
  border-top: 1px solid rgba(255,255,255,0.2);
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 0.75rem 1.5rem;
  font-size: 0.78rem;
  color: rgba(255,255,255,0.55);
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
}
.footer-bottom a { color: rgba(255,255,255,0.6); }
.footer-bottom a:hover { color: var(--white); }

/* ── Responsive ── */
@media (max-width: 768px) {
  .header-inner {
    flex-wrap: wrap;
    gap: 0.5rem;
  }
  .logo-right { margin-left: 0; }
  .header-title { order: 3; flex: 100%; text-align: center; }

  .hero-image-wrap { height: 360px; }
  .hero-text { padding: 1.5rem; }

  .about-section { grid-template-columns: 1fr; gap: 1.5rem; }
  .venue-grid { grid-template-columns: 1fr; }

  .main-nav ul { flex-wrap: wrap; }
  .main-nav ul li a { padding: 0.5rem 0.85rem; font-size: 0.82rem; }
}