/* c1zztem — software · dezent / dunkel / minimal */

:root {
  --bg:        #0c0e12;
  --bg-alt:    #11141a;
  --surface:   #161a22;
  --border:    #232936;
  --text:      #e6e9ef;
  --muted:     #9aa3b2;
  --accent:    #4ade80;
  --accent-dim: #22c55e;
  --radius:    14px;
  --maxw:      1080px;
  --font: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  --mono: "SF Mono", "JetBrains Mono", "Fira Code", ui-monospace, Menlo, Consolas, monospace;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: var(--font);
  background: var(--bg);
  color: var(--text);
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

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

.container.narrow { max-width: 720px; }

a { color: inherit; text-decoration: none; }

.accent { color: var(--accent); }

.skip-link {
  position: absolute;
  left: -999px;
  top: 0;
  background: var(--accent);
  color: #052e16;
  padding: 10px 16px;
  border-radius: 0 0 8px 0;
  z-index: 100;
}
.skip-link:focus { left: 0; }

/* ---------- Header / Nav ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(12, 14, 18, 0.78);
  backdrop-filter: saturate(140%) blur(12px);
  border-bottom: 1px solid var(--border);
}

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

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 600;
  letter-spacing: -0.01em;
}

.brand-mark {
  display: grid;
  place-items: center;
  width: 32px;
  height: 32px;
  border-radius: 8px;
  background: var(--surface);
  border: 1px solid var(--border);
  color: var(--accent);
  font-family: var(--mono);
  font-size: 14px;
  font-weight: 700;
}

.brand-sub { color: var(--muted); font-weight: 400; margin-left: 4px; }

.nav-links {
  display: flex;
  align-items: center;
  gap: 28px;
  font-size: 15px;
}

.nav-links a { color: var(--muted); transition: color .18s ease; }
.nav-links a:hover { color: var(--text); }

.nav-cta {
  color: var(--text) !important;
  border: 1px solid var(--border);
  padding: 7px 16px;
  border-radius: 999px;
  transition: border-color .18s ease, background .18s ease;
}
.nav-cta:hover { border-color: var(--accent); background: rgba(74,222,128,0.06); }

/* ---------- Hero ---------- */
.hero {
  position: relative;
  padding: clamp(72px, 14vw, 150px) 0 clamp(56px, 9vw, 110px);
  overflow: hidden;
}

.hero::before {
  content: "";
  position: absolute;
  top: -200px;
  left: 50%;
  transform: translateX(-50%);
  width: 760px;
  height: 760px;
  background: radial-gradient(circle, rgba(34,197,94,0.10), transparent 62%);
  pointer-events: none;
}

.eyebrow {
  font-family: var(--mono);
  font-size: 13px;
  letter-spacing: 0.04em;
  color: var(--accent-dim);
  margin: 0 0 18px;
}

.hero h1 {
  font-size: clamp(34px, 6vw, 60px);
  line-height: 1.08;
  letter-spacing: -0.02em;
  margin: 0 0 22px;
  font-weight: 700;
}

.lead {
  font-size: clamp(16px, 2.2vw, 19px);
  color: var(--muted);
  max-width: 620px;
  margin: 0 0 34px;
}

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

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 12px 24px;
  border-radius: 999px;
  font-size: 15px;
  font-weight: 600;
  border: 1px solid transparent;
  transition: transform .12s ease, background .18s ease, border-color .18s ease;
}
.btn:active { transform: translateY(1px); }

.btn-primary { background: var(--accent); color: #052e16; }
.btn-primary:hover { background: #86efac; }

.btn-ghost { border-color: var(--border); color: var(--text); }
.btn-ghost:hover { border-color: var(--accent); }

/* ---------- Sections ---------- */
.section { padding: clamp(64px, 10vw, 104px) 0; }
.section-alt { background: var(--bg-alt); border-top: 1px solid var(--border); border-bottom: 1px solid var(--border); }

.section-title {
  font-size: clamp(26px, 4vw, 36px);
  letter-spacing: -0.02em;
  margin: 0 0 14px;
}

.section-intro {
  color: var(--muted);
  font-size: 17px;
  max-width: 620px;
  margin: 0 0 44px;
}

/* ---------- Cards ---------- */
.cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 20px;
}

.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 28px 26px;
  transition: border-color .2s ease, transform .2s ease;
}
.card:hover { border-color: var(--accent-dim); transform: translateY(-3px); }

.card-icon {
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  border-radius: 10px;
  background: rgba(74,222,128,0.08);
  color: var(--accent);
  font-family: var(--mono);
  font-size: 18px;
  margin-bottom: 18px;
}

.card h3 { margin: 0 0 8px; font-size: 19px; }
.card p { margin: 0; color: var(--muted); font-size: 15px; }

/* ---------- Steps ---------- */
.steps {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 28px;
  counter-reset: none;
}

.steps li { position: relative; padding-top: 8px; }

.step-num {
  font-family: var(--mono);
  font-size: 14px;
  color: var(--accent-dim);
  display: block;
  margin-bottom: 10px;
}

.steps h3 { margin: 0 0 8px; font-size: 19px; }
.steps p { margin: 0; color: var(--muted); font-size: 15px; }

/* ---------- About ---------- */
.about-text { color: var(--muted); font-size: 17px; margin: 0 0 18px; }

/* ---------- Contact ---------- */
.contact-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 8px 24px;
  margin: 0 0 28px;
}

.contact-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px 16px;
  flex-wrap: wrap;
  padding: 16px 0;
  transition: color .18s ease;
}
.contact-row:hover .contact-value { color: var(--accent); }

.contact-label { color: var(--muted); font-size: 14px; }
.contact-value {
  font-family: var(--mono);
  font-size: 15px;
  word-break: break-word;
  overflow-wrap: anywhere;
}

.contact-btn { margin-top: 4px; }

/* ---------- Footer ---------- */
.site-footer {
  border-top: 1px solid var(--border);
  padding: 28px 0;
  background: var(--bg-alt);
}

.footer-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
  font-size: 14px;
}

.footer-brand { color: var(--muted); }
.footer-links { display: flex; gap: 22px; }
.footer-links a { color: var(--muted); transition: color .18s ease; }
.footer-links a:hover { color: var(--text); }

/* ---------- Legal pages ---------- */
.legal { padding: clamp(56px, 9vw, 96px) 0; }
.legal h1 { font-size: clamp(28px, 4vw, 38px); letter-spacing: -0.02em; margin: 0 0 8px; }
.legal h2 { font-size: 20px; margin: 36px 0 10px; }
.legal p, .legal address { color: var(--muted); font-size: 16px; margin: 0 0 14px; font-style: normal; }
.legal a { color: var(--accent); }
.back-link { font-family: var(--mono); font-size: 14px; color: var(--muted); display: inline-block; margin-bottom: 28px; }
.back-link:hover { color: var(--text); }
.legal-stand { margin-top: 32px; font-size: 14px; }
.placeholder { color: var(--accent-dim); font-style: italic; }

/* ---------- Responsive ---------- */
@media (max-width: 640px) {
  .nav-links { gap: 16px; font-size: 14px; }
  .nav-links a:not(.nav-cta) { display: none; }
  .brand-sub { display: none; }

  .contact-card { padding: 4px 18px; }
  .contact-row {
    flex-direction: column;
    align-items: flex-start;
    gap: 4px;
  }
  .contact-btn { width: 100%; }
}

@media (prefers-reduced-motion: reduce) {
  * { scroll-behavior: auto !important; transition: none !important; }
}

/* ---------- Projects (CV) ---------- */
.projects { display: grid; gap: 20px; }

.project {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 28px 26px;
  transition: border-color .2s ease;
}
.project:hover { border-color: var(--accent-dim); }

.project-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 6px 16px;
  margin-bottom: 10px;
}
.project-head h3 { margin: 0; font-size: 20px; }

.project-link {
  font-family: var(--mono);
  font-size: 14px;
  color: var(--accent);
}
.project-link:hover { color: #86efac; }
.project-link.muted { color: var(--muted); }

.project p { margin: 0 0 16px; color: var(--muted); font-size: 15px; }

.tags {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.tags li {
  font-family: var(--mono);
  font-size: 12.5px;
  color: var(--accent-dim);
  background: rgba(74,222,128,0.07);
  border: 1px solid rgba(74,222,128,0.18);
  border-radius: 999px;
  padding: 3px 11px;
}

/* ---------- Character: terminal & stars (c1zz.de only) ---------- */
::selection { background: rgba(74,222,128,0.28); color: #f0fdf4; }

::-webkit-scrollbar { width: 10px; }
::-webkit-scrollbar-track { background: var(--bg); }
::-webkit-scrollbar-thumb { background: var(--border); border-radius: 5px; }
::-webkit-scrollbar-thumb:hover { background: var(--accent-dim); }

/* blinking block cursor after the hero prompt */
.cursor {
  display: inline-block;
  width: 9px;
  height: 1.05em;
  margin-left: 7px;
  vertical-align: text-bottom;
  background: var(--accent);
  animation: blink 1.1s steps(1) infinite;
}
@keyframes blink { 50% { opacity: 0; } }

/* layered star field, fading out toward the hero bottom */
.hero::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background-image:
    radial-gradient(1px 1px at 25px 35px,   rgba(230,233,239,0.75), transparent),
    radial-gradient(1px 1px at 210px 140px, rgba(74,222,128,0.55),  transparent),
    radial-gradient(1.5px 1.5px at 340px 60px, rgba(230,233,239,0.55), transparent),
    radial-gradient(1px 1px at 110px 210px, rgba(230,233,239,0.45), transparent),
    radial-gradient(1px 1px at 460px 170px, rgba(74,222,128,0.4),   transparent);
  background-size: 520px 300px, 460px 340px, 610px 280px, 380px 260px, 550px 320px;
  background-repeat: repeat;
  -webkit-mask-image: linear-gradient(to bottom, rgba(0,0,0,0.9) 0%, transparent 78%);
  mask-image: linear-gradient(to bottom, rgba(0,0,0,0.9) 0%, transparent 78%);
  animation: twinkle 7s ease-in-out infinite alternate;
}
@keyframes twinkle {
  from { opacity: 0.5; }
  to   { opacity: 1; }
}

/* section titles as terminal paths */
.section-title {
  font-family: var(--mono);
  font-size: clamp(23px, 3.4vw, 31px);
  font-weight: 600;
  letter-spacing: -0.01em;
}
.path-prefix { color: var(--accent-dim); }

/* a bit more life on hover */
.project:hover {
  box-shadow: 0 0 0 1px rgba(74,222,128,0.10), 0 14px 36px -20px rgba(74,222,128,0.35);
}
.project:hover .tags li { border-color: rgba(74,222,128,0.38); }

.btn-primary:hover { box-shadow: 0 0 26px -6px rgba(74,222,128,0.55); }

.contact-label { font-family: var(--mono); }

/* tag pills must never wrap internally */
.tags li { white-space: nowrap; }

/* ---------- Contact form ---------- */
.contact-grid { display: grid; gap: 36px; }
@media (min-width: 800px) {
  .contact-grid {
    grid-template-columns: 1fr 1.5fr;
    gap: 64px;
    align-items: start;
  }
  /* optically align the intro with the first input row, not the tiny label */
  .contact-info { padding-top: 34px; }
}
.contact-info .section-intro { margin-bottom: 26px; }
.contact-hint {
  margin: 18px 0 0;
  font-family: var(--mono);
  font-size: 13px;
  color: var(--muted);
}

.contact-form { margin-top: 0; }

.form-row { margin-bottom: 16px; }
.form-row label {
  display: block;
  font-family: var(--mono);
  font-size: 13px;
  color: var(--accent-dim);
  margin-bottom: 6px;
}
.form-row label::before { content: "> "; opacity: 0.6; }
.form-opt { color: var(--muted); }

.form-row input,
.form-row textarea {
  width: 100%;
  padding: 11px 14px;
  font-family: var(--mono);
  font-size: 14px;
  color: var(--text);
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 3px;
  caret-color: var(--accent);
  transition: border-color .18s ease, box-shadow .18s ease;
}
.form-row textarea { resize: vertical; min-height: 120px; }
.form-row input:focus,
.form-row textarea:focus {
  outline: none;
  border-color: var(--accent-dim);
  box-shadow: 0 0 14px -6px rgba(74,222,128,0.55);
}

/* honeypot: off-screen, still submittable by naive bots */
.form-hp {
  position: absolute;
  left: -9999px;
  width: 1px;
  height: 1px;
  opacity: 0;
}

.form-actions {
  display: flex;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
}
.form-status {
  margin: 0;
  font-family: var(--mono);
  font-size: 13.5px;
  color: var(--accent);
}
.form-status.is-error { color: #fca5a5; }

.contact-direct {
  margin: 0;
  font-family: var(--mono);
  font-size: 13.5px;
  line-height: 2;
  color: var(--muted);
}
.contact-direct a { color: var(--accent); }
.contact-direct a:hover { color: #86efac; }

.footer-exit {
  font-family: var(--mono);
  font-size: 12.5px;
  color: var(--muted);
  opacity: 0.65;
}

@media (prefers-reduced-motion: reduce) {
  .cursor, .hero::after { animation: none !important; }
}

/* structured background: hexagon mesh + film grain (inline SVG, no requests).
   Lives on a fixed layer so the pattern stays put while the page scrolls. */
body { background-color: var(--bg); }
body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  background-image:
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='180' height='180'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2'/%3E%3C/filter%3E%3Crect width='180' height='180' filter='url(%23n)' opacity='0.06'/%3E%3C/svg%3E"),
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='28' height='50' viewBox='0 0 56 100'%3E%3Cg fill='none' stroke='%234ade80' stroke-opacity='0.11' stroke-width='2'%3E%3Cpath d='M28 0V17L0 33V67L28 83V100'/%3E%3Cpath d='M28 17L56 33V67L28 83'/%3E%3C/g%3E%3C/svg%3E");
  background-size: 180px 180px, 28px 50px;
}

/* let the grid shimmer through the alt sections and footer */
.section-alt { background: rgba(17, 20, 26, 0.72); }
.site-footer { background: rgba(17, 20, 26, 0.72); }

/* ---------- Terminal chat ---------- */
.term-toggle {
  position: fixed;
  right: 18px;
  bottom: 18px;
  z-index: 70;
  width: 48px;
  height: 48px;
  border-radius: 12px;
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--accent);
  font-family: var(--mono);
  font-size: 16px;
  font-weight: 700;
  cursor: pointer;
  transition: border-color .18s ease, box-shadow .18s ease;
}
.term-toggle:hover { border-color: var(--accent); box-shadow: 0 0 20px -6px rgba(74,222,128,0.5); }

.term[hidden] { display: none; }

.term {
  position: fixed;
  right: 18px;
  bottom: 76px;
  z-index: 70;
  width: min(420px, calc(100vw - 36px));
  height: min(460px, 65vh);
  display: flex;
  flex-direction: column;
  background: rgba(12, 14, 18, 0.97);
  border: 1px solid var(--border);
  border-radius: 12px;
  box-shadow: 0 24px 60px -24px rgba(0,0,0,0.8), 0 0 0 1px rgba(74,222,128,0.06);
  overflow: hidden;
}

.term-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 14px;
  border-bottom: 1px solid var(--border);
  background: var(--bg-alt);
}
.term-title { font-family: var(--mono); font-size: 12.5px; color: var(--muted); }
.term-close {
  border: 0;
  background: none;
  color: var(--muted);
  font-size: 18px;
  line-height: 1;
  cursor: pointer;
  padding: 2px 6px;
}
.term-close:hover { color: var(--text); }

.term-body {
  flex: 1;
  overflow-y: auto;
  padding: 12px 14px;
  font-family: var(--mono);
  font-size: 13px;
  line-height: 1.6;
}
.term-line { white-space: pre-wrap; overflow-wrap: anywhere; }
.term-line a { color: var(--accent); }
.term-line a:hover { color: #86efac; }
.term-echo { color: var(--muted); margin-top: 6px; }
.term-muted { color: var(--muted); }

.term-input-row {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 14px;
  border-top: 1px solid var(--border);
}
.term-ps1 { font-family: var(--mono); color: var(--accent); font-size: 13px; }
.term-input-row input {
  flex: 1;
  border: 0;
  outline: 0;
  background: none;
  color: var(--text);
  font-family: var(--mono);
  font-size: 13px;
  caret-color: var(--accent);
}

@media (max-width: 640px) {
  .term {
    left: 12px;
    right: 12px;
    bottom: 74px;
    width: auto;
    height: min(400px, 55vh);
  }
  .term-toggle { right: 12px; bottom: 14px; }
}

/* project screenshots: desktop-only thumbnail column */
.project-shot { display: none; }
@media (min-width: 720px) {
  .project {
    display: grid;
    grid-template-columns: 1fr 250px;
    column-gap: 26px;
    align-items: start;
  }
  .project-head, .project p, .project .tags { grid-column: 1; }
  .project-shot {
    display: block;
    grid-column: 2;
    grid-row: 1 / span 3;
    position: relative;
  }
  .project-shot img {
    display: block;
    width: 100%;
    height: auto;
    border: 1px solid var(--border);
    border-radius: 6px;
    transition: border-color .2s ease;
  }
  /* CRT scanlines on the thumbs, matching the terminal screen */
  .project-shot::after {
    content: "";
    position: absolute;
    inset: 0;
    border-radius: 6px;
    pointer-events: none;
    background: repeating-linear-gradient(0deg, rgba(0,0,0,0.12) 0 1px, transparent 1px 3px);
  }
  .project:hover .project-shot img { border-color: var(--accent-dim); }
}

/* c1zztem logo in the Auftragsarbeit section */
.auftrag-logo {
  display: block;
  height: 68px;
  width: auto;
  margin: 6px 0 22px;
}
@media (max-width: 640px) {
  .auftrag-logo { height: 56px; }
}

/* ---------- 80s CRT touches ---------- */

/* TUI-style buttons: sharp corners, mono; ghost buttons get brackets */
.btn,
.nav-cta {
  border-radius: 3px;
  font-family: var(--mono);
}
.btn-ghost::before { content: "[ "; color: var(--accent-dim); }
.btn-ghost::after  { content: " ]"; color: var(--accent-dim); }
.tags li { border-radius: 3px; }
.term-toggle { border-radius: 5px; }

/* scanlines + corner vignette over the whole page */
body::after {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 100;
  pointer-events: none;
  background:
    repeating-linear-gradient(0deg, rgba(0, 0, 0, 0.11) 0 1px, transparent 1px 3px),
    radial-gradient(ellipse at center, transparent 62%, rgba(0, 0, 0, 0.26) 100%);
}

/* soft phosphor glow on mono/accent elements */
.eyebrow,
.path-prefix,
.term-ps1 { text-shadow: 0 0 8px rgba(74, 222, 128, 0.45); }
.section-title { text-shadow: 0 0 10px rgba(230, 233, 239, 0.18); }
.cursor { box-shadow: 0 0 10px rgba(74, 222, 128, 0.6); }
.brand-hex { display: block; filter: drop-shadow(0 0 6px rgba(74, 222, 128, 0.4)); }
.brand .brand-sub { margin-left: 0; }

/* hero prompt types itself on load */
.typed {
  display: inline-block;
  overflow: hidden;
  white-space: nowrap;
  vertical-align: bottom;
  width: 6ch;
  animation: typing 1.1s steps(6) 0.5s backwards;
}
@keyframes typing { from { width: 0; } }

/* chat terminal: CRT power-on + green scanlines on its screen */
.term { animation: crt-on 0.22s ease-out; }
@keyframes crt-on {
  0%   { transform: scaleY(0.04); filter: brightness(2); }
  70%  { transform: scaleY(1.02); }
  100% { transform: scaleY(1); filter: brightness(1); }
}
.term::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  border-radius: inherit;
  background: repeating-linear-gradient(0deg, rgba(74, 222, 128, 0.035) 0 1px, transparent 1px 3px);
}
.term-body a { text-shadow: 0 0 8px rgba(74, 222, 128, 0.4); }

@media (prefers-reduced-motion: reduce) {
  .typed, .term { animation: none !important; }
}

