/* ============ Tokens ============ */
/* Dark is the default, signature look. data-theme="light" overrides below. */
:root{
  --bg: #07080a;
  --bg-elevated: #0e1013;
  --card: #12141a;
  --border: rgba(255,255,255,0.08);
  --text: #f5f6f8;
  --text-dim: #9ba0aa;
  --text-faint: #5b606b;
  --accent: #33e6c3;
  --accent-2: #4da3ff;
  --accent-rgb: 51,230,195;
  --accent-2-rgb: 77,163,255;
  --accent-soft: rgba(51,230,195,0.12);
  --node-rgb: 148,255,231;
  --surface-tint: rgba(255,255,255,0.02);
  --nav-scroll-bg: rgba(7,8,10,0.72);
  --nav-mobile-bg: rgba(9,10,13,0.98);
  --radius: 18px;
  --ease: cubic-bezier(.16,.84,.32,1);
  --font-head: "Space Grotesk", "Inter", sans-serif;
  --font-body: "Inter", -apple-system, BlinkMacSystemFont, sans-serif;
}

:root[data-theme="light"]{
  --bg: #f5f6f8;
  --bg-elevated: #ffffff;
  --card: #ffffff;
  --border: rgba(13,18,26,0.1);
  --text: #10151c;
  --text-dim: #4b5563;
  --text-faint: #848d99;
  --accent: #0f9e8e;
  --accent-2: #2f6fe0;
  --accent-rgb: 15,158,142;
  --accent-2-rgb: 47,111,224;
  --accent-soft: rgba(15,158,142,0.14);
  --node-rgb: 15,158,142;
  --surface-tint: rgba(13,18,26,0.03);
  --nav-scroll-bg: rgba(245,246,248,0.78);
  --nav-mobile-bg: rgba(255,255,255,0.97);
}

*{margin:0;padding:0;box-sizing:border-box;}
html{scroll-behavior:smooth;}
body{
  background:var(--bg);
  color:var(--text);
  font-family:var(--font-body);
  overflow-x:hidden;
  -webkit-font-smoothing:antialiased;
  transition:background-color .4s var(--ease), color .4s var(--ease);
}
img{max-width:100%;display:block;}
a{color:inherit;text-decoration:none;}
ul{list-style:none;}

.container{
  max-width:1100px;
  margin:0 auto;
  padding:0 32px;
}

/* ============ Scroll progress ============ */
.progress-bar{
  position:fixed;
  top:0; left:0;
  height:3px;
  width:0%;
  background:linear-gradient(90deg,var(--accent),var(--accent-2));
  z-index:200;
  transition:width .1s linear;
}

/* ============ Nav ============ */
#mainNav{
  position:fixed;
  top:0; left:0; right:0;
  z-index:150;
  padding:22px 0;
  transition:padding .4s var(--ease), background .4s var(--ease), border-color .4s var(--ease);
  border-bottom:1px solid transparent;
}
#mainNav.scrolled{
  padding:14px 0;
  background:var(--nav-scroll-bg);
  backdrop-filter:blur(16px) saturate(140%);
  border-color:var(--border);
}
.nav-right{
  display:flex;
  align-items:center;
  gap:28px;
}
.theme-toggle{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  width:38px; height:38px;
  border-radius:50%;
  border:1px solid var(--border);
  background:var(--card);
  color:var(--text);
  cursor:pointer;
  flex-shrink:0;
  transition:border-color .3s var(--ease), transform .3s var(--ease), background-color .3s var(--ease);
}
.theme-toggle:hover{
  border-color:rgba(var(--accent-rgb),0.4);
  transform:translateY(-1px);
}
.theme-toggle:focus-visible{outline:2px solid var(--accent); outline-offset:2px;}
.theme-toggle .icon{width:17px; height:17px;}
.theme-toggle .icon-moon{display:none;}
:root[data-theme="light"] .theme-toggle .icon-sun{display:none;}
:root[data-theme="light"] .theme-toggle .icon-moon{display:block;}
.nav-inner{
  max-width:1100px;
  margin:0 auto;
  padding:0 32px;
  display:flex;
  align-items:center;
  justify-content:space-between;
}
.nav-logo{
  font-family:var(--font-head);
  font-weight:700;
  font-size:20px;
  letter-spacing:-0.02em;
}
.nav-logo .dot{color:var(--accent);}
.nav-links{
  display:flex;
  gap:36px;
}
.nav-links a{
  position:relative;
  font-size:14.5px;
  color:var(--text-dim);
  transition:color .3s var(--ease);
  padding-bottom:6px;
}
.nav-links a::after{
  content:"";
  position:absolute;
  left:0; bottom:0;
  height:1px; width:0%;
  background:var(--accent);
  transition:width .35s var(--ease);
}
.nav-links a:hover{color:var(--text);}
.nav-links a.active{color:var(--text);}
.nav-links a.active::after{width:100%;}

.nav-burger{
  display:none;
  flex-direction:column;
  gap:5px;
  background:none;
  border:none;
  cursor:pointer;
  padding:8px;
}
.nav-burger span{
  width:22px; height:2px;
  background:var(--text);
  border-radius:2px;
  transition:transform .3s var(--ease), opacity .3s var(--ease);
}

/* ============ Section basics ============ */
.section{
  padding:140px 0;
  position:relative;
}
.section-tag{
  font-size:13px;
  letter-spacing:.14em;
  text-transform:uppercase;
  color:var(--accent);
  margin-bottom:18px;
  font-weight:600;
}
.section-title{
  font-family:var(--font-head);
  font-size:clamp(28px,4vw,44px);
  font-weight:600;
  letter-spacing:-0.01em;
  line-height:1.2;
  margin-bottom:20px;
  max-width:640px;
}

/* ============ Reveal animation ============ */
.reveal{
  opacity:0;
  transform:translateY(36px);
  transition:opacity .9s var(--ease), transform .9s var(--ease);
  transition-delay:calc(var(--d,0) * 90ms);
}
.reveal.in-view{
  opacity:1;
  transform:translateY(0);
}

/* ============ Hero ============ */
.hero{
  position:relative;
  min-height:100vh;
  display:flex;
  align-items:center;
  justify-content:center;
  overflow:hidden;
  isolation:isolate;
}
#netCanvas{
  position:absolute;
  inset:0;
  width:100%;
  height:100%;
  z-index:0;
  opacity:.55;
}
.hero-glow{
  position:absolute;
  top:-20%;
  left:50%;
  width:1100px;
  height:1100px;
  transform:translateX(-50%);
  background:radial-gradient(circle at center, rgba(var(--accent-rgb),0.16), rgba(var(--accent-2-rgb),0.06) 40%, transparent 70%);
  z-index:0;
  pointer-events:none;
}
.hero-content{
  position:relative;
  z-index:1;
  text-align:center;
  padding:0 24px;
}
.hero-eyebrow{
  font-size:14px;
  letter-spacing:.12em;
  text-transform:uppercase;
  color:var(--text-dim);
  margin-bottom:28px;
}
.hero-title{
  font-family:var(--font-head);
  font-weight:700;
  font-size:clamp(56px,11vw,140px);
  line-height:.98;
  letter-spacing:-0.02em;
}
.hero-title span{display:block;}
.hero-role{
  margin-top:28px;
  font-size:clamp(16px,2.2vw,22px);
  color:var(--text);
  font-weight:500;
}
.hero-role .pipe{color:var(--text-faint); margin:0 6px;}
.hero-company{
  margin-top:8px;
  color:var(--text-dim);
  font-size:15px;
}
.hero-cta{
  margin-top:44px;
  display:flex;
  gap:16px;
  justify-content:center;
}

.btn{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  padding:14px 28px;
  border-radius:100px;
  font-size:14.5px;
  font-weight:600;
  transition:transform .35s var(--ease), box-shadow .35s var(--ease), background .35s var(--ease), border-color .35s var(--ease);
}
.btn-primary{
  background:linear-gradient(135deg,var(--accent),var(--accent-2));
  color:#04110d;
}
.btn-primary:hover{
  transform:translateY(-2px);
  box-shadow:0 12px 30px -8px rgba(var(--accent-rgb),0.45);
}
.btn-ghost{
  border:1px solid var(--border);
  color:var(--text);
  background:var(--surface-tint);
}
.btn-ghost:hover{
  border-color:rgba(255,255,255,0.25);
  transform:translateY(-2px);
}

.scroll-cue{
  position:absolute;
  bottom:38px;
  left:50%;
  transform:translateX(-50%);
  display:flex;
  flex-direction:column;
  align-items:center;
  gap:10px;
  z-index:1;
}
.scroll-cue span{
  font-size:11px;
  letter-spacing:.18em;
  text-transform:uppercase;
  color:var(--text-faint);
}
.scroll-cue-line{
  width:1px;
  height:38px;
  background:linear-gradient(to bottom, var(--accent), transparent);
  animation:scrollCue 2s var(--ease) infinite;
}
@keyframes scrollCue{
  0%{transform:scaleY(0); transform-origin:top;}
  50%{transform:scaleY(1); transform-origin:top;}
  50.01%{transform-origin:bottom;}
  100%{transform:scaleY(0); transform-origin:bottom;}
}

/* ============ About ============ */
.about-grid{
  display:grid;
  grid-template-columns:280px 1fr;
  gap:80px;
  align-items:start;
}
.about-visual{display:flex; justify-content:center;}
.monogram{
  position:relative;
  width:220px; height:220px;
  border-radius:50%;
  display:flex;
  align-items:center;
  justify-content:center;
  background:linear-gradient(160deg,var(--bg-elevated),var(--card));
  border:1px solid var(--border);
}
.monogram span{
  font-family:var(--font-head);
  font-size:56px;
  font-weight:700;
  background:linear-gradient(135deg,var(--accent),var(--accent-2));
  -webkit-background-clip:text;
  background-clip:text;
  color:transparent;
}
.monogram-ring{
  position:absolute;
  inset:-14px;
  border-radius:50%;
  border:1px dashed rgba(var(--accent-rgb),0.3);
  animation:spin 24s linear infinite;
}
@keyframes spin{to{transform:rotate(360deg);}}

.about-body{
  color:var(--text-dim);
  font-size:17px;
  line-height:1.75;
  max-width:560px;
  margin-bottom:18px;
}
.about-note{
  color:var(--text-faint);
  font-size:15px;
  line-height:1.7;
  max-width:560px;
  padding-left:16px;
  border-left:2px solid var(--border);
  margin-bottom:42px;
}
.stat-row{
  display:flex;
  gap:52px;
}
.stat{
  display:flex;
  flex-direction:column;
}
.stat-number{
  font-family:var(--font-head);
  font-size:40px;
  font-weight:700;
  color:var(--text);
}
.stat-suffix{
  font-family:var(--font-head);
  font-size:40px;
  font-weight:700;
  color:var(--accent);
}
.stat-label{
  margin-top:6px;
  font-size:13px;
  color:var(--text-faint);
}

/* ============ Timeline ============ */
.timeline-section .container > .section-title{margin-bottom:80px;}
.timeline-wrap{
  position:relative;
  display:grid;
  grid-template-columns:40px 1fr;
  gap:32px;
}
.timeline-rail{
  position:relative;
  width:2px;
  background:var(--border);
  margin-left:19px;
  border-radius:2px;
}
.timeline-rail-fill{
  position:absolute;
  top:0; left:0;
  width:100%;
  height:0%;
  background:linear-gradient(to bottom,var(--accent),var(--accent-2));
  border-radius:2px;
  transition:height .1s linear;
}
.timeline-items{
  display:flex;
  flex-direction:column;
  gap:64px;
}
.timeline-item{
  position:relative;
}
.timeline-dot{
  position:absolute;
  left:-52px;
  top:6px;
  width:16px; height:16px;
  border-radius:50%;
  background:var(--bg);
  border:2px solid var(--text-faint);
  transition:border-color .4s var(--ease), background .4s var(--ease), box-shadow .4s var(--ease);
}
.timeline-item.active .timeline-dot{
  border-color:var(--accent);
  background:var(--accent);
  box-shadow:0 0 0 6px var(--accent-soft);
}
.timeline-card{
  background:var(--card);
  border:1px solid var(--border);
  border-radius:var(--radius);
  padding:30px 32px;
  transition:border-color .4s var(--ease), transform .4s var(--ease);
}
.timeline-item.active .timeline-card{
  border-color:rgba(var(--accent-rgb),0.35);
  transform:translateX(4px);
}
.timeline-item--muted .timeline-card{opacity:.72;}
.timeline-date{
  display:inline-block;
  font-size:12.5px;
  letter-spacing:.06em;
  color:var(--accent);
  font-weight:600;
  margin-bottom:10px;
}
.timeline-card h3{
  font-family:var(--font-head);
  font-size:19px;
  font-weight:600;
  margin-bottom:6px;
  line-height:1.35;
}
.timeline-company{
  color:var(--text-dim);
  font-size:14px;
  margin-bottom:12px;
}
.timeline-desc{
  color:var(--text-faint);
  font-size:14.5px;
  line-height:1.65;
  max-width:620px;
}

/* ============ Skills ============ */
.skills-groups{
  display:grid;
  grid-template-columns:repeat(auto-fit, minmax(240px, 1fr));
  gap:40px 48px;
  margin-top:20px;
}
.skills-group h3{
  font-family:var(--font-head);
  font-size:15px;
  font-weight:600;
  color:var(--text-dim);
  margin-bottom:18px;
  text-transform:uppercase;
  letter-spacing:.04em;
}
.chip-grid{
  display:flex;
  flex-wrap:wrap;
  gap:10px;
}
.chip{
  display:inline-block;
  padding:10px 16px;
  border-radius:100px;
  border:1px solid var(--border);
  background:var(--card);
  font-size:13.5px;
  color:var(--text);
  transition:transform .3s var(--ease), border-color .3s var(--ease), background .3s var(--ease), box-shadow .3s var(--ease);
  cursor:default;
}
.chip:hover{
  transform:translateY(-3px) scale(1.04);
  border-color:rgba(var(--accent-rgb),0.4);
  background:linear-gradient(135deg, rgba(var(--accent-rgb),0.1), rgba(var(--accent-2-rgb),0.06));
  box-shadow:0 10px 24px -12px rgba(var(--accent-rgb),0.35);
}

.languages{margin-top:80px;}
.languages h3{
  font-family:var(--font-head);
  font-size:15px;
  font-weight:600;
  color:var(--text-dim);
  margin-bottom:22px;
  text-transform:uppercase;
  letter-spacing:.04em;
}
.lang-row{
  display:flex;
  flex-direction:column;
  gap:22px;
  max-width:480px;
}
.lang-head{
  display:flex;
  justify-content:space-between;
  font-size:14px;
  margin-bottom:8px;
}
.lang-head span:first-child{font-weight:600;}
.lang-head span:last-child{color:var(--text-faint);}
.lang-bar{
  height:6px;
  border-radius:100px;
  background:var(--border);
  overflow:hidden;
}
.lang-bar-fill{
  height:100%;
  width:0%;
  border-radius:100px;
  background:linear-gradient(90deg,var(--accent),var(--accent-2));
  transition:width 1.4s var(--ease);
}

/* ============ Contact ============ */
.contact-section{
  text-align:center;
}
.contact-inner{
  display:flex;
  flex-direction:column;
  align-items:center;
}
.contact-section .section-title{max-width:520px;}
.contact-sub{
  color:var(--text-dim);
  margin-bottom:40px;
}
.contact-links{
  display:flex;
  gap:16px;
}

/* ============ Footer ============ */
.site-footer{
  border-top:1px solid var(--border);
  padding:32px 0;
}
.footer-inner{
  display:flex;
  justify-content:space-between;
  align-items:center;
  font-size:13px;
  color:var(--text-faint);
}
.footer-right{
  display:flex;
  align-items:center;
  gap:20px;
}
.footer-link{
  color:var(--text-faint);
  transition:color .3s var(--ease);
}
.footer-link:hover{color:var(--accent);}

/* ============ Legal pages (Impressum) ============ */
.legal-section{
  padding-top:180px;
}
.legal-block{
  max-width:640px;
}
.legal-block h2{
  font-family:var(--font-head);
  font-size:16px;
  font-weight:600;
  color:var(--text);
  margin-top:44px;
  margin-bottom:12px;
}
.legal-block h2:first-of-type{margin-top:0;}
.legal-block p{
  color:var(--text-dim);
  font-size:15px;
  line-height:1.75;
  margin-bottom:4px;
}
.legal-back{margin-top:56px; display:inline-flex;}

/* ============ Responsive ============ */
@media (max-width:860px){
  .about-grid{grid-template-columns:1fr; gap:40px;}
  .about-visual{justify-content:flex-start;}
  .skills-groups{grid-template-columns:1fr; gap:36px;}
  .nav-links{
    position:fixed;
    top:0; right:0;
    height:100vh;
    width:min(78vw,320px);
    background:var(--nav-mobile-bg);
    backdrop-filter:blur(20px);
    flex-direction:column;
    justify-content:center;
    gap:32px;
    padding:0 40px;
    transform:translateX(100%);
    transition:transform .45s var(--ease);
    border-left:1px solid var(--border);
  }
  .nav-links.open{transform:translateX(0);}
  .nav-links a{font-size:17px;}
  .nav-burger{display:flex;}
  .section{padding:100px 0;}
  .timeline-wrap{grid-template-columns:24px 1fr; gap:16px;}
  .timeline-rail{margin-left:11px;}
  .timeline-dot{left:-32px;}
}

@media (max-width:520px){
  .hero-cta{flex-direction:column; width:100%;}
  .stat-row{gap:32px; flex-wrap:wrap;}
}
