/* ── Fonts ── */
@font-face {
  font-family: 'Atkinson Hyperlegible Next';
  src: url('/assets/fonts/atkinson-next-variable.woff2') format('woff2-variations');
  font-weight: 200 800;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: 'Atkinson Hyperlegible Next';
  src: url('/assets/fonts/atkinson-next-italic.woff2') format('woff2');
  font-weight: 400;
  font-style: italic;
  font-display: swap;
}
@font-face {
  font-family: 'Lexend';
  src: url('/assets/fonts/lexend-regular.woff2') format('woff2');
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: 'Lexend';
  src: url('/assets/fonts/lexend-semibold.woff2') format('woff2');
  font-weight: 600;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: 'Castoro';
  src: url('/assets/fonts/castoro-latin-400-normal.woff2') format('woff2');
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: 'Castoro';
  src: url('/assets/fonts/castoro-latin-400-italic.woff2') format('woff2');
  font-weight: 400;
  font-style: italic;
  font-display: swap;
}

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

/* ── Tokens ── */
:root {
  --gold:          #C8922A;
  --gold-light:    #FDF3E0;
  --gold-border:   rgba(200,146,42,0.2);
  --teal:          #1D9E75;
  --teal-light:    #E1F5EE;
  --teal-border:   rgba(29,158,117,0.2);
  --coral:         #D85A30;
  --coral-light:   #FAECE7;
  --coral-border:  rgba(216,90,48,0.2);
  --amber:         #BA7517;
  --amber-light:   #FAEEDA;
  --amber-border:  rgba(186,117,23,0.2);
  --purple:        #7C5CC4;
  --purple-light:  #EFEAFA;
  --purple-border: rgba(124,92,196,0.2);
  --ink:         #1C1A16;
  --ink-mid:     #5F5A50;
  --ink-soft:    #9A9285;
  --surface:     #FFFDF7;
  --border:      rgba(100,85,60,0.13);
  --font:        'Lexend', 'Atkinson Hyperlegible Next', system-ui, -apple-system, sans-serif;
  --font-serif:  'Castoro', Georgia, serif;
  --radius:      10px;
  --radius-sm:   6px;
}

/* ── Base ── */
html { font-size: 17px; -webkit-text-size-adjust: 100%; }
body {
  font-family: var(--font);
  background: var(--surface);
  color: var(--ink);
  line-height: 1.7;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}
a { color: inherit; text-decoration: none; }
main { flex: 1; position: relative; }

/* ── Nav ── */
.nav {
  position: sticky;
  top: 0;
  z-index: 100;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0 2rem;
  height: 56px;
  background: rgba(255,253,247,0.6);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 0.5px solid var(--border);
  overflow: hidden;
}
.nav-name {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  font-size: 15px;
  font-weight: 500;
  color: var(--ink);
  position: relative;
  z-index: 1;
  letter-spacing: 0.01em;
}
.nav-name:hover { color: var(--gold); }
.nav-links {
  display: flex;
  gap: 2rem;
  position: relative;
  z-index: 1;
}
.nav-links a {
  font-size: 13px;
  color: var(--ink-mid);
  transition: color 0.15s;
}
.nav-links a:hover { color: var(--gold); }

/* Dezenter Gold-Planet + Orbit als ruhiger Akzent neben dem Namen */
.nav-planet {
  position: relative;
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: var(--gold);
  pointer-events: none;
  flex-shrink: 0;
}
.nav-planet::before {
  content: '';
  position: absolute;
  left: 50%;
  top: 50%;
  width: 28px;
  height: 14px;
  border: 1px solid var(--gold);
  opacity: 0.3;
  border-radius: 50%;
  transform: translate(-50%, -50%) rotate(-20deg);
}
@media (max-width: 640px) { .nav-planet { display: none; } }

/* ── Footer ── */
.footer {
  position: relative;
  background: rgba(255,253,247,0.6);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-top: 0.5px solid var(--border);
  height: 52px;
}
.footer-inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  height: 100%;
  padding: 0 2rem;
  font-size: 12px;
  color: var(--ink-soft);
}
.footer-inner a {
  color: var(--ink-soft);
}
.footer-inner a:hover { color: var(--gold); }

/* ── Page wrapper ── */
.page {
  max-width: 760px;
  margin: 0 auto;
  padding: 3.5rem 2rem 4rem;
}
.page-wide {
  max-width: 860px;
  margin: 0 auto;
  padding: 3rem 2rem 4rem;
}

/* ── Hero ── */
.hero-label {
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.09em;
  text-transform: uppercase;
  color: var(--ink-soft);
  margin-bottom: 1rem;
}
.hero-heading {
  font-family: var(--font-serif);
  font-size: 34px;
  font-weight: 500;
  line-height: 1.3;
  color: var(--ink);
  margin-bottom: 1.25rem;
}
.hero-heading em {
  font-style: normal;
  color: var(--gold);
}

/* ── Tags ── */
.tag-row { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 0; margin-bottom: 0; }
.tag {
  display: inline-block;
  padding: 5px 14px;
  border-radius: 20px;
  font-size: 12px;
  font-weight: 500;
  border: 0.5px solid transparent;
}
.tag--kids   { background: var(--amber-light);  border-color: var(--amber-border);  color: var(--amber); }
.tag--online { background: var(--teal-light);   border-color: var(--teal-border);   color: var(--teal); }
.tag--psych  { background: var(--purple-light); border-color: var(--purple-border); color: var(--purple); }
.tag-row--sm { margin-top: 0.5rem; margin-bottom: 0.75rem; }
.tag-row--sm .tag { font-size: 11px; padding: 3px 10px; }

/* ── Highlights ── */
.highlight-list {
  list-style: none;
  padding: 0;
  margin: 2rem 0 2.5rem;
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
}
.highlight-list li {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  font-size: 14px;
  color: var(--ink-mid);
}
.highlight-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: var(--gold-light);
  color: var(--gold);
}

/* ── LinkedIn banner ── */
.linkedin-banner {
  display: flex;
  width: 100%;
  max-width: 340px;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 12px 22px;
  margin: 0 auto 3rem;
  border-radius: 30px;
  background: #0A66C2;
  border: 0.5px solid #0A66C2;
  color: #fff;
  font-size: 13px;
  font-weight: 500;
  transition: transform 0.15s, box-shadow 0.15s;
}
.linkedin-banner:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 24px rgba(10,102,194,0.35);
}
.linkedin-banner-arrow { transition: transform 0.15s; }
.linkedin-banner:hover .linkedin-banner-arrow { transform: translateX(3px); }

/* ── Divider ── */
.divider {
  border: none;
  border-top: 0.5px solid var(--border);
  margin: 0;
}

/* ── Section label ── */
.section-label {
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.09em;
  text-transform: uppercase;
  color: var(--ink-soft);
  margin-bottom: 1.5rem;
}

/* ── Contact block ── */
.contact-block {
  background: var(--gold-light);
  border: 0.5px solid var(--gold-border);
  border-radius: var(--radius);
  padding: 1.25rem 1.5rem;
}
.c-line {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 14px;
  color: var(--ink-mid);
  margin-bottom: 8px;
}
.c-line:last-child { margin-bottom: 0; }
.c-line svg { color: var(--gold); flex-shrink: 0; }

/* ── Portfolio grid ── */
.portfolio-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 1.25rem;
  margin-top: 1.5rem;
}
.p-card {
  display: flex;
  flex-direction: column;
  border: 0.5px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  background: white;
  text-decoration: none;
  transition: transform 0.15s, box-shadow 0.15s, border-color 0.15s;
}
.p-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 12px 28px rgba(28,26,22,0.08);
  border-color: var(--gold-border);
}
.p-card-thumb {
  aspect-ratio: 16 / 9;
  overflow: hidden;
  background: linear-gradient(135deg, var(--gold-light) 0%, var(--surface) 100%);
  display: flex;
  align-items: center;
  justify-content: center;
}
.p-card-thumb img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  display: block;
  transition: transform 0.25s;
}
.p-card:hover .p-card-thumb img { transform: scale(1.04); }
.p-card-placeholder {
  font-size: 13px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--ink-soft);
  font-weight: 500;
}
.p-card-thumb--teal  { background: linear-gradient(135deg, var(--teal-light)  0%, var(--surface) 100%); }
.p-card-thumb--amber { background: linear-gradient(135deg, var(--amber-light) 0%, var(--surface) 100%); }
.p-card-thumb--coral { background: linear-gradient(135deg, var(--coral-light) 0%, var(--surface) 100%); }
.p-card-body {
  display: flex;
  flex-direction: column;
  flex: 1;
  padding: 1.1rem 1.25rem 1.25rem;
}
.p-card-arrow {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-top: auto;
  padding-top: 0.85rem;
  font-size: 12px;
  font-weight: 500;
  color: var(--ink-soft);
  transition: color 0.15s, gap 0.15s;
}
.p-card:hover .p-card-arrow { color: var(--gold); gap: 9px; }
.p-type {
  font-size: 10px;
  font-weight: 500;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  margin-bottom: 3px;
}
.p-type.teal  { color: var(--teal); }
.p-type.amber { color: var(--amber); }
.p-type.coral { color: var(--coral); }
.p-title {
  font-size: 14px;
  font-weight: 500;
  color: var(--ink);
  margin-bottom: 3px;
}
.p-desc {
  font-size: 12px;
  color: var(--ink-mid);
  line-height: 1.5;
}

/* ── Portfolio detail ── */
.portfolio-detail { max-width: 620px; margin: 0 auto; padding: 3rem 2rem 4rem; }
.portfolio-back {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 13px;
  color: var(--ink-soft);
  margin-bottom: 2.5rem;
}
.portfolio-back:hover { color: var(--ink); }
.portfolio-type {
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin-bottom: 0.75rem;
}
.portfolio-type.teal  { color: var(--teal); }
.portfolio-type.amber { color: var(--amber); }
.portfolio-type.coral { color: var(--coral); }
.portfolio-heading {
  font-family: var(--font-serif);
  font-size: 26px;
  font-weight: 500;
  color: var(--ink);
  line-height: 1.3;
  margin-bottom: 0.5rem;
}
.portfolio-meta {
  font-size: 13px;
  color: var(--ink-soft);
  margin-bottom: 2rem;
}
.portfolio-body {
  font-size: 15px;
  line-height: 1.8;
  color: var(--ink-mid);
}
.portfolio-body p { margin-bottom: 1rem; }
.portfolio-body a { color: var(--teal); text-decoration: underline; text-underline-offset: 3px; }
.portfolio-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-top: 2rem;
  padding: 8px 18px;
  border-radius: 20px;
  border: 0.5px solid var(--border);
  font-size: 13px;
  color: var(--ink-mid);
  background: white;
  transition: border-color 0.15s, color 0.15s;
}
.portfolio-link:hover { border-color: var(--teal); color: var(--teal); }
.portfolio-link--tight { margin-top: 1rem; }

/* ── Responsive ── */
@media (max-width: 560px) {
  .nav { padding: 0 1rem; }
  .page, .portfolio-detail { padding: 2rem 1rem 3rem; }
  .hero-heading { font-size: 25px; }
}
@media (max-width: 420px) {
  .nav { gap: 0.5rem; }
  .nav-name { font-size: 13px; white-space: nowrap; }
  .nav-links { gap: 1rem; }
  .nav-links a { font-size: 12px; }
}

/* ── CV ── */
.cv-profile {
  margin-bottom: 2.5rem;
  padding-bottom: 2rem;
  border-bottom: 0.5px solid var(--border);
}
.cv-profile-text { flex: 1; }
/* Portrait & Kontaktzeile nur im PDF-Export */
.cv-portrait, .cv-contact { display: none; }
.cv-name {
  font-family: var(--font-serif); font-size: 22px; font-weight: 500; color: var(--ink); margin-bottom: 0.2rem; }
.cv-subtitle { font-size: 12px; letter-spacing: 0.07em; text-transform: uppercase; color: var(--ink-soft); margin-bottom: 0.9rem; }
.cv-statement { font-size: 15px; line-height: 1.75; color: var(--ink-mid); max-width: 540px; }
.cv-statement em { font-style: normal; color: var(--gold); font-weight: 500; }
.cv-section { margin-bottom: 2.25rem; }
.cv-timeline { position: relative; padding-left: 1.5rem; }
.cv-timeline::before { content: ''; position: absolute; left: 0; top: 6px; bottom: 6px; width: 1px; background: var(--border); }
.cv-entry { position: relative; margin-bottom: 2.5rem; }
.cv-entry:last-child { margin-bottom: 0; }
.cv-dot { position: absolute; left: -1.5rem; top: 5px; width: 7px; height: 7px; border-radius: 50%; border: 1.5px solid var(--border); background: var(--surface); transform: translateX(-3px); }
.cv-dot--filled    { background: var(--border); border-color: var(--border); }
.cv-dot--teal      { border-color: var(--teal); }
.cv-dot--amber     { border-color: var(--amber); }
.cv-dot--psych     { border-color: var(--purple); }
.cv-dot--filled.cv-dot--teal  { background: var(--teal);   border-color: var(--teal); }
.cv-dot--filled.cv-dot--amber { background: var(--amber);  border-color: var(--amber); }
.cv-dot--filled.cv-dot--psych { background: var(--purple); border-color: var(--purple); }
.cv-entry-header { display: flex; justify-content: space-between; align-items: flex-start; gap: 1rem; margin-bottom: 3px; }
.cv-entry-title { font-size: 14px; font-weight: 500; color: var(--ink); line-height: 1.4; }
.cv-org { font-weight: 400; color: var(--ink-soft); }
.cv-entry-date { font-size: 11px; color: var(--ink-soft); white-space: nowrap; flex-shrink: 0; margin-top: 2px; }
.cv-entry-org { font-size: 12px; color: var(--ink-soft); margin-bottom: 6px; }
.cv-bullets { margin: 0; padding: 0; list-style: none; }
.cv-bullets li { font-size: 13px; color: var(--ink-mid); line-height: 1.55; padding-left: 0.85rem; position: relative; margin-bottom: 2px; }
.cv-bullets li::before { content: '–'; position: absolute; left: 0; color: var(--ink-soft); }
.cv-thread { display: block; margin-top: 7px; font-size: 12px; font-style: italic; color: var(--ink-soft); line-height: 1.5; }
.cv-thread--teal  { color: var(--teal); }
.cv-thread--amber { color: var(--amber); }
.cv-thread--psych { color: var(--purple); }
.cv-skills { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.cv-skill { background: white; border: 0.5px solid var(--border); border-radius: 6px; padding: 8px 12px; }
.cv-skill-label { font-size: 11px; font-weight: 500; color: var(--ink-soft); text-transform: uppercase; letter-spacing: 0.06em; margin-bottom: 2px; }
.cv-skill-value { font-size: 13px; color: var(--ink-mid); line-height: 1.4; }
.cv-legend {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.4rem 1rem;
  font-size: 11px;
  color: var(--ink-soft);
  margin: 0.5rem 0 2.25rem;
}
.cv-legend span { display: inline-flex; align-items: center; gap: 5px; }
.cv-legend-sep { color: var(--border); }
.cv-dot--mini { position: static; display: inline-block; transform: none; width: 7px; height: 7px; }
.cv-swatch { display: inline-block; width: 8px; height: 8px; border-radius: 50%; }
.cv-pub { font-size: 13px; color: var(--ink-mid); line-height: 1.6; }
.cv-pub em { font-style: italic; }

/* ── Hero background glow (fills whole viewport, scrolls behind nav) ── */
.hero-glow {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: -1;
  overflow: hidden;
}
.hero-glow::before,
.hero-glow::after {
  content: '';
  position: absolute;
  border-radius: 50%;
  filter: blur(90px);
  opacity: 0.4;
}
.hero-glow::before {
  width: 620px;
  height: 620px;
  top: -240px;
  left: -200px;
  background: radial-gradient(circle, var(--gold) 0%, transparent 70%);
}
.hero-glow::after {
  width: 560px;
  height: 560px;
  bottom: -260px;
  right: -220px;
  background: radial-gradient(circle, var(--teal) 0%, transparent 70%);
  opacity: 0.28;
}

/* ── Hero photo ── */
.hero-intro {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  gap: 2.5rem;
  margin-bottom: 1.5rem;
}
.hero-photo-wrap {
  flex: 0 0 270px;
}
.hero-photo {
  width: 100%;
  height: auto;
  object-fit: contain;
  object-position: bottom;
  display: block;
  filter: drop-shadow(0 12px 28px rgba(28,26,22,0.12));
  -webkit-mask-image: linear-gradient(to bottom, #000 92%, transparent 100%);
  mask-image: linear-gradient(to bottom, #000 92%, transparent 100%);
}
.hero-text { flex: 1; display: flex; flex-direction: column; gap: 1.25rem; }
.hero-text .hero-label { margin-bottom: 0; }
.hero-statement {
  font-family: var(--font-serif);
  font-size: 22px;
  font-style: italic;
  color: var(--gold);
  margin-top: 0.6rem;
}
.hero-statement p { margin: 0; }
.hero-subline {
  font-size: 14px;
  color: var(--ink-soft);
  margin-top: 0.6rem;
  margin-bottom: 0;
}
.hero-text .hero-heading { font-size: 36px; margin-bottom: 0; }

@media (max-width: 560px) {
  .hero-intro { flex-direction: column; align-items: center; text-align: center; gap: 1.5rem; }
  .hero-photo-wrap { flex: 0 0 auto; width: 55%; }
  .hero-text { align-items: center; }
  .hero-text .tag-row { justify-content: center; }
  .hero-text .hero-heading { font-size: 22px; }
  .highlight-list li { text-align: left; }
  .linkedin-banner { margin-top: 0.5rem; }
  .cv-legend { margin-top: 0; }
}

/* ── Portfolio image ── */
.portfolio-image {
  width: 100%;
  border-radius: var(--radius);
  border: 0.5px solid var(--border);
  margin: 1.5rem 0;
  display: block;
}
.portfolio-image-caption {
  font-size: 12px;
  color: var(--ink-soft);
  text-align: center;
  margin-top: -1rem;
  margin-bottom: 1.5rem;
}

/* ── Portfolio gallery ── */
.portfolio-images {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin: 1.5rem 0;
}
.portfolio-figure { margin: 0; }
@media (max-width: 520px) {
  .portfolio-images { grid-template-columns: 1fr; }
}

/* ── Portfolio two-column layout ── */
.portfolio-layout {
  display: grid;
  grid-template-columns: 45% 1fr;
  gap: 2.5rem;
  align-items: start;
  margin-bottom: 2rem;
}
.portfolio-visuals { position: sticky; top: 1.5rem; }
.portfolio-main-img {
  width: 100%;
  border-radius: var(--radius);
  border: 0.5px solid var(--border);
  display: block;
}
.portfolio-thumbs {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  margin-top: 8px;
}
.portfolio-thumb { margin: 0; }
.portfolio-thumb img {
  width: 100%;
  border-radius: var(--radius-sm);
  border: 0.5px solid var(--border);
  display: block;
}
.portfolio-thumb figcaption {
  font-size: 11px;
  color: var(--ink-soft);
  margin-top: 4px;
  line-height: 1.4;
}

/* ── Portfolio prev/next nav ── */
.portfolio-nav {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  padding-top: 1.5rem;
  border-top: 0.5px solid var(--border);
  margin-top: 1rem;
}
.portfolio-nav-prev,
.portfolio-nav-next { flex: 1; }
.portfolio-nav-next { text-align: right; }
.portfolio-nav-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  color: var(--ink-mid);
  text-decoration: none;
  padding: 8px 0;
  transition: color 0.15s;
}
.portfolio-nav-link:hover { color: var(--gold); }
.portfolio-nav-link--right { flex-direction: row-reverse; }
.portfolio-nav-link small {
  display: block;
  font-size: 11px;
  color: var(--ink-soft);
  margin-bottom: 1px;
}
.portfolio-nav-link span { display: flex; flex-direction: column; }
.portfolio-nav-link--right span { align-items: flex-end; }

/* ── Responsive portfolio layout ── */
@media (max-width: 600px) {
  .portfolio-layout {
    grid-template-columns: 1fr;
    gap: 1.5rem;
  }
  .portfolio-visuals { position: static; }
}

/* ── Portfolio full layout ── */
.portfolio-detail--full { max-width: 780px; }
.portfolio-hero-img {
  width: 100%;
  border-radius: var(--radius);
  border: 0.5px solid var(--border);
  margin: 1.5rem 0 0.5rem;
  display: block;
}
.portfolio-body--wide { max-width: 100%; margin: 1.5rem 0; }

/* ── Portfolio gallery (full layout) ── */
.portfolio-gallery {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 12px;
  margin: 1.5rem 0;
}
.portfolio-gallery-item { margin: 0; }
.portfolio-gallery-item img,
.portfolio-gallery-item video {
  width: 100%;
  border-radius: var(--radius);
  border: 0.5px solid var(--border);
  display: block;
}
.portfolio-gallery-item figcaption {
  font-size: 11px;
  color: var(--ink-soft);
  margin-top: 5px;
  line-height: 1.4;
}

/* ── Section divider within portfolio body ── */
.portfolio-body h2 {
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--ink-soft);
  margin: 2rem 0 0.75rem;
  padding-top: 1.5rem;
  border-top: 0.5px solid var(--border);
}

/* ── Figcaptions ── */
.portfolio-figcaption {
  font-size: 11px;
  color: var(--ink-soft);
  margin-top: 6px;
  line-height: 1.4;
  display: block;
}
.portfolio-figure-full,
.portfolio-figure-main { margin: 0; }
.portfolio-figure-full { margin: 1.5rem 0 0; }

/* Bilder nie overflow, immer block */
.portfolio-main-img,
.portfolio-hero-img,
.portfolio-gallery-item img,
.portfolio-thumb img { display: block; width: 100%; }

/* Klick-Cursor auf anklickbare Bilder */
.lightbox-trigger { display: block; cursor: zoom-in; }
.lightbox-trigger img { transition: opacity 0.15s; }
.lightbox-trigger:hover img { opacity: 0.9; }

/* ── Lightbox ── */
.lightbox {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.88);
  z-index: 1000;
  align-items: center;
  justify-content: center;
  padding: 2rem;
}
.lightbox--open { display: flex; }
.lightbox-inner {
  max-width: min(90vw, 1000px);
  max-height: 90vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
}
.lightbox-inner img {
  max-width: 100%;
  max-height: 80vh;
  object-fit: contain;
  border-radius: var(--radius);
  display: block;
}
.lightbox-caption {
  font-size: 13px;
  color: rgba(255,255,255,0.6);
  text-align: center;
  margin: 0;
}
.lightbox-close {
  position: fixed;
  top: 1.25rem;
  right: 1.5rem;
  background: none;
  border: none;
  color: white;
  font-size: 28px;
  line-height: 1;
  cursor: pointer;
  opacity: 0.7;
  padding: 4px 8px;
}
.lightbox-close:hover { opacity: 1; }

/* ── CV Download Button ── */
.cv-download-row { display: flex; justify-content: flex-end; margin-bottom: 1.75rem; }
.cv-download-btn {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 7px 16px;
  font-size: 13px;
  font-weight: 500;
  color: var(--ink-mid);
  background: var(--surface);
  border: 0.5px solid var(--border);
  border-radius: 20px;
  cursor: pointer;
  transition: border-color 0.15s, color 0.15s;
}
.cv-download-btn:hover { border-color: var(--gold); color: var(--gold); }

/* ── Print / PDF ── */
@media print {
  /* Page setup */
  @page {
    size: A4;
    margin: 18mm 20mm 18mm 20mm;
  }
  @page :first { @top-left { content: ""; } @top-right { content: ""; } @bottom-left { content: ""; } @bottom-right { content: ""; } @bottom-center { content: ""; } @top-center { content: ""; } }
  @page { @top-left { content: ""; } @top-right { content: ""; } @bottom-left { content: ""; } @bottom-right { content: ""; } @bottom-center { content: ""; } @top-center { content: ""; } }

  /* Hide everything that doesn't belong in the PDF */
  nav, footer, .cv-download-row, .lightbox { display: none !important; }

  /* Reset background & surfaces */
  body, .page { background: white !important; color: #1C1A16 !important; }
  .cv-skill { background: white !important; border-color: #ddd !important; }

  /* Profil-Header: Portrait links, etwa so hoch wie Name + Kontaktblock */
  .cv-profile { display: flex; align-items: center; gap: 6mm; }
  .cv-portrait {
    display: block;
    height: 40mm;
    width: 40mm;
    object-fit: cover;
    flex-shrink: 0;
    -webkit-print-color-adjust: exact; print-color-adjust: exact;
  }
  .cv-contact {
    display: flex;
    flex-direction: column;
    gap: 2pt;
    margin-top: 6pt;
    font-size: 8.5pt;
  }
  .cv-contact a { color: #1C1A16 !important; text-decoration: none; }

  /* Typography */
  body { font-size: 11pt; }
  .cv-name { font-size: 22pt; }
  .cv-subtitle { font-size: 8pt; }
  .cv-statement { font-size: 10pt; }
  .cv-entry-title { font-size: 10pt; }
  .cv-entry-date { font-size: 8pt; }
  .cv-entry-org { font-size: 8.5pt; }
  .cv-bullets li { font-size: 9.5pt; }
  .cv-thread { font-size: 8.5pt; }
  .section-label { font-size: 8pt; }
  .cv-skill-label { font-size: 8pt; }
  .cv-skill-value { font-size: 9.5pt; }
  .cv-pub { font-size: 9.5pt; }
  .cv-legend { font-size: 8pt; }

  /* Colors: keep brand colors for dots, threads, tags */
  .cv-dot--teal      { border-color: #1D9E75 !important; }
  .cv-dot--amber     { border-color: #BA7517 !important; }
  .cv-dot--psych     { border-color: #7C5CC4 !important; }
  .cv-dot--filled.cv-dot--teal  { background: #1D9E75 !important; }
  .cv-dot--filled.cv-dot--amber { background: #BA7517 !important; }
  .cv-dot--filled.cv-dot--psych { background: #7C5CC4 !important; }
  .cv-thread--teal  { color: #1D9E75 !important; }
  .cv-thread--amber { color: #BA7517 !important; }
  .cv-thread--psych { color: #7C5CC4 !important; }
  .tag--kids   { background: #FAEEDA !important; color: #BA7517 !important; border-color: rgba(186,117,23,0.3) !important; -webkit-print-color-adjust: exact; print-color-adjust: exact; }
  .tag--online { background: #E1F5EE !important; color: #1D9E75 !important; border-color: rgba(29,158,117,0.3) !important; -webkit-print-color-adjust: exact; print-color-adjust: exact; }
  .tag--psych  { background: #EFEAFA !important; color: #7C5CC4 !important; border-color: rgba(124,92,196,0.3) !important; -webkit-print-color-adjust: exact; print-color-adjust: exact; }
  .cv-swatch { -webkit-print-color-adjust: exact; print-color-adjust: exact; }
  .cv-timeline::before { background: #ddd !important; }

  /* Page breaks */
  .cv-section { page-break-inside: avoid; }
  .cv-entry { page-break-inside: avoid; }
  .cv-profile { page-break-after: avoid; }
}
