/* =====================================================================
   Friedberger Wohnungsbaugesellschaft mbH — Design System v1
   Clean / glassmorphism · Urbanist · FBW-Blau #0072BC
   Author: Light Hunters
   ===================================================================== */

/* ---------- Design Tokens ---------- */
:root {
  /* Brand */
  --fbw-blue:       #0072BC;   /* Corporate primary (Logo)          */
  --fbw-blue-deep:  #005A94;   /* Hover / depth                     */
  --fbw-ink:        #2A4859;   /* Headlines, dark UI text           */
  --soft-blue:      #85B9C9;   /* Calm accent (from moodboard)      */
  --accent:         #FAD349;   /* Warm highlight                    */

  /* Neutrals */
  --white:          #FFFFFF;
  --bg:             #F6F6F6;
  --surface:        #FFFFFF;
  --line:           #E7ECEF;
  --ink-900:        #14232B;   /* near-black text                   */
  --ink-600:        #4A5b64;
  --ink-400:        #7C8B92;

  /* Glass */
  --glass-bg:       rgba(255, 255, 255, 0.55);
  --glass-brd:      rgba(255, 255, 255, 0.65);
  --glass-blur:     18px;

  /* Radius */
  --r-sm: 12px;
  --r-md: 20px;
  --r-lg: 28px;
  --r-xl: 36px;
  --r-pill: 999px;

  /* Shadow */
  --shadow-sm: 0 2px 8px rgba(20, 35, 43, 0.06);
  --shadow-md: 0 12px 32px rgba(20, 35, 43, 0.10);
  --shadow-lg: 0 24px 60px rgba(20, 35, 43, 0.14);

  /* Spacing scale (8pt) */
  --s-1: 4px;  --s-2: 8px;  --s-3: 12px; --s-4: 16px;
  --s-5: 24px; --s-6: 32px; --s-7: 48px; --s-8: 64px; --s-9: 96px;

  /* Type */
  --font: 'Urbanist', system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
  --maxw: 1120px;
}

/* ---------- Reset ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--font);
  font-weight: 400;
  font-size: 1.0625rem;
  line-height: 1.6;
  color: var(--ink-900);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
h1, h2, h3, h4 { margin: 0; color: var(--fbw-ink); line-height: 1.1; letter-spacing: -0.02em; }

/* ---------- Type scale ---------- */
.display { font-size: clamp(2.5rem, 6vw, 4.25rem); font-weight: 800; }
.h1 { font-size: clamp(2rem, 4vw, 3rem); font-weight: 700; }
.h2 { font-size: clamp(1.5rem, 3vw, 2.25rem); font-weight: 700; }
.h3 { font-size: 1.25rem; font-weight: 700; }
.lead { font-size: clamp(1.125rem, 1.6vw, 1.375rem); color: var(--ink-600); font-weight: 400; }
.eyebrow {
  font-size: 0.8125rem; font-weight: 700; letter-spacing: 0.14em;
  text-transform: uppercase; color: var(--fbw-blue);
}
.muted { color: var(--ink-400); }

/* ---------- Layout ---------- */
.wrap { width: 100%; max-width: var(--maxw); margin-inline: auto; padding-inline: var(--s-5); }
.section { padding-block: clamp(var(--s-7), 8vw, var(--s-9)); }
.stack > * + * { margin-top: var(--s-4); }
.grid-2 { display: grid; gap: var(--s-5); grid-template-columns: 1fr; }
@media (min-width: 820px) { .grid-2 { grid-template-columns: 1fr 1fr; } }

/* ---------- Aurora background ---------- */
.aurora { position: relative; overflow: clip; isolation: isolate; }
.aurora::before {
  content: ""; position: absolute; inset: -20% -10% auto -10%; height: 130%;
  z-index: -1;
  background:
    radial-gradient(42% 55% at 12% 18%, rgba(133,185,201,0.55), transparent 70%),
    radial-gradient(40% 50% at 88% 12%, rgba(0,114,188,0.30), transparent 70%),
    radial-gradient(45% 55% at 78% 88%, rgba(250,211,73,0.28), transparent 72%),
    radial-gradient(50% 60% at 30% 92%, rgba(199,178,232,0.30), transparent 72%);
  filter: blur(8px);
}

/* ---------- Glass card ---------- */
.glass {
  background: var(--glass-bg);
  border: 1px solid var(--glass-brd);
  border-radius: var(--r-lg);
  box-shadow: var(--shadow-md);
  -webkit-backdrop-filter: blur(var(--glass-blur)) saturate(140%);
  backdrop-filter: blur(var(--glass-blur)) saturate(140%);
}
.card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  box-shadow: var(--shadow-sm);
  padding: var(--s-6);
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; gap: var(--s-2);
  font-family: var(--font); font-weight: 700; font-size: 1rem;
  padding: 14px 26px; border-radius: var(--r-pill);
  border: 1px solid transparent; cursor: pointer;
  transition: transform .15s ease, box-shadow .2s ease, background .2s ease;
}
.btn:hover { transform: translateY(-2px); }
.btn--primary { background: var(--fbw-blue); color: var(--white); box-shadow: 0 8px 20px rgba(0,114,188,0.32); }
.btn--primary:hover { background: var(--fbw-blue-deep); }
.btn--ghost { background: rgba(255,255,255,0.6); color: var(--fbw-ink); border-color: var(--glass-brd); }
.btn--ghost:hover { background: var(--white); }
.btn--dark { background: var(--ink-900); color: var(--white); }
.btn__arrow { transition: transform .2s ease; }
.btn:hover .btn__arrow { transform: translateX(3px); }

/* ---------- Pills / chips ---------- */
.chip {
  display: inline-flex; align-items: center; gap: 6px;
  font-size: 0.8125rem; font-weight: 600;
  padding: 6px 14px; border-radius: var(--r-pill);
  background: rgba(255,255,255,0.7); border: 1px solid var(--glass-brd); color: var(--fbw-ink);
}

/* ---------- Header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(246,246,246,0.72);
  -webkit-backdrop-filter: blur(12px); backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--line);
}
.site-header .wrap { display: flex; align-items: center; justify-content: space-between; padding-block: var(--s-3); }
.brand { display: flex; align-items: center; gap: var(--s-3); }
.brand img { height: 42px; width: auto; }
.header-contact { display: none; gap: var(--s-4); align-items: center; font-size: 0.9rem; color: var(--ink-600); }
.header-contact a { font-weight: 600; }
@media (min-width: 720px) { .header-contact { display: flex; } }

/* ---------- Portal cards ---------- */
.portal {
  display: flex; flex-direction: column; gap: var(--s-4);
  padding: clamp(var(--s-6), 4vw, var(--s-7));
  border-radius: var(--r-xl);
  min-height: 300px;
  transition: transform .2s ease, box-shadow .25s ease;
}
.portal:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); }
.portal__icon {
  width: 56px; height: 56px; border-radius: 16px;
  display: grid; place-items: center; color: var(--white);
  box-shadow: var(--shadow-sm);
}
.portal__icon svg { width: 28px; height: 28px; }
.portal--tenant .portal__icon { background: linear-gradient(135deg, var(--fbw-blue), var(--soft-blue)); }
.portal--applicant .portal__icon { background: linear-gradient(135deg, var(--fbw-ink), var(--fbw-blue)); }
.portal p { color: var(--ink-600); margin: 0; }
.portal .btn { margin-top: auto; align-self: flex-start; }

/* ---------- Contact ---------- */
.contact-grid { display: grid; gap: var(--s-4); grid-template-columns: 1fr; }
@media (min-width: 640px) { .contact-grid { grid-template-columns: repeat(2, 1fr); } }
.contact-item { display: flex; gap: var(--s-3); align-items: flex-start; }
.contact-item .ic { color: var(--fbw-blue); flex: none; margin-top: 2px; }
.contact-item strong { display: block; color: var(--fbw-ink); font-weight: 700; }

/* ---------- Footer ---------- */
.site-footer { background: var(--ink-900); color: rgba(255,255,255,0.72); padding-block: var(--s-7); }
.site-footer a:hover { color: var(--white); }
.site-footer .wrap { display: flex; flex-wrap: wrap; gap: var(--s-5); justify-content: space-between; align-items: center; }
.footer-links { display: flex; gap: var(--s-4); flex-wrap: wrap; }

/* ---------- Design-system board helpers ---------- */
.swatch { border-radius: var(--r-md); height: 120px; display: flex; align-items: flex-end; padding: 14px; color: #fff; font-weight: 700; box-shadow: var(--shadow-sm); }
.swatch small { display:block; font-weight:500; opacity:.85; }
.swatch--light { color: var(--ink-900); }
.ds-grid { display: grid; gap: var(--s-4); grid-template-columns: repeat(2, 1fr); }
@media (min-width: 720px) { .ds-grid { grid-template-columns: repeat(4, 1fr); } }

/* ---------- Motion safety ---------- */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto; }
}
