/* ============================================================
   claren.io — Philip Claren, IT Consulting
   Kein Build-Step, keine externen Abhängigkeiten.
   ============================================================ */

:root {
  --bg: #07090f;
  --bg-elevated: #0d1119;
  --surface: rgba(255, 255, 255, 0.04);
  --border: rgba(255, 255, 255, 0.09);
  --text: #e8ecf4;
  --text-muted: #9aa3b5;
  --accent-1: #38bdf8;   /* cyan */
  --accent-2: #818cf8;   /* indigo */
  --accent-3: #f472b6;   /* pink */
  --radius: 18px;
  --font-sans: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  --font-mono: ui-monospace, "SF Mono", SFMono-Regular, Menlo, Consolas, monospace;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-sans);
  font-size: 17px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

.container {
  max-width: 1080px;
  margin: 0 auto;
  padding-left: 24px;
  padding-right: 24px;
}

::selection { background: var(--accent-2); color: #fff; }

/* ---------- Aurora background ---------- */

.aurora {
  position: fixed;
  inset: 0;
  z-index: -1;
  overflow: hidden;
}

/* Weiche Gradients statt filter:blur() — deutlich günstiger fürs Rendering */
.aurora-blob {
  position: absolute;
  border-radius: 50%;
  will-change: transform;
}

.aurora-1 {
  width: 70vw; height: 70vw;
  top: -30vw; left: -18vw;
  background: radial-gradient(circle, rgba(129, 140, 248, 0.28), rgba(129, 140, 248, 0.10) 40%, transparent 70%);
  animation: drift-1 26s ease-in-out infinite alternate;
}

.aurora-2 {
  width: 60vw; height: 60vw;
  top: 0; right: -22vw;
  background: radial-gradient(circle, rgba(56, 189, 248, 0.22), rgba(56, 189, 248, 0.08) 40%, transparent 70%);
  animation: drift-2 32s ease-in-out infinite alternate;
}

.aurora-3 {
  width: 55vw; height: 55vw;
  bottom: -30vw; left: 25vw;
  background: radial-gradient(circle, rgba(244, 114, 182, 0.16), rgba(244, 114, 182, 0.06) 40%, transparent 70%);
  animation: drift-3 38s ease-in-out infinite alternate;
}

@keyframes drift-1 { to { transform: translate(8vw, 6vw) scale(1.15); } }
@keyframes drift-2 { to { transform: translate(-10vw, 8vw) scale(0.9); } }
@keyframes drift-3 { to { transform: translate(-6vw, -8vw) scale(1.2); } }

@media (prefers-reduced-motion: reduce) {
  .aurora-blob { animation: none; }
  html { scroll-behavior: auto; }
}

/* ---------- Header / Nav ---------- */

.site-header {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  background: rgba(7, 9, 15, 0.55);
  border-bottom: 1px solid transparent;
  transition: border-color 0.3s;
}

.site-header.scrolled { border-bottom-color: var(--border); }

.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 68px;
}

.brand {
  font-family: var(--font-mono);
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--text);
  text-decoration: none;
  letter-spacing: -0.02em;
}

.brand .accent {
  background: linear-gradient(90deg, var(--accent-1), var(--accent-2));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 32px;
  list-style: none;
}

.nav-links a {
  color: var(--text-muted);
  text-decoration: none;
  font-size: 0.95rem;
  font-weight: 500;
  transition: color 0.2s;
}

.nav-links a:hover { color: var(--text); }

.nav-cta {
  padding: 9px 20px;
  border-radius: 999px;
  border: 1px solid var(--border);
  color: var(--text) !important;
  background: var(--surface);
  transition: border-color 0.2s, background 0.2s;
}

.nav-cta:hover {
  border-color: var(--accent-1);
  background: rgba(56, 189, 248, 0.1);
}

.lang-toggle {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 4px;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: var(--surface);
}

.lang-flag {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  text-decoration: none;
  filter: grayscale(70%);
  opacity: 0.45;
  transition: opacity 0.2s, filter 0.2s, background 0.2s;
}

.lang-flag svg {
  display: block;
  width: 18px;
  height: auto;
  border-radius: 2px;
  box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.18);
}

.lang-flag:hover { opacity: 0.8; filter: grayscale(20%); }

/* höhere Spezifität als ".nav-links a" (Mobile-Menü), damit display/padding
   dort nicht die Flex-Zentrierung des Flaggen-Links überschreiben */
.nav-links a.lang-flag {
  display: flex;
  padding: 0;
}

.lang-flag.is-active {
  opacity: 1;
  filter: none;
  background: rgba(255, 255, 255, 0.1);
  cursor: default;
}

.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 8px;
}

.nav-toggle span {
  display: block;
  width: 22px; height: 2px;
  background: var(--text);
  border-radius: 2px;
  transition: transform 0.25s, opacity 0.25s;
}

/* ---------- Reveal animation ---------- */

.reveal {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}

.reveal.visible {
  opacity: 1;
  transform: none;
}

@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; transition: none; }
}

/* ---------- Hero ---------- */

.hero {
  padding-top: clamp(140px, 22vh, 220px);
  padding-bottom: 100px;
}


.eyebrow {
  font-family: var(--font-mono);
  font-size: 0.85rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--accent-1);
  margin-bottom: 24px;
}

.hero h1 {
  font-size: clamp(2.1rem, 7vw, 5rem);
  hyphens: manual;
  line-height: 1.06;
  font-weight: 800;
  letter-spacing: -0.03em;
  margin-bottom: 32px;
}

.gradient-text {
  background: linear-gradient(100deg, var(--accent-1), var(--accent-2) 55%, var(--accent-3));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.hero-sub {
  max-width: 640px;
  font-size: 1.15rem;
  color: var(--text-muted);
  margin-bottom: 40px;
}

.hero-sub strong { color: var(--text); }

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  margin-bottom: 72px;
}

.btn {
  display: inline-block;
  padding: 14px 30px;
  border-radius: 999px;
  font-size: 1rem;
  font-weight: 600;
  text-decoration: none;
  transition: transform 0.2s, box-shadow 0.2s, background 0.2s, border-color 0.2s;
}

.btn-primary {
  background: linear-gradient(100deg, var(--accent-1), var(--accent-2));
  color: #050810;
  box-shadow: 0 8px 32px rgba(56, 189, 248, 0.25);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 12px 40px rgba(129, 140, 248, 0.4);
}

.btn-ghost {
  border: 1px solid var(--border);
  color: var(--text);
  background: var(--surface);
}

.btn-ghost:hover {
  border-color: var(--accent-2);
  transform: translateY(-2px);
}

.hero-stats {
  display: flex;
  flex-wrap: wrap;
  gap: 48px;
  border-top: 1px solid var(--border);
  padding-top: 32px;
}

.hero-stats dt {
  font-size: 1.6rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  background: linear-gradient(100deg, var(--accent-1), var(--accent-2));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.hero-stats dd { color: var(--text-muted); font-size: 0.92rem; }

/* ---------- Sections (generic) ---------- */

section { padding: 90px 24px; }

.section-label {
  font-family: var(--font-mono);
  font-size: 0.8rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent-3);
  margin-bottom: 16px;
}

h2 {
  font-size: clamp(1.9rem, 4vw, 2.8rem);
  font-weight: 800;
  letter-spacing: -0.02em;
  line-height: 1.15;
  margin-bottom: 48px;
}

/* ---------- Profil ---------- */

.profil { padding-top: 40px; }

.statement {
  font-size: clamp(1.4rem, 3vw, 2rem);
  font-weight: 600;
  line-height: 1.4;
  letter-spacing: -0.01em;
  max-width: 860px;
  margin-bottom: 28px;
}

.profil-text {
  max-width: 720px;
  color: var(--text-muted);
  font-size: 1.1rem;
}

/* ---------- Leistungen ---------- */

.cards {
  display: grid;
  grid-template-columns: 1fr;
  gap: 20px;
}

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

.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 32px 28px;
  transition: transform 0.25s, border-color 0.25s, background 0.25s;
}

.card:hover {
  transform: translateY(-4px);
  border-color: rgba(129, 140, 248, 0.5);
  background: rgba(129, 140, 248, 0.06);
}

.card-icon {
  font-size: 1.1rem;
  color: var(--accent-1);
  margin-bottom: 18px;
}

.card h3 {
  font-size: 1.2rem;
  font-weight: 700;
  margin-bottom: 12px;
  letter-spacing: -0.01em;
}

.card p { color: var(--text-muted); font-size: 0.97rem; }

/* ---------- Timeline ---------- */

.timeline {
  display: flex;
  flex-direction: column;
  gap: 0;
}

.tl-item {
  display: grid;
  grid-template-columns: 240px 1fr;
  gap: 32px;
  padding: 36px 0;
  border-top: 1px solid var(--border);
}

.tl-item:last-child { border-bottom: 1px solid var(--border); }

.tl-meta { display: flex; flex-direction: column; gap: 6px; }

.tl-period {
  font-family: var(--font-mono);
  font-size: 0.85rem;
  color: var(--accent-1);
}

.tl-client {
  font-size: 0.92rem;
  color: var(--text-muted);
  font-weight: 600;
}

.tl-body h3 {
  font-size: 1.25rem;
  font-weight: 700;
  letter-spacing: -0.01em;
  margin-bottom: 10px;
}

.tl-body p { color: var(--text-muted); font-size: 0.98rem; }

.tl-stack {
  font-family: var(--font-mono);
  font-size: 0.8rem !important;
  color: var(--accent-2) !important;
  margin-top: 14px;
}

.tl-more {
  margin-top: 28px;
  color: var(--text-muted);
  font-size: 0.92rem;
}

/* ---------- Expertise ---------- */

.skills {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
  gap: 20px;
}

.skill-group {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 28px 24px;
}

.skill-group h3 {
  font-family: var(--font-mono);
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--accent-1);
  margin-bottom: 18px;
}

.skill-group ul { list-style: none; }

.skill-group li {
  padding: 7px 0;
  color: var(--text-muted);
  font-size: 0.95rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.skill-group li:last-child { border-bottom: none; }

/* ---------- Buch ---------- */

.book-list {
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.book-card {
  display: grid;
  grid-template-columns: 200px 1fr;
  gap: 36px;
  align-items: start;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 32px;
}

.book-cover {
  width: 100%;
  height: auto;
  border-radius: 10px;
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.4);
}

.book-info h3 {
  font-size: 1.4rem;
  font-weight: 700;
  letter-spacing: -0.01em;
  margin-bottom: 10px;
}

.book-subtitle {
  color: var(--accent-2);
  font-size: 0.95rem;
  font-weight: 600;
  margin-bottom: 18px;
}

.book-info > p:not(.book-subtitle) {
  color: var(--text-muted);
  font-size: 0.98rem;
  margin-bottom: 26px;
}

.book-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
}

/* ---------- Kontakt ---------- */

.kontakt { padding-bottom: 120px; }

.kontakt-inner {
  background: linear-gradient(135deg, rgba(56, 189, 248, 0.08), rgba(129, 140, 248, 0.08) 50%, rgba(244, 114, 182, 0.08));
  border: 1px solid var(--border);
  border-radius: 28px;
  padding: clamp(40px, 6vw, 80px);
  text-align: center;
}

.kontakt-portrait {
  display: block;
  width: 96px;
  height: 96px;
  margin: 0 auto 20px;
  border-radius: 50%;
  object-fit: cover;
  border: 3px solid var(--bg);
  box-shadow: 0 0 0 1px var(--border), 0 12px 32px rgba(0, 0, 0, 0.4);
}

.kontakt-inner h2 { margin-bottom: 20px; }

.kontakt-inner > p {
  max-width: 560px;
  margin: 0 auto 36px;
  color: var(--text-muted);
  font-size: 1.08rem;
}

.kontakt-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 16px;
  margin-bottom: 40px;
}

.social {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 28px;
  list-style: none;
}

.social a {
  color: var(--text-muted);
  text-decoration: none;
  font-size: 0.95rem;
  font-weight: 500;
  transition: color 0.2s;
}

.social a:hover { color: var(--accent-1); }

/* ---------- Footer ---------- */

.site-footer {
  border-top: 1px solid var(--border);
  padding: 32px 0;
}

.footer-inner {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  justify-content: space-between;
  align-items: center;
  color: var(--text-muted);
  font-size: 0.88rem;
}

.footer-inner nav { display: flex; gap: 24px; }

.footer-inner a {
  color: var(--text-muted);
  text-decoration: none;
}

.footer-inner a:hover { color: var(--text); }

/* ---------- Unterseiten (Impressum / Datenschutz) ---------- */

.legal {
  padding-top: 140px;
  padding-bottom: 80px;
  max-width: 760px;
}

.legal h1 {
  font-size: clamp(2rem, 5vw, 3rem);
  font-weight: 800;
  letter-spacing: -0.02em;
  margin-bottom: 40px;
}

.legal h2 { font-size: 1.3rem; margin: 40px 0 12px; }

.legal p, .legal li { color: var(--text-muted); margin-bottom: 12px; }

.legal a { color: var(--accent-1); }

/* ---------- Responsive ---------- */

@media (max-width: 760px) {
  section { padding: 64px 24px; }

  .nav-toggle { display: flex; }

  .nav-links {
    position: absolute;
    top: 68px; left: 0; right: 0;
    flex-direction: column;
    align-items: flex-start;
    gap: 0;
    background: rgba(7, 9, 15, 0.97);
    border-bottom: 1px solid var(--border);
    padding: 12px 24px 24px;
    display: none;
  }

  .nav-links.open { display: flex; }

  .nav-links li { width: 100%; }

  .nav-links a {
    display: block;
    padding: 14px 0;
    font-size: 1.05rem;
  }

  .nav-cta {
    margin-top: 8px;
    text-align: center;
    padding: 14px 20px;
  }

  .nav-item-lang {
    display: flex;
    justify-content: center;
    margin-top: 10px;
  }

  .nav-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
  .nav-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
  .nav-toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

  .hero-stats { gap: 28px; }

  .tl-item {
    grid-template-columns: 1fr;
    gap: 12px;
  }

  .book-card {
    grid-template-columns: 1fr;
    padding: 24px;
  }

  .book-cover {
    width: 140px;
    margin: 0 auto;
  }

  .book-info { text-align: center; }

  .book-actions { justify-content: center; }
}
