/* =============================================================================
   wohnung.d-solve.de — display page
   Look ported from the original Astro template. No external requests: the type
   stack is the system stack, there is no CDN, no webfont, no analytics.
   The --brand-* ramp is written by app.js from the `accent` parameter.
   ============================================================================= */

:root {
  --brand-50: #eef5fb;
  --brand-100: #d7e7f5;
  --brand-500: #2f7fc4;
  --brand-600: #1f6fb4;
  --brand-700: #175a95;
  --brand-800: #124a7c;

  --ink-50: #f6f7f9;
  --ink-100: #eceef2;
  --ink-200: #dde1e8;
  --ink-400: #98a1b0;
  --ink-500: #6b7484;
  --ink-600: #4c5563;
  --ink-700: #374151;
  --ink-800: #1f2733;
  --ink-900: #131922;

  --bg: #ffffff;
  --bg-soft: #f6f7f9;
  --radius: 16px;
  --radius-sm: 10px;
  --shadow: 0 1px 3px rgba(19, 25, 34, 0.08), 0 8px 24px rgba(19, 25, 34, 0.06);
  --maxw: 68rem;

  --font: system-ui, -apple-system, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;

  /* Maximum height of the big photo at the top. */
  --hero-photo-height: 440px;

  /* The check-list tick. A data: URI cannot read a CSS variable, so app.js
     rebuilds this whole value when a custom accent colour is given. */
  --check-icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20' fill='%23175a95'%3E%3Cpath fill-rule='evenodd' d='M16.7 5.3a1 1 0 0 1 0 1.4l-7.5 7.5a1 1 0 0 1-1.4 0L3.3 9.7a1 1 0 1 1 1.4-1.4l3.1 3.1 6.8-6.8a1 1 0 0 1 1.4 0z' clip-rule='evenodd'/%3E%3C/svg%3E");
}

* { box-sizing: border-box; }

html {
  scroll-behavior: smooth;
  scroll-padding-top: 84px; /* so anchors don't hide under the sticky header */
}

body {
  margin: 0;
  font-family: var(--font);
  color: var(--ink-800);
  background: var(--bg);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3 {
  color: var(--ink-900);
  line-height: 1.15;
  letter-spacing: -0.02em;
  margin: 0 0 0.5em;
}

p { margin: 0 0 1em; }
a { color: var(--brand-700); }
img { max-width: 100%; display: block; }

.container {
  max-width: var(--maxw);
  margin-inline: auto;
  padding-inline: 1.25rem;
}

.section { padding-block: clamp(2.5rem, 6vw, 4.5rem); }
.section--soft { background: var(--bg-soft); }

.section__title {
  font-size: clamp(1.5rem, 3.5vw, 2rem);
  margin-bottom: 1.5rem;
}

.eyebrow {
  display: inline-block;
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--brand-700);
  margin-bottom: 0.5rem;
}

/* ---- Skip link ---- */
.skip-link { position: absolute; left: -999px; top: 0; z-index: 100; }
.skip-link:focus {
  left: 1rem;
  top: 1rem;
  background: var(--brand-700);
  color: #fff;
  padding: 0.6rem 1rem;
  border-radius: var(--radius-sm);
}

/* ---- Header ---- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 40;
  background: rgba(255, 255, 255, 0.85);
  backdrop-filter: saturate(180%) blur(8px);
  border-bottom: 1px solid var(--ink-100);
}
.site-header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding-block: 0.75rem;
}
.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  font-weight: 700;
  color: var(--ink-900);
  text-decoration: none;
  letter-spacing: -0.01em;
}
.brand__mark {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.1rem;
  height: 2.1rem;
  border-radius: 10px;
  background: var(--brand-700);
  color: #fff;
  font-size: 1.1rem;
  flex-shrink: 0;
}
.header-actions { display: flex; align-items: center; gap: 0.75rem; }

/* ---- Language switch ---- */
.lang-switch {
  display: inline-flex;
  border: 1px solid var(--ink-200);
  border-radius: 999px;
  overflow: hidden;
  font-size: 0.85rem;
  font-weight: 600;
}
.lang-switch button {
  padding: 0.35rem 0.8rem;
  border: none;
  background: none;
  font: inherit;
  font-weight: 600;
  color: var(--ink-600);
  cursor: pointer;
}
.lang-switch button[aria-current="true"] { background: var(--brand-700); color: #fff; }

/* ---- Buttons ---- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.7rem 1.15rem;
  border-radius: var(--radius-sm);
  font-size: 0.95rem;
  font-weight: 600;
  font-family: inherit;
  text-decoration: none;
  cursor: pointer;
  border: 1px solid transparent;
  transition: background 0.15s, border-color 0.15s, color 0.15s, transform 0.05s;
}
.btn:active { transform: translateY(1px); }
.btn--primary { background: var(--brand-700); color: #fff; }
.btn--primary:hover { background: var(--brand-800); }
.btn--ghost { background: #fff; border-color: var(--ink-200); color: var(--ink-800); }
.btn--ghost:hover { border-color: var(--brand-500); color: var(--brand-700); }
.btn--sm { padding: 0.45rem 0.9rem; font-size: 0.85rem; }
.btn svg { width: 1.05em; height: 1.05em; }

/* ---- Hero ---- */
.hero { background: var(--bg-soft); }
.hero__media {
  width: 100%;
  display: flex;
  justify-content: center;
  background: var(--bg-soft);
}
.hero__img {
  display: block;
  width: auto;
  max-width: 100%;
  max-height: var(--hero-photo-height);
  object-fit: contain;
}
/* Shown instead of a photo when no `photo` parameter was given. */
.hero__placeholder {
  width: 100%;
  height: clamp(160px, 26vw, 260px);
  display: grid;
  place-items: center;
  font-size: clamp(3rem, 9vw, 5rem);
  background: linear-gradient(135deg, var(--brand-50), var(--brand-100));
  user-select: none;
}
.hero__names {
  background: var(--brand-700);
  color: #fff;
  text-align: center;
  font-weight: 600;
  letter-spacing: 0.02em;
  font-size: clamp(1rem, 2.5vw, 1.25rem);
  padding: 0.6rem 1rem;
}
.hero__inner { padding-block: clamp(1.75rem, 4vw, 2.75rem); }
.hero__location {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-weight: 600;
  font-size: 0.9rem;
  color: var(--brand-800);
  background: var(--brand-50);
  border: 1px solid var(--brand-100);
  padding: 0.3rem 0.75rem;
  border-radius: 999px;
  margin-bottom: 1rem;
}
.hero__title { font-size: clamp(1.9rem, 5vw, 3.1rem); max-width: 20ch; }
.hero__subline {
  font-size: clamp(1rem, 2.2vw, 1.2rem);
  max-width: 60ch;
  color: var(--ink-600);
}
.hero__badges {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  list-style: none;
  padding: 0;
  margin: 1.25rem 0 1.75rem;
}
.hero__badges li {
  background: #fff;
  border: 1px solid var(--ink-200);
  color: var(--ink-700);
  padding: 0.3rem 0.75rem;
  border-radius: 999px;
  font-size: 0.85rem;
  font-weight: 500;
}
.hero__actions { display: flex; flex-wrap: wrap; gap: 0.75rem; }

/* ---- Facts ---- */
.facts-list { margin: 0; padding: 0; max-width: 44rem; }
.facts-list__row {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 1.5rem;
  padding: 0.75rem 0;
  border-bottom: 1px solid var(--ink-200);
}
.facts-list__row:last-child { border-bottom: none; }
.facts-list__label { color: var(--ink-600); }
.facts-list__value {
  margin: 0;
  font-weight: 600;
  color: var(--ink-900);
  text-align: right;
}

/* ---- Cards / grids ---- */
.grid-2 { display: grid; gap: 1.5rem; grid-template-columns: 1fr; }
@media (min-width: 720px) {
  .grid-2 { grid-template-columns: 1fr 1fr; }
}
/* People grid. On mid-width screens the columns are found from the available
   space; only from 960px up does the chosen --people-cols count apply. A math
   function inside repeat() would be the obvious way to cap it earlier, but
   support for that is uneven, and a rejected declaration drops the whole grid
   to one column. */
.grid-people { display: grid; gap: 1.5rem; grid-template-columns: 1fr; }
@media (min-width: 640px) {
  .grid-people { grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); }
}
@media (min-width: 960px) {
  .grid-people { grid-template-columns: repeat(var(--people-cols, 2), 1fr); }
}

.card {
  background: #fff;
  border: 1px solid var(--ink-100);
  border-radius: var(--radius);
  padding: 1.5rem;
  box-shadow: var(--shadow);
}
.card h3 { margin-top: 0; }

.check-list { list-style: none; padding: 0; margin: 0; display: grid; gap: 0.6rem; }
.check-list li { position: relative; padding-left: 1.75rem; }
.check-list li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.35em;
  width: 1.1rem;
  height: 1.1rem;
  border-radius: 50%;
  background: var(--brand-50);
  background-image: var(--check-icon);
  background-repeat: no-repeat;
  background-position: center;
  background-size: 0.8rem;
}

/* ---- Chips (districts) ---- */
.chips {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  list-style: none;
  padding: 0;
  margin: 0 0 1rem;
}
.chips li {
  background: var(--brand-50);
  color: var(--brand-800);
  border: 1px solid var(--brand-100);
  padding: 0.35rem 0.85rem;
  border-radius: 999px;
  font-weight: 600;
  font-size: 0.9rem;
}

/* ---- People ---- */
.person-card { padding: 1.1rem; }
.person-card__photo {
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  border-radius: 14px;
  background: var(--ink-100);
  margin-bottom: 1.1rem;
}
/* Emoji stands in for a photo — the default state, since defaults are anonymous. */
.person-card__avatar {
  width: 100%;
  aspect-ratio: 4 / 3;
  display: grid;
  place-items: center;
  border-radius: 14px;
  background: linear-gradient(135deg, var(--brand-50), var(--brand-100));
  font-size: clamp(2.5rem, 8vw, 3.75rem);
  margin-bottom: 1.1rem;
  user-select: none;
}
.person-card__name { margin: 0.2rem 0 0.1rem; font-size: 1.35rem; }
.person__role {
  color: var(--brand-700);
  font-weight: 600;
  font-size: 0.9rem;
  margin: 0 0 0.6rem;
}
.person-facts { list-style: none; padding: 0; margin: 0; display: grid; gap: 0.55rem; }
.person-facts li {
  display: flex;
  align-items: center;
  gap: 0.7rem;
  font-weight: 500;
  color: var(--ink-800);
}
.person-facts__icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  width: 2rem;
  height: 2rem;
  border-radius: 10px;
  background: var(--brand-50);
  font-size: 1.05rem;
  line-height: 1;
}

/* ---- Contact: mail + phone only, no form ---- */
.contact-grid { display: grid; gap: 1.5rem; grid-template-columns: 1fr; }
@media (min-width: 720px) {
  .contact-grid { grid-template-columns: 1fr 1fr; }
}
.contact-card {
  background: #fff;
  border: 1px solid var(--ink-100);
  border-radius: var(--radius);
  padding: 1.5rem;
  box-shadow: var(--shadow);
  display: flex;
  align-items: center;
  gap: 1rem;
}
.contact-card__icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  width: 2.75rem;
  height: 2.75rem;
  border-radius: 12px;
  background: var(--brand-50);
  font-size: 1.35rem;
  line-height: 1;
}
.contact-card__label {
  display: block;
  font-size: 0.85rem;
  color: var(--ink-500);
  margin-bottom: 0.1rem;
}
.contact-card__value {
  font-weight: 700;
  font-size: 1.05rem;
  color: var(--brand-700);
  text-decoration: none;
  overflow-wrap: anywhere;
}
.contact-card__value:hover { text-decoration: underline; }

/* ---- Footer ---- */
.site-footer {
  border-top: 1px solid var(--ink-100);
  padding-block: 2rem;
  color: var(--ink-500);
  font-size: 0.9rem;
}
.site-footer__inner {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1.5rem;
  justify-content: space-between;
  align-items: center;
}
.site-footer a { color: var(--ink-600); }
.site-footer__links { display: flex; flex-wrap: wrap; gap: 0.5rem 1rem; }

.lede { font-size: 1.1rem; color: var(--ink-700); max-width: 60ch; }

/* Free-form intro text: line breaks from the parameter are preserved. */
.intro__body > :first-child { margin-top: 0; }
.intro__body > :last-child { margin-bottom: 0; }
.intro__text { white-space: pre-line; margin: 0 0 1em; }

.intro-list {
  list-style: disc;
  padding-left: 1.75rem;
  margin: 0.25rem 0 1.25rem;
  display: grid;
  gap: 0.4rem;
}
.intro-list li { padding-left: 0.25rem; }
.intro-list li::marker { color: var(--brand-600); }

.visually-hidden {
  position: absolute !important;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0);
  white-space: nowrap; border: 0;
}
