/*
Theme Name: Portfolio
Theme URI:
Author: Valentin Jobstmann
Description: Professional portfolio theme.
Version: 9.0
License: GNU General Public License v2 or later
*/

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

:root {
  --white: #ffffff;
  --offwhite: #f5f7fa;
  --text: #1e293b;
  --text-light: #64748b;
  --blue: #1e40af;
  --blue-light: #e8edf6;
  --border: #e2e8f0;
  --font: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Helvetica, Arial, sans-serif;
}

body {
  font-family: var(--font);
  background: var(--white);
  color: var(--text);
  line-height: 1.7;
  font-size: 15px;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

a { color: var(--blue); text-decoration: none; }
a:hover { text-decoration: underline; }
img { max-width: 100%; height: auto; display: block; }

.wrap { max-width: 1060px; margin: 0 auto; padding: 0 2rem; width: 100%; }

/* ── Header ── */
.site-header {
  background: rgba(255,255,255,0.92);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
  padding: 1rem 0;
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
}
.site-header .wrap {
  display: flex;
  justify-content: center;
  align-items: center;
}
.site-logo {
  font-size: 1rem;
  font-weight: 700;
  color: var(--text);
  text-decoration: none;
}
.site-logo:hover { text-decoration: none; }
.site-logo span { color: var(--blue); }
.site-nav { display: flex; gap: 2rem; list-style: none; }
.site-nav a {
  font-size: 0.85rem;
  font-weight: 500;
  color: var(--text-light);
  text-decoration: none;
}
.site-nav a:hover { color: var(--blue); text-decoration: none; }

/* ── Scroll Scenes ── */
.scene {
  position: relative;
  height: 250vh;
  margin-bottom: -150vh; /* overlap scenes so transitions interleave */
  z-index: 1;
}
.scene:last-child { margin-bottom: 0; }
.scene-pin {
  position: sticky;
  top: 0;
  height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

.scene-hero { z-index: 1; }
.scene-services { z-index: 2; }
.scene-experience { z-index: 3; }
.scene-projects { z-index: 4; }
.scene-contact { z-index: 5; }
.scene-impressum { z-index: 6; }

.scene-hero .scene-pin { background: var(--offwhite); }
.scene-services .scene-pin { background: rgba(255,255,255,0); }
.scene-experience .scene-pin { background: rgba(245,247,250,0); }
.scene-projects .scene-pin { background: rgba(255,255,255,0); }
.scene-contact .scene-pin { background: rgba(245,247,250,0); }
.scene-impressum .scene-pin { background: rgba(255,255,255,0); }

/* ── Impressum ── */
.impressum-content {
  max-width: 600px;
  width: 100%;
}
.impressum-content h2 {
  font-size: 1.5rem;
  font-weight: 700;
  margin-bottom: 1.5rem;
}
.impressum-content p {
  font-size: 0.85rem;
  color: var(--text-light);
  line-height: 1.8;
  margin-bottom: 1rem;
}

/* ── 3D Nav Cube ── */
.nav-cube-wrap {
  position: fixed;
  bottom: 2rem;
  right: 2rem;
  z-index: 99;
  perspective: 500px;
}
.nav-cube {
  width: 100px;
  height: 100px;
  position: relative;
  transform-style: preserve-3d;
  will-change: transform;
}
.nav-cube-face {
  position: absolute;
  width: 100px;
  height: 100px;
  border: 2px solid var(--blue);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 0.6rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--blue);
  background: rgba(255,255,255,0.92);
  border-radius: 2px;
  line-height: 1.3;
  text-align: center;
  padding: 6px;
}
.nav-cube-face.front  { transform: translateZ(50px); }
.nav-cube-face.back   { transform: rotateY(180deg) translateZ(50px); }
.nav-cube-face.right  { transform: rotateY(90deg) translateZ(50px); }
.nav-cube-face.left   { transform: rotateY(-90deg) translateZ(50px); }
.nav-cube-face.top    { transform: rotateX(90deg) translateZ(50px); }
.nav-cube-face.bottom { transform: rotateX(-90deg) translateZ(50px); }

/* ── Hero ── */
.hero-grid {
  display: grid;
  grid-template-columns: 1fr 240px;
  gap: 4rem;
  align-items: center;
  width: 100%;
}
.hero-eyebrow {
  font-size: 0.8rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--blue);
  margin-bottom: 0.75rem;
}
.hero-content h1 {
  font-size: 2.25rem;
  font-weight: 700;
  line-height: 1.25;
  letter-spacing: -0.02em;
  margin-bottom: 1rem;
}
.hero-content p {
  font-size: 1rem;
  color: var(--text-light);
  max-width: 500px;
  line-height: 1.75;
  margin-bottom: 2rem;
}
.hero-cta {
  display: inline-block;
  padding: 0.65rem 1.75rem;
  background: var(--blue);
  color: var(--white) !important;
  font-size: 0.85rem;
  font-weight: 600;
  border-radius: 4px;
  text-decoration: none !important;
}
.hero-cta:hover { background: #1e3a8a; }
.hero-photo img {
  width: 240px;
  height: 280px;
  object-fit: cover;
  border-radius: 4px;
}

/* ── Section Common ── */
.section-header {
  text-align: center;
  margin-bottom: 3rem;
}
.section-header h2 {
  font-size: 1.5rem;
  font-weight: 700;
  margin-bottom: 0.5rem;
}
.section-header p {
  font-size: 0.9rem;
  color: var(--text-light);
  max-width: 480px;
  margin: 0 auto;
}
.section-header .line {
  display: block;
  width: 40px;
  height: 3px;
  background: var(--blue);
  margin: 1rem auto 0;
}

/* ── Services ── */
.services-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
}
.service-card {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: 4px;
  padding: 2rem 1.5rem;
  text-align: center;
  will-change: transform, opacity;
}
.service-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 48px;
  height: 48px;
  background: var(--blue-light);
  border-radius: 4px;
  margin-bottom: 1.25rem;
  font-size: 1.25rem;
}
.service-card h3 { font-size: 0.95rem; font-weight: 600; margin-bottom: 0.5rem; }
.service-card p { font-size: 0.82rem; color: var(--text-light); line-height: 1.6; }

/* ── Experience ── */
.timeline { list-style: none; max-width: 680px; }
.timeline-item {
  position: relative;
  padding-left: 1.75rem;
  padding-bottom: 2.25rem;
  border-left: 2px solid var(--border);
  will-change: transform, opacity;
}
.timeline-item:last-child { padding-bottom: 0; }
.timeline-item::before {
  content: '';
  position: absolute;
  left: -5px;
  top: 5px;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--blue);
}
.timeline-item h3 { font-size: 0.95rem; font-weight: 600; margin-bottom: 0.15rem; }
.timeline-item .meta { font-size: 0.8rem; color: var(--blue); font-weight: 500; margin-bottom: 0.4rem; }
.timeline-item p { font-size: 0.85rem; color: var(--text-light); }

/* ── Projects ── */
.projects-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1.5rem;
}
.project-card {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: 4px;
  overflow: hidden;
  will-change: transform, opacity;
}
.project-thumb { width: 100%; height: 190px; object-fit: cover; }
.project-body { padding: 1.25rem; }
.project-body h3 { font-size: 0.95rem; font-weight: 600; margin-bottom: 0.35rem; }
.project-body p { font-size: 0.82rem; color: var(--text-light); margin-bottom: 0.75rem; line-height: 1.6; }
.tags { display: flex; flex-wrap: wrap; gap: 0.35rem; }
.tag {
  font-size: 0.7rem;
  font-weight: 500;
  padding: 0.2rem 0.55rem;
  background: var(--blue-light);
  border-radius: 3px;
  color: var(--blue);
}

/* ── Contact ── */
.contact-box {
  background: var(--blue);
  color: var(--white);
  border-radius: 4px;
  padding: 3.5rem;
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 2rem;
  align-items: center;
  will-change: transform, opacity;
}
.contact-box h2 { font-size: 1.5rem; font-weight: 700; margin-bottom: 0.5rem; }
.contact-box p { font-size: 0.9rem; opacity: 0.85; }
.contact-links { display: flex; gap: 0.75rem; }
.contact-btn {
  display: inline-block;
  padding: 0.6rem 1.5rem;
  background: var(--white);
  color: var(--blue) !important;
  font-size: 0.85rem;
  font-weight: 600;
  border-radius: 4px;
  text-decoration: none !important;
}
.contact-btn:hover { background: #e8edf6; }
.contact-btn-outline {
  display: inline-block;
  padding: 0.6rem 1.5rem;
  background: transparent;
  color: var(--white) !important;
  font-size: 0.85rem;
  font-weight: 500;
  border-radius: 4px;
  border: 1px solid rgba(255,255,255,0.3);
  text-decoration: none !important;
}
.contact-btn-outline:hover { border-color: rgba(255,255,255,0.7); }

/* ── Footer ── */
.site-footer {
  padding: 2rem 0;
  border-top: 1px solid var(--border);
  font-size: 0.8rem;
  color: var(--text-light);
}
.site-footer .wrap {
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.footer-links { display: flex; gap: 1.5rem; }
.footer-links a { font-size: 0.8rem; color: var(--text-light); text-decoration: none; }
.footer-links a:hover { color: var(--blue); }

/* ── Responsive ── */
@media (max-width: 768px) {
  .hero-grid { grid-template-columns: 1fr; gap: 2rem; }
  .hero-photo { order: -1; }
  .hero-photo img { width: 160px; height: 180px; }
  .services-grid { grid-template-columns: 1fr; }
  .projects-grid { grid-template-columns: 1fr; }
  .contact-box { grid-template-columns: 1fr; text-align: center; }
  .contact-links { justify-content: center; }
}
