/* ==========================================================================
   CityFoundry AG — Legal (Impressum · Datenschutz · Nutzungsbedingungen)
   Banner, sticky section switcher, long-form legal copy.
   Requires: tokens.css, base.css, components.css
   ========================================================================== */

@keyframes cf-legal-fade {
  from { opacity: 0; transform: translateY(18px); }
  to   { opacity: 1; transform: none; }
}

/* --- Banner --------------------------------------------------------------- */
.cf-lghero {
  position: relative;
  background: var(--cf-teal);
  padding: var(--cf-sec-pad) var(--cf-gutter);
  overflow: hidden;
}

.cf-lghero__glow {
  position: absolute;
  right: -6%;
  top: -45%;
  width: 560px;
  height: 560px;
  border-radius: 50%;
  background: var(--cf-gradient-conic);
  filter: blur(110px);
  opacity: .2;
}

.cf-lghero__inner {
  position: relative;
  max-width: var(--cf-shell);
  margin: 0 auto;
  animation: cf-legal-fade .7s ease both;
}

.cf-lghero__title {
  margin: 0 0 20px;
  max-width: 20ch;
  font-family: var(--cf-font-head);
  font-weight: 700;
  letter-spacing: -.01em;
  line-height: var(--cf-lh-h1);
  font-size: clamp(34px, 4.4vw, var(--cf-fs-h1));
  color: var(--cf-white);
}

.cf-lghero__lead {
  margin: 0;
  max-width: 560px;
  font-size: 18px;
  line-height: 1.7;
  color: var(--cf-sky);
}

/* --- Layout ----------------------------------------------------------------- */
.cf-legal-section {
  background: var(--cf-white);
  padding: 76px var(--cf-gutter) 100px;
}

/* One column since the tab sidebar was dropped. It was a two-column grid whose
   narrow track held the tabs; with the tabs gone the document landed in that
   .3fr track and read about 355px wide. 820px is a reading measure — the full
   1280px shell would run a legal paragraph past 120 characters. */
.cf-legal {
  max-width: 820px;
  margin: 0 auto;
}

/* --- Legal copy ------------------------------------------------------------------ */
.cf-legaldoc { animation: cf-legal-fade .4s ease both; }

.cf-legaldoc__title {
  margin: 0 0 26px;
  font-family: var(--cf-font-head);
  font-weight: 700;
  letter-spacing: -.035em;
  line-height: 1.1;
  font-size: clamp(26px, 3vw, 38px);
}

.cf-legaldoc__h3 {
  margin: 0 0 14px;
  font-family: var(--cf-font-head);
  font-weight: 700;
  font-size: 21px;
  letter-spacing: -.02em;
}

/* Sub-headings that follow a block of copy need air above them. */
.cf-legaldoc__h3--spaced { margin-top: 44px; }

.cf-legaldoc__p {
  margin: 0;
  font-size: 17px;
  line-height: 1.8;
  color: var(--cf-teal);
}

.cf-legaldoc__p--gap { margin-bottom: 16px; }
.cf-legaldoc__p--block { margin-bottom: 30px; }

/* --- Company facts table ------------------------------------------------------------ */

/* Hairlines are drawn with the grid gap showing through. */
.cf-facts {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1px;
  background: var(--cf-line-ink-10);
  border-radius: 18px;
  overflow: hidden;
  border: 1px solid var(--cf-line-ink-10);
}

.cf-facts__row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 32px;
  padding: 22px 26px;
  background: var(--cf-white);
}

.cf-facts__key {
  min-width: 190px;
  font-size: 15px;
  color: var(--cf-muted);
}

.cf-facts__value {
  font-size: 16.5px;
  font-weight: 500;
}

.cf-facts__note {
  margin: 26px 0 0;
  padding: 20px 24px;
  border-radius: 16px;
  background: var(--cf-crystal);
  font-size: 15px;
  line-height: 1.65;
  color: var(--cf-teal);
}

/* --- Privacy accordion ----------------------------------------------------------------- */
.cf-legal-accordion {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.cf-legal-accordion__item { border-top: 1px solid var(--cf-line-ink-12); }

.cf-legal-accordion__q {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 22px;
  padding: 24px 4px;
  border: 0;
  background: transparent;
  color: var(--cf-ink);
  font-family: var(--cf-font-head);
  font-weight: 700;
  font-size: clamp(17px, 1.9vw, 20px);
  letter-spacing: -.02em;
  text-align: left;
  cursor: pointer;
}

.cf-legal-accordion__label {
  display: flex;
  align-items: center;
  gap: 16px;
}

.cf-legal-accordion__num {
  font-size: 12px;
  color: var(--cf-placeholder);
}

/* `--icon-*` flip when the panel opens. */
.cf-legal-accordion__icon {
  flex-shrink: 0;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  border: 1px solid var(--cf-line-ink-16);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 17px;
  background: var(--icon-bg);
  color: var(--icon-fg);
  transition: all .3s ease;
}

.cf-legal-accordion__a {
  margin: 0;
  padding: 0 62px 26px 32px;
  font-size: 16.5px;
  line-height: 1.8;
  color: var(--cf-teal);
  animation: cf-legal-fade .3s ease both;
}

/* --- Rights panel ------------------------------------------------------------------------ */
.cf-rights {
  margin-top: 34px;
  padding: 28px 30px;
  border-radius: 20px;
  background: var(--cf-ink);
  color: var(--cf-sky);
}

.cf-rights__title {
  margin: 0 0 8px;
  font-family: var(--cf-font-head);
  font-weight: 700;
  font-size: 18px;
  color: var(--cf-white);
}

.cf-rights__text {
  margin: 0 0 16px;
  font-size: 16px;
  line-height: 1.7;
}

.cf-rights__link {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 16px;
  font-weight: 500;
  color: var(--cf-cyan);
  text-decoration: none;
}

/* --- Responsive ------------------------------------------------------------------------------ */
@media (max-width: 720px) {
  .cf-lghero,
  .cf-legal-section {
    padding-left: var(--cf-gutter-sm);
    padding-right: var(--cf-gutter-sm);
  }
}


/* Values the client still has to supply. Marked rather than invented - an
   invented address on a Swiss AG's Impressum is worse than a blank one. */
.cf-facts__pending {
  color: var(--cf-placeholder);
  font-style: italic;
}
