:root {
    --color-bg: #fafaf8;
    --color-surface: #ffffff;
    --color-text: #1a2332;
    --color-text-muted: #55637a;
    --color-primary: #1e3a5f;
    --color-primary-dark: #132538;
    --color-accent: #d4a24c;
    --color-border: #e5e7eb;
    --color-hover: #f3f4f6;
    --max-width: 1100px;
    --radius: 8px;
    --shadow-sm: 0 1px 2px rgba(19, 37, 56, 0.06);
    --shadow-md: 0 4px 12px rgba(19, 37, 56, 0.08);
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Inter", Roboto, "Helvetica Neue", Arial, sans-serif;
    font-size: 17px;
    line-height: 1.65;
    color: var(--color-text);
    background: var(--color-bg);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

.container {
    max-width: var(--max-width);
    margin: 0 auto;
    padding: 0 1.5rem;
}

a {
    color: var(--color-primary);
    text-decoration: none;
    transition: color 0.15s ease;
}

a:hover {
    color: var(--color-accent);
    text-decoration: underline;
    text-underline-offset: 3px;
}

h1, h2, h3 {
    font-weight: 600;
    line-height: 1.25;
    color: var(--color-primary-dark);
}

h1 { font-size: clamp(2rem, 4.5vw, 3.25rem); letter-spacing: -0.02em; }
h2 { font-size: clamp(1.5rem, 3vw, 2.1rem); letter-spacing: -0.015em; margin-bottom: 1.25rem; }
h3 { font-size: 1.2rem; margin-bottom: 0.5rem; }

p { margin-bottom: 1rem; }

/* ---- Header ---- */

.site-header {
    background: var(--color-surface);
    border-bottom: 1px solid var(--color-border);
    position: sticky;
    top: 0;
    z-index: 100;
    backdrop-filter: saturate(180%) blur(8px);
    background-color: rgba(255, 255, 255, 0.92);
}

.site-header .container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding-top: 1rem;
    padding-bottom: 1rem;
}

.brand {
    display: flex;
    align-items: center;
    gap: 0.7rem;
    font-weight: 700;
    font-size: 1.15rem;
    color: var(--color-primary-dark);
    letter-spacing: -0.01em;
}

.brand:hover { text-decoration: none; color: var(--color-primary-dark); }

.brand-logo {
    height: 44px;
    width: auto;
    display: block;
}

.brand-tagline {
    font-weight: 400;
    color: var(--color-text-muted);
    font-size: 0.95rem;
    margin-left: 0.25rem;
}

.site-nav {
    display: flex;
    gap: 1.75rem;
    align-items: center;
}

.site-nav a {
    color: var(--color-text);
    font-size: 0.95rem;
    font-weight: 500;
}

.lang-switch {
    color: var(--color-text-muted);
    font-size: 0.9rem;
    padding-left: 1rem;
    border-left: 1px solid var(--color-border);
}

/* ---- Hero ---- */

.hero {
    padding: 5rem 0 4rem;
    background: linear-gradient(180deg, #fafaf8 0%, #f1f3f7 100%);
    border-bottom: 1px solid var(--color-border);
}

.hero-inner {
    max-width: 780px;
}

.hero .eyebrow {
    display: inline-block;
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--color-accent);
    text-transform: uppercase;
    letter-spacing: 0.1em;
    margin-bottom: 1rem;
}

.hero p.lead {
    font-size: 1.2rem;
    color: var(--color-text-muted);
    margin-top: 1.25rem;
    max-width: 640px;
}

.hero-cta {
    margin-top: 2rem;
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
}

.btn {
    display: inline-block;
    padding: 0.8rem 1.5rem;
    border-radius: var(--radius);
    font-weight: 500;
    font-size: 0.98rem;
    transition: all 0.15s ease;
    border: 1px solid transparent;
}

.btn-primary {
    background: var(--color-primary);
    color: #fff;
}

.btn-primary:hover {
    background: var(--color-primary-dark);
    color: #fff;
    text-decoration: none;
    transform: translateY(-1px);
    box-shadow: var(--shadow-md);
}

.btn-secondary {
    background: var(--color-surface);
    color: var(--color-primary);
    border-color: var(--color-border);
}

.btn-secondary:hover {
    background: var(--color-hover);
    border-color: var(--color-primary);
    color: var(--color-primary);
    text-decoration: none;
}

/* ---- Sections ---- */

section {
    padding: 4rem 0;
}

section.alt {
    background: var(--color-surface);
    border-top: 1px solid var(--color-border);
    border-bottom: 1px solid var(--color-border);
}

.section-lead {
    color: var(--color-text-muted);
    max-width: 720px;
    margin-bottom: 2.5rem;
    font-size: 1.05rem;
}

/* ---- Team cards ---- */

.team-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 1.75rem;
}

.team-card {
    background: var(--color-surface);
    border: 1px solid var(--color-border);
    border-radius: var(--radius);
    padding: 2rem;
    box-shadow: var(--shadow-sm);
    transition: box-shadow 0.2s ease, transform 0.2s ease;
    display: flex;
    flex-direction: column;
}

.team-card:hover {
    box-shadow: var(--shadow-md);
    transform: translateY(-2px);
}

.team-photo {
    width: 108px;
    height: 108px;
    border-radius: 50%;
    object-fit: cover;
    margin-bottom: 1.25rem;
    border: 3px solid var(--color-surface);
    box-shadow: 0 2px 8px rgba(19, 37, 56, 0.15);
    background: var(--color-bg);
}

.team-photo-placeholder {
    width: 108px;
    height: 108px;
    border-radius: 50%;
    margin-bottom: 1.25rem;
    background: linear-gradient(135deg, var(--color-primary) 0%, var(--color-primary-dark) 100%);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2.2rem;
    font-weight: 600;
    letter-spacing: 0.02em;
    border: 3px solid var(--color-surface);
    box-shadow: 0 2px 8px rgba(19, 37, 56, 0.15);
}

.team-header {
    display: flex;
    align-items: center;
    gap: 1rem;
    width: 100%;
    margin-bottom: 0.75rem;
}

.team-header .team-name-role {
    flex: 1;
    min-width: 0;
}

.team-header .team-name-role h3 {
    margin-bottom: 0.15rem;
}

.team-header .credential-badge {
    height: 84px;
    width: auto;
    flex-shrink: 0;
}

.team-header .role {
    margin-bottom: 0;
}

.team-card h3 {
    margin-bottom: 0.15rem;
}

.team-card .role {
    color: var(--color-accent);
    font-size: 0.9rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    margin-bottom: 1rem;
}

.team-card p {
    color: var(--color-text-muted);
    font-size: 0.98rem;
    flex-grow: 1;
}

.team-card .expertise {
    display: flex;
    flex-wrap: wrap;
    gap: 0.4rem;
    margin: 1rem 0 1.25rem;
}

.tag {
    display: inline-block;
    padding: 0.25rem 0.65rem;
    background: var(--color-bg);
    border: 1px solid var(--color-border);
    border-radius: 999px;
    font-size: 0.82rem;
    color: var(--color-text-muted);
}

.team-card .links {
    display: flex;
    gap: 1rem;
    margin-top: auto;
    padding-top: 0.5rem;
    font-size: 0.92rem;
}

.team-card .links a {
    font-weight: 500;
}

.team-card.provisional {
    border-style: dashed;
    border-color: var(--color-accent);
}

.team-card.provisional::before {
    content: "Profil in Arbeit";
    display: inline-block;
    font-size: 0.72rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--color-accent);
    background: rgba(212, 162, 76, 0.12);
    padding: 0.2rem 0.6rem;
    border-radius: 4px;
    margin-bottom: 0.75rem;
    align-self: flex-start;
}

.team-card.provisional[lang="en"]::before {
    content: "Profile in progress";
}

/* ---- Services ---- */

.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 1.25rem;
}

.service {
    padding: 1.5rem;
    background: var(--color-bg);
    border: 1px solid var(--color-border);
    border-radius: var(--radius);
}

.service h3 {
    font-size: 1.05rem;
    margin-bottom: 0.5rem;
    color: var(--color-primary);
}

.service p {
    font-size: 0.94rem;
    color: var(--color-text-muted);
    margin-bottom: 0;
}

/* ---- Partners ---- */

.partners-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 1rem;
    margin-top: 1.5rem;
}

.partner {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 0.6rem;
    padding: 1.5rem 1rem;
    background: var(--color-surface);
    border: 1px solid var(--color-border);
    border-radius: var(--radius);
    text-align: center;
    min-height: 130px;
    transition: border-color 0.15s ease, transform 0.15s ease, box-shadow 0.15s ease;
}

.partner:hover {
    border-color: var(--color-primary);
    transform: translateY(-2px);
    box-shadow: var(--shadow-sm);
    text-decoration: none;
}

.partner img {
    max-height: 56px;
    max-width: 150px;
    object-fit: contain;
}

.partner .partner-name {
    font-weight: 600;
    color: var(--color-primary-dark);
    font-size: 0.95rem;
    line-height: 1.25;
}

.partner.no-logo .partner-name {
    font-size: 1.05rem;
    color: var(--color-primary);
}

.partner.no-logo::before {
    content: "";
    display: block;
    width: 40px;
    height: 2px;
    background: var(--color-accent);
    border-radius: 2px;
    margin-bottom: 0.25rem;
}

/* ---- Contact ---- */

.contact-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 1.5rem;
    margin-top: 1rem;
}

.contact-block h3 {
    font-size: 1rem;
    color: var(--color-text-muted);
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    margin-bottom: 0.5rem;
}

.contact-block p {
    font-size: 1.05rem;
    color: var(--color-text);
    margin-bottom: 0.25rem;
}

/* ---- Footer ---- */

.site-footer {
    background: var(--color-primary-dark);
    color: #c5cad5;
    padding: 2.5rem 0;
    font-size: 0.92rem;
}

.site-footer .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 1rem;
}

.site-footer a {
    color: #e5e7eb;
}

.site-footer a:hover {
    color: var(--color-accent);
}

.footer-links {
    display: flex;
    gap: 1.5rem;
    flex-wrap: wrap;
}

/* ---- Legal pages ---- */

.legal {
    padding: 3rem 0 4rem;
    max-width: 780px;
    margin: 0 auto;
}

.legal h1 { margin-bottom: 1.5rem; }
.legal h2 { margin-top: 2rem; font-size: 1.35rem; }
.legal h3 { margin-top: 1.25rem; font-size: 1.1rem; color: var(--color-text); }

.legal p, .legal li {
    color: var(--color-text);
    font-size: 0.98rem;
}

.legal ul {
    padding-left: 1.5rem;
    margin-bottom: 1rem;
}

/* ---- Responsive ---- */

@media (max-width: 640px) {
    .site-header .container { flex-wrap: wrap; gap: 0.75rem; }
    .site-nav { gap: 1rem; font-size: 0.9rem; }
    .brand-tagline { display: none; }
    .hero { padding: 3rem 0; }
    section { padding: 3rem 0; }
    .site-footer .container { flex-direction: column; text-align: center; }
}
