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

:root {
  --navy:       #0A2540;
  --navy-2:     #0D2B47;
  --navy-3:     #0f2235;
  --terra:      #C96B47;
  --terra-dim:  rgba(201,107,71,0.15);
  --terra-glow: rgba(201,107,71,0.07);
  --slate:      #8994A6;
  --slate-dim:  rgba(137,148,166,0.2);
  --white:      #ffffff;
  --white-80:   rgba(255,255,255,0.80);
  --white-50:   rgba(255,255,255,0.50);
  --white-20:   rgba(255,255,255,0.20);
  --white-10:   rgba(255,255,255,0.10);
  --white-05:   rgba(255,255,255,0.05);
  --mono:       'JetBrains Mono', monospace;
  --sans:       'Exo 2', sans-serif;
  --display:    'Exo 2', sans-serif;
  --max:        1100px;
  --gap:        clamp(1.5rem, 5vw, 4rem);
}

html { scroll-behavior: smooth; }

body {
  font-family: var(--sans);
  font-size: 1rem;
  line-height: 1.7;
  color: var(--white-80);
  background: var(--navy);
  -webkit-font-smoothing: antialiased;
}

/* ─── Header ────────────────────────────────────────────────── */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(10,37,64,0.92);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--white-10);
  padding: 0 var(--gap);
}
.header-inner {
  max-width: var(--max);
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 64px;
}
.logo-link { display: flex; align-items: center; }
.logo-img { height: 32px; width: auto; }
nav { display: flex; gap: 2rem; }
nav a {
  font-family: var(--mono);
  font-size: 0.72rem;
  font-weight: 500;
  color: var(--white-50);
  text-decoration: none;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  transition: color 0.2s;
}
nav a:hover { color: var(--terra); }

/* ─── Hero ──────────────────────────────────────────────────── */
.hero {
  position: relative;
  overflow: hidden;
  min-height: 90vh;
  display: flex;
  align-items: center;
  padding: var(--gap);
  padding-top: calc(var(--gap) + 2rem);
}
.hero-grid {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(var(--white-05) 1px, transparent 1px),
    linear-gradient(90deg, var(--white-05) 1px, transparent 1px);
  background-size: 60px 60px;
  mask-image: radial-gradient(ellipse 80% 60% at 40% 50%, black 30%, transparent 100%);
  pointer-events: none;
}
.hero-inner {
  max-width: var(--max);
  margin: 0 auto;
  width: 100%;
  position: relative;
  z-index: 1;
  max-width: 640px;
}
.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-family: var(--mono);
  font-size: 0.68rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--terra);
  border: 1px solid var(--terra-dim);
  padding: 0.35rem 0.85rem;
  margin-bottom: 2rem;
}
.badge-dot {
  width: 6px; height: 6px;
  border-radius: 50%;
  background: var(--terra);
  animation: pulse 2s ease-in-out infinite;
}
@keyframes pulse { 0%,100%{opacity:1} 50%{opacity:0.35} }

.hero-name {
  font-family: var(--display);
  font-size: clamp(2.5rem, 6vw, 4.5rem);
  font-weight: 600;
  line-height: 1.05;
  letter-spacing: -0.01em;
  color: var(--white);
  margin-bottom: 1rem;
}
.hero-title {
  font-family: var(--mono);
  font-size: clamp(0.8rem, 1.8vw, 0.95rem);
  color: var(--slate);
  letter-spacing: 0.06em;
  margin-bottom: 0.5rem;
}
.hero-sub {
  font-size: 0.875rem;
  color: var(--white-50);
  margin-bottom: 2rem;
}
.hero-domains {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-bottom: 2.5rem;
}
.domain-tag {
  font-family: var(--mono);
  font-size: 0.68rem;
  letter-spacing: 0.06em;
  padding: 0.3rem 0.75rem;
  border: 1px solid var(--slate-dim);
  color: var(--slate);
  transition: border-color 0.2s, color 0.2s;
}
.domain-tag:hover { border-color: var(--terra); color: var(--terra); }
.hero-actions { display: flex; gap: 1rem; flex-wrap: wrap; }

/* ─── Hero Visual ───────────────────────────────────────────── */
.hero-visual {
  position: absolute;
  right: 5%;
  top: 50%;
  transform: translateY(-50%);
  z-index: 0;
  opacity: 0.22;
  pointer-events: none;
}
.chip-frame { width: 380px; height: 380px; display: flex; align-items: center; justify-content: center; }
.chip-logo { width: 260px; height: auto; filter: brightness(10); }

/* ─── Buttons ───────────────────────────────────────────────── */
.btn {
  display: inline-flex;
  align-items: center;
  padding: 0.75rem 1.75rem;
  font-family: var(--mono);
  font-size: 0.75rem;
  font-weight: 500;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  text-decoration: none;
  transition: all 0.2s;
}
.btn--primary { background: var(--terra); color: var(--white); border: 1px solid var(--terra); }
.btn--primary:hover { background: #d97a57; border-color: #d97a57; transform: translateY(-1px); }
.btn--ghost { background: transparent; color: var(--white-80); border: 1px solid var(--white-20); }
.btn--ghost:hover { border-color: var(--terra); color: var(--terra); }

/* ─── Sections ──────────────────────────────────────────────── */
.section { padding: clamp(4rem, 10vw, 7rem) var(--gap); }
.section--dark { background: var(--navy-3); }
.section-inner { max-width: var(--max); margin: 0 auto; }
.section-label {
  font-family: var(--mono);
  font-size: 0.68rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--terra);
  margin-bottom: 0.75rem;
}
.section-title {
  font-family: var(--display);
  font-size: clamp(1.75rem, 4vw, 2.75rem);
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--white);
  margin-bottom: 3rem;
  line-height: 1.15;
}

/* ─── About ─────────────────────────────────────────────────── */
.about-grid {
  display: grid;
  grid-template-columns: 220px 1fr;
  gap: 4rem;
  align-items: start;
}
.about-photo-col { display: flex; justify-content: center; }
.about-photo-wrap {
  width: 200px;
  height: 200px;
  border-radius: 50%;
  overflow: hidden;
  flex-shrink: 0;
}
.about-photo {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 15%;
  transform: scale(1.15);
  filter: grayscale(10%);
}
.about-main { display: flex; flex-direction: column; gap: 2rem; }
.about-text p {
  font-size: 1.05rem;
  line-height: 1.9;
  color: var(--white-80);
  margin-bottom: 1rem;
}
.about-stats { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
.stat-card {
  background: var(--white-05);
  border: 1px solid var(--white-10);
  border-left: 3px solid var(--terra);
  padding: 1.25rem 1rem;
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  transition: background 0.2s;
}
.stat-card:hover { background: var(--terra-glow); }
.stat-num { font-family: var(--mono); font-size: 1rem; font-weight: 500; color: var(--terra); }
.stat-label { font-size: 0.72rem; color: var(--white-50); letter-spacing: 0.02em; }

/* ─── Skills ────────────────────────────────────────────────── */
.section--dark h3 {
  font-family: var(--mono);
  font-size: 0.68rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--terra);
  margin: 2.5rem 0 1rem;
  padding-bottom: 0.5rem;
  border-bottom: 1px solid var(--white-10);
}
.section--dark h3:first-child { margin-top: 0; }
.section--dark ul { list-style: none; display: flex; flex-wrap: wrap; gap: 0.5rem; }
.section--dark li {
  font-family: var(--mono);
  font-size: 0.72rem;
  padding: 0.3rem 0.8rem;
  border: 1px solid var(--white-10);
  color: var(--white-80);
  letter-spacing: 0.03em;
  transition: border-color 0.2s, color 0.2s;
}
.section--dark li:hover { border-color: var(--terra); color: var(--terra); }

/* ─── Contact ───────────────────────────────────────────────── */
.contact-intro { font-size: 1.05rem; color: var(--white-50); margin-bottom: 2.5rem; max-width: 540px; }
.contact-cards { display: flex; flex-direction: column; gap: 1rem; max-width: 520px; }
.contact-card {
  display: flex;
  align-items: center;
  gap: 1.25rem;
  padding: 1.25rem 1.5rem;
  border: 1px solid var(--white-10);
  background: var(--white-05);
  text-decoration: none;
  transition: border-color 0.2s, background 0.2s;
}
.contact-card:hover { border-color: var(--terra); background: var(--terra-glow); }
.contact-card__icon {
  font-family: var(--mono);
  font-size: 0.8rem;
  font-weight: 500;
  background: var(--terra);
  color: var(--white);
  width: 2.5rem;
  height: 2.5rem;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.contact-card__label { font-family: var(--mono); font-size: 0.63rem; letter-spacing: 0.1em; text-transform: uppercase; color: var(--white-50); margin-bottom: 0.2rem; }
.contact-card__value { font-size: 0.9rem; color: var(--white-80); }

/* ─── Footer ────────────────────────────────────────────────── */
.site-footer { padding: 2rem var(--gap); border-top: 1px solid var(--white-10); }
.footer-inner { max-width: var(--max); margin: 0 auto; display: flex; align-items: center; gap: 1.5rem; flex-wrap: wrap; }
.footer-logo { height: 22px; width: auto; opacity: 0.4; }
.site-footer p { font-size: 0.72rem; color: var(--white-50); font-family: var(--mono); }

/* ─── Responsive ────────────────────────────────────────────── */
@media (max-width: 768px) {
  .about-grid {
    grid-template-columns: 1fr;
    gap: 2rem;
  }
  .about-photo-col {
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 1.25rem;
  }
  .about-photo-wrap {
    width: 80px;
    height: 80px;
    flex-shrink: 0;
  }
  .about-photo-col::after {
    content: 'Christoph Niemann\ASenior Embedded Systems Architect';
    white-space: pre;
    font-family: var(--display);
    font-size: 1rem;
    font-weight: 600;
    color: var(--white);
    line-height: 1.4;
  }
  .hero-visual { display: none; }
  .hero-inner { max-width: 100%; }
  nav { gap: 1.25rem; }
}
@media (max-width: 480px) {
  .hero-actions { flex-direction: column; }
  .btn { text-align: center; justify-content: center; }
}