:root {
  --ink: #19221d;
  --muted: #626862;
  --paper: #f5f2eb;
  --paper-deep: #ebe8e1;
  --forest: #1d2d24;
  --clay: #bd5a38;
  --line: rgba(25, 34, 29, .2);
  --serif: Georgia, 'Times New Roman', serif;
  --sans: Arial, Helvetica, sans-serif;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; background: var(--paper); color: var(--ink); font-family: var(--sans); line-height: 1.6; }
a { color: inherit; }
a:focus-visible, button:focus-visible { outline: 3px solid var(--clay); outline-offset: 4px; }
.skip-link { position: absolute; left: 1rem; top: -5rem; background: var(--clay); color: #fff; padding: .75rem 1rem; z-index: 10; }
.skip-link:focus { top: 1rem; }

.site-header { display: flex; align-items: center; gap: 2rem; min-height: 5.25rem; padding: .7rem clamp(1.25rem, 4vw, 4.5rem); border-bottom: 1px solid rgba(25, 34, 29, .08); background: rgba(249, 247, 242, .96); position: sticky; top: 0; z-index: 5; }
.brand { display: flex; align-items: center; gap: .8rem; text-decoration: none; white-space: nowrap; }
.brand-logo { display: block; width: 8.4rem; height: 3.35rem; object-fit: contain; object-position: center; mix-blend-mode: multiply; }
.brand-divider { width: 1px; height: 2rem; background: var(--line); }
.brand-site { font-size: 1.25rem; letter-spacing: -.02em; }
.site-nav { display: flex; align-items: center; gap: clamp(1rem, 2.4vw, 2.5rem); margin-left: auto; font-size: .95rem; }
.site-nav a, .portal-link { text-decoration: none; }
.site-nav a:not(.nav-action):hover, .portal-link:hover { color: var(--clay); }
.nav-action { background: var(--clay); color: #fff; padding: .72rem 1.15rem; }
.nav-action:hover, .button-primary:hover { background: #a94c2e; }
.portal-link { border-bottom: 1px solid currentColor; white-space: nowrap; }

.hero { min-height: min(760px, calc(100dvh - 5.25rem)); display: grid; align-items: end; position: relative; overflow: hidden; color: #fff; background: #4f604f url('/static/assets/toka-hero-poster.jpg') center/cover; }
.hero-media, .hero-scrim { position: absolute; inset: 0; width: 100%; height: 100%; }
.hero-media { object-fit: cover; object-position: center bottom; transform: scale(1.34); transform-origin: center bottom; }
.hero-scrim { background: linear-gradient(90deg, rgba(18, 29, 22, .78), rgba(18, 29, 22, .32) 68%, rgba(18, 29, 22, .08)), linear-gradient(0deg, rgba(15, 24, 18, .55), transparent 55%); pointer-events: none; }
.hero-copy { position: relative; z-index: 1; max-width: 47rem; padding: clamp(5rem, 12vw, 10rem) clamp(1.25rem, 9vw, 8rem) clamp(4rem, 8vw, 6.5rem); }
.eyebrow { text-transform: uppercase; letter-spacing: .14em; font-size: .72rem; font-weight: 700; margin: 0 0 1.5rem; }
h1, h2, h3 { font-family: var(--serif); font-weight: 400; line-height: 1.02; text-wrap: balance; }
h1 { font-size: clamp(4rem, 10vw, 8.8rem); letter-spacing: -.06em; margin: 0; }
h2 { font-size: clamp(2.35rem, 4.5vw, 4.8rem); letter-spacing: -.045em; margin: 0 0 1.5rem; }
.hero-lead { max-width: 34rem; font-size: clamp(1.15rem, 2vw, 1.5rem); line-height: 1.35; }
.hero-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 1.5rem; margin-top: 2.25rem; }
.button { display: inline-block; text-decoration: none; padding: .9rem 1.25rem; font-weight: 700; transition: transform .2s ease, background .2s ease; }
.button:hover { transform: translateY(-2px); }
.button-primary { background: var(--clay); color: #fff; }
.text-link { display: inline-flex; gap: .5rem; align-items: center; text-decoration: none; border-bottom: 1px solid currentColor; padding-bottom: .15rem; }
.text-link:hover { color: var(--clay); }
.text-link.light { color: #fff; }
.text-link.light:hover { color: #fff; }

.section-shell { max-width: 1400px; margin: 0 auto; padding: clamp(4.5rem, 9vw, 8rem) clamp(1.25rem, 5vw, 5rem); }
.work-section { padding-top: clamp(4rem, 8vw, 7rem); padding-bottom: 0; }
.service-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 0; border-bottom: 1px solid var(--line); }
.service-grid article { padding: 0 2rem 3.5rem 0; border-right: 1px solid var(--line); }
.service-grid article + article { padding-left: clamp(1.5rem, 4vw, 4rem); }
.service-grid article:last-child { border-right: 0; }
.service-icon { display: grid; place-items: center; width: 3.7rem; height: 3.7rem; border: 1px solid rgba(25, 34, 29, .35); border-radius: 50%; font-family: var(--serif); font-size: 2rem; margin-bottom: 1.35rem; }
.service-grid h2 { font-size: clamp(1.7rem, 2.5vw, 2.25rem); margin-bottom: .8rem; }
.service-grid p, .project-copy p, .contact p { max-width: 30rem; color: var(--muted); font-size: 1.05rem; }

.project { display: grid; grid-template-columns: minmax(0, .9fr) minmax(22rem, 1.1fr); gap: clamp(2rem, 7vw, 7rem); align-items: center; padding: clamp(4rem, 8vw, 7rem) 0; }
.project-copy { max-width: 34rem; }
.project-image { margin: 0; background: var(--paper-deep); }
.project-image img { display: block; width: 100%; aspect-ratio: 1.5; object-fit: cover; }
.project-image figcaption { display: grid; gap: .18rem; padding: 1rem 1.25rem 1.2rem; }
.project-image figcaption span, .project-image figcaption small { color: var(--muted); }
.project-image figcaption strong { font-size: 1.1rem; }
.contact { max-width: none; text-align: center; border-top: 1px solid var(--line); }
.contact > * { margin-left: auto; margin-right: auto; }

.portal-page { min-height: 70vh; }
.portal-intro { padding-bottom: 3rem; }
.portal-intro h1 { font-size: clamp(3.5rem, 8vw, 7rem); }
.portal-intro > p:last-child { max-width: 35rem; font-size: 1.25rem; color: var(--muted); }
.portal-actions { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1rem; padding-top: 0; }
.portal-action { display: flex; flex-direction: column; gap: .7rem; padding: 2rem; min-height: 13rem; text-decoration: none; background: #fffdf8; border: 1px solid var(--line); transition: transform .2s ease, border-color .2s ease; }
.portal-action:hover { transform: translateY(-3px); border-color: var(--clay); }
.portal-action strong { font-size: 1.4rem; }
.portal-action span:last-child { color: var(--muted); }
.portal-icon { font-size: 2rem; color: var(--clay); }
.portal-login { padding-top: 2rem; }
.portal-login p { max-width: 40rem; color: var(--muted); }
.admin-page { min-height: 70vh; background: var(--paper); }
.admin-login { max-width: 44rem; }
.admin-login h1, .admin-heading h1 { margin-bottom: .8rem; }
.admin-intro { max-width: 42rem; color: var(--muted); font-size: 1.15rem; }
.admin-login-form { display: grid; gap: .8rem; max-width: 28rem; margin-top: 2rem; padding: 2rem; background: #fffdf8; border: 1px solid var(--line); }
.admin-login-form input, .admin-card input, .admin-card select, .admin-card textarea { width: 100%; border: 1px solid #aeb4ad; background: #fff; color: var(--ink); padding: .8rem; font: inherit; }
.admin-login-form input:focus, .admin-card input:focus, .admin-card select:focus, .admin-card textarea:focus { outline: 3px solid rgba(194, 89, 52, .25); border-color: var(--clay); }
.admin-config-warning, .admin-saved { max-width: 44rem; margin-top: 1.25rem; padding: 1rem 1.25rem; background: #fff0df; border-left: 4px solid var(--clay); }
.admin-heading { display: flex; align-items: flex-start; justify-content: space-between; gap: 2rem; margin-bottom: 2.5rem; }
.admin-table-wrap { overflow-x: auto; background: #fffdf8; border: 1px solid var(--line); }
.admin-table { width: 100%; min-width: 760px; border-collapse: collapse; text-align: left; }
.admin-table th, .admin-table td { padding: 1rem 1.1rem; border-bottom: 1px solid var(--line); vertical-align: top; }
.admin-table thead { background: var(--paper-deep); font-size: .82rem; text-transform: uppercase; letter-spacing: .08em; }
.admin-table tbody tr:last-child th, .admin-table tbody tr:last-child td { border-bottom: 0; }
.admin-table tbody tr:hover { background: #faf7f0; }
.admin-table tbody th { font-weight: 700; }
.admin-table small { display: block; margin-top: .35rem; color: var(--muted); font-weight: 400; }
.status { display: inline-block; padding: .35rem .55rem; border: 1px solid var(--line); font-size: .78rem; white-space: nowrap; }
.status-neu { background: #fff0df; border-color: #e3b49e; }
.status-in_pruefung { background: #eef1e8; }
.status-zugesagt { background: #dcefe1; }
.status-abgelehnt, .status-archiviert { background: #eeeeeb; color: var(--muted); }
.admin-empty, .admin-card { padding: 1.7rem; background: #fffdf8; border: 1px solid var(--line); }
.admin-detail-grid { display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(18rem, .75fr); gap: 1rem; margin-bottom: 1rem; }
.admin-card h2 { margin-top: 0; font-size: 1.8rem; }
.admin-card form { display: grid; gap: .7rem; }
.admin-card textarea { resize: vertical; min-height: 12rem; }
.admin-facts { display: grid; gap: 0; margin: 0; }
.admin-facts div { display: grid; grid-template-columns: minmax(8rem, .8fr) 1.2fr; gap: 1rem; padding: .85rem 0; border-bottom: 1px solid var(--line); }
.admin-facts div:last-child { border-bottom: 0; }
.admin-facts dt { color: var(--muted); }
.admin-facts dd { margin: 0; overflow-wrap: anywhere; }
.admin-facts-wide { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 2rem; }
.admin-facts-wide div { display: block; }
.admin-facts-wide dt { margin-bottom: .25rem; }
.admin-facts-wide dd { white-space: pre-wrap; }
.legal-page { min-height: 70vh; }
.legal-copy { max-width: 48rem; font-size: 1.05rem; }
.legal-copy h2 { font-size: 2.3rem; margin-top: 3rem; }

.properties-page { min-height: 70vh; }
.properties-intro { padding-bottom: clamp(3rem, 6vw, 5rem); }
.properties-intro h1 { font-size: clamp(4rem, 9vw, 8rem); }
.properties-intro > p:last-child { max-width: 42rem; color: var(--muted); font-size: 1.2rem; }
.property-feature { display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(20rem, .8fr); gap: clamp(2rem, 7vw, 7rem); align-items: start; padding-top: 0; }
.property-gallery { display: grid; grid-template-columns: 1.15fr .85fr; gap: .75rem; }
.property-gallery a { display: block; overflow: hidden; background: var(--paper-deep); }
.property-gallery a:first-child { grid-row: span 2; }
.property-gallery img { display: block; width: 100%; height: 100%; min-height: 12rem; object-fit: cover; transition: transform .35s ease; }
.property-gallery a:first-child img { min-height: 31rem; }
.property-gallery a:hover img { transform: scale(1.025); }
.property-copy { padding-top: 1rem; }
.property-status { color: var(--clay); font-size: .75rem; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; }
.property-copy h2 { font-size: clamp(2.5rem, 5vw, 5rem); }
.property-copy > p:not(.property-status) { max-width: 34rem; color: var(--muted); font-size: 1.1rem; }
.property-facts { display: grid; gap: .85rem; margin: 2rem 0 2.25rem; border-top: 1px solid var(--line); }
.property-facts div { display: flex; justify-content: space-between; gap: 1rem; padding-top: .85rem; border-bottom: 1px solid var(--line); }
.property-facts dt { color: var(--muted); }
.property-facts dd { margin: 0; text-align: right; }
.property-portal-note { max-width: none; margin-top: clamp(2rem, 6vw, 5rem); border-top: 1px solid var(--line); background: var(--paper-deep); }
.property-portal-note h2 { max-width: 34rem; }
.property-portal-note p:last-child { max-width: 38rem; color: var(--muted); font-size: 1.1rem; }

.application-page { min-height: 70vh; }
.application-intro { padding-bottom: 3rem; }
.application-intro h1 { max-width: 56rem; font-size: clamp(3.6rem, 8vw, 7.5rem); }
.application-intro > p:not(.eyebrow) { max-width: 42rem; color: var(--muted); font-size: 1.2rem; }
.application-steps { display: flex; flex-wrap: wrap; gap: .75rem 2rem; margin-top: 2rem; color: var(--muted); font-size: .95rem; }
.application-steps span { display: inline-flex; align-items: center; gap: .55rem; }
.application-steps b { display: grid; place-items: center; width: 1.8rem; height: 1.8rem; border: 1px solid var(--line); border-radius: 50%; color: var(--clay); }
.application-form { max-width: 1100px; padding-top: 2rem; }
.form-section { min-width: 0; margin: 0 0 2rem; padding: clamp(1.5rem, 3vw, 2.5rem); border: 1px solid var(--line); background: rgba(255, 253, 248, .6); }
.form-section legend { padding: 0 .7rem; font-family: var(--serif); font-size: clamp(1.8rem, 3vw, 2.5rem); line-height: 1.1; }
.form-section-intro { margin-top: 0; color: var(--muted); }
.form-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1.25rem 1.5rem; }
.field { display: grid; align-content: start; gap: .45rem; min-width: 0; }
.field-full { grid-column: 1 / -1; }
.field label, .field-inline-label { font-weight: 700; }
.field label span, .application-consent span span { color: var(--clay); }
.field input, .field textarea, .field select, .member-row input, .member-row select, .choice-fieldset input:not([type="radio"]) { width: 100%; min-height: 3.1rem; padding: .7rem .8rem; border: 1px solid rgba(25, 34, 29, .35); border-radius: 0; background: #fffefb; color: var(--ink); font: inherit; font-size: 1rem; }
.field textarea { min-height: 6rem; resize: vertical; }
.field input:focus, .field textarea:focus, .field select:focus, .member-row input:focus, .member-row select:focus { outline: 3px solid rgba(189, 90, 56, .35); outline-offset: 1px; border-color: var(--clay); }
.field-hint { color: var(--muted); font-size: .9rem; }
.choice-fieldset { min-width: 0; margin: 0; padding: 0; border: 0; }
.choice-fieldset legend { padding: 0; font-family: var(--sans); font-size: 1rem; font-weight: 700; line-height: 1.5; }
.choice-group { display: flex; flex-wrap: wrap; gap: .7rem; margin-top: .55rem; }
.choice { display: inline-flex; align-items: center; gap: .55rem; min-height: 3rem; padding: .55rem .9rem; border: 1px solid var(--line); background: #fffefb; cursor: pointer; }
.choice input { width: 1.2rem; height: 1.2rem; accent-color: var(--clay); }
.question-list { display: grid; gap: 1.4rem; }
.question-list .choice-fieldset { padding-bottom: 1.25rem; border-bottom: 1px solid var(--line); }
.question-list .choice-fieldset:last-child { padding-bottom: 0; border-bottom: 0; }
.field-inline-label { display: block; margin-top: 1rem; }
.field-inline-label + input { margin-top: .45rem; }
.member-table { display: grid; gap: .65rem; overflow-x: auto; }
.member-row { display: grid; grid-template-columns: minmax(11rem, 1fr) minmax(12rem, 1fr) minmax(11rem, 1fr); gap: .65rem; min-width: 35rem; }
.member-heading { color: var(--muted); font-size: .85rem; font-weight: 700; }
.member-row input, .member-row select { min-height: 2.9rem; }
.application-legal-copy { max-width: 56rem; margin: 1.75rem 0; color: var(--muted); font-size: .95rem; }
.application-consent { display: flex; align-items: flex-start; gap: .75rem; max-width: 58rem; font-size: .95rem; }
.application-consent input { flex: 0 0 auto; width: 1.35rem; height: 1.35rem; margin-top: .2rem; accent-color: var(--clay); }
.application-consent a, .application-submit a { text-decoration: underline; text-underline-offset: .18em; }
.application-submit { display: flex; align-items: center; justify-content: space-between; gap: 2rem; padding: 1rem 0 4rem; }
.application-submit p { max-width: 48rem; margin: 0; color: var(--muted); }
.application-submit .button { min-height: 3.25rem; white-space: nowrap; border: 0; font: inherit; cursor: pointer; }
.application-errors { margin: 0 0 1.5rem; padding: 1.1rem 1.25rem; border-left: .35rem solid var(--clay); background: #fff5ef; }
.application-errors ul { margin: .45rem 0 0; padding-left: 1.2rem; }
.application-result-page { background: var(--paper); }
.application-success { max-width: 900px; min-height: 65vh; padding-top: clamp(5rem, 12vw, 9rem); }
.application-success h1 { max-width: 50rem; font-size: clamp(3.5rem, 8vw, 7rem); }
.application-success > p:not(.eyebrow) { max-width: 40rem; color: var(--muted); font-size: 1.25rem; }
.success-next-step { max-width: 40rem; margin: 2rem 0; padding: 1.4rem 1.5rem; border-left: .35rem solid var(--clay); background: #fffefb; }
.success-next-step p { margin-bottom: 0; color: var(--muted); }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }

.site-footer { display: flex; justify-content: space-between; gap: 2rem; padding: 3rem clamp(1.25rem, 5vw, 5rem); background: var(--forest); color: #f5f2e9; }
.site-footer > div, .site-footer nav { display: flex; flex-wrap: wrap; gap: 1rem 1.5rem; align-items: center; }
.site-footer a { color: inherit; }
.site-footer a:hover { color: #e5b49c; }

@media (max-width: 800px) {
  .site-header { flex-wrap: wrap; gap: 1rem; }
  .brand-logo { width: 7rem; height: 2.8rem; }
  .site-nav { order: 3; width: 100%; overflow-x: auto; margin-left: 0; padding-top: .5rem; }
  .portal-link { margin-left: auto; }
  .service-grid, .project, .portal-actions { grid-template-columns: 1fr; }
  .service-grid article, .service-grid article + article { padding: 1.75rem 0; border-right: 0; border-bottom: 1px solid var(--line); }
  .service-grid article:first-child { padding-top: 0; }
  .service-grid article:last-child { border-bottom: 0; }
  .project { gap: 2.5rem; }
  .project-image { order: 2; }
  .property-feature { grid-template-columns: 1fr; gap: 2rem; }
  .property-gallery { grid-template-columns: 1fr 1fr; }
  .property-gallery a:first-child { grid-row: auto; grid-column: span 2; }
  .property-gallery a:first-child img { min-height: 20rem; }
  .property-copy { padding-top: 0; }
  .form-grid { grid-template-columns: 1fr; }
  .admin-heading, .admin-detail-grid { grid-template-columns: 1fr; display: grid; }
  .admin-facts-wide { grid-template-columns: 1fr; }
  .field-full { grid-column: auto; }
  .application-submit { align-items: flex-start; flex-direction: column; }
  .application-submit .button { width: 100%; text-align: center; }
  .site-footer { flex-direction: column; }
  .hero-media { transform: scale(1.5); }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .hero-media { display: none; }
  *, *::before, *::after { transition-duration: .01ms !important; animation-duration: .01ms !important; }
}
