@font-face {
  font-family: "Montserrat";
  src: url("/wp-content/themes/sd-relaunch/assets/fonts/montserrat-latin.woff2") format("woff2");
  font-weight: 400 800;
  font-style: normal;
  font-display: swap;
}

:root {
  --bg: #f6f1e8;
  --paper: #fffaf2;
  --paper-strong: #f0e7d8;
  --navy: #26374d;
  --navy-soft: #4b5d73;
  --beige: #ccbfa3;
  --beige-deep: #b7a687;
  --line: rgba(38, 55, 77, 0.16);
  --shadow: 0 24px 64px rgba(38, 55, 77, 0.12);
  --radius-xl: 32px;
  --radius-lg: 24px;
  --radius-md: 18px;
  --radius-sm: 14px;
  --content: 1180px;
}

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

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--navy);
  background:
    radial-gradient(circle at top left, rgba(204, 191, 163, 0.2), transparent 38%),
    radial-gradient(circle at top right, rgba(38, 55, 77, 0.06), transparent 34%),
    linear-gradient(180deg, #fcfaf5 0%, #f7f1e7 52%, #f3ecdf 100%);
  font-family: "Montserrat", "Segoe UI", sans-serif;
  line-height: 1.65;
}

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

button {
  font: inherit;
}

img {
  display: block;
  max-width: 100%;
}

.topbar,
.page-shell {
  width: min(calc(100% - 32px), var(--content));
  margin: 0 auto;
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  padding: 18px 0 12px;
  backdrop-filter: blur(16px);
}

.brand {
  display: inline-flex;
  flex-direction: column;
  gap: 2px;
}

.brand__mark {
  font-size: 0.92rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.brand__sub {
  color: var(--navy-soft);
  font-size: 0.92rem;
}

.topbar__actions {
  display: flex;
  align-items: center;
  gap: 12px;
}

.lang-switch,
.action-button,
.action-link {
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(255, 250, 242, 0.92);
  box-shadow: var(--shadow);
}

.lang-switch {
  display: inline-flex;
  padding: 4px;
}

.lang-switch__button,
.action-button,
.action-link {
  min-height: 46px;
  padding: 0 18px;
  border: 0;
  background: transparent;
  color: var(--navy);
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.lang-switch__button {
  border-radius: 999px;
  font-weight: 700;
}

.lang-switch__button.is-active {
  background: var(--navy);
  color: #fff;
}

.action-button {
  border-radius: 999px;
  font-weight: 700;
}

.action-button--solid {
  background: var(--navy);
  color: var(--paper);
}

.action-link {
  font-weight: 700;
}

.action-link--button {
  width: auto;
}

.action-link--danger {
  border-color: rgba(148, 55, 55, 0.22);
  color: #8a3030;
}

.page-shell {
  padding: 20px 0 48px;
}

.lang-block {
  display: none;
}

body[data-lang="de"] .lang-block[data-lang="de"],
body[data-lang="en"] .lang-block[data-lang="en"] {
  display: block;
}

.hero {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(300px, 0.8fr);
  gap: 24px;
  margin-bottom: 24px;
}

.hero__copy,
.hero__aside,
.panel {
  border: 1px solid var(--line);
  border-radius: var(--radius-xl);
  background: linear-gradient(135deg, rgba(255, 250, 242, 0.98), rgba(240, 231, 216, 0.94));
  box-shadow: var(--shadow);
}

.hero__copy {
  padding: 38px;
}

.hero__aside {
  padding: 28px;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  margin: 0 0 18px;
  padding: 8px 14px;
  border-radius: 999px;
  background: rgba(204, 191, 163, 0.28);
  font-size: 0.8rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.eyebrow::before {
  content: "";
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--beige-deep);
}

h1,
h2,
h3,
p {
  margin-top: 0;
}

h1 {
  margin-bottom: 12px;
  font-size: clamp(2.4rem, 4vw, 4.3rem);
  line-height: 1.05;
  letter-spacing: -0.02em;
}

h2 {
  margin-bottom: 14px;
  font-size: 1.45rem;
  line-height: 1.2;
}

h3 {
  margin-bottom: 8px;
  font-size: 1.08rem;
}

.hero__role {
  margin-bottom: 18px;
  color: var(--navy-soft);
  font-size: 1.16rem;
  font-weight: 700;
}

.hero__lead {
  max-width: 58ch;
  margin-bottom: 28px;
  font-size: 1.04rem;
}

.hero__facts {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.fact {
  padding: 14px 16px;
  border: 1px solid rgba(38, 55, 77, 0.12);
  border-radius: var(--radius-md);
  background: rgba(255, 255, 255, 0.42);
}

.fact__label {
  display: block;
  margin-bottom: 6px;
  color: var(--navy-soft);
  font-size: 0.82rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.fact__value {
  font-weight: 600;
  word-break: break-word;
}

.fact__value--link {
  text-decoration: underline;
  text-decoration-color: rgba(38, 55, 77, 0.28);
  text-underline-offset: 3px;
}

.portrait {
  width: min(100%, 380px);
  margin: 0 auto 22px;
  border-radius: 28px;
  border: 1px solid var(--line);
  box-shadow: 0 20px 50px rgba(38, 55, 77, 0.18);
}

.hero__card {
  padding: 18px;
  border-radius: var(--radius-lg);
  background: rgba(255, 255, 255, 0.58);
  border: 1px solid rgba(38, 55, 77, 0.12);
}

.focus-list,
.timeline-item ul,
.project-list {
  margin: 0;
  padding-left: 20px;
}

.focus-list li,
.timeline-item li,
.project-list li {
  margin-bottom: 10px;
}

.content-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 24px;
}

.panel {
  padding: 28px;
}

.panel--wide {
  grid-column: 1 / -1;
}

.auth-page,
.admin-page {
  min-height: 100vh;
}

.auth-shell {
  width: min(calc(100% - 32px), 560px);
  margin: 0 auto;
  min-height: 100vh;
  display: grid;
  align-items: center;
  padding: 40px 0;
}

.auth-card {
  padding: 32px;
  border: 1px solid var(--line);
  border-radius: var(--radius-xl);
  background: linear-gradient(135deg, rgba(255, 250, 242, 0.98), rgba(240, 231, 216, 0.94));
  box-shadow: var(--shadow);
  text-align: center;
}

.auth-copy,
.admin-copy {
  max-width: 60ch;
}

.auth-copy {
  margin-right: auto;
  margin-left: auto;
}

.auth-form,
.stack-form {
  display: grid;
  gap: 16px;
}

.auth-form {
  max-width: 380px;
  margin: 0 auto;
}

.form-field {
  display: grid;
  gap: 8px;
  text-align: left;
}

.form-field span {
  font-size: 0.9rem;
  font-weight: 700;
}

.form-field input {
  min-height: 48px;
  padding: 0 14px;
  border: 1px solid rgba(38, 55, 77, 0.18);
  border-radius: var(--radius-sm);
  background: rgba(255, 255, 255, 0.9);
  color: var(--navy);
  font: inherit;
}

.flash {
  margin-bottom: 18px;
  padding: 14px 16px;
  border-radius: var(--radius-md);
  font-weight: 600;
  text-align: left;
}

.flash--success {
  background: rgba(40, 122, 76, 0.12);
  border: 1px solid rgba(40, 122, 76, 0.18);
}

.flash--error {
  background: rgba(148, 55, 55, 0.12);
  border: 1px solid rgba(148, 55, 55, 0.18);
}

.admin-shell {
  padding-top: 20px;
}

.admin-title {
  margin-bottom: 12px;
}

.user-list {
  display: grid;
  gap: 18px;
}

.user-card {
  padding: 18px;
  border: 1px solid rgba(38, 55, 77, 0.14);
  border-radius: var(--radius-lg);
  background: rgba(255, 255, 255, 0.48);
}

.user-card__header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 12px;
  margin-bottom: 16px;
}

.user-card__meta {
  color: var(--navy-soft);
  font-size: 0.94rem;
}

.user-card__actions {
  display: grid;
  gap: 12px;
}

.inline-form {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
}

.password-box {
  padding: 12px 14px;
  border: 1px solid rgba(38, 55, 77, 0.14);
  border-radius: var(--radius-md);
  background: rgba(255, 255, 255, 0.5);
}

.password-box summary {
  cursor: pointer;
  font-weight: 700;
}

.password-box__value {
  margin-top: 10px;
  font-weight: 700;
  word-break: break-all;
}

.inline-form--stretch input {
  flex: 1 1 220px;
  min-height: 44px;
  padding: 0 14px;
  border: 1px solid rgba(38, 55, 77, 0.18);
  border-radius: var(--radius-sm);
  background: rgba(255, 255, 255, 0.92);
  color: var(--navy);
  font: inherit;
}

.chip-list {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.chip {
  display: inline-flex;
  align-items: center;
  min-height: 40px;
  padding: 0 14px;
  border: 1px solid rgba(38, 55, 77, 0.14);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.52);
  font-size: 0.92rem;
  font-weight: 700;
}

.timeline-item + .timeline-item,
.education-item + .education-item {
  margin-top: 22px;
  padding-top: 22px;
  border-top: 1px solid rgba(38, 55, 77, 0.12);
}

.timeline-item {
  display: grid;
  grid-template-columns: 160px minmax(0, 1fr);
  gap: 18px;
}

.timeline-item__meta,
.education-item__date {
  color: var(--navy-soft);
  font-size: 0.92rem;
  font-weight: 800;
  letter-spacing: 0.03em;
}

.timeline-item__role {
  color: var(--navy-soft);
  font-weight: 700;
}

.education-item {
  display: grid;
  grid-template-columns: 160px minmax(0, 1fr);
  gap: 18px;
}

@media (max-width: 960px) {
  .hero,
  .content-grid,
  .timeline-item,
  .education-item {
    grid-template-columns: 1fr;
  }

  .hero__facts {
    grid-template-columns: 1fr;
  }

  .topbar {
    position: static;
    flex-direction: column;
    align-items: flex-start;
  }

  .topbar__actions {
    width: 100%;
    justify-content: space-between;
  }

  .user-card__header {
    flex-direction: column;
  }
}

@media (max-width: 640px) {
  .hero__copy,
  .hero__aside,
  .panel {
    padding: 22px;
    border-radius: 24px;
  }

  h1 {
    font-size: 2.35rem;
  }

  .topbar__actions {
    flex-wrap: wrap;
  }

  .lang-switch,
  .action-button,
  .action-link {
    width: 100%;
  }

  .lang-switch {
    justify-content: stretch;
  }

  .lang-switch__button,
  .action-button,
  .action-link {
    flex: 1 1 auto;
    justify-content: center;
  }
}

@media print {
  body {
    background: #fff;
    font-size: 11pt;
  }

  .topbar {
    display: none;
  }

  .page-shell {
    width: 100%;
    padding: 0;
  }

  .hero,
  .content-grid {
    gap: 12pt;
  }

  .hero__copy,
  .hero__aside,
  .panel {
    border: 1px solid #d7d7d7;
    border-radius: 14pt;
    box-shadow: none;
    background: #fff;
    break-inside: avoid;
  }

  .portrait {
    width: 240px;
    box-shadow: none;
  }

  a {
    text-decoration: none;
  }
}
