/* ============================================================
   CBB — Bauunternehmen & Architekturbüro Berlin
   Design system: Dunkelgrün + Gold/Sand + Weiß
   Sharp corners, editorial bands, heavy/light type contrast
   ============================================================ */

/* ---------- Self-hosted Schriften (DSGVO-konform, kein CDN) ---------- */
/* Dateien in assets/fonts/ ablegen — siehe assets/fonts/README.txt */
@font-face {
  font-family: "Hanken Grotesk";
  font-weight: 300;
  font-style: normal;
  font-display: swap;
  src: url("fonts/HankenGrotesk-Light.woff2") format("woff2");
}
@font-face {
  font-family: "Hanken Grotesk";
  font-weight: 400;
  font-style: normal;
  font-display: swap;
  src: url("fonts/HankenGrotesk-Regular.woff2") format("woff2");
}
@font-face {
  font-family: "Hanken Grotesk";
  font-weight: 500;
  font-style: normal;
  font-display: swap;
  src: url("fonts/HankenGrotesk-Medium.woff2") format("woff2");
}
@font-face {
  font-family: "Hanken Grotesk";
  font-weight: 600;
  font-style: normal;
  font-display: swap;
  src: url("fonts/HankenGrotesk-SemiBold.woff2") format("woff2");
}
@font-face {
  font-family: "Hanken Grotesk";
  font-weight: 700;
  font-style: normal;
  font-display: swap;
  src: url("fonts/HankenGrotesk-Bold.woff2") format("woff2");
}
@font-face {
  font-family: "Clash Display";
  font-weight: 400;
  font-style: normal;
  font-display: swap;
  src: url("fonts/ClashDisplay-Regular.woff2") format("woff2");
}
@font-face {
  font-family: "Clash Display";
  font-weight: 500;
  font-style: normal;
  font-display: swap;
  src: url("fonts/ClashDisplay-Medium.woff2") format("woff2");
}
@font-face {
  font-family: "Clash Display";
  font-weight: 600;
  font-style: normal;
  font-display: swap;
  src: url("fonts/ClashDisplay-Semibold.woff2") format("woff2");
}
@font-face {
  font-family: "Clash Display";
  font-weight: 700;
  font-style: normal;
  font-display: swap;
  src: url("fonts/ClashDisplay-Bold.woff2") format("woff2");
}

:root {
  /* Color system */
  --green: #15352B;
  --green-2: #1F4A3B;
  --green-deep: #0E2620;
  --gold: #B5904A;
  --gold-hi: #CBA85F;
  --sand: #F4EFE6;
  --white: #FFFFFF;
  --ink: #1A1F1C;
  --ink-2: #5E625C;
  --line: #E2DCCF;
  --line-dark: rgba(244, 239, 230, 0.16);

  /* Layout */
  --maxw: 1320px;
  --gutter: clamp(20px, 4.5vw, 72px);
  --col-gap: clamp(20px, 2.2vw, 32px);

  /* Type */
  --display: "Clash Display", "Space Grotesk", system-ui, sans-serif;
  --body: "Hanken Grotesk", system-ui, -apple-system, sans-serif;

  --section-y: clamp(80px, 11vw, 160px);
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
}

body {
  margin: 0;
  font-family: var(--body);
  font-weight: 400;
  color: var(--ink);
  background: var(--white);
  font-size: 18px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
button { font-family: inherit; cursor: pointer; }

::selection { background: var(--gold); color: var(--green-deep); }

/* Accessibility: visible focus */
a:focus-visible,
button:focus-visible,
input:focus-visible,
textarea:focus-visible,
select:focus-visible {
  outline: 2px solid var(--gold);
  outline-offset: 3px;
}

.skip-link {
  position: absolute;
  left: 16px; top: -100px;
  background: var(--gold);
  color: var(--green-deep);
  padding: 12px 20px;
  font-weight: 600;
  z-index: 200;
  transition: top .2s ease;
}
.skip-link:focus { top: 16px; }

/* ---------- Layout primitives ---------- */
.wrap {
  width: 100%;
  max-width: var(--maxw);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

.section { padding-block: var(--section-y); }

.band--green { background: var(--green); color: var(--sand); }
.band--green-deep { background: var(--green-deep); color: var(--sand); }
.band--sand { background: var(--sand); color: var(--ink); }
.band--white { background: var(--white); color: var(--ink); }

.grid12 {
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  gap: var(--col-gap);
}

/* ---------- Typography ---------- */
.eyebrow {
  font-family: var(--body);
  font-weight: 600;
  font-size: 13px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--gold);
  margin: 0 0 22px;
  display: inline-flex;
  align-items: center;
  gap: 14px;
}
.eyebrow::before {
  content: "";
  width: 34px;
  height: 1px;
  background: var(--gold);
  display: inline-block;
}
.eyebrow--center { justify-content: center; }

h1, h2, h3, h4 {
  font-family: var(--display);
  font-weight: 600;
  letter-spacing: -0.02em;
  line-height: 1.02;
  margin: 0;
  text-wrap: balance;
}

.display {
  font-weight: 700;
  font-size: clamp(2.6rem, 6.4vw, 5.4rem);
  line-height: 0.98;
  letter-spacing: -0.035em;
}
.h-xl { font-weight: 600; font-size: clamp(2.1rem, 4.6vw, 3.6rem); letter-spacing: -0.03em; }
.h-lg { font-weight: 600; font-size: clamp(1.7rem, 3vw, 2.5rem); }
.h-md { font-weight: 600; font-size: clamp(1.25rem, 2vw, 1.6rem); }

.lead {
  font-weight: 300;
  font-size: clamp(1.05rem, 1.5vw, 1.35rem);
  line-height: 1.6;
  color: var(--ink-2);
  max-width: 64ch;
}
.band--green .lead, .band--green-deep .lead { color: rgba(244, 239, 230, 0.82); }

p { margin: 0 0 1.1em; max-width: 68ch; }
.measure { max-width: 62ch; }

/* ---------- Buttons & link CTAs ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  white-space: nowrap;
  font-family: var(--body);
  font-weight: 600;
  font-size: 16px;
  letter-spacing: 0.01em;
  padding: 17px 30px;
  border: 1px solid transparent;
  transition: background .25s ease, color .25s ease, border-color .25s ease, transform .25s ease;
}
.btn--gold { background: var(--gold); color: var(--green-deep); }
.btn--gold:hover { background: var(--gold-hi); }
.btn--ghost-light { background: transparent; color: var(--sand); border-color: var(--line-dark); }
.btn--ghost-light:hover { border-color: var(--gold); color: var(--gold-hi); }
.btn--ghost-dark { background: transparent; color: var(--ink); border-color: var(--line); }
.btn--ghost-dark:hover { border-color: var(--green); }

.arrow-link {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  white-space: nowrap;
  font-weight: 600;
  font-size: 16px;
  color: var(--green);
  position: relative;
}
.band--green .arrow-link, .band--green-deep .arrow-link { color: var(--gold-hi); }
.arrow-link .arw { transition: transform .28s cubic-bezier(.2,.7,.3,1); }
.arrow-link:hover .arw { transform: translateX(7px); }
.arrow-link::after {
  content: "";
  position: absolute;
  left: 0; bottom: -4px;
  height: 1px; width: 0;
  background: currentColor;
  transition: width .3s ease;
}
.arrow-link:hover::after { width: calc(100% - 28px); }

/* ---------- Image placeholders (striped, square, captioned) ---------- */
.ph {
  position: relative;
  background-color: var(--sand);
  background-image: repeating-linear-gradient(
    -45deg,
    rgba(21, 53, 43, 0.045),
    rgba(21, 53, 43, 0.045) 1px,
    transparent 1px,
    transparent 11px
  );
  border: 1px solid var(--line);
  overflow: hidden;
  display: flex;
  align-items: flex-end;
}
.ph--dark {
  background-color: var(--green-deep);
  background-image: repeating-linear-gradient(
    -45deg,
    rgba(181, 144, 74, 0.10),
    rgba(181, 144, 74, 0.10) 1px,
    transparent 1px,
    transparent 11px
  );
  border-color: var(--line-dark);
}
.ph__cap {
  font-family: ui-monospace, "SF Mono", Menlo, Consolas, monospace;
  font-size: 11.5px;
  line-height: 1.4;
  letter-spacing: 0.01em;
  color: var(--ink-2);
  background: rgba(255,255,255,0.82);
  border-top: 1px solid var(--line);
  padding: 10px 14px;
  width: 100%;
  backdrop-filter: blur(2px);
}
.ph--dark .ph__cap {
  color: rgba(244,239,230,0.78);
  background: rgba(14, 38, 32, 0.72);
  border-top: 1px solid var(--line-dark);
}
.ph__badge {
  position: absolute;
  top: 16px; left: 16px;
  font-family: ui-monospace, Menlo, monospace;
  font-size: 10.5px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--gold);
  border: 1px solid var(--gold);
  padding: 5px 9px;
}

/* ---------- Reveal on scroll (only hidden when JS is active) ---------- */
.js .reveal {
  opacity: 0;
  transform: translateY(26px);
  transition: opacity .8s cubic-bezier(.2,.7,.2,1), transform .8s cubic-bezier(.2,.7,.2,1);
}
.reveal.in { opacity: 1; transform: none; }
/* snap-visible (above-the-fold, on load) — no fade to avoid CLS / stuck transitions */
.reveal.shown { opacity: 1; transform: none; transition: none; }
.reveal[data-d="1"] { transition-delay: .08s; }
.reveal[data-d="2"] { transition-delay: .16s; }
.reveal[data-d="3"] { transition-delay: .24s; }
.reveal[data-d="4"] { transition-delay: .32s; }
@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; transition: none; }
}
