/* =========================
   Design Tokens
   ========================= */
:root{
  --font: Inter, system-ui, -apple-system, Segoe UI, Roboto, Arial, sans-serif;

  /* Spacing (8px scale) */
  --s1: 8px;
  --s2: 12px;
  --s3: 16px;
  --s4: 24px;
  --s5: 32px;
  --s6: 48px;
  --s7: 72px;
  --s8: 96px;

  /* Radius */
  --r1: 12px;
  --r2: 18px;
  --r3: 999px;

  /* Default: Dark */
  --bg: #0b0c0f;
  --bg2: #0f1117;
  --surface: rgba(255,255,255,0.04);
  --surface2: rgba(255,255,255,0.06);
  --border: rgba(255,255,255,0.10);
  --text: rgba(255,255,255,0.92);
  --muted: rgba(255,255,255,0.70);

  --accent: #7c3aed;   /* violet */
  --accent2: #2563eb;  /* blue */

  --shadow: 0 18px 55px rgba(0,0,0,0.35);
  --shadow2: 0 12px 40px rgba(0,0,0,0.25);

  --focus: rgba(124,58,237,0.55);
}

@media (prefers-color-scheme: light){
  :root{
    --bg: #f6f7fb;
    --bg2: #ffffff;
    --surface: #ffffff;
    --surface2: rgba(15,23,42,0.03);
    --border: rgba(15,23,42,0.12);
    --text: rgba(15,23,42,0.92);
    --muted: rgba(15,23,42,0.70);

    --accent: #2563eb;
    --accent2: #7c3aed;

    --shadow: 0 18px 55px rgba(15,23,42,0.10);
    --shadow2: 0 12px 40px rgba(15,23,42,0.08);

    --focus: rgba(37,99,235,0.35);
  }
}

/* =========================
   Base
   ========================= */
*{ box-sizing: border-box; }
html, body{ height: 100%; }
body{
  margin: 0;
  font-family: var(--font);
  color: var(--text);
  background: var(--bg);
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

a{ color: inherit; }
img{ max-width: 100%; display: block; }

.container{
  width: 100%;
  max-width: 1120px;
  margin: 0 auto;
  padding: 0 var(--s4);
}

/* Skip link for accessibility */
.skip-link{
  position: absolute;
  left: -999px;
  top: var(--s3);
  background: var(--bg2);
  border: 1px solid var(--border);
  padding: var(--s2) var(--s3);
  border-radius: var(--r1);
  z-index: 999;
}
.skip-link:focus{ left: var(--s3); outline: none; box-shadow: 0 0 0 4px var(--focus); }

/* Focus styles */
:focus-visible{
  outline: none;
  box-shadow: 0 0 0 4px var(--focus);
  border-radius: 10px;
}

/* =========================
   Header / Hero
   ========================= */
.site-header{
  position: relative;
  padding: var(--s7) 0 var(--s5);
  background:
    radial-gradient(900px 500px at 15% -10%, rgba(37,99,235,0.18), transparent 55%),
    radial-gradient(900px 500px at 90% 0%, rgba(124,58,237,0.16), transparent 55%),
    linear-gradient(to bottom, var(--bg2), var(--bg));
  overflow: clip;
}

.bg-glow{
  position: absolute;
  inset: -120px -120px auto -120px;
  height: 380px;
  background: radial-gradient(circle at 30% 40%, rgba(124,58,237,0.22), transparent 60%);
  filter: blur(8px);
  opacity: 0.9;
  pointer-events: none;
}

.hero{
  display: grid;
  grid-template-columns: 1.25fr 0.75fr;
  gap: var(--s6);
  align-items: center;
  margin-bottom: var(--s5);
}

.eyebrow{
  margin: 0 0 var(--s2);
  color: var(--muted);
  font-size: 13px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.hero-title{
  margin: 0 0 var(--s2);
  font-size: clamp(44px, 5vw, 72px);
  line-height: 1.05;
  letter-spacing: -0.03em;
  font-weight: 800;
}

.gradient-text{
  background: linear-gradient(135deg, var(--accent), var(--accent2));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.hero-subtitle{
  margin: 0 0 var(--s4);
  max-width: 65ch;
  font-size: 18px;
  color: var(--muted);
}

.hero-cta{
  display: flex;
  flex-wrap: wrap;
  gap: var(--s2);
  margin-bottom: var(--s4);
}

.hero-meta{
  display: flex;
  flex-wrap: wrap;
  gap: var(--s2);
}

.meta-chip{
  border: 1px solid var(--border);
  background: var(--surface);
  border-radius: var(--r3);
  padding: 10px 12px;
  display: inline-flex;
  gap: 10px;
  align-items: baseline;
}
.chip-label{
  color: var(--muted);
  font-size: 12px;
}
.chip-value{
  font-size: 13px;
  font-weight: 600;
  color: var(--text);
}

.avatar-card{
  border: 1px solid var(--border);
  background: var(--surface);
  border-radius: var(--r2);
  box-shadow: var(--shadow2);
  overflow: hidden;
}

.avatar{
  width: 100%;
  height: auto;
  aspect-ratio: 4 / 5;
  object-fit: cover;
}

.avatar-caption{
  padding: var(--s3);
  border-top: 1px solid var(--border);
}
.caption-title{
  font-weight: 700;
  letter-spacing: -0.01em;
}
.caption-sub{
  color: var(--muted);
  font-size: 14px;
  margin-top: 2px;
}

/* =========================
   Navigation (sticky pill)
   ========================= */
.nav{
  position: sticky;
  top: 14px;
  z-index: 20;

  border: 1px solid var(--border);
  background: rgba(15,17,23,0.55);
  backdrop-filter: blur(10px);
  border-radius: var(--r3);

  /* Mehr Höhe/Polsterung */
  padding: 14px 16px;
  min-height: 56px;

  display: flex;
  align-items: center;
}

@media (prefers-color-scheme: light){
  .nav{ background: rgba(255,255,255,0.65); }
}

.nav-list{
  list-style: none;
  margin: 0;
  padding: 6px 4px;

  display: flex;
  gap: 8px;
  justify-content: flex-start;
  align-items: center;

  overflow-x: auto;
  overflow-y: auto;

  flex-wrap: nowrap;
  scrollbar-width: none;          /* Firefox */
  -ms-overflow-style: none;       /* Legacy */
  -webkit-overflow-scrolling: touch;
}
	  
.nav-list::-webkit-scrollbar{
  height: 0;                      /* Chrome/Safari/Edge */
}	  

.nav-link{
  text-decoration: none;
  color: var(--muted);

  /* Etwas mehr Höhe */
  padding: 10px 12px;
  line-height: 1;                 

  border-radius: var(--r3);
  font-weight: 600;
  font-size: 14px;

  transition: background .18s ease, color .18s ease, transform .18s ease;
  white-space: nowrap;
}
	  
@media (min-width: 901px){
  .nav-list{
    justify-content: center;
    overflow-x: visible;
  }
}	  
	  
.nav-link:hover{
  color: var(--text);
  background: var(--surface2);
}
.nav-link[aria-current="page"]{
  color: var(--text);
  background: linear-gradient(135deg, rgba(124,58,237,0.18), rgba(37,99,235,0.14));
  border: 1px solid rgba(124,58,237,0.30);
}

/* =========================
   Sections
   ========================= */
.section{
  padding: var(--s8) 0;
}

.section-head{
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--s2);
  margin-bottom: var(--s5);
}

.section-title{
  margin: 0;
  font-size: clamp(24px, 2.4vw, 34px);
  letter-spacing: -0.02em;
  line-height: 1.15;
  font-weight: 800;
}

.section-desc{
  margin: 0;
  max-width: 70ch;
  color: var(--muted);
  font-size: 16px;
}

/* =========================
   Cards / Layout blocks
   ========================= */
.highlights{
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--s3);
}

.stack{
  display: grid;
  gap: var(--s3);
}

.card{
  border: 1px solid var(--border);
  background: var(--surface);
  border-radius: var(--r2);
  padding: var(--s4);
  box-shadow: 0 0 0 rgba(0,0,0,0);
  transition: transform .18s ease, box-shadow .18s ease, border-color .18s ease, background .18s ease;
}
.card:hover{
  transform: translateY(-2px);
  box-shadow: var(--shadow2);
  border-color: rgba(124,58,237,0.28);
  background: var(--surface2);
}

.card-lg{ padding: var(--s5); }

.card-title{
  margin: 0 0 6px;
  font-size: 18px;
  font-weight: 800;
  letter-spacing: -0.01em;
  line-height: 1.2;
}

.card-subtitle{
  margin: 0;
  color: var(--muted);
  font-size: 14px;
  font-weight: 600;
}

.card-text{
  margin: 0;
  color: var(--muted);
  font-size: 15px;
}

.card-meta{
  display: flex;
  gap: var(--s3);
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: var(--s3);
}

.date-pill{
  border: 1px solid var(--border);
  background: rgba(255,255,255,0.03);
  padding: 8px 10px;
  border-radius: var(--r3);
  font-size: 13px;
  color: var(--muted);
  white-space: nowrap;
}

/* Stats */
.stat-row{
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: var(--s2);
  margin: var(--s3) 0 var(--s4);
}
.stat{
  border: 1px solid var(--border);
  background: rgba(255,255,255,0.03);
  border-radius: var(--r1);
  padding: 12px;
}
.stat-value{
  font-size: 22px;
  font-weight: 900;
  letter-spacing: -0.02em;
}
.stat-label{
  color: var(--muted);
  font-size: 12px;
  margin-top: 2px;
}

/* Bullets */
.bullets{
  margin: 0;
  padding-left: 18px;
  color: var(--muted);
}
.bullets li{
  margin: 10px 0;
}

/* Skills grid */
.skills-grid{
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--s3);
}

/* Contact */
.contact-card{
  border: 1px solid var(--border);
  background: linear-gradient(135deg, rgba(124,58,237,0.12), rgba(37,99,235,0.10));
  border-radius: var(--r2);
  padding: var(--s6);
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  gap: var(--s4);
  align-items: center;
}

.contact-actions{
  display: grid;
  gap: var(--s2);
  justify-items: start;
}

/* =========================
   Buttons
   ========================= */
.btn{
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  text-decoration: none;
  font-weight: 700;
  font-size: 14px;
  padding: 10px 14px;
  border-radius: var(--r1);
  border: 1px solid var(--border);
  transition: transform .15s ease, background .15s ease, border-color .15s ease, box-shadow .15s ease;
}
.btn:hover{ transform: translateY(-1px); }

.btn-primary{
  border-color: transparent;
  color: white;
  background: linear-gradient(135deg, var(--accent), var(--accent2));
  box-shadow: 0 14px 40px rgba(124,58,237,0.18);
}
.btn-primary:hover{
  box-shadow: 0 18px 55px rgba(124,58,237,0.25);
}

.btn-secondary{
  background: var(--surface);
  color: var(--text);
}
.btn-secondary:hover{
  background: var(--surface2);
}

.btn-ghost{
  background: transparent;
  color: var(--muted);
}
.btn-ghost:hover{
  color: var(--text);
  background: rgba(255,255,255,0.04);
}

/* =========================
   Footer
   ========================= */
.site-footer{
  border-top: 1px solid var(--border);
  padding: var(--s5) 0;
  background: var(--bg2);
}

.footer-inner{
  display: flex;
  gap: var(--s3);
  align-items: baseline;
  justify-content: space-between;
  flex-wrap: wrap;
}
.site-footer p{
  margin: 0;
  color: var(--muted);
  font-size: 14px;
}
.footer-note{
  color: var(--muted);
}

/* Noscript message */
.noscript{
  position: fixed;
  left: var(--s3);
  right: var(--s3);
  bottom: var(--s3);
  padding: var(--s3);
  border-radius: var(--r1);
  border: 1px solid var(--border);
  background: var(--bg2);
  color: var(--muted);
  z-index: 50;
}

/* =========================
   Reveal animations
   ========================= */
.reveal{
  opacity: 0;
  transform: translateY(10px);
  transition: opacity .5s ease, transform .5s ease;
}
.reveal.is-visible{
  opacity: 1;
  transform: translateY(0);
}

@media (prefers-reduced-motion: reduce){
  html{ scroll-behavior: auto; }
  *{ transition: none !important; animation: none !important; }
  .reveal{ opacity: 1; transform: none; }
}

/* Anchor offset for sticky nav */
.section{ scroll-margin-top: 90px; }

/* =========================
   Responsive
   ========================= */
@media (max-width: 980px){
  .hero{
    grid-template-columns: 1fr;
  }
  .hero-right{
    order: -1;
  }
  .contact-card{
    grid-template-columns: 1fr;
  }
  .contact-actions{
    justify-items: stretch;
  }
  .btn{ width: 100%; }
}

@media (max-width: 900px){
  .highlights{ grid-template-columns: 1fr; }
  .skills-grid{ grid-template-columns: 1fr; }
  .section{ padding: var(--s7) 0; }
  .site-header{ padding: var(--s6) 0 var(--s4); }
}

@media (max-width: 520px){
  .container{ padding: 0 var(--s3); }
  .nav{ top: 10px; }
  .hero-subtitle{ font-size: 16px; }
  .card-lg{ padding: var(--s4); }
  .contact-card{ padding: var(--s5); }
  .stat-row{ grid-template-columns: 1fr; }
}
